History

initial import

phil9 committed 5 years ago

Commit dd360bcNo parent (first commit)1336 files · +557163 −-5Browse files

Showing the changes to lib/vimfiles/syntax/gnuplot.vim (1 of 1336 files). Show all

Unified · Split

lib/vimfiles/syntax/gnuplot.vim+198−0
@@ -0,0 +1,198 @@
1+" Vim syntax file
2+" Language: gnuplot 3.8i.0
3+" Maintainer: John Hoelzel johnh51@users.sourceforge.net
4+" Last Change: Mon May 26 02:33:33 UTC 2003
5+" Filenames: *.gpi *.gih scripts: #!*gnuplot
6+" URL: http://johnh51.get.to/vim/syntax/gnuplot.vim
7+"
8+
9+" thanks to "David Necas (Yeti)" <yeti@physics.muni.cz> for heads up - working on more changes .
10+" *.gpi = GnuPlot Input - what I use because there is no other guideline. jeh 11/2000
11+" *.gih = makes using cut/pasting from gnuplot.gih easier ...
12+" #!*gnuplot = for Linux bash shell scripts of gnuplot commands.
13+" emacs used a suffix of '<gp?>'
14+" gnuplot demo files show no preference.
15+" I will post mail and newsgroup comments on a standard suffix in 'URL' directory.
16+
17+" For version 5.x: Clear all syntax items
18+" For version 6.x: Quit when a syntax file was already loaded
19+if version < 600
20+ syntax clear
21+elseif exists("b:current_syntax")
22+ finish
23+endif
24+
25+" some shortened names to make demo files look clean... jeh. 11/2000
26+" demos -> 3.8i ... jeh. 5/2003 - a work in progress...
27+
28+" commands
29+
30+syn keyword gnuplotStatement cd call clear exit set unset plot splot help
31+syn keyword gnuplotStatement load pause quit fit rep[lot] if
32+syn keyword gnuplotStatement FIT_LIMIT FIT_MAXITER FIT_START_LAMBDA
33+syn keyword gnuplotStatement FIT_LAMBDA_FACTOR FIT_LOG FIT_SCRIPT
34+syn keyword gnuplotStatement print pwd reread reset save show test ! functions var
35+syn keyword gnuplotConditional if
36+" if is cond + stmt - ok?
37+
38+" numbers fm c.vim
39+
40+" integer number, or floating point number without a dot and with "f".
41+syn case ignore
42+syn match gnuplotNumber "\<[0-9]\+\(u\=l\=\|lu\|f\)\>"
43+" floating point number, with dot, optional exponent
44+syn match gnuplotFloat "\<[0-9]\+\.[0-9]*\(e[-+]\=[0-9]\+\)\=[fl]\=\>"
45+" floating point number, starting with a dot, optional exponent
46+syn match gnuplotFloat "\.[0-9]\+\(e[-+]\=[0-9]\+\)\=[fl]\=\>"
47+" floating point number, without dot, with exponent
48+syn match gnuplotFloat "\<[0-9]\+e[-+]\=[0-9]\+[fl]\=\>"
49+" hex number
50+syn match gnuplotNumber "\<0x[0-9a-f]\+\(u\=l\=\|lu\)\>"
51+syn case match
52+" flag an octal number with wrong digits by not hilighting
53+syn match gnuplotOctalError "\<0[0-7]*[89]"
54+
55+" plot args
56+
57+syn keyword gnuplotType u[sing] tit[le] notit[le] wi[th] steps fs[teps]
58+syn keyword gnuplotType title notitle t
59+syn keyword gnuplotType with w
60+syn keyword gnuplotType li[nes] l
61+" t - too much? w - too much? l - too much?
62+syn keyword gnuplotType linespoints via
63+
64+" funcs
65+
66+syn keyword gnuplotFunc abs acos acosh arg asin asinh atan atanh atan2
67+syn keyword gnuplotFunc besj0 besj1 besy0 besy1
68+syn keyword gnuplotFunc ceil column cos cosh erf erfc exp floor gamma
69+syn keyword gnuplotFunc ibeta inverf igamma imag invnorm int lgamma
70+syn keyword gnuplotFunc log log10 norm rand real sgn sin sinh sqrt tan
71+syn keyword gnuplotFunc lambertw
72+syn keyword gnuplotFunc tanh valid
73+syn keyword gnuplotFunc tm_hour tm_mday tm_min tm_mon tm_sec
74+syn keyword gnuplotFunc tm_wday tm_yday tm_year
75+
76+" set vars
77+
78+syn keyword gnuplotType xdata timefmt grid noytics ytics fs
79+syn keyword gnuplotType logscale time notime mxtics nomxtics style mcbtics
80+syn keyword gnuplotType nologscale
81+syn keyword gnuplotType axes x1y2 unique acs[plines]
82+syn keyword gnuplotType size origin multiplot xtics xr[ange] yr[ange] square nosquare ratio noratio
83+syn keyword gnuplotType binary matrix index every thru sm[ooth]
84+syn keyword gnuplotType all angles degrees radians
85+syn keyword gnuplotType arrow noarrow autoscale noautoscale arrowstyle
86+" autoscale args = x y xy z t ymin ... - too much?
87+" needs code to: using title vs autoscale t
88+syn keyword gnuplotType x y z zcb
89+syn keyword gnuplotType linear cubicspline bspline order level[s]
90+syn keyword gnuplotType auto disc[rete] incr[emental] from to head nohead
91+syn keyword gnuplotType graph base both nosurface table out[put] data
92+syn keyword gnuplotType bar border noborder boxwidth
93+syn keyword gnuplotType clabel noclabel clip noclip cntrp[aram]
94+syn keyword gnuplotType contour nocontour
95+syn keyword gnuplotType dgrid3d nodgrid3d dummy encoding format
96+" set encoding args not included - yet.
97+syn keyword gnuplotType function grid nogrid hidden[3d] nohidden[3d] isosample[s] key nokey
98+syn keyword gnuplotType historysize nohistorysize
99+syn keyword gnuplotType defaults offset nooffset trianglepattern undefined noundefined altdiagonal bentover noaltdiagonal nobentover
100+syn keyword gnuplotType left right top bottom outside below samplen spacing width height box nobox linestyle ls linetype lt linewidth lw
101+syn keyword gnuplotType Left Right autotitles noautotitles enhanced noenhanced
102+syn keyword gnuplotType isosamples
103+syn keyword gnuplotType label nolabel logscale nolog[scale] missing center font locale
104+syn keyword gnuplotType mapping margin bmargin lmargin rmargin tmargin spherical cylindrical cartesian
105+syn keyword gnuplotType linestyle nolinestyle linetype lt linewidth lw pointtype pt pointsize ps
106+syn keyword gnuplotType mouse nomouse
107+syn keyword gnuplotType nooffsets data candlesticks financebars linespoints lp vector nosurface
108+syn keyword gnuplotType term[inal] linux aed767 aed512 gpic
109+syn keyword gnuplotType regis tek410x tek40 vttek kc-tek40xx
110+syn keyword gnuplotType km-tek40xx selanar bitgraph xlib x11 X11
111+" x11 args
112+syn keyword gnuplotType aifm cgm dumb fig gif small large size nofontlist winword6 corel dxf emf
113+syn keyword gnuplotType hpgl
114+" syn keyword gnuplotType transparent hp2623a hp2648 hp500c pcl5 why jeh
115+syn keyword gnuplotType hp2623a hp2648 hp500c pcl5
116+syn match gnuplotType "\<transparent\>"
117+syn keyword gnuplotType hpljii hpdj hppj imagen mif pbm png svg
118+syn keyword gnuplotType postscript enhanced_postscript qms table
119+" postscript editing values?
120+syn keyword gnuplotType tgif tkcanvas epson-180dpi epson-60dpi
121+syn keyword gnuplotType epson-lx800 nec-cp6 okidata starc
122+syn keyword gnuplotType tandy-60dpi latex emtex pslatex pstex epslatex
123+syn keyword gnuplotType eepic tpic pstricks texdraw mf metafont mpost mp
124+syn keyword gnuplotType timestamp notimestamp
125+syn keyword gnuplotType variables version
126+syn keyword gnuplotType x2data y2data ydata zdata
127+syn keyword gnuplotType reverse writeback noreverse nowriteback
128+syn keyword gnuplotType axis mirror autofreq nomirror rotate autofreq norotate
129+syn keyword gnuplotType update
130+syn keyword gnuplotType multiplot nomultiplot mytics
131+syn keyword gnuplotType nomytics mztics nomztics mx2tics nomx2tics
132+syn keyword gnuplotType my2tics nomy2tics offsets origin output
133+syn keyword gnuplotType para[metric] nopara[metric] pointsize polar nopolar
134+syn keyword gnuplotType zrange x2range y2range rrange cbrange
135+syn keyword gnuplotType trange urange vrange sample[s] size
136+syn keyword gnuplotType bezier boxerrorbars boxes bargraph bar[s]
137+syn keyword gnuplotType boxxy[errorbars] csplines dots fsteps histeps impulses
138+syn keyword gnuplotType line[s] linesp[oints] points poiinttype sbezier splines steps
139+" w lt lw ls = optional
140+syn keyword gnuplotType vectors xerr[orbars] xyerr[orbars] yerr[orbars] financebars candlesticks vector
141+syn keyword gnuplotType errorb[ars] surface
142+syn keyword gnuplotType filledcurve[s] pm3d x1 x2 y1 y2 xy closed
143+syn keyword gnuplotType at pi front
144+syn keyword gnuplotType errorlines xerrorlines yerrorlines xyerrorlines
145+syn keyword gnuplotType tics ticslevel ticscale time timefmt view
146+syn keyword gnuplotType xdata xdtics noxdtics ydtics noydtics
147+syn keyword gnuplotType zdtics nozdtics x2dtics nox2dtics y2dtics noy2dtics
148+syn keyword gnuplotType xlab[el] ylab[el] zlab[el] cblab[el] x2label y2label xmtics
149+syn keyword gnuplotType xmtics noxmtics ymtics noymtics zmtics nozmtics
150+syn keyword gnuplotType x2mtics nox2mtics y2mtics noy2mtics
151+syn keyword gnuplotType cbdtics nocbdtics cbmtics nocbmtics cbtics nocbtics
152+syn keyword gnuplotType xtics noxtics ytics noytics
153+syn keyword gnuplotType ztics noztics x2tics nox2tics
154+syn keyword gnuplotType y2tics noy2tics zero nozero zeroaxis nozeroaxis
155+syn keyword gnuplotType xzeroaxis noxzeroaxis yzeroaxis noyzeroaxis
156+syn keyword gnuplotType x2zeroaxis nox2zeroaxis y2zeroaxis noy2zeroaxis
157+syn keyword gnuplotType angles one two fill empty solid pattern
158+syn keyword gnuplotType default
159+syn keyword gnuplotType scansautomatic flush b[egin] noftriangles implicit
160+" b too much? - used in demo
161+syn keyword gnuplotType palette positive negative ps_allcF nops_allcF maxcolors
162+syn keyword gnuplotType push fontfile pop
163+syn keyword gnuplotType rgbformulae defined file color model gradient colornames
164+syn keyword gnuplotType RGB HSV CMY YIQ XYZ
165+syn keyword gnuplotType colorbox vertical horizontal user bdefault
166+syn keyword gnuplotType loadpath fontpath decimalsign in out
167+
168+" comments + strings
169+syn region gnuplotComment start="#" end="$"
170+syn region gnuplotComment start=+"+ skip=+\\"+ end=+"+
171+syn region gnuplotComment start=+'+ end=+'+
172+
173+" Define the default highlighting.
174+" For version 5.7 and earlier: only when not done already
175+" For version 5.8 and later: only when an item doesn't have highlighting yet
176+if version >= 508 || !exists("did_gnuplot_syntax_inits")
177+ if version < 508
178+ let did_gnuplot_syntax_inits = 1
179+ command -nargs=+ HiLink hi link <args>
180+ else
181+ command -nargs=+ HiLink hi def link <args>
182+ endif
183+
184+ HiLink gnuplotStatement Statement
185+ HiLink gnuplotConditional Conditional
186+ HiLink gnuplotNumber Number
187+ HiLink gnuplotFloat Float
188+ HiLink gnuplotOctalError Error
189+ HiLink gnuplotFunc Type
190+ HiLink gnuplotType Type
191+ HiLink gnuplotComment Comment
192+
193+ delcommand HiLink
194+endif
195+
196+let b:current_syntax = "gnuplot"
197+
198+" vim: ts=8