Start anew
[msysgit.git] / share / vim / vim58 / syntax / mgp.vim
blobedcf12327e821d61bdefcee504f1d66fe91dc3f5
1 " Vim syntax file
2 " Language:     mgp - MaGic Point
3 " Maintainer:   Gerfried Fuchs <alfie@ist.org>
4 " Filenames:    *.mgp
5 " Last Change:  25 Apr 2001
6 " URL:          http://alfie.ist.org/vim/syntax/mgp.vim
8 " Comments are very welcome - but please make sure that you are commenting on
9 " the latest version of this file.
10 " SPAM is _NOT_ welcome - be ready to be reported!
13 " For version 5.x: Clear all syntax items
14 " For version 6.x: Quit when a syntax file was already loaded
15 if version < 600
16   syn clear
17 elseif exists("b:current_syntax")
18   finish
19 endif
22 syn match mgpLineSkip "\\$"
24 " all the commands that are currently recognized
25 syn keyword mgpCommand contained size fore back bgrad left leftfill center
26 syn keyword mgpCommand contained right shrink lcutin rcutin cont xfont vfont
27 syn keyword mgpCommand contained tfont tmfont tfont0 bar image newimage
28 syn keyword mgpCommand contained prefix icon bimage default tab vgap hgap
29 syn keyword mgpCommand contained pause mark again system filter endfilter
30 syn keyword mgpCommand contained vfcap tfdir deffont font embed endembed
31 syn keyword mgpCommand contained noop pcache include
33 " charset is not yet supported :-)
34 " syn keyword mgpCommand contained charset
36 syn region mgpFile     contained start=+"+ skip=+\\\\\|\\"+ end=+"+
37 syn match mgpValue     contained "\d\+"
38 syn match mgpSize      contained "\d\+x\d\+"
39 syn match mgpLine      +^%.*$+ contains=mgpCommand,mgpFile,mgpSize,mgpValue
41 " Comments
42 syn match mgpPercent   +^%%.*$+
43 syn match mgpHash      +^#.*$+
45 " these only work alone
46 syn match mgpPage      +^%page$+
47 syn match mgpNoDefault +^%nodefault$+
50 " Define the default highlighting.
51 " For version 5.7 and earlier: only when not done already
52 " For version 5.8 and later: only when an item doesn't have highlighting yet
53 if version >= 508 || !exists("did_mgp_syn_inits")
54   let did_mgp_syn_inits = 1
55   if version < 508
56     let did_mgp_syn_inits = 1
57     command -nargs=+ HiLink hi link <args>
58   else
59     command -nargs=+ HiLink hi def link <args>
60   endif
62   HiLink mgpLineSkip    Special
64   HiLink mgpHash        mgpComment
65   HiLink mgpPercent     mgpComment
66   HiLink mgpComment     Comment
68   HiLink mgpCommand     Identifier
70   HiLink mgpLine        Type
72   HiLink mgpFile        String
73   HiLink mgpSize        Number
74   HiLink mgpValue       Number
76   HiLink mgpPage        mgpDefine
77   HiLink mgpNoDefault   mgpDefine
78   HiLink mgpDefine      Define
80   delcommand HiLink
81 endif
83 let b:current_syntax = "mgp"