annotate runtime/syntax/a2ps.vim @ 0:76efa0be13f1

Initial revision
author atsuki
date Sat, 10 Nov 2007 15:07:22 +0900
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
1 " Vim syntax file
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
2 " Language: a2ps(1) configuration file
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
3 " Maintainer: Nikolai Weibull <now@bitwi.se>
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
4 " Latest Revision: 2006-04-19
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
5
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
6 if exists("b:current_syntax")
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
7 finish
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
8 endif
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
9
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
10 let s:cpo_save = &cpo
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
11 set cpo&vim
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
12
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
13 syn keyword a2psPreProc Include
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
14 \ nextgroup=a2psKeywordColon
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
15
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
16 syn keyword a2psMacro UserOption
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
17 \ nextgroup=a2psKeywordColon
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
18
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
19 syn keyword a2psKeyword LibraryPath AppendLibraryPath PrependLibraryPath
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
20 \ Options Medium Printer UnknownPrinter
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
21 \ DefaultPrinter OutputFirstLine
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
22 \ PageLabelFormat Delegation FileCommand
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
23 \ nextgroup=a2psKeywordColon
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
24
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
25 syn match a2psKeywordColon contained display ':'
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
26
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
27 syn keyword a2psKeyword Variable nextgroup=a2psVariableColon
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
28
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
29 syn match a2psVariableColon contained display ':'
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
30 \ nextgroup=a2psVariable skipwhite
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
31
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
32 syn match a2psVariable contained display '[^ \t:(){}]\+'
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
33 \ contains=a2psVarPrefix
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
34
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
35 syn match a2psVarPrefix contained display
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
36 \ '\<\%(del\|pro\|ps\|pl\|toc\|user\|\)\ze\.'
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
37
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
38 syn match a2psLineCont display '\\$'
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
39
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
40 syn match a2psSubst display '$\%(-\=.\=\d\+\)\=\h\d\='
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
41 syn match a2psSubst display '#[?!]\=\w\d\='
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
42 syn match a2psSubst display '#{[^}]\+}'
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
43
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
44 syn region a2psString display oneline start=+'+ end=+'+
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
45 \ contains=a2psSubst
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
46
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
47 syn region a2psString display oneline start=+"+ end=+"+
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
48 \ contains=a2psSubst
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
49
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
50 syn keyword a2psTodo contained TODO FIXME XXX NOTE
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
51
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
52 syn region a2psComment display oneline start='^\s*#' end='$'
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
53 \ contains=a2psTodo,@Spell
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
54
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
55 hi def link a2psTodo Todo
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
56 hi def link a2psComment Comment
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
57 hi def link a2psPreProc PreProc
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
58 hi def link a2psMacro Macro
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
59 hi def link a2psKeyword Keyword
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
60 hi def link a2psKeywordColon Delimiter
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
61 hi def link a2psVariableColon Delimiter
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
62 hi def link a2psVariable Identifier
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
63 hi def link a2psVarPrefix Type
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
64 hi def link a2psLineCont Special
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
65 hi def link a2psSubst PreProc
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
66 hi def link a2psString String
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
67
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
68 let b:current_syntax = "a2ps"
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
69
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
70 let &cpo = s:cpo_save
76efa0be13f1 Initial revision
atsuki
parents:
diff changeset
71 unlet s:cpo_save