Mercurial > vim
annotate runtime/syntax/cterm.vim @ 12199:5040c9c973c9
Added tag v8.0.0979 for changeset 65cff399750bbf2a9d01c5b4ed959cedc3024679
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Sun, 20 Aug 2017 20:30:04 +0200 |
parents | 46763b01cd9a |
children |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
2 " Language: Century Term Command Script | |
3 " Maintainer: Sean M. McKee <mckee@misslink.net> | |
4 " Last Change: 2002 Apr 13 | |
5 " Version Info: @(#)cterm.vim 1.7 97/12/15 09:23:14 | |
6 | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
7 " quit when a syntax file was already loaded |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
8 if exists("b:current_syntax") |
7 | 9 finish |
10 endif | |
11 | |
12 syn case ignore | |
13 | |
14 "FUNCTIONS | |
15 syn keyword ctermFunction abort addcr addlf answer at attr batch baud | |
16 syn keyword ctermFunction break call capture cd cdelay charset cls color | |
17 syn keyword ctermFunction combase config commect copy cread | |
18 syn keyword ctermFunction creadint devprefix dialer dialog dimint | |
19 syn keyword ctermFunction dimlog dimstr display dtimeout dwait edit | |
20 syn keyword ctermFunction editor emulate erase escloop fcreate | |
21 syn keyword ctermFunction fflush fillchar flags flush fopen fread | |
22 syn keyword ctermFunction freadln fseek fwrite fwriteln get hangup | |
23 syn keyword ctermFunction help hiwait htime ignore init itime | |
24 syn keyword ctermFunction keyboard lchar ldelay learn lockfile | |
25 syn keyword ctermFunction locktime log login logout lowait | |
26 syn keyword ctermFunction lsend ltime memlist menu mkdir mode | |
27 syn keyword ctermFunction modem netdialog netport noerror pages parity | |
28 syn keyword ctermFunction pause portlist printer protocol quit rcv | |
29 syn keyword ctermFunction read readint readn redial release | |
30 syn keyword ctermFunction remote rename restart retries return | |
31 syn keyword ctermFunction rmdir rtime run runx scrollback send | |
32 syn keyword ctermFunction session set setcap setcolor setkey | |
33 syn keyword ctermFunction setsym setvar startserver status | |
34 syn keyword ctermFunction stime stopbits stopserver tdelay | |
35 syn keyword ctermFunction terminal time trans type usend version | |
36 syn keyword ctermFunction vi vidblink vidcard vidout vidunder wait | |
37 syn keyword ctermFunction wildsize wclose wopen wordlen wru wruchar | |
38 syn keyword ctermFunction xfer xmit xprot | |
39 syn match ctermFunction "?" | |
40 "syn keyword ctermFunction comment remark | |
41 | |
42 "END FUNCTIONS | |
43 "INTEGER FUNCTIONS | |
44 syn keyword ctermIntFunction asc atod eval filedate filemode filesize ftell | |
45 syn keyword ctermIntFunction len termbits opsys pos sum time val mdmstat | |
46 "END INTEGER FUNCTIONS | |
47 | |
48 "STRING FUNCTIONS | |
49 syn keyword ctermStrFunction cdate ctime chr chrdy chrin comin getenv | |
50 syn keyword ctermStrFunction gethomedir left midstr right str tolower | |
51 syn keyword ctermStrFunction toupper uniq comst exists feof hascolor | |
52 | |
53 "END STRING FUNCTIONS | |
54 | |
55 "PREDEFINED TERM VARIABLES R/W | |
56 syn keyword ctermPreVarRW f _escloop _filename _kermiteol _obufsiz | |
57 syn keyword ctermPreVarRW _port _rcvsync _cbaud _reval _turnchar | |
58 syn keyword ctermPreVarRW _txblksiz _txwindow _vmin _vtime _cparity | |
59 syn keyword ctermPreVarRW _cnumber false t true _cwordlen _cstopbits | |
60 syn keyword ctermPreVarRW _cmode _cemulate _cxprot _clogin _clogout | |
61 syn keyword ctermPreVarRW _cstartsrv _cstopsrv _ccmdfile _cwru | |
62 syn keyword ctermPreVarRW _cprotocol _captfile _cremark _combufsiz | |
63 syn keyword ctermPreVarRW logfile | |
64 "END PREDEFINED TERM VARIABLES R/W | |
65 | |
66 "PREDEFINED TERM VARIABLES R/O | |
67 syn keyword ctermPreVarRO _1 _2 _3 _4 _5 _6 _7 _8 _9 _cursess | |
68 syn keyword ctermPreVarRO _lockfile _baud _errno _retval _sernum | |
69 syn keyword ctermPreVarRO _timeout _row _col _version | |
70 "END PREDEFINED TERM VARIABLES R/O | |
71 | |
72 syn keyword ctermOperator not mod eq ne gt le lt ge xor and or shr not shl | |
73 | |
74 "SYMBOLS | |
75 syn match CtermSymbols "|" | |
76 "syn keyword ctermOperators + - * / % = != > < >= <= & | ^ ! << >> | |
77 "END SYMBOLS | |
78 | |
79 "STATEMENT | |
80 syn keyword ctermStatement off | |
81 syn keyword ctermStatement disk overwrite append spool none | |
82 syn keyword ctermStatement echo view wrap | |
83 "END STATEMENT | |
84 | |
85 "TYPE | |
86 "syn keyword ctermType | |
87 "END TYPE | |
88 | |
89 "USERLIB FUNCTIONS | |
90 "syn keyword ctermLibFunc | |
91 "END USERLIB FUNCTIONS | |
92 | |
93 "LABEL | |
94 syn keyword ctermLabel case default | |
95 "END LABEL | |
96 | |
97 "CONDITIONAL | |
98 syn keyword ctermConditional on endon | |
99 syn keyword ctermConditional proc endproc | |
100 syn keyword ctermConditional for in do endfor | |
101 syn keyword ctermConditional if else elseif endif iferror | |
102 syn keyword ctermConditional switch endswitch | |
103 syn keyword ctermConditional repeat until | |
104 "END CONDITIONAL | |
105 | |
106 "REPEAT | |
107 syn keyword ctermRepeat while | |
108 "END REPEAT | |
109 | |
110 " Function arguments (eg $1 $2 $3) | |
111 syn match ctermFuncArg "\$[1-9]" | |
112 | |
113 syn keyword ctermTodo contained TODO | |
114 | |
115 syn match ctermNumber "\<\d\+\(u\=l\=\|lu\|f\)\>" | |
116 "floating point number, with dot, optional exponent | |
117 syn match ctermNumber "\<\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=\>" | |
118 "floating point number, starting with a dot, optional exponent | |
119 syn match ctermNumber "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" | |
120 "floating point number, without dot, with exponent | |
121 syn match ctermNumber "\<\d\+e[-+]\=\d\+[fl]\=\>" | |
122 "hex number | |
123 syn match ctermNumber "0x[0-9a-f]\+\(u\=l\=\|lu\)\>" | |
124 | |
125 syn match ctermComment "![^=].*$" contains=ctermTodo | |
126 syn match ctermComment "!$" | |
127 syn match ctermComment "\*.*$" contains=ctermTodo | |
128 syn region ctermComment start="comment" end="$" contains=ctermTodo | |
129 syn region ctermComment start="remark" end="$" contains=ctermTodo | |
130 | |
131 syn region ctermVar start="\$(" end=")" | |
132 | |
133 " String and Character contstants | |
134 " Highlight special characters (those which have a backslash) differently | |
135 syn match ctermSpecial contained "\\\d\d\d\|\\." | |
136 syn match ctermSpecial contained "\^." | |
137 syn region ctermString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=ctermSpecial,ctermVar,ctermSymbols | |
138 syn match ctermCharacter "'[^\\]'" | |
139 syn match ctermSpecialCharacter "'\\.'" | |
140 | |
141 " Define the default highlighting. | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
142 " Only when an item doesn't have highlighting yet |
7 | 143 |
10051
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
144 hi def link ctermStatement Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
145 hi def link ctermFunction Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
146 hi def link ctermStrFunction Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
147 hi def link ctermIntFunction Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
148 hi def link ctermLabel Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
149 hi def link ctermConditional Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
150 hi def link ctermRepeat Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
151 hi def link ctermLibFunc UserDefFunc |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
152 hi def link ctermType Type |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
153 hi def link ctermFuncArg PreCondit |
7 | 154 |
10051
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
155 hi def link ctermPreVarRO PreCondit |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
156 hi def link ctermPreVarRW PreConditBold |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
157 hi def link ctermVar Type |
7 | 158 |
10051
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
159 hi def link ctermComment Comment |
7 | 160 |
10051
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
161 hi def link ctermCharacter SpecialChar |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
162 hi def link ctermSpecial Special |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
163 hi def link ctermSpecialCharacter SpecialChar |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
164 hi def link ctermSymbols Special |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
165 hi def link ctermString String |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
166 hi def link ctermTodo Todo |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
167 hi def link ctermOperator Statement |
46763b01cd9a
commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents:
10048
diff
changeset
|
168 hi def link ctermNumber Number |
7 | 169 |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
170 " redefine the colors |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
171 "hi PreConditBold term=bold ctermfg=1 cterm=bold guifg=Purple gui=bold |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
172 "hi Special term=bold ctermfg=6 guifg=SlateBlue gui=underline |
7 | 173 |
174 | |
175 let b:current_syntax = "cterm" | |
176 | |
177 " vim: ts=8 |