2 " Language: bin using xxd
3 " Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
4 " Last Change: Sep 06, 2005
6 " Notes: use :help xxd to see how to invoke it
7 " URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
9 " For version 5.x: Clear all syntax items
10 " For version 6.x: Quit when a syntax file was already loaded
13 elseif exists("b:current_syntax")
17 syn match xxdAddress "^[0-9a-f]\+:" contains=xxdSep
18 syn match xxdSep contained ":"
19 syn match xxdAscii " .\{,16\}\r\=$"hs=s+2 contains=xxdDot
20 syn match xxdDot contained "[.\r]"
22 " Define the default highlighting.
23 " For version 5.7 and earlier: only when not done already
24 " For version 5.8 and later: only when an item doesn't have highlighting yet
25 if version >= 508 || !exists("did_xxd_syntax_inits")
27 let did_xxd_syntax_inits = 1
28 command -nargs=+ HiLink hi link <args>
30 command -nargs=+ HiLink hi def link <args>
33 HiLink xxdAddress Constant
34 HiLink xxdSep Identifier
35 HiLink xxdAscii Statement
40 let b:current_syntax = "xxd"