blob: 5af57aa0b1625bd6656cdb3897e3bd4265b4a308 [file] [log] [blame]
Bram Moolenaar071d4272004-06-13 20:20:40 +00001" Vim syntax file
2" Language: PostScript - all Levels, selectable
3" Maintainer: Mike Williams <mrw@eandem.co.uk>
4" Filenames: *.ps,*.eps
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +00005" Last Change: 31st October 2007
6" URL: http://www.eandem.co.uk/mrw/vim
Bram Moolenaar071d4272004-06-13 20:20:40 +00007"
8" Options Flags:
Bram Moolenaar6c391a72021-09-09 21:55:11 +02009" postscr_level - language level to use for highlighting (1, 2, or 3)
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000010" postscr_display - include display PS operators
11" postscr_ghostscript - include GS extensions
12" postscr_fonts - highlight standard font names (a lot for PS 3)
13" postscr_encodings - highlight encoding names (there are a lot)
14" postscr_andornot_binary - highlight and, or, and not as binary operators (not logical)
Bram Moolenaar071d4272004-06-13 20:20:40 +000015"
Bram Moolenaar89bcfda2016-08-30 23:26:57 +020016" quit when a syntax file was already loaded
17if exists("b:current_syntax")
Bram Moolenaar071d4272004-06-13 20:20:40 +000018 finish
19endif
20
21" PostScript is case sensitive
22syn case match
23
24" Keyword characters - all 7-bit ASCII bar PS delimiters and ws
Bram Moolenaar89bcfda2016-08-30 23:26:57 +020025setlocal iskeyword=33-127,^(,^),^<,^>,^[,^],^{,^},^/,^%
Bram Moolenaar071d4272004-06-13 20:20:40 +000026
27" Yer trusty old TODO highlghter!
28syn keyword postscrTodo contained TODO
29
30" Comment
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000031syn match postscrComment "%.*$" contains=postscrTodo,@Spell
Bram Moolenaar071d4272004-06-13 20:20:40 +000032" DSC comment start line (NB: defines DSC level, not PS level!)
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000033syn match postscrDSCComment "^%!PS-Adobe-\d\+\.\d\+\s*.*$"
Bram Moolenaar071d4272004-06-13 20:20:40 +000034" DSC comment line (no check on possible comments - another language!)
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000035syn match postscrDSCComment "^%%\u\+.*$" contains=@postscrString,@postscrNumber,@Spell
Bram Moolenaar071d4272004-06-13 20:20:40 +000036" DSC continuation line (no check that previous line is DSC comment)
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000037syn match postscrDSCComment "^%%+ *.*$" contains=@postscrString,@postscrNumber,@Spell
Bram Moolenaar071d4272004-06-13 20:20:40 +000038
39" Names
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000040syn match postscrName "\k\+"
Bram Moolenaar071d4272004-06-13 20:20:40 +000041
42" Identifiers
43syn match postscrIdentifierError "/\{1,2}[[:space:]\[\]{}]"me=e-1
44syn match postscrIdentifier "/\{1,2}\k\+" contains=postscrConstant,postscrBoolean,postscrCustConstant
45
46" Numbers
47syn case ignore
48" In file hex data - usually complete lines
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000049syn match postscrHex "^[[:xdigit:]][[:xdigit:][:space:]]*$"
50"syn match postscrHex "\<\x\{2,}\>"
Bram Moolenaar071d4272004-06-13 20:20:40 +000051" Integers
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000052syn match postscrInteger "\<[+-]\=\d\+\>"
Bram Moolenaar071d4272004-06-13 20:20:40 +000053" Radix
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000054syn match postscrRadix "\d\+#\x\+\>"
Bram Moolenaar071d4272004-06-13 20:20:40 +000055" Reals - upper and lower case e is allowed
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000056syn match postscrFloat "[+-]\=\d\+\.\>"
57syn match postscrFloat "[+-]\=\d\+\.\d*\(e[+-]\=\d\+\)\=\>"
58syn match postscrFloat "[+-]\=\.\d\+\(e[+-]\=\d\+\)\=\>"
59syn match postscrFloat "[+-]\=\d\+e[+-]\=\d\+\>"
60syn cluster postscrNumber contains=postscrInteger,postscrRadix,postscrFloat
Bram Moolenaar071d4272004-06-13 20:20:40 +000061syn case match
62
63" Escaped characters
64syn match postscrSpecialChar contained "\\[nrtbf\\()]"
65syn match postscrSpecialCharError contained "\\[^nrtbf\\()]"he=e-1
66" Escaped octal characters
67syn match postscrSpecialChar contained "\\\o\{1,3}"
68
69" Strings
70" ASCII strings
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +000071syn region postscrASCIIString start=+(+ end=+)+ skip=+([^)]*)+ contains=postscrSpecialChar,postscrSpecialCharError,@Spell
72syn match postscrASCIIStringError ")"
Bram Moolenaar071d4272004-06-13 20:20:40 +000073" Hex strings
74syn match postscrHexCharError contained "[^<>[:xdigit:][:space:]]"
75syn region postscrHexString start=+<\($\|[^<]\)+ end=+>+ contains=postscrHexCharError
76syn match postscrHexString "<>"
77" ASCII85 strings
78syn match postscrASCII85CharError contained "[^<>\~!-uz[:space:]]"
79syn region postscrASCII85String start=+<\~+ end=+\~>+ contains=postscrASCII85CharError
80syn cluster postscrString contains=postscrASCIIString,postscrHexString,postscrASCII85String
81
82
83" Set default highlighting to level 2 - most common at the moment
84if !exists("postscr_level")
85 let postscr_level = 2
86endif
87
88
89" PS level 1 operators - common to all levels (well ...)
90
91" Stack operators
92syn keyword postscrOperator pop exch dup copy index roll clear count mark cleartomark counttomark
93
94" Math operators
95syn keyword postscrMathOperator add div idiv mod mul sub abs neg ceiling floor round truncate sqrt atan cos
96syn keyword postscrMathOperator sin exp ln log rand srand rrand
97
98" Array operators
99syn match postscrOperator "[\[\]{}]"
100syn keyword postscrOperator array length get put getinterval putinterval astore aload copy
101syn keyword postscrRepeat forall
102
103" Dictionary operators
104syn keyword postscrOperator dict maxlength begin end def load store known where currentdict
105syn keyword postscrOperator countdictstack dictstack cleardictstack internaldict
106syn keyword postscrConstant $error systemdict userdict statusdict errordict
107
108" String operators
109syn keyword postscrOperator string anchorsearch search token
110
111" Logic operators
112syn keyword postscrLogicalOperator eq ne ge gt le lt and not or
113if exists("postscr_andornot_binaryop")
114 syn keyword postscrBinaryOperator and or not
115else
116 syn keyword postscrLogicalOperator and not or
117endif
118syn keyword postscrBinaryOperator xor bitshift
119syn keyword postscrBoolean true false
120
121" PS Type names
122syn keyword postscrConstant arraytype booleantype conditiontype dicttype filetype fonttype gstatetype
123syn keyword postscrConstant integertype locktype marktype nametype nulltype operatortype
124syn keyword postscrConstant packedarraytype realtype savetype stringtype
125
126" Control operators
127syn keyword postscrConditional if ifelse
128syn keyword postscrRepeat for repeat loop
129syn keyword postscrOperator exec exit stop stopped countexecstack execstack quit
130syn keyword postscrProcedure start
131
132" Object operators
133syn keyword postscrOperator type cvlit cvx xcheck executeonly noaccess readonly rcheck wcheck cvi cvn cvr
134syn keyword postscrOperator cvrs cvs
135
136" File operators
137syn keyword postscrOperator file closefile read write readhexstring writehexstring readstring writestring
138syn keyword postscrOperator bytesavailable flush flushfile resetfile status run currentfile print
139syn keyword postscrOperator stack pstack readline deletefile setfileposition fileposition renamefile
140syn keyword postscrRepeat filenameforall
141syn keyword postscrProcedure = ==
142
143" VM operators
144syn keyword postscrOperator save restore
145
146" Misc operators
147syn keyword postscrOperator bind null usertime executive echo realtime
148syn keyword postscrConstant product revision serialnumber version
149syn keyword postscrProcedure prompt
150
151" GState operators
152syn keyword postscrOperator gsave grestore grestoreall initgraphics setlinewidth setlinecap currentgray
153syn keyword postscrOperator currentlinejoin setmiterlimit currentmiterlimit setdash currentdash setgray
154syn keyword postscrOperator sethsbcolor currenthsbcolor setrgbcolor currentrgbcolor currentlinewidth
155syn keyword postscrOperator currentlinecap setlinejoin setcmykcolor currentcmykcolor
156
157" Device gstate operators
158syn keyword postscrOperator setscreen currentscreen settransfer currenttransfer setflat currentflat
159syn keyword postscrOperator currentblackgeneration setblackgeneration setundercolorremoval
160syn keyword postscrOperator setcolorscreen currentcolorscreen setcolortransfer currentcolortransfer
161syn keyword postscrOperator currentundercolorremoval
162
163" Matrix operators
164syn keyword postscrOperator matrix initmatrix identmatrix defaultmatrix currentmatrix setmatrix translate
165syn keyword postscrOperator concat concatmatrix transform dtransform itransform idtransform invertmatrix
166syn keyword postscrOperator scale rotate
167
168" Path operators
169syn keyword postscrOperator newpath currentpoint moveto rmoveto lineto rlineto arc arcn arcto curveto
170syn keyword postscrOperator closepath flattenpath reversepath strokepath charpath clippath pathbbox
171syn keyword postscrOperator initclip clip eoclip rcurveto
172syn keyword postscrRepeat pathforall
173
174" Painting operators
175syn keyword postscrOperator erasepage fill eofill stroke image imagemask colorimage
176
177" Device operators
178syn keyword postscrOperator showpage copypage nulldevice
179
180" Character operators
181syn keyword postscrProcedure findfont
182syn keyword postscrConstant FontDirectory ISOLatin1Encoding StandardEncoding
183syn keyword postscrOperator definefont scalefont makefont setfont currentfont show ashow
184syn keyword postscrOperator stringwidth kshow setcachedevice
185syn keyword postscrOperator setcharwidth widthshow awidthshow findencoding cshow rootfont setcachedevice2
186
187" Interpreter operators
188syn keyword postscrOperator vmstatus cachestatus setcachelimit
189
190" PS constants
191syn keyword postscrConstant contained Gray Red Green Blue All None DeviceGray DeviceRGB
192
193" PS Filters
194syn keyword postscrConstant contained ASCIIHexDecode ASCIIHexEncode ASCII85Decode ASCII85Encode LZWDecode
195syn keyword postscrConstant contained RunLengthDecode RunLengthEncode SubFileDecode NullEncode
196syn keyword postscrConstant contained GIFDecode PNGDecode LZWEncode
197
198" PS JPEG filter dictionary entries
199syn keyword postscrConstant contained DCTEncode DCTDecode Colors HSamples VSamples QuantTables QFactor
200syn keyword postscrConstant contained HuffTables ColorTransform
201
202" PS CCITT filter dictionary entries
203syn keyword postscrConstant contained CCITTFaxEncode CCITTFaxDecode Uncompressed K EndOfLine
204syn keyword postscrConstant contained Columns Rows EndOfBlock Blacks1 DamagedRowsBeforeError
205syn keyword postscrConstant contained EncodedByteAlign
206
207" PS Form dictionary entries
208syn keyword postscrConstant contained FormType XUID BBox Matrix PaintProc Implementation
209
210" PS Errors
211syn keyword postscrProcedure handleerror
212syn keyword postscrConstant contained configurationerror dictfull dictstackunderflow dictstackoverflow
213syn keyword postscrConstant contained execstackoverflow interrupt invalidaccess
214syn keyword postscrConstant contained invalidcontext invalidexit invalidfileaccess invalidfont
215syn keyword postscrConstant contained invalidid invalidrestore ioerror limitcheck nocurrentpoint
216syn keyword postscrConstant contained rangecheck stackoverflow stackunderflow syntaxerror timeout
217syn keyword postscrConstant contained typecheck undefined undefinedfilename undefinedresource
218syn keyword postscrConstant contained undefinedresult unmatchedmark unregistered VMerror
219
220if exists("postscr_fonts")
221" Font names
222 syn keyword postscrConstant contained Symbol Times-Roman Times-Italic Times-Bold Times-BoldItalic
223 syn keyword postscrConstant contained Helvetica Helvetica-Oblique Helvetica-Bold Helvetica-BoldOblique
224 syn keyword postscrConstant contained Courier Courier-Oblique Courier-Bold Courier-BoldOblique
225endif
226
227
228if exists("postscr_display")
229" Display PS only operators
230 syn keyword postscrOperator currentcontext fork join detach lock monitor condition wait notify yield
231 syn keyword postscrOperator viewclip eoviewclip rectviewclip initviewclip viewclippath deviceinfo
232 syn keyword postscrOperator sethalftonephase currenthalftonephase wtranslation defineusername
233endif
234
235" PS Character encoding names
236if exists("postscr_encodings")
237" Common encoding names
238 syn keyword postscrConstant contained .notdef
239
240" Standard and ISO encoding names
241 syn keyword postscrConstant contained space exclam quotedbl numbersign dollar percent ampersand quoteright
242 syn keyword postscrConstant contained parenleft parenright asterisk plus comma hyphen period slash zero
243 syn keyword postscrConstant contained one two three four five six seven eight nine colon semicolon less
244 syn keyword postscrConstant contained equal greater question at
245 syn keyword postscrConstant contained bracketleft backslash bracketright asciicircum underscore quoteleft
246 syn keyword postscrConstant contained braceleft bar braceright asciitilde
247 syn keyword postscrConstant contained exclamdown cent sterling fraction yen florin section currency
248 syn keyword postscrConstant contained quotesingle quotedblleft guillemotleft guilsinglleft guilsinglright
249 syn keyword postscrConstant contained fi fl endash dagger daggerdbl periodcentered paragraph bullet
250 syn keyword postscrConstant contained quotesinglbase quotedblbase quotedblright guillemotright ellipsis
251 syn keyword postscrConstant contained perthousand questiondown grave acute circumflex tilde macron breve
252 syn keyword postscrConstant contained dotaccent dieresis ring cedilla hungarumlaut ogonek caron emdash
253 syn keyword postscrConstant contained AE ordfeminine Lslash Oslash OE ordmasculine ae dotlessi lslash
254 syn keyword postscrConstant contained oslash oe germandbls
255" The following are valid names, but are used as short procedure names in generated PS!
256" a b c d e f g h i j k l m n o p q r s t u v w x y z
257" A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
258
259" Symbol encoding names
260 syn keyword postscrConstant contained universal existential suchthat asteriskmath minus
261 syn keyword postscrConstant contained congruent Alpha Beta Chi Delta Epsilon Phi Gamma Eta Iota theta1
262 syn keyword postscrConstant contained Kappa Lambda Mu Nu Omicron Pi Theta Rho Sigma Tau Upsilon sigma1
263 syn keyword postscrConstant contained Omega Xi Psi Zeta therefore perpendicular
264 syn keyword postscrConstant contained radicalex alpha beta chi delta epsilon phi gamma eta iota phi1
265 syn keyword postscrConstant contained kappa lambda mu nu omicron pi theta rho sigma tau upsilon omega1
266 syn keyword postscrConstant contained Upsilon1 minute lessequal infinity club diamond heart spade
267 syn keyword postscrConstant contained arrowboth arrowleft arrowup arrowright arrowdown degree plusminus
268 syn keyword postscrConstant contained second greaterequal multiply proportional partialdiff divide
269 syn keyword postscrConstant contained notequal equivalence approxequal arrowvertex arrowhorizex
270 syn keyword postscrConstant contained aleph Ifraktur Rfraktur weierstrass circlemultiply circleplus
271 syn keyword postscrConstant contained emptyset intersection union propersuperset reflexsuperset notsubset
272 syn keyword postscrConstant contained propersubset reflexsubset element notelement angle gradient
273 syn keyword postscrConstant contained registerserif copyrightserif trademarkserif radical dotmath
274 syn keyword postscrConstant contained logicalnot logicaland logicalor arrowdblboth arrowdblleft arrowdblup
275 syn keyword postscrConstant contained arrowdblright arrowdbldown omega xi psi zeta similar carriagereturn
276 syn keyword postscrConstant contained lozenge angleleft registersans copyrightsans trademarksans summation
277 syn keyword postscrConstant contained parenlefttp parenleftex parenleftbt bracketlefttp bracketleftex
278 syn keyword postscrConstant contained bracketleftbt bracelefttp braceleftmid braceleftbt braceex euro
279 syn keyword postscrConstant contained angleright integral integraltp integralex integralbt parenrighttp
280 syn keyword postscrConstant contained parenrightex parenrightbt bracketrighttp bracketrightex
281 syn keyword postscrConstant contained bracketrightbt bracerighttp bracerightmid bracerightbt
282
283" ISO Latin1 encoding names
284 syn keyword postscrConstant contained brokenbar copyright registered twosuperior threesuperior
285 syn keyword postscrConstant contained onesuperior onequarter onehalf threequarters
286 syn keyword postscrConstant contained Agrave Aacute Acircumflex Atilde Adieresis Aring Ccedilla Egrave
287 syn keyword postscrConstant contained Eacute Ecircumflex Edieresis Igrave Iacute Icircumflex Idieresis
288 syn keyword postscrConstant contained Eth Ntilde Ograve Oacute Ocircumflex Otilde Odieresis Ugrave Uacute
289 syn keyword postscrConstant contained Ucircumflex Udieresis Yacute Thorn
290 syn keyword postscrConstant contained agrave aacute acircumflex atilde adieresis aring ccedilla egrave
291 syn keyword postscrConstant contained eacute ecircumflex edieresis igrave iacute icircumflex idieresis
292 syn keyword postscrConstant contained eth ntilde ograve oacute ocircumflex otilde odieresis ugrave uacute
293 syn keyword postscrConstant contained ucircumflex udieresis yacute thorn ydieresis
294 syn keyword postscrConstant contained zcaron exclamsmall Hungarumlautsmall dollaroldstyle dollarsuperior
295 syn keyword postscrConstant contained ampersandsmall Acutesmall parenleftsuperior parenrightsuperior
296 syn keyword postscrConstant contained twodotenleader onedotenleader zerooldstyle oneoldstyle twooldstyle
297 syn keyword postscrConstant contained threeoldstyle fouroldstyle fiveoldstyle sixoldstyle sevenoldstyle
298 syn keyword postscrConstant contained eightoldstyle nineoldstyle commasuperior
299 syn keyword postscrConstant contained threequartersemdash periodsuperior questionsmall asuperior bsuperior
300 syn keyword postscrConstant contained centsuperior dsuperior esuperior isuperior lsuperior msuperior
301 syn keyword postscrConstant contained nsuperior osuperior rsuperior ssuperior tsuperior ff ffi ffl
302 syn keyword postscrConstant contained parenleftinferior parenrightinferior Circumflexsmall hyphensuperior
303 syn keyword postscrConstant contained Gravesmall Asmall Bsmall Csmall Dsmall Esmall Fsmall Gsmall Hsmall
304 syn keyword postscrConstant contained Ismall Jsmall Ksmall Lsmall Msmall Nsmall Osmall Psmall Qsmall
305 syn keyword postscrConstant contained Rsmall Ssmall Tsmall Usmall Vsmall Wsmall Xsmall Ysmall Zsmall
306 syn keyword postscrConstant contained colonmonetary onefitted rupiah Tildesmall exclamdownsmall
307 syn keyword postscrConstant contained centoldstyle Lslashsmall Scaronsmall Zcaronsmall Dieresissmall
308 syn keyword postscrConstant contained Brevesmall Caronsmall Dotaccentsmall Macronsmall figuredash
309 syn keyword postscrConstant contained hypheninferior Ogoneksmall Ringsmall Cedillasmall questiondownsmall
310 syn keyword postscrConstant contained oneeighth threeeighths fiveeighths seveneighths onethird twothirds
311 syn keyword postscrConstant contained zerosuperior foursuperior fivesuperior sixsuperior sevensuperior
312 syn keyword postscrConstant contained eightsuperior ninesuperior zeroinferior oneinferior twoinferior
313 syn keyword postscrConstant contained threeinferior fourinferior fiveinferior sixinferior seveninferior
314 syn keyword postscrConstant contained eightinferior nineinferior centinferior dollarinferior periodinferior
315 syn keyword postscrConstant contained commainferior Agravesmall Aacutesmall Acircumflexsmall
316 syn keyword postscrConstant contained Atildesmall Adieresissmall Aringsmall AEsmall Ccedillasmall
317 syn keyword postscrConstant contained Egravesmall Eacutesmall Ecircumflexsmall Edieresissmall Igravesmall
318 syn keyword postscrConstant contained Iacutesmall Icircumflexsmall Idieresissmall Ethsmall Ntildesmall
319 syn keyword postscrConstant contained Ogravesmall Oacutesmall Ocircumflexsmall Otildesmall Odieresissmall
320 syn keyword postscrConstant contained OEsmall Oslashsmall Ugravesmall Uacutesmall Ucircumflexsmall
321 syn keyword postscrConstant contained Udieresissmall Yacutesmall Thornsmall Ydieresissmall Black Bold Book
322 syn keyword postscrConstant contained Light Medium Regular Roman Semibold
323
324" Sundry standard and expert encoding names
325 syn keyword postscrConstant contained trademark Scaron Ydieresis Zcaron scaron softhyphen overscore
326 syn keyword postscrConstant contained graybox Sacute Tcaron Zacute sacute tcaron zacute Aogonek Scedilla
327 syn keyword postscrConstant contained Zdotaccent aogonek scedilla Lcaron lcaron zdotaccent Racute Abreve
328 syn keyword postscrConstant contained Lacute Cacute Ccaron Eogonek Ecaron Dcaron Dcroat Nacute Ncaron
329 syn keyword postscrConstant contained Ohungarumlaut Rcaron Uring Uhungarumlaut Tcommaaccent racute abreve
330 syn keyword postscrConstant contained lacute cacute ccaron eogonek ecaron dcaron dcroat nacute ncaron
331 syn keyword postscrConstant contained ohungarumlaut rcaron uring uhungarumlaut tcommaaccent Gbreve
332 syn keyword postscrConstant contained Idotaccent gbreve blank apple
333endif
334
335
336" By default level 3 includes all level 2 operators
337if postscr_level == 2 || postscr_level == 3
338" Dictionary operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000339 syn match postscrL2Operator "\(<<\|>>\)"
340 syn keyword postscrL2Operator undef
Bram Moolenaar071d4272004-06-13 20:20:40 +0000341 syn keyword postscrConstant globaldict shareddict
342
343" Device operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000344 syn keyword postscrL2Operator setpagedevice currentpagedevice
Bram Moolenaar071d4272004-06-13 20:20:40 +0000345
346" Path operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000347 syn keyword postscrL2Operator rectclip setbbox uappend ucache upath ustrokepath arct
Bram Moolenaar071d4272004-06-13 20:20:40 +0000348
349" Painting operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000350 syn keyword postscrL2Operator rectfill rectstroke ufill ueofill ustroke
Bram Moolenaar071d4272004-06-13 20:20:40 +0000351
352" Array operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000353 syn keyword postscrL2Operator currentpacking setpacking packedarray
Bram Moolenaar071d4272004-06-13 20:20:40 +0000354
355" Misc operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000356 syn keyword postscrL2Operator languagelevel
Bram Moolenaar071d4272004-06-13 20:20:40 +0000357
358" Insideness operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000359 syn keyword postscrL2Operator infill ineofill instroke inufill inueofill inustroke
Bram Moolenaar071d4272004-06-13 20:20:40 +0000360
361" GState operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000362 syn keyword postscrL2Operator gstate setgstate currentgstate setcolor
363 syn keyword postscrL2Operator setcolorspace currentcolorspace setstrokeadjust currentstrokeadjust
364 syn keyword postscrL2Operator currentcolor
Bram Moolenaar071d4272004-06-13 20:20:40 +0000365
366" Device gstate operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000367 syn keyword postscrL2Operator sethalftone currenthalftone setoverprint currentoverprint
368 syn keyword postscrL2Operator setcolorrendering currentcolorrendering
Bram Moolenaar071d4272004-06-13 20:20:40 +0000369
370" Character operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000371 syn keyword postscrL2Constant GlobalFontDirectory SharedFontDirectory
372 syn keyword postscrL2Operator glyphshow selectfont
373 syn keyword postscrL2Operator addglyph undefinefont xshow xyshow yshow
Bram Moolenaar071d4272004-06-13 20:20:40 +0000374
375" Pattern operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000376 syn keyword postscrL2Operator makepattern setpattern execform
Bram Moolenaar071d4272004-06-13 20:20:40 +0000377
378" Resource operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000379 syn keyword postscrL2Operator defineresource undefineresource findresource resourcestatus
380 syn keyword postscrL2Repeat resourceforall
Bram Moolenaar071d4272004-06-13 20:20:40 +0000381
382" File operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000383 syn keyword postscrL2Operator filter printobject writeobject setobjectformat currentobjectformat
Bram Moolenaar071d4272004-06-13 20:20:40 +0000384
385" VM operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000386 syn keyword postscrL2Operator currentshared setshared defineuserobject execuserobject undefineuserobject
387 syn keyword postscrL2Operator gcheck scheck startjob currentglobal setglobal
Bram Moolenaar071d4272004-06-13 20:20:40 +0000388 syn keyword postscrConstant UserObjects
389
390" Interpreter operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000391 syn keyword postscrL2Operator setucacheparams setvmthreshold ucachestatus setsystemparams
392 syn keyword postscrL2Operator setuserparams currentuserparams setcacheparams currentcacheparams
393 syn keyword postscrL2Operator currentdevparams setdevparams vmreclaim currentsystemparams
Bram Moolenaar071d4272004-06-13 20:20:40 +0000394
395" PS2 constants
396 syn keyword postscrConstant contained DeviceCMYK Pattern Indexed Separation Cyan Magenta Yellow Black
397 syn keyword postscrConstant contained CIEBasedA CIEBasedABC CIEBasedDEF CIEBasedDEFG
398
399" PS2 $error dictionary entries
400 syn keyword postscrConstant contained newerror errorname command errorinfo ostack estack dstack
401 syn keyword postscrConstant contained recordstacks binary
402
403" PS2 Category dictionary
404 syn keyword postscrConstant contained DefineResource UndefineResource FindResource ResourceStatus
405 syn keyword postscrConstant contained ResourceForAll Category InstanceType ResourceFileName
406
407" PS2 Category names
408 syn keyword postscrConstant contained Font Encoding Form Pattern ProcSet ColorSpace Halftone
409 syn keyword postscrConstant contained ColorRendering Filter ColorSpaceFamily Emulator IODevice
410 syn keyword postscrConstant contained ColorRenderingType FMapType FontType FormType HalftoneType
411 syn keyword postscrConstant contained ImageType PatternType Category Generic
412
413" PS2 pagedevice dictionary entries
414 syn keyword postscrConstant contained PageSize MediaColor MediaWeight MediaType InputAttributes ManualFeed
415 syn keyword postscrConstant contained OutputType OutputAttributes NumCopies Collate Duplex Tumble
416 syn keyword postscrConstant contained Separations HWResolution Margins NegativePrint MirrorPrint
417 syn keyword postscrConstant contained CutMedia AdvanceMedia AdvanceDistance ImagingBBox
418 syn keyword postscrConstant contained Policies Install BeginPage EndPage PolicyNotFound PolicyReport
419 syn keyword postscrConstant contained ManualSize OutputFaceUp Jog
420 syn keyword postscrConstant contained Bind BindDetails Booklet BookletDetails CollateDetails
421 syn keyword postscrConstant contained DeviceRenderingInfo ExitJamRecovery Fold FoldDetails Laminate
422 syn keyword postscrConstant contained ManualFeedTimeout Orientation OutputPage
423 syn keyword postscrConstant contained PostRenderingEnhance PostRenderingEnhanceDetails
424 syn keyword postscrConstant contained PreRenderingEnhance PreRenderingEnhanceDetails
425 syn keyword postscrConstant contained Signature SlipSheet Staple StapleDetails Trim
426 syn keyword postscrConstant contained ProofSet REValue PrintQuality ValuesPerColorComponent AntiAlias
427
428" PS2 PDL resource entries
429 syn keyword postscrConstant contained Selector LanguageFamily LanguageVersion
430
431" PS2 halftone dictionary entries
432 syn keyword postscrConstant contained HalftoneType HalftoneName
433 syn keyword postscrConstant contained AccurateScreens ActualAngle Xsquare Ysquare AccurateFrequency
434 syn keyword postscrConstant contained Frequency SpotFunction Angle Width Height Thresholds
435 syn keyword postscrConstant contained RedFrequency RedSpotFunction RedAngle RedWidth RedHeight
436 syn keyword postscrConstant contained GreenFrequency GreenSpotFunction GreenAngle GreenWidth GreenHeight
437 syn keyword postscrConstant contained BlueFrequency BlueSpotFunction BlueAngle BlueWidth BlueHeight
438 syn keyword postscrConstant contained GrayFrequency GrayAngle GraySpotFunction GrayWidth GrayHeight
439 syn keyword postscrConstant contained GrayThresholds BlueThresholds GreenThresholds RedThresholds
440 syn keyword postscrConstant contained TransferFunction
441
442" PS2 CSR dictionaries
443 syn keyword postscrConstant contained RangeA DecodeA MatrixA RangeABC DecodeABC MatrixABC BlackPoint
444 syn keyword postscrConstant contained RangeLMN DecodeLMN MatrixLMN WhitePoint RangeDEF DecodeDEF RangeHIJ
445 syn keyword postscrConstant contained RangeDEFG DecodeDEFG RangeHIJK Table
446
447" PS2 CRD dictionaries
448 syn keyword postscrConstant contained ColorRenderingType EncodeLMB EncodeABC RangePQR MatrixPQR
449 syn keyword postscrConstant contained AbsoluteColorimetric RelativeColorimetric Saturation Perceptual
450 syn keyword postscrConstant contained TransformPQR RenderTable
451
452" PS2 Pattern dictionary
453 syn keyword postscrConstant contained PatternType PaintType TilingType XStep YStep
454
455" PS2 Image dictionary
456 syn keyword postscrConstant contained ImageType ImageMatrix MultipleDataSources DataSource
457 syn keyword postscrConstant contained BitsPerComponent Decode Interpolate
458
459" PS2 Font dictionaries
460 syn keyword postscrConstant contained FontType FontMatrix FontName FontInfo LanguageLevel WMode Encoding
461 syn keyword postscrConstant contained UniqueID StrokeWidth Metrics Metrics2 CDevProc CharStrings Private
462 syn keyword postscrConstant contained FullName Notice version ItalicAngle isFixedPitch UnderlinePosition
463 syn keyword postscrConstant contained FMapType Encoding FDepVector PrefEnc EscChar ShiftOut ShiftIn
464 syn keyword postscrConstant contained WeightVector Blend $Blend CIDFontType sfnts CIDSystemInfo CodeMap
465 syn keyword postscrConstant contained CMap CIDFontName CIDSystemInfo UIDBase CIDDevProc CIDCount
466 syn keyword postscrConstant contained CIDMapOffset FDArray FDBytes GDBytes GlyphData GlyphDictionary
467 syn keyword postscrConstant contained SDBytes SubrMapOffset SubrCount BuildGlyph CIDMap FID MIDVector
468 syn keyword postscrConstant contained Ordering Registry Supplement CMapName CMapVersion UIDOffset
469 syn keyword postscrConstant contained SubsVector UnderlineThickness FamilyName FontBBox CurMID
470 syn keyword postscrConstant contained Weight
471
Bram Moolenaar6c391a72021-09-09 21:55:11 +0200472" PS2 User parameters
Bram Moolenaar071d4272004-06-13 20:20:40 +0000473 syn keyword postscrConstant contained MaxFontItem MinFontCompress MaxUPathItem MaxFormItem MaxPatternItem
474 syn keyword postscrConstant contained MaxScreenItem MaxOpStack MaxDictStack MaxExecStack MaxLocalVM
475 syn keyword postscrConstant contained VMReclaim VMThreshold
476
Bram Moolenaar6c391a72021-09-09 21:55:11 +0200477" PS2 System parameters
Bram Moolenaar071d4272004-06-13 20:20:40 +0000478 syn keyword postscrConstant contained SystemParamsPassword StartJobPassword BuildTime ByteOrder RealFormat
479 syn keyword postscrConstant contained MaxFontCache CurFontCache MaxOutlineCache CurOutlineCache
480 syn keyword postscrConstant contained MaxUPathCache CurUPathCache MaxFormCache CurFormCache
481 syn keyword postscrConstant contained MaxPatternCache CurPatternCache MaxScreenStorage CurScreenStorage
482 syn keyword postscrConstant contained MaxDisplayList CurDisplayList
483
484" PS2 LZW Filters
485 syn keyword postscrConstant contained Predictor
486
487" Paper Size operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000488 syn keyword postscrL2Operator letter lettersmall legal ledger 11x17 a4 a3 a4small b5 note
Bram Moolenaar071d4272004-06-13 20:20:40 +0000489
490" Paper Tray operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000491 syn keyword postscrL2Operator lettertray legaltray ledgertray a3tray a4tray b5tray 11x17tray
Bram Moolenaar071d4272004-06-13 20:20:40 +0000492
493" SCC compatibility operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000494 syn keyword postscrL2Operator sccbatch sccinteractive setsccbatch setsccinteractive
Bram Moolenaar071d4272004-06-13 20:20:40 +0000495
496" Page duplexing operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000497 syn keyword postscrL2Operator duplexmode firstside newsheet setduplexmode settumble tumble
Bram Moolenaar071d4272004-06-13 20:20:40 +0000498
Bram Moolenaar6c391a72021-09-09 21:55:11 +0200499" Device compatibility operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000500 syn keyword postscrL2Operator devdismount devformat devmount devstatus
501 syn keyword postscrL2Repeat devforall
Bram Moolenaar071d4272004-06-13 20:20:40 +0000502
Bram Moolenaar6c391a72021-09-09 21:55:11 +0200503" Imagesetter compatibility operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000504 syn keyword postscrL2Operator accuratescreens checkscreen pagemargin pageparams setaccuratescreens setpage
505 syn keyword postscrL2Operator setpagemargin setpageparams
Bram Moolenaar071d4272004-06-13 20:20:40 +0000506
Bram Moolenaar6c391a72021-09-09 21:55:11 +0200507" Misc compatibility operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000508 syn keyword postscrL2Operator appletalktype buildtime byteorder checkpassword defaulttimeouts diskonline
509 syn keyword postscrL2Operator diskstatus manualfeed manualfeedtimeout margins mirrorprint pagecount
510 syn keyword postscrL2Operator pagestackorder printername processcolors sethardwareiomode setjobtimeout
511 syn keyword postscrL2Operator setpagestockorder setprintername setresolution doprinterrors dostartpage
512 syn keyword postscrL2Operator hardwareiomode initializedisk jobname jobtimeout ramsize realformat resolution
513 syn keyword postscrL2Operator setdefaulttimeouts setdoprinterrors setdostartpage setdosysstart
514 syn keyword postscrL2Operator setuserdiskpercent softwareiomode userdiskpercent waittimeout
515 syn keyword postscrL2Operator setsoftwareiomode dosysstart emulate setmargins setmirrorprint
Bram Moolenaar071d4272004-06-13 20:20:40 +0000516
517endif " PS2 highlighting
518
519if postscr_level == 3
520" Shading operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000521 syn keyword postscrL3Operator setsmoothness currentsmoothness shfill
Bram Moolenaar071d4272004-06-13 20:20:40 +0000522
523" Clip operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000524 syn keyword postscrL3Operator clipsave cliprestore
Bram Moolenaar071d4272004-06-13 20:20:40 +0000525
526" Pagedevive operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000527 syn keyword postscrL3Operator setpage setpageparams
Bram Moolenaar071d4272004-06-13 20:20:40 +0000528
529" Device gstate operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000530 syn keyword postscrL3Operator findcolorrendering
Bram Moolenaar071d4272004-06-13 20:20:40 +0000531
532" Font operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000533 syn keyword postscrL3Operator composefont
Bram Moolenaar071d4272004-06-13 20:20:40 +0000534
535" PS LL3 Output device resource entries
536 syn keyword postscrConstant contained DeviceN TrappingDetailsType
537
538" PS LL3 pagdevice dictionary entries
539 syn keyword postscrConstant contained DeferredMediaSelection ImageShift InsertSheet LeadingEdge MaxSeparations
540 syn keyword postscrConstant contained MediaClass MediaPosition OutputDevice PageDeviceName PageOffset ProcessColorModel
541 syn keyword postscrConstant contained RollFedMedia SeparationColorNames SeparationOrder Trapping TrappingDetails
542 syn keyword postscrConstant contained TraySwitch UseCIEColor
543 syn keyword postscrConstant contained ColorantDetails ColorantName ColorantType NeutralDensity TrappingOrder
544 syn keyword postscrConstant contained ColorantSetName
545
546" PS LL3 trapping dictionary entries
547 syn keyword postscrConstant contained BlackColorLimit BlackDensityLimit BlackWidth ColorantZoneDetails
548 syn keyword postscrConstant contained SlidingTrapLimit StepLimit TrapColorScaling TrapSetName TrapWidth
549 syn keyword postscrConstant contained ImageResolution ImageToObjectTrapping ImageTrapPlacement
550 syn keyword postscrConstant contained StepLimit TrapColorScaling Enabled ImageInternalTrapping
551
552" PS LL3 filters and entries
553 syn keyword postscrConstant contained ReusableStreamDecode CloseSource CloseTarget UnitSize LowBitFirst
554 syn keyword postscrConstant contained FlateEncode FlateDecode DecodeParams Intent AsyncRead
555
556" PS LL3 halftone dictionary entries
557 syn keyword postscrConstant contained Height2 Width2
558
559" PS LL3 function dictionary entries
560 syn keyword postscrConstant contained FunctionType Domain Range Order BitsPerSample Encode Size C0 C1 N
561 syn keyword postscrConstant contained Functions Bounds
562
563" PS LL3 image dictionary entries
564 syn keyword postscrConstant contained InterleaveType MaskDict DataDict MaskColor
565
566" PS LL3 Pattern and shading dictionary entries
567 syn keyword postscrConstant contained Shading ShadingType Background ColorSpace Coords Extend Function
568 syn keyword postscrConstant contained VerticesPerRow BitsPerCoordinate BitsPerFlag
569
570" PS LL3 image dictionary entries
571 syn keyword postscrConstant contained XOrigin YOrigin UnpaintedPath PixelCopy
572
573" PS LL3 colorrendering procedures
574 syn keyword postscrProcedure GetHalftoneName GetPageDeviceName GetSubstituteCRD
575
576" PS LL3 CIDInit procedures
577 syn keyword postscrProcedure beginbfchar beginbfrange begincidchar begincidrange begincmap begincodespacerange
578 syn keyword postscrProcedure beginnotdefchar beginnotdefrange beginrearrangedfont beginusematrix
579 syn keyword postscrProcedure endbfchar endbfrange endcidchar endcidrange endcmap endcodespacerange
580 syn keyword postscrProcedure endnotdefchar endnotdefrange endrearrangedfont endusematrix
581 syn keyword postscrProcedure StartData usefont usecmp
582
583" PS LL3 Trapping procedures
584 syn keyword postscrProcedure settrapparams currenttrapparams settrapzone
585
586" PS LL3 BitmapFontInit procedures
587 syn keyword postscrProcedure removeall removeglyphs
588
589" PS LL3 Font names
590 if exists("postscr_fonts")
591 syn keyword postscrConstant contained AlbertusMT AlbertusMT-Italic AlbertusMT-Light Apple-Chancery Apple-ChanceryCE
592 syn keyword postscrConstant contained AntiqueOlive-Roman AntiqueOlive-Italic AntiqueOlive-Bold AntiqueOlive-Compact
593 syn keyword postscrConstant contained AntiqueOliveCE-Roman AntiqueOliveCE-Italic AntiqueOliveCE-Bold AntiqueOliveCE-Compact
594 syn keyword postscrConstant contained ArialMT Arial-ItalicMT Arial-LightMT Arial-BoldMT Arial-BoldItalicMT
595 syn keyword postscrConstant contained ArialCE ArialCE-Italic ArialCE-Light ArialCE-Bold ArialCE-BoldItalic
596 syn keyword postscrConstant contained AvantGarde-Book AvantGarde-BookOblique AvantGarde-Demi AvantGarde-DemiOblique
597 syn keyword postscrConstant contained AvantGardeCE-Book AvantGardeCE-BookOblique AvantGardeCE-Demi AvantGardeCE-DemiOblique
598 syn keyword postscrConstant contained Bodoni Bodoni-Italic Bodoni-Bold Bodoni-BoldItalic Bodoni-Poster Bodoni-PosterCompressed
599 syn keyword postscrConstant contained BodoniCE BodoniCE-Italic BodoniCE-Bold BodoniCE-BoldItalic BodoniCE-Poster BodoniCE-PosterCompressed
600 syn keyword postscrConstant contained Bookman-Light Bookman-LightItalic Bookman-Demi Bookman-DemiItalic
601 syn keyword postscrConstant contained BookmanCE-Light BookmanCE-LightItalic BookmanCE-Demi BookmanCE-DemiItalic
602 syn keyword postscrConstant contained Carta Chicago ChicagoCE Clarendon Clarendon-Light Clarendon-Bold
603 syn keyword postscrConstant contained ClarendonCE ClarendonCE-Light ClarendonCE-Bold CooperBlack CooperBlack-Italic
604 syn keyword postscrConstant contained Copperplate-ThirtyTwoBC CopperPlate-ThirtyThreeBC Coronet-Regular CoronetCE-Regular
605 syn keyword postscrConstant contained CourierCE CourierCE-Oblique CourierCE-Bold CourierCE-BoldOblique
606 syn keyword postscrConstant contained Eurostile Eurostile-Bold Eurostile-ExtendedTwo Eurostile-BoldExtendedTwo
607 syn keyword postscrConstant contained Eurostile EurostileCE-Bold EurostileCE-ExtendedTwo EurostileCE-BoldExtendedTwo
608 syn keyword postscrConstant contained Geneva GenevaCE GillSans GillSans-Italic GillSans-Bold GillSans-BoldItalic GillSans-BoldCondensed
609 syn keyword postscrConstant contained GillSans-Light GillSans-LightItalic GillSans-ExtraBold
610 syn keyword postscrConstant contained GillSansCE-Roman GillSansCE-Italic GillSansCE-Bold GillSansCE-BoldItalic GillSansCE-BoldCondensed
611 syn keyword postscrConstant contained GillSansCE-Light GillSansCE-LightItalic GillSansCE-ExtraBold
612 syn keyword postscrConstant contained Goudy Goudy-Italic Goudy-Bold Goudy-BoldItalic Goudy-ExtraBould
613 syn keyword postscrConstant contained HelveticaCE HelveticaCE-Oblique HelveticaCE-Bold HelveticaCE-BoldOblique
614 syn keyword postscrConstant contained Helvetica-Condensed Helvetica-Condensed-Oblique Helvetica-Condensed-Bold Helvetica-Condensed-BoldObl
615 syn keyword postscrConstant contained HelveticaCE-Condensed HelveticaCE-Condensed-Oblique HelveticaCE-Condensed-Bold
616 syn keyword postscrConstant contained HelveticaCE-Condensed-BoldObl Helvetica-Narrow Helvetica-Narrow-Oblique Helvetica-Narrow-Bold
617 syn keyword postscrConstant contained Helvetica-Narrow-BoldOblique HelveticaCE-Narrow HelveticaCE-Narrow-Oblique HelveticaCE-Narrow-Bold
618 syn keyword postscrConstant contained HelveticaCE-Narrow-BoldOblique HoeflerText-Regular HoeflerText-Italic HoeflerText-Black
619 syn keyword postscrConstant contained HoeflerText-BlackItalic HoeflerText-Ornaments HoeflerTextCE-Regular HoeflerTextCE-Italic
620 syn keyword postscrConstant contained HoeflerTextCE-Black HoeflerTextCE-BlackItalic
621 syn keyword postscrConstant contained JoannaMT JoannaMT-Italic JoannaMT-Bold JoannaMT-BoldItalic
622 syn keyword postscrConstant contained JoannaMTCE JoannaMTCE-Italic JoannaMTCE-Bold JoannaMTCE-BoldItalic
623 syn keyword postscrConstant contained LetterGothic LetterGothic-Slanted LetterGothic-Bold LetterGothic-BoldSlanted
624 syn keyword postscrConstant contained LetterGothicCE LetterGothicCE-Slanted LetterGothicCE-Bold LetterGothicCE-BoldSlanted
625 syn keyword postscrConstant contained LubalinGraph-Book LubalinGraph-BookOblique LubalinGraph-Demi LubalinGraph-DemiOblique
626 syn keyword postscrConstant contained LubalinGraphCE-Book LubalinGraphCE-BookOblique LubalinGraphCE-Demi LubalinGraphCE-DemiOblique
627 syn keyword postscrConstant contained Marigold Monaco MonacoCE MonaLisa-Recut Oxford Symbol Tekton
628 syn keyword postscrConstant contained NewCennturySchlbk-Roman NewCenturySchlbk-Italic NewCenturySchlbk-Bold NewCenturySchlbk-BoldItalic
629 syn keyword postscrConstant contained NewCenturySchlbkCE-Roman NewCenturySchlbkCE-Italic NewCenturySchlbkCE-Bold
630 syn keyword postscrConstant contained NewCenturySchlbkCE-BoldItalic NewYork NewYorkCE
631 syn keyword postscrConstant contained Optima Optima-Italic Optima-Bold Optima-BoldItalic
632 syn keyword postscrConstant contained OptimaCE OptimaCE-Italic OptimaCE-Bold OptimaCE-BoldItalic
633 syn keyword postscrConstant contained Palatino-Roman Palatino-Italic Palatino-Bold Palatino-BoldItalic
634 syn keyword postscrConstant contained PalatinoCE-Roman PalatinoCE-Italic PalatinoCE-Bold PalatinoCE-BoldItalic
635 syn keyword postscrConstant contained StempelGaramond-Roman StempelGaramond-Italic StempelGaramond-Bold StempelGaramond-BoldItalic
636 syn keyword postscrConstant contained StempelGaramondCE-Roman StempelGaramondCE-Italic StempelGaramondCE-Bold StempelGaramondCE-BoldItalic
637 syn keyword postscrConstant contained TimesCE-Roman TimesCE-Italic TimesCE-Bold TimesCE-BoldItalic
638 syn keyword postscrConstant contained TimesNewRomanPSMT TimesNewRomanPS-ItalicMT TimesNewRomanPS-BoldMT TimesNewRomanPS-BoldItalicMT
639 syn keyword postscrConstant contained TimesNewRomanCE TimesNewRomanCE-Italic TimesNewRomanCE-Bold TimesNewRomanCE-BoldItalic
640 syn keyword postscrConstant contained Univers Univers-Oblique Univers-Bold Univers-BoldOblique
641 syn keyword postscrConstant contained UniversCE-Medium UniversCE-Oblique UniversCE-Bold UniversCE-BoldOblique
642 syn keyword postscrConstant contained Univers-Light Univers-LightOblique UniversCE-Light UniversCE-LightOblique
643 syn keyword postscrConstant contained Univers-Condensed Univers-CondensedOblique Univers-CondensedBold Univers-CondensedBoldOblique
644 syn keyword postscrConstant contained UniversCE-Condensed UniversCE-CondensedOblique UniversCE-CondensedBold UniversCE-CondensedBoldOblique
645 syn keyword postscrConstant contained Univers-Extended Univers-ExtendedObl Univers-BoldExt Univers-BoldExtObl
646 syn keyword postscrConstant contained UniversCE-Extended UniversCE-ExtendedObl UniversCE-BoldExt UniversCE-BoldExtObl
647 syn keyword postscrConstant contained Wingdings-Regular ZapfChancery-MediumItalic ZapfChanceryCE-MediumItalic ZapfDingBats
648 endif " Font names
649
650endif " PS LL3 highlighting
651
652
653if exists("postscr_ghostscript")
654 " GS gstate operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000655 syn keyword postscrGSOperator .setaccuratecurves .currentaccuratecurves .setclipoutside
656 syn keyword postscrGSOperator .setdashadapt .currentdashadapt .setdefaultmatrix .setdotlength
657 syn keyword postscrGSOperator .currentdotlength .setfilladjust2 .currentfilladjust2
658 syn keyword postscrGSOperator .currentclipoutside .setcurvejoin .currentcurvejoin
659 syn keyword postscrGSOperator .setblendmode .currentblendmode .setopacityalpha .currentopacityalpha .setshapealpha .currentshapealpha
660 syn keyword postscrGSOperator .setlimitclamp .currentlimitclamp .setoverprintmode .currentoverprintmode
Bram Moolenaar071d4272004-06-13 20:20:40 +0000661
662 " GS path operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000663 syn keyword postscrGSOperator .dashpath .rectappend
Bram Moolenaar071d4272004-06-13 20:20:40 +0000664
665 " GS painting operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000666 syn keyword postscrGSOperator .setrasterop .currentrasterop .setsourcetransparent
667 syn keyword postscrGSOperator .settexturetransparent .currenttexturetransparent
668 syn keyword postscrGSOperator .currentsourcetransparent
Bram Moolenaar071d4272004-06-13 20:20:40 +0000669
670 " GS character operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000671 syn keyword postscrGSOperator .charboxpath .type1execchar %Type1BuildChar %Type1BuildGlyph
Bram Moolenaar071d4272004-06-13 20:20:40 +0000672
673 " GS mathematical operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000674 syn keyword postscrGSMathOperator arccos arcsin
Bram Moolenaar071d4272004-06-13 20:20:40 +0000675
676 " GS dictionary operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000677 syn keyword postscrGSOperator .dicttomark .forceput .forceundef .knownget .setmaxlength
Bram Moolenaar071d4272004-06-13 20:20:40 +0000678
679 " GS byte and string operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000680 syn keyword postscrGSOperator .type1encrypt .type1decrypt
681 syn keyword postscrGSOperator .bytestring .namestring .stringmatch
Bram Moolenaar071d4272004-06-13 20:20:40 +0000682
683 " GS relational operators (seem like math ones to me!)
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000684 syn keyword postscrGSMathOperator max min
Bram Moolenaar071d4272004-06-13 20:20:40 +0000685
686 " GS file operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000687 syn keyword postscrGSOperator findlibfile unread writeppmfile
688 syn keyword postscrGSOperator .filename .fileposition .peekstring .unread
Bram Moolenaar071d4272004-06-13 20:20:40 +0000689
690 " GS vm operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000691 syn keyword postscrGSOperator .forgetsave
Bram Moolenaar071d4272004-06-13 20:20:40 +0000692
693 " GS device operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000694 syn keyword postscrGSOperator copydevice .getdevice makeimagedevice makewordimagedevice copyscanlines
695 syn keyword postscrGSOperator setdevice currentdevice getdeviceprops putdeviceprops flushpage
696 syn keyword postscrGSOperator finddevice findprotodevice .getbitsrect
Bram Moolenaar071d4272004-06-13 20:20:40 +0000697
698 " GS misc operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000699 syn keyword postscrGSOperator getenv .makeoperator .setdebug .oserrno .oserror .execn
Bram Moolenaar071d4272004-06-13 20:20:40 +0000700
701 " GS rendering stack operators
Bram Moolenaarc1a11ed2008-06-24 22:09:24 +0000702 syn keyword postscrGSOperator .begintransparencygroup .discardtransparencygroup .endtransparencygroup
703 syn keyword postscrGSOperator .begintransparencymask .discardtransparencymask .endtransparencymask .inittransparencymask
704 syn keyword postscrGSOperator .settextknockout .currenttextknockout
Bram Moolenaar071d4272004-06-13 20:20:40 +0000705
706 " GS filters
707 syn keyword postscrConstant contained BCPEncode BCPDecode eexecEncode eexecDecode PCXDecode
708 syn keyword postscrConstant contained PixelDifferenceEncode PixelDifferenceDecode
709 syn keyword postscrConstant contained PNGPredictorDecode TBCPEncode TBCPDecode zlibEncode
710 syn keyword postscrConstant contained zlibDecode PNGPredictorEncode PFBDecode
711 syn keyword postscrConstant contained MD5Encode
712
713 " GS filter keys
714 syn keyword postscrConstant contained InitialCodeLength FirstBitLowOrder BlockData DecodedByteAlign
715
716 " GS device parameters
717 syn keyword postscrConstant contained BitsPerPixel .HWMargins HWSize Name GrayValues
718 syn keyword postscrConstant contained ColorValues TextAlphaBits GraphicsAlphaBits BufferSpace
719 syn keyword postscrConstant contained OpenOutputFile PageCount BandHeight BandWidth BandBufferSpace
720 syn keyword postscrConstant contained ViewerPreProcess GreenValues BlueValues OutputFile
721 syn keyword postscrConstant contained MaxBitmap RedValues
722
723endif " GhostScript highlighting
724
725" Define the default highlighting.
Bram Moolenaar89bcfda2016-08-30 23:26:57 +0200726" Only when an item doesn't have highlighting yet
Bram Moolenaar071d4272004-06-13 20:20:40 +0000727
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200728hi def link postscrComment Comment
Bram Moolenaar071d4272004-06-13 20:20:40 +0000729
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200730hi def link postscrConstant Constant
731hi def link postscrString String
732hi def link postscrASCIIString postscrString
733hi def link postscrHexString postscrString
734hi def link postscrASCII85String postscrString
735hi def link postscrNumber Number
736hi def link postscrInteger postscrNumber
737hi def link postscrHex postscrNumber
738hi def link postscrRadix postscrNumber
739hi def link postscrFloat Float
740hi def link postscrBoolean Boolean
Bram Moolenaar071d4272004-06-13 20:20:40 +0000741
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200742hi def link postscrIdentifier Identifier
743hi def link postscrProcedure Function
Bram Moolenaar071d4272004-06-13 20:20:40 +0000744
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200745hi def link postscrName Statement
746hi def link postscrConditional Conditional
747hi def link postscrRepeat Repeat
748hi def link postscrL2Repeat postscrRepeat
749hi def link postscrOperator Operator
750hi def link postscrL1Operator postscrOperator
751hi def link postscrL2Operator postscrOperator
752hi def link postscrL3Operator postscrOperator
753hi def link postscrMathOperator postscrOperator
754hi def link postscrLogicalOperator postscrOperator
755hi def link postscrBinaryOperator postscrOperator
Bram Moolenaar071d4272004-06-13 20:20:40 +0000756
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200757hi def link postscrDSCComment SpecialComment
758hi def link postscrSpecialChar SpecialChar
Bram Moolenaar071d4272004-06-13 20:20:40 +0000759
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200760hi def link postscrTodo Todo
Bram Moolenaar071d4272004-06-13 20:20:40 +0000761
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200762hi def link postscrError Error
763hi def link postscrSpecialCharError postscrError
764hi def link postscrASCII85CharError postscrError
765hi def link postscrHexCharError postscrError
766hi def link postscrASCIIStringError postscrError
767hi def link postscrIdentifierError postscrError
Bram Moolenaar071d4272004-06-13 20:20:40 +0000768
Bram Moolenaar89bcfda2016-08-30 23:26:57 +0200769if exists("postscr_ghostscript")
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200770hi def link postscrGSOperator postscrOperator
771hi def link postscrGSMathOperator postscrMathOperator
Bram Moolenaar89bcfda2016-08-30 23:26:57 +0200772else
Bram Moolenaarf37506f2016-08-31 22:22:10 +0200773hi def link postscrGSOperator postscrError
774hi def link postscrGSMathOperator postscrError
Bram Moolenaar071d4272004-06-13 20:20:40 +0000775endif
776
Bram Moolenaar89bcfda2016-08-30 23:26:57 +0200777
Bram Moolenaar071d4272004-06-13 20:20:40 +0000778let b:current_syntax = "postscr"
779
780" vim: ts=8