From 5b77877888162f4e415fe9a7b8c5e9fb5dfb6ee1 Mon Sep 17 00:00:00 2001 From: Adam Stankiewicz Date: Wed, 27 Sep 2017 20:43:42 +0200 Subject: [PATCH] Add syntax files from upstream vim repository --- README.md | 6 +- autoload/ada.vim | 641 ++ autoload/adacomplete.vim | 113 + autoload/ccomplete.vim | 614 ++ autoload/clojurecomplete.vim | 26 + autoload/context.vim | 188 + autoload/contextcomplete.vim | 29 + autoload/csscomplete.vim | 744 ++ autoload/decada.vim | 79 + autoload/getscript.vim | 671 ++ autoload/gnat.vim | 151 + autoload/gzip.vim | 224 + autoload/htmlcomplete.vim | 812 ++ autoload/javascriptcomplete.vim | 629 ++ autoload/netrw.vim | 12046 ++++++++++++++++++++++++++++++ autoload/netrwFileHandlers.vim | 366 + autoload/netrwSettings.vim | 249 + autoload/netrw_gitignore.vim | 82 + autoload/paste.vim | 39 + autoload/phpcomplete.vim | 2959 ++++++++ autoload/python3complete.vim | 611 ++ autoload/pythoncomplete.vim | 630 ++ autoload/rubycomplete.vim | 837 +++ autoload/rust.vim | 419 ++ autoload/rustfmt.vim | 111 + autoload/spellfile.vim | 213 + autoload/sqlcomplete.vim | 1000 +++ autoload/syntaxcomplete.vim | 759 ++ autoload/tar.vim | 630 ++ autoload/tohtml.vim | 927 +++ autoload/vimball.vim | 779 ++ autoload/xml/html32.vim | 387 + autoload/xml/html401f.vim | 472 ++ autoload/xml/html401s.vim | 414 + autoload/xml/html401t.vim | 464 ++ autoload/xml/html40f.vim | 472 ++ autoload/xml/html40s.vim | 414 + autoload/xml/html40t.vim | 464 ++ autoload/xml/xhtml10f.vim | 473 ++ autoload/xml/xhtml10s.vim | 414 + autoload/xml/xhtml10t.vim | 464 ++ autoload/xml/xhtml11.vim | 438 ++ autoload/xml/xsd.vim | 134 + autoload/xml/xsl.vim | 42 + autoload/xmlcomplete.vim | 543 ++ autoload/zip.vim | 465 ++ build | 2 +- compiler/ant.vim | 42 + compiler/bcc.vim | 23 + compiler/bdf.vim | 26 + compiler/cargo.vim | 39 + compiler/checkstyle.vim | 23 + compiler/context.vim | 58 + compiler/cs.vim | 30 + compiler/csslint.vim | 20 + compiler/cucumber.vim | 33 + compiler/decada.vim | 62 + compiler/dot.vim | 19 + compiler/erlang.vim | 17 + compiler/eruby.vim | 43 + compiler/fortran_F.vim | 31 + compiler/fortran_cv.vim | 34 + compiler/fortran_elf90.vim | 37 + compiler/fortran_g77.vim | 52 + compiler/fortran_lf95.vim | 31 + compiler/fpc.vim | 21 + compiler/g95.vim | 32 + compiler/gcc.vim | 45 + compiler/gfortran.vim | 31 + compiler/ghc.vim | 30 + compiler/gnat.vim | 80 + compiler/go.vim | 33 + compiler/haml.vim | 32 + compiler/hp_acc.vim | 42 + compiler/icc.vim | 22 + compiler/ifort.vim | 31 + compiler/intel.vim | 30 + compiler/irix5_c.vim | 30 + compiler/irix5_cpp.vim | 30 + compiler/javac.vim | 21 + compiler/jikes.vim | 22 + compiler/mcs.vim | 34 + compiler/mips_c.vim | 30 + compiler/mipspro_c89.vim | 31 + compiler/mipspro_cpp.vim | 30 + compiler/modelsim_vcom.vim | 24 + compiler/msbuild.vim | 25 + compiler/msvc.vim | 17 + compiler/neato.vim | 19 + compiler/ocaml.vim | 48 + compiler/onsgmls.vim | 28 + compiler/pbx.vim | 24 + compiler/perl.vim | 51 + compiler/php.vim | 30 + compiler/pylint.vim | 20 + compiler/pyunit.vim | 20 + compiler/rake.vim | 43 + compiler/rspec.vim | 38 + compiler/rst.vim | 36 + compiler/ruby.vim | 49 + compiler/rubyunit.vim | 39 + compiler/rustc.vim | 50 + compiler/sass.vim | 34 + compiler/se.vim | 34 + compiler/splint.vim | 75 + compiler/tcl.vim | 21 + compiler/tex.vim | 71 + compiler/tidy.vim | 23 + compiler/xbuild.vim | 26 + compiler/xmllint.vim | 30 + compiler/xmlwf.vim | 27 + ftdetect/polyglot.vim | 8 +- ftplugin/a2ps.vim | 24 + ftplugin/aap.vim | 29 + ftplugin/abap.vim | 33 + ftplugin/abaqus.vim | 101 + ftplugin/ada.vim | 214 + ftplugin/alsaconf.vim | 23 + ftplugin/ant.vim | 48 + ftplugin/arch.vim | 23 + ftplugin/art.vim | 19 + ftplugin/aspvbs.vim | 64 + ftplugin/automake.vim | 20 + ftplugin/awk.vim | 22 + ftplugin/bdf.vim | 24 + ftplugin/bst.vim | 19 + ftplugin/btm.vim | 16 + ftplugin/bzl.vim | 98 + ftplugin/c.vim | 68 + ftplugin/calendar.vim | 24 + ftplugin/cdrdaoconf.vim | 22 + ftplugin/ch.vim | 21 + ftplugin/changelog.vim | 305 + ftplugin/clojure.vim | 99 + ftplugin/cobol.vim | 271 + ftplugin/conf.vim | 23 + ftplugin/config.vim | 46 + ftplugin/context.vim | 106 + ftplugin/cpp.vim | 16 + ftplugin/crm.vim | 23 + ftplugin/cs.vim | 33 + ftplugin/csc.vim | 31 + ftplugin/csh.vim | 52 + ftplugin/css.vim | 27 + ftplugin/cucumber.vim | 154 + ftplugin/cvsrc.vim | 23 + ftplugin/debchangelog.vim | 387 + ftplugin/debcontrol.vim | 74 + ftplugin/denyhosts.vim | 22 + ftplugin/dictconf.vim | 23 + ftplugin/dictdconf.vim | 23 + ftplugin/diff.vim | 19 + ftplugin/dircolors.vim | 23 + ftplugin/docbk.vim | 28 + ftplugin/dockerfile.vim | 20 + ftplugin/dosbatch.vim | 34 + ftplugin/dosini.vim | 23 + ftplugin/dtd.vim | 44 + ftplugin/dtrace.vim | 44 + ftplugin/eiffel.vim | 100 + ftplugin/elinks.vim | 23 + ftplugin/erlang.vim | 91 + ftplugin/eruby.vim | 106 + ftplugin/eterm.vim | 24 + ftplugin/falcon.vim | 52 + ftplugin/fetchmail.vim | 23 + ftplugin/flexwiki.vim | 63 + ftplugin/fortran.vim | 136 + ftplugin/framescript.vim | 34 + ftplugin/fvwm.vim | 18 + ftplugin/git.vim | 45 + ftplugin/gitcommit.vim | 68 + ftplugin/gitconfig.vim | 19 + ftplugin/gitrebase.vim | 48 + ftplugin/gitsendemail.vim | 10 + ftplugin/go.vim | 22 + ftplugin/gpg.vim | 23 + ftplugin/gprof.vim | 36 + ftplugin/groovy.vim | 23 + ftplugin/group.vim | 23 + ftplugin/grub.vim | 23 + ftplugin/haml.vim | 73 + ftplugin/hamster.vim | 66 + ftplugin/haskell.vim | 24 + ftplugin/help.vim | 26 + ftplugin/hgcommit.vim | 20 + ftplugin/hog.vim | 43 + ftplugin/hostconf.vim | 22 + ftplugin/hostsaccess.vim | 23 + ftplugin/html.vim | 55 + ftplugin/htmldjango.vim | 17 + ftplugin/indent.vim | 24 + ftplugin/initex.vim | 43 + ftplugin/ishd.vim | 37 + ftplugin/j.vim | 85 + ftplugin/java.vim | 55 + ftplugin/javascript.vim | 42 + ftplugin/jproperties.vim | 19 + ftplugin/json.vim | 21 + ftplugin/jsp.vim | 71 + ftplugin/kconfig.vim | 31 + ftplugin/kwt.vim | 36 + ftplugin/ld.vim | 24 + ftplugin/less.vim | 24 + ftplugin/lftp.vim | 23 + ftplugin/libao.vim | 23 + ftplugin/limits.vim | 23 + ftplugin/liquid.vim | 65 + ftplugin/lisp.vim | 30 + ftplugin/logcheck.vim | 21 + ftplugin/loginaccess.vim | 23 + ftplugin/logindefs.vim | 23 + ftplugin/logtalk.vim | 22 + ftplugin/lprolog.vim | 41 + ftplugin/lua.vim | 46 + ftplugin/m4.vim | 24 + ftplugin/mail.vim | 42 + ftplugin/mailaliases.vim | 22 + ftplugin/mailcap.vim | 23 + ftplugin/make.vim | 37 + ftplugin/man.vim | 219 + ftplugin/manconf.vim | 23 + ftplugin/markdown.vim | 54 + ftplugin/matlab.vim | 36 + ftplugin/mf.vim | 74 + ftplugin/modconf.vim | 24 + ftplugin/mp.vim | 86 + ftplugin/mplayerconf.vim | 24 + ftplugin/mrxvtrc.vim | 26 + ftplugin/msmessages.vim | 44 + ftplugin/muttrc.vim | 26 + ftplugin/nanorc.vim | 23 + ftplugin/netrc.vim | 23 + ftplugin/nsis.vim | 26 + ftplugin/objc.vim | 16 + ftplugin/ocaml.vim | 624 ++ ftplugin/occam.vim | 53 + ftplugin/pamconf.vim | 23 + ftplugin/pascal.vim | 24 + ftplugin/passwd.vim | 23 + ftplugin/pdf.vim | 93 + ftplugin/perl.vim | 93 + ftplugin/perl6.vim | 81 + ftplugin/php.vim | 87 + ftplugin/pinfo.vim | 23 + ftplugin/plaintex.vim | 41 + ftplugin/postscr.vim | 42 + ftplugin/procmail.vim | 25 + ftplugin/prolog.vim | 24 + ftplugin/protocols.vim | 23 + ftplugin/pyrex.vim | 31 + ftplugin/python.vim | 92 + ftplugin/qf.vim | 20 + ftplugin/quake.vim | 23 + ftplugin/r.vim | 36 + ftplugin/racc.vim | 24 + ftplugin/readline.vim | 23 + ftplugin/registry.vim | 40 + ftplugin/reva.vim | 29 + ftplugin/rhelp.vim | 34 + ftplugin/rmd.vim | 58 + ftplugin/rnc.vim | 23 + ftplugin/rnoweb.vim | 45 + ftplugin/rpl.vim | 26 + ftplugin/rrst.vim | 42 + ftplugin/rst.vim | 24 + ftplugin/ruby.vim | 424 ++ ftplugin/rust.vim | 201 + ftplugin/sass.vim | 27 + ftplugin/sbt.vim | 19 + ftplugin/scala.vim | 39 + ftplugin/scheme.vim | 49 + ftplugin/screen.vim | 23 + ftplugin/scss.vim | 17 + ftplugin/sensors.vim | 23 + ftplugin/services.vim | 23 + ftplugin/setserial.vim | 23 + ftplugin/sgml.vim | 44 + ftplugin/sh.vim | 43 + ftplugin/sieve.vim | 24 + ftplugin/slpconf.vim | 24 + ftplugin/slpreg.vim | 24 + ftplugin/slpspi.vim | 24 + ftplugin/spec.vim | 214 + ftplugin/sql.vim | 552 ++ ftplugin/sshconfig.vim | 23 + ftplugin/sudoers.vim | 23 + ftplugin/svg.vim | 44 + ftplugin/sysctl.vim | 24 + ftplugin/systemd.vim | 11 + ftplugin/systemverilog.vim | 15 + ftplugin/tcl.vim | 41 + ftplugin/tcsh.vim | 44 + ftplugin/terminfo.vim | 23 + ftplugin/tex.vim | 50 + ftplugin/text.vim | 21 + ftplugin/tmux.vim | 16 + ftplugin/treetop.vim | 23 + ftplugin/tt2html.vim | 17 + ftplugin/udevconf.vim | 23 + ftplugin/udevperm.vim | 23 + ftplugin/udevrules.vim | 23 + ftplugin/updatedb.vim | 23 + ftplugin/vb.vim | 49 + ftplugin/verilog.vim | 70 + ftplugin/vhdl.vim | 92 + ftplugin/vim.vim | 81 + ftplugin/vroom.vim | 39 + ftplugin/xdefaults.vim | 24 + ftplugin/xf86conf.vim | 23 + ftplugin/xhtml.vim | 71 + ftplugin/xinetd.vim | 24 + ftplugin/xml.vim | 68 + ftplugin/xmodmap.vim | 23 + ftplugin/xs.vim | 18 + ftplugin/xsd.vim | 43 + ftplugin/xslt.vim | 20 + ftplugin/yaml.vim | 24 + ftplugin/zimbu.vim | 155 + ftplugin/zsh.vim | 33 + indent/aap.vim | 16 + indent/ada.vim | 312 + indent/ant.vim | 16 + indent/automake.vim | 15 + indent/awk.vim | 236 + indent/bib.vim | 19 + indent/bst.vim | 79 + indent/bzl.vim | 98 + indent/c.vim | 19 + indent/cdl.vim | 133 + indent/ch.vim | 22 + indent/chaiscript.vim | 54 + indent/changelog.vim | 18 + indent/clojure.vim | 398 + indent/cmake.vim | 93 + indent/cobol.vim | 220 + indent/config.vim | 86 + indent/context.vim | 40 + indent/cpp.vim | 19 + indent/cs.vim | 19 + indent/css.vim | 88 + indent/cucumber.vim | 79 + indent/cuda.vim | 19 + indent/d.vim | 26 + indent/dictconf.vim | 17 + indent/dictdconf.vim | 17 + indent/docbk.vim | 19 + indent/dtd.vim | 329 + indent/dtrace.vim | 21 + indent/dylan.vim | 94 + indent/eiffel.vim | 119 + indent/erlang.vim | 1394 ++++ indent/eruby.vim | 109 + indent/eterm.vim | 40 + indent/falcon.vim | 455 ++ indent/fortran.vim | 222 + indent/framescript.vim | 45 + indent/gitconfig.vim | 42 + indent/gitolite.vim | 49 + indent/go.vim | 70 + indent/haml.vim | 78 + indent/hamster.vim | 59 + indent/hog.vim | 81 + indent/html.vim | 1056 +++ indent/htmldjango.vim | 16 + indent/idlang.vim | 66 + indent/ishd.vim | 72 + indent/j.vim | 54 + indent/java.vim | 154 + indent/javascript.vim | 453 ++ indent/json.vim | 172 + indent/jsp.vim | 21 + indent/ld.vim | 88 + indent/less.vim | 17 + indent/lifelines.vim | 28 + indent/liquid.vim | 67 + indent/lisp.vim | 19 + indent/logtalk.vim | 65 + indent/lua.vim | 67 + indent/mail.vim | 17 + indent/make.vim | 120 + indent/matlab.vim | 78 + indent/mf.vim | 10 + indent/mma.vim | 79 + indent/mp.vim | 364 + indent/objc.vim | 83 + indent/ocaml.vim | 277 + indent/occam.vim | 191 + indent/pascal.vim | 232 + indent/perl.vim | 184 + indent/perl6.vim | 136 + indent/php.vim | 853 +++ indent/postscr.vim | 72 + indent/pov.vim | 88 + indent/prolog.vim | 62 + indent/pyrex.vim | 17 + indent/python.vim | 202 + indent/r.vim | 525 ++ indent/readline.vim | 40 + indent/rhelp.vim | 112 + indent/rmd.vim | 51 + indent/rnoweb.vim | 51 + indent/rpl.vim | 67 + indent/rrst.vim | 51 + indent/rst.vim | 63 + indent/ruby.vim | 699 ++ indent/rust.vim | 217 + indent/sas.vim | 142 + indent/sass.vim | 42 + indent/scala.vim | 613 ++ indent/scheme.vim | 15 + indent/scss.vim | 16 + indent/sdl.vim | 97 + indent/sh.vim | 203 + indent/sml.vim | 221 + indent/sql.vim | 43 + indent/sqlanywhere.vim | 397 + indent/systemd.vim | 14 + indent/systemverilog.vim | 234 + indent/tcl.vim | 79 + indent/tcsh.vim | 53 + indent/teraterm.vim | 59 + indent/tex.vim | 421 ++ indent/tf.vim | 76 + indent/tilde.vim | 40 + indent/treetop.vim | 42 + indent/vb.vim | 82 + indent/verilog.vim | 233 + indent/vhdl.vim | 438 ++ indent/vim.vim | 106 + indent/vroom.vim | 25 + indent/xf86conf.vim | 41 + indent/xhtml.vim | 16 + indent/xinetd.vim | 59 + indent/xml.vim | 111 + indent/xsd.vim | 17 + indent/xslt.vim | 17 + indent/yacc.vim | 45 + indent/yaml.vim | 159 + indent/zimbu.vim | 132 + indent/zsh.vim | 18 + syntax/2html.vim | 1812 +++++ syntax/a2ps.vim | 75 + syntax/a65.vim | 157 + syntax/aap.vim | 162 + syntax/abap.vim | 201 + syntax/abaqus.vim | 39 + syntax/abc.vim | 55 + syntax/abel.vim | 165 + syntax/acedb.vim | 114 + syntax/ada.vim | 372 + syntax/aflex.vim | 86 + syntax/ahdl.vim | 85 + syntax/alsaconf.vim | 53 + syntax/amiga.vim | 92 + syntax/aml.vim | 148 + syntax/ampl.vim | 144 + syntax/ant.vim | 101 + syntax/antlr.vim | 58 + syntax/apache.vim | 205 + syntax/apachestyle.vim | 56 + syntax/aptconf.vim | 578 ++ syntax/arch.vim | 45 + syntax/arduino.vim | 58 + syntax/art.vim | 54 + syntax/asciidoc.vim | 189 + syntax/asm.vim | 134 + syntax/asm68k.vim | 382 + syntax/asmh8300.vim | 72 + syntax/asn.vim | 77 + syntax/aspperl.vim | 29 + syntax/aspvbs.vim | 186 + syntax/asterisk.vim | 92 + syntax/asteriskvm.vim | 55 + syntax/atlas.vim | 89 + syntax/autohotkey.vim | 326 + syntax/autoit.vim | 1128 +++ syntax/automake.vim | 81 + syntax/ave.vim | 83 + syntax/avra.vim | 75 + syntax/awk.vim | 213 + syntax/ayacc.vim | 79 + syntax/b.vim | 118 + syntax/baan.vim | 1921 +++++ syntax/basic.vim | 170 + syntax/bc.vim | 70 + syntax/bdf.vim | 101 + syntax/bib.vim | 122 + syntax/bindzone.vim | 101 + syntax/blank.vim | 43 + syntax/bst.vim | 74 + syntax/btm.vim | 220 + syntax/bzl.vim | 20 + syntax/bzr.vim | 54 + syntax/c.vim | 481 ++ syntax/cabal.vim | 123 + syntax/calendar.vim | 114 + syntax/catalog.vim | 34 + syntax/cdl.vim | 82 + syntax/cdrdaoconf.vim | 143 + syntax/cdrtoc.vim | 541 ++ syntax/cf.vim | 441 ++ syntax/cfg.vim | 52 + syntax/ch.vim | 42 + syntax/chaiscript.vim | 98 + syntax/change.vim | 33 + syntax/changelog.vim | 62 + syntax/chaskell.vim | 18 + syntax/cheetah.vim | 51 + syntax/chill.vim | 182 + syntax/chordpro.vim | 71 + syntax/cl.vim | 102 + syntax/clean.vim | 94 + syntax/clipper.vim | 139 + syntax/clojure.vim | 227 + syntax/cmake.vim | 481 ++ syntax/cmusrc.vim | 313 + syntax/cobol.vim | 196 + syntax/coco.vim | 36 + syntax/colortest.vim | 85 + syntax/conaryrecipe.vim | 141 + syntax/conf.vim | 30 + syntax/config.vim | 56 + syntax/context.vim | 145 + syntax/cpp.vim | 81 + syntax/crm.vim | 45 + syntax/crontab.vim | 71 + syntax/cs.vim | 158 + syntax/csc.vim | 195 + syntax/csdl.vim | 540 ++ syntax/csh.vim | 147 + syntax/csp.vim | 186 + syntax/css.vim | 335 +- syntax/cterm.vim | 181 + syntax/ctrlh.vim | 27 + syntax/cucumber.vim | 146 + syntax/cuda.vim | 69 + syntax/cupl.vim | 128 + syntax/cuplsim.vim | 67 + syntax/cvs.vim | 34 + syntax/cvsrc.vim | 43 + syntax/cweb.vim | 72 + syntax/cynlib.vim | 78 + syntax/cynpp.vim | 54 + syntax/d.vim | 577 ++ syntax/datascript.vim | 106 + syntax/dcd.vim | 55 + syntax/dcl.vim | 156 + syntax/debchangelog.vim | 55 + syntax/debcontrol.vim | 117 + syntax/debsources.vim | 58 + syntax/def.vim | 48 + syntax/denyhosts.vim | 293 + syntax/desc.vim | 92 + syntax/desktop.vim | 111 + syntax/dictconf.vim | 84 + syntax/dictdconf.vim | 150 + syntax/diff.vim | 386 + syntax/dircolors.vim | 220 + syntax/dirpager.vim | 60 + syntax/diva.vim | 100 + syntax/django.vim | 87 + syntax/dns.vim | 9 + syntax/dnsmasq.vim | 246 + syntax/docbk.vim | 190 + syntax/docbksgml.vim | 11 + syntax/docbkxml.vim | 11 + syntax/dockerfile.vim | 28 + syntax/dosbatch.vim | 151 + syntax/dosini.vim | 42 + syntax/dot.vim | 101 + syntax/doxygen.vim | 598 ++ syntax/dracula.vim | 76 + syntax/dsl.vim | 42 + syntax/dtd.vim | 164 + syntax/dtml.vim | 212 + syntax/dtrace.vim | 149 + syntax/dts.vim | 34 + syntax/dylan.vim | 96 + syntax/dylanintr.vim | 43 + syntax/dylanlid.vim | 33 + syntax/ecd.vim | 48 + syntax/edif.vim | 49 + syntax/eiffel.vim | 203 + syntax/elf.vim | 86 + syntax/elinks.vim | 192 + syntax/elmfilt.vim | 62 + syntax/erlang.vim | 262 + syntax/eruby.vim | 78 + syntax/esmtprc.vim | 35 + syntax/esqlc.vim | 62 + syntax/esterel.vim | 82 + syntax/eterm.vim | 433 ++ syntax/euphoria3.vim | 137 + syntax/euphoria4.vim | 249 + syntax/eviews.vim | 91 + syntax/exim.vim | 109 + syntax/expect.vim | 107 + syntax/exports.vim | 62 + syntax/falcon.vim | 201 + syntax/fan.vim | 136 + syntax/fasm.vim | 155 + syntax/fdcc.vim | 105 + syntax/fetchmail.vim | 79 + syntax/fgl.vim | 138 + syntax/flexwiki.vim | 137 + syntax/focexec.vim | 92 + syntax/form.vim | 149 + syntax/forth.vim | 334 + syntax/fortran.vim | 540 ++ syntax/foxpro.vim | 720 ++ syntax/framescript.vim | 495 ++ syntax/freebasic.vim | 256 + syntax/fstab.vim | 291 + syntax/fvwm.vim | 646 ++ syntax/fvwm2m4.vim | 36 + syntax/gdb.vim | 107 + syntax/gdmo.vim | 87 + syntax/gedcom.vim | 57 + syntax/git.vim | 82 + syntax/gitcommit.vim | 88 + syntax/gitconfig.vim | 42 + syntax/gitolite.vim | 90 + syntax/gitrebase.vim | 44 + syntax/gitsendemail.vim | 27 + syntax/gkrellmrc.vim | 79 + syntax/gnash.vim | 100 + syntax/gnuplot.vim | 548 ++ syntax/go.vim | 212 + syntax/godoc.vim | 23 + syntax/gp.vim | 87 + syntax/gpg.vim | 109 + syntax/gprof.vim | 73 + syntax/grads.vim | 77 + syntax/gretl.vim | 89 + syntax/groff.vim | 14 + syntax/groovy.vim | 454 ++ syntax/group.vim | 56 + syntax/grub.vim | 97 + syntax/gsp.vim | 58 + syntax/gtkrc.vim | 130 + syntax/haml.vim | 113 + syntax/hamster.vim | 374 + syntax/haskell.vim | 186 + syntax/haste.vim | 146 + syntax/hastepreproc.vim | 42 + syntax/hb.vim | 93 + syntax/help.vim | 220 + syntax/hercules.vim | 123 + syntax/hex.vim | 93 + syntax/hgcommit.vim | 31 + syntax/hitest.vim | 142 + syntax/hog.vim | 203 + syntax/hostconf.vim | 151 + syntax/hostsaccess.vim | 27 + syntax/html.vim | 309 + syntax/htmlcheetah.vim | 28 + syntax/htmldjango.vim | 30 + syntax/htmlm4.vim | 35 + syntax/htmlos.vim | 153 + syntax/ia64.vim | 298 + syntax/ibasic.vim | 180 + syntax/icemenu.vim | 38 + syntax/icon.vim | 203 + syntax/idl.vim | 328 + syntax/idlang.vim | 244 + syntax/indent.vim | 156 + syntax/inform.vim | 396 + syntax/initex.vim | 380 + syntax/initng.vim | 95 + syntax/inittab.vim | 67 + syntax/ipfilter.vim | 58 + syntax/ishd.vim | 413 + syntax/iss.vim | 140 + syntax/ist.vim | 62 + syntax/j.vim | 150 + syntax/jal.vim | 240 + syntax/jam.vim | 244 + syntax/jargon.vim | 27 + syntax/java.vim | 346 + syntax/javacc.vim | 69 + syntax/javascript.vim | 129 + syntax/jess.vim | 148 + syntax/jgraph.vim | 49 + syntax/jovial.vim | 114 + syntax/jproperties.vim | 139 + syntax/json.vim | 136 + syntax/jsp.vim | 72 + syntax/kconfig.vim | 743 ++ syntax/kivy.vim | 40 + syntax/kix.vim | 174 + syntax/kscript.vim | 61 + syntax/kwt.vim | 74 + syntax/lace.vim | 126 + syntax/latte.vim | 85 + syntax/ld.vim | 85 + syntax/ldapconf.vim | 342 + syntax/ldif.vim | 37 + syntax/less.vim | 83 + syntax/lex.vim | 147 + syntax/lftp.vim | 156 + syntax/lhaskell.vim | 127 + syntax/libao.vim | 31 + syntax/lifelines.vim | 158 + syntax/lilo.vim | 178 + syntax/limits.vim | 48 + syntax/liquid.vim | 142 + syntax/lisp.vim | 622 ++ syntax/lite.vim | 172 + syntax/litestep.vim | 273 + syntax/loginaccess.vim | 100 + syntax/logindefs.vim | 178 + syntax/logtalk.vim | 439 ++ syntax/lotos.vim | 73 + syntax/lout.vim | 139 + syntax/lpc.vim | 451 ++ syntax/lprolog.vim | 128 + syntax/lscript.vim | 204 + syntax/lsl.vim | 281 + syntax/lss.vim | 127 + syntax/lua.vim | 358 + syntax/lynx.vim | 144 + syntax/m4.vim | 64 + syntax/mail.vim | 116 + syntax/mailaliases.vim | 75 + syntax/mailcap.vim | 39 + syntax/make.vim | 134 + syntax/mallard.vim | 41 + syntax/man.vim | 54 + syntax/manconf.vim | 121 + syntax/manual.vim | 33 + syntax/maple.vim | 626 ++ syntax/markdown.vim | 149 + syntax/masm.vim | 379 + syntax/mason.vim | 87 + syntax/master.vim | 41 + syntax/matlab.vim | 120 + syntax/maxima.vim | 265 + syntax/mel.vim | 112 + syntax/messages.vim | 77 + syntax/mf.vim | 299 + syntax/mgl.vim | 121 + syntax/mgp.vim | 73 + syntax/mib.vim | 61 + syntax/mix.vim | 87 + syntax/mma.vim | 325 + syntax/mmix.vim | 156 + syntax/mmp.vim | 53 + syntax/modconf.vim | 48 + syntax/model.vim | 48 + syntax/modsim3.vim | 101 + syntax/modula2.vim | 77 + syntax/modula3.vim | 63 + syntax/monk.vim | 221 + syntax/moo.vim | 177 + syntax/mp.vim | 773 ++ syntax/mplayerconf.vim | 132 + syntax/mrxvtrc.vim | 286 + syntax/msidl.vim | 88 + syntax/msmessages.vim | 136 + syntax/msql.vim | 87 + syntax/mupad.vim | 287 + syntax/murphi.vim | 131 + syntax/mush.vim | 219 + syntax/muttrc.vim | 785 ++ syntax/mysql.vim | 292 + syntax/n1ql.vim | 438 ++ syntax/named.vim | 233 + syntax/nanorc.vim | 247 + syntax/nasm.vim | 530 ++ syntax/nastran.vim | 185 + syntax/natural.vim | 205 + syntax/ncf.vim | 251 + syntax/netrc.vim | 56 + syntax/netrw.vim | 126 + syntax/ninja.vim | 87 + syntax/nosyntax.vim | 34 + syntax/nqc.vim | 369 + syntax/nroff.vim | 253 + syntax/nsis.vim | 260 + syntax/obj.vim | 87 + syntax/objc.vim | 537 ++ syntax/objcpp.vim | 24 + syntax/ocaml.vim | 322 + syntax/occam.vim | 120 + syntax/omnimark.vim | 110 + syntax/openroad.vim | 256 + syntax/opl.vim | 93 + syntax/ora.vim | 468 ++ syntax/pamconf.vim | 124 + syntax/papp.vim | 80 + syntax/pascal.vim | 364 + syntax/passwd.vim | 75 + syntax/pcap.vim | 52 + syntax/pccts.vim | 93 + syntax/pdf.vim | 77 + syntax/perl.vim | 586 ++ syntax/perl6.vim | 2246 ++++++ syntax/pf.vim | 110 + syntax/pfmain.vim | 1839 +++++ syntax/php.vim | 669 ++ syntax/phtml.vim | 10 + syntax/pic.vim | 118 + syntax/pike.vim | 146 + syntax/pilrc.vim | 140 + syntax/pine.vim | 359 + syntax/pinfo.vim | 114 + syntax/plaintex.vim | 174 + syntax/pli.vim | 270 + syntax/plm.vim | 138 + syntax/plp.vim | 41 + syntax/plsql.vim | 268 + syntax/po.vim | 137 + syntax/pod.vim | 179 + syntax/postscr.vim | 784 ++ syntax/pov.vim | 148 + syntax/povini.vim | 60 + syntax/ppd.vim | 39 + syntax/ppwiz.vim | 88 + syntax/prescribe.vim | 60 + syntax/privoxy.vim | 75 + syntax/procmail.vim | 58 + syntax/progress.vim | 316 + syntax/prolog.vim | 117 + syntax/promela.vim | 57 + syntax/proto.vim | 77 + syntax/protocols.vim | 48 + syntax/psf.vim | 95 + syntax/ptcap.vim | 99 + syntax/purifylog.vim | 110 + syntax/pyrex.vim | 55 + syntax/python.vim | 343 + syntax/qf.vim | 28 + syntax/quake.vim | 174 + syntax/r.vim | 378 + syntax/racc.vim | 146 + syntax/radiance.vim | 146 + syntax/ratpoison.vim | 271 + syntax/rc.vim | 194 + syntax/rcs.vim | 67 + syntax/rcslog.vim | 29 + syntax/readline.vim | 402 + syntax/rebol.vim | 203 + syntax/redif.vim | 974 +++ syntax/registry.vim | 107 + syntax/remind.vim | 77 + syntax/resolv.vim | 82 + syntax/reva.vim | 195 + syntax/rexx.vim | 322 + syntax/rhelp.vim | 278 + syntax/rib.vim | 66 + syntax/rmd.vim | 127 + syntax/rnc.vim | 72 + syntax/rng.vim | 29 + syntax/rnoweb.vim | 56 + syntax/robots.vim | 61 + syntax/rpcgen.vim | 50 + syntax/rpl.vim | 487 ++ syntax/rrst.vim | 47 + syntax/rst.vim | 211 + syntax/rtf.vim | 79 + syntax/ruby.vim | 556 ++ syntax/rust.vim | 299 + syntax/samba.vim | 122 + syntax/sas.vim | 269 + syntax/sass.vim | 110 + syntax/sather.vim | 96 + syntax/sbt.vim | 36 + syntax/scala.vim | 236 + syntax/scheme.vim | 332 + syntax/scilab.vim | 106 + syntax/screen.vim | 264 + syntax/scss.vim | 24 + syntax/sd.vim | 75 + syntax/sdc.vim | 45 + syntax/sdl.vim | 157 + syntax/sed.vim | 114 + syntax/sendpr.vim | 39 + syntax/sensors.vim | 56 + syntax/services.vim | 58 + syntax/setserial.vim | 124 + syntax/sgml.vim | 338 + syntax/sgmldecl.vim | 76 + syntax/sgmllnx.vim | 58 + syntax/sh.vim | 729 ++ syntax/sicad.vim | 394 + syntax/sieve.vim | 59 + syntax/simula.vim | 91 + syntax/sinda.vim | 133 + syntax/sindacmp.vim | 65 + syntax/sindaout.vim | 87 + syntax/sisu.vim | 279 + syntax/skill.vim | 553 ++ syntax/sl.vim | 111 + syntax/slang.vim | 93 + syntax/slice.vim | 82 + syntax/slpconf.vim | 277 + syntax/slpreg.vim | 126 + syntax/slpspi.vim | 43 + syntax/slrnrc.vim | 185 + syntax/slrnsc.vim | 72 + syntax/sm.vim | 84 + syntax/smarty.vim | 80 + syntax/smcl.vim | 311 + syntax/smil.vim | 150 + syntax/smith.vim | 43 + syntax/sml.vim | 221 + syntax/snnsnet.vim | 71 + syntax/snnspat.vim | 66 + syntax/snnsres.vim | 54 + syntax/snobol4.vim | 116 + syntax/spec.vim | 227 + syntax/specman.vim | 173 + syntax/spice.vim | 79 + syntax/splint.vim | 247 + syntax/spup.vim | 273 + syntax/spyce.vim | 108 + syntax/sql.vim | 40 + syntax/sqlanywhere.vim | 909 +++ syntax/sqlforms.vim | 156 + syntax/sqlhana.vim | 294 + syntax/sqlinformix.vim | 187 + syntax/sqlj.vim | 95 + syntax/sqloracle.vim | 148 + syntax/sqr.vim | 266 + syntax/squid.vim | 144 + syntax/srec.vim | 87 + syntax/sshconfig.vim | 262 + syntax/sshdconfig.vim | 271 + syntax/st.vim | 99 + syntax/stata.vim | 454 ++ syntax/stp.vim | 158 + syntax/strace.vim | 57 + syntax/sudoers.vim | 346 + syntax/svg.vim | 19 + syntax/svn.vim | 60 + syntax/syncolor.vim | 89 + syntax/synload.vim | 85 + syntax/syntax.vim | 47 + syntax/sysctl.vim | 43 + syntax/systemd.vim | 12 + syntax/systemverilog.vim | 89 + syntax/tads.vim | 175 + syntax/tags.vim | 35 + syntax/tak.vim | 123 + syntax/takcmp.vim | 73 + syntax/takout.vim | 89 + syntax/tap.vim | 101 + syntax/tar.vim | 21 + syntax/taskdata.vim | 49 + syntax/taskedit.vim | 41 + syntax/tasm.vim | 119 + syntax/tcl.vim | 278 + syntax/tcsh.vim | 252 + syntax/teraterm.vim | 143 + syntax/terminfo.vim | 97 + syntax/tex.vim | 1382 ++++ syntax/texinfo.vim | 400 + syntax/texmf.vim | 78 + syntax/tf.vim | 200 + syntax/tidy.vim | 139 + syntax/tilde.vim | 45 + syntax/tli.vim | 62 + syntax/tmux.vim | 128 + syntax/tpp.vim | 87 + syntax/trasys.vim | 164 + syntax/treetop.vim | 114 + syntax/trustees.vim | 46 + syntax/tsalt.vim | 210 + syntax/tsscl.vim | 208 + syntax/tssgm.vim | 102 + syntax/tssop.vim | 78 + syntax/tt2.vim | 214 + syntax/tt2html.vim | 24 + syntax/tt2js.vim | 24 + syntax/uc.vim | 169 + syntax/udevconf.vim | 43 + syntax/udevperm.vim | 73 + syntax/udevrules.vim | 175 + syntax/uil.vim | 79 + syntax/updatedb.vim | 45 + syntax/upstart.vim | 115 + syntax/upstreamdat.vim | 309 + syntax/upstreaminstalllog.vim | 31 + syntax/upstreamlog.vim | 58 + syntax/upstreamrpt.vim | 314 + syntax/usserverlog.vim | 64 + syntax/usw2kagtlog.vim | 58 + syntax/valgrind.vim | 115 + syntax/vb.vim | 369 + syntax/vera.vim | 352 + syntax/verilog.vim | 123 + syntax/verilogams.vim | 136 + syntax/vgrindefs.vim | 49 + syntax/vhdl.vim | 264 + syntax/vim.vim | 981 +++ syntax/viminfo.vim | 52 + syntax/virata.vim | 211 + syntax/vmasm.vim | 242 + syntax/voscm.vim | 98 + syntax/vrml.vim | 226 + syntax/vroom.vim | 114 + syntax/vsejcl.vim | 40 + syntax/wdiff.vim | 33 + syntax/web.vim | 36 + syntax/webmacro.vim | 71 + syntax/wget.vim | 193 + syntax/whitespace.vim | 17 + syntax/winbatch.vim | 178 + syntax/wml.vim | 154 + syntax/wsh.vim | 49 + syntax/wsml.vim | 117 + syntax/wvdial.vim | 32 + syntax/xbl.vim | 33 + syntax/xdefaults.vim | 136 + syntax/xf86conf.vim | 209 + syntax/xhtml.vim | 15 + syntax/xinetd.vim | 351 + syntax/xkb.vim | 83 + syntax/xmath.vim | 229 + syntax/xml.vim | 350 + syntax/xmodmap.vim | 681 ++ syntax/xpm.vim | 142 + syntax/xpm2.vim | 157 + syntax/xquery.vim | 86 + syntax/xs.vim | 3681 +++++++++ syntax/xsd.vim | 65 + syntax/xslt.vim | 66 + syntax/xxd.vim | 34 + syntax/yacc.vim | 123 + syntax/yaml.vim | 247 + syntax/z8a.vim | 105 + syntax/zimbu.vim | 164 + syntax/zsh.vim | 408 + 1034 files changed, 172275 insertions(+), 181 deletions(-) create mode 100644 autoload/ada.vim create mode 100644 autoload/adacomplete.vim create mode 100644 autoload/ccomplete.vim create mode 100644 autoload/context.vim create mode 100644 autoload/contextcomplete.vim create mode 100644 autoload/csscomplete.vim create mode 100644 autoload/decada.vim create mode 100644 autoload/getscript.vim create mode 100644 autoload/gnat.vim create mode 100644 autoload/gzip.vim create mode 100644 autoload/javascriptcomplete.vim create mode 100644 autoload/netrw.vim create mode 100644 autoload/netrwFileHandlers.vim create mode 100644 autoload/netrwSettings.vim create mode 100644 autoload/netrw_gitignore.vim create mode 100644 autoload/paste.vim create mode 100644 autoload/phpcomplete.vim create mode 100644 autoload/python3complete.vim create mode 100644 autoload/pythoncomplete.vim create mode 100644 autoload/spellfile.vim create mode 100644 autoload/sqlcomplete.vim create mode 100644 autoload/syntaxcomplete.vim create mode 100644 autoload/tar.vim create mode 100644 autoload/tohtml.vim create mode 100644 autoload/vimball.vim create mode 100644 autoload/xml/html32.vim create mode 100644 autoload/xml/html401f.vim create mode 100644 autoload/xml/html401s.vim create mode 100644 autoload/xml/html401t.vim create mode 100644 autoload/xml/html40f.vim create mode 100644 autoload/xml/html40s.vim create mode 100644 autoload/xml/html40t.vim create mode 100644 autoload/xml/xhtml10f.vim create mode 100644 autoload/xml/xhtml10s.vim create mode 100644 autoload/xml/xhtml10t.vim create mode 100644 autoload/xml/xhtml11.vim create mode 100644 autoload/xml/xsd.vim create mode 100644 autoload/xml/xsl.vim create mode 100644 autoload/xmlcomplete.vim create mode 100644 autoload/zip.vim create mode 100644 compiler/ant.vim create mode 100644 compiler/bcc.vim create mode 100644 compiler/bdf.vim create mode 100644 compiler/checkstyle.vim create mode 100644 compiler/context.vim create mode 100644 compiler/cs.vim create mode 100644 compiler/csslint.vim create mode 100644 compiler/decada.vim create mode 100644 compiler/dot.vim create mode 100644 compiler/erlang.vim create mode 100644 compiler/fortran_F.vim create mode 100644 compiler/fortran_cv.vim create mode 100644 compiler/fortran_elf90.vim create mode 100644 compiler/fortran_g77.vim create mode 100644 compiler/fortran_lf95.vim create mode 100644 compiler/fpc.vim create mode 100644 compiler/g95.vim create mode 100644 compiler/gcc.vim create mode 100644 compiler/gfortran.vim create mode 100644 compiler/ghc.vim create mode 100644 compiler/gnat.vim create mode 100644 compiler/hp_acc.vim create mode 100644 compiler/icc.vim create mode 100644 compiler/ifort.vim create mode 100644 compiler/intel.vim create mode 100644 compiler/irix5_c.vim create mode 100644 compiler/irix5_cpp.vim create mode 100644 compiler/javac.vim create mode 100644 compiler/jikes.vim create mode 100644 compiler/mcs.vim create mode 100644 compiler/mips_c.vim create mode 100644 compiler/mipspro_c89.vim create mode 100644 compiler/mipspro_cpp.vim create mode 100644 compiler/modelsim_vcom.vim create mode 100644 compiler/msbuild.vim create mode 100644 compiler/msvc.vim create mode 100644 compiler/neato.vim create mode 100644 compiler/ocaml.vim create mode 100644 compiler/onsgmls.vim create mode 100644 compiler/pbx.vim create mode 100644 compiler/perl.vim create mode 100644 compiler/php.vim create mode 100644 compiler/pylint.vim create mode 100644 compiler/pyunit.vim create mode 100644 compiler/rst.vim create mode 100644 compiler/sass.vim create mode 100644 compiler/se.vim create mode 100644 compiler/splint.vim create mode 100644 compiler/tcl.vim create mode 100644 compiler/tex.vim create mode 100644 compiler/tidy.vim create mode 100644 compiler/xbuild.vim create mode 100644 compiler/xmllint.vim create mode 100644 compiler/xmlwf.vim create mode 100644 ftplugin/a2ps.vim create mode 100644 ftplugin/aap.vim create mode 100644 ftplugin/abap.vim create mode 100644 ftplugin/abaqus.vim create mode 100644 ftplugin/ada.vim create mode 100644 ftplugin/alsaconf.vim create mode 100644 ftplugin/ant.vim create mode 100644 ftplugin/arch.vim create mode 100644 ftplugin/art.vim create mode 100644 ftplugin/aspvbs.vim create mode 100644 ftplugin/automake.vim create mode 100644 ftplugin/awk.vim create mode 100644 ftplugin/bdf.vim create mode 100644 ftplugin/bst.vim create mode 100644 ftplugin/btm.vim create mode 100644 ftplugin/bzl.vim create mode 100644 ftplugin/c.vim create mode 100644 ftplugin/calendar.vim create mode 100644 ftplugin/cdrdaoconf.vim create mode 100644 ftplugin/ch.vim create mode 100644 ftplugin/changelog.vim create mode 100644 ftplugin/cobol.vim create mode 100644 ftplugin/conf.vim create mode 100644 ftplugin/config.vim create mode 100644 ftplugin/context.vim create mode 100644 ftplugin/cpp.vim create mode 100644 ftplugin/crm.vim create mode 100644 ftplugin/cs.vim create mode 100644 ftplugin/csc.vim create mode 100644 ftplugin/csh.vim create mode 100644 ftplugin/css.vim create mode 100644 ftplugin/cvsrc.vim create mode 100644 ftplugin/debchangelog.vim create mode 100644 ftplugin/debcontrol.vim create mode 100644 ftplugin/denyhosts.vim create mode 100644 ftplugin/dictconf.vim create mode 100644 ftplugin/dictdconf.vim create mode 100644 ftplugin/diff.vim create mode 100644 ftplugin/dircolors.vim create mode 100644 ftplugin/docbk.vim create mode 100644 ftplugin/dockerfile.vim create mode 100644 ftplugin/dosbatch.vim create mode 100644 ftplugin/dosini.vim create mode 100644 ftplugin/dtd.vim create mode 100644 ftplugin/dtrace.vim create mode 100644 ftplugin/eiffel.vim create mode 100644 ftplugin/elinks.vim create mode 100644 ftplugin/erlang.vim create mode 100644 ftplugin/eterm.vim create mode 100644 ftplugin/falcon.vim create mode 100644 ftplugin/fetchmail.vim create mode 100644 ftplugin/flexwiki.vim create mode 100644 ftplugin/fortran.vim create mode 100644 ftplugin/framescript.vim create mode 100644 ftplugin/fvwm.vim create mode 100644 ftplugin/go.vim create mode 100644 ftplugin/gpg.vim create mode 100644 ftplugin/gprof.vim create mode 100644 ftplugin/groovy.vim create mode 100644 ftplugin/group.vim create mode 100644 ftplugin/grub.vim create mode 100644 ftplugin/hamster.vim create mode 100644 ftplugin/help.vim create mode 100644 ftplugin/hgcommit.vim create mode 100644 ftplugin/hog.vim create mode 100644 ftplugin/hostconf.vim create mode 100644 ftplugin/hostsaccess.vim create mode 100644 ftplugin/htmldjango.vim create mode 100644 ftplugin/indent.vim create mode 100644 ftplugin/initex.vim create mode 100644 ftplugin/ishd.vim create mode 100644 ftplugin/j.vim create mode 100644 ftplugin/java.vim create mode 100644 ftplugin/javascript.vim create mode 100644 ftplugin/jproperties.vim create mode 100644 ftplugin/jsp.vim create mode 100644 ftplugin/kconfig.vim create mode 100644 ftplugin/kwt.vim create mode 100644 ftplugin/ld.vim create mode 100644 ftplugin/lftp.vim create mode 100644 ftplugin/libao.vim create mode 100644 ftplugin/limits.vim create mode 100644 ftplugin/lisp.vim create mode 100644 ftplugin/logcheck.vim create mode 100644 ftplugin/loginaccess.vim create mode 100644 ftplugin/logindefs.vim create mode 100644 ftplugin/logtalk.vim create mode 100644 ftplugin/lprolog.vim create mode 100644 ftplugin/lua.vim create mode 100644 ftplugin/m4.vim create mode 100644 ftplugin/mail.vim create mode 100644 ftplugin/mailaliases.vim create mode 100644 ftplugin/mailcap.vim create mode 100644 ftplugin/make.vim create mode 100644 ftplugin/man.vim create mode 100644 ftplugin/manconf.vim create mode 100644 ftplugin/markdown.vim create mode 100644 ftplugin/matlab.vim create mode 100644 ftplugin/mf.vim create mode 100644 ftplugin/modconf.vim create mode 100644 ftplugin/mp.vim create mode 100644 ftplugin/mplayerconf.vim create mode 100644 ftplugin/mrxvtrc.vim create mode 100644 ftplugin/msmessages.vim create mode 100644 ftplugin/muttrc.vim create mode 100644 ftplugin/nanorc.vim create mode 100644 ftplugin/netrc.vim create mode 100644 ftplugin/nsis.vim create mode 100644 ftplugin/occam.vim create mode 100644 ftplugin/pamconf.vim create mode 100644 ftplugin/pascal.vim create mode 100644 ftplugin/passwd.vim create mode 100644 ftplugin/pdf.vim create mode 100644 ftplugin/perl6.vim create mode 100644 ftplugin/php.vim create mode 100644 ftplugin/pinfo.vim create mode 100644 ftplugin/plaintex.vim create mode 100644 ftplugin/postscr.vim create mode 100644 ftplugin/procmail.vim create mode 100644 ftplugin/prolog.vim create mode 100644 ftplugin/protocols.vim create mode 100644 ftplugin/pyrex.vim create mode 100644 ftplugin/python.vim create mode 100644 ftplugin/qf.vim create mode 100644 ftplugin/quake.vim create mode 100644 ftplugin/racc.vim create mode 100644 ftplugin/readline.vim create mode 100644 ftplugin/registry.vim create mode 100644 ftplugin/reva.vim create mode 100644 ftplugin/rmd.vim create mode 100644 ftplugin/rnc.vim create mode 100644 ftplugin/rpl.vim create mode 100644 ftplugin/rrst.vim create mode 100644 ftplugin/rst.vim create mode 100644 ftplugin/sass.vim create mode 100644 ftplugin/sbt.vim create mode 100644 ftplugin/scheme.vim create mode 100644 ftplugin/screen.vim create mode 100644 ftplugin/sensors.vim create mode 100644 ftplugin/services.vim create mode 100644 ftplugin/setserial.vim create mode 100644 ftplugin/sgml.vim create mode 100644 ftplugin/sh.vim create mode 100644 ftplugin/sieve.vim create mode 100644 ftplugin/slpconf.vim create mode 100644 ftplugin/slpreg.vim create mode 100644 ftplugin/slpspi.vim create mode 100644 ftplugin/spec.vim create mode 100644 ftplugin/sql.vim create mode 100644 ftplugin/sshconfig.vim create mode 100644 ftplugin/sudoers.vim create mode 100644 ftplugin/svg.vim create mode 100644 ftplugin/sysctl.vim create mode 100644 ftplugin/systemd.vim create mode 100644 ftplugin/systemverilog.vim create mode 100644 ftplugin/tcl.vim create mode 100644 ftplugin/tcsh.vim create mode 100644 ftplugin/terminfo.vim create mode 100644 ftplugin/tex.vim create mode 100644 ftplugin/text.vim create mode 100644 ftplugin/treetop.vim create mode 100644 ftplugin/udevconf.vim create mode 100644 ftplugin/udevperm.vim create mode 100644 ftplugin/udevrules.vim create mode 100644 ftplugin/updatedb.vim create mode 100644 ftplugin/vb.vim create mode 100644 ftplugin/verilog.vim create mode 100644 ftplugin/vhdl.vim create mode 100644 ftplugin/vim.vim create mode 100644 ftplugin/vroom.vim create mode 100644 ftplugin/xdefaults.vim create mode 100644 ftplugin/xf86conf.vim create mode 100644 ftplugin/xhtml.vim create mode 100644 ftplugin/xinetd.vim create mode 100644 ftplugin/xml.vim create mode 100644 ftplugin/xmodmap.vim create mode 100644 ftplugin/xsd.vim create mode 100644 ftplugin/xslt.vim create mode 100644 ftplugin/yaml.vim create mode 100644 ftplugin/zimbu.vim create mode 100644 ftplugin/zsh.vim create mode 100644 indent/aap.vim create mode 100644 indent/ada.vim create mode 100644 indent/ant.vim create mode 100644 indent/automake.vim create mode 100644 indent/awk.vim create mode 100644 indent/bib.vim create mode 100644 indent/bst.vim create mode 100644 indent/bzl.vim create mode 100644 indent/c.vim create mode 100644 indent/cdl.vim create mode 100644 indent/ch.vim create mode 100644 indent/chaiscript.vim create mode 100644 indent/changelog.vim create mode 100644 indent/cmake.vim create mode 100644 indent/cobol.vim create mode 100644 indent/config.vim create mode 100644 indent/context.vim create mode 100644 indent/cpp.vim create mode 100644 indent/cs.vim create mode 100644 indent/css.vim create mode 100644 indent/cuda.vim create mode 100644 indent/d.vim create mode 100644 indent/dictconf.vim create mode 100644 indent/dictdconf.vim create mode 100644 indent/docbk.vim create mode 100644 indent/dtd.vim create mode 100644 indent/dtrace.vim create mode 100644 indent/dylan.vim create mode 100644 indent/eiffel.vim create mode 100644 indent/eterm.vim create mode 100644 indent/falcon.vim create mode 100644 indent/fortran.vim create mode 100644 indent/framescript.vim create mode 100644 indent/gitolite.vim create mode 100644 indent/hamster.vim create mode 100644 indent/hog.vim create mode 100644 indent/htmldjango.vim create mode 100644 indent/idlang.vim create mode 100644 indent/ishd.vim create mode 100644 indent/j.vim create mode 100644 indent/java.vim create mode 100644 indent/jsp.vim create mode 100644 indent/ld.vim create mode 100644 indent/lifelines.vim create mode 100644 indent/lisp.vim create mode 100644 indent/logtalk.vim create mode 100644 indent/mail.vim create mode 100644 indent/make.vim create mode 100644 indent/matlab.vim create mode 100644 indent/mf.vim create mode 100644 indent/mma.vim create mode 100644 indent/mp.vim create mode 100644 indent/objc.vim create mode 100644 indent/occam.vim create mode 100644 indent/pascal.vim create mode 100644 indent/perl6.vim create mode 100644 indent/php.vim create mode 100644 indent/postscr.vim create mode 100644 indent/pov.vim create mode 100644 indent/prolog.vim create mode 100644 indent/pyrex.vim create mode 100644 indent/r.vim create mode 100644 indent/readline.vim create mode 100644 indent/rhelp.vim create mode 100644 indent/rmd.vim create mode 100644 indent/rnoweb.vim create mode 100644 indent/rpl.vim create mode 100644 indent/rrst.vim create mode 100644 indent/rst.vim create mode 100644 indent/sas.vim create mode 100644 indent/sass.vim create mode 100644 indent/scheme.vim create mode 100644 indent/scss.vim create mode 100644 indent/sdl.vim create mode 100644 indent/sh.vim create mode 100644 indent/sml.vim create mode 100644 indent/sql.vim create mode 100644 indent/sqlanywhere.vim create mode 100644 indent/systemd.vim create mode 100644 indent/systemverilog.vim create mode 100644 indent/tcl.vim create mode 100644 indent/tcsh.vim create mode 100644 indent/teraterm.vim create mode 100644 indent/tf.vim create mode 100644 indent/tilde.vim create mode 100644 indent/treetop.vim create mode 100644 indent/vb.vim create mode 100644 indent/verilog.vim create mode 100644 indent/vhdl.vim create mode 100644 indent/vim.vim create mode 100644 indent/vroom.vim create mode 100644 indent/xf86conf.vim create mode 100644 indent/xhtml.vim create mode 100644 indent/xinetd.vim create mode 100644 indent/xml.vim create mode 100644 indent/xsd.vim create mode 100644 indent/xslt.vim create mode 100644 indent/yacc.vim create mode 100644 indent/yaml.vim create mode 100644 indent/zimbu.vim create mode 100644 indent/zsh.vim create mode 100644 syntax/2html.vim create mode 100644 syntax/a2ps.vim create mode 100644 syntax/a65.vim create mode 100644 syntax/aap.vim create mode 100644 syntax/abap.vim create mode 100644 syntax/abaqus.vim create mode 100644 syntax/abc.vim create mode 100644 syntax/abel.vim create mode 100644 syntax/acedb.vim create mode 100644 syntax/ada.vim create mode 100644 syntax/aflex.vim create mode 100644 syntax/ahdl.vim create mode 100644 syntax/alsaconf.vim create mode 100644 syntax/amiga.vim create mode 100644 syntax/aml.vim create mode 100644 syntax/ampl.vim create mode 100644 syntax/ant.vim create mode 100644 syntax/antlr.vim create mode 100644 syntax/apache.vim create mode 100644 syntax/apachestyle.vim create mode 100644 syntax/aptconf.vim create mode 100644 syntax/arch.vim create mode 100644 syntax/art.vim create mode 100644 syntax/asm.vim create mode 100644 syntax/asm68k.vim create mode 100644 syntax/asmh8300.vim create mode 100644 syntax/asn.vim create mode 100644 syntax/aspperl.vim create mode 100644 syntax/aspvbs.vim create mode 100644 syntax/asterisk.vim create mode 100644 syntax/asteriskvm.vim create mode 100644 syntax/atlas.vim create mode 100644 syntax/autohotkey.vim create mode 100644 syntax/autoit.vim create mode 100644 syntax/automake.vim create mode 100644 syntax/ave.vim create mode 100644 syntax/avra.vim create mode 100644 syntax/awk.vim create mode 100644 syntax/ayacc.vim create mode 100644 syntax/b.vim create mode 100644 syntax/baan.vim create mode 100644 syntax/basic.vim create mode 100644 syntax/bc.vim create mode 100644 syntax/bdf.vim create mode 100644 syntax/bib.vim create mode 100644 syntax/bindzone.vim create mode 100644 syntax/blank.vim create mode 100644 syntax/bst.vim create mode 100644 syntax/btm.vim create mode 100644 syntax/bzl.vim create mode 100644 syntax/bzr.vim create mode 100644 syntax/calendar.vim create mode 100644 syntax/catalog.vim create mode 100644 syntax/cdl.vim create mode 100644 syntax/cdrdaoconf.vim create mode 100644 syntax/cdrtoc.vim create mode 100644 syntax/cf.vim create mode 100644 syntax/cfg.vim create mode 100644 syntax/ch.vim create mode 100644 syntax/chaiscript.vim create mode 100644 syntax/change.vim create mode 100644 syntax/changelog.vim create mode 100644 syntax/chaskell.vim create mode 100644 syntax/cheetah.vim create mode 100644 syntax/chill.vim create mode 100644 syntax/chordpro.vim create mode 100644 syntax/cl.vim create mode 100644 syntax/clean.vim create mode 100644 syntax/clipper.vim create mode 100644 syntax/cmake.vim create mode 100644 syntax/cmusrc.vim create mode 100644 syntax/cobol.vim create mode 100644 syntax/coco.vim create mode 100644 syntax/colortest.vim create mode 100644 syntax/conaryrecipe.vim create mode 100644 syntax/conf.vim create mode 100644 syntax/config.vim create mode 100644 syntax/context.vim create mode 100644 syntax/crm.vim create mode 100644 syntax/crontab.vim create mode 100644 syntax/cs.vim create mode 100644 syntax/csc.vim create mode 100644 syntax/csdl.vim create mode 100644 syntax/csh.vim create mode 100644 syntax/csp.vim create mode 100644 syntax/cterm.vim create mode 100644 syntax/ctrlh.vim create mode 100644 syntax/cuda.vim create mode 100644 syntax/cupl.vim create mode 100644 syntax/cuplsim.vim create mode 100644 syntax/cvs.vim create mode 100644 syntax/cvsrc.vim create mode 100644 syntax/cweb.vim create mode 100644 syntax/cynlib.vim create mode 100644 syntax/cynpp.vim create mode 100644 syntax/d.vim create mode 100644 syntax/datascript.vim create mode 100644 syntax/dcd.vim create mode 100644 syntax/dcl.vim create mode 100644 syntax/debchangelog.vim create mode 100644 syntax/debcontrol.vim create mode 100644 syntax/debsources.vim create mode 100644 syntax/def.vim create mode 100644 syntax/denyhosts.vim create mode 100644 syntax/desc.vim create mode 100644 syntax/desktop.vim create mode 100644 syntax/dictconf.vim create mode 100644 syntax/dictdconf.vim create mode 100644 syntax/diff.vim create mode 100644 syntax/dircolors.vim create mode 100644 syntax/dirpager.vim create mode 100644 syntax/diva.vim create mode 100644 syntax/django.vim create mode 100644 syntax/dns.vim create mode 100644 syntax/dnsmasq.vim create mode 100644 syntax/docbk.vim create mode 100644 syntax/docbksgml.vim create mode 100644 syntax/docbkxml.vim create mode 100644 syntax/dosbatch.vim create mode 100644 syntax/dosini.vim create mode 100644 syntax/dot.vim create mode 100644 syntax/doxygen.vim create mode 100644 syntax/dracula.vim create mode 100644 syntax/dsl.vim create mode 100644 syntax/dtd.vim create mode 100644 syntax/dtml.vim create mode 100644 syntax/dtrace.vim create mode 100644 syntax/dts.vim create mode 100644 syntax/dylan.vim create mode 100644 syntax/dylanintr.vim create mode 100644 syntax/dylanlid.vim create mode 100644 syntax/ecd.vim create mode 100644 syntax/edif.vim create mode 100644 syntax/eiffel.vim create mode 100644 syntax/elf.vim create mode 100644 syntax/elinks.vim create mode 100644 syntax/elmfilt.vim create mode 100644 syntax/esmtprc.vim create mode 100644 syntax/esqlc.vim create mode 100644 syntax/esterel.vim create mode 100644 syntax/eterm.vim create mode 100644 syntax/euphoria3.vim create mode 100644 syntax/euphoria4.vim create mode 100644 syntax/eviews.vim create mode 100644 syntax/exim.vim create mode 100644 syntax/expect.vim create mode 100644 syntax/exports.vim create mode 100644 syntax/falcon.vim create mode 100644 syntax/fan.vim create mode 100644 syntax/fasm.vim create mode 100644 syntax/fdcc.vim create mode 100644 syntax/fetchmail.vim create mode 100644 syntax/fgl.vim create mode 100644 syntax/flexwiki.vim create mode 100644 syntax/focexec.vim create mode 100644 syntax/form.vim create mode 100644 syntax/forth.vim create mode 100644 syntax/fortran.vim create mode 100644 syntax/foxpro.vim create mode 100644 syntax/framescript.vim create mode 100644 syntax/freebasic.vim create mode 100644 syntax/fstab.vim create mode 100644 syntax/fvwm.vim create mode 100644 syntax/fvwm2m4.vim create mode 100644 syntax/gdb.vim create mode 100644 syntax/gdmo.vim create mode 100644 syntax/gedcom.vim create mode 100644 syntax/gitolite.vim create mode 100644 syntax/gkrellmrc.vim create mode 100644 syntax/gnash.vim create mode 100644 syntax/godoc.vim create mode 100644 syntax/gp.vim create mode 100644 syntax/gpg.vim create mode 100644 syntax/gprof.vim create mode 100644 syntax/grads.vim create mode 100644 syntax/gretl.vim create mode 100644 syntax/groff.vim create mode 100644 syntax/group.vim create mode 100644 syntax/grub.vim create mode 100644 syntax/gsp.vim create mode 100644 syntax/gtkrc.vim create mode 100644 syntax/hamster.vim create mode 100644 syntax/haste.vim create mode 100644 syntax/hastepreproc.vim create mode 100644 syntax/hb.vim create mode 100644 syntax/help.vim create mode 100644 syntax/hercules.vim create mode 100644 syntax/hex.vim create mode 100644 syntax/hgcommit.vim create mode 100644 syntax/hitest.vim create mode 100644 syntax/hog.vim create mode 100644 syntax/hostconf.vim create mode 100644 syntax/hostsaccess.vim create mode 100644 syntax/htmlcheetah.vim create mode 100644 syntax/htmldjango.vim create mode 100644 syntax/htmlm4.vim create mode 100644 syntax/htmlos.vim create mode 100644 syntax/ia64.vim create mode 100644 syntax/ibasic.vim create mode 100644 syntax/icemenu.vim create mode 100644 syntax/icon.vim create mode 100644 syntax/idl.vim create mode 100644 syntax/idlang.vim create mode 100644 syntax/indent.vim create mode 100644 syntax/inform.vim create mode 100644 syntax/initex.vim create mode 100644 syntax/initng.vim create mode 100644 syntax/inittab.vim create mode 100644 syntax/ipfilter.vim create mode 100644 syntax/ishd.vim create mode 100644 syntax/iss.vim create mode 100644 syntax/ist.vim create mode 100644 syntax/j.vim create mode 100644 syntax/jal.vim create mode 100644 syntax/jam.vim create mode 100644 syntax/jargon.vim create mode 100644 syntax/java.vim create mode 100644 syntax/javacc.vim create mode 100644 syntax/jess.vim create mode 100644 syntax/jgraph.vim create mode 100644 syntax/jovial.vim create mode 100644 syntax/jproperties.vim create mode 100644 syntax/jsp.vim create mode 100644 syntax/kconfig.vim create mode 100644 syntax/kivy.vim create mode 100644 syntax/kix.vim create mode 100644 syntax/kscript.vim create mode 100644 syntax/kwt.vim create mode 100644 syntax/lace.vim create mode 100644 syntax/latte.vim create mode 100644 syntax/ld.vim create mode 100644 syntax/ldapconf.vim create mode 100644 syntax/ldif.vim create mode 100644 syntax/lex.vim create mode 100644 syntax/lftp.vim create mode 100644 syntax/lhaskell.vim create mode 100644 syntax/libao.vim create mode 100644 syntax/lifelines.vim create mode 100644 syntax/lilo.vim create mode 100644 syntax/limits.vim create mode 100644 syntax/lisp.vim create mode 100644 syntax/lite.vim create mode 100644 syntax/litestep.vim create mode 100644 syntax/loginaccess.vim create mode 100644 syntax/logindefs.vim create mode 100644 syntax/logtalk.vim create mode 100644 syntax/lotos.vim create mode 100644 syntax/lout.vim create mode 100644 syntax/lpc.vim create mode 100644 syntax/lprolog.vim create mode 100644 syntax/lscript.vim create mode 100644 syntax/lsl.vim create mode 100644 syntax/lss.vim create mode 100644 syntax/lynx.vim create mode 100644 syntax/m4.vim create mode 100644 syntax/mail.vim create mode 100644 syntax/mailaliases.vim create mode 100644 syntax/mailcap.vim create mode 100644 syntax/make.vim create mode 100644 syntax/mallard.vim create mode 100644 syntax/man.vim create mode 100644 syntax/manconf.vim create mode 100644 syntax/manual.vim create mode 100644 syntax/maple.vim create mode 100644 syntax/masm.vim create mode 100644 syntax/master.vim create mode 100644 syntax/matlab.vim create mode 100644 syntax/maxima.vim create mode 100644 syntax/mel.vim create mode 100644 syntax/messages.vim create mode 100644 syntax/mf.vim create mode 100644 syntax/mgl.vim create mode 100644 syntax/mgp.vim create mode 100644 syntax/mib.vim create mode 100644 syntax/mix.vim create mode 100644 syntax/mmix.vim create mode 100644 syntax/mmp.vim create mode 100644 syntax/modconf.vim create mode 100644 syntax/model.vim create mode 100644 syntax/modsim3.vim create mode 100644 syntax/modula2.vim create mode 100644 syntax/modula3.vim create mode 100644 syntax/monk.vim create mode 100644 syntax/moo.vim create mode 100644 syntax/mp.vim create mode 100644 syntax/mplayerconf.vim create mode 100644 syntax/mrxvtrc.vim create mode 100644 syntax/msidl.vim create mode 100644 syntax/msmessages.vim create mode 100644 syntax/msql.vim create mode 100644 syntax/mupad.vim create mode 100644 syntax/murphi.vim create mode 100644 syntax/mush.vim create mode 100644 syntax/muttrc.vim create mode 100644 syntax/mysql.vim create mode 100644 syntax/n1ql.vim create mode 100644 syntax/named.vim create mode 100644 syntax/nanorc.vim create mode 100644 syntax/nasm.vim create mode 100644 syntax/nastran.vim create mode 100644 syntax/natural.vim create mode 100644 syntax/ncf.vim create mode 100644 syntax/netrc.vim create mode 100644 syntax/netrw.vim create mode 100644 syntax/ninja.vim create mode 100644 syntax/nosyntax.vim create mode 100644 syntax/nqc.vim create mode 100644 syntax/nroff.vim create mode 100644 syntax/nsis.vim create mode 100644 syntax/obj.vim create mode 100644 syntax/objc.vim create mode 100644 syntax/objcpp.vim create mode 100644 syntax/occam.vim create mode 100644 syntax/omnimark.vim create mode 100644 syntax/openroad.vim create mode 100644 syntax/opl.vim create mode 100644 syntax/ora.vim create mode 100644 syntax/pamconf.vim create mode 100644 syntax/papp.vim create mode 100644 syntax/pascal.vim create mode 100644 syntax/passwd.vim create mode 100644 syntax/pcap.vim create mode 100644 syntax/pccts.vim create mode 100644 syntax/pdf.vim create mode 100644 syntax/perl6.vim create mode 100644 syntax/pf.vim create mode 100644 syntax/pfmain.vim create mode 100644 syntax/phtml.vim create mode 100644 syntax/pic.vim create mode 100644 syntax/pike.vim create mode 100644 syntax/pilrc.vim create mode 100644 syntax/pine.vim create mode 100644 syntax/pinfo.vim create mode 100644 syntax/plaintex.vim create mode 100644 syntax/pli.vim create mode 100644 syntax/plm.vim create mode 100644 syntax/plp.vim create mode 100644 syntax/plsql.vim create mode 100644 syntax/po.vim create mode 100644 syntax/postscr.vim create mode 100644 syntax/pov.vim create mode 100644 syntax/povini.vim create mode 100644 syntax/ppd.vim create mode 100644 syntax/ppwiz.vim create mode 100644 syntax/prescribe.vim create mode 100644 syntax/privoxy.vim create mode 100644 syntax/procmail.vim create mode 100644 syntax/progress.vim create mode 100644 syntax/prolog.vim create mode 100644 syntax/promela.vim create mode 100644 syntax/protocols.vim create mode 100644 syntax/psf.vim create mode 100644 syntax/ptcap.vim create mode 100644 syntax/purifylog.vim create mode 100644 syntax/pyrex.vim create mode 100644 syntax/qf.vim create mode 100644 syntax/quake.vim create mode 100644 syntax/r.vim create mode 100644 syntax/racc.vim create mode 100644 syntax/radiance.vim create mode 100644 syntax/ratpoison.vim create mode 100644 syntax/rc.vim create mode 100644 syntax/rcs.vim create mode 100644 syntax/rcslog.vim create mode 100644 syntax/readline.vim create mode 100644 syntax/rebol.vim create mode 100644 syntax/redif.vim create mode 100644 syntax/registry.vim create mode 100644 syntax/remind.vim create mode 100644 syntax/resolv.vim create mode 100644 syntax/reva.vim create mode 100644 syntax/rexx.vim create mode 100644 syntax/rib.vim create mode 100644 syntax/rmd.vim create mode 100644 syntax/rnc.vim create mode 100644 syntax/rng.vim create mode 100644 syntax/robots.vim create mode 100644 syntax/rpcgen.vim create mode 100644 syntax/rpl.vim create mode 100644 syntax/rrst.vim create mode 100644 syntax/rst.vim create mode 100644 syntax/rtf.vim create mode 100644 syntax/samba.vim create mode 100644 syntax/sas.vim create mode 100644 syntax/sass.vim create mode 100644 syntax/sather.vim create mode 100644 syntax/scheme.vim create mode 100644 syntax/scilab.vim create mode 100644 syntax/screen.vim create mode 100644 syntax/sd.vim create mode 100644 syntax/sdc.vim create mode 100644 syntax/sdl.vim create mode 100644 syntax/sed.vim create mode 100644 syntax/sendpr.vim create mode 100644 syntax/sensors.vim create mode 100644 syntax/services.vim create mode 100644 syntax/setserial.vim create mode 100644 syntax/sgml.vim create mode 100644 syntax/sgmldecl.vim create mode 100644 syntax/sgmllnx.vim create mode 100644 syntax/sh.vim create mode 100644 syntax/sicad.vim create mode 100644 syntax/sieve.vim create mode 100644 syntax/simula.vim create mode 100644 syntax/sinda.vim create mode 100644 syntax/sindacmp.vim create mode 100644 syntax/sindaout.vim create mode 100644 syntax/sisu.vim create mode 100644 syntax/skill.vim create mode 100644 syntax/sl.vim create mode 100644 syntax/slang.vim create mode 100644 syntax/slice.vim create mode 100644 syntax/slpconf.vim create mode 100644 syntax/slpreg.vim create mode 100644 syntax/slpspi.vim create mode 100644 syntax/slrnrc.vim create mode 100644 syntax/slrnsc.vim create mode 100644 syntax/sm.vim create mode 100644 syntax/smarty.vim create mode 100644 syntax/smcl.vim create mode 100644 syntax/smil.vim create mode 100644 syntax/smith.vim create mode 100644 syntax/sml.vim create mode 100644 syntax/snnsnet.vim create mode 100644 syntax/snnspat.vim create mode 100644 syntax/snnsres.vim create mode 100644 syntax/snobol4.vim create mode 100644 syntax/spec.vim create mode 100644 syntax/specman.vim create mode 100644 syntax/spice.vim create mode 100644 syntax/splint.vim create mode 100644 syntax/spup.vim create mode 100644 syntax/spyce.vim create mode 100644 syntax/sql.vim create mode 100644 syntax/sqlanywhere.vim create mode 100644 syntax/sqlforms.vim create mode 100644 syntax/sqlhana.vim create mode 100644 syntax/sqlinformix.vim create mode 100644 syntax/sqlj.vim create mode 100644 syntax/sqloracle.vim create mode 100644 syntax/sqr.vim create mode 100644 syntax/squid.vim create mode 100644 syntax/srec.vim create mode 100644 syntax/sshconfig.vim create mode 100644 syntax/sshdconfig.vim create mode 100644 syntax/st.vim create mode 100644 syntax/stata.vim create mode 100644 syntax/stp.vim create mode 100644 syntax/strace.vim create mode 100644 syntax/sudoers.vim create mode 100644 syntax/svg.vim create mode 100644 syntax/svn.vim create mode 100644 syntax/syncolor.vim create mode 100644 syntax/synload.vim create mode 100644 syntax/syntax.vim create mode 100644 syntax/sysctl.vim create mode 100644 syntax/systemverilog.vim create mode 100644 syntax/tads.vim create mode 100644 syntax/tags.vim create mode 100644 syntax/tak.vim create mode 100644 syntax/takcmp.vim create mode 100644 syntax/takout.vim create mode 100644 syntax/tar.vim create mode 100644 syntax/taskdata.vim create mode 100644 syntax/taskedit.vim create mode 100644 syntax/tasm.vim create mode 100644 syntax/tcl.vim create mode 100644 syntax/tcsh.vim create mode 100644 syntax/teraterm.vim create mode 100644 syntax/terminfo.vim create mode 100644 syntax/tex.vim create mode 100644 syntax/texinfo.vim create mode 100644 syntax/texmf.vim create mode 100644 syntax/tf.vim create mode 100644 syntax/tidy.vim create mode 100644 syntax/tilde.vim create mode 100644 syntax/tli.vim create mode 100644 syntax/tpp.vim create mode 100644 syntax/trasys.vim create mode 100644 syntax/treetop.vim create mode 100644 syntax/trustees.vim create mode 100644 syntax/tsalt.vim create mode 100644 syntax/tsscl.vim create mode 100644 syntax/tssgm.vim create mode 100644 syntax/tssop.vim create mode 100644 syntax/uc.vim create mode 100644 syntax/udevconf.vim create mode 100644 syntax/udevperm.vim create mode 100644 syntax/udevrules.vim create mode 100644 syntax/uil.vim create mode 100644 syntax/updatedb.vim create mode 100644 syntax/upstart.vim create mode 100644 syntax/upstreamdat.vim create mode 100644 syntax/upstreaminstalllog.vim create mode 100644 syntax/upstreamlog.vim create mode 100644 syntax/upstreamrpt.vim create mode 100644 syntax/usserverlog.vim create mode 100644 syntax/usw2kagtlog.vim create mode 100644 syntax/valgrind.vim create mode 100644 syntax/vb.vim create mode 100644 syntax/vera.vim create mode 100644 syntax/verilog.vim create mode 100644 syntax/verilogams.vim create mode 100644 syntax/vgrindefs.vim create mode 100644 syntax/vhdl.vim create mode 100644 syntax/vim.vim create mode 100644 syntax/viminfo.vim create mode 100644 syntax/virata.vim create mode 100644 syntax/vmasm.vim create mode 100644 syntax/voscm.vim create mode 100644 syntax/vrml.vim create mode 100644 syntax/vroom.vim create mode 100644 syntax/vsejcl.vim create mode 100644 syntax/wdiff.vim create mode 100644 syntax/web.vim create mode 100644 syntax/webmacro.vim create mode 100644 syntax/wget.vim create mode 100644 syntax/whitespace.vim create mode 100644 syntax/winbatch.vim create mode 100644 syntax/wml.vim create mode 100644 syntax/wsh.vim create mode 100644 syntax/wsml.vim create mode 100644 syntax/wvdial.vim create mode 100644 syntax/xbl.vim create mode 100644 syntax/xdefaults.vim create mode 100644 syntax/xf86conf.vim create mode 100644 syntax/xhtml.vim create mode 100644 syntax/xinetd.vim create mode 100644 syntax/xkb.vim create mode 100644 syntax/xmath.vim create mode 100644 syntax/xml.vim create mode 100644 syntax/xmodmap.vim create mode 100644 syntax/xpm.vim create mode 100644 syntax/xpm2.vim create mode 100644 syntax/xquery.vim create mode 100644 syntax/xsd.vim create mode 100644 syntax/xslt.vim create mode 100644 syntax/xxd.vim create mode 100644 syntax/yacc.vim create mode 100644 syntax/yaml.vim create mode 100644 syntax/z8a.vim create mode 100644 syntax/zimbu.vim create mode 100644 syntax/zsh.vim diff --git a/README.md b/README.md index ae44610..4397cfa 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,10 @@ NOTE: Not all features of listed language packs are available. We strip them fro If you need full functionality of any plugin, please use it directly with your plugin manager. +## Basic language pack + +Most importantly, vim-polyglot contains all runtime syntax files from upstream [vim](https://github.com/vim/vim) repository, plus: + ## Language packs - [ansible](https://github.com/pearofducks/ansible-vim) (syntax, indent, ftplugin) @@ -52,7 +56,6 @@ If you need full functionality of any plugin, please use it directly with your p - [cql](https://github.com/elubow/cql-vim) (syntax) - [cryptol](https://github.com/victoredwardocallaghan/cryptol.vim) (syntax, compiler, ftplugin) - [crystal](https://github.com/rhysd/vim-crystal) (syntax, indent, autoload, ftplugin) -- [css](https://github.com/JulesWang/css.vim) (syntax) - [cucumber](https://github.com/tpope/vim-cucumber) (syntax, indent, compiler, ftplugin) - [dart](https://github.com/dart-lang/dart-vim-plugin) (syntax, indent, autoload, ftplugin) - [dockerfile](https://github.com/docker/docker) (syntax) @@ -139,6 +142,7 @@ If you need full functionality of any plugin, please use it directly with your p - [vbnet](https://github.com/vim-scripts/vbnet.vim) (syntax) - [vcl](https://github.com/smerrill/vcl-vim-plugin) (syntax) - [vifm](https://github.com/vifm/vifm.vim) (syntax, autoload, ftplugin) +- [vim](https://github.com/vim/vim) (syntax, indent, compiler, autoload, ftplugin) - [vm](https://github.com/lepture/vim-velocity) (syntax, indent) - [vue](https://github.com/posva/vim-vue) (syntax, indent, ftplugin) - [xls](https://github.com/vim-scripts/XSLT-syntax) (syntax) diff --git a/autoload/ada.vim b/autoload/ada.vim new file mode 100644 index 0000000..c62db2b --- /dev/null +++ b/autoload/ada.vim @@ -0,0 +1,641 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +"------------------------------------------------------------------------------ +" Description: Perform Ada specific completion & tagging. +" Language: Ada (2005) +" $Id: ada.vim 887 2008-07-08 14:29:01Z krischik $ +" Maintainer: Mathias Brousset +" Martin Krischik +" Taylor Venable +" Neil Bird +" Ned Okie +" $Author: krischik $ +" $Date: 2017-01-31 20:20:05 +0200 (Mon, 01 Jan 2017) $ +" Version: 4.6 +" $Revision: 887 $ +" $HeadURL: https://gnuada.svn.sourceforge.net/svnroot/gnuada/trunk/tools/vim/autoload/ada.vim $ +" History: 24.05.2006 MK Unified Headers +" 26.05.2006 MK ' should not be in iskeyword. +" 16.07.2006 MK Ada-Mode as vim-ball +" 02.10.2006 MK Better folding. +" 15.10.2006 MK Bram's suggestion for runtime integration +" 05.11.2006 MK Bram suggested not to use include protection for +" autoload +" 05.11.2006 MK Bram suggested to save on spaces +" 08.07.2007 TV fix mapleader problems. +" 09.05.2007 MK Session just won't work no matter how much +" tweaking is done +" 19.09.2007 NO still some mapleader problems +" 31.01.2017 MB fix more mapleader problems +" Help Page: ft-ada-functions +"------------------------------------------------------------------------------ + +if version < 700 + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +" Section: Constants {{{1 +" +let g:ada#DotWordRegex = '\a\w*\(\_s*\.\_s*\a\w*\)*' +let g:ada#WordRegex = '\a\w*' +let g:ada#Comment = "\\v^(\"[^\"]*\"|'.'|[^\"']){-}\\zs\\s*--.*" +let g:ada#Keywords = [] + +" Section: g:ada#Keywords {{{1 +" +" Section: add Ada keywords {{{2 +" +for Item in ['abort', 'else', 'new', 'return', 'abs', 'elsif', 'not', 'reverse', 'abstract', 'end', 'null', 'accept', 'entry', 'select', 'access', 'exception', 'of', 'separate', 'aliased', 'exit', 'or', 'subtype', 'all', 'others', 'synchronized', 'and', 'for', 'out', 'array', 'function', 'overriding', 'tagged', 'at', 'task', 'generic', 'package', 'terminate', 'begin', 'goto', 'pragma', 'then', 'body', 'private', 'type', 'if', 'procedure', 'case', 'in', 'protected', 'until', 'constant', 'interface', 'use', 'is', 'raise', 'declare', 'range', 'when', 'delay', 'limited', 'record', 'while', 'delta', 'loop', 'rem', 'with', 'digits', 'renames', 'do', 'mod', 'requeue', 'xor'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'keyword', + \ 'info': 'Ada keyword.', + \ 'kind': 'k', + \ 'icase': 1}] +endfor + +" Section: GNAT Project Files {{{3 +" +if exists ('g:ada_with_gnat_project_files') + for Item in ['project'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'keyword', + \ 'info': 'GNAT projectfile keyword.', + \ 'kind': 'k', + \ 'icase': 1}] + endfor +endif + +" Section: add standart exception {{{2 +" +for Item in ['Constraint_Error', 'Program_Error', 'Storage_Error', 'Tasking_Error', 'Status_Error', 'Mode_Error', 'Name_Error', 'Use_Error', 'Device_Error', 'End_Error', 'Data_Error', 'Layout_Error', 'Length_Error', 'Pattern_Error', 'Index_Error', 'Translation_Error', 'Time_Error', 'Argument_Error', 'Tag_Error', 'Picture_Error', 'Terminator_Error', 'Conversion_Error', 'Pointer_Error', 'Dereference_Error', 'Update_Error'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'exception', + \ 'info': 'Ada standart exception.', + \ 'kind': 'x', + \ 'icase': 1}] +endfor + +" Section: add GNAT exception {{{3 +" +if exists ('g:ada_gnat_extensions') + for Item in ['Assert_Failure'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'exception', + \ 'info': 'GNAT exception.', + \ 'kind': 'x', + \ 'icase': 1}] + endfor +endif + +" Section: add Ada buildin types {{{2 +" +for Item in ['Boolean', 'Integer', 'Natural', 'Positive', 'Float', 'Character', 'Wide_Character', 'Wide_Wide_Character', 'String', 'Wide_String', 'Wide_Wide_String', 'Duration'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'type', + \ 'info': 'Ada buildin type.', + \ 'kind': 't', + \ 'icase': 1}] +endfor + +" Section: add GNAT buildin types {{{3 +" +if exists ('g:ada_gnat_extensions') + for Item in ['Short_Integer', 'Short_Short_Integer', 'Long_Integer', 'Long_Long_Integer', 'Short_Float', 'Short_Short_Float', 'Long_Float', 'Long_Long_Float'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'type', + \ 'info': 'GNAT buildin type.', + \ 'kind': 't', + \ 'icase': 1}] + endfor +endif + +" Section: add Ada Attributes {{{2 +" +for Item in ['''Access', '''Address', '''Adjacent', '''Aft', '''Alignment', '''Base', '''Bit_Order', '''Body_Version', '''Callable', '''Caller', '''Ceiling', '''Class', '''Component_Size', '''Compose', '''Constrained', '''Copy_Sign', '''Count', '''Definite', '''Delta', '''Denorm', '''Digits', '''Emax', '''Exponent', '''External_Tag', '''Epsilon', '''First', '''First_Bit', '''Floor', '''Fore', '''Fraction', '''Identity', '''Image', '''Input', '''Large', '''Last', '''Last_Bit', '''Leading_Part', '''Length', '''Machine', '''Machine_Emax', '''Machine_Emin', '''Machine_Mantissa', '''Machine_Overflows', '''Machine_Radix', '''Machine_Rounding', '''Machine_Rounds', '''Mantissa', '''Max', '''Max_Size_In_Storage_Elements', '''Min', '''Mod', '''Model', '''Model_Emin', '''Model_Epsilon', '''Model_Mantissa', '''Model_Small', '''Modulus', '''Output', '''Partition_ID', '''Pos', '''Position', '''Pred', '''Priority', '''Range', '''Read', '''Remainder', '''Round', '''Rounding', '''Safe_Emax', '''Safe_First', '''Safe_Large', '''Safe_Last', '''Safe_Small', '''Scale', '''Scaling', '''Signed_Zeros', '''Size', '''Small', '''Storage_Pool', '''Storage_Size', '''Stream_Size', '''Succ', '''Tag', '''Terminated', '''Truncation', '''Unbiased_Rounding', '''Unchecked_Access', '''Val', '''Valid', '''Value', '''Version', '''Wide_Image', '''Wide_Value', '''Wide_Wide_Image', '''Wide_Wide_Value', '''Wide_Wide_Width', '''Wide_Width', '''Width', '''Write'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'attribute', + \ 'info': 'Ada attribute.', + \ 'kind': 'a', + \ 'icase': 1}] +endfor + +" Section: add GNAT Attributes {{{3 +" +if exists ('g:ada_gnat_extensions') + for Item in ['''Abort_Signal', '''Address_Size', '''Asm_Input', '''Asm_Output', '''AST_Entry', '''Bit', '''Bit_Position', '''Code_Address', '''Default_Bit_Order', '''Elaborated', '''Elab_Body', '''Elab_Spec', '''Emax', '''Enum_Rep', '''Epsilon', '''Fixed_Value', '''Has_Access_Values', '''Has_Discriminants', '''Img', '''Integer_Value', '''Machine_Size', '''Max_Interrupt_Priority', '''Max_Priority', '''Maximum_Alignment', '''Mechanism_Code', '''Null_Parameter', '''Object_Size', '''Passed_By_Reference', '''Range_Length', '''Storage_Unit', '''Target_Name', '''Tick', '''To_Address', '''Type_Class', '''UET_Address', '''Unconstrained_Array', '''Universal_Literal_String', '''Unrestricted_Access', '''VADS_Size', '''Value_Size', '''Wchar_T_Size', '''Word_Size'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'attribute', + \ 'info': 'GNAT attribute.', + \ 'kind': 'a', + \ 'icase': 1}] + endfor +endif + +" Section: add Ada Pragmas {{{2 +" +for Item in ['All_Calls_Remote', 'Assert', 'Assertion_Policy', 'Asynchronous', 'Atomic', 'Atomic_Components', 'Attach_Handler', 'Controlled', 'Convention', 'Detect_Blocking', 'Discard_Names', 'Elaborate', 'Elaborate_All', 'Elaborate_Body', 'Export', 'Import', 'Inline', 'Inspection_Point', 'Interface (Obsolescent)', 'Interrupt_Handler', 'Interrupt_Priority', 'Linker_Options', 'List', 'Locking_Policy', 'Memory_Size (Obsolescent)', 'No_Return', 'Normalize_Scalars', 'Optimize', 'Pack', 'Page', 'Partition_Elaboration_Policy', 'Preelaborable_Initialization', 'Preelaborate', 'Priority', 'Priority_Specific_Dispatching', 'Profile', 'Pure', 'Queueing_Policy', 'Relative_Deadline', 'Remote_Call_Interface', 'Remote_Types', 'Restrictions', 'Reviewable', 'Shared (Obsolescent)', 'Shared_Passive', 'Storage_Size', 'Storage_Unit (Obsolescent)', 'Suppress', 'System_Name (Obsolescent)', 'Task_Dispatching_Policy', 'Unchecked_Union', 'Unsuppress', 'Volatile', 'Volatile_Components'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'pragma', + \ 'info': 'Ada pragma.', + \ 'kind': 'p', + \ 'icase': 1}] +endfor + +" Section: add GNAT Pragmas {{{3 +" +if exists ('g:ada_gnat_extensions') + for Item in ['Abort_Defer', 'Ada_83', 'Ada_95', 'Ada_05', 'Annotate', 'Ast_Entry', 'C_Pass_By_Copy', 'Comment', 'Common_Object', 'Compile_Time_Warning', 'Complex_Representation', 'Component_Alignment', 'Convention_Identifier', 'CPP_Class', 'CPP_Constructor', 'CPP_Virtual', 'CPP_Vtable', 'Debug', 'Elaboration_Checks', 'Eliminate', 'Export_Exception', 'Export_Function', 'Export_Object', 'Export_Procedure', 'Export_Value', 'Export_Valued_Procedure', 'Extend_System', 'External', 'External_Name_Casing', 'Finalize_Storage_Only', 'Float_Representation', 'Ident', 'Import_Exception', 'Import_Function', 'Import_Object', 'Import_Procedure', 'Import_Valued_Procedure', 'Initialize_Scalars', 'Inline_Always', 'Inline_Generic', 'Interface_Name', 'Interrupt_State', 'Keep_Names', 'License', 'Link_With', 'Linker_Alias', 'Linker_Section', 'Long_Float', 'Machine_Attribute', 'Main_Storage', 'Obsolescent', 'Passive', 'Polling', 'Profile_Warnings', 'Propagate_Exceptions', 'Psect_Object', 'Pure_Function', 'Restriction_Warnings', 'Source_File_Name', 'Source_File_Name_Project', 'Source_Reference', 'Stream_Convert', 'Style_Checks', 'Subtitle', 'Suppress_All', 'Suppress_Exception_Locations', 'Suppress_Initialization', 'Task_Info', 'Task_Name', 'Task_Storage', 'Thread_Body', 'Time_Slice', 'Title', 'Unimplemented_Unit', 'Universal_Data', 'Unreferenced', 'Unreserve_All_Interrupts', 'Use_VADS_Size', 'Validity_Checks', 'Warnings', 'Weak_External'] + let g:ada#Keywords += [{ + \ 'word': Item, + \ 'menu': 'pragma', + \ 'info': 'GNAT pragma.', + \ 'kind': 'p', + \ 'icase': 1}] + endfor +endif +" 1}}} + +" Section: g:ada#Ctags_Kinds {{{1 +" +let g:ada#Ctags_Kinds = { + \ 'P': ["packspec", "package specifications"], + \ 'p': ["package", "packages"], + \ 'T': ["typespec", "type specifications"], + \ 't': ["type", "types"], + \ 'U': ["subspec", "subtype specifications"], + \ 'u': ["subtype", "subtypes"], + \ 'c': ["component", "record type components"], + \ 'l': ["literal", "enum type literals"], + \ 'V': ["varspec", "variable specifications"], + \ 'v': ["variable", "variables"], + \ 'f': ["formal", "generic formal parameters"], + \ 'n': ["constant", "constants"], + \ 'x': ["exception", "user defined exceptions"], + \ 'R': ["subprogspec", "subprogram specifications"], + \ 'r': ["subprogram", "subprograms"], + \ 'K': ["taskspec", "task specifications"], + \ 'k': ["task", "tasks"], + \ 'O': ["protectspec", "protected data specifications"], + \ 'o': ["protected", "protected data"], + \ 'E': ["entryspec", "task/protected data entry specifications"], + \ 'e': ["entry", "task/protected data entries"], + \ 'b': ["label", "labels"], + \ 'i': ["identifier", "loop/declare identifiers"], + \ 'a': ["autovar", "automatic variables"], + \ 'y': ["annon", "loops and blocks with no identifier"]} + +" Section: ada#Word (...) {{{1 +" +" Extract current Ada word across multiple lines +" AdaWord ([line, column])\ +" +function ada#Word (...) + if a:0 > 1 + let l:Line_Nr = a:1 + let l:Column_Nr = a:2 - 1 + else + let l:Line_Nr = line('.') + let l:Column_Nr = col('.') - 1 + endif + + let l:Line = substitute (getline (l:Line_Nr), g:ada#Comment, '', '' ) + + " Cope with tag searching for items in comments; if we are, don't loop + " backards looking for previous lines + if l:Column_Nr > strlen(l:Line) + " We were in a comment + let l:Line = getline(l:Line_Nr) + let l:Search_Prev_Lines = 0 + else + let l:Search_Prev_Lines = 1 + endif + + " Go backwards until we find a match (Ada ID) that *doesn't* include our + " location - i.e., the previous ID. This is because the current 'correct' + " match will toggle matching/not matching as we traverse characters + " backwards. Thus, we have to find the previous unrelated match, exclude + " it, then use the next full match (ours). + " Remember to convert vim column 'l:Column_Nr' [1..n] to string offset [0..(n-1)] + " ... but start, here, one after the required char. + let l:New_Column = l:Column_Nr + 1 + while 1 + let l:New_Column = l:New_Column - 1 + if l:New_Column < 0 + " Have to include previous l:Line from file + let l:Line_Nr = l:Line_Nr - 1 + if l:Line_Nr < 1 || !l:Search_Prev_Lines + " Start of file or matching in a comment + let l:Line_Nr = 1 + let l:New_Column = 0 + let l:Our_Match = match (l:Line, g:ada#WordRegex ) + break + endif + " Get previous l:Line, and prepend it to our search string + let l:New_Line = substitute (getline (l:Line_Nr), g:ada#Comment, '', '' ) + let l:New_Column = strlen (l:New_Line) - 1 + let l:Column_Nr = l:Column_Nr + l:New_Column + let l:Line = l:New_Line . l:Line + endif + " Check to see if this is a match excluding 'us' + let l:Match_End = l:New_Column + + \ matchend (strpart (l:Line,l:New_Column), g:ada#WordRegex ) - 1 + if l:Match_End >= l:New_Column && + \ l:Match_End < l:Column_Nr + " Yes + let l:Our_Match = l:Match_End+1 + + \ match (strpart (l:Line,l:Match_End+1), g:ada#WordRegex ) + break + endif + endwhile + + " Got anything? + if l:Our_Match < 0 + return '' + else + let l:Line = strpart (l:Line, l:Our_Match) + endif + + " Now simply add further lines until the match gets no bigger + let l:Match_String = matchstr (l:Line, g:ada#WordRegex) + let l:Last_Line = line ('$') + let l:Line_Nr = line ('.') + 1 + while l:Line_Nr <= l:Last_Line + let l:Last_Match = l:Match_String + let l:Line = l:Line . + \ substitute (getline (l:Line_Nr), g:ada#Comment, '', '') + let l:Match_String = matchstr (l:Line, g:ada#WordRegex) + if l:Match_String == l:Last_Match + break + endif + endwhile + + " Strip whitespace & return + return substitute (l:Match_String, '\s\+', '', 'g') +endfunction ada#Word + +" Section: ada#List_Tag (...) {{{1 +" +" List tags in quickfix window +" +function ada#List_Tag (...) + if a:0 > 1 + let l:Tag_Word = ada#Word (a:1, a:2) + elseif a:0 > 0 + let l:Tag_Word = a:1 + else + let l:Tag_Word = ada#Word () + endif + + echo "Searching for" l:Tag_Word + + let l:Pattern = '^' . l:Tag_Word . '$' + let l:Tag_List = taglist (l:Pattern) + let l:Error_List = [] + " + " add symbols + " + for Tag_Item in l:Tag_List + if l:Tag_Item['kind'] == '' + let l:Tag_Item['kind'] = 's' + endif + + let l:Error_List += [ + \ l:Tag_Item['filename'] . '|' . + \ l:Tag_Item['cmd'] . '|' . + \ l:Tag_Item['kind'] . "\t" . + \ l:Tag_Item['name'] ] + endfor + set errorformat=%f\|%l\|%m + cexpr l:Error_List + cwindow +endfunction ada#List_Tag + +" Section: ada#Jump_Tag (Word, Mode) {{{1 +" +" Word tag - include '.' and if Ada make uppercase +" +function ada#Jump_Tag (Word, Mode) + if a:Word == '' + " Get current word + let l:Word = ada#Word() + if l:Word == '' + throw "NOT_FOUND: no identifier found." + endif + else + let l:Word = a:Word + endif + + echo "Searching for " . l:Word + + try + execute a:Mode l:Word + catch /.*:E426:.*/ + let ignorecase = &ignorecase + set ignorecase + execute a:Mode l:Word + let &ignorecase = ignorecase + endtry + + return +endfunction ada#Jump_Tag + +" Section: ada#Insert_Backspace () {{{1 +" +" Backspace at end of line after auto-inserted commentstring '-- ' wipes it +" +function ada#Insert_Backspace () + let l:Line = getline ('.') + if col ('.') > strlen (l:Line) && + \ match (l:Line, '-- $') != -1 && + \ match (&comments,'--') != -1 + return "\\\" + else + return "\" + endif + + return +endfunction ada#InsertBackspace + +" Section: Insert Completions {{{1 +" +" Section: ada#User_Complete(findstart, base) {{{2 +" +" This function is used for the 'complete' option. +" +function! ada#User_Complete(findstart, base) + if a:findstart == 1 + " + " locate the start of the word + " + let line = getline ('.') + let start = col ('.') - 1 + while start > 0 && line[start - 1] =~ '\i\|''' + let start -= 1 + endwhile + return start + else + " + " look up matches + " + let l:Pattern = '^' . a:base . '.*$' + " + " add keywords + " + for Tag_Item in g:ada#Keywords + if l:Tag_Item['word'] =~? l:Pattern + if complete_add (l:Tag_Item) == 0 + return [] + endif + if complete_check () + return [] + endif + endif + endfor + return [] + endif +endfunction ada#User_Complete + +" Section: ada#Completion (cmd) {{{2 +" +" Word completion (^N/^R/^X^]) - force '.' inclusion +function ada#Completion (cmd) + set iskeyword+=46 + return a:cmd . "\=ada#Completion_End ()\" +endfunction ada#Completion + +" Section: ada#Completion_End () {{{2 +" +function ada#Completion_End () + set iskeyword-=46 + return '' +endfunction ada#Completion_End + +" Section: ada#Create_Tags {{{1 +" +function ada#Create_Tags (option) + if a:option == 'file' + let l:Filename = fnamemodify (bufname ('%'), ':p') + elseif a:option == 'dir' + let l:Filename = + \ fnamemodify (bufname ('%'), ':p:h') . "*.ada " . + \ fnamemodify (bufname ('%'), ':p:h') . "*.adb " . + \ fnamemodify (bufname ('%'), ':p:h') . "*.ads" + else + let l:Filename = a:option + endif + execute '!ctags --excmd=number ' . l:Filename +endfunction ada#Create_Tags + +" Section: ada#Switch_Session {{{1 +" +function ada#Switch_Session (New_Session) + " + " you should not save to much date into the seession since they will + " be sourced + " + let l:sessionoptions=&sessionoptions + + try + set sessionoptions=buffers,curdir,folds,globals,resize,slash,tabpages,tabpages,unix,winpos,winsize + + if a:New_Session != v:this_session + " + " We actually got a new session - otherwise there + " is nothing to do. + " + if strlen (v:this_session) > 0 + execute 'mksession! ' . v:this_session + endif + + let v:this_session = a:New_Session + + "if filereadable (v:this_session) + "execute 'source ' . v:this_session + "endif + + augroup ada_session + autocmd! + autocmd VimLeavePre * execute 'mksession! ' . v:this_session + augroup END + + "if exists ("g:Tlist_Auto_Open") && g:Tlist_Auto_Open + "TlistOpen + "endif + + endif + finally + let &sessionoptions=l:sessionoptions + endtry + + return +endfunction ada#Switch_Session + +" Section: GNAT Pretty Printer folding {{{1 +" +if exists('g:ada_folding') && g:ada_folding[0] == 'g' + " + " Lines consisting only of ')' ';' are due to a gnat pretty bug and + " have the same level as the line above (can't happen in the first + " line). + " + let s:Fold_Collate = '^\([;)]*$\|' + + " + " some lone statements are folded with the line above + " + if stridx (g:ada_folding, 'i') >= 0 + let s:Fold_Collate .= '\s\+\$\|' + endif + if stridx (g:ada_folding, 'b') >= 0 + let s:Fold_Collate .= '\s\+\$\|' + endif + if stridx (g:ada_folding, 'p') >= 0 + let s:Fold_Collate .= '\s\+\$\|' + endif + if stridx (g:ada_folding, 'x') >= 0 + let s:Fold_Collate .= '\s\+\$\|' + endif + + " We also handle empty lines and + " comments here. + let s:Fold_Collate .= '--\)' + + function ada#Pretty_Print_Folding (Line) " {{{2 + let l:Text = getline (a:Line) + + if l:Text =~ s:Fold_Collate + " + " fold with line above + " + let l:Level = "=" + elseif l:Text =~ '^\s\+(' + " + " gnat outdents a line which stards with a ( by one characters so + " that parameters which follow are aligned. + " + let l:Level = (indent (a:Line) + 1) / &shiftwidth + else + let l:Level = indent (a:Line) / &shiftwidth + endif + + return l:Level + endfunction ada#Pretty_Print_Folding " }}}2 +endif + +" Section: Options and Menus {{{1 +" +" Section: ada#Switch_Syntax_Options {{{2 +" +function ada#Switch_Syntax_Option (option) + syntax off + if exists ('g:ada_' . a:option) + unlet g:ada_{a:option} + echo a:option . 'now off' + else + let g:ada_{a:option}=1 + echo a:option . 'now on' + endif + syntax on +endfunction ada#Switch_Syntax_Option + +" Section: ada#Map_Menu {{{2 +" +function ada#Map_Menu (Text, Keys, Command) + if a:Keys[0] == ':' + execute + \ "50amenu " . + \ "Ada." . escape(a:Text, ' ') . + \ "" . a:Keys . + \ " :" . a:Command . "" + execute + \ "command -buffer " . + \ a:Keys[1:] . + \" :" . a:Command . "" + elseif a:Keys[0] == '<' + execute + \ "50amenu " . + \ "Ada." . escape(a:Text, ' ') . + \ "" . a:Keys . + \ " :" . a:Command . "" + execute + \ "nnoremap " . + \ a:Keys . + \" :" . a:Command . "" + execute + \ "inoremap " . + \ a:Keys . + \" :" . a:Command . "" + else + if exists("g:mapleader") + let l:leader = g:mapleader + else + let l:leader = '\' + endif + execute + \ "50amenu " . + \ "Ada." . escape(a:Text, ' ') . + \ "" . escape(l:leader . "a" . a:Keys , '\') . + \ " :" . a:Command . "" + execute + \ "nnoremap " . + \ " a" . a:Keys . + \" :" . a:Command + execute + \ "inoremap " . + \ " a" . a:Keys . + \" :" . a:Command + endif + return +endfunction + +" Section: ada#Map_Popup {{{2 +" +function ada#Map_Popup (Text, Keys, Command) + if exists("g:mapleader") + let l:leader = g:mapleader + else + let l:leader = '\' + endif + execute + \ "50amenu " . + \ "PopUp." . escape(a:Text, ' ') . + \ "" . escape(l:leader . "a" . a:Keys , '\') . + \ " :" . a:Command . "" + + call ada#Map_Menu (a:Text, a:Keys, a:Command) + return +endfunction ada#Map_Popup + +" }}}1 + +lockvar g:ada#WordRegex +lockvar g:ada#DotWordRegex +lockvar g:ada#Comment +lockvar! g:ada#Keywords +lockvar! g:ada#Ctags_Kinds + +let &cpo = s:keepcpo +unlet s:keepcpo + +finish " 1}}} + +"------------------------------------------------------------------------------ +" Copyright (C) 2006 Martin Krischik +" +" Vim is Charityware - see ":help license" or uganda.txt for licence details. +"------------------------------------------------------------------------------ +" vim: textwidth=78 wrap tabstop=8 shiftwidth=3 softtabstop=3 noexpandtab +" vim: foldmethod=marker + +endif diff --git a/autoload/adacomplete.vim b/autoload/adacomplete.vim new file mode 100644 index 0000000..575f87c --- /dev/null +++ b/autoload/adacomplete.vim @@ -0,0 +1,113 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +"------------------------------------------------------------------------------ +" Description: Vim Ada omnicompletion file +" Language: Ada (2005) +" $Id: adacomplete.vim 887 2008-07-08 14:29:01Z krischik $ +" Maintainer: Martin Krischik +" $Author: krischik $ +" $Date: 2008-07-08 16:29:01 +0200 (Di, 08 Jul 2008) $ +" Version: 4.6 +" $Revision: 887 $ +" $HeadURL: https://gnuada.svn.sourceforge.net/svnroot/gnuada/trunk/tools/vim/autoload/adacomplete.vim $ +" History: 24.05.2006 MK Unified Headers +" 26.05.2006 MK improved search for begin of word. +" 16.07.2006 MK Ada-Mode as vim-ball +" 15.10.2006 MK Bram's suggestion for runtime integration +" 05.11.2006 MK Bram suggested not to use include protection for +" autoload +" 05.11.2006 MK Bram suggested agaist using setlocal omnifunc +" 05.11.2006 MK Bram suggested to save on spaces +" Help Page: ft-ada-omni +"------------------------------------------------------------------------------ + +if version < 700 + finish +endif + +" Section: adacomplete#Complete () {{{1 +" +" This function is used for the 'omnifunc' option. +" +function! adacomplete#Complete (findstart, base) + if a:findstart == 1 + return ada#User_Complete (a:findstart, a:base) + else + " + " look up matches + " + if exists ("g:ada_omni_with_keywords") + call ada#User_Complete (a:findstart, a:base) + endif + " + " search tag file for matches + " + let l:Pattern = '^' . a:base . '.*$' + let l:Tag_List = taglist (l:Pattern) + " + " add symbols + " + for Tag_Item in l:Tag_List + if l:Tag_Item['kind'] == '' + " + " Tag created by gnat xref + " + let l:Match_Item = { + \ 'word': l:Tag_Item['name'], + \ 'menu': l:Tag_Item['filename'], + \ 'info': "Symbol from file " . l:Tag_Item['filename'] . " line " . l:Tag_Item['cmd'], + \ 'kind': 's', + \ 'icase': 1} + else + " + " Tag created by ctags + " + let l:Info = 'Symbol : ' . l:Tag_Item['name'] . "\n" + let l:Info .= 'Of type : ' . g:ada#Ctags_Kinds[l:Tag_Item['kind']][1] . "\n" + let l:Info .= 'Defined in File : ' . l:Tag_Item['filename'] . "\n" + + if has_key( l:Tag_Item, 'package') + let l:Info .= 'Package : ' . l:Tag_Item['package'] . "\n" + let l:Menu = l:Tag_Item['package'] + elseif has_key( l:Tag_Item, 'separate') + let l:Info .= 'Separate from Package : ' . l:Tag_Item['separate'] . "\n" + let l:Menu = l:Tag_Item['separate'] + elseif has_key( l:Tag_Item, 'packspec') + let l:Info .= 'Package Specification : ' . l:Tag_Item['packspec'] . "\n" + let l:Menu = l:Tag_Item['packspec'] + elseif has_key( l:Tag_Item, 'type') + let l:Info .= 'Datetype : ' . l:Tag_Item['type'] . "\n" + let l:Menu = l:Tag_Item['type'] + else + let l:Menu = l:Tag_Item['filename'] + endif + + let l:Match_Item = { + \ 'word': l:Tag_Item['name'], + \ 'menu': l:Menu, + \ 'info': l:Info, + \ 'kind': l:Tag_Item['kind'], + \ 'icase': 1} + endif + if complete_add (l:Match_Item) == 0 + return [] + endif + if complete_check () + return [] + endif + endfor + return [] + endif +endfunction adacomplete#Complete + +finish " 1}}} + +"------------------------------------------------------------------------------ +" Copyright (C) 2006 Martin Krischik +" +" Vim is Charityware - see ":help license" or uganda.txt for licence details. +"------------------------------------------------------------------------------ +" vim: textwidth=78 wrap tabstop=8 shiftwidth=3 softtabstop=3 noexpandtab +" vim: foldmethod=marker + +endif diff --git a/autoload/ccomplete.vim b/autoload/ccomplete.vim new file mode 100644 index 0000000..ccfac84 --- /dev/null +++ b/autoload/ccomplete.vim @@ -0,0 +1,614 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim completion script +" Language: C +" Maintainer: Bram Moolenaar +" Last Change: 2012 Jun 20 + +let s:cpo_save = &cpo +set cpo&vim + +" This function is used for the 'omnifunc' option. +function! ccomplete#Complete(findstart, base) + if a:findstart + " Locate the start of the item, including ".", "->" and "[...]". + let line = getline('.') + let start = col('.') - 1 + let lastword = -1 + while start > 0 + if line[start - 1] =~ '\w' + let start -= 1 + elseif line[start - 1] =~ '\.' + if lastword == -1 + let lastword = start + endif + let start -= 1 + elseif start > 1 && line[start - 2] == '-' && line[start - 1] == '>' + if lastword == -1 + let lastword = start + endif + let start -= 2 + elseif line[start - 1] == ']' + " Skip over [...]. + let n = 0 + let start -= 1 + while start > 0 + let start -= 1 + if line[start] == '[' + if n == 0 + break + endif + let n -= 1 + elseif line[start] == ']' " nested [] + let n += 1 + endif + endwhile + else + break + endif + endwhile + + " Return the column of the last word, which is going to be changed. + " Remember the text that comes before it in s:prepended. + if lastword == -1 + let s:prepended = '' + return start + endif + let s:prepended = strpart(line, start, lastword - start) + return lastword + endif + + " Return list of matches. + + let base = s:prepended . a:base + + " Don't do anything for an empty base, would result in all the tags in the + " tags file. + if base == '' + return [] + endif + + " init cache for vimgrep to empty + let s:grepCache = {} + + " Split item in words, keep empty word after "." or "->". + " "aa" -> ['aa'], "aa." -> ['aa', ''], "aa.bb" -> ['aa', 'bb'], etc. + " We can't use split, because we need to skip nested [...]. + let items = [] + let s = 0 + while 1 + let e = match(base, '\.\|->\|\[', s) + if e < 0 + if s == 0 || base[s - 1] != ']' + call add(items, strpart(base, s)) + endif + break + endif + if s == 0 || base[s - 1] != ']' + call add(items, strpart(base, s, e - s)) + endif + if base[e] == '.' + let s = e + 1 " skip over '.' + elseif base[e] == '-' + let s = e + 2 " skip over '->' + else + " Skip over [...]. + let n = 0 + let s = e + let e += 1 + while e < len(base) + if base[e] == ']' + if n == 0 + break + endif + let n -= 1 + elseif base[e] == '[' " nested [...] + let n += 1 + endif + let e += 1 + endwhile + let e += 1 + call add(items, strpart(base, s, e - s)) + let s = e + endif + endwhile + + " Find the variable items[0]. + " 1. in current function (like with "gd") + " 2. in tags file(s) (like with ":tag") + " 3. in current file (like with "gD") + let res = [] + if searchdecl(items[0], 0, 1) == 0 + " Found, now figure out the type. + " TODO: join previous line if it makes sense + let line = getline('.') + let col = col('.') + if stridx(strpart(line, 0, col), ';') != -1 + " Handle multiple declarations on the same line. + let col2 = col - 1 + while line[col2] != ';' + let col2 -= 1 + endwhile + let line = strpart(line, col2 + 1) + let col -= col2 + endif + if stridx(strpart(line, 0, col), ',') != -1 + " Handle multiple declarations on the same line in a function + " declaration. + let col2 = col - 1 + while line[col2] != ',' + let col2 -= 1 + endwhile + if strpart(line, col2 + 1, col - col2 - 1) =~ ' *[^ ][^ ]* *[^ ]' + let line = strpart(line, col2 + 1) + let col -= col2 + endif + endif + if len(items) == 1 + " Completing one word and it's a local variable: May add '[', '.' or + " '->'. + let match = items[0] + let kind = 'v' + if match(line, '\<' . match . '\s*\[') > 0 + let match .= '[' + else + let res = s:Nextitem(strpart(line, 0, col), [''], 0, 1) + if len(res) > 0 + " There are members, thus add "." or "->". + if match(line, '\*[ \t(]*' . match . '\>') > 0 + let match .= '->' + else + let match .= '.' + endif + endif + endif + let res = [{'match': match, 'tagline' : '', 'kind' : kind, 'info' : line}] + else + " Completing "var.", "var.something", etc. + let res = s:Nextitem(strpart(line, 0, col), items[1:], 0, 1) + endif + endif + + if len(items) == 1 + " Only one part, no "." or "->": complete from tags file. + let tags = taglist('^' . base) + + " Remove members, these can't appear without something in front. + call filter(tags, 'has_key(v:val, "kind") ? v:val["kind"] != "m" : 1') + + " Remove static matches in other files. + call filter(tags, '!has_key(v:val, "static") || !v:val["static"] || bufnr("%") == bufnr(v:val["filename"])') + + call extend(res, map(tags, 's:Tag2item(v:val)')) + endif + + if len(res) == 0 + " Find the variable in the tags file(s) + let diclist = taglist('^' . items[0] . '$') + + " Remove members, these can't appear without something in front. + call filter(diclist, 'has_key(v:val, "kind") ? v:val["kind"] != "m" : 1') + + let res = [] + for i in range(len(diclist)) + " New ctags has the "typeref" field. Patched version has "typename". + if has_key(diclist[i], 'typename') + call extend(res, s:StructMembers(diclist[i]['typename'], items[1:], 1)) + elseif has_key(diclist[i], 'typeref') + call extend(res, s:StructMembers(diclist[i]['typeref'], items[1:], 1)) + endif + + " For a variable use the command, which must be a search pattern that + " shows the declaration of the variable. + if diclist[i]['kind'] == 'v' + let line = diclist[i]['cmd'] + if line[0] == '/' && line[1] == '^' + let col = match(line, '\<' . items[0] . '\>') + call extend(res, s:Nextitem(strpart(line, 2, col - 2), items[1:], 0, 1)) + endif + endif + endfor + endif + + if len(res) == 0 && searchdecl(items[0], 1) == 0 + " Found, now figure out the type. + " TODO: join previous line if it makes sense + let line = getline('.') + let col = col('.') + let res = s:Nextitem(strpart(line, 0, col), items[1:], 0, 1) + endif + + " If the last item(s) are [...] they need to be added to the matches. + let last = len(items) - 1 + let brackets = '' + while last >= 0 + if items[last][0] != '[' + break + endif + let brackets = items[last] . brackets + let last -= 1 + endwhile + + return map(res, 's:Tagline2item(v:val, brackets)') +endfunc + +function! s:GetAddition(line, match, memarg, bracket) + " Guess if the item is an array. + if a:bracket && match(a:line, a:match . '\s*\[') > 0 + return '[' + endif + + " Check if the item has members. + if len(s:SearchMembers(a:memarg, [''], 0)) > 0 + " If there is a '*' before the name use "->". + if match(a:line, '\*[ \t(]*' . a:match . '\>') > 0 + return '->' + else + return '.' + endif + endif + return '' +endfunction + +" Turn the tag info "val" into an item for completion. +" "val" is is an item in the list returned by taglist(). +" If it is a variable we may add "." or "->". Don't do it for other types, +" such as a typedef, by not including the info that s:GetAddition() uses. +function! s:Tag2item(val) + let res = {'match': a:val['name']} + + let res['extra'] = s:Tagcmd2extra(a:val['cmd'], a:val['name'], a:val['filename']) + + let s = s:Dict2info(a:val) + if s != '' + let res['info'] = s + endif + + let res['tagline'] = '' + if has_key(a:val, "kind") + let kind = a:val['kind'] + let res['kind'] = kind + if kind == 'v' + let res['tagline'] = "\t" . a:val['cmd'] + let res['dict'] = a:val + elseif kind == 'f' + let res['match'] = a:val['name'] . '(' + endif + endif + + return res +endfunction + +" Use all the items in dictionary for the "info" entry. +function! s:Dict2info(dict) + let info = '' + for k in sort(keys(a:dict)) + let info .= k . repeat(' ', 10 - len(k)) + if k == 'cmd' + let info .= substitute(matchstr(a:dict['cmd'], '/^\s*\zs.*\ze$/'), '\\\(.\)', '\1', 'g') + else + let info .= a:dict[k] + endif + let info .= "\n" + endfor + return info +endfunc + +" Parse a tag line and return a dictionary with items like taglist() +function! s:ParseTagline(line) + let l = split(a:line, "\t") + let d = {} + if len(l) >= 3 + let d['name'] = l[0] + let d['filename'] = l[1] + let d['cmd'] = l[2] + let n = 2 + if l[2] =~ '^/' + " Find end of cmd, it may contain Tabs. + while n < len(l) && l[n] !~ '/;"$' + let n += 1 + let d['cmd'] .= " " . l[n] + endwhile + endif + for i in range(n + 1, len(l) - 1) + if l[i] == 'file:' + let d['static'] = 1 + elseif l[i] !~ ':' + let d['kind'] = l[i] + else + let d[matchstr(l[i], '[^:]*')] = matchstr(l[i], ':\zs.*') + endif + endfor + endif + + return d +endfunction + +" Turn a match item "val" into an item for completion. +" "val['match']" is the matching item. +" "val['tagline']" is the tagline in which the last part was found. +function! s:Tagline2item(val, brackets) + let line = a:val['tagline'] + let add = s:GetAddition(line, a:val['match'], [a:val], a:brackets == '') + let res = {'word': a:val['match'] . a:brackets . add } + + if has_key(a:val, 'info') + " Use info from Tag2item(). + let res['info'] = a:val['info'] + else + " Parse the tag line and add each part to the "info" entry. + let s = s:Dict2info(s:ParseTagline(line)) + if s != '' + let res['info'] = s + endif + endif + + if has_key(a:val, 'kind') + let res['kind'] = a:val['kind'] + elseif add == '(' + let res['kind'] = 'f' + else + let s = matchstr(line, '\t\(kind:\)\=\zs\S\ze\(\t\|$\)') + if s != '' + let res['kind'] = s + endif + endif + + if has_key(a:val, 'extra') + let res['menu'] = a:val['extra'] + return res + endif + + " Isolate the command after the tag and filename. + let s = matchstr(line, '[^\t]*\t[^\t]*\t\zs\(/^.*$/\|[^\t]*\)\ze\(;"\t\|\t\|$\)') + if s != '' + let res['menu'] = s:Tagcmd2extra(s, a:val['match'], matchstr(line, '[^\t]*\t\zs[^\t]*\ze\t')) + endif + return res +endfunction + +" Turn a command from a tag line to something that is useful in the menu +function! s:Tagcmd2extra(cmd, name, fname) + if a:cmd =~ '^/^' + " The command is a search command, useful to see what it is. + let x = matchstr(a:cmd, '^/^\s*\zs.*\ze$/') + let x = substitute(x, '\<' . a:name . '\>', '@@', '') + let x = substitute(x, '\\\(.\)', '\1', 'g') + let x = x . ' - ' . a:fname + elseif a:cmd =~ '^\d*$' + " The command is a line number, the file name is more useful. + let x = a:fname . ' - ' . a:cmd + else + " Not recognized, use command and file name. + let x = a:cmd . ' - ' . a:fname + endif + return x +endfunction + +" Find composing type in "lead" and match items[0] with it. +" Repeat this recursively for items[1], if it's there. +" When resolving typedefs "depth" is used to avoid infinite recursion. +" Return the list of matches. +function! s:Nextitem(lead, items, depth, all) + + " Use the text up to the variable name and split it in tokens. + let tokens = split(a:lead, '\s\+\|\<') + + " Try to recognize the type of the variable. This is rough guessing... + let res = [] + for tidx in range(len(tokens)) + + " Skip tokens starting with a non-ID character. + if tokens[tidx] !~ '^\h' + continue + endif + + " Recognize "struct foobar" and "union foobar". + " Also do "class foobar" when it's C++ after all (doesn't work very well + " though). + if (tokens[tidx] == 'struct' || tokens[tidx] == 'union' || tokens[tidx] == 'class') && tidx + 1 < len(tokens) + let res = s:StructMembers(tokens[tidx] . ':' . tokens[tidx + 1], a:items, a:all) + break + endif + + " TODO: add more reserved words + if index(['int', 'short', 'char', 'float', 'double', 'static', 'unsigned', 'extern'], tokens[tidx]) >= 0 + continue + endif + + " Use the tags file to find out if this is a typedef. + let diclist = taglist('^' . tokens[tidx] . '$') + for tagidx in range(len(diclist)) + let item = diclist[tagidx] + + " New ctags has the "typeref" field. Patched version has "typename". + if has_key(item, 'typeref') + call extend(res, s:StructMembers(item['typeref'], a:items, a:all)) + continue + endif + if has_key(item, 'typename') + call extend(res, s:StructMembers(item['typename'], a:items, a:all)) + continue + endif + + " Only handle typedefs here. + if item['kind'] != 't' + continue + endif + + " Skip matches local to another file. + if has_key(item, 'static') && item['static'] && bufnr('%') != bufnr(item['filename']) + continue + endif + + " For old ctags we recognize "typedef struct aaa" and + " "typedef union bbb" in the tags file command. + let cmd = item['cmd'] + let ei = matchend(cmd, 'typedef\s\+') + if ei > 1 + let cmdtokens = split(strpart(cmd, ei), '\s\+\|\<') + if len(cmdtokens) > 1 + if cmdtokens[0] == 'struct' || cmdtokens[0] == 'union' || cmdtokens[0] == 'class' + let name = '' + " Use the first identifier after the "struct" or "union" + for ti in range(len(cmdtokens) - 1) + if cmdtokens[ti] =~ '^\w' + let name = cmdtokens[ti] + break + endif + endfor + if name != '' + call extend(res, s:StructMembers(cmdtokens[0] . ':' . name, a:items, a:all)) + endif + elseif a:depth < 10 + " Could be "typedef other_T some_T". + call extend(res, s:Nextitem(cmdtokens[0], a:items, a:depth + 1, a:all)) + endif + endif + endif + endfor + if len(res) > 0 + break + endif + endfor + + return res +endfunction + + +" Search for members of structure "typename" in tags files. +" Return a list with resulting matches. +" Each match is a dictionary with "match" and "tagline" entries. +" When "all" is non-zero find all, otherwise just return 1 if there is any +" member. +function! s:StructMembers(typename, items, all) + " Todo: What about local structures? + let fnames = join(map(tagfiles(), 'escape(v:val, " \\#%")')) + if fnames == '' + return [] + endif + + let typename = a:typename + let qflist = [] + let cached = 0 + if a:all == 0 + let n = '1' " stop at first found match + if has_key(s:grepCache, a:typename) + let qflist = s:grepCache[a:typename] + let cached = 1 + endif + else + let n = '' + endif + if !cached + while 1 + exe 'silent! keepj noautocmd ' . n . 'vimgrep /\t' . typename . '\(\t\|$\)/j ' . fnames + + let qflist = getqflist() + if len(qflist) > 0 || match(typename, "::") < 0 + break + endif + " No match for "struct:context::name", remove "context::" and try again. + let typename = substitute(typename, ':[^:]*::', ':', '') + endwhile + + if a:all == 0 + " Store the result to be able to use it again later. + let s:grepCache[a:typename] = qflist + endif + endif + + " Put matching members in matches[]. + let matches = [] + for l in qflist + let memb = matchstr(l['text'], '[^\t]*') + if memb =~ '^' . a:items[0] + " Skip matches local to another file. + if match(l['text'], "\tfile:") < 0 || bufnr('%') == bufnr(matchstr(l['text'], '\t\zs[^\t]*')) + let item = {'match': memb, 'tagline': l['text']} + + " Add the kind of item. + let s = matchstr(l['text'], '\t\(kind:\)\=\zs\S\ze\(\t\|$\)') + if s != '' + let item['kind'] = s + if s == 'f' + let item['match'] = memb . '(' + endif + endif + + call add(matches, item) + endif + endif + endfor + + if len(matches) > 0 + " Skip over [...] items + let idx = 1 + while 1 + if idx >= len(a:items) + return matches " No further items, return the result. + endif + if a:items[idx][0] != '[' + break + endif + let idx += 1 + endwhile + + " More items following. For each of the possible members find the + " matching following members. + return s:SearchMembers(matches, a:items[idx :], a:all) + endif + + " Failed to find anything. + return [] +endfunction + +" For matching members, find matches for following items. +" When "all" is non-zero find all, otherwise just return 1 if there is any +" member. +function! s:SearchMembers(matches, items, all) + let res = [] + for i in range(len(a:matches)) + let typename = '' + if has_key(a:matches[i], 'dict') + if has_key(a:matches[i].dict, 'typename') + let typename = a:matches[i].dict['typename'] + elseif has_key(a:matches[i].dict, 'typeref') + let typename = a:matches[i].dict['typeref'] + endif + let line = "\t" . a:matches[i].dict['cmd'] + else + let line = a:matches[i]['tagline'] + let e = matchend(line, '\ttypename:') + if e < 0 + let e = matchend(line, '\ttyperef:') + endif + if e > 0 + " Use typename field + let typename = matchstr(line, '[^\t]*', e) + endif + endif + + if typename != '' + call extend(res, s:StructMembers(typename, a:items, a:all)) + else + " Use the search command (the declaration itself). + let s = match(line, '\t\zs/^') + if s > 0 + let e = match(line, '\<' . a:matches[i]['match'] . '\>', s) + if e > 0 + call extend(res, s:Nextitem(strpart(line, s, e - s), a:items, 0, a:all)) + endif + endif + endif + if a:all == 0 && len(res) > 0 + break + endif + endfor + return res +endfunc + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/autoload/clojurecomplete.vim b/autoload/clojurecomplete.vim index aa2644c..790d7e8 100644 --- a/autoload/clojurecomplete.vim +++ b/autoload/clojurecomplete.vim @@ -1,3 +1,29 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim completion script +" Language: Clojure +" Maintainer: Sung Pae +" URL: https://github.com/guns/vim-clojure-static +" License: Same as Vim +" Last Change: 18 July 2016 + +" -*- COMPLETION WORDS -*- +" Generated from https://github.com/guns/vim-clojure-static/blob/vim-release-011/clj/src/vim_clojure_static/generate.clj +" Clojure version 1.8.0 +let s:words = ["*","*'","*1","*2","*3","*agent*","*allow-unresolved-vars*","*assert*","*clojure-version*","*command-line-args*","*compile-files*","*compile-path*","*compiler-options*","*data-readers*","*default-data-reader-fn*","*e","*err*","*file*","*flush-on-newline*","*fn-loader*","*in*","*math-context*","*ns*","*out*","*print-dup*","*print-length*","*print-level*","*print-meta*","*print-readably*","*read-eval*","*source-path*","*suppress-read*","*unchecked-math*","*use-context-classloader*","*verbose-defrecords*","*warn-on-reflection*","+","+'","-","-'","->","->>","->ArrayChunk","->Eduction","->Vec","->VecNode","->VecSeq","-cache-protocol-fn","-reset-methods",".","..","/","<","<=","=","==",">",">=","EMPTY-NODE","Throwable->map","accessor","aclone","add-classpath","add-watch","agent","agent-error","agent-errors","aget","alength","alias","all-ns","alter","alter-meta!","alter-var-root","amap","ancestors","and","apply","areduce","array-map","as->","aset","aset-boolean","aset-byte","aset-char","aset-double","aset-float","aset-int","aset-long","aset-short","assert","assoc!","assoc","assoc-in","associative?","atom","await","await-for","await1","bases","bean","bigdec","bigint","biginteger","binding","bit-and","bit-and-not","bit-clear","bit-flip","bit-not","bit-or","bit-set","bit-shift-left","bit-shift-right","bit-test","bit-xor","boolean","boolean-array","booleans","bound-fn","bound-fn*","bound?","butlast","byte","byte-array","bytes","case","cast","cat","catch","char","char-array","char-escape-string","char-name-string","char?","chars","chunk","chunk-append","chunk-buffer","chunk-cons","chunk-first","chunk-next","chunk-rest","chunked-seq?","class","class?","clear-agent-errors","clojure-version","coll?","comment","commute","comp","comparator","compare","compare-and-set!","compile","complement","completing","concat","cond","cond->","cond->>","condp","conj!","conj","cons","constantly","construct-proxy","contains?","count","counted?","create-ns","create-struct","cycle","dec","dec'","decimal?","declare","dedupe","def","default-data-readers","definline","definterface","defmacro","defmethod","defmulti","defn","defn-","defonce","defprotocol","defrecord","defstruct","deftype","delay","delay?","deliver","denominator","deref","derive","descendants","destructure","disj!","disj","dissoc!","dissoc","distinct","distinct?","do","doall","dorun","doseq","dosync","dotimes","doto","double","double-array","doubles","drop","drop-last","drop-while","eduction","empty","empty?","ensure","ensure-reduced","enumeration-seq","error-handler","error-mode","eval","even?","every-pred","every?","ex-data","ex-info","extend","extend-protocol","extend-type","extenders","extends?","false?","ffirst","file-seq","filter","filterv","finally","find","find-keyword","find-ns","find-protocol-impl","find-protocol-method","find-var","first","flatten","float","float-array","float?","floats","flush","fn","fn","fn?","fnext","fnil","for","force","format","frequencies","future","future-call","future-cancel","future-cancelled?","future-done?","future?","gen-class","gen-interface","gensym","get","get-in","get-method","get-proxy-class","get-thread-bindings","get-validator","group-by","hash","hash-combine","hash-map","hash-ordered-coll","hash-set","hash-unordered-coll","identical?","identity","if","if-let","if-not","if-some","ifn?","import","in-ns","inc","inc'","init-proxy","instance?","int","int-array","integer?","interleave","intern","interpose","into","into-array","ints","io!","isa?","iterate","iterator-seq","juxt","keep","keep-indexed","key","keys","keyword","keyword?","last","lazy-cat","lazy-seq","let","let","letfn","line-seq","list","list*","list?","load","load-file","load-reader","load-string","loaded-libs","locking","long","long-array","longs","loop","loop","macroexpand","macroexpand-1","make-array","make-hierarchy","map","map-entry?","map-indexed","map?","mapcat","mapv","max","max-key","memfn","memoize","merge","merge-with","meta","method-sig","methods","min","min-key","mix-collection-hash","mod","monitor-enter","monitor-exit","munge","name","namespace","namespace-munge","neg?","new","newline","next","nfirst","nil?","nnext","not","not-any?","not-empty","not-every?","not=","ns","ns-aliases","ns-imports","ns-interns","ns-map","ns-name","ns-publics","ns-refers","ns-resolve","ns-unalias","ns-unmap","nth","nthnext","nthrest","num","number?","numerator","object-array","odd?","or","parents","partial","partition","partition-all","partition-by","pcalls","peek","persistent!","pmap","pop!","pop","pop-thread-bindings","pos?","pr","pr-str","prefer-method","prefers","primitives-classnames","print","print-ctor","print-dup","print-method","print-simple","print-str","printf","println","println-str","prn","prn-str","promise","proxy","proxy-call-with-super","proxy-mappings","proxy-name","proxy-super","push-thread-bindings","pvalues","quot","quote","rand","rand-int","rand-nth","random-sample","range","ratio?","rational?","rationalize","re-find","re-groups","re-matcher","re-matches","re-pattern","re-seq","read","read-line","read-string","reader-conditional","reader-conditional?","realized?","record?","recur","reduce","reduce-kv","reduced","reduced?","reductions","ref","ref-history-count","ref-max-history","ref-min-history","ref-set","refer","refer-clojure","reify","release-pending-sends","rem","remove","remove-all-methods","remove-method","remove-ns","remove-watch","repeat","repeatedly","replace","replicate","require","reset!","reset-meta!","resolve","rest","restart-agent","resultset-seq","reverse","reversible?","rseq","rsubseq","run!","satisfies?","second","select-keys","send","send-off","send-via","seq","seq?","seque","sequence","sequential?","set!","set","set-agent-send-executor!","set-agent-send-off-executor!","set-error-handler!","set-error-mode!","set-validator!","set?","short","short-array","shorts","shuffle","shutdown-agents","slurp","some","some->","some->>","some-fn","some?","sort","sort-by","sorted-map","sorted-map-by","sorted-set","sorted-set-by","sorted?","special-symbol?","spit","split-at","split-with","str","string?","struct","struct-map","subs","subseq","subvec","supers","swap!","symbol","symbol?","sync","tagged-literal","tagged-literal?","take","take-last","take-nth","take-while","test","the-ns","thread-bound?","throw","time","to-array","to-array-2d","trampoline","transduce","transient","tree-seq","true?","try","type","unchecked-add","unchecked-add-int","unchecked-byte","unchecked-char","unchecked-dec","unchecked-dec-int","unchecked-divide-int","unchecked-double","unchecked-float","unchecked-inc","unchecked-inc-int","unchecked-int","unchecked-long","unchecked-multiply","unchecked-multiply-int","unchecked-negate","unchecked-negate-int","unchecked-remainder-int","unchecked-short","unchecked-subtract","unchecked-subtract-int","underive","unquote","unquote-splicing","unreduced","unsigned-bit-shift-right","update","update-in","update-proxy","use","val","vals","var","var-get","var-set","var?","vary-meta","vec","vector","vector-of","vector?","volatile!","volatile?","vreset!","vswap!","when","when-first","when-let","when-not","when-some","while","with-bindings","with-bindings*","with-in-str","with-loading-context","with-local-vars","with-meta","with-open","with-out-str","with-precision","with-redefs","with-redefs-fn","xml-seq","zero?","zipmap"] + +" Simple word completion for special forms and public vars in clojure.core +function! clojurecomplete#Complete(findstart, base) + if a:findstart + return searchpos('\<', 'bnW', line('.'))[1] - 1 + else + return { 'words': filter(copy(s:words), 'v:val =~# "\\V\\^' . a:base . '"') } + endif +endfunction + +" vim:sts=8:sw=8:ts=8:noet + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'clojure') == -1 " Vim completion script diff --git a/autoload/context.vim b/autoload/context.vim new file mode 100644 index 0000000..15157dc --- /dev/null +++ b/autoload/context.vim @@ -0,0 +1,188 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: ConTeXt typesetting engine +" Maintainer: Nicola Vitacolonna +" Latest Revision: 2016 Oct 21 + +let s:keepcpo= &cpo +set cpo&vim + +" Helper functions {{{ +function! s:context_echo(message, mode) + redraw + echo "\r" + execute 'echohl' a:mode + echomsg '[ConTeXt]' a:message + echohl None +endf + +function! s:sh() + return has('win32') || has('win64') || has('win16') || has('win95') + \ ? ['cmd.exe', '/C'] + \ : ['/bin/sh', '-c'] +endfunction + +" For backward compatibility +if exists('*win_getid') + + function! s:win_getid() + return win_getid() + endf + + function! s:win_id2win(winid) + return win_id2win(a:winid) + endf + +else + + function! s:win_getid() + return winnr() + endf + + function! s:win_id2win(winnr) + return a:winnr + endf + +endif +" }}} + +" ConTeXt jobs {{{ +if has('job') + + let g:context_jobs = [] + + " Print the status of ConTeXt jobs + function! context#job_status() + let l:jobs = filter(g:context_jobs, 'job_status(v:val) == "run"') + let l:n = len(l:jobs) + call s:context_echo( + \ 'There '.(l:n == 1 ? 'is' : 'are').' '.(l:n == 0 ? 'no' : l:n) + \ .' job'.(l:n == 1 ? '' : 's').' running' + \ .(l:n == 0 ? '.' : ' (' . join(l:jobs, ', ').').'), + \ 'ModeMsg') + endfunction + + " Stop all ConTeXt jobs + function! context#stop_jobs() + let l:jobs = filter(g:context_jobs, 'job_status(v:val) == "run"') + for job in l:jobs + call job_stop(job) + endfor + sleep 1 + let l:tmp = [] + for job in l:jobs + if job_status(job) == "run" + call add(l:tmp, job) + endif + endfor + let g:context_jobs = l:tmp + if empty(g:context_jobs) + call s:context_echo('Done. No jobs running.', 'ModeMsg') + else + call s:context_echo('There are still some jobs running. Please try again.', 'WarningMsg') + endif + endfunction + + function! context#callback(path, job, status) + if index(g:context_jobs, a:job) != -1 && job_status(a:job) != 'run' " just in case + call remove(g:context_jobs, index(g:context_jobs, a:job)) + endif + call s:callback(a:path, a:job, a:status) + endfunction + + function! context#close_cb(channel) + call job_status(ch_getjob(a:channel)) " Trigger exit_cb's callback for faster feedback + endfunction + + function! s:typeset(path) + call add(g:context_jobs, + \ job_start(add(s:sh(), context#command() . ' ' . shellescape(fnamemodify(a:path, ":t"))), { + \ 'close_cb' : 'context#close_cb', + \ 'exit_cb' : function(get(b:, 'context_callback', get(g:, 'context_callback', 'context#callback')), + \ [a:path]), + \ 'in_io' : 'null' + \ })) + endfunction + +else " No jobs + + function! context#job_status() + call s:context_echo('Not implemented', 'WarningMsg') + endfunction! + + function! context#stop_jobs() + call s:context_echo('Not implemented', 'WarningMsg') + endfunction + + function! context#callback(path, job, status) + call s:callback(a:path, a:job, a:status) + endfunction + + function! s:typeset(path) + execute '!' . context#command() . ' ' . shellescape(fnamemodify(a:path, ":t")) + call call(get(b:, 'context_callback', get(g:, 'context_callback', 'context#callback')), + \ [a:path, 0, v:shell_error]) + endfunction + +endif " has('job') + +function! s:callback(path, job, status) abort + if a:status < 0 " Assume the job was terminated + return + endif + " Get info about the current window + let l:winid = s:win_getid() " Save window id + let l:efm = &l:errorformat " Save local errorformat + let l:cwd = fnamemodify(getcwd(), ":p") " Save local working directory + " Set errorformat to parse ConTeXt errors + execute 'setl efm=' . escape(b:context_errorformat, ' ') + try " Set cwd to expand error file correctly + execute 'lcd' fnameescape(fnamemodify(a:path, ':h')) + catch /.*/ + execute 'setl efm=' . escape(l:efm, ' ') + throw v:exception + endtry + try + execute 'cgetfile' fnameescape(fnamemodify(a:path, ':r') . '.log') + botright cwindow + finally " Restore cwd and errorformat + execute s:win_id2win(l:winid) . 'wincmd w' + execute 'lcd ' . fnameescape(l:cwd) + execute 'setl efm=' . escape(l:efm, ' ') + endtry + if a:status == 0 + call s:context_echo('Success!', 'ModeMsg') + else + call s:context_echo('There are errors. ', 'ErrorMsg') + endif +endfunction + +function! context#command() + return get(b:, 'context_mtxrun', get(g:, 'context_mtxrun', 'mtxrun')) + \ . ' --script context --autogenerate --nonstopmode' + \ . ' --synctex=' . (get(b:, 'context_synctex', get(g:, 'context_synctex', 0)) ? '1' : '0') + \ . ' ' . get(b:, 'context_extra_options', get(g:, 'context_extra_options', '')) +endfunction + +" Accepts an optional path (useful for big projects, when the file you are +" editing is not the project's root document). If no argument is given, uses +" the path of the current buffer. +function! context#typeset(...) abort + let l:path = fnamemodify(strlen(a:000[0]) > 0 ? a:1 : expand("%"), ":p") + let l:cwd = fnamemodify(getcwd(), ":p") " Save local working directory + call s:context_echo('Typesetting...', 'ModeMsg') + execute 'lcd' fnameescape(fnamemodify(l:path, ":h")) + try + call s:typeset(l:path) + finally " Restore local working directory + execute 'lcd ' . fnameescape(l:cwd) + endtry +endfunction! +"}}} + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim: sw=2 fdm=marker + +endif diff --git a/autoload/contextcomplete.vim b/autoload/contextcomplete.vim new file mode 100644 index 0000000..d4ffa05 --- /dev/null +++ b/autoload/contextcomplete.vim @@ -0,0 +1,29 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: ConTeXt typesetting engine +" Maintainer: Nicola Vitacolonna +" Latest Revision: 2016 Oct 15 + +let s:keepcpo= &cpo +set cpo&vim + +" Complete keywords in MetaPost blocks +function! contextcomplete#Complete(findstart, base) + if a:findstart == 1 + if len(synstack(line('.'), 1)) > 0 && + \ synIDattr(synstack(line('.'), 1)[0], "name") ==# 'contextMPGraphic' + return syntaxcomplete#Complete(a:findstart, a:base) + else + return -3 + endif + else + return syntaxcomplete#Complete(a:findstart, a:base) + endif +endfunction + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim: sw=2 fdm=marker + +endif diff --git a/autoload/csscomplete.vim b/autoload/csscomplete.vim new file mode 100644 index 0000000..06e0ab5 --- /dev/null +++ b/autoload/csscomplete.vim @@ -0,0 +1,744 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim completion script +" Language: CSS +" Based on MDN CSS Reference at 2016 Jan +" plus CSS Speech Module +" Maintainer: Kao, Wei-Ko(othree) ( othree AT gmail DOT com ) +" Original Author: Mikolaj Machowski ( mikmach AT wp DOT pl ) +" Last Change: 2016 Jan 11 + +let s:values = split("all additive-symbols align-content align-items align-self animation animation-delay animation-direction animation-duration animation-fill-mode animation-iteration-count animation-name animation-play-state animation-timing-function backface-visibility background background-attachment background-blend-mode background-clip background-color background-image background-origin background-position background-repeat background-size block-size border border-block-end border-block-end-color border-block-end-style border-block-end-width border-block-start border-block-start-color border-block-start-style border-block-start-width border-bottom border-bottom-color border-bottom-left-radius border-bottom-right-radius border-bottom-style border-bottom-width border-collapse border-color border-image border-image-outset border-image-repeat border-image-slice border-image-source border-image-width border-inline-end border-inline-end-color border-inline-end-style border-inline-end-width border-inline-start border-inline-start-color border-inline-start-style border-inline-start-width border-left border-left-color border-left-style border-left-width border-radius border-right border-right-color border-right-style border-right-width border-spacing border-style border-top border-top-color border-top-left-radius border-top-right-radius border-top-style border-top-width border-width bottom box-decoration-break box-shadow box-sizing break-after break-before break-inside caption-side clear clip clip-path color columns column-count column-fill column-gap column-rule column-rule-color column-rule-style column-rule-width column-span column-width content counter-increment counter-reset cue cue-before cue-after cursor direction display empty-cells fallback filter flex flex-basis flex-direction flex-flow flex-grow flex-shrink flex-wrap float font font-family font-feature-settings font-kerning font-language-override font-size font-size-adjust font-stretch font-style font-synthesis font-variant font-variant-alternates font-variant-caps font-variant-east-asian font-variant-ligatures font-variant-numeric font-variant-position font-weight grid grid-area grid-auto-columns grid-auto-flow grid-auto-position grid-auto-rows grid-column grid-column-start grid-column-end grid-row grid-row-start grid-row-end grid-template grid-template-areas grid-template-rows grid-template-columns height hyphens image-rendering image-resolution image-orientation ime-mode inline-size isolation justify-content left letter-spacing line-break line-height list-style list-style-image list-style-position list-style-type margin margin-block-end margin-block-start margin-bottom margin-inline-end margin-inline-start margin-left margin-right margin-top marks mask mask-type max-block-size max-height max-inline-size max-width max-zoom min-block-size min-height min-inline-size min-width min-zoom mix-blend-mode negative object-fit object-position offset-block-end offset-block-start offset-inline-end offset-inline-start opacity order orientation orphans outline outline-color outline-offset outline-style outline-width overflow overflow-wrap overflow-x overflow-y pad padding padding-block-end padding-block-start padding-bottom padding-inline-end padding-inline-start padding-left padding-right padding-top page-break-after page-break-before page-break-inside pause-before pause-after pause perspective perspective-origin pointer-events position prefix quotes range resize rest rest-before rest-after right ruby-align ruby-merge ruby-position scroll-behavior scroll-snap-coordinate scroll-snap-destination scroll-snap-points-x scroll-snap-points-y scroll-snap-type scroll-snap-type-x scroll-snap-type-y shape-image-threshold shape-margin shape-outside speak speak-as suffix symbols system table-layout tab-size text-align text-align-last text-combine-upright text-decoration text-decoration-color text-decoration-line text-emphasis text-emphasis-color text-emphasis-position text-emphasis-style text-indent text-orientation text-overflow text-rendering text-shadow text-transform text-underline-position top touch-action transform transform-box transform-origin transform-style transition transition-delay transition-duration transition-property transition-timing-function unicode-bidi unicode-range user-zoom vertical-align visibility voice-balance voice-duration voice-family voice-pitch voice-rate voice-range voice-stress voice-volume white-space widows width will-change word-break word-spacing word-wrap writing-mode z-index zoom") + + +function! csscomplete#CompleteCSS(findstart, base) + + if a:findstart + " We need whole line to proper checking + let line = getline('.') + let start = col('.') - 1 + let compl_begin = col('.') - 2 + while start >= 0 && line[start - 1] =~ '\%(\k\|-\)' + let start -= 1 + endwhile + let b:after = line[compl_begin :] + let b:compl_context = line[0:compl_begin] + return start + endif + + " There are few chars important for context: + " ^ ; : { } /* */ + " Where ^ is start of line and /* */ are comment borders + " Depending on their relative position to cursor we will know what should + " be completed. + " 1. if nearest are ^ or { or ; current word is property + " 2. if : it is value (with exception of pseudo things) + " 3. if } we are outside of css definitions + " 4. for comments ignoring is be the easiest but assume they are the same + " as 1. + " 5. if @ complete at-rule + " 6. if ! complete important + if exists("b:compl_context") + let line = b:compl_context + let after = b:after + unlet! b:compl_context + else + let line = a:base + endif + + let res = [] + let res2 = [] + let borders = {} + + " Check last occurrence of sequence + + let openbrace = strridx(line, '{') + let closebrace = strridx(line, '}') + let colon = strridx(line, ':') + let semicolon = strridx(line, ';') + let opencomm = strridx(line, '/*') + let closecomm = strridx(line, '*/') + let style = strridx(line, 'style\s*=') + let atrule = strridx(line, '@') + let exclam = strridx(line, '!') + + if openbrace > -1 + let borders[openbrace] = "openbrace" + endif + if closebrace > -1 + let borders[closebrace] = "closebrace" + endif + if colon > -1 + let borders[colon] = "colon" + endif + if semicolon > -1 + let borders[semicolon] = "semicolon" + endif + if opencomm > -1 + let borders[opencomm] = "opencomm" + endif + if closecomm > -1 + let borders[closecomm] = "closecomm" + endif + if style > -1 + let borders[style] = "style" + endif + if atrule > -1 + let borders[atrule] = "atrule" + endif + if exclam > -1 + let borders[exclam] = "exclam" + endif + + + if len(borders) == 0 || borders[max(keys(borders))] =~ '^\%(openbrace\|semicolon\|opencomm\|closecomm\|style\)$' + " Complete properties + + + let entered_property = matchstr(line, '.\{-}\zs[a-zA-Z-]*$') + + for m in s:values + if m =~? '^'.entered_property + call add(res, m . ':') + elseif m =~? entered_property + call add(res2, m . ':') + endif + endfor + + return res + res2 + + elseif borders[max(keys(borders))] == 'colon' + " Get name of property + let prop = tolower(matchstr(line, '\zs[a-zA-Z-]*\ze\s*:[^:]\{-}$')) + + let wide_keywords = ["initial", "inherit", "unset"] + let color_values = ["transparent", "rgb(", "rgba(", "hsl(", "hsla(", "#"] + let border_style_values = ["none", "hidden", "dotted", "dashed", "solid", "double", "groove", "ridge", "inset", "outset"] + let border_width_values = ["thin", "thick", "medium"] + let list_style_type_values = ["decimal", "decimal-leading-zero", "arabic-indic", "armenian", "upper-armenian", "lower-armenian", "bengali", "cambodian", "khmer", "cjk-decimal", "devanagari", "georgian", "gujarati", "gurmukhi", "hebrew", "kannada", "lao", "malayalam", "mongolian", "myanmar", "oriya", "persian", "lower-roman", "upper-roman", "tamil", "telugu", "thai", "tibetan", "lower-alpha", "lower-latin", "upper-alpha", "upper-latin", "cjk-earthly-branch", "cjk-heavenly-stem", "lower-greek", "hiragana", "hiragana-iroha", "katakana", "katakana-iroha", "disc", "circle", "square", "disclosure-open", "disclosure-closed"] + let timing_functions = ["cubic-bezier(", "steps(", "linear", "ease", "ease-in", "ease-in-out", "ease-out", "step-start", "step-end"] + + if prop == 'all' + let values = [] + elseif prop == 'additive-symbols' + let values = [] + elseif prop == 'align-content' + let values = ["flex-start", "flex-end", "center", "space-between", "space-around", "stretch"] + elseif prop == 'align-items' + let values = ["flex-start", "flex-end", "center", "baseline", "stretch"] + elseif prop == 'align-self' + let values = ["auto", "flex-start", "flex-end", "center", "baseline", "stretch"] + elseif prop == 'animation' + let values = timing_functions + ["normal", "reverse", "alternate", "alternate-reverse"] + ["none", "forwards", "backwards", "both"] + ["running", "paused"] + elseif prop == 'animation-delay' + let values = [] + elseif prop == 'animation-direction' + let values = ["normal", "reverse", "alternate", "alternate-reverse"] + elseif prop == 'animation-duration' + let values = [] + elseif prop == 'animation-fill-mode' + let values = ["none", "forwards", "backwards", "both"] + elseif prop == 'animation-iteration-count' + let values = [] + elseif prop == 'animation-name' + let values = [] + elseif prop == 'animation-play-state' + let values = ["running", "paused"] + elseif prop == 'animation-timing-function' + let values = timing_functions + elseif prop == 'background-attachment' + let values = ["scroll", "fixed"] + elseif prop == 'background-color' + let values = color_values + elseif prop == 'background-image' + let values = ["url(", "none"] + elseif prop == 'background-position' + let vals = matchstr(line, '.*:\s*\zs.*') + if vals =~ '^\%([a-zA-Z]\+\)\?$' + let values = ["top", "center", "bottom"] + elseif vals =~ '^[a-zA-Z]\+\s\+\%([a-zA-Z]\+\)\?$' + let values = ["left", "center", "right"] + else + return [] + endif + elseif prop == 'background-repeat' + let values = ["repeat", "repeat-x", "repeat-y", "no-repeat"] + elseif prop == 'background-size' + let values = ["auto", "contain", "cover"] + elseif prop == 'background' + let values = ["scroll", "fixed"] + color_values + ["url(", "none"] + ["top", "center", "bottom", "left", "right"] + ["repeat", "repeat-x", "repeat-y", "no-repeat"] + ["auto", "contain", "cover"] + elseif prop =~ 'border\%(-top\|-right\|-bottom\|-left\|-block-start\|-block-end\)\?$' + let vals = matchstr(line, '.*:\s*\zs.*') + if vals =~ '^\%([a-zA-Z0-9.]\+\)\?$' + let values = border_width_values + elseif vals =~ '^[a-zA-Z0-9.]\+\s\+\%([a-zA-Z]\+\)\?$' + let values = border_style_values + elseif vals =~ '^[a-zA-Z0-9.]\+\s\+[a-zA-Z]\+\s\+\%([a-zA-Z(]\+\)\?$' + let values = color_values + else + return [] + endif + elseif prop =~ 'border-\%(top\|right\|bottom\|left\|block-start\|block-end\)-color' + let values = color_values + elseif prop =~ 'border-\%(top\|right\|bottom\|left\|block-start\|block-end\)-style' + let values = border_style_values + elseif prop =~ 'border-\%(top\|right\|bottom\|left\|block-start\|block-end\)-width' + let values = border_width_values + elseif prop == 'border-color' + let values = color_values + elseif prop == 'border-style' + let values = border_style_values + elseif prop == 'border-width' + let values = border_width_values + elseif prop == 'bottom' + let values = ["auto"] + elseif prop == 'box-decoration-break' + let values = ["slice", "clone"] + elseif prop == 'box-shadow' + let values = ["inset"] + elseif prop == 'box-sizing' + let values = ["border-box", "content-box"] + elseif prop =~ 'break-\%(before\|after\)' + let values = ["auto", "always", "avoid", "left", "right", "page", "column", "region", "recto", "verso", "avoid-page", "avoid-column", "avoid-region"] + elseif prop == 'break-inside' + let values = ["auto", "avoid", "avoid-page", "avoid-column", "avoid-region"] + elseif prop == 'caption-side' + let values = ["top", "bottom"] + elseif prop == 'clear' + let values = ["none", "left", "right", "both"] + elseif prop == 'clip' + let values = ["auto", "rect("] + elseif prop == 'clip-path' + let values = ["fill-box", "stroke-box", "view-box", "none"] + elseif prop == 'color' + let values = color_values + elseif prop == 'columns' + let values = [] + elseif prop == 'column-count' + let values = ['auto'] + elseif prop == 'column-fill' + let values = ['auto', 'balance'] + elseif prop == 'column-rule-color' + let values = color_values + elseif prop == 'column-rule-style' + let values = border_style_values + elseif prop == 'column-rule-width' + let values = border_width_values + elseif prop == 'column-rule' + let vals = matchstr(line, '.*:\s*\zs.*') + if vals =~ '^\%([a-zA-Z0-9.]\+\)\?$' + let values = border_width_values + elseif vals =~ '^[a-zA-Z0-9.]\+\s\+\%([a-zA-Z]\+\)\?$' + let values = border_style_values + elseif vals =~ '^[a-zA-Z0-9.]\+\s\+[a-zA-Z]\+\s\+\%([a-zA-Z(]\+\)\?$' + let values = color_values + else + return [] + endif + elseif prop == 'column-span' + let values = ["none", "all"] + elseif prop == 'column-width' + let values = ["auto"] + elseif prop == 'content' + let values = ["normal", "attr(", "open-quote", "close-quote", "no-open-quote", "no-close-quote"] + elseif prop =~ 'counter-\%(increment\|reset\)$' + let values = ["none"] + elseif prop =~ 'cue\%(-after\|-before\)\=$' + let values = ["url("] + elseif prop == 'cursor' + let values = ["url(", "auto", "crosshair", "default", "pointer", "move", "e-resize", "ne-resize", "nw-resize", "n-resize", "se-resize", "sw-resize", "s-resize", "w-resize", "text", "wait", "help", "progress"] + elseif prop == 'direction' + let values = ["ltr", "rtl"] + elseif prop == 'display' + let values = ["inline", "block", "list-item", "inline-list-item", "run-in", "inline-block", "table", "inline-table", "table-row-group", "table-header-group", "table-footer-group", "table-row", "table-column-group", "table-column", "table-cell", "table-caption", "none", "flex", "inline-flex", "grid", "inline-grid", "ruby", "ruby-base", "ruby-text", "ruby-base-container", "ruby-text-container", "contents"] + elseif prop == 'elevation' + let values = ["below", "level", "above", "higher", "lower"] + elseif prop == 'empty-cells' + let values = ["show", "hide"] + elseif prop == 'fallback' + let values = list_style_type_values + elseif prop == 'filter' + let values = ["blur(", "brightness(", "contrast(", "drop-shadow(", "grayscale(", "hue-rotate(", "invert(", "opacity(", "sepia(", "saturate("] + elseif prop == 'flex-basis' + let values = ["auto", "content"] + elseif prop == 'flex-flow' + let values = ["row", "row-reverse", "column", "column-reverse", "nowrap", "wrap", "wrap-reverse"] + elseif prop == 'flex-grow' + let values = [] + elseif prop == 'flex-shrink' + let values = [] + elseif prop == 'flex-wrap' + let values = ["nowrap", "wrap", "wrap-reverse"] + elseif prop == 'flex' + let values = ["nowrap", "wrap", "wrap-reverse"] + ["row", "row-reverse", "column", "column-reverse", "nowrap", "wrap", "wrap-reverse"] + ["auto", "content"] + elseif prop == 'float' + let values = ["left", "right", "none"] + elseif prop == 'font-family' + let values = ["sans-serif", "serif", "monospace", "cursive", "fantasy"] + elseif prop == 'font-feature-settings' + let values = ["normal", '"aalt"', '"abvf"', '"abvm"', '"abvs"', '"afrc"', '"akhn"', '"blwf"', '"blwm"', '"blws"', '"calt"', '"case"', '"ccmp"', '"cfar"', '"cjct"', '"clig"', '"cpct"', '"cpsp"', '"cswh"', '"curs"', '"cv', '"c2pc"', '"c2sc"', '"dist"', '"dlig"', '"dnom"', '"dtls"', '"expt"', '"falt"', '"fin2"', '"fin3"', '"fina"', '"flac"', '"frac"', '"fwid"', '"half"', '"haln"', '"halt"', '"hist"', '"hkna"', '"hlig"', '"hngl"', '"hojo"', '"hwid"', '"init"', '"isol"', '"ital"', '"jalt"', '"jp78"', '"jp83"', '"jp90"', '"jp04"', '"kern"', '"lfbd"', '"liga"', '"ljmo"', '"lnum"', '"locl"', '"ltra"', '"ltrm"', '"mark"', '"med2"', '"medi"', '"mgrk"', '"mkmk"', '"mset"', '"nalt"', '"nlck"', '"nukt"', '"numr"', '"onum"', '"opbd"', '"ordn"', '"ornm"', '"palt"', '"pcap"', '"pkna"', '"pnum"', '"pref"', '"pres"', '"pstf"', '"psts"', '"pwid"', '"qwid"', '"rand"', '"rclt"', '"rkrf"', '"rlig"', '"rphf"', '"rtbd"', '"rtla"', '"rtlm"', '"ruby"', '"salt"', '"sinf"', '"size"', '"smcp"', '"smpl"', '"ss01"', '"ss02"', '"ss03"', '"ss04"', '"ss05"', '"ss06"', '"ss07"', '"ss08"', '"ss09"', '"ss10"', '"ss11"', '"ss12"', '"ss13"', '"ss14"', '"ss15"', '"ss16"', '"ss17"', '"ss18"', '"ss19"', '"ss20"', '"ssty"', '"stch"', '"subs"', '"sups"', '"swsh"', '"titl"', '"tjmo"', '"tnam"', '"tnum"', '"trad"', '"twid"', '"unic"', '"valt"', '"vatu"', '"vert"', '"vhal"', '"vjmo"', '"vkna"', '"vkrn"', '"vpal"', '"vrt2"', '"zero"'] + elseif prop == 'font-kerning' + let values = ["auto", "normal", "none"] + elseif prop == 'font-language-override' + let values = ["normal"] + elseif prop == 'font-size' + let values = ["xx-small", "x-small", "small", "medium", "large", "x-large", "xx-large", "larger", "smaller"] + elseif prop == 'font-size-adjust' + let values = [] + elseif prop == 'font-stretch' + let values = ["normal", "ultra-condensed", "extra-condensed", "condensed", "semi-condensed", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded"] + elseif prop == 'font-style' + let values = ["normal", "italic", "oblique"] + elseif prop == 'font-synthesis' + let values = ["none", "weight", "style"] + elseif prop == 'font-variant-alternates' + let values = ["normal", "historical-forms", "stylistic(", "styleset(", "character-variant(", "swash(", "ornaments(", "annotation("] + elseif prop == 'font-variant-caps' + let values = ["normal", "small-caps", "all-small-caps", "petite-caps", "all-petite-caps", "unicase", "titling-caps"] + elseif prop == 'font-variant-asian' + let values = ["normal", "ruby", "jis78", "jis83", "jis90", "jis04", "simplified", "traditional"] + elseif prop == 'font-variant-ligatures' + let values = ["normal", "none", "common-ligatures", "no-common-ligatures", "discretionary-ligatures", "no-discretionary-ligatures", "historical-ligatures", "no-historical-ligatures", "contextual", "no-contextual"] + elseif prop == 'font-variant-numeric' + let values = ["normal", "ordinal", "slashed-zero", "lining-nums", "oldstyle-nums", "proportional-nums", "tabular-nums", "diagonal-fractions", "stacked-fractions"] + elseif prop == 'font-variant-position' + let values = ["normal", "sub", "super"] + elseif prop == 'font-variant' + let values = ["normal", "historical-forms", "stylistic(", "styleset(", "character-variant(", "swash(", "ornaments(", "annotation("] + ["small-caps", "all-small-caps", "petite-caps", "all-petite-caps", "unicase", "titling-caps"] + ["ruby", "jis78", "jis83", "jis90", "jis04", "simplified", "traditional"] + ["none", "common-ligatures", "no-common-ligatures", "discretionary-ligatures", "no-discretionary-ligatures", "historical-ligatures", "no-historical-ligatures", "contextual", "no-contextual"] + ["ordinal", "slashed-zero", "lining-nums", "oldstyle-nums", "proportional-nums", "tabular-nums", "diagonal-fractions", "stacked-fractions"] + ["sub", "super"] + elseif prop == 'font-weight' + let values = ["normal", "bold", "bolder", "lighter", "100", "200", "300", "400", "500", "600", "700", "800", "900"] + elseif prop == 'font' + let values = ["normal", "italic", "oblique", "small-caps", "bold", "bolder", "lighter", "100", "200", "300", "400", "500", "600", "700", "800", "900", "xx-small", "x-small", "small", "medium", "large", "x-large", "xx-large", "larger", "smaller", "sans-serif", "serif", "monospace", "cursive", "fantasy", "caption", "icon", "menu", "message-box", "small-caption", "status-bar"] + elseif prop =~ '^\%(height\|width\)$' + let values = ["auto", "border-box", "content-box", "max-content", "min-content", "available", "fit-content"] + elseif prop =~ '^\%(left\|rigth\)$' + let values = ["auto"] + elseif prop == 'image-rendering' + let values = ["auto", "crisp-edges", "pixelated"] + elseif prop == 'image-orientation' + let values = ["from-image", "flip"] + elseif prop == 'ime-mode' + let values = ["auto", "normal", "active", "inactive", "disabled"] + elseif prop == 'inline-size' + let values = ["auto", "border-box", "content-box", "max-content", "min-content", "available", "fit-content"] + elseif prop == 'isolation' + let values = ["auto", "isolate"] + elseif prop == 'justify-content' + let values = ["flex-start", "flex-end", "center", "space-between", "space-around"] + elseif prop == 'letter-spacing' + let values = ["normal"] + elseif prop == 'line-break' + let values = ["auto", "loose", "normal", "strict"] + elseif prop == 'line-height' + let values = ["normal"] + elseif prop == 'list-style-image' + let values = ["url(", "none"] + elseif prop == 'list-style-position' + let values = ["inside", "outside"] + elseif prop == 'list-style-type' + let values = list_style_type_values + elseif prop == 'list-style' + let values = list_style_type_values + ["inside", "outside"] + ["url(", "none"] + elseif prop == 'margin' + let values = ["auto"] + elseif prop =~ 'margin-\%(right\|left\|top\|bottom\|block-start\|block-end\|inline-start\|inline-end\)$' + let values = ["auto"] + elseif prop == 'marks' + let values = ["crop", "cross", "none"] + elseif prop == 'mask' + let values = ["url("] + elseif prop == 'mask-type' + let values = ["luminance", "alpha"] + elseif prop == '\%(max\|min\)-\%(block\|inline\)-size' + let values = ["auto", "border-box", "content-box", "max-content", "min-content", "available", "fit-content"] + elseif prop == '\%(max\|min\)-\%(height\|width\)' + let values = ["auto", "border-box", "content-box", "max-content", "min-content", "available", "fit-content"] + elseif prop == '\%(max\|min\)-zoom' + let values = ["auto"] + elseif prop == 'mix-blend-mode' + let values = ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"] + elseif prop == 'opacity' + let values = [] + elseif prop == 'orientation' + let values = ["auto", "portrait", "landscape"] + elseif prop == 'orphans' + let values = [] + elseif prop == 'outline-offset' + let values = [] + elseif prop == 'outline-color' + let values = color_values + elseif prop == 'outline-style' + let values = ["none", "hidden", "dotted", "dashed", "solid", "double", "groove", "ridge", "inset", "outset"] + elseif prop == 'outline-width' + let values = ["thin", "thick", "medium"] + elseif prop == 'outline' + let vals = matchstr(line, '.*:\s*\zs.*') + if vals =~ '^\%([a-zA-Z0-9,()#]\+\)\?$' + let values = color_values + elseif vals =~ '^[a-zA-Z0-9,()#]\+\s\+\%([a-zA-Z]\+\)\?$' + let values = ["none", "hidden", "dotted", "dashed", "solid", "double", "groove", "ridge", "inset", "outset"] + elseif vals =~ '^[a-zA-Z0-9,()#]\+\s\+[a-zA-Z]\+\s\+\%([a-zA-Z(]\+\)\?$' + let values = ["thin", "thick", "medium"] + else + return [] + endif + elseif prop == 'overflow-wrap' + let values = ["normal", "break-word"] + elseif prop =~ 'overflow\%(-x\|-y\)\=' + let values = ["visible", "hidden", "scroll", "auto"] + elseif prop == 'pad' + let values = [] + elseif prop == 'padding' + let values = [] + elseif prop =~ 'padding-\%(top\|right\|bottom\|left\|inline-start\|inline-end\|block-start\|block-end\)$' + let values = [] + elseif prop =~ 'page-break-\%(after\|before\)$' + let values = ["auto", "always", "avoid", "left", "right", "recto", "verso"] + elseif prop == 'page-break-inside' + let values = ["auto", "avoid"] + elseif prop =~ 'pause\%(-after\|-before\)\=$' + let values = ["none", "x-weak", "weak", "medium", "strong", "x-strong"] + elseif prop == 'perspective' + let values = ["none"] + elseif prop == 'perspective-origin' + let values = ["top", "bottom", "left", "center", " right"] + elseif prop == 'pointer-events' + let values = ["auto", "none", "visiblePainted", "visibleFill", "visibleStroke", "visible", "painted", "fill", "stroke", "all"] + elseif prop == 'position' + let values = ["static", "relative", "absolute", "fixed", "sticky"] + elseif prop == 'prefix' + let values = [] + elseif prop == 'quotes' + let values = ["none"] + elseif prop == 'range' + let values = ["auto", "infinite"] + elseif prop == 'resize' + let values = ["none", "both", "horizontal", "vertical"] + elseif prop =~ 'rest\%(-after\|-before\)\=$' + let values = ["none", "x-weak", "weak", "medium", "strong", "x-strong"] + elseif prop == 'ruby-align' + let values = ["start", "center", "space-between", "space-around"] + elseif prop == 'ruby-merge' + let values = ["separate", "collapse", "auto"] + elseif prop == 'ruby-position' + let values = ["over", "under", "inter-character"] + elseif prop == 'scroll-behavior' + let values = ["auto", "smooth"] + elseif prop == 'scroll-snap-coordinate' + let values = ["none"] + elseif prop == 'scroll-snap-destination' + return [] + elseif prop == 'scroll-snap-points-\%(x\|y\)$' + let values = ["none", "repeat("] + elseif prop == 'scroll-snap-type\%(-x\|-y\)\=$' + let values = ["none", "mandatory", "proximity"] + elseif prop == 'shape-image-threshold' + let values = [] + elseif prop == 'shape-margin' + let values = [] + elseif prop == 'shape-outside' + let values = ["margin-box", "border-box", "padding-box", "content-box", 'inset(', 'circle(', 'ellipse(', 'polygon(', 'url('] + elseif prop == 'speak' + let values = ["auto", "none", "normal"] + elseif prop == 'speak-as' + let values = ["auto", "normal", "spell-out", "digits"] + elseif prop == 'src' + let values = ["url("] + elseif prop == 'suffix' + let values = [] + elseif prop == 'symbols' + let values = [] + elseif prop == 'system' + let vals = matchstr(line, '.*:\s*\zs.*') + if vals =~ '^extends' + let values = list_style_type_values + else + let values = ["cyclic", "numeric", "alphabetic", "symbolic", "additive", "fixed", "extends"] + endif + elseif prop == 'table-layout' + let values = ["auto", "fixed"] + elseif prop == 'tab-size' + let values = [] + elseif prop == 'text-align' + let values = ["start", "end", "left", "right", "center", "justify", "match-parent"] + elseif prop == 'text-align-last' + let values = ["auto", "start", "end", "left", "right", "center", "justify"] + elseif prop == 'text-combine-upright' + let values = ["none", "all", "digits"] + elseif prop == 'text-decoration-line' + let values = ["none", "underline", "overline", "line-through", "blink"] + elseif prop == 'text-decoration-color' + let values = color_values + elseif prop == 'text-decoration-style' + let values = ["solid", "double", "dotted", "dashed", "wavy"] + elseif prop == 'text-decoration' + let values = ["none", "underline", "overline", "line-through", "blink"] + ["solid", "double", "dotted", "dashed", "wavy"] + color_values + elseif prop == 'text-emphasis-color' + let values = color_values + elseif prop == 'text-emphasis-position' + let values = ["over", "under", "left", "right"] + elseif prop == 'text-emphasis-style' + let values = ["none", "filled", "open", "dot", "circle", "double-circle", "triangle", "sesame"] + elseif prop == 'text-emphasis' + let values = color_values + ["over", "under", "left", "right"] + ["none", "filled", "open", "dot", "circle", "double-circle", "triangle", "sesame"] + elseif prop == 'text-indent' + let values = ["hanging", "each-line"] + elseif prop == 'text-orientation' + let values = ["mixed", "upright", "sideways", "sideways-right", "use-glyph-orientation"] + elseif prop == 'text-overflow' + let values = ["clip", "ellipsis"] + elseif prop == 'text-rendering' + let values = ["auto", "optimizeSpeed", "optimizeLegibility", "geometricPrecision"] + elseif prop == 'text-shadow' + let values = color_values + elseif prop == 'text-transform' + let values = ["capitalize", "uppercase", "lowercase", "full-width", "none"] + elseif prop == 'text-underline-position' + let values = ["auto", "under", "left", "right"] + elseif prop == 'touch-action' + let values = ["auto", "none", "pan-x", "pan-y", "manipulation", "pan-left", "pan-right", "pan-top", "pan-down"] + elseif prop == 'transform' + let values = ["matrix(", "translate(", "translateX(", "translateY(", "scale(", "scaleX(", "scaleY(", "rotate(", "skew(", "skewX(", "skewY(", "matrix3d(", "translate3d(", "translateZ(", "scale3d(", "scaleZ(", "rotate3d(", "rotateX(", "rotateY(", "rotateZ(", "perspective("] + elseif prop == 'transform-box' + let values = ["border-box", "fill-box", "view-box"] + elseif prop == 'transform-origin' + let values = ["left", "center", "right", "top", "bottom"] + elseif prop == 'transform-style' + let values = ["flat", "preserve-3d"] + elseif prop == 'top' + let values = ["auto"] + elseif prop == 'transition-property' + let values = ["all", "none"] + s:values + elseif prop == 'transition-duration' + let values = [] + elseif prop == 'transition-delay' + let values = [] + elseif prop == 'transition-timing-function' + let values = timing_functions + elseif prop == 'transition' + let values = ["all", "none"] + s:values + timing_functions + elseif prop == 'unicode-bidi' + let values = ["normal", "embed", "isolate", "bidi-override", "isolate-override", "plaintext"] + elseif prop == 'unicode-range' + let values = ["U+"] + elseif prop == 'user-zoom' + let values = ["zoom", "fixed"] + elseif prop == 'vertical-align' + let values = ["baseline", "sub", "super", "top", "text-top", "middle", "bottom", "text-bottom"] + elseif prop == 'visibility' + let values = ["visible", "hidden", "collapse"] + elseif prop == 'voice-volume' + let values = ["silent", "x-soft", "soft", "medium", "loud", "x-loud"] + elseif prop == 'voice-balance' + let values = ["left", "center", "right", "leftwards", "rightwards"] + elseif prop == 'voice-family' + let values = [] + elseif prop == 'voice-rate' + let values = ["normal", "x-slow", "slow", "medium", "fast", "x-fast"] + elseif prop == 'voice-pitch' + let values = ["absolute", "x-low", "low", "medium", "high", "x-high"] + elseif prop == 'voice-range' + let values = ["absolute", "x-low", "low", "medium", "high", "x-high"] + elseif prop == 'voice-stress' + let values = ["normal", "strong", "moderate", "none", "reduced "] + elseif prop == 'voice-duration' + let values = ["auto"] + elseif prop == 'white-space' + let values = ["normal", "pre", "nowrap", "pre-wrap", "pre-line"] + elseif prop == 'widows' + let values = [] + elseif prop == 'will-change' + let values = ["auto", "scroll-position", "contents"] + s:values + elseif prop == 'word-break' + let values = ["normal", "break-all", "keep-all"] + elseif prop == 'word-spacing' + let values = ["normal"] + elseif prop == 'word-wrap' + let values = ["normal", "break-word"] + elseif prop == 'writing-mode' + let values = ["horizontal-tb", "vertical-rl", "vertical-lr", "sideways-rl", "sideways-lr"] + elseif prop == 'z-index' + let values = ["auto"] + elseif prop == 'zoom' + let values = ["auto"] + else + " If no property match it is possible we are outside of {} and + " trying to complete pseudo-(class|element) + let element = tolower(matchstr(line, '\zs[a-zA-Z1-6]*\ze:[^:[:space:]]\{-}$')) + if stridx('a,abbr,address,area,article,aside,audio,b,base,bdi,bdo,bgsound,blockquote,body,br,button,canvas,caption,center,cite,code,col,colgroup,command,content,data,datalist,dd,del,details,dfn,dialog,div,dl,dt,element,em,embed,fieldset,figcaption,figure,font,footer,form,frame,frameset,head,header,hgroup,hr,html,i,iframe,image,img,input,ins,isindex,kbd,keygen,label,legend,li,link,main,map,mark,menu,menuitem,meta,meter,nav,nobr,noframes,noscript,object,ol,optgroup,option,output,p,param,picture,pre,progress,q,rp,rt,rtc,ruby,s,samp,script,section,select,shadow,small,source,span,strong,style,sub,summary,sup,table,tbody,td,template,textarea,tfoot,th,thead,time,title,tr,track,u,ul,var,video,wbr', ','.element.',') > -1 + let values = ["active", "any", "checked", "default", "dir(", "disabled", "empty", "enabled", "first", "first-child", "first-of-type", "fullscreen", "focus", "hover", "indeterminate", "in-range", "invalid", "lang(", "last-child", "last-of-type", "left", "link", "not(", "nth-child(", "nth-last-child(", "nth-last-of-type(", "nth-of-type(", "only-child", "only-of-type", "optional", "out-of-range", "read-only", "read-write", "required", "right", "root", "scope", "target", "valid", "visited", "first-line", "first-letter", "before", "after", "selection", "backdrop"] + else + return [] + endif + endif + + let values = wide_keywords + values + " Complete values + let entered_value = matchstr(line, '.\{-}\zs[a-zA-Z0-9#,.(_-]*$') + + for m in values + if m =~? '^'.entered_value + call add(res, m) + elseif m =~? entered_value + call add(res2, m) + endif + endfor + + return res + res2 + + elseif borders[max(keys(borders))] == 'closebrace' + + return [] + + elseif borders[max(keys(borders))] == 'exclam' + + " Complete values + let entered_imp = matchstr(line, '.\{-}!\s*\zs[a-zA-Z ]*$') + + let values = ["important"] + + for m in values + if m =~? '^'.entered_imp + call add(res, m) + endif + endfor + + return res + + elseif borders[max(keys(borders))] == 'atrule' + + let afterat = matchstr(line, '.*@\zs.*') + + if afterat =~ '\s' + + let atrulename = matchstr(line, '.*@\zs[a-zA-Z-]\+\ze') + + if atrulename == 'media' + let entered_atruleafter = matchstr(line, '.*@media\s\+\zs.*$') + + if entered_atruleafter =~ "([^)]*$" + let entered_atruleafter = matchstr(entered_atruleafter, '(\s*\zs[^)]*$') + let values = ["max-width", "min-width", "width", "max-height", "min-height", "height", "max-aspect-ration", "min-aspect-ration", "aspect-ratio", "orientation", "max-resolution", "min-resolution", "resolution", "scan", "grid", "update-frequency", "overflow-block", "overflow-inline", "max-color", "min-color", "color", "max-color-index", "min-color-index", "color-index", "monochrome", "inverted-colors", "pointer", "hover", "any-pointer", "any-hover", "light-level", "scripting"] + else + let values = ["screen", "print", "speech", "all", "not", "and", "("] + endif + + elseif atrulename == 'supports' + let entered_atruleafter = matchstr(line, '.*@supports\s\+\zs.*$') + + if entered_atruleafter =~ "([^)]*$" + let entered_atruleafter = matchstr(entered_atruleafter, '(\s*\zs.*$') + let values = s:values + else + let values = ["("] + endif + + elseif atrulename == 'charset' + let entered_atruleafter = matchstr(line, '.*@charset\s\+\zs.*$') + let values = [ + \ '"UTF-8";', '"ANSI_X3.4-1968";', '"ISO_8859-1:1987";', '"ISO_8859-2:1987";', '"ISO_8859-3:1988";', '"ISO_8859-4:1988";', '"ISO_8859-5:1988";', + \ '"ISO_8859-6:1987";', '"ISO_8859-7:1987";', '"ISO_8859-8:1988";', '"ISO_8859-9:1989";', '"ISO-8859-10";', '"ISO_6937-2-add";', '"JIS_X0201";', + \ '"JIS_Encoding";', '"Shift_JIS";', '"Extended_UNIX_Code_Packed_Format_for_Japanese";', '"Extended_UNIX_Code_Fixed_Width_for_Japanese";', + \ '"BS_4730";', '"SEN_850200_C";', '"IT";', '"ES";', '"DIN_66003";', '"NS_4551-1";', '"NF_Z_62-010";', '"ISO-10646-UTF-1";', '"ISO_646.basic:1983";', + \ '"INVARIANT";', '"ISO_646.irv:1983";', '"NATS-SEFI";', '"NATS-SEFI-ADD";', '"NATS-DANO";', '"NATS-DANO-ADD";', '"SEN_850200_B";', '"KS_C_5601-1987";', + \ '"ISO-2022-KR";', '"EUC-KR";', '"ISO-2022-JP";', '"ISO-2022-JP-2";', '"JIS_C6220-1969-jp";', '"JIS_C6220-1969-ro";', '"PT";', '"greek7-old";', + \ '"latin-greek";', '"NF_Z_62-010_(1973)";', '"Latin-greek-1";', '"ISO_5427";', '"JIS_C6226-1978";', '"BS_viewdata";', '"INIS";', '"INIS-8";', + \ '"INIS-cyrillic";', '"ISO_5427:1981";', '"ISO_5428:1980";', '"GB_1988-80";', '"GB_2312-80";', '"NS_4551-2";', '"videotex-suppl";', '"PT2";', + \ '"ES2";', '"MSZ_7795.3";', '"JIS_C6226-1983";', '"greek7";', '"ASMO_449";', '"iso-ir-90";', '"JIS_C6229-1984-a";', '"JIS_C6229-1984-b";', + \ '"JIS_C6229-1984-b-add";', '"JIS_C6229-1984-hand";', '"JIS_C6229-1984-hand-add";', '"JIS_C6229-1984-kana";', '"ISO_2033-1983";', + \ '"ANSI_X3.110-1983";', '"T.61-7bit";', '"T.61-8bit";', '"ECMA-cyrillic";', '"CSA_Z243.4-1985-1";', '"CSA_Z243.4-1985-2";', '"CSA_Z243.4-1985-gr";', + \ '"ISO_8859-6-E";', '"ISO_8859-6-I";', '"T.101-G2";', '"ISO_8859-8-E";', '"ISO_8859-8-I";', '"CSN_369103";', '"JUS_I.B1.002";', '"IEC_P27-1";', + \ '"JUS_I.B1.003-serb";', '"JUS_I.B1.003-mac";', '"greek-ccitt";', '"NC_NC00-10:81";', '"ISO_6937-2-25";', '"GOST_19768-74";', '"ISO_8859-supp";', + \ '"ISO_10367-box";', '"latin-lap";', '"JIS_X0212-1990";', '"DS_2089";', '"us-dk";', '"dk-us";', '"KSC5636";', '"UNICODE-1-1-UTF-7";', '"ISO-2022-CN";', + \ '"ISO-2022-CN-EXT";', '"ISO-8859-13";', '"ISO-8859-14";', '"ISO-8859-15";', '"ISO-8859-16";', '"GBK";', '"GB18030";', '"OSD_EBCDIC_DF04_15";', + \ '"OSD_EBCDIC_DF03_IRV";', '"OSD_EBCDIC_DF04_1";', '"ISO-11548-1";', '"KZ-1048";', '"ISO-10646-UCS-2";', '"ISO-10646-UCS-4";', '"ISO-10646-UCS-Basic";', + \ '"ISO-10646-Unicode-Latin1";', '"ISO-10646-J-1";', '"ISO-Unicode-IBM-1261";', '"ISO-Unicode-IBM-1268";', '"ISO-Unicode-IBM-1276";', + \ '"ISO-Unicode-IBM-1264";', '"ISO-Unicode-IBM-1265";', '"UNICODE-1-1";', '"SCSU";', '"UTF-7";', '"UTF-16BE";', '"UTF-16LE";', '"UTF-16";', '"CESU-8";', + \ '"UTF-32";', '"UTF-32BE";', '"UTF-32LE";', '"BOCU-1";', '"ISO-8859-1-Windows-3.0-Latin-1";', '"ISO-8859-1-Windows-3.1-Latin-1";', + \ '"ISO-8859-2-Windows-Latin-2";', '"ISO-8859-9-Windows-Latin-5";', '"hp-roman8";', '"Adobe-Standard-Encoding";', '"Ventura-US";', + \ '"Ventura-International";', '"DEC-MCS";', '"IBM850";', '"PC8-Danish-Norwegian";', '"IBM862";', '"PC8-Turkish";', '"IBM-Symbols";', '"IBM-Thai";', + \ '"HP-Legal";', '"HP-Pi-font";', '"HP-Math8";', '"Adobe-Symbol-Encoding";', '"HP-DeskTop";', '"Ventura-Math";', '"Microsoft-Publishing";', + \ '"Windows-31J";', '"GB2312";', '"Big5";', '"macintosh";', '"IBM037";', '"IBM038";', '"IBM273";', '"IBM274";', '"IBM275";', '"IBM277";', '"IBM278";', + \ '"IBM280";', '"IBM281";', '"IBM284";', '"IBM285";', '"IBM290";', '"IBM297";', '"IBM420";', '"IBM423";', '"IBM424";', '"IBM437";', '"IBM500";', '"IBM851";', + \ '"IBM852";', '"IBM855";', '"IBM857";', '"IBM860";', '"IBM861";', '"IBM863";', '"IBM864";', '"IBM865";', '"IBM868";', '"IBM869";', '"IBM870";', '"IBM871";', + \ '"IBM880";', '"IBM891";', '"IBM903";', '"IBM904";', '"IBM905";', '"IBM918";', '"IBM1026";', '"EBCDIC-AT-DE";', '"EBCDIC-AT-DE-A";', '"EBCDIC-CA-FR";', + \ '"EBCDIC-DK-NO";', '"EBCDIC-DK-NO-A";', '"EBCDIC-FI-SE";', '"EBCDIC-FI-SE-A";', '"EBCDIC-FR";', '"EBCDIC-IT";', '"EBCDIC-PT";', '"EBCDIC-ES";', + \ '"EBCDIC-ES-A";', '"EBCDIC-ES-S";', '"EBCDIC-UK";', '"EBCDIC-US";', '"UNKNOWN-8BIT";', '"MNEMONIC";', '"MNEM";', '"VISCII";', '"VIQR";', '"KOI8-R";', + \ '"HZ-GB-2312";', '"IBM866";', '"IBM775";', '"KOI8-U";', '"IBM00858";', '"IBM00924";', '"IBM01140";', '"IBM01141";', '"IBM01142";', '"IBM01143";', + \ '"IBM01144";', '"IBM01145";', '"IBM01146";', '"IBM01147";', '"IBM01148";', '"IBM01149";', '"Big5-HKSCS";', '"IBM1047";', '"PTCP154";', '"Amiga-1251";', + \ '"KOI7-switched";', '"BRF";', '"TSCII";', '"windows-1250";', '"windows-1251";', '"windows-1252";', '"windows-1253";', '"windows-1254";', '"windows-1255";', + \ '"windows-1256";', '"windows-1257";', '"windows-1258";', '"TIS-620";'] + + elseif atrulename == 'namespace' + let entered_atruleafter = matchstr(line, '.*@namespace\s\+\zs.*$') + let values = ["url("] + + elseif atrulename == 'document' + let entered_atruleafter = matchstr(line, '.*@document\s\+\zs.*$') + let values = ["url(", "url-prefix(", "domain(", "regexp("] + + elseif atrulename == 'import' + let entered_atruleafter = matchstr(line, '.*@import\s\+\zs.*$') + + if entered_atruleafter =~ "^[\"']" + let filestart = matchstr(entered_atruleafter, '^.\zs.*') + let files = split(glob(filestart.'*'), '\n') + let values = map(copy(files), '"\"".v:val') + + elseif entered_atruleafter =~ "^url(" + let filestart = matchstr(entered_atruleafter, "^url([\"']\\?\\zs.*") + let files = split(glob(filestart.'*'), '\n') + let values = map(copy(files), '"url(".v:val') + + else + let values = ['"', 'url('] + + endif + + else + return [] + + endif + + for m in values + if m =~? '^'.entered_atruleafter + if entered_atruleafter =~? '^"' && m =~? '^"' + let m = m[1:] + endif + if b:after =~? '"' && stridx(m, '"') > -1 + let m = m[0:stridx(m, '"')-1] + endif + call add(res, m) + elseif m =~? entered_atruleafter + if m =~? '^"' + let m = m[1:] + endif + call add(res2, m) + endif + endfor + + return res + res2 + + endif + + let values = ["charset", "page", "media", "import", "font-face", "namespace", "supports", "keyframes", "viewport", "document"] + + let entered_atrule = matchstr(line, '.*@\zs[a-zA-Z-]*$') + + for m in values + if m =~? '^'.entered_atrule + call add(res, m .' ') + elseif m =~? entered_atrule + call add(res2, m .' ') + endif + endfor + + return res + res2 + + endif + + return [] + +endfunction + +endif diff --git a/autoload/decada.vim b/autoload/decada.vim new file mode 100644 index 0000000..c748302 --- /dev/null +++ b/autoload/decada.vim @@ -0,0 +1,79 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +"------------------------------------------------------------------------------ +" Description: Vim Ada/Dec Ada compiler file +" Language: Ada (Dec Ada) +" $Id: decada.vim 887 2008-07-08 14:29:01Z krischik $ +" Copyright: Copyright (C) 2006 Martin Krischik +" Maintainer: Martin Krischik +" $Author: krischik $ +" $Date: 2008-07-08 16:29:01 +0200 (Di, 08 Jul 2008) $ +" Version: 4.6 +" $Revision: 887 $ +" $HeadURL: https://gnuada.svn.sourceforge.net/svnroot/gnuada/trunk/tools/vim/autoload/decada.vim $ +" History: 21.07.2006 MK New Dec Ada +" 15.10.2006 MK Bram's suggestion for runtime integration +" 05.11.2006 MK Bram suggested not to use include protection for +" autoload +" 05.11.2006 MK Bram suggested to save on spaces +" Help Page: compiler-decada +"------------------------------------------------------------------------------ + +if version < 700 + finish +endif + +function decada#Unit_Name () dict " {{{1 + " Convert filename into acs unit: + " 1: remove the file extenstion. + " 2: replace all double '_' or '-' with an dot (which denotes a separate) + " 3: remove a trailing '_' (wich denotes a specification) + return substitute (substitute (expand ("%:t:r"), '__\|-', ".", "g"), '_$', "", '') +endfunction decada#Unit_Name " }}}1 + +function decada#Make () dict " {{{1 + let l:make_prg = substitute (g:self.Make_Command, '%<', self.Unit_Name(), '') + let &errorformat = g:self.Error_Format + let &makeprg = l:make_prg + wall + make + copen + set wrap + wincmd W +endfunction decada#Build " }}}1 + +function decada#Set_Session (...) dict " {{{1 + if a:0 > 0 + call ada#Switch_Session (a:1) + elseif argc() == 0 && strlen (v:servername) > 0 + call ada#Switch_Session ( + \ expand('~')[0:-2] . ".vimfiles.session]decada_" . + \ v:servername . ".vim") + endif + return +endfunction decada#Set_Session " }}}1 + +function decada#New () " }}}1 + let Retval = { + \ 'Make' : function ('decada#Make'), + \ 'Unit_Name' : function ('decada#Unit_Name'), + \ 'Set_Session' : function ('decada#Set_Session'), + \ 'Project_Dir' : '', + \ 'Make_Command' : 'ACS COMPILE /Wait /Log /NoPreLoad /Optimize=Development /Debug %<', + \ 'Error_Format' : '%+A%%ADAC-%t-%m,%C %#%m,%Zat line number %l in file %f,' . + \ '%+I%%ada-I-%m,%C %#%m,%Zat line number %l in file %f'} + + return Retval +endfunction decada#New " }}}1 + +finish " 1}}} + +"------------------------------------------------------------------------------ +" Copyright (C) 2006 Martin Krischik +" +" Vim is Charityware - see ":help license" or uganda.txt for licence details. +"------------------------------------------------------------------------------ +" vim: textwidth=78 wrap tabstop=8 shiftwidth=3 softtabstop=3 noexpandtab +" vim: foldmethod=marker + +endif diff --git a/autoload/getscript.vim b/autoload/getscript.vim new file mode 100644 index 0000000..06f4d3d --- /dev/null +++ b/autoload/getscript.vim @@ -0,0 +1,671 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" --------------------------------------------------------------------- +" getscript.vim +" Author: Charles E. Campbell +" Date: Jan 21, 2014 +" Version: 36 +" Installing: :help glvs-install +" Usage: :help glvs +" +" GetLatestVimScripts: 642 1 :AutoInstall: getscript.vim +"redraw!|call inputsave()|call input("Press to continue")|call inputrestore() +" --------------------------------------------------------------------- +" Initialization: {{{1 +" if you're sourcing this file, surely you can't be +" expecting vim to be in its vi-compatible mode! +if exists("g:loaded_getscript") + finish +endif +let g:loaded_getscript= "v36" +if &cp + echoerr "GetLatestVimScripts is not vi-compatible; not loaded (you need to set nocp)" + finish +endif +if v:version < 702 + echohl WarningMsg + echo "***warning*** this version of getscript needs vim 7.2" + echohl Normal + finish +endif +let s:keepcpo = &cpo +set cpo&vim +"DechoTabOn + +" --------------------------- +" Global Variables: {{{1 +" --------------------------- +" Cygwin Detection ------- {{{2 +if !exists("g:getscript_cygwin") + if has("win32") || has("win95") || has("win64") || has("win16") + if &shell =~ '\%(\\|\\)\%(\.exe\)\=$' + let g:getscript_cygwin= 1 + else + let g:getscript_cygwin= 0 + endif + else + let g:getscript_cygwin= 0 + endif +endif + +" wget vs curl {{{2 +if !exists("g:GetLatestVimScripts_wget") + if executable("wget") + let g:GetLatestVimScripts_wget= "wget" + elseif executable("curl") + let g:GetLatestVimScripts_wget= "curl" + else + let g:GetLatestVimScripts_wget = 'echo "GetLatestVimScripts needs wget or curl"' + let g:GetLatestVimScripts_options = "" + endif +endif + +" options that wget and curl require: +if !exists("g:GetLatestVimScripts_options") + if g:GetLatestVimScripts_wget == "wget" + let g:GetLatestVimScripts_options= "-q -O" + elseif g:GetLatestVimScripts_wget == "curl" + let g:GetLatestVimScripts_options= "-s -O" + else + let g:GetLatestVimScripts_options= "" + endif +endif + +" by default, allow autoinstall lines to work +if !exists("g:GetLatestVimScripts_allowautoinstall") + let g:GetLatestVimScripts_allowautoinstall= 1 +endif + +" set up default scriptaddr address +if !exists("g:GetLatestVimScripts_scriptaddr") + let g:GetLatestVimScripts_scriptaddr = 'http://vim.sourceforge.net/script.php?script_id=' +endif + +"" For debugging: +"let g:GetLatestVimScripts_wget = "echo" +"let g:GetLatestVimScripts_options = "options" + +" --------------------------------------------------------------------- +" Check If AutoInstall Capable: {{{1 +let s:autoinstall= "" +if g:GetLatestVimScripts_allowautoinstall + + if (has("win32") || has("gui_win32") || has("gui_win32s") || has("win16") || has("win64") || has("win32unix") || has("win95")) && &shell != "bash" + " windows (but not cygwin/bash) + let s:dotvim= "vimfiles" + if !exists("g:GetLatestVimScripts_mv") + let g:GetLatestVimScripts_mv= "ren" + endif + + else + " unix + let s:dotvim= ".vim" + if !exists("g:GetLatestVimScripts_mv") + let g:GetLatestVimScripts_mv= "mv" + endif + endif + + if exists("g:GetLatestVimScripts_autoinstalldir") && isdirectory(g:GetLatestVimScripts_autoinstalldir) + let s:autoinstall= g:GetLatestVimScripts_autoinstalldir" + elseif exists('$HOME') && isdirectory(expand("$HOME")."/".s:dotvim) + let s:autoinstall= $HOME."/".s:dotvim + endif +" call Decho("s:autoinstall<".s:autoinstall.">") +"else "Decho +" call Decho("g:GetLatestVimScripts_allowautoinstall=".g:GetLatestVimScripts_allowautoinstall.": :AutoInstall: disabled") +endif + +" --------------------------------------------------------------------- +" Public Interface: {{{1 +com! -nargs=0 GetLatestVimScripts call getscript#GetLatestVimScripts() +com! -nargs=0 GetScript call getscript#GetLatestVimScripts() +silent! com -nargs=0 GLVS call getscript#GetLatestVimScripts() + +" --------------------------------------------------------------------- +" GetLatestVimScripts: this function gets the latest versions of {{{1 +" scripts based on the list in +" (first dir in runtimepath)/GetLatest/GetLatestVimScripts.dat +fun! getscript#GetLatestVimScripts() +" call Dfunc("GetLatestVimScripts() autoinstall<".s:autoinstall.">") + +" insure that wget is executable + if executable(g:GetLatestVimScripts_wget) != 1 + echoerr "GetLatestVimScripts needs ".g:GetLatestVimScripts_wget." which apparently is not available on your system" +" call Dret("GetLatestVimScripts : wget not executable/availble") + return + endif + + " insure that fnameescape() is available + if !exists("*fnameescape") + echoerr "GetLatestVimScripts needs fnameescape() (provided by 7.1.299 or later)" + return + endif + + " Find the .../GetLatest subdirectory under the runtimepath + for datadir in split(&rtp,',') + [''] + if isdirectory(datadir."/GetLatest") +" call Decho("found directory<".datadir.">") + let datadir= datadir . "/GetLatest" + break + endif + if filereadable(datadir."GetLatestVimScripts.dat") +" call Decho("found ".datadir."/GetLatestVimScripts.dat") + break + endif + endfor + + " Sanity checks: readability and writability + if datadir == "" + echoerr 'Missing "GetLatest/" on your runtimepath - see :help glvs-dist-install' +" call Dret("GetLatestVimScripts : unable to find a GetLatest subdirectory") + return + endif + if filewritable(datadir) != 2 + echoerr "(getLatestVimScripts) Your ".datadir." isn't writable" +" call Dret("GetLatestVimScripts : non-writable directory<".datadir.">") + return + endif + let datafile= datadir."/GetLatestVimScripts.dat" + if !filereadable(datafile) + echoerr "Your data file<".datafile."> isn't readable" +" call Dret("GetLatestVimScripts : non-readable datafile<".datafile.">") + return + endif + if !filewritable(datafile) + echoerr "Your data file<".datafile."> isn't writable" +" call Dret("GetLatestVimScripts : non-writable datafile<".datafile.">") + return + endif + " -------------------- + " Passed sanity checks + " -------------------- + +" call Decho("datadir <".datadir.">") +" call Decho("datafile <".datafile.">") + + " don't let any event handlers interfere (like winmanager's, taglist's, etc) + let eikeep = &ei + let hlskeep = &hls + let acdkeep = &acd + set ei=all hls&vim noacd + + " Edit the datafile (ie. GetLatestVimScripts.dat): + " 1. record current directory (origdir), + " 2. change directory to datadir, + " 3. split window + " 4. edit datafile + let origdir= getcwd() +" call Decho("exe cd ".fnameescape(substitute(datadir,'\','/','ge'))) + exe "cd ".fnameescape(substitute(datadir,'\','/','ge')) + split +" call Decho("exe e ".fnameescape(substitute(datafile,'\','/','ge'))) + exe "e ".fnameescape(substitute(datafile,'\','/','ge')) + res 1000 + let s:downloads = 0 + let s:downerrors= 0 + + " Check on dependencies mentioned in plugins +" call Decho(" ") +" call Decho("searching plugins for GetLatestVimScripts dependencies") + let lastline = line("$") +" call Decho("lastline#".lastline) + let firstdir = substitute(&rtp,',.*$','','') + let plugins = split(globpath(firstdir,"plugin/**/*.vim"),'\n') + let plugins = plugins + split(globpath(firstdir,"AsNeeded/**/*.vim"),'\n') + let foundscript = 0 + + " this loop updates the GetLatestVimScripts.dat file + " with dependencies explicitly mentioned in the plugins + " via GetLatestVimScripts: ... lines + " It reads the plugin script at the end of the GetLatestVimScripts.dat + " file, examines it, and then removes it. + for plugin in plugins +" call Decho(" ") +" call Decho("plugin<".plugin.">") + + " read plugin in + " evidently a :r creates a new buffer (the "#" buffer) that is subsequently unused -- bwiping it + $ +" call Decho(".dependency checking<".plugin."> line$=".line("$")) +" call Decho("..exe silent r ".fnameescape(plugin)) + exe "silent r ".fnameescape(plugin) + exe "silent bwipe ".bufnr("#") + + while search('^"\s\+GetLatestVimScripts:\s\+\d\+\s\+\d\+','W') != 0 + let depscript = substitute(getline("."),'^"\s\+GetLatestVimScripts:\s\+\d\+\s\+\d\+\s\+\(.*\)$','\1','e') + let depscriptid = substitute(getline("."),'^"\s\+GetLatestVimScripts:\s\+\(\d\+\)\s\+.*$','\1','') + let llp1 = lastline+1 +" call Decho("..depscript<".depscript.">") + + " found a "GetLatestVimScripts: # #" line in the script; + " check if it's already in the datafile by searching backwards from llp1, + " the (prior to reading in the plugin script) last line plus one of the GetLatestVimScripts.dat file, + " for the script-id with no wrapping allowed. + let curline = line(".") + let noai_script = substitute(depscript,'\s*:AutoInstall:\s*','','e') + exe llp1 + let srchline = search('^\s*'.depscriptid.'\s\+\d\+\s\+.*$','bW') + if srchline == 0 + " this second search is taken when, for example, a 0 0 scriptname is to be skipped over + let srchline= search('\<'.noai_script.'\>','bW') + endif +" call Decho("..noai_script<".noai_script."> depscriptid#".depscriptid." srchline#".srchline." curline#".line(".")." lastline#".lastline) + + if srchline == 0 + " found a new script to permanently include in the datafile + let keep_rega = @a + let @a = substitute(getline(curline),'^"\s\+GetLatestVimScripts:\s\+','','') + echomsg "Appending <".@a."> to ".datafile." for ".depscript +" call Decho("..Appending <".@a."> to ".datafile." for ".depscript) + exe lastline."put a" + let @a = keep_rega + let lastline = llp1 + let curline = curline + 1 + let foundscript = foundscript + 1 +" else " Decho +" call Decho("..found <".noai_script."> (already in datafile at line#".srchline.")") + endif + + let curline = curline + 1 + exe curline + endwhile + + " llp1: last line plus one + let llp1= lastline + 1 +" call Decho(".deleting lines: ".llp1.",$d") + exe "silent! ".llp1.",$d" + endfor +" call Decho("--- end dependency checking loop --- foundscript=".foundscript) +" call Decho(" ") +" call Dredir("BUFFER TEST (GetLatestVimScripts 1)","ls!") + + if foundscript == 0 + setlocal nomod + endif + + " -------------------------------------------------------------------- + " Check on out-of-date scripts using GetLatest/GetLatestVimScripts.dat + " -------------------------------------------------------------------- +" call Decho("begin: checking out-of-date scripts using datafile<".datafile.">") + setlocal lz + 1 +" /^-----/,$g/^\s*\d/call Decho(getline(".")) + 1 + /^-----/,$g/^\s*\d/call s:GetOneScript() +" call Decho("--- end out-of-date checking --- ") + + " Final report (an echomsg) + try + silent! ?^-------? + catch /^Vim\%((\a\+)\)\=:E114/ +" call Dret("GetLatestVimScripts : nothing done!") + return + endtry + exe "norm! kz\" + redraw! + let s:msg = "" + if s:downloads == 1 + let s:msg = "Downloaded one updated script to <".datadir.">" + elseif s:downloads == 2 + let s:msg= "Downloaded two updated scripts to <".datadir.">" + elseif s:downloads > 1 + let s:msg= "Downloaded ".s:downloads." updated scripts to <".datadir.">" + else + let s:msg= "Everything was already current" + endif + if s:downerrors > 0 + let s:msg= s:msg." (".s:downerrors." downloading errors)" + endif + echomsg s:msg + " save the file + if &mod + silent! w! + endif + q! + + " restore events and current directory + exe "cd ".fnameescape(substitute(origdir,'\','/','ge')) + let &ei = eikeep + let &hls = hlskeep + let &acd = acdkeep + setlocal nolz +" call Dredir("BUFFER TEST (GetLatestVimScripts 2)","ls!") +" call Dret("GetLatestVimScripts : did ".s:downloads." downloads") +endfun + +" --------------------------------------------------------------------- +" GetOneScript: (Get Latest Vim Script) this function operates {{{1 +" on the current line, interpreting two numbers and text as +" ScriptID, SourceID, and Filename. +" It downloads any scripts that have newer versions from vim.sourceforge.net. +fun! s:GetOneScript(...) +" call Dfunc("GetOneScript()") + + " set options to allow progress to be shown on screen + let rega= @a + let t_ti= &t_ti + let t_te= &t_te + let rs = &rs + set t_ti= t_te= nors + + " put current line on top-of-screen and interpret it into + " a script identifer : used to obtain webpage + " source identifier : used to identify current version + " and an associated comment: used to report on what's being considered + if a:0 >= 3 + let scriptid = a:1 + let srcid = a:2 + let fname = a:3 + let cmmnt = "" +" call Decho("scriptid<".scriptid.">") +" call Decho("srcid <".srcid.">") +" call Decho("fname <".fname.">") + else + let curline = getline(".") + if curline =~ '^\s*#' + let @a= rega +" call Dret("GetOneScript : skipping a pure comment line") + return + endif + let parsepat = '^\s*\(\d\+\)\s\+\(\d\+\)\s\+\(.\{-}\)\(\s*#.*\)\=$' + try + let scriptid = substitute(curline,parsepat,'\1','e') + catch /^Vim\%((\a\+)\)\=:E486/ + let scriptid= 0 + endtry + try + let srcid = substitute(curline,parsepat,'\2','e') + catch /^Vim\%((\a\+)\)\=:E486/ + let srcid= 0 + endtry + try + let fname= substitute(curline,parsepat,'\3','e') + catch /^Vim\%((\a\+)\)\=:E486/ + let fname= "" + endtry + try + let cmmnt= substitute(curline,parsepat,'\4','e') + catch /^Vim\%((\a\+)\)\=:E486/ + let cmmnt= "" + endtry +" call Decho("curline <".curline.">") +" call Decho("parsepat<".parsepat.">") +" call Decho("scriptid<".scriptid.">") +" call Decho("srcid <".srcid.">") +" call Decho("fname <".fname.">") + endif + + " plugin author protection from downloading his/her own scripts atop their latest work + if scriptid == 0 || srcid == 0 + " When looking for :AutoInstall: lines, skip scripts that have 0 0 scriptname + let @a= rega +" call Dret("GetOneScript : skipping a scriptid==srcid==0 line") + return + endif + + let doautoinstall= 0 + if fname =~ ":AutoInstall:" +" call Decho("case AutoInstall: fname<".fname.">") + let aicmmnt= substitute(fname,'\s\+:AutoInstall:\s\+',' ','') +" call Decho("aicmmnt<".aicmmnt."> s:autoinstall=".s:autoinstall) + if s:autoinstall != "" + let doautoinstall = g:GetLatestVimScripts_allowautoinstall + endif + else + let aicmmnt= fname + endif +" call Decho("aicmmnt<".aicmmnt.">: doautoinstall=".doautoinstall) + + exe "norm z\" + redraw! +" call Decho('considering <'.aicmmnt.'> scriptid='.scriptid.' srcid='.srcid) + echo 'considering <'.aicmmnt.'> scriptid='.scriptid.' srcid='.srcid + + " grab a copy of the plugin's vim.sourceforge.net webpage + let scriptaddr = g:GetLatestVimScripts_scriptaddr.scriptid + let tmpfile = tempname() + let v:errmsg = "" + + " make up to three tries at downloading the description + let itry= 1 + while itry <= 3 +" call Decho(".try#".itry." to download description of <".aicmmnt."> with addr=".scriptaddr) + if has("win32") || has("win16") || has("win95") +" call Decho(".new|exe silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(tmpfile).' '.shellescape(scriptaddr)."|bw!") + new|exe "silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(tmpfile).' '.shellescape(scriptaddr)|bw! + else +" call Decho(".exe silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(tmpfile)." ".shellescape(scriptaddr)) + exe "silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(tmpfile)." ".shellescape(scriptaddr) + endif + if itry == 1 + exe "silent vsplit ".fnameescape(tmpfile) + else + silent! e % + endif + setlocal bh=wipe + + " find the latest source-id in the plugin's webpage + silent! 1 + let findpkg= search('Click on the package to download','W') + if findpkg > 0 + break + endif + let itry= itry + 1 + endwhile +" call Decho(" --- end downloading tries while loop --- itry=".itry) + + " testing: did finding "Click on the package..." fail? + if findpkg == 0 || itry >= 4 + silent q! + call delete(tmpfile) + " restore options + let &t_ti = t_ti + let &t_te = t_te + let &rs = rs + let s:downerrors = s:downerrors + 1 +" call Decho("***warning*** couldn'".'t find "Click on the package..." in description page for <'.aicmmnt.">") + echomsg "***warning*** couldn'".'t find "Click on the package..." in description page for <'.aicmmnt.">" +" call Dret("GetOneScript : srch for /Click on the package/ failed") + let @a= rega + return + endif +" call Decho('found "Click on the package to download"') + + let findsrcid= search('src_id=','W') + if findsrcid == 0 + silent q! + call delete(tmpfile) + " restore options + let &t_ti = t_ti + let &t_te = t_te + let &rs = rs + let s:downerrors = s:downerrors + 1 +" call Decho("***warning*** couldn'".'t find "src_id=" in description page for <'.aicmmnt.">") + echomsg "***warning*** couldn'".'t find "src_id=" in description page for <'.aicmmnt.">" + let @a= rega +" call Dret("GetOneScript : srch for /src_id/ failed") + return + endif +" call Decho('found "src_id=" in description page') + + let srcidpat = '^\s*\([^<]\+\)<.*$' + let latestsrcid= substitute(getline("."),srcidpat,'\1','') + let sname = substitute(getline("."),srcidpat,'\2','') " script name actually downloaded +" call Decho("srcidpat<".srcidpat."> latestsrcid<".latestsrcid."> sname<".sname.">") + silent q! + call delete(tmpfile) + + " convert the strings-of-numbers into numbers + let srcid = srcid + 0 + let latestsrcid = latestsrcid + 0 +" call Decho("srcid=".srcid." latestsrcid=".latestsrcid." sname<".sname.">") + + " has the plugin's most-recent srcid increased, which indicates that it has been updated + if latestsrcid > srcid +" call Decho("[latestsrcid=".latestsrcid."] <= [srcid=".srcid."]: need to update <".sname.">") + + let s:downloads= s:downloads + 1 + if sname == bufname("%") + " GetLatestVimScript has to be careful about downloading itself + let sname= "NEW_".sname + endif + + " ----------------------------------------------------------------------------- + " the plugin has been updated since we last obtained it, so download a new copy + " ----------------------------------------------------------------------------- +" call Decho(".downloading new <".sname.">") + echomsg ".downloading new <".sname.">" + if has("win32") || has("win16") || has("win95") +" call Decho(".new|exe silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id='.latestsrcid)."|q") + new|exe "silent r!".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id='.latestsrcid)|q + else +" call Decho(".exe silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id=')) + exe "silent !".g:GetLatestVimScripts_wget." ".g:GetLatestVimScripts_options." ".shellescape(sname)." ".shellescape('http://vim.sourceforge.net/scripts/download_script.php?src_id=').latestsrcid + endif + + " -------------------------------------------------------------------------- + " AutoInstall: only if doautoinstall has been requested by the plugin itself + " -------------------------------------------------------------------------- +" call Decho("checking if plugin requested autoinstall: doautoinstall=".doautoinstall) + if doautoinstall +" call Decho(" ") +" call Decho("Autoinstall: getcwd<".getcwd()."> filereadable(".sname.")=".filereadable(sname)) + if filereadable(sname) +" call Decho("<".sname."> is readable") +" call Decho("exe silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".shellescape(s:autoinstall)) + exe "silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".shellescape(s:autoinstall) + let curdir = fnameescape(substitute(getcwd(),'\','/','ge')) + let installdir= curdir."/Installed" + if !isdirectory(installdir) + call mkdir(installdir) + endif +" call Decho("curdir<".curdir."> installdir<".installdir.">") +" call Decho("exe cd ".fnameescape(s:autoinstall)) + exe "cd ".fnameescape(s:autoinstall) + + " determine target directory for moves + let firstdir= substitute(&rtp,',.*$','','') + let pname = substitute(sname,'\..*','.vim','') +" call Decho("determine tgtdir: is <".firstdir.'/AsNeeded/'.pname." readable?") + if filereadable(firstdir.'/AsNeeded/'.pname) + let tgtdir= "AsNeeded" + else + let tgtdir= "plugin" + endif +" call Decho("tgtdir<".tgtdir."> pname<".pname.">") + + " decompress + if sname =~ '\.bz2$' +" call Decho("decompress: attempt to bunzip2 ".sname) + exe "sil !bunzip2 ".shellescape(sname) + let sname= substitute(sname,'\.bz2$','','') +" call Decho("decompress: new sname<".sname."> after bunzip2") + elseif sname =~ '\.gz$' +" call Decho("decompress: attempt to gunzip ".sname) + exe "sil !gunzip ".shellescape(sname) + let sname= substitute(sname,'\.gz$','','') +" call Decho("decompress: new sname<".sname."> after gunzip") + elseif sname =~ '\.xz$' +" call Decho("decompress: attempt to unxz ".sname) + exe "sil !unxz ".shellescape(sname) + let sname= substitute(sname,'\.xz$','','') +" call Decho("decompress: new sname<".sname."> after unxz") + else +" call Decho("no decompression needed") + endif + + " distribute archive(.zip, .tar, .vba, ...) contents + if sname =~ '\.zip$' +" call Decho("dearchive: attempt to unzip ".sname) + exe "silent !unzip -o ".shellescape(sname) + elseif sname =~ '\.tar$' +" call Decho("dearchive: attempt to untar ".sname) + exe "silent !tar -xvf ".shellescape(sname) + elseif sname =~ '\.tgz$' +" call Decho("dearchive: attempt to untar+gunzip ".sname) + exe "silent !tar -zxvf ".shellescape(sname) + elseif sname =~ '\.taz$' +" call Decho("dearchive: attempt to untar+uncompress ".sname) + exe "silent !tar -Zxvf ".shellescape(sname) + elseif sname =~ '\.tbz$' +" call Decho("dearchive: attempt to untar+bunzip2 ".sname) + exe "silent !tar -jxvf ".shellescape(sname) + elseif sname =~ '\.txz$' +" call Decho("dearchive: attempt to untar+xz ".sname) + exe "silent !tar -Jxvf ".shellescape(sname) + elseif sname =~ '\.vba$' +" call Decho("dearchive: attempt to handle a vimball: ".sname) + silent 1split + if exists("g:vimball_home") + let oldvimballhome= g:vimball_home + endif + let g:vimball_home= s:autoinstall + exe "silent e ".fnameescape(sname) + silent so % + silent q + if exists("oldvimballhome") + let g:vimball_home= oldvimballhome + else + unlet g:vimball_home + endif + else +" call Decho("no dearchiving needed") + endif + + " --------------------------------------------- + " move plugin to plugin/ or AsNeeded/ directory + " --------------------------------------------- + if sname =~ '.vim$' +" call Decho("dearchive: attempt to simply move ".sname." to ".tgtdir) + exe "silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".tgtdir + else +" call Decho("dearchive: move <".sname."> to installdir<".installdir.">") + exe "silent !".g:GetLatestVimScripts_mv." ".shellescape(sname)." ".installdir + endif + if tgtdir != "plugin" +" call Decho("exe silent !".g:GetLatestVimScripts_mv." plugin/".shellescape(pname)." ".tgtdir) + exe "silent !".g:GetLatestVimScripts_mv." plugin/".shellescape(pname)." ".tgtdir + endif + + " helptags step + let docdir= substitute(&rtp,',.*','','e')."/doc" +" call Decho("helptags: docdir<".docdir.">") + exe "helptags ".fnameescape(docdir) + exe "cd ".fnameescape(curdir) + endif + if fname !~ ':AutoInstall:' + let modline=scriptid." ".latestsrcid." :AutoInstall: ".fname.cmmnt + else + let modline=scriptid." ".latestsrcid." ".fname.cmmnt + endif + else + let modline=scriptid." ".latestsrcid." ".fname.cmmnt + endif + + " update the data in the file + call setline(line("."),modline) +" call Decho("update data in ".expand("%")."#".line(".").": modline<".modline.">") +" else " Decho +" call Decho("[latestsrcid=".latestsrcid."] <= [srcid=".srcid."], no need to update") + endif + + " restore options + let &t_ti = t_ti + let &t_te = t_te + let &rs = rs + let @a = rega +" call Dredir("BUFFER TEST (GetOneScript)","ls!") + +" call Dret("GetOneScript") +endfun + +" --------------------------------------------------------------------- +" Restore Options: {{{1 +let &cpo= s:keepcpo +unlet s:keepcpo + +" --------------------------------------------------------------------- +" Modelines: {{{1 +" vim: ts=8 sts=2 fdm=marker nowrap + +endif diff --git a/autoload/gnat.vim b/autoload/gnat.vim new file mode 100644 index 0000000..4c7b672 --- /dev/null +++ b/autoload/gnat.vim @@ -0,0 +1,151 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +"------------------------------------------------------------------------------ +" Description: Vim Ada/GNAT compiler file +" Language: Ada (GNAT) +" $Id: gnat.vim 887 2008-07-08 14:29:01Z krischik $ +" Copyright: Copyright (C) 2006 Martin Krischik +" Maintainer: Martin Krischi k +" Ned Okie +" $Author: krischik $ +" $Date: 2008-07-08 16:29:01 +0200 (Di, 08 Jul 2008) $ +" Version: 4.6 +" $Revision: 887 $ +" $HeadURL: https://gnuada.svn.sourceforge.net/svnroot/gnuada/trunk/tools/vim/autoload/gnat.vim $ +" History: 24.05.2006 MK Unified Headers +" 16.07.2006 MK Ada-Mode as vim-ball +" 05.08.2006 MK Add session support +" 15.10.2006 MK Bram's suggestion for runtime integration +" 05.11.2006 MK Bram suggested not to use include protection for +" autoload +" 05.11.2006 MK Bram suggested to save on spaces +" 19.09.2007 NO use project file only when there is a project +" Help Page: compiler-gnat +"------------------------------------------------------------------------------ + +if version < 700 + finish +endif + +function gnat#Make () dict " {{{1 + let &l:makeprg = self.Get_Command('Make') + let &l:errorformat = self.Error_Format + wall + make + copen + set wrap + wincmd W +endfunction gnat#Make " }}}1 + +function gnat#Pretty () dict " {{{1 + execute "!" . self.Get_Command('Pretty') +endfunction gnat#Make " }}}1 + +function gnat#Find () dict " {{{1 + execute "!" . self.Get_Command('Find') +endfunction gnat#Find " }}}1 + +function gnat#Tags () dict " {{{1 + execute "!" . self.Get_Command('Tags') + edit tags + call gnat#Insert_Tags_Header () + update + quit +endfunction gnat#Tags " }}}1 + +function gnat#Set_Project_File (...) dict " {{{1 + if a:0 > 0 + let self.Project_File = a:1 + + if ! filereadable (self.Project_File) + let self.Project_File = findfile ( + \ fnamemodify (self.Project_File, ':r'), + \ $ADA_PROJECT_PATH, + \ 1) + endif + elseif strlen (self.Project_File) > 0 + let self.Project_File = browse (0, 'GNAT Project File?', '', self.Project_File) + elseif expand ("%:e") == 'gpr' + let self.Project_File = browse (0, 'GNAT Project File?', '', expand ("%:e")) + else + let self.Project_File = browse (0, 'GNAT Project File?', '', 'default.gpr') + endif + + if strlen (v:this_session) > 0 + execute 'mksession! ' . v:this_session + endif + + "if strlen (self.Project_File) > 0 + "if has("vms") + "call ada#Switch_Session ( + "\ expand('~')[0:-2] . ".vimfiles.session]gnat_" . + "\ fnamemodify (self.Project_File, ":t:r") . ".vim") + "else + "call ada#Switch_Session ( + "\ expand('~') . "/vimfiles/session/gnat_" . + "\ fnamemodify (self.Project_File, ":t:r") . ".vim") + "endif + "else + "call ada#Switch_Session ('') + "endif + + return +endfunction gnat#Set_Project_File " }}}1 + +function gnat#Get_Command (Command) dict " {{{1 + let l:Command = eval ('self.' . a:Command . '_Command') + return eval (l:Command) +endfunction gnat#Get_Command " }}}1 + +function gnat#Set_Session (...) dict " {{{1 + if argc() == 1 && fnamemodify (argv(0), ':e') == 'gpr' + call self.Set_Project_File (argv(0)) + elseif strlen (v:servername) > 0 + call self.Set_Project_File (v:servername . '.gpr') + endif +endfunction gnat#Set_Session " }}}1 + +function gnat#New () " {{{1 + let l:Retval = { + \ 'Make' : function ('gnat#Make'), + \ 'Pretty' : function ('gnat#Pretty'), + \ 'Find' : function ('gnat#Find'), + \ 'Tags' : function ('gnat#Tags'), + \ 'Set_Project_File' : function ('gnat#Set_Project_File'), + \ 'Set_Session' : function ('gnat#Set_Session'), + \ 'Get_Command' : function ('gnat#Get_Command'), + \ 'Project_File' : '', + \ 'Make_Command' : '"gnat make -P " . self.Project_File . " -F -gnatef "', + \ 'Pretty_Command' : '"gnat pretty -P " . self.Project_File . " "', + \ 'Find_Program' : '"gnat find -P " . self.Project_File . " -F "', + \ 'Tags_Command' : '"gnat xref -P " . self.Project_File . " -v *.AD*"', + \ 'Error_Format' : '%f:%l:%c: %trror: %m,' . + \ '%f:%l:%c: %tarning: %m,' . + \ '%f:%l:%c: (%ttyle) %m'} + + return l:Retval +endfunction gnat#New " }}}1 + +function gnat#Insert_Tags_Header () " {{{1 + 1insert +!_TAG_FILE_FORMAT 1 /extended format; --format=1 will not append ;" to lines/ +!_TAG_FILE_SORTED 1 /0=unsorted, 1=sorted, 2=foldcase/ +!_TAG_PROGRAM_AUTHOR AdaCore /info@adacore.com/ +!_TAG_PROGRAM_NAME gnatxref // +!_TAG_PROGRAM_URL http://www.adacore.com /official site/ +!_TAG_PROGRAM_VERSION 5.05w // +. + return +endfunction gnat#Insert_Tags_Header " }}}1 + +finish " 1}}} + +"------------------------------------------------------------------------------ +" Copyright (C) 2006 Martin Krischik +" +" Vim is Charityware - see ":help license" or uganda.txt for licence details. +"------------------------------------------------------------------------------ +" vim: textwidth=0 wrap tabstop=8 shiftwidth=3 softtabstop=3 noexpandtab +" vim: foldmethod=marker + +endif diff --git a/autoload/gzip.vim b/autoload/gzip.vim new file mode 100644 index 0000000..39ae410 --- /dev/null +++ b/autoload/gzip.vim @@ -0,0 +1,224 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim autoload file for editing compressed files. +" Maintainer: Bram Moolenaar +" Last Change: 2016 Sep 28 + +" These functions are used by the gzip plugin. + +" Function to check that executing "cmd [-f]" works. +" The result is cached in s:have_"cmd" for speed. +fun s:check(cmd) + let name = substitute(a:cmd, '\(\S*\).*', '\1', '') + if !exists("s:have_" . name) + let e = executable(name) + if e < 0 + let r = system(name . " --version") + let e = (r !~ "not found" && r != "") + endif + exe "let s:have_" . name . "=" . e + endif + exe "return s:have_" . name +endfun + +" Set b:gzip_comp_arg to the gzip argument to be used for compression, based on +" the flags in the compressed file. +" The only compression methods that can be detected are max speed (-1) and max +" compression (-9). +fun s:set_compression(line) + " get the Compression Method + let l:cm = char2nr(a:line[2]) + " if it's 8 (DEFLATE), we can check for the compression level + if l:cm == 8 + " get the eXtra FLags + let l:xfl = char2nr(a:line[8]) + " max compression + if l:xfl == 2 + let b:gzip_comp_arg = "-9" + " min compression + elseif l:xfl == 4 + let b:gzip_comp_arg = "-1" + endif + endif +endfun + + +" After reading compressed file: Uncompress text in buffer with "cmd" +fun gzip#read(cmd) + " don't do anything if the cmd is not supported + if !s:check(a:cmd) + return + endif + + " for gzip check current compression level and set b:gzip_comp_arg. + silent! unlet b:gzip_comp_arg + if a:cmd[0] == 'g' + call s:set_compression(getline(1)) + endif + + " make 'patchmode' empty, we don't want a copy of the written file + let pm_save = &pm + set pm= + " remove 'a' and 'A' from 'cpo' to avoid the alternate file changes + let cpo_save = &cpo + set cpo-=a cpo-=A + " set 'modifiable' + let ma_save = &ma + setlocal ma + " set 'write' + let write_save = &write + set write + " Reset 'foldenable', otherwise line numbers get adjusted. + if has("folding") + let fen_save = &fen + setlocal nofen + endif + + " when filtering the whole buffer, it will become empty + let empty = line("'[") == 1 && line("']") == line("$") + let tmp = tempname() + let tmpe = tmp . "." . expand(":e") + if exists('*fnameescape') + let tmp_esc = fnameescape(tmp) + let tmpe_esc = fnameescape(tmpe) + else + let tmp_esc = escape(tmp, ' ') + let tmpe_esc = escape(tmpe, ' ') + endif + " write the just read lines to a temp file "'[,']w tmp.gz" + execute "silent '[,']w " . tmpe_esc + " uncompress the temp file: call system("gzip -dn tmp.gz") + call system(a:cmd . " " . s:escape(tmpe)) + if !filereadable(tmp) + " uncompress didn't work! Keep the compressed file then. + echoerr "Error: Could not read uncompressed file" + let ok = 0 + else + let ok = 1 + " delete the compressed lines; remember the line number + let l = line("'[") - 1 + if exists(":lockmarks") + lockmarks '[,']d _ + else + '[,']d _ + endif + " read in the uncompressed lines "'[-1r tmp" + " Use ++edit if the buffer was empty, keep the 'ff' and 'fenc' options. + setlocal nobin + if exists(":lockmarks") + if empty + execute "silent lockmarks " . l . "r ++edit " . tmp_esc + else + execute "silent lockmarks " . l . "r " . tmp_esc + endif + else + execute "silent " . l . "r " . tmp_esc + endif + + " if buffer became empty, delete trailing blank line + if empty + silent $delete _ + 1 + endif + " delete the temp file and the used buffers + call delete(tmp) + silent! exe "bwipe " . tmp_esc + silent! exe "bwipe " . tmpe_esc + endif + " Store the OK flag, so that we can use it when writing. + let b:uncompressOk = ok + + " Restore saved option values. + let &pm = pm_save + let &cpo = cpo_save + let &l:ma = ma_save + let &write = write_save + if has("folding") + let &l:fen = fen_save + endif + + " When uncompressed the whole buffer, do autocommands + if ok && empty + if exists('*fnameescape') + let fname = fnameescape(expand("%:r")) + else + let fname = escape(expand("%:r"), " \t\n*?[{`$\\%#'\"|!<") + endif + if &verbose >= 8 + execute "doau BufReadPost " . fname + else + execute "silent! doau BufReadPost " . fname + endif + endif +endfun + +" After writing compressed file: Compress written file with "cmd" +fun gzip#write(cmd) + if exists('b:uncompressOk') && !b:uncompressOk + echomsg "Not compressing file because uncompress failed; reset b:uncompressOk to compress anyway" + " don't do anything if the cmd is not supported + elseif s:check(a:cmd) + " Rename the file before compressing it. + let nm = resolve(expand("")) + let nmt = s:tempname(nm) + if rename(nm, nmt) == 0 + if exists("b:gzip_comp_arg") + call system(a:cmd . " " . b:gzip_comp_arg . " -- " . s:escape(nmt)) + else + call system(a:cmd . " -- " . s:escape(nmt)) + endif + call rename(nmt . "." . expand(":e"), nm) + endif + endif +endfun + +" Before appending to compressed file: Uncompress file with "cmd" +fun gzip#appre(cmd) + " don't do anything if the cmd is not supported + if s:check(a:cmd) + let nm = expand("") + + " for gzip check current compression level and set b:gzip_comp_arg. + silent! unlet b:gzip_comp_arg + if a:cmd[0] == 'g' + call s:set_compression(readfile(nm, "b", 1)[0]) + endif + + " Rename to a weird name to avoid the risk of overwriting another file + let nmt = expand(":p:h") . "/X~=@l9q5" + let nmte = nmt . "." . expand(":e") + if rename(nm, nmte) == 0 + if &patchmode != "" && getfsize(nm . &patchmode) == -1 + " Create patchmode file by creating the decompressed file new + call system(a:cmd . " -c -- " . s:escape(nmte) . " > " . s:escape(nmt)) + call rename(nmte, nm . &patchmode) + else + call system(a:cmd . " -- " . s:escape(nmte)) + endif + call rename(nmt, nm) + endif + endif +endfun + +" find a file name for the file to be compressed. Use "name" without an +" extension if possible. Otherwise use a weird name to avoid overwriting an +" existing file. +fun s:tempname(name) + let fn = fnamemodify(a:name, ":r") + if !filereadable(fn) && !isdirectory(fn) + return fn + endif + return fnamemodify(a:name, ":p:h") . "/X~=@l9q5" +endfun + +fun s:escape(name) + " shellescape() was added by patch 7.0.111 + if exists("*shellescape") + return shellescape(a:name) + endif + return "'" . a:name . "'" +endfun + +" vim: set sw=2 : + +endif diff --git a/autoload/htmlcomplete.vim b/autoload/htmlcomplete.vim index fc9a4b5..1ef80e3 100644 --- a/autoload/htmlcomplete.vim +++ b/autoload/htmlcomplete.vim @@ -1,3 +1,815 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim completion script +" Language: HTML and XHTML +" Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl ) +" Last Change: 2014 Jun 20 + +" Distinguish between HTML versions. +" To use with other HTML versions add another "elseif" condition to match +" proper DOCTYPE. +function! htmlcomplete#DetectOmniFlavor() + if &filetype == 'xhtml' + let b:html_omni_flavor = 'xhtml10s' + else + let b:html_omni_flavor = 'html401t' + endif + let i = 1 + let line = "" + while i < 10 && i < line("$") + let line = getline(i) + if line =~ '' + let b:html_omni_flavor = 'html40' + endif + if line =~ '\' + let b:html_omni_flavor .= 't' + elseif line =~ '\' + let b:html_omni_flavor .= 'f' + else + let b:html_omni_flavor .= 's' + endif + endif + endif +endfunction + +function! htmlcomplete#CompleteTags(findstart, base) + if a:findstart + " locate the start of the word + let line = getline('.') + let start = col('.') - 1 + let curline = line('.') + let compl_begin = col('.') - 2 + while start >= 0 && line[start - 1] =~ '\(\k\|[!:.-]\)' + let start -= 1 + endwhile + " Handling of entities {{{ + if start >= 0 && line[start - 1] =~ '&' + let b:entitiescompl = 1 + let b:compl_context = '' + return start + endif + " }}} + " Handling of ') + if style_start > 0 && style_end > 0 + let buf_styles = getline(style_start + 1, style_end - 1) + for a_style in buf_styles + if index(style, a_style) == -1 + if diff_style_start == 0 + if a_style =~ '\\_s\+.*id='oneCharWidth'.*\_s\+.*id='oneInputWidth'.*\_s\+.*id='oneEmWidth'\)\?\zs/d_ + $ + ??,$d_ + let temp = getline(1,'$') + " clean out id on the main content container because we already set it on + " the table + let temp[0] = substitute(temp[0], " id='vimCodeElement[^']*'", "", "") + " undo deletion of start and end part + " so we can later save the file as valid html + " TODO: restore using grabbed lines if undolevel is 1? + normal! 2u + if s:settings.use_css + call add(html, '
') + elseif s:settings.use_xhtml + call add(html, '
') + else + call add(html, '
') + endif + let html += temp + call add(html, '
') + + " Close this buffer + " TODO: the comment above says we're going to allow saving the file + " later...but here we discard it? + quit! + endfor + + let html[body_line_num] = body_line + + call add(html, '') + call add(html, '') + call add(html, s:body_end_line) + call add(html, '') + + " The generated HTML is admittedly ugly and takes a LONG time to fold. + " Make sure the user doesn't do syntax folding when loading a generated file, + " using a modeline. + call add(html, '') + + let i = 1 + let name = "Diff" . (s:settings.use_xhtml ? ".xhtml" : ".html") + " Find an unused file name if current file name is already in use + while filereadable(name) + let name = substitute(name, '\d*\.x\?html$', '', '') . i . '.' . fnamemodify(copy(name), ":t:e") + let i += 1 + endwhile + exe "topleft new " . name + setlocal modifiable + + " just in case some user autocmd creates content in the new buffer, make sure + " it is empty before proceeding + %d + + " set the fileencoding to match the charset we'll be using + let &l:fileencoding=s:settings.vim_encoding + + " According to http://www.w3.org/TR/html4/charset.html#doc-char-set, the byte + " order mark is highly recommend on the web when using multibyte encodings. But, + " it is not a good idea to include it on UTF-8 files. Otherwise, let Vim + " determine when it is actually inserted. + if s:settings.vim_encoding == 'utf-8' + setlocal nobomb + else + setlocal bomb + endif + + call append(0, html) + + if len(style) > 0 + 1 + let style_start = search('^')-1 + + " add required javascript in reverse order so we can just call append again + " and again without adjusting {{{ + + " insert script closing tag + call append(style_start, [ + \ '', + \ s:settings.use_xhtml ? '//]]>' : '-->', + \ "" + \ ]) + + " insert script which corrects the size of small input elements in + " prevent_copy mode. See 2html.vim for details on why this is needed and how + " it works. + if !empty(s:settings.prevent_copy) + call append(style_start, [ + \ '', + \ '/* simulate a "ch" unit by asking the browser how big a zero character is */', + \ 'function FixCharWidth() {', + \ ' /* get the hidden element which gives the width of a single character */', + \ ' var goodWidth = document.getElementById("oneCharWidth").clientWidth;', + \ ' /* get all input elements, we''ll filter on class later */', + \ ' var inputTags = document.getElementsByTagName("input");', + \ ' var ratio = 5;', + \ ' var inputWidth = document.getElementById("oneInputWidth").clientWidth;', + \ ' var emWidth = document.getElementById("oneEmWidth").clientWidth;', + \ ' if (inputWidth > goodWidth) {', + \ ' while (ratio < 100*goodWidth/emWidth && ratio < 100) {', + \ ' ratio += 5;', + \ ' }', + \ ' document.getElementById("vimCodeElement'.s:settings.id_suffix.'").className = "em"+ratio;', + \ ' }', + \ '}' + \ ]) + endif + " + " insert javascript to get IDs from line numbers, and to open a fold before + " jumping to any lines contained therein + call append(style_start, [ + \ " /* Always jump to new location even if the line was hidden inside a fold, or", + \ " * we corrected the raw number to a line ID.", + \ " */", + \ " if (lineElem) {", + \ " lineElem.scrollIntoView(true);", + \ " }", + \ " return true;", + \ "}", + \ "if ('onhashchange' in window) {", + \ " window.onhashchange = JumpToLine;", + \ "}" + \ ]) + if s:settings.dynamic_folds + call append(style_start, [ + \ "", + \ " /* navigate upwards in the DOM tree to open all folds containing the line */", + \ " var node = lineElem;", + \ " while (node && node.id != 'vimCodeElement".s:settings.id_suffix."')", + \ " {", + \ " if (node.className == 'closed-fold')", + \ " {", + \ " /* toggle open the fold ID (remove window ID) */", + \ " toggleFold(node.id.substr(4));", + \ " }", + \ " node = node.parentNode;", + \ " }", + \ ]) + endif + call append(style_start, [ + \ "", + \ "/* function to open any folds containing a jumped-to line before jumping to it */", + \ "function JumpToLine()", + \ "{", + \ " var lineNum;", + \ " lineNum = window.location.hash;", + \ " lineNum = lineNum.substr(1); /* strip off '#' */", + \ "", + \ " if (lineNum.indexOf('L') == -1) {", + \ " lineNum = 'L'+lineNum;", + \ " }", + \ " if (lineNum.indexOf('W') == -1) {", + \ " lineNum = 'W1'+lineNum;", + \ " }", + \ " lineElem = document.getElementById(lineNum);" + \ ]) + + " Insert javascript to toggle matching folds open and closed in all windows, + " if dynamic folding is active. + if s:settings.dynamic_folds + call append(style_start, [ + \ " function toggleFold(objID)", + \ " {", + \ " for (win_num = 1; win_num <= ".len(a:buf_list)."; win_num++)", + \ " {", + \ " var fold;", + \ ' fold = document.getElementById("win"+win_num+objID);', + \ " if(fold.className == 'closed-fold')", + \ " {", + \ " fold.className = 'open-fold';", + \ " }", + \ " else if (fold.className == 'open-fold')", + \ " {", + \ " fold.className = 'closed-fold';", + \ " }", + \ " }", + \ " }", + \ ]) + endif + + " insert script tag; javascript is always needed for the line number + " normalization for URL hashes + call append(style_start, [ + \ "" + \ ]) + +call extend(s:lines, [""]) +if !empty(s:settings.prevent_copy) + call extend(s:lines, + \ ["", + \ "", + \ "
0
", + \ "
", + \ "
" + \ ]) +else + call extend(s:lines, [""]) +endif +if s:settings.no_pre + " if we're not using CSS we use a font tag which can't have a div inside + if s:settings.use_css + call extend(s:lines, ["
"]) + endif +else + call extend(s:lines, ["
"])
+endif
+
+exe s:orgwin . "wincmd w"
+
+" caches of style data
+" initialize to include line numbers if using them
+if s:settings.number_lines
+  let s:stylelist = { s:LINENR_ID : ".LineNr { " . s:CSS1( s:LINENR_ID ) . "}" }
+else
+  let s:stylelist = {}
+endif
+let s:diffstylelist = {
+      \   s:DIFF_A_ID : ".DiffAdd { " . s:CSS1( s:DIFF_A_ID ) . "}",
+      \   s:DIFF_C_ID : ".DiffChange { " . s:CSS1( s:DIFF_C_ID ) . "}",
+      \   s:DIFF_D_ID : ".DiffDelete { " . s:CSS1( s:DIFF_D_ID ) . "}",
+      \   s:DIFF_T_ID : ".DiffText { " . s:CSS1( s:DIFF_T_ID ) . "}"
+      \ }
+
+" set up progress bar in the status line
+if !s:settings.no_progress
+  " ProgressBar Indicator
+  let s:progressbar={}
+
+  " Progessbar specific functions
+  func! s:ProgressBar(title, max_value, winnr)
+    let pgb=copy(s:progressbar)
+    let pgb.title = a:title.' '
+    let pgb.max_value = a:max_value
+    let pgb.winnr = a:winnr
+    let pgb.cur_value = 0
+    let pgb.items = { 'title'   : { 'color' : 'Statusline' },
+	  \'bar'     : { 'color' : 'Statusline' , 'fillcolor' : 'DiffDelete' , 'bg' : 'Statusline' } ,
+	  \'counter' : { 'color' : 'Statusline' } }
+    let pgb.last_value = 0
+    let pgb.needs_redraw = 0
+    " Note that you must use len(split) instead of len() if you want to use 
+    " unicode in title.
+    "
+    " Subtract 3 for spacing around the title.
+    " Subtract 4 for the percentage display.
+    " Subtract 2 for spacing before this.
+    " Subtract 2 more for the '|' on either side of the progress bar
+    let pgb.subtractedlen=len(split(pgb.title, '\zs'))+3+4+2+2
+    let pgb.max_len = 0
+    set laststatus=2
+    return pgb
+  endfun
+
+  " Function: progressbar.calculate_ticks() {{{1
+  func! s:progressbar.calculate_ticks(pb_len)
+    if a:pb_len<=0
+      let pb_len = 100
+    else
+      let pb_len = a:pb_len
+    endif
+    let self.progress_ticks = map(range(pb_len+1), "v:val * self.max_value / pb_len")
+  endfun
+
+  "Function: progressbar.paint()
+  func! s:progressbar.paint()
+    " Recalculate widths.
+    let max_len = winwidth(self.winnr)
+    let pb_len = 0
+    " always true on first call because of initial value of self.max_len
+    if max_len != self.max_len
+      let self.max_len = max_len
+
+      " Progressbar length
+      let pb_len = max_len - self.subtractedlen
+
+      call self.calculate_ticks(pb_len)
+
+      let self.needs_redraw = 1
+      let cur_value = 0
+      let self.pb_len = pb_len
+    else
+      " start searching at the last found index to make the search for the
+      " appropriate tick value normally take 0 or 1 comparisons
+      let cur_value = self.last_value
+      let pb_len = self.pb_len
+    endif
+
+    let cur_val_max = pb_len > 0 ? pb_len : 100
+
+    " find the current progress bar position based on precalculated thresholds
+    while cur_value < cur_val_max && self.cur_value > self.progress_ticks[cur_value]
+      let cur_value += 1
+    endwhile
+
+    " update progress bar
+    if self.last_value != cur_value || self.needs_redraw || self.cur_value == self.max_value
+      let self.needs_redraw = 1
+      let self.last_value = cur_value
+
+      let t_color  = self.items.title.color
+      let b_fcolor = self.items.bar.fillcolor
+      let b_color  = self.items.bar.color
+      let c_color  = self.items.counter.color
+
+      let stl =  "%#".t_color."#%-( ".self.title." %)".
+	    \"%#".b_color."#".
+	    \(pb_len>0 ?
+	    \	('|%#'.b_fcolor."#%-(".repeat(" ",cur_value)."%)".
+	    \	 '%#'.b_color."#".repeat(" ",pb_len-cur_value)."|"):
+	    \	('')).
+	    \"%=%#".c_color."#%( ".printf("%3.d ",100*self.cur_value/self.max_value)."%% %)"
+      call setwinvar(self.winnr, '&stl', stl)
+    endif
+  endfun
+
+  func! s:progressbar.incr( ... )
+    let self.cur_value += (a:0 ? a:1 : 1)
+    " if we were making a general-purpose progress bar, we'd need to limit to a
+    " lower limit as well, but since we always increment with a positive value
+    " in this script, we only need limit the upper value
+    let self.cur_value = (self.cur_value > self.max_value ? self.max_value : self.cur_value)
+    call self.paint()
+  endfun
+  " }}}
+  if s:settings.dynamic_folds
+    " to process folds we make two passes through each line
+    let s:pgb = s:ProgressBar("Processing folds:", line('$')*2, s:orgwin)
+  endif
+endif
+
+" First do some preprocessing for dynamic folding. Do this for the entire file
+" so we don't accidentally start within a closed fold or something.
+let s:allfolds = []
+
+if s:settings.dynamic_folds
+  let s:lnum = 1
+  let s:end = line('$')
+  " save the fold text and set it to the default so we can find fold levels
+  let s:foldtext_save = &foldtext
+  setlocal foldtext&
+
+  " we will set the foldcolumn in the html to the greater of the maximum fold
+  " level and the current foldcolumn setting
+  let s:foldcolumn = &foldcolumn
+
+  " get all info needed to describe currently closed folds
+  while s:lnum <= s:end
+    if foldclosed(s:lnum) == s:lnum
+      " default fold text has '+-' and then a number of dashes equal to fold
+      " level, so subtract 2 from index of first non-dash after the dashes
+      " in order to get the fold level of the current fold
+      let s:level = match(foldtextresult(s:lnum), '+-*\zs[^-]') - 2
+      " store fold info for later use
+      let s:newfold = {'firstline': s:lnum, 'lastline': foldclosedend(s:lnum), 'level': s:level,'type': "closed-fold"}
+      call add(s:allfolds, s:newfold)
+      " open the fold so we can find any contained folds
+      execute s:lnum."foldopen"
+    else
+      if !s:settings.no_progress
+	call s:pgb.incr()
+	if s:pgb.needs_redraw
+	  redrawstatus
+	  let s:pgb.needs_redraw = 0
+	endif
+      endif
+      let s:lnum = s:lnum + 1
+    endif
+  endwhile
+
+  " close all folds to get info for originally open folds
+  silent! %foldclose!
+  let s:lnum = 1
+
+  " the originally open folds will be all folds we encounter that aren't
+  " already in the list of closed folds
+  while s:lnum <= s:end
+    if foldclosed(s:lnum) == s:lnum
+      " default fold text has '+-' and then a number of dashes equal to fold
+      " level, so subtract 2 from index of first non-dash after the dashes
+      " in order to get the fold level of the current fold
+      let s:level = match(foldtextresult(s:lnum), '+-*\zs[^-]') - 2
+      let s:newfold = {'firstline': s:lnum, 'lastline': foldclosedend(s:lnum), 'level': s:level,'type': "closed-fold"}
+      " only add the fold if we don't already have it
+      if empty(s:allfolds) || index(s:allfolds, s:newfold) == -1
+	let s:newfold.type = "open-fold"
+	call add(s:allfolds, s:newfold)
+      endif
+      " open the fold so we can find any contained folds
+      execute s:lnum."foldopen"
+    else
+      if !s:settings.no_progress
+	call s:pgb.incr()
+	if s:pgb.needs_redraw
+	  redrawstatus
+	  let s:pgb.needs_redraw = 0
+	endif
+      endif
+      let s:lnum = s:lnum + 1
+    endif
+  endwhile
+
+  " sort the folds so that we only ever need to look at the first item in the
+  " list of folds
+  call sort(s:allfolds, "s:FoldCompare")
+
+  let &l:foldtext = s:foldtext_save
+  unlet s:foldtext_save
+
+  " close all folds again so we can get the fold text as we go
+  silent! %foldclose!
+
+  " Go through and remove folds we don't need to (or cannot) process in the
+  " current conversion range
+  "
+  " If a fold is removed which contains other folds, which are included, we need
+  " to adjust the level of the included folds as used by the conversion logic
+  " (avoiding special cases is good)
+  "
+  " Note any time we remove a fold, either all of the included folds are in it,
+  " or none of them, because we only remove a fold if neither its start nor its
+  " end are within the conversion range.
+  let leveladjust = 0
+  for afold in s:allfolds
+    let removed = 0
+    if exists("g:html_start_line") && exists("g:html_end_line")
+      if afold.firstline < g:html_start_line
+	if afold.lastline <= g:html_end_line && afold.lastline >= g:html_start_line
+	  " if a fold starts before the range to convert but stops within the
+	  " range, we need to include it. Make it start on the first converted
+	  " line.
+	  let afold.firstline = g:html_start_line
+	else
+	  " if the fold lies outside the range or the start and stop enclose
+	  " the entire range, don't bother parsing it
+	  call remove(s:allfolds, index(s:allfolds, afold))
+	  let removed = 1
+	  if afold.lastline > g:html_end_line
+	    let leveladjust += 1
+	  endif
+	endif
+      elseif afold.firstline > g:html_end_line
+	" If the entire fold lies outside the range we need to remove it.
+	call remove(s:allfolds, index(s:allfolds, afold))
+	let removed = 1
+      endif
+    elseif exists("g:html_start_line")
+      if afold.firstline < g:html_start_line
+	" if there is no last line, but there is a first line, the end of the
+	" fold will always lie within the region of interest, so keep it
+	let afold.firstline = g:html_start_line
+      endif
+    elseif exists("g:html_end_line")
+      " if there is no first line we default to the first line in the buffer so
+      " the fold start will always be included if the fold itself is included.
+      " If however the entire fold lies outside the range we need to remove it.
+      if afold.firstline > g:html_end_line
+	call remove(s:allfolds, index(s:allfolds, afold))
+	let removed = 1
+      endif
+    endif
+    if !removed
+      let afold.level -= leveladjust
+      if afold.level+1 > s:foldcolumn
+	let s:foldcolumn = afold.level+1
+      endif
+    endif
+  endfor
+
+  " if we've removed folds containing the conversion range from processing,
+  " getting foldtext as we go won't know to open the removed folds, so the
+  " foldtext would be wrong; open them now.
+  "
+  " Note that only when a start and an end line is specified will a fold
+  " containing the current range ever be removed.
+  while leveladjust > 0
+    exe g:html_start_line."foldopen"
+    let leveladjust -= 1
+  endwhile
+endif
+
+" Now loop over all lines in the original text to convert to html.
+" Use html_start_line and html_end_line if they are set.
+if exists("g:html_start_line")
+  let s:lnum = html_start_line
+  if s:lnum < 1 || s:lnum > line("$")
+    let s:lnum = 1
+  endif
+else
+  let s:lnum = 1
+endif
+if exists("g:html_end_line")
+  let s:end = html_end_line
+  if s:end < s:lnum || s:end > line("$")
+    let s:end = line("$")
+  endif
+else
+  let s:end = line("$")
+endif
+
+" stack to keep track of all the folds containing the current line
+let s:foldstack = []
+
+if !s:settings.no_progress
+  let s:pgb = s:ProgressBar("Processing lines:", s:end - s:lnum + 1, s:orgwin)
+endif
+
+if s:settings.number_lines
+  let s:margin = strlen(s:end) + 1
+else
+  let s:margin = 0
+endif
+
+if has('folding') && !s:settings.ignore_folding
+  let s:foldfillchar = &fillchars[matchend(&fillchars, 'fold:')]
+  if s:foldfillchar == ''
+    let s:foldfillchar = '-'
+  endif
+endif
+let s:difffillchar = &fillchars[matchend(&fillchars, 'diff:')]
+if s:difffillchar == ''
+  let s:difffillchar = '-'
+endif
+
+let s:foldId = 0
+
+if !s:settings.expand_tabs
+  " If keeping tabs, add them to printable characters so we keep them when
+  " formatting text (strtrans() doesn't replace printable chars)
+  let s:old_isprint = &isprint
+  setlocal isprint+=9
+endif
+
+while s:lnum <= s:end
+
+  " If there are filler lines for diff mode, show these above the line.
+  let s:filler = diff_filler(s:lnum)
+  if s:filler > 0
+    let s:n = s:filler
+    while s:n > 0
+      let s:new = repeat(s:difffillchar, 3)
+
+      if s:n > 2 && s:n < s:filler && !s:settings.whole_filler
+	let s:new = s:new . " " . s:filler . " inserted lines "
+	let s:n = 2
+      endif
+
+      if !s:settings.no_pre
+	" HTML line wrapping is off--go ahead and fill to the margin
+	" TODO: what about when CSS wrapping is turned on?
+	let s:new = s:new . repeat(s:difffillchar, &columns - strlen(s:new) - s:margin)
+      else
+	let s:new = s:new . repeat(s:difffillchar, 3)
+      endif
+
+      let s:new = s:HtmlFormat_d(s:new, s:DIFF_D_ID, 0)
+      if s:settings.number_lines
+	" Indent if line numbering is on. Indent gets style of line number
+	" column.
+	let s:new = s:HtmlFormat_n(repeat(' ', s:margin), s:LINENR_ID, 0, 0) . s:new
+      endif
+      if s:settings.dynamic_folds && !s:settings.no_foldcolumn && s:foldcolumn > 0
+	" Indent for foldcolumn if there is one. Assume it's empty, there should
+	" not be a fold for deleted lines in diff mode.
+	let s:new = s:FoldColumn_fill() . s:new
+      endif
+      call add(s:lines, s:new.s:HtmlEndline)
+
+      let s:n = s:n - 1
+    endwhile
+    unlet s:n
+  endif
+  unlet s:filler
+
+  " Start the line with the line number.
+  if s:settings.number_lines
+    let s:numcol = repeat(' ', s:margin - 1 - strlen(s:lnum)) . s:lnum . ' '
+  endif
+
+  let s:new = ""
+
+  if has('folding') && !s:settings.ignore_folding && foldclosed(s:lnum) > -1 && !s:settings.dynamic_folds
+    "
+    " This is the beginning of a folded block (with no dynamic folding)
+    let s:new = foldtextresult(s:lnum)
+    if !s:settings.no_pre
+      " HTML line wrapping is off--go ahead and fill to the margin
+      let s:new = s:new . repeat(s:foldfillchar, &columns - strlen(s:new))
+    endif
+
+    " put numcol in a separate group for sake of unselectable text
+    let s:new = (s:settings.number_lines ? s:HtmlFormat_n(s:numcol, s:FOLDED_ID, 0, s:lnum): "") . s:HtmlFormat_t(s:new, s:FOLDED_ID, 0)
+
+    " Skip to the end of the fold
+    let s:new_lnum = foldclosedend(s:lnum)
+
+    if !s:settings.no_progress
+      call s:pgb.incr(s:new_lnum - s:lnum)
+    endif
+
+    let s:lnum = s:new_lnum
+
+  else
+    "
+    " A line that is not folded, or doing dynamic folding.
+    "
+    let s:line = getline(s:lnum)
+    let s:len = strlen(s:line)
+
+    if s:settings.dynamic_folds
+      " First insert a closing for any open folds that end on this line
+      while !empty(s:foldstack) && get(s:foldstack,0).lastline == s:lnum-1
+	let s:new = s:new.""
+	call remove(s:foldstack, 0)
+      endwhile
+
+      " Now insert an opening for any new folds that start on this line
+      let s:firstfold = 1
+      while !empty(s:allfolds) && get(s:allfolds,0).firstline == s:lnum
+	let s:foldId = s:foldId + 1
+	let s:new .= ""
+
+
+	" Unless disabled, add a fold column for the opening line of a fold.
+	"
+	" Note that dynamic folds require using css so we just use css to take
+	" care of the leading spaces rather than using   in the case of
+	" html_no_pre to make it easier
+	if !s:settings.no_foldcolumn
+	  " add fold column that can open the new fold
+	  if s:allfolds[0].level > 1 && s:firstfold
+	    let s:new = s:new . s:FoldColumn_build('|', s:allfolds[0].level - 1, 0, "",
+		  \ 'toggle-open FoldColumn','javascript:toggleFold("fold'.s:foldstack[0].id.s:settings.id_suffix.'");')
+	  endif
+	  " add the filler spaces separately from the '+' char so that it can be
+	  " shown/hidden separately during a hover unfold
+	  let s:new = s:new . s:FoldColumn_build("+", 1, 0, "",
+		\ 'toggle-open FoldColumn', 'javascript:toggleFold("fold'.s:foldId.s:settings.id_suffix.'");')
+	  " If this is not the last fold we're opening on this line, we need
+	  " to keep the filler spaces hidden if the fold is opened by mouse
+	  " hover. If it is the last fold to open in the line, we shouldn't hide
+	  " them, so don't apply the toggle-filler class.
+	  let s:new = s:new . s:FoldColumn_build(" ", 1, s:foldcolumn - s:allfolds[0].level - 1, "",
+		\ 'toggle-open FoldColumn'. (get(s:allfolds, 1, {'firstline': 0}).firstline == s:lnum ?" toggle-filler" :""),
+		\ 'javascript:toggleFold("fold'.s:foldId.s:settings.id_suffix.'");')
+
+	  " add fold column that can close the new fold
+	  " only add extra blank space if we aren't opening another fold on the
+	  " same line
+	  if get(s:allfolds, 1, {'firstline': 0}).firstline != s:lnum
+	    let s:extra_space = s:foldcolumn - s:allfolds[0].level
+	  else
+	    let s:extra_space = 0
+	  endif
+	  if s:firstfold
+	    " the first fold in a line has '|' characters from folds opened in
+	    " previous lines, before the '-' for this fold
+	    let s:new .= s:FoldColumn_build('|', s:allfolds[0].level - 1, s:extra_space, '-',
+		  \ 'toggle-closed FoldColumn', 'javascript:toggleFold("fold'.s:foldId.s:settings.id_suffix.'");')
+	  else
+	    " any subsequent folds in the line only add a single '-'
+	    let s:new = s:new . s:FoldColumn_build("-", 1, s:extra_space, "",
+		  \ 'toggle-closed FoldColumn', 'javascript:toggleFold("fold'.s:foldId.s:settings.id_suffix.'");')
+	  endif
+	  let s:firstfold = 0
+	endif
+
+	" Add fold text, moving the span ending to the next line so collapsing
+	" of folds works correctly.
+	" Put numcol in a separate group for sake of unselectable text.
+	let s:new = s:new . (s:settings.number_lines ? s:HtmlFormat_n(s:numcol, s:FOLDED_ID, 0, 0) : "") . substitute(s:HtmlFormat_t(foldtextresult(s:lnum), s:FOLDED_ID, 0), '', s:HtmlEndline.'\n\0', '')
+	let s:new = s:new . ""
+
+	" open the fold now that we have the fold text to allow retrieval of
+	" fold text for subsequent folds
+	execute s:lnum."foldopen"
+	call insert(s:foldstack, remove(s:allfolds,0))
+	let s:foldstack[0].id = s:foldId
+      endwhile
+
+      " Unless disabled, add a fold column for other lines.
+      "
+      " Note that dynamic folds require using css so we just use css to take
+      " care of the leading spaces rather than using   in the case of
+      " html_no_pre to make it easier
+      if !s:settings.no_foldcolumn
+	if empty(s:foldstack)
+	  " add the empty foldcolumn for unfolded lines if there is a fold
+	  " column at all
+	  if s:foldcolumn > 0
+	    let s:new = s:new . s:FoldColumn_fill()
+	  endif
+	else
+	  " add the fold column for folds not on the opening line
+	  if get(s:foldstack, 0).firstline < s:lnum
+	    let s:new = s:new . s:FoldColumn_build('|', s:foldstack[0].level, s:foldcolumn - s:foldstack[0].level, "",
+		  \ 'FoldColumn', 'javascript:toggleFold("fold'.s:foldstack[0].id.s:settings.id_suffix.'");')
+	  endif
+	endif
+      endif
+    endif
+
+    " Now continue with the unfolded line text
+    if s:settings.number_lines
+      let s:new = s:new . s:HtmlFormat_n(s:numcol, s:LINENR_ID, 0, s:lnum)
+    elseif s:settings.line_ids
+      let s:new = s:new . s:HtmlFormat_n("", s:LINENR_ID, 0, s:lnum)
+    endif
+
+    " Get the diff attribute, if any.
+    let s:diffattr = diff_hlID(s:lnum, 1)
+
+    " initialize conceal info to act like not concealed, just in case
+    let s:concealinfo = [0, '']
+
+    " Loop over each character in the line
+    let s:col = 1
+
+    " most of the time we won't use the diff_id, initialize to zero
+    let s:diff_id = 0
+
+    while s:col <= s:len || (s:col == 1 && s:diffattr)
+      let s:startcol = s:col " The start column for processing text
+      if !s:settings.ignore_conceal && has('conceal')
+	let s:concealinfo = synconcealed(s:lnum, s:col)
+      endif
+      if !s:settings.ignore_conceal && s:concealinfo[0]
+	let s:col = s:col + 1
+	" Speed loop (it's small - that's the trick)
+	" Go along till we find a change in the match sequence number (ending
+	" the specific concealed region) or until there are no more concealed
+	" characters.
+	while s:col <= s:len && s:concealinfo == synconcealed(s:lnum, s:col) | let s:col = s:col + 1 | endwhile
+      elseif s:diffattr
+	let s:diff_id = diff_hlID(s:lnum, s:col)
+	let s:id = synID(s:lnum, s:col, 1)
+	let s:col = s:col + 1
+	" Speed loop (it's small - that's the trick)
+	" Go along till we find a change in hlID
+	while s:col <= s:len && s:id == synID(s:lnum, s:col, 1)
+	      \   && s:diff_id == diff_hlID(s:lnum, s:col) |
+	      \     let s:col = s:col + 1 |
+	      \ endwhile
+	if s:len < &columns && !s:settings.no_pre
+	  " Add spaces at the end of the raw text line to extend the changed
+	  " line to the full width.
+	  let s:line = s:line . repeat(' ', &columns - virtcol([s:lnum, s:len]) - s:margin)
+	  let s:len = &columns
+	endif
+      else
+	let s:id = synID(s:lnum, s:col, 1)
+	let s:col = s:col + 1
+	" Speed loop (it's small - that's the trick)
+	" Go along till we find a change in synID
+	while s:col <= s:len && s:id == synID(s:lnum, s:col, 1) | let s:col = s:col + 1 | endwhile
+      endif
+
+      if s:settings.ignore_conceal || !s:concealinfo[0]
+	" Expand tabs if needed
+	let s:expandedtab = strpart(s:line, s:startcol - 1, s:col - s:startcol)
+	if s:settings.expand_tabs
+	  let s:offset = 0
+	  let s:idx = stridx(s:expandedtab, "\t")
+	  while s:idx >= 0
+	    if has("multi_byte_encoding")
+	      if s:startcol + s:idx == 1
+		let s:i = &ts
+	      else
+		if s:idx == 0
+		  let s:prevc = matchstr(s:line, '.\%' . (s:startcol + s:idx + s:offset) . 'c')
+		else
+		  let s:prevc = matchstr(s:expandedtab, '.\%' . (s:idx + 1) . 'c')
+		endif
+		let s:vcol = virtcol([s:lnum, s:startcol + s:idx + s:offset - len(s:prevc)])
+		let s:i = &ts - (s:vcol % &ts)
+	      endif
+	      let s:offset -= s:i - 1
+	    else
+	      let s:i = &ts - ((s:idx + s:startcol - 1) % &ts)
+	    endif
+	    let s:expandedtab = substitute(s:expandedtab, '\t', repeat(' ', s:i), '')
+	    let s:idx = stridx(s:expandedtab, "\t")
+	  endwhile
+	end
+
+	" get the highlight group name to use
+	let s:id = synIDtrans(s:id)
+      else
+	" use Conceal highlighting for concealed text
+	let s:id = s:CONCEAL_ID
+	let s:expandedtab = s:concealinfo[1]
+      endif
+
+      " Output the text with the same synID, with class set to the highlight ID
+      " name, unless it has been concealed completely.
+      if strlen(s:expandedtab) > 0
+	let s:new = s:new . s:HtmlFormat(s:expandedtab,  s:id, s:diff_id, "", 0)
+      endif
+    endwhile
+  endif
+
+  call extend(s:lines, split(s:new.s:HtmlEndline, '\n', 1))
+  if !s:settings.no_progress && s:pgb.needs_redraw
+    redrawstatus
+    let s:pgb.needs_redraw = 0
+  endif
+  let s:lnum = s:lnum + 1
+
+  if !s:settings.no_progress
+    call s:pgb.incr()
+  endif
+endwhile
+
+if s:settings.dynamic_folds
+  " finish off any open folds
+  while !empty(s:foldstack)
+    let s:lines[-1].=""
+    call remove(s:foldstack, 0)
+  endwhile
+
+  " add fold column to the style list if not already there
+  let s:id = s:FOLD_C_ID
+  if !has_key(s:stylelist, s:id)
+    let s:stylelist[s:id] = '.FoldColumn { ' . s:CSS1(s:id) . '}'
+  endif
+endif
+
+if s:settings.no_pre
+  if !s:settings.use_css
+    " Close off the font tag that encapsulates the whole 
+    call extend(s:lines, ["", "", ""])
+  else
+    call extend(s:lines, ["
", "", ""]) + endif +else + call extend(s:lines, ["", "", ""]) +endif + +exe s:newwin . "wincmd w" +call setline(1, s:lines) +unlet s:lines + +" Mangle modelines so Vim doesn't try to use HTML text as a modeline if editing +" this file in the future; need to do this after generating all the text in case +" the modeline text has different highlight groups which all turn out to be +" stripped from the final output. +%s!\v(%(^|\s+)%([Vv]i%(m%([<=>]?\d+)?)?|ex)):!\1\:!ge + +" The generated HTML is admittedly ugly and takes a LONG time to fold. +" Make sure the user doesn't do syntax folding when loading a generated file, +" using a modeline. +call append(line('$'), "") + +" Now, when we finally know which, we define the colors and styles +if s:settings.use_css + 1;/+ contains=@htmlCss,htmlTag,htmlEndTag,htmlCssStyleComment,@htmlPreproc + syn match htmlCssStyleComment contained "\(\)" + syn region htmlCssDefinition matchgroup=htmlArg start='style="' keepend matchgroup=htmlString end='"' contains=css.*Attr,css.*Prop,cssComment,cssLength,cssColor,cssURL,cssImportant,cssError,cssString,@htmlPreproc + hi def link htmlStyleArg htmlString +endif + +if main_syntax == "html" + " synchronizing (does not always work if a comment includes legal + " html tags, but doing it right would mean to always start + " at the first line, which is too slow) + syn sync match htmlHighlight groupthere NONE "<[/a-zA-Z]" + syn sync match htmlHighlight groupthere javaScript " +" Last Change: 2003-05-11 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'html' +endif + +runtime! syntax/cheetah.vim +runtime! syntax/html.vim +unlet b:current_syntax + +syntax cluster htmlPreproc add=cheetahPlaceHolder +syntax cluster htmlString add=cheetahPlaceHolder + +let b:current_syntax = "htmlcheetah" + + + +endif diff --git a/syntax/htmldjango.vim b/syntax/htmldjango.vim new file mode 100644 index 0000000..aeef4e2 --- /dev/null +++ b/syntax/htmldjango.vim @@ -0,0 +1,30 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Django HTML template +" Maintainer: Dave Hodder +" Last Change: 2014 Jul 13 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'html' +endif + +runtime! syntax/django.vim +runtime! syntax/html.vim +unlet b:current_syntax + +syn cluster djangoBlocks add=djangoTagBlock,djangoVarBlock,djangoComment,djangoComBlock + +syn region djangoTagBlock start="{%" end="%}" contains=djangoStatement,djangoFilter,djangoArgument,djangoTagError display containedin=ALLBUT,@djangoBlocks +syn region djangoVarBlock start="{{" end="}}" contains=djangoFilter,djangoArgument,djangoVarError display containedin=ALLBUT,@djangoBlocks +syn region djangoComment start="{%\s*comment\(\s\+.\{-}\)\?%}" end="{%\s*endcomment\s*%}" contains=djangoTodo containedin=ALLBUT,@djangoBlocks +syn region djangoComBlock start="{#" end="#}" contains=djangoTodo containedin=ALLBUT,@djangoBlocks + +let b:current_syntax = "htmldjango" + +endif diff --git a/syntax/htmlm4.vim b/syntax/htmlm4.vim new file mode 100644 index 0000000..7c67505 --- /dev/null +++ b/syntax/htmlm4.vim @@ -0,0 +1,35 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: HTML and M4 +" Maintainer: Claudio Fleiner +" URL: http://www.fleiner.com/vim/syntax/htmlm4.vim +" Last Change: 2001 Apr 30 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" we define it here so that included files can test for it +if !exists("main_syntax") + let main_syntax='htmlm4' +endif + +runtime! syntax/html.vim +unlet b:current_syntax +syn case match + +runtime! syntax/m4.vim + +unlet b:current_syntax +syn cluster htmlPreproc add=@m4Top +syn cluster m4StringContents add=htmlTag,htmlEndTag + +let b:current_syntax = "htmlm4" + +if main_syntax == 'htmlm4' + unlet main_syntax +endif + +endif diff --git a/syntax/htmlos.vim b/syntax/htmlos.vim new file mode 100644 index 0000000..50ea7d3 --- /dev/null +++ b/syntax/htmlos.vim @@ -0,0 +1,153 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: HTML/OS by Aestiva +" Maintainer: Jason Rust +" URL: http://www.rustyparts.com/vim/syntax/htmlos.vim +" Info: http://www.rustyparts.com/scripts.php +" Last Change: 2003 May 11 +" + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'htmlos' +endif + +runtime! syntax/html.vim +unlet b:current_syntax + +syn cluster htmlPreproc add=htmlosRegion + +syn case ignore + +" Function names +syn keyword htmlosFunctions expand sleep getlink version system ascii getascii syslock sysunlock cr lf clean postprep listtorow split listtocol coltolist rowtolist tabletolist contained +syn keyword htmlosFunctions cut \display cutall cutx cutallx length reverse lower upper proper repeat left right middle trim trimleft trimright count countx locate locatex replace replacex replaceall replaceallx paste pasteleft pasteleftx pasteleftall pasteleftallx pasteright pasterightall pasterightallx chopleft chopleftx chopright choprightx format concat contained +syn keyword htmlosFunctions goto exitgoto contained +syn keyword htmlosFunctions layout cols rows row items getitem putitem switchitems gettable delrow delrows delcol delcols append merge fillcol fillrow filltable pastetable getcol getrow fillindexcol insindexcol dups nodups maxtable mintable maxcol mincol maxrow minrow avetable avecol averow mediantable mediancol medianrow producttable productcol productrow sumtable sumcol sumrow sumsqrtable sumsqrcol sumsqrrow reversecols reverserows switchcols switchrows inscols insrows insfillcol sortcol reversesortcol sortcoln reversesortcoln sortrow sortrown reversesortrow reversesortrown getcoleq getcoleqn getcolnoteq getcolany getcolbegin getcolnotany getcolnotbegin getcolge getcolgt getcolle getcollt getcolgen getcolgtn getcollen getcoltn getcolend getcolnotend getrowend getrownotend getcolin getcolnotin getcolinbegin getcolnotinbegin getcolinend getcolnotinend getrowin getrownotin getrowinbegin getrownotinbegin getrowinend getrownotinend contained +syn keyword htmlosFunctions dbcreate dbadd dbedit dbdelete dbsearch dbsearchsort dbget dbgetsort dbstatus dbindex dbimport dbfill dbexport dbsort dbgetrec dbremove dbpurge dbfind dbfindsort dbunique dbcopy dbmove dbkill dbtransfer dbpoke dbsearchx dbgetx contained +syn keyword htmlosFunctions syshtmlosname sysstartname sysfixfile fileinfo filelist fileindex domainname page browser regdomain username usernum getenv httpheader copy file ts row sysls syscp sysmv sysmd sysrd filepush filepushlink dirname contained +syn keyword htmlosFunctions mail to address subject netmail netmailopen netmailclose mailfilelist netweb netwebresults webpush netsockopen netsockread netsockwrite netsockclose contained +syn keyword htmlosFunctions today time systime now yesterday tomorrow getday getmonth getyear getminute getweekday getweeknum getyearday getdate gettime getamorpm gethour addhours addminutes adddays timebetween timetill timefrom datetill datefrom mixedtimebetween mixeddatetill mixedtimetill mixedtimefrom mixeddatefrom nextdaybyweekfromdate nextdaybyweekfromtoday nextdaybymonthfromdate nextdaybymonthfromtoday nextdaybyyearfromdate nextdaybyyearfromtoday offsetdaybyweekfromdate offsetdaybyweekfromtoday offsetdaybymonthfromdate offsetdaybymonthfromtoday contained +syn keyword htmlosFunctions isprivate ispublic isfile isdir isblank iserror iserror iseven isodd istrue isfalse islogical istext istag isnumber isinteger isdate istableeq istableeqx istableeqn isfuture ispast istoday isweekday isweekend issamedate iseq isnoteq isge isle ismod10 isvalidstring contained +syn keyword htmlosFunctions celtof celtokel ftocel ftokel keltocel keltof cmtoin intocm fttom mtoft fttomile miletoft kmtomile miletokm mtoyd ydtom galtoltr ltrtogal ltrtoqt qttoltr gtooz oztog kgtolb lbtokg mttoton tontomt contained +syn keyword htmlosFunctions max min abs sign inverse square sqrt cube roundsig round ceiling roundup floor rounddown roundeven rounddowneven roundupeven roundodd roundupodd rounddownodd random factorial summand fibonacci remainder mod radians degrees cos sin tan cotan secant cosecant acos asin atan exp power power10 ln log10 log sinh cosh tanh contained +syn keyword htmlosFunctions xmldelete xmldeletex xmldeleteattr xmldeleteattrx xmledit xmleditx xmleditvalue xmleditvaluex xmleditattr xmleditattrx xmlinsertbefore xmlinsertbeforex smlinsertafter xmlinsertafterx xmlinsertattr xmlinsertattrx smlget xmlgetx xmlgetvalue xmlgetvaluex xmlgetattrvalue xmlgetattrvaluex xmlgetrec xmlgetrecx xmlgetrecattrvalue xmlgetrecattrvaluex xmlchopleftbefore xmlchopleftbeforex xmlchoprightbefore xmlchoprightbeforex xmlchopleftafter xmlchopleftafterx xmlchoprightafter xmlchoprightafterx xmllocatebefore xmllocatebeforex xmllocateafter xmllocateafterx contained + +" Type +syn keyword htmlosType int str dol flt dat grp contained + +" StorageClass +syn keyword htmlosStorageClass locals contained + +" Operator +syn match htmlosOperator "[-=+/\*!]" contained +syn match htmlosRelation "[~]" contained +syn match htmlosRelation "[=~][&!]" contained +syn match htmlosRelation "[!=<>]=" contained +syn match htmlosRelation "[<>]" contained + +" Comment +syn region htmlosComment start="#" end="/#" contained + +" Conditional +syn keyword htmlosConditional if then /if to else elif contained +syn keyword htmlosConditional and or nand nor xor not contained +" Repeat +syn keyword htmlosRepeat while do /while for /for contained + +" Keyword +syn keyword htmlosKeyword name value step do rowname colname rownum contained + +" Repeat +syn keyword htmlosLabel case matched /case switch contained + +" Statement +syn keyword htmlosStatement break exit return continue contained + +" Identifier +syn match htmlosIdentifier "\h\w*[\.]*\w*" contained + +" Special identifier +syn match htmlosSpecialIdentifier "[\$@]" contained + +" Define +syn keyword htmlosDefine function overlay contained + +" Boolean +syn keyword htmlosBoolean true false contained + +" String +syn region htmlosStringDouble keepend matchgroup=None start=+"+ end=+"+ contained +syn region htmlosStringSingle keepend matchgroup=None start=+'+ end=+'+ contained + +" Number +syn match htmlosNumber "-\=\<\d\+\>" contained + +" Float +syn match htmlosFloat "\(-\=\<\d+\|-\=\)\.\d\+\>" contained + +" Error +syn match htmlosError "ERROR" contained + +" Parent +syn match htmlosParent "[({[\]})]" contained + +" Todo +syn keyword htmlosTodo TODO Todo todo contained + +syn cluster htmlosInside contains=htmlosComment,htmlosFunctions,htmlosIdentifier,htmlosSpecialIdentifier,htmlosConditional,htmlosRepeat,htmlosLabel,htmlosStatement,htmlosOperator,htmlosRelation,htmlosStringSingle,htmlosStringDouble,htmlosNumber,htmlosFloat,htmlosError,htmlosKeyword,htmlosType,htmlosBoolean,htmlosParent + +syn cluster htmlosTop contains=@htmlosInside,htmlosDefine,htmlosError,htmlosStorageClass + +syn region htmlosRegion keepend matchgroup=Delimiter start="<<" skip=+".\{-}?>.\{-}"\|'.\{-}?>.\{-}'\|/\*.\{-}?>.\{-}\*/+ end=">>" contains=@htmlosTop +syn region htmlosRegion keepend matchgroup=Delimiter start="\[\[" skip=+".\{-}?>.\{-}"\|'.\{-}?>.\{-}'\|/\*.\{-}?>.\{-}\*/+ end="\]\]" contains=@htmlosTop + + +" sync +if exists("htmlos_minlines") + exec "syn sync minlines=" . htmlos_minlines +else + syn sync minlines=100 +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link htmlosSpecialIdentifier Operator +hi def link htmlosIdentifier Identifier +hi def link htmlosStorageClass StorageClass +hi def link htmlosComment Comment +hi def link htmlosBoolean Boolean +hi def link htmlosStringSingle String +hi def link htmlosStringDouble String +hi def link htmlosNumber Number +hi def link htmlosFloat Float +hi def link htmlosFunctions Function +hi def link htmlosRepeat Repeat +hi def link htmlosConditional Conditional +hi def link htmlosLabel Label +hi def link htmlosStatement Statement +hi def link htmlosKeyword Statement +hi def link htmlosType Type +hi def link htmlosDefine Define +hi def link htmlosParent Delimiter +hi def link htmlosError Error +hi def link htmlosTodo Todo +hi def link htmlosOperator Operator +hi def link htmlosRelation Operator + +let b:current_syntax = "htmlos" + +if main_syntax == 'htmlos' + unlet main_syntax +endif + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/ia64.vim b/syntax/ia64.vim new file mode 100644 index 0000000..fa41995 --- /dev/null +++ b/syntax/ia64.vim @@ -0,0 +1,298 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: IA-64 (Itanium) assembly language +" Maintainer: Parth Malwankar +" URL: http://www.geocities.com/pmalwankar (Home Page with link to my Vim page) +" http://www.geocities.com/pmalwankar/vim.htm (for VIM) +" File Version: 0.7 +" Last Change: 2006 Sep 08 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +"ignore case for assembly +syn case ignore + +" Identifier Keyword characters (defines \k) +setlocal iskeyword=@,48-57,#,$,.,:,?,@-@,_,~ + +syn sync minlines=5 + +" Read the MASM syntax to start with +" This is needed as both IA-64 as well as IA-32 instructions are supported +source :p:h/masm.vim + +syn region ia64Comment start="//" end="$" contains=ia64Todo +syn region ia64Comment start="/\*" end="\*/" contains=ia64Todo + +syn match ia64Identifier "[a-zA-Z_$][a-zA-Z0-9_$]*" +syn match ia64Directive "\.[a-zA-Z_$][a-zA-Z_$.]\+" +syn match ia64Label "[a-zA-Z_$.][a-zA-Z0-9_$.]*\s\=:\>"he=e-1 +syn match ia64Label "[a-zA-Z_$.][a-zA-Z0-9_$.]*\s\=::\>"he=e-2 +syn match ia64Label "[a-zA-Z_$.][a-zA-Z0-9_$.]*\s\=#\>"he=e-1 +syn region ia64string start=+L\="+ skip=+\\\\\|\\"+ end=+"+ +syn match ia64Octal "0[0-7_]*\>" +syn match ia64Binary "0[bB][01_]*\>" +syn match ia64Hex "0[xX][0-9a-fA-F_]*\>" +syn match ia64Decimal "[1-9_][0-9_]*\>" +syn match ia64Float "[0-9_]*\.[0-9_]*\([eE][+-]\=[0-9_]*\)\=\>" + +"simple instructions +syn keyword ia64opcode add adds addl addp4 alloc and andcm cover epc +syn keyword ia64opcode fabs fand fandcm fc flushrs fneg fnegabs for +syn keyword ia64opcode fpabs fpack fpneg fpnegabs fselect fand fabdcm +syn keyword ia64opcode fc fwb fxor loadrs movl mux1 mux2 or padd4 +syn keyword ia64opcode pavgsub1 pavgsub2 popcnt psad1 pshl2 pshl4 pshladd2 +syn keyword ia64opcode pshradd2 psub4 rfi rsm rum shl shladd shladdp4 +syn keyword ia64opcode shrp ssm sub sum sync.i tak thash +syn keyword ia64opcode tpa ttag xor + +"put to override these being recognized as floats. They are orignally from masm.vim +"put here to avoid confusion with float +syn match ia64Directive "\.186" +syn match ia64Directive "\.286" +syn match ia64Directive "\.286c" +syn match ia64Directive "\.286p" +syn match ia64Directive "\.287" +syn match ia64Directive "\.386" +syn match ia64Directive "\.386c" +syn match ia64Directive "\.386p" +syn match ia64Directive "\.387" +syn match ia64Directive "\.486" +syn match ia64Directive "\.486c" +syn match ia64Directive "\.486p" +syn match ia64Directive "\.8086" +syn match ia64Directive "\.8087" + + + +"delimiters +syn match ia64delimiter ";;" + +"operators +syn match ia64operators "[\[\]()#,]" +syn match ia64operators "\(+\|-\|=\)" + +"TODO +syn match ia64Todo "\(TODO\|XXX\|FIXME\|NOTE\)" + +"What follows is a long list of regular expressions for parsing the +"ia64 instructions that use many completers + +"br +syn match ia64opcode "br\(\(\.\(cond\|call\|ret\|ia\|cloop\|ctop\|cexit\|wtop\|wexit\)\)\=\(\.\(spnt\|dpnt\|sptk\|dptk\)\)\=\(\.few\|\.many\)\=\(\.clr\)\=\)\=\>" +"break +syn match ia64opcode "break\(\.[ibmfx]\)\=\>" +"brp +syn match ia64opcode "brp\(\.\(sptk\|dptk\|loop\|exit\)\)\(\.imp\)\=\>" +syn match ia64opcode "brp\.ret\(\.\(sptk\|dptk\)\)\{1}\(\.imp\)\=\>" +"bsw +syn match ia64opcode "bsw\.[01]\>" +"chk +syn match ia64opcode "chk\.\(s\(\.[im]\)\=\)\>" +syn match ia64opcode "chk\.a\.\(clr\|nc\)\>" +"clrrrb +syn match ia64opcode "clrrrb\(\.pr\)\=\>" +"cmp/cmp4 +syn match ia64opcode "cmp4\=\.\(eq\|ne\|l[te]\|g[te]\|[lg]tu\|[lg]eu\)\(\.unc\)\=\>" +syn match ia64opcode "cmp4\=\.\(eq\|[lgn]e\|[lg]t\)\.\(\(or\(\.andcm\|cm\)\=\)\|\(and\(\(\.or\)\=cm\)\=\)\)\>" +"cmpxchg +syn match ia64opcode "cmpxchg[1248]\.\(acq\|rel\)\(\.nt1\|\.nta\)\=\>" +"czx +syn match ia64opcode "czx[12]\.[lr]\>" +"dep +syn match ia64opcode "dep\(\.z\)\=\>" +"extr +syn match ia64opcode "extr\(\.u\)\=\>" +"fadd +syn match ia64opcode "fadd\(\.[sd]\)\=\(\.s[0-3]\)\=\>" +"famax/famin +syn match ia64opcode "fa\(max\|min\)\(\.s[0-3]\)\=\>" +"fchkf/fmax/fmin +syn match ia64opcode "f\(chkf\|max\|min\)\(\.s[0-3]\)\=\>" +"fclass +syn match ia64opcode "fclass\(\.n\=m\)\(\.unc\)\=\>" +"fclrf/fpamax +syn match ia64opcode "f\(clrf\|pamax\|pamin\)\(\.s[0-3]\)\=\>" +"fcmp +syn match ia64opcode "fcmp\.\(n\=[lg][te]\|n\=eq\|\(un\)\=ord\)\(\.unc\)\=\(\.s[0-3]\)\=\>" +"fcvt/fcvt.xf/fcvt.xuf.pc.sf +syn match ia64opcode "fcvt\.\(\(fxu\=\(\.trunc\)\=\(\.s[0-3]\)\=\)\|\(xf\|xuf\(\.[sd]\)\=\(\.s[0-3]\)\=\)\)\>" +"fetchadd +syn match ia64opcode "fetchadd[48]\.\(acq\|rel\)\(\.nt1\|\.nta\)\=\>" +"fma/fmpy/fms +syn match ia64opcode "fm\([as]\|py\)\(\.[sd]\)\=\(\.s[0-3]\)\=\>" +"fmerge/fpmerge +syn match ia64opcode "fp\=merge\.\(ns\|se\=\)\>" +"fmix +syn match ia64opcode "fmix\.\(lr\|[lr]\)\>" +"fnma/fnorm/fnmpy +syn match ia64opcode "fn\(ma\|mpy\|orm\)\(\.[sd]\)\=\(\.s[0-3]\)\=\>" +"fpcmp +syn match ia64opcode "fpcmp\.\(n\=[lg][te]\|n\=eq\|\(un\)\=ord\)\(\.s[0-3]\)\=\>" +"fpcvt +syn match ia64opcode "fpcvt\.fxu\=\(\(\.trunc\)\=\(\.s[0-3]\)\=\)\>" +"fpma/fpmax/fpmin/fpmpy/fpms/fpnma/fpnmpy/fprcpa/fpsqrta +syn match ia64opcode "fp\(max\=\|min\|n\=mpy\|ms\|nma\|rcpa\|sqrta\)\(\.s[0-3]\)\=\>" +"frcpa/frsqrta +syn match ia64opcode "fr\(cpa\|sqrta\)\(\.s[0-3]\)\=\>" +"fsetc/famin/fchkf +syn match ia64opcode "f\(setc\|amin\|chkf\)\(\.s[0-3]\)\=\>" +"fsub +syn match ia64opcode "fsub\(\.[sd]\)\=\(\.s[0-3]\)\=\>" +"fswap +syn match ia64opcode "fswap\(\.n[lr]\=\)\=\>" +"fsxt +syn match ia64opcode "fsxt\.[lr]\>" +"getf +syn match ia64opcode "getf\.\([sd]\|exp\|sig\)\>" +"invala +syn match ia64opcode "invala\(\.[ae]\)\=\>" +"itc/itr +syn match ia64opcode "it[cr]\.[id]\>" +"ld +syn match ia64opcode "ld[1248]\>\|ld[1248]\(\.\(sa\=\|a\|c\.\(nc\|clr\(\.acq\)\=\)\|acq\|bias\)\)\=\(\.nt[1a]\)\=\>" +syn match ia64opcode "ld8\.fill\(\.nt[1a]\)\=\>" +"ldf +syn match ia64opcode "ldf[sde8]\(\(\.\(sa\=\|a\|c\.\(nc\|clr\)\)\)\=\(\.nt[1a]\)\=\)\=\>" +syn match ia64opcode "ldf\.fill\(\.nt[1a]\)\=\>" +"ldfp +syn match ia64opcode "ldfp[sd8]\(\(\.\(sa\=\|a\|c\.\(nc\|clr\)\)\)\=\(\.nt[1a]\)\=\)\=\>" +"lfetch +syn match ia64opcode "lfetch\(\.fault\(\.excl\)\=\|\.excl\)\=\(\.nt[12a]\)\=\>" +"mf +syn match ia64opcode "mf\(\.a\)\=\>" +"mix +syn match ia64opcode "mix[124]\.[lr]\>" +"mov +syn match ia64opcode "mov\(\.[im]\)\=\>" +syn match ia64opcode "mov\(\.ret\)\=\(\(\.sptk\|\.dptk\)\=\(\.imp\)\=\)\=\>" +"nop +syn match ia64opcode "nop\(\.[ibmfx]\)\=\>" +"pack +syn match ia64opcode "pack\(2\.[su]ss\|4\.sss\)\>" +"padd //padd4 added to keywords +syn match ia64opcode "padd[12]\(\.\(sss\|uus\|uuu\)\)\=\>" +"pavg +syn match ia64opcode "pavg[12]\(\.raz\)\=\>" +"pcmp +syn match ia64opcode "pcmp[124]\.\(eq\|gt\)\>" +"pmax/pmin +syn match ia64opcode "pm\(ax\|in\)\(\(1\.u\)\|2\)\>" +"pmpy +syn match ia64opcode "pmpy2\.[rl]\>" +"pmpyshr +syn match ia64opcode "pmpyshr2\(\.u\)\=\>" +"probe +syn match ia64opcode "probe\.[rw]\>" +syn match ia64opcode "probe\.\(\(r\|w\|rw\)\.fault\)\>" +"pshr +syn match ia64opcode "pshr[24]\(\.u\)\=\>" +"psub +syn match ia64opcode "psub[12]\(\.\(sss\|uu[su]\)\)\=\>" +"ptc +syn match ia64opcode "ptc\.\(l\|e\|ga\=\)\>" +"ptr +syn match ia64opcode "ptr\.\(d\|i\)\>" +"setf +syn match ia64opcode "setf\.\(s\|d\|exp\|sig\)\>" +"shr +syn match ia64opcode "shr\(\.u\)\=\>" +"srlz +syn match ia64opcode "srlz\(\.[id]\)\>" +"st +syn match ia64opcode "st[1248]\(\.rel\)\=\(\.nta\)\=\>" +syn match ia64opcode "st8\.spill\(\.nta\)\=\>" +"stf +syn match ia64opcode "stf[1248]\(\.nta\)\=\>" +syn match ia64opcode "stf\.spill\(\.nta\)\=\>" +"sxt +syn match ia64opcode "sxt[124]\>" +"tbit/tnat +syn match ia64opcode "t\(bit\|nat\)\(\.nz\|\.z\)\=\(\.\(unc\|or\(\.andcm\|cm\)\=\|and\(\.orcm\|cm\)\=\)\)\=\>" +"unpack +syn match ia64opcode "unpack[124]\.[lh]\>" +"xchq +syn match ia64opcode "xchg[1248]\(\.nt[1a]\)\=\>" +"xma/xmpy +syn match ia64opcode "xm\(a\|py\)\.[lh]u\=\>" +"zxt +syn match ia64opcode "zxt[124]\>" + + +"The regex for different ia64 registers are given below + +"limits the rXXX and fXXX and cr suffix in the range 0-127 +syn match ia64registers "\([fr]\|cr\)\([0-9]\|[1-9][0-9]\|1[0-1][0-9]\|12[0-7]\)\{1}\>" +"branch ia64registers +syn match ia64registers "b[0-7]\>" +"predicate ia64registers +syn match ia64registers "p\([0-9]\|[1-5][0-9]\|6[0-3]\)\>" +"application ia64registers +syn match ia64registers "ar\.\(fpsr\|mat\|unat\|rnat\|pfs\|bsp\|bspstore\|rsc\|lc\|ec\|ccv\|itc\|k[0-7]\)\>" +"ia32 AR's +syn match ia64registers "ar\.\(eflag\|fcr\|csd\|ssd\|cflg\|fsr\|fir\|fdr\)\>" +"sp/gp/pr/pr.rot/rp +syn keyword ia64registers sp gp pr pr.rot rp ip tp +"in/out/local +syn match ia64registers "\(in\|out\|loc\)\([0-9]\|[1-8][0-9]\|9[0-5]\)\>" +"argument ia64registers +syn match ia64registers "farg[0-7]\>" +"return value ia64registers +syn match ia64registers "fret[0-7]\>" +"psr +syn match ia64registers "psr\(\.\(l\|um\)\)\=\>" +"cr +syn match ia64registers "cr\.\(dcr\|itm\|iva\|pta\|ipsr\|isr\|ifa\|iip\|itir\|iipa\|ifs\|iim\|iha\|lid\|ivr\|tpr\|eoi\|irr[0-3]\|itv\|pmv\|lrr[01]\|cmcv\)\>" +"Indirect registers +syn match ia64registers "\(cpuid\|dbr\|ibr\|pkr\|pmc\|pmd\|rr\|itr\|dtr\)\>" +"MUX permutations for 8-bit elements +syn match ia64registers "\(@rev\|@mix\|@shuf\|@alt\|@brcst\)\>" +"floating point classes +syn match ia64registers "\(@nat\|@qnan\|@snan\|@pos\|@neg\|@zero\|@unorm\|@norm\|@inf\)\>" +"link relocation operators +syn match ia64registers "\(@\(\(\(gp\|sec\|seg\|image\)rel\)\|ltoff\|fptr\|ptloff\|ltv\|section\)\)\>" + +"Data allocation syntax +syn match ia64data "data[1248]\(\(\(\.ua\)\=\(\.msb\|\.lsb\)\=\)\|\(\(\.msb\|\.lsb\)\=\(\.ua\)\=\)\)\=\>" +syn match ia64data "real\([48]\|1[06]\)\(\(\(\.ua\)\=\(\.msb\|\.lsb\)\=\)\|\(\(\.msb\|\.lsb\)\=\(\.ua\)\=\)\)\=\>" +syn match ia64data "stringz\=\(\(\(\.ua\)\=\(\.msb\|\.lsb\)\=\)\|\(\(\.msb\|\.lsb\)\=\(\.ua\)\=\)\)\=\>" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +"put masm groups with our groups +hi def link masmOperator ia64operator +hi def link masmDirective ia64Directive +hi def link masmOpcode ia64Opcode +hi def link masmIdentifier ia64Identifier +hi def link masmFloat ia64Float + +"ia64 specific stuff +hi def link ia64Label Define +hi def link ia64Comment Comment +hi def link ia64Directive Type +hi def link ia64opcode Statement +hi def link ia64registers Operator +hi def link ia64string String +hi def link ia64Hex Number +hi def link ia64Binary Number +hi def link ia64Octal Number +hi def link ia64Float Float +hi def link ia64Decimal Number +hi def link ia64Identifier Identifier +hi def link ia64data Type +hi def link ia64delimiter Delimiter +hi def link ia64operator Operator +hi def link ia64Todo Todo + + +let b:current_syntax = "ia64" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/ibasic.vim b/syntax/ibasic.vim new file mode 100644 index 0000000..27ce4ca --- /dev/null +++ b/syntax/ibasic.vim @@ -0,0 +1,180 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: ibasic +" Maintainer: Mark Manning +" Originator: Allan Kelly +" Created: 10/1/2006 +" Updated: 10/21/2006 +" Description: A vim file to handle the IBasic file format. +" Notes: +" Updated by Mark Manning +" Applied IBasic support to the already excellent support for standard +" basic syntax (like QB). +" +" First version based on Micro$soft QBASIC circa 1989, as documented in +" 'Learn BASIC Now' by Halvorson&Rygmyr. Microsoft Press 1989. +" This syntax file not a complete implementation yet. +" Send suggestions to the maintainer. +" +" This version is based upon the commands found in IBasic (www.pyxia.com). +" MEM 10/6/2006 +" +" Quit when a (custom) syntax file was already loaded (Taken from c.vim) +" +if exists("b:current_syntax") + finish +endif +" +" Be sure to turn on the "case ignore" since current versions of basic +" support both upper as well as lowercase letters. +" +syn case ignore +" +" A bunch of useful BASIC keywords +" +syn keyword ibasicStatement beep bload bsave call absolute chain chdir circle +syn keyword ibasicStatement clear close cls color com common const data +syn keyword ibasicStatement loop draw end environ erase error exit field +syn keyword ibasicStatement files function get gosub goto +syn keyword ibasicStatement input input# ioctl key kill let line locate +syn keyword ibasicStatement lock unlock lprint using lset mkdir name +syn keyword ibasicStatement on error open option base out paint palette pcopy +syn keyword ibasicStatement pen play pmap poke preset print print# using pset +syn keyword ibasicStatement put randomize read redim reset restore resume +syn keyword ibasicStatement return rmdir rset run seek screen +syn keyword ibasicStatement shared shell sleep sound static stop strig sub +syn keyword ibasicStatement swap system timer troff tron type unlock +syn keyword ibasicStatement view wait width window write +syn keyword ibasicStatement date$ mid$ time$ +" +" Do the basic variables names first. This is because it +" is the most inclusive of the tests. Later on we change +" this so the identifiers are split up into the various +" types of identifiers like functions, basic commands and +" such. MEM 9/9/2006 +" +syn match ibasicIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>" +syn match ibasicGenericFunction "\<[a-zA-Z_][a-zA-Z0-9_]*\>\s*("me=e-1,he=e-1 +" +" Function list +" +syn keyword ibasicBuiltInFunction abs asc atn cdbl cint clng cos csng csrlin cvd cvdmbf +syn keyword ibasicBuiltInFunction cvi cvl cvs cvsmbf eof erdev erl err exp fileattr +syn keyword ibasicBuiltInFunction fix fre freefile inp instr lbound len loc lof +syn keyword ibasicBuiltInFunction log lpos mod peek pen point pos rnd sadd screen seek +syn keyword ibasicBuiltInFunction setmem sgn sin spc sqr stick strig tab tan ubound +syn keyword ibasicBuiltInFunction val valptr valseg varptr varseg +syn keyword ibasicBuiltInFunction chr\$ command$ date$ environ$ erdev$ hex$ inkey$ +syn keyword ibasicBuiltInFunction input$ ioctl$ lcases$ laft$ ltrim$ mid$ mkdmbf$ mkd$ +syn keyword ibasicBuiltInFunction mki$ mkl$ mksmbf$ mks$ oct$ right$ rtrim$ space$ +syn keyword ibasicBuiltInFunction str$ string$ time$ ucase$ varptr$ +syn keyword ibasicTodo contained TODO +syn cluster ibasicFunctionCluster contains=ibasicBuiltInFunction,ibasicGenericFunction + +syn keyword Conditional if else then elseif endif select case endselect +syn keyword Repeat for do while next enddo endwhile wend + +syn keyword ibasicTypeSpecifier single double defdbl defsng +syn keyword ibasicTypeSpecifier int integer uint uinteger int64 uint64 defint deflng +syn keyword ibasicTypeSpecifier byte char string istring defstr +syn keyword ibasicDefine dim def declare +" +"catch errors caused by wrong parenthesis +" +syn cluster ibasicParenGroup contains=ibasicParenError,ibasicIncluded,ibasicSpecial,ibasicTodo,ibasicUserCont,ibasicUserLabel,ibasicBitField +syn region ibasicParen transparent start='(' end=')' contains=ALLBUT,@bParenGroup +syn match ibasicParenError ")" +syn match ibasicInParen contained "[{}]" +" +"integer number, or floating point number without a dot and with "f". +" +syn region ibasicHex start="&h" end="\W" +syn region ibasicHexError start="&h\x*[g-zG-Z]" end="\W" +syn match ibasicInteger "\<\d\+\(u\=l\=\|lu\|f\)\>" +" +"floating point number, with dot, optional exponent +" +syn match ibasicFloat "\<\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=\>" +" +"floating point number, starting with a dot, optional exponent +" +syn match ibasicFloat "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +" +"floating point number, without dot, with exponent +" +syn match ibasicFloat "\<\d\+e[-+]\=\d\+[fl]\=\>" +" +"hex number +" +syn match ibasicIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>" +syn match ibasicFunction "\<[a-zA-Z_][a-zA-Z0-9_]*\>\s*("me=e-1,he=e-1 +syn case match +syn match ibasicOctalError "\<0\o*[89]" +" +" String and Character contstants +" +syn region ibasicString start='"' end='"' contains=ibasicSpecial,ibasicTodo +syn region ibasicString start="'" end="'" contains=ibasicSpecial,ibasicTodo +" +" Comments +" +syn match ibasicSpecial contained "\\." +syn region ibasicComment start="^rem" end="$" contains=ibasicSpecial,ibasicTodo +syn region ibasicComment start=":\s*rem" end="$" contains=ibasicSpecial,ibasicTodo +syn region ibasicComment start="\s*'" end="$" contains=ibasicSpecial,ibasicTodo +syn region ibasicComment start="^'" end="$" contains=ibasicSpecial,ibasicTodo +" +" Now do the comments and labels +" +syn match ibasicLabel "^\d" +syn region ibasicLineNumber start="^\d" end="\s" +" +" Pre-compiler options : FreeBasic +" +syn region ibasicPreCondit start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=ibasicString,ibasicCharacter,ibasicNumber,ibasicCommentError,ibasicSpaceError +syn match ibasicInclude "^\s*#\s*include\s*" +" +" Create the clusters +" +syn cluster ibasicNumber contains=ibasicHex,ibasicInteger,ibasicFloat +syn cluster ibasicError contains=ibasicHexError +" +" Used with OPEN statement +" +syn match ibasicFilenumber "#\d\+" +" +"syn sync ccomment ibasicComment +" +syn match ibasicMathOperator "[\+\-\=\|\*\/\>\<\%\()[\]]" contains=ibasicParen +" +" The default methods for highlighting. Can be overridden later +" +hi def link ibasicLabel Label +hi def link ibasicConditional Conditional +hi def link ibasicRepeat Repeat +hi def link ibasicHex Number +hi def link ibasicInteger Number +hi def link ibasicFloat Number +hi def link ibasicError Error +hi def link ibasicHexError Error +hi def link ibasicStatement Statement +hi def link ibasicString String +hi def link ibasicComment Comment +hi def link ibasicLineNumber Comment +hi def link ibasicSpecial Special +hi def link ibasicTodo Todo +hi def link ibasicGenericFunction Function +hi def link ibasicBuiltInFunction Function +hi def link ibasicTypeSpecifier Type +hi def link ibasicDefine Type +hi def link ibasicInclude Include +hi def link ibasicIdentifier Identifier +hi def link ibasicFilenumber ibasicTypeSpecifier +hi def link ibasicMathOperator Operator + +let b:current_syntax = "ibasic" + +" vim: ts=8 + +endif diff --git a/syntax/icemenu.vim b/syntax/icemenu.vim new file mode 100644 index 0000000..a107b14 --- /dev/null +++ b/syntax/icemenu.vim @@ -0,0 +1,38 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Icewm Menu +" Maintainer: James Mahler +" Last Change: Fri Apr 1 15:13:48 EST 2005 +" Extensions: ~/.icewm/menu +" Comment: Icewm is a lightweight window manager. This adds syntax +" highlighting when editing your user's menu file (~/.icewm/menu). + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" not case sensitive +syntax case ignore + +" icons .xpm .png and .gif +syntax match _icon /"\=\/.*\.xpm"\=/ +syntax match _icon /"\=\/.*\.png"\=/ +syntax match _icon /"\=\/.*\.gif"\=/ +syntax match _icon /"\-"/ + +" separator +syntax keyword _rules separator + +" prog and menu +syntax keyword _ids menu prog + +" highlights +highlight link _rules Underlined +highlight link _ids Type +highlight link _icon Special + +let b:current_syntax = "IceMenu" + +endif diff --git a/syntax/icon.vim b/syntax/icon.vim new file mode 100644 index 0000000..499f626 --- /dev/null +++ b/syntax/icon.vim @@ -0,0 +1,203 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Icon +" Maintainer: Wendell Turner +" URL: ftp://ftp.halcyon.com/pub/users/wturner/icon.vim +" Last Change: 2003 May 11 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword iconFunction abs acos any args asin atan bal +syn keyword iconFunction callout center char chdir close collect copy +syn keyword iconFunction cos cset delay delete detab display dtor +syn keyword iconFunction entab errorclear exit exp find flush function +syn keyword iconFunction get getch getche getenv iand icom image +syn keyword iconFunction insert integer ior ishift ixor kbhit key +syn keyword iconFunction left list loadfunc log many map match +syn keyword iconFunction member move name numeric open ord pop +syn keyword iconFunction pos proc pull push put read reads +syn keyword iconFunction real remove rename repl reverse right rtod +syn keyword iconFunction runerr save seek seq set sin sort +syn keyword iconFunction sortf sqrt stop string system tab table +syn keyword iconFunction tan trim type upto variable where write writes + +" Keywords +syn match iconKeyword "&allocated" +syn match iconKeyword "&ascii" +syn match iconKeyword "&clock" +syn match iconKeyword "&collections" +syn match iconKeyword "&cset" +syn match iconKeyword "¤t" +syn match iconKeyword "&date" +syn match iconKeyword "&dateline" +syn match iconKeyword "&digits" +syn match iconKeyword "&dump" +syn match iconKeyword "&e" +syn match iconKeyword "&error" +syn match iconKeyword "&errornumber" +syn match iconKeyword "&errortext" +syn match iconKeyword "&errorvalue" +syn match iconKeyword "&errout" +syn match iconKeyword "&fail" +syn match iconKeyword "&features" +syn match iconKeyword "&file" +syn match iconKeyword "&host" +syn match iconKeyword "&input" +syn match iconKeyword "&lcase" +syn match iconKeyword "&letters" +syn match iconKeyword "&level" +syn match iconKeyword "&line" +syn match iconKeyword "&main" +syn match iconKeyword "&null" +syn match iconKeyword "&output" +syn match iconKeyword "&phi" +syn match iconKeyword "&pi" +syn match iconKeyword "&pos" +syn match iconKeyword "&progname" +syn match iconKeyword "&random" +syn match iconKeyword "®ions" +syn match iconKeyword "&source" +syn match iconKeyword "&storage" +syn match iconKeyword "&subject" +syn match iconKeyword "&time" +syn match iconKeyword "&trace" +syn match iconKeyword "&ucase" +syn match iconKeyword "&version" + +" Reserved words +syn keyword iconReserved break by case create default do +syn keyword iconReserved else end every fail if +syn keyword iconReserved initial link next not of +syn keyword iconReserved procedure repeat return suspend +syn keyword iconReserved then to until while + +" Storage class reserved words +syn keyword iconStorageClass global static local record + +syn keyword iconTodo contained TODO FIXME XXX BUG + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match iconSpecial contained "\\x\x\{2}\|\\\o\{3\}\|\\[bdeflnrtv\"\'\\]\|\\^c[a-zA-Z0-9]\|\\$" +syn region iconString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=iconSpecial +syn region iconCset start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=iconSpecial +syn match iconCharacter "'[^\\]'" + +" not sure about these +"syn match iconSpecialCharacter "'\\[bdeflnrtv]'" +"syn match iconSpecialCharacter "'\\\o\{3\}'" +"syn match iconSpecialCharacter "'\\x\x\{2}'" +"syn match iconSpecialCharacter "'\\^c\[a-zA-Z0-9]'" + +"when wanted, highlight trailing white space +if exists("icon_space_errors") + syn match iconSpaceError "\s*$" + syn match iconSpaceError " \+\t"me=e-1 +endif + +"catch errors caused by wrong parenthesis +syn cluster iconParenGroup contains=iconParenError,iconIncluded,iconSpecial,iconTodo,iconUserCont,iconUserLabel,iconBitField + +syn region iconParen transparent start='(' end=')' contains=ALLBUT,@iconParenGroup +syn match iconParenError ")" +syn match iconInParen contained "[{}]" + + +syn case ignore + +"integer number, or floating point number without a dot +syn match iconNumber "\<\d\+\>" + +"floating point number, with dot, optional exponent +syn match iconFloat "\<\d\+\.\d*\(e[-+]\=\d\+\)\=\>" + +"floating point number, starting with a dot, optional exponent +syn match iconFloat "\.\d\+\(e[-+]\=\d\+\)\=\>" + +"floating point number, without dot, with exponent +syn match iconFloat "\<\d\+e[-+]\=\d\+\>" + +"radix number +syn match iconRadix "\<\d\{1,2}[rR][a-zA-Z0-9]\+\>" + + +" syn match iconIdentifier "\<[a-z_][a-z0-9_]*\>" + +syn case match + +" Comment +syn match iconComment "#.*" contains=iconTodo,iconSpaceError + +syn region iconPreCondit start="^\s*$\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=iconComment,iconString,iconCharacter,iconNumber,iconCommentError,iconSpaceError + +syn region iconIncluded contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match iconIncluded contained "<[^>]*>" +syn match iconInclude "^\s*$\s*include\>\s*["<]" contains=iconIncluded +"syn match iconLineSkip "\\$" + +syn cluster iconPreProcGroup contains=iconPreCondit,iconIncluded,iconInclude,iconDefine,iconInParen,iconUserLabel + +syn region iconDefine start="^\s*$\s*\(define\>\|undef\>\)" skip="\\$" end="$" contains=ALLBUT,@iconPreProcGroup + +"wt:syn region iconPreProc "start="^\s*#\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" "end="$" contains=ALLBUT,@iconPreProcGroup + +" Highlight User Labels + +" syn cluster iconMultiGroup contains=iconIncluded,iconSpecial,iconTodo,iconUserCont,iconUserLabel,iconBitField + +if !exists("icon_minlines") + let icon_minlines = 15 +endif +exec "syn sync ccomment iconComment minlines=" . icon_minlines + +" Define the default highlighting. + +" Only when an item doesn't have highlighting + +" The default methods for highlighting. Can be overridden later + +" hi def link iconSpecialCharacter iconSpecial + +hi def link iconOctalError iconError +hi def link iconParenError iconError +hi def link iconInParen iconError +hi def link iconCommentError iconError +hi def link iconSpaceError iconError +hi def link iconCommentError iconError +hi def link iconIncluded iconString +hi def link iconCommentString iconString +hi def link iconComment2String iconString +hi def link iconCommentSkip iconComment + +hi def link iconUserLabel Label +hi def link iconCharacter Character +hi def link iconNumber Number +hi def link iconRadix Number +hi def link iconFloat Float +hi def link iconInclude Include +hi def link iconPreProc PreProc +hi def link iconDefine Macro +hi def link iconError Error +hi def link iconStatement Statement +hi def link iconPreCondit PreCondit +hi def link iconString String +hi def link iconCset String +hi def link iconComment Comment +hi def link iconSpecial SpecialChar +hi def link iconTodo Todo +hi def link iconStorageClass StorageClass +hi def link iconFunction Statement +hi def link iconReserved Label +hi def link iconKeyword Operator + +"hi def link iconIdentifier Identifier + + +let b:current_syntax = "icon" + + +endif diff --git a/syntax/idl.vim b/syntax/idl.vim new file mode 100644 index 0000000..e0149e7 --- /dev/null +++ b/syntax/idl.vim @@ -0,0 +1,328 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: IDL (Interface Description Language) +" Created By: Jody Goldberg +" Maintainer: Michael Geddes +" Last Change: 2012 Jan 11 + + +" This is an experiment. IDL's structure is simple enough to permit a full +" grammar based approach to rather than using a few heuristics. The result +" is large and somewhat repetative but seems to work. + +" There are some Microsoft extensions to idl files that are here. Some of +" them are disabled by defining idl_no_ms_extensions. +" +" The more complex of the extensions are disabled by defining idl_no_extensions. +" +" History: +" 2.0: Michael's new version +" 2.1: Support for Vim 7 spell (Anduin Withers) +" + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +try + set cpo&vim + + if exists("idlsyntax_showerror") + syn match idlError +\S+ skipwhite skipempty nextgroup=idlError + endif + + syn region idlCppQuote start='\]*>" + syn match idlInclude "^[ \t]*#[ \t]*include\>[ \t]*["<]" contains=idlIncluded,idlString + syn region idlPreCondit start="^[ \t]*#[ \t]*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=idlComment,idlCommentError + syn region idlDefine start="^[ \t]*#[ \t]*\(define\>\|undef\>\)" skip="\\$" end="$" contains=idlLiteral,idlString + + " Constants + syn keyword idlConst const skipempty skipwhite nextgroup=idlBaseType,idlBaseTypeInt + + " Attribute + syn keyword idlROAttr readonly skipempty skipwhite nextgroup=idlAttr + syn keyword idlAttr attribute skipempty skipwhite nextgroup=idlBaseTypeInt,idlBaseType + + " Types + syn region idlD4 contained start="<" end=">" skipempty skipwhite nextgroup=idlSimpDecl contains=idlSeqType,idlBaseTypeInt,idlBaseType,idlLiteral + syn keyword idlSeqType contained sequence skipempty skipwhite nextgroup=idlD4 + syn keyword idlBaseType contained float double char boolean octet any skipempty skipwhite nextgroup=idlSimpDecl + syn keyword idlBaseTypeInt contained short long skipempty skipwhite nextgroup=idlSimpDecl + syn keyword idlBaseType contained unsigned skipempty skipwhite nextgroup=idlBaseTypeInt + syn region idlD1 contained start="<" end=">" skipempty skipwhite nextgroup=idlSimpDecl contains=idlString,idlLiteral + syn keyword idlBaseType contained string skipempty skipwhite nextgroup=idlD1,idlSimpDecl + syn match idlBaseType contained "[a-zA-Z0-9_]\+[ \t]*\(::[ \t]*[a-zA-Z0-9_]\+\)*" skipempty skipwhite nextgroup=idlSimpDecl + + " Modules + syn region idlModuleContent contained start="{" end="}" skipempty skipwhite nextgroup=idlError,idlSemiColon contains=idlUnion,idlStruct,idlEnum,idlInterface,idlComment,idlTypedef,idlConst,idlException,idlModule + syn match idlModuleName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlModuleContent,idlError,idlSemiColon + syn keyword idlModule module skipempty skipwhite nextgroup=idlModuleName + + " Interfaces + syn cluster idlCommentable contains=idlComment + syn cluster idlContentCluster contains=idlUnion,idlStruct,idlEnum,idlROAttr,idlAttr,idlOp,idlOneWayOp,idlException,idlConst,idlTypedef,idlAttributes,idlErrorSquareBracket,idlErrorBracket,idlInterfaceSections + + syn region idlInterfaceContent contained start="{" end="}" skipempty skipwhite nextgroup=idlError,idlSemiColon contains=@idlContentCluster,@idlCommentable + syn match idlInheritFrom2 contained "," skipempty skipwhite nextgroup=idlInheritFrom + syn match idlInheritFrom contained "[a-zA-Z0-9_]\+[ \t]*\(::[ \t]*[a-zA-Z0-9_]\+\)*" skipempty skipwhite nextgroup=idlInheritFrom2,idlInterfaceContent + syn match idlInherit contained ":" skipempty skipwhite nextgroup=idlInheritFrom + syn match idlInterfaceName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlInterfaceContent,idlInherit,idlError,idlSemiColon + syn keyword idlInterface interface dispinterface skipempty skipwhite nextgroup=idlInterfaceName + syn keyword idlInterfaceSections contained properties methods skipempty skipwhite nextgroup=idlSectionColon,idlError + syn match idlSectionColon contained ":" + + + syn match idlLibraryName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlLibraryContent,idlError,idlSemiColon + syn keyword idlLibrary library skipempty skipwhite nextgroup=idlLibraryName + syn region idlLibraryContent contained start="{" end="}" skipempty skipwhite nextgroup=idlError,idlSemiColon contains=@idlCommentable,idlAttributes,idlErrorSquareBracket,idlErrorBracket,idlImportlib,idlCoclass,idlTypedef,idlInterface + + syn keyword idlImportlib contained importlib skipempty skipwhite nextgroup=idlStringArg + syn region idlStringArg contained start="(" end=")" contains=idlString nextgroup=idlError,idlSemiColon,idlErrorBrace,idlErrorSquareBracket + + syn keyword idlCoclass coclass contained skipempty skipwhite nextgroup=idlCoclassName + syn match idlCoclassName "[a-zA-Z0-9_]\+" contained skipempty skipwhite nextgroup=idlCoclassDefinition,idlError,idlSemiColon + + syn region idlCoclassDefinition contained start="{" end="}" contains=idlCoclassAttributes,idlInterface,idlErrorBracket,idlErrorSquareBracket skipempty skipwhite nextgroup=idlError,idlSemiColon + syn region idlCoclassAttributes contained start=+\[+ end=+]+ skipempty skipwhite nextgroup=idlInterface contains=idlErrorBracket,idlErrorBrace,idlCoclassAttribute + syn keyword idlCoclassAttribute contained default source + "syn keyword idlInterface interface skipempty skipwhite nextgroup=idlInterfaceStubName + + syn match idlImportString +"\f\+"+ skipempty skipwhite nextgroup=idlError,idlSemiColon + syn keyword idlImport import skipempty skipwhite nextgroup=idlImportString + + syn region idlAttributes start="\[" end="\]" contains=idlAttribute,idlAttributeParam,idlErrorBracket,idlErrorBrace,idlComment + syn keyword idlAttribute contained propput propget propputref id helpstring object uuid pointer_default + if !exists('idl_no_ms_extensions') + syn keyword idlAttribute contained nonextensible dual version aggregatable restricted hidden noncreatable oleautomation + endif + syn region idlAttributeParam contained start="(" end=")" contains=idlString,idlUuid,idlLiteral,idlErrorBrace,idlErrorSquareBracket + " skipwhite nextgroup=idlArraySize,idlParmList contains=idlArraySize,idlLiteral + syn match idlErrorBrace contained "}" + syn match idlErrorBracket contained ")" + syn match idlErrorSquareBracket contained "\]" + + syn match idlUuid contained +[0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}+ + + " Raises + syn keyword idlRaises contained raises skipempty skipwhite nextgroup=idlRaises,idlContext,idlError,idlSemiColon + + " Context + syn keyword idlContext contained context skipempty skipwhite nextgroup=idlRaises,idlContext,idlError,idlSemiColon + + " Operation + syn match idlParmList contained "," skipempty skipwhite nextgroup=idlOpParms + syn region idlArraySize contained start="\[" end="\]" skipempty skipwhite nextgroup=idlArraySize,idlParmList contains=idlArraySize,idlLiteral + syn match idlParmName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlParmList,idlArraySize + syn keyword idlParmInt contained short long skipempty skipwhite nextgroup=idlParmName + syn keyword idlParmType contained unsigned skipempty skipwhite nextgroup=idlParmInt + syn region idlD3 contained start="<" end=">" skipempty skipwhite nextgroup=idlParmName contains=idlString,idlLiteral + syn keyword idlParmType contained string skipempty skipwhite nextgroup=idlD3,idlParmName + syn keyword idlParmType contained void float double char boolean octet any skipempty skipwhite nextgroup=idlParmName + syn match idlParmType contained "[a-zA-Z0-9_]\+[ \t]*\(::[ \t]*[a-zA-Z0-9_]\+\)*" skipempty skipwhite nextgroup=idlParmName + syn keyword idlOpParms contained in out inout skipempty skipwhite nextgroup=idlParmType + + if !exists('idl_no_ms_extensions') + syn keyword idlOpParms contained retval optional skipempty skipwhite nextgroup=idlParmType + syn match idlOpParms contained +\<\(iid_is\|defaultvalue\)\s*([^)]*)+ skipempty skipwhite nextgroup=idlParamType + + syn keyword idlVariantType contained BSTR VARIANT VARIANT_BOOL long short unsigned double CURRENCY DATE + syn region idlSafeArray contained matchgroup=idlVariantType start=+SAFEARRAY(\s*+ end=+)+ contains=idlVariantType + endif + + syn region idlOpContents contained start="(" end=")" skipempty skipwhite nextgroup=idlRaises,idlContext,idlError,idlSemiColon contains=idlOpParms,idlSafeArray,idlVariantType,@idlCommentable + syn match idlOpName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlOpContents + syn keyword idlOpInt contained short long skipempty skipwhite nextgroup=idlOpName + syn region idlD2 contained start="<" end=">" skipempty skipwhite nextgroup=idlOpName contains=idlString,idlLiteral + syn keyword idlOp contained unsigned skipempty skipwhite nextgroup=idlOpInt + syn keyword idlOp contained string skipempty skipwhite nextgroup=idlD2,idlOpName + syn keyword idlOp contained void float double char boolean octet any skipempty skipwhite nextgroup=idlOpName + syn match idlOp contained "[a-zA-Z0-9_]\+[ \t]*\(::[ \t]*[a-zA-Z0-9_]\+\)*" skipempty skipwhite nextgroup=idlOpName + syn keyword idlOp contained void skipempty skipwhite nextgroup=idlOpName + syn keyword idlOneWayOp contained oneway skipempty skipwhite nextgroup=idOp + + " Enum + syn region idlEnumContents contained start="{" end="}" skipempty skipwhite nextgroup=idlError,idlSemiColon,idlSimpDecl contains=idlId,idlAttributes,@idlCommentable + syn match idlEnumName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlEnumContents + syn keyword idlEnum enum skipempty skipwhite nextgroup=idlEnumName,idlEnumContents + + " Typedef + syn keyword idlTypedef typedef skipempty skipwhite nextgroup=idlTypedefOtherTypeQualifier,idlDefBaseType,idlDefBaseTypeInt,idlDefSeqType,idlDefv1Enum,idlDefEnum,idlDefOtherType,idlDefAttributes,idlError + + if !exists('idl_no_extensions') + syn keyword idlTypedefOtherTypeQualifier contained struct enum interface nextgroup=idlDefBaseType,idlDefBaseTypeInt,idlDefSeqType,idlDefv1Enum,idlDefEnum,idlDefOtherType,idlDefAttributes,idlError skipwhite + + syn region idlDefAttributes contained start="\[" end="\]" contains=idlAttribute,idlAttributeParam,idlErrorBracket,idlErrorBrace skipempty skipwhite nextgroup=idlDefBaseType,idlDefBaseTypeInt,idlDefSeqType,idlDefv1Enum,idlDefEnum,idlDefOtherType,idlError + + syn keyword idlDefBaseType contained float double char boolean octet any skipempty skipwhite nextgroup=idlTypedefDecl,idlError + syn keyword idlDefBaseTypeInt contained short long skipempty skipwhite nextgroup=idlTypedefDecl,idlError + syn match idlDefOtherType contained +\<\k\+\>+ skipempty nextgroup=idlTypedefDecl,idlError + " syn keyword idlDefSeqType contained sequence skipempty skipwhite nextgroup=idlD4 + + " Enum typedef + syn keyword idlDefEnum contained enum skipempty skipwhite nextgroup=idlDefEnumName,idlDefEnumContents + syn match idlDefEnumName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlDefEnumContents,idlTypedefDecl + syn region idlDefEnumContents contained start="{" end="}" skipempty skipwhite nextgroup=idlError,idlTypedefDecl contains=idlId,idlAttributes + + syn match idlTypedefDecl contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlError,idlSemiColon + endif + + " Struct + syn region idlStructContent contained start="{" end="}" skipempty skipwhite nextgroup=idlError,idlSemiColon,idlSimpDecl contains=idlBaseType,idlBaseTypeInt,idlSeqType,@idlCommentable,idlEnum,idlUnion + syn match idlStructName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlStructContent + syn keyword idlStruct struct skipempty skipwhite nextgroup=idlStructName + + " Exception + syn keyword idlException exception skipempty skipwhite nextgroup=idlStructName + + " Union + syn match idlColon contained ":" skipempty skipwhite nextgroup=idlCase,idlSeqType,idlBaseType,idlBaseTypeInt + syn region idlCaseLabel contained start="" skip="::" end=":"me=e-1 skipempty skipwhite nextgroup=idlColon contains=idlLiteral,idlString + syn keyword idlCase contained case skipempty skipwhite nextgroup=idlCaseLabel + syn keyword idlCase contained default skipempty skipwhite nextgroup=idlColon + syn region idlUnionContent contained start="{" end="}" skipempty skipwhite nextgroup=idlError,idlSemiColon,idlSimpDecl contains=idlCase + syn region idlSwitchType contained start="(" end=")" skipempty skipwhite nextgroup=idlUnionContent + syn keyword idlUnionSwitch contained switch skipempty skipwhite nextgroup=idlSwitchType + syn match idlUnionName contained "[a-zA-Z0-9_]\+" skipempty skipwhite nextgroup=idlUnionSwitch + syn keyword idlUnion union skipempty skipwhite nextgroup=idlUnionName + + if !exists('idl_no_extensions') + syn sync match idlInterfaceSync grouphere idlInterfaceContent "\<\(disp\)\=interface\>\s\+\k\+\s*:\s*\k\+\_s*{" skipempty skipwhite nextgroup=idlError,idlSemiColon contains=@idlContentCluster,@idlCommentable + syn sync maxlines=1000 minlines=100 + else + syn sync lines=200 + endif + " syn sync fromstart + + if !exists("did_idl_syntax_inits") + let did_idl_syntax_inits = 1 + " The default methods for highlighting. Can be overridden later + + hi def link idlInclude Include + hi def link idlPreProc PreProc + hi def link idlPreCondit PreCondit + hi def link idlDefine Macro + hi def link idlIncluded String + hi def link idlString String + hi def link idlComment Comment + hi def link idlTodo Todo + hi def link idlLiteral Number + hi def link idlUuid Number + hi def link idlType Type + hi def link idlVariantType idlType + + hi def link idlModule Keyword + hi def link idlInterface Keyword + hi def link idlEnum Keyword + hi def link idlStruct Keyword + hi def link idlUnion Keyword + hi def link idlTypedef Keyword + hi def link idlException Keyword + hi def link idlTypedefOtherTypeQualifier keyword + + hi def link idlModuleName Typedef + hi def link idlInterfaceName Typedef + hi def link idlEnumName Typedef + hi def link idlStructName Typedef + hi def link idlUnionName Typedef + + hi def link idlBaseTypeInt idlType + hi def link idlBaseType idlType + hi def link idlSeqType idlType + hi def link idlD1 Paren + hi def link idlD2 Paren + hi def link idlD3 Paren + hi def link idlD4 Paren + "hi def link idlArraySize Paren + "hi def link idlArraySize1 Paren + hi def link idlModuleContent Paren + hi def link idlUnionContent Paren + hi def link idlStructContent Paren + hi def link idlEnumContents Paren + hi def link idlInterfaceContent Paren + + hi def link idlSimpDecl Identifier + hi def link idlROAttr StorageClass + hi def link idlAttr Keyword + hi def link idlConst StorageClass + + hi def link idlOneWayOp StorageClass + hi def link idlOp idlType + hi def link idlParmType idlType + hi def link idlOpName Function + hi def link idlOpParms SpecialComment + hi def link idlParmName Identifier + hi def link idlInheritFrom Identifier + hi def link idlAttribute SpecialComment + + hi def link idlId Constant + "hi def link idlCase Keyword + hi def link idlCaseLabel Constant + + hi def link idlErrorBracket Error + hi def link idlErrorBrace Error + hi def link idlErrorSquareBracket Error + + hi def link idlImport Keyword + hi def link idlImportString idlString + hi def link idlCoclassAttribute StorageClass + hi def link idlLibrary Keyword + hi def link idlImportlib Keyword + hi def link idlCoclass Keyword + hi def link idlLibraryName Typedef + hi def link idlCoclassName Typedef + " hi def link idlLibraryContent guifg=red + hi def link idlTypedefDecl Typedef + hi def link idlDefEnum Keyword + hi def link idlDefv1Enum Keyword + hi def link idlDefEnumName Typedef + hi def link idlDefEnumContents Paren + hi def link idlDefBaseTypeInt idlType + hi def link idlDefBaseType idlType + hi def link idlDefSeqType idlType + hi def link idlInterfaceSections Label + + if exists("idlsyntax_showerror") + if exists("idlsyntax_showerror_soft") + hi default idlError guibg=#d0ffd0 + else + hi def link idlError Error + endif + endif + endif + + let b:current_syntax = "idl" +finally + let &cpo = s:cpo_save + unlet s:cpo_save +endtry +" vim: sw=2 et + +endif diff --git a/syntax/idlang.vim b/syntax/idlang.vim new file mode 100644 index 0000000..9c429b3 --- /dev/null +++ b/syntax/idlang.vim @@ -0,0 +1,244 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Interactive Data Language syntax file (IDL, too [:-)] +" Maintainer: Aleksandar Jelenak +" Last change: 2011 Apr 11 +" Created by: Hermann Rochholz + +" Remove any old syntax stuff hanging around +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syntax case ignore + +syn match idlangStatement "^\s*pro\s" +syn match idlangStatement "^\s*function\s" +syn keyword idlangStatement return continue mod do break +syn keyword idlangStatement compile_opt forward_function goto +syn keyword idlangStatement begin common end of +syn keyword idlangStatement inherits on_ioerror begin + +syn keyword idlangConditional if else then for while case switch +syn keyword idlangConditional endcase endelse endfor endswitch +syn keyword idlangConditional endif endrep endwhile repeat until + +syn match idlangOperator "\ and\ " +syn match idlangOperator "\ eq\ " +syn match idlangOperator "\ ge\ " +syn match idlangOperator "\ gt\ " +syn match idlangOperator "\ le\ " +syn match idlangOperator "\ lt\ " +syn match idlangOperator "\ ne\ " +syn match idlangOperator /\(\ \|(\)not\ /hs=e-3 +syn match idlangOperator "\ or\ " +syn match idlangOperator "\ xor\ " + +syn keyword idlangStop stop pause + +syn match idlangStrucvar "\h\w*\(\.\h\w*\)\+" +syn match idlangStrucvar "[),\]]\(\.\h\w*\)\+"hs=s+1 + +syn match idlangSystem "\!\a\w*\(\.\w*\)\=" + +syn match idlangKeyword "\([(,]\s*\(\$\_s*\)\=\)\@<=/\h\w*" +syn match idlangKeyword "\([(,]\s*\(\$\_s*\)\=\)\@<=\h\w*\s*=" + +syn keyword idlangTodo contained TODO + +syn region idlangString start=+"+ end=+"+ +syn region idlangString start=+'+ end=+'+ + +syn match idlangPreCondit "^\s*@\w*\(\.\a\{3}\)\=" + +syn match idlangRealNumber "\<\d\+\(\.\=\d*e[+-]\=\d\+\|\.\d*d\|\.\d*\|d\)" +syn match idlangRealNumber "\.\d\+\(d\|e[+-]\=\d\+\)\=" + +syn match idlangNumber "\<\.\@!\d\+\.\@!\(b\|u\|us\|s\|l\|ul\|ll\|ull\)\=\>" + +syn match idlangComment "[\;].*$" contains=idlangTodo + +syn match idlangContinueLine "\$\s*\($\|;\)"he=s+1 contains=idlangComment +syn match idlangContinueLine "&\s*\(\h\|;\)"he=s+1 contains=ALL + +syn match idlangDblCommaError "\,\s*\," + +" List of standard routines as of IDL version 5.4. +syn match idlangRoutine "EOS_\a*" +syn match idlangRoutine "HDF_\a*" +syn match idlangRoutine "CDF_\a*" +syn match idlangRoutine "NCDF_\a*" +syn match idlangRoutine "QUERY_\a*" +syn match idlangRoutine "\ +" Latest Revision: 2010-01-23 +" indent_is_bsd: If exists, will change somewhat to match BSD implementation +" +" TODO: is the deny-all (a la lilo.vim nice or no?)... +" irritating to be wrong to the last char... +" would be sweet if right until one char fails + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword+=-,+ + +syn match indentError '\S\+' + +syn keyword indentTodo contained TODO FIXME XXX NOTE + +syn region indentComment start='/\*' end='\*/' + \ contains=indentTodo,@Spell +syn region indentComment start='//' skip='\\$' end='$' + \ contains=indentTodo,@Spell + +if !exists("indent_is_bsd") + syn match indentOptions '-i\|--indentation-level\|-il\|--indent-level' + \ nextgroup=indentNumber skipwhite skipempty +endif +syn match indentOptions '-\%(bli\|c\%([bl]i\|[dip]\)\=\|di\=\|ip\=\|lc\=\|pp\=i\|sbi\|ts\|-\%(brace-indent\|comment-indentation\|case-brace-indentation\|declaration-comment-column\|continuation-indentation\|case-indentation\|else-endif-column\|line-comments-indentation\|declaration-indentation\|indent-level\|parameter-indentation\|line-length\|comment-line-length\|paren-indentation\|preprocessor-indentation\|struct-brace-indentation\|tab-size\)\)' + \ nextgroup=indentNumber skipwhite skipempty + +syn match indentNumber display contained '\d\+\>' + +syn match indentOptions '-T' + \ nextgroup=indentIdent skipwhite skipempty + +syn match indentIdent display contained '\h\w*\>' + +syn keyword indentOptions -bacc --blank-lines-after-ifdefs + \ -bad --blank-lines-after-declarations + \ -badp --blank-lines-after-procedure-declarations + \ -bap --blank-lines-after-procedures + \ -bbb --blank-lines-before-block-comments + \ -bbo --break-before-boolean-operator + \ -bc --blank-lines-after-commas + \ -bfda --break-function-decl-args + \ -bfde --break-function-decl-args-end + \ -bl --braces-after-if-line + \ -blf --braces-after-func-def-line + \ -bls --braces-after-struct-decl-line + \ -br --braces-on-if-line + \ -brf --braces-on-func-def-line + \ -brs --braces-on-struct-decl-line + \ -bs --Bill-Shannon --blank-before-sizeof + \ -c++ --c-plus-plus + \ -cdb --comment-delimiters-on-blank-lines + \ -cdw --cuddle-do-while + \ -ce --cuddle-else + \ -cs --space-after-cast + \ -dj --left-justify-declarations + \ -eei --extra-expression-indentation + \ -fc1 --format-first-column-comments + \ -fca --format-all-comments + \ -gnu --gnu-style + \ -h --help --usage + \ -hnl --honour-newlines + \ -kr --k-and-r-style --kernighan-and-ritchie --kernighan-and-ritchie-style + \ -lp --continue-at-parentheses + \ -lps --leave-preprocessor-space + \ -nbacc --no-blank-lines-after-ifdefs + \ -nbad --no-blank-lines-after-declarations + \ -nbadp --no-blank-lines-after-procedure-declarations + \ -nbap --no-blank-lines-after-procedures + \ -nbbb --no-blank-lines-before-block-comments + \ -nbbo --break-after-boolean-operator + \ -nbc --no-blank-lines-after-commas + \ -nbfda --dont-break-function-decl-args + \ -nbfde --dont-break-function-decl-args-end + \ -nbs --no-Bill-Shannon --no-blank-before-sizeof + \ -ncdb --no-comment-delimiters-on-blank-lines + \ -ncdw --dont-cuddle-do-while + \ -nce --dont-cuddle-else + \ -ncs --no-space-after-casts + \ -ndj --dont-left-justify-declarations + \ -neei --no-extra-expression-indentation + \ -nfc1 --dont-format-first-column-comments + \ -nfca --dont-format-comments + \ -nhnl --ignore-newlines + \ -nip --dont-indent-parameters --no-parameter-indentation + \ -nlp --dont-line-up-parentheses + \ -nlps --remove-preprocessor-space + \ -npcs --no-space-after-function-call-names + \ -npmt + \ -npro --ignore-profile + \ -nprs --no-space-after-parentheses + \ -npsl --dont-break-procedure-type + \ -nsaf --no-space-after-for + \ -nsai --no-space-after-if + \ -nsaw --no-space-after-while + \ -nsc --dont-star-comments + \ -nsob --leave-optional-blank-lines + \ -nss --dont-space-special-semicolon + \ -nut --no-tabs + \ -nv --no-verbosity + \ -o --output + \ -o --output-file + \ -orig --berkeley --berkeley-style --original --original-style + \ -pcs --space-after-procedure-calls + \ -pmt --preserve-mtime + \ -prs --space-after-parentheses + \ -psl --procnames-start-lines + \ -saf --space-after-for + \ -sai --space-after-if + \ -saw --space-after-while + \ -sc --start-left-side-of-comments + \ -sob --swallow-optional-blank-lines + \ -ss --space-special-semicolon + \ -st --standard-output + \ -ut --use-tabs + \ -v --verbose + \ -version --version + \ -linux --linux-style + +if exists("indent_is_bsd") + syn keyword indentOptions -ip -ei -nei +endif + +if exists("c_minlines") + let b:c_minlines = c_minlines +else + if !exists("c_no_if0") + let b:c_minlines = 50 " #if 0 constructs can be long + else + let b:c_minlines = 15 " mostly for () constructs + endif +endif + +hi def link indentError Error +hi def link indentComment Comment +hi def link indentTodo Todo +hi def link indentOptions Keyword +hi def link indentNumber Number +hi def link indentIdent Identifier + +let b:current_syntax = "indent" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/inform.vim b/syntax/inform.vim new file mode 100644 index 0000000..583e397 --- /dev/null +++ b/syntax/inform.vim @@ -0,0 +1,396 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Inform +" Maintainer: Stephen Thomas (stephen@gowarthomas.com) +" URL: http://www.gowarthomas.com/informvim +" Last Change: 2006 April 20 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful Inform keywords. First, case insensitive stuff + +syn case ignore + +syn keyword informDefine Constant + +syn keyword informType Array Attribute Class Nearby +syn keyword informType Object Property String Routine +syn match informType "\" + +syn keyword informInclude Import Include Link Replace System_file + +syn keyword informPreCondit End Endif Ifdef Ifndef Iftrue Iffalse Ifv3 Ifv5 +syn keyword informPreCondit Ifnot + +syn keyword informPreProc Abbreviate Default Fake_action Lowstring +syn keyword informPreProc Message Release Serial Statusline Stub Switches +syn keyword informPreProc Trace Zcharacter + +syn region informGlobalRegion matchgroup=informType start="\" matchgroup=NONE skip=+!.*$\|".*"\|'.*'+ end=";" contains=ALLBUT,informGramPreProc,informPredicate,informGrammar,informAsm,informAsmObsolete + +syn keyword informGramPreProc contained Verb Extend + +if !exists("inform_highlight_simple") + syn keyword informLibAttrib absent animate clothing concealed container + syn keyword informLibAttrib door edible enterable female general light + syn keyword informLibAttrib lockable locked male moved neuter on open + syn keyword informLibAttrib openable pluralname proper scenery scored + syn keyword informLibAttrib static supporter switchable talkable + syn keyword informLibAttrib visited workflag worn + syn match informLibAttrib "\" + + syn keyword informLibProp e_to se_to s_to sw_to w_to nw_to n_to ne_to + syn keyword informLibProp u_to d_to in_to out_to before after life + syn keyword informLibProp door_to with_key door_dir invent plural + syn keyword informLibProp add_to_scope list_together react_before + syn keyword informLibProp react_after grammar orders initial when_open + syn keyword informLibProp when_closed when_on when_off description + syn keyword informLibProp describe article cant_go found_in time_left + syn keyword informLibProp number time_out daemon each_turn capacity + syn keyword informLibProp name short_name short_name_indef parse_name + syn keyword informLibProp articles inside_description + if !exists("inform_highlight_old") + syn keyword informLibProp compass_look before_implicit + syn keyword informLibProp ext_initialise ext_messages + endif + + syn keyword informLibObj e_obj se_obj s_obj sw_obj w_obj nw_obj n_obj + syn keyword informLibObj ne_obj u_obj d_obj in_obj out_obj compass + syn keyword informLibObj thedark selfobj player location second actor + syn keyword informLibObj noun + if !exists("inform_highlight_old") + syn keyword informLibObj LibraryExtensions + endif + + syn keyword informLibRoutine Achieved AfterRoutines AddToScope + syn keyword informLibRoutine AllowPushDir Banner ChangeDefault + syn keyword informLibRoutine ChangePlayer CommonAncestor DictionaryLookup + syn keyword informLibRoutine DisplayStatus DoMenu DrawStatusLine + syn keyword informLibRoutine EnglishNumber HasLightSource GetGNAOfObject + syn keyword informLibRoutine IndirectlyContains IsSeeThrough Locale + syn keyword informLibRoutine LoopOverScope LTI_Insert MoveFloatingObjects + syn keyword informLibRoutine NextWord NextWordStopped NounDomain + syn keyword informLibRoutine ObjectIsUntouchable OffersLight ParseToken + syn keyword informLibRoutine PlaceInScope PlayerTo PrintShortName + syn keyword informLibRoutine PronounNotice ScopeWithin SetPronoun SetTime + syn keyword informLibRoutine StartDaemon StartTimer StopDaemon StopTimer + syn keyword informLibRoutine TestScope TryNumber UnsignedCompare + syn keyword informLibRoutine WordAddress WordInProperty WordLength + syn keyword informLibRoutine WriteListFrom YesOrNo ZRegion RunRoutines + syn keyword informLibRoutine AfterLife AfterPrompt Amusing BeforeParsing + syn keyword informLibRoutine ChooseObjects DarkToDark DeathMessage + syn keyword informLibRoutine GamePostRoutine GamePreRoutine Initialise + syn keyword informLibRoutine InScope LookRoutine NewRoom ParseNoun + syn keyword informLibRoutine ParseNumber ParserError PrintRank PrintVerb + syn keyword informLibRoutine PrintTaskName TimePasses UnknownVerb + if exists("inform_highlight_glulx") + syn keyword informLibRoutine IdentifyGlkObject HandleGlkEvent + syn keyword informLibRoutine InitGlkWindow + endif + if !exists("inform_highlight_old") + syn keyword informLibRoutine KeyCharPrimitive KeyDelay ClearScreen + syn keyword informLibRoutine MoveCursor MainWindow StatusLineHeight + syn keyword informLibRoutine ScreenWidth ScreenHeight SetColour + syn keyword informLibRoutine DecimalNumber PrintToBuffer Length + syn keyword informLibRoutine UpperCase LowerCase PrintCapitalised + syn keyword informLibRoutine Cap Centre + if exists("inform_highlight_glulx") + syn keyword informLibRoutine PrintAnything PrintAnyToArray + endif + endif + + syn keyword informLibAction Quit Restart Restore Verify Save + syn keyword informLibAction ScriptOn ScriptOff Pronouns Score + syn keyword informLibAction Fullscore LMode1 LMode2 LMode3 + syn keyword informLibAction NotifyOn NotifyOff Version Places + syn keyword informLibAction Objects TraceOn TraceOff TraceLevel + syn keyword informLibAction ActionsOn ActionsOff RoutinesOn + syn keyword informLibAction RoutinesOff TimersOn TimersOff + syn keyword informLibAction CommandsOn CommandsOff CommandsRead + syn keyword informLibAction Predictable XPurloin XAbstract XTree + syn keyword informLibAction Scope Goto Gonear Inv InvTall InvWide + syn keyword informLibAction Take Drop Remove PutOn Insert Transfer + syn keyword informLibAction Empty Enter Exit GetOff Go Goin Look + syn keyword informLibAction Examine Search Give Show Unlock Lock + syn keyword informLibAction SwitchOn SwitchOff Open Close Disrobe + syn keyword informLibAction Wear Eat Yes No Burn Pray Wake + syn keyword informLibAction WakeOther Consult Kiss Think Smell + syn keyword informLibAction Listen Taste Touch Dig Cut Jump + syn keyword informLibAction JumpOver Tie Drink Fill Sorry Strong + syn keyword informLibAction Mild Attack Swim Swing Blow Rub Set + syn keyword informLibAction SetTo WaveHands Wave Pull Push PushDir + syn keyword informLibAction Turn Squeeze LookUnder ThrowAt Tell + syn keyword informLibAction Answer Buy Ask AskFor Sing Climb Wait + syn keyword informLibAction Sleep LetGo Receive ThrownAt Order + syn keyword informLibAction TheSame PluralFound Miscellany Prompt + syn keyword informLibAction ChangesOn ChangesOff Showverb Showobj + syn keyword informLibAction EmptyT VagueGo + if exists("inform_highlight_glulx") + syn keyword informLibAction GlkList + endif + + syn keyword informLibVariable keep_silent deadflag action special_number + syn keyword informLibVariable consult_from consult_words etype verb_num + syn keyword informLibVariable verb_word the_time real_location c_style + syn keyword informLibVariable parser_one parser_two listing_together wn + syn keyword informLibVariable parser_action scope_stage scope_reason + syn keyword informLibVariable action_to_be menu_item item_name item_width + syn keyword informLibVariable lm_o lm_n inventory_style task_scores + syn keyword informLibVariable inventory_stage + + syn keyword informLibConst AMUSING_PROVIDED DEBUG Headline MAX_CARRIED + syn keyword informLibConst MAX_SCORE MAX_TIMERS NO_PLACES NUMBER_TASKS + syn keyword informLibConst OBJECT_SCORE ROOM_SCORE SACK_OBJECT Story + syn keyword informLibConst TASKS_PROVIDED WITHOUT_DIRECTIONS + syn keyword informLibConst NEWLINE_BIT INDENT_BIT FULLINV_BIT ENGLISH_BIT + syn keyword informLibConst RECURSE_BIT ALWAYS_BIT TERSE_BIT PARTINV_BIT + syn keyword informLibConst DEFART_BIT WORKFLAG_BIT ISARE_BIT CONCEAL_BIT + syn keyword informLibConst PARSING_REASON TALKING_REASON EACHTURN_REASON + syn keyword informLibConst REACT_BEFORE_REASON REACT_AFTER_REASON + syn keyword informLibConst TESTSCOPE_REASON LOOPOVERSCOPE_REASON + syn keyword informLibConst STUCK_PE UPTO_PE NUMBER_PE CANTSEE_PE TOOLIT_PE + syn keyword informLibConst NOTHELD_PE MULTI_PE MMULTI_PE VAGUE_PE EXCEPT_PE + syn keyword informLibConst ANIMA_PE VERB_PE SCENERY_PE ITGONE_PE + syn keyword informLibConst JUNKAFTER_PE TOOFEW_PE NOTHING_PE ASKSCOPE_PE + if !exists("inform_highlight_old") + syn keyword informLibConst WORDSIZE TARGET_ZCODE TARGET_GLULX + syn keyword informLibConst LIBRARY_PARSER LIBRARY_VERBLIB LIBRARY_GRAMMAR + syn keyword informLibConst LIBRARY_ENGLISH NO_SCORE START_MOVE + syn keyword informLibConst CLR_DEFAULT CLR_BLACK CLR_RED CLR_GREEN + syn keyword informLibConst CLR_YELLOW CLR_BLUE CLR_MAGENTA CLR_CYAN + syn keyword informLibConst CLR_WHITE CLR_PURPLE CLR_AZURE + syn keyword informLibConst WIN_ALL WIN_MAIN WIN_STATUS + endif +endif + +" Now the case sensitive stuff. + +syntax case match + +syn keyword informSysFunc child children elder indirect parent random +syn keyword informSysFunc sibling younger youngest metaclass +if exists("inform_highlight_glulx") + syn keyword informSysFunc glk +endif + +syn keyword informSysConst adjectives_table actions_table classes_table +syn keyword informSysConst identifiers_table preactions_table version_number +syn keyword informSysConst largest_object strings_offset code_offset +syn keyword informSysConst dict_par1 dict_par2 dict_par3 +syn keyword informSysConst actual_largest_object static_memory_offset +syn keyword informSysConst array_names_offset readable_memory_offset +syn keyword informSysConst cpv__start cpv__end ipv__start ipv__end +syn keyword informSysConst array__start array__end lowest_attribute_number +syn keyword informSysConst highest_attribute_number attribute_names_array +syn keyword informSysConst lowest_property_number highest_property_number +syn keyword informSysConst property_names_array lowest_action_number +syn keyword informSysConst highest_action_number action_names_array +syn keyword informSysConst lowest_fake_action_number highest_fake_action_number +syn keyword informSysConst fake_action_names_array lowest_routine_number +syn keyword informSysConst highest_routine_number routines_array +syn keyword informSysConst routine_names_array routine_flags_array +syn keyword informSysConst lowest_global_number highest_global_number globals_array +syn keyword informSysConst global_names_array global_flags_array +syn keyword informSysConst lowest_array_number highest_array_number arrays_array +syn keyword informSysConst array_names_array array_flags_array lowest_constant_number +syn keyword informSysConst highest_constant_number constants_array constant_names_array +syn keyword informSysConst lowest_class_number highest_class_number class_objects_array +syn keyword informSysConst lowest_object_number highest_object_number +if !exists("inform_highlight_old") + syn keyword informSysConst sys_statusline_flag +endif + +syn keyword informConditional default else if switch + +syn keyword informRepeat break continue do for objectloop until while + +syn keyword informStatement box font give inversion jump move new_line +syn keyword informStatement print print_ret quit read remove restore return +syn keyword informStatement rfalse rtrue save spaces string style + +syn keyword informOperator roman reverse bold underline fixed on off to +syn keyword informOperator near from + +syn keyword informKeyword dictionary symbols objects verbs assembly +syn keyword informKeyword expressions lines tokens linker on off alias long +syn keyword informKeyword additive score time string table +syn keyword informKeyword with private has class error fatalerror +syn keyword informKeyword warning self +if !exists("inform_highlight_old") + syn keyword informKeyword buffer +endif + +syn keyword informMetaAttrib remaining create destroy recreate copy call +syn keyword informMetaAttrib print_to_array + +syn keyword informPredicate has hasnt in notin ofclass or +syn keyword informPredicate provides + +syn keyword informGrammar contained noun held multi multiheld multiexcept +syn keyword informGrammar contained multiinside creature special number +syn keyword informGrammar contained scope topic reverse meta only replace +syn keyword informGrammar contained first last + +syn keyword informKeywordObsolete contained initial data initstr + +syn keyword informTodo contained TODO + +" Assembly language mnemonics must be preceded by a '@'. + +syn match informAsmContainer "@\s*\k*" contains=informAsm,informAsmObsolete + +if exists("inform_highlight_glulx") + syn keyword informAsm contained nop add sub mul div mod neg bitand bitor + syn keyword informAsm contained bitxor bitnot shiftl sshiftr ushiftr jump jz + syn keyword informAsm contained jnz jeq jne jlt jge jgt jle jltu jgeu jgtu + syn keyword informAsm contained jleu call return catch throw tailcall copy + syn keyword informAsm contained copys copyb sexs sexb aload aloads aloadb + syn keyword informAsm contained aloadbit astore astores astoreb astorebit + syn keyword informAsm contained stkcount stkpeek stkswap stkroll stkcopy + syn keyword informAsm contained streamchar streamnum streamstr gestalt + syn keyword informAsm contained debugtrap getmemsize setmemsize jumpabs + syn keyword informAsm contained random setrandom quit verify restart save + syn keyword informAsm contained restore saveundo restoreundo protect glk + syn keyword informAsm contained getstringtbl setstringtbl getiosys setiosys + syn keyword informAsm contained linearsearch binarysearch linkedsearch + syn keyword informAsm contained callf callfi callfii callfiii +else + syn keyword informAsm contained je jl jg dec_chk inc_chk jin test or and + syn keyword informAsm contained test_attr set_attr clear_attr store + syn keyword informAsm contained insert_obj loadw loadb get_prop + syn keyword informAsm contained get_prop_addr get_next_prop add sub mul div + syn keyword informAsm contained mod call storew storeb put_prop sread + syn keyword informAsm contained print_num random push pull + syn keyword informAsm contained split_window set_window output_stream + syn keyword informAsm contained input_stream sound_effect jz get_sibling + syn keyword informAsm contained get_child get_parent get_prop_len inc dec + syn keyword informAsm contained remove_obj print_obj ret jump + syn keyword informAsm contained load not rtrue rfalse print + syn keyword informAsm contained print_ret nop save restore restart + syn keyword informAsm contained ret_popped pop quit new_line show_status + syn keyword informAsm contained verify call_2s call_vs aread call_vs2 + syn keyword informAsm contained erase_window erase_line set_cursor get_cursor + syn keyword informAsm contained set_text_style buffer_mode read_char + syn keyword informAsm contained scan_table call_1s call_2n set_colour throw + syn keyword informAsm contained call_vn call_vn2 tokenise encode_text + syn keyword informAsm contained copy_table print_table check_arg_count + syn keyword informAsm contained call_1n catch piracy log_shift art_shift + syn keyword informAsm contained set_font save_undo restore_undo draw_picture + syn keyword informAsm contained picture_data erase_picture set_margins + syn keyword informAsm contained move_window window_size window_style + syn keyword informAsm contained get_wind_prop scroll_window pop_stack + syn keyword informAsm contained read_mouse mouse_window push_stack + syn keyword informAsm contained put_wind_prop print_form make_menu + syn keyword informAsm contained picture_table + if !exists("inform_highlight_old") + syn keyword informAsm contained check_unicode print_unicode + endif + syn keyword informAsmObsolete contained print_paddr print_addr print_char +endif + +" Handling for different versions of VIM. + +setlocal iskeyword+=$ +command -nargs=+ SynDisplay syntax display + +" Grammar sections. + +syn region informGrammarSection matchgroup=informGramPreProc start="\" skip=+".*"+ end=";"he=e-1 contains=ALLBUT,informAsm + +" Special character forms. + +SynDisplay match informBadAccent contained "@[^{[:digit:]]\D" +SynDisplay match informBadAccent contained "@{[^}]*}" +SynDisplay match informAccent contained "@:[aouAOUeiyEI]" +SynDisplay match informAccent contained "@'[aeiouyAEIOUY]" +SynDisplay match informAccent contained "@`[aeiouAEIOU]" +SynDisplay match informAccent contained "@\^[aeiouAEIOU]" +SynDisplay match informAccent contained "@\~[anoANO]" +SynDisplay match informAccent contained "@/[oO]" +SynDisplay match informAccent contained "@ss\|@<<\|@>>\|@oa\|@oA\|@ae\|@AE\|@cc\|@cC" +SynDisplay match informAccent contained "@th\|@et\|@Th\|@Et\|@LL\|@oe\|@OE\|@!!\|@??" +SynDisplay match informAccent contained "@{\x\{1,4}}" +SynDisplay match informBadStrUnicode contained "@@\D" +SynDisplay match informStringUnicode contained "@@\d\+" +SynDisplay match informStringCode contained "@\d\d" + +" String and Character constants. Ordering is important here. +syn region informString start=+"+ skip=+\\\\+ end=+"+ contains=informAccent,informStringUnicode,informStringCode,informBadAccent,informBadStrUnicode +syn region informDictString start="'" end="'" contains=informAccent,informBadAccent +SynDisplay match informBadDictString "''" +SynDisplay match informDictString "'''" + +" Integer numbers: decimal, hexadecimal and binary. +SynDisplay match informNumber "\<\d\+\>" +SynDisplay match informNumber "\<\$\x\+\>" +SynDisplay match informNumber "\<\$\$[01]\+\>" + +" Comments +syn match informComment "!.*" contains=informTodo + +" Syncronization +syn sync match informSyncStringEnd grouphere NONE /"[;,]\s*$/ +syn sync match informSyncRoutineEnd grouphere NONE /][;,]\s*$/ +syn sync match informSyncCommentEnd grouphere NONE /^\s*!.*$/ +syn sync match informSyncRoutine groupthere informGrammarSection "\" +syn sync maxlines=500 + +delcommand SynDisplay + +" The default highlighting. + +hi def link informDefine Define +hi def link informType Type +hi def link informInclude Include +hi def link informPreCondit PreCondit +hi def link informPreProc PreProc +hi def link informGramPreProc PreProc +hi def link informAsm Special +if !exists("inform_suppress_obsolete") +hi def link informAsmObsolete informError +hi def link informKeywordObsolete informError +else +hi def link informAsmObsolete Special +hi def link informKeywordObsolete Keyword +endif +hi def link informPredicate Operator +hi def link informSysFunc Identifier +hi def link informSysConst Identifier +hi def link informConditional Conditional +hi def link informRepeat Repeat +hi def link informStatement Statement +hi def link informOperator Operator +hi def link informKeyword Keyword +hi def link informGrammar Keyword +hi def link informDictString String +hi def link informNumber Number +hi def link informError Error +hi def link informString String +hi def link informComment Comment +hi def link informAccent Special +hi def link informStringUnicode Special +hi def link informStringCode Special +hi def link informTodo Todo +if !exists("inform_highlight_simple") +hi def link informLibAttrib Identifier +hi def link informLibProp Identifier +hi def link informLibObj Identifier +hi def link informLibRoutine Identifier +hi def link informLibVariable Identifier +hi def link informLibConst Identifier +hi def link informLibAction Identifier +endif +hi def link informBadDictString informError +hi def link informBadAccent informError +hi def link informBadStrUnicode informError + + +let b:current_syntax = "inform" + +" vim: ts=8 + +endif diff --git a/syntax/initex.vim b/syntax/initex.vim new file mode 100644 index 0000000..2ff2fe9 --- /dev/null +++ b/syntax/initex.vim @@ -0,0 +1,380 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TeX (core definition) +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" This follows the grouping (sort of) found at +" http: //www.tug.org/utilities/plain/cseq.html#top-fam + +syn keyword initexTodo TODO FIXME XXX NOTE + +syn match initexComment display contains=initexTodo + \ '\\\@' + +syn cluster initexBox + \ contains=initexBoxCommand,initexBoxInternalQuantity, + \ initexBoxParameterDimen,initexBoxParameterInteger, + \ initexBoxParameterToken + +syn cluster initexCharacter + \ contains=initexCharacterCommand,initexCharacterInternalQuantity, + \ initexCharacterParameterInteger + +syn cluster initexDebugging + \ contains=initexDebuggingCommand,initexDebuggingParameterInteger, + \ initexDebuggingParameterToken + +syn cluster initexFileIO + \ contains=initexFileIOCommand,initexFileIOInternalQuantity, + \ initexFileIOParameterToken + +syn cluster initexFonts + \ contains=initexFontsCommand,initexFontsInternalQuantity + +syn cluster initexGlue + \ contains=initexGlueCommand,initexGlueDerivedCommand + +syn cluster initexHyphenation + \ contains=initexHyphenationCommand,initexHyphenationDerivedCommand, + \ initexHyphenationInternalQuantity,initexHyphenationParameterInteger + +syn cluster initexInserts + \ contains=initexInsertsCommand,initexInsertsParameterDimen, + \ initexInsertsParameterGlue,initexInsertsParameterInteger + +syn cluster initexJob + \ contains=initexJobCommand,initexJobInternalQuantity, + \ initexJobParameterInteger + +syn cluster initexKern + \ contains=initexKernCommand,initexKernInternalQuantity + +syn cluster initexLogic + \ contains=initexLogicCommand + +syn cluster initexMacro + \ contains=initexMacroCommand,initexMacroDerivedCommand, + \ initexMacroParameterInteger + +syn cluster initexMarks + \ contains=initexMarksCommand + +syn cluster initexMath + \ contains=initexMathCommand,initexMathDerivedCommand, + \ initexMathInternalQuantity,initexMathParameterDimen, + \ initexMathParameterGlue,initexMathParameterInteger, + \ initexMathParameterMuglue,initexMathParameterToken + +syn cluster initexPage + \ contains=initexPageInternalQuantity,initexPageParameterDimen, + \ initexPageParameterGlue + +syn cluster initexParagraph + \ contains=initexParagraphCommand,initexParagraphInternalQuantity, + \ initexParagraphParameterDimen,initexParagraphParameterGlue, + \ initexParagraphParameterInteger,initexParagraphParameterToken + +syn cluster initexPenalties + \ contains=initexPenaltiesCommand,initexPenaltiesInternalQuantity, + \ initexPenaltiesParameterInteger + +syn cluster initexRegisters + \ contains=initexRegistersCommand,initexRegistersInternalQuantity + +syn cluster initexTables + \ contains=initexTablesCommand,initexTablesParameterGlue, + \ initexTablesParameterToken + +syn cluster initexCommand + \ contains=initexBoxCommand,initexCharacterCommand, + \ initexDebuggingCommand,initexFileIOCommand, + \ initexFontsCommand,initexGlueCommand, + \ initexHyphenationCommand,initexInsertsCommand, + \ initexJobCommand,initexKernCommand,initexLogicCommand, + \ initexMacroCommand,initexMarksCommand,initexMathCommand, + \ initexParagraphCommand,initexPenaltiesCommand,initexRegistersCommand, + \ initexTablesCommand + +syn match initexBoxCommand display contains=@NoSpell + \ '\\\%([hv]\=box\|[cx]\=leaders\|copy\|[hv]rule\|lastbox\|setbox\|un[hv]\%(box\|copy\)\|vtop\)\>' +syn match initexCharacterCommand display contains=@NoSpell + \ '\\\%([] ]\|\%(^^M\|accent\|char\|\%(lower\|upper\)case\|number\|romannumeral\|string\)\>\)' +syn match initexDebuggingCommand display contains=@NoSpell + \ '\\\%(\%(batch\|\%(non\|error\)stop\|scroll\)mode\|\%(err\)\=message\|meaning\|show\%(box\%(breadth\|depth\)\=\|lists\|the\)\)\>' +syn match initexFileIOCommand display contains=@NoSpell + \ '\\\%(\%(close\|open\)\%(in\|out\)\|endinput\|immediate\|input\|read\|shipout\|special\|write\)\>' +syn match initexFontsCommand display contains=@NoSpell + \ '\\\%(/\|fontname\)\>' +syn match initexGlueCommand display contains=@NoSpell + \ '\\\%([hv]\|un\)skip\>' +syn match initexHyphenationCommand display contains=@NoSpell + \ '\\\%(discretionary\|hyphenation\|patterns\|setlanguage\)\>' +syn match initexInsertsCommand display contains=@NoSpell + \ '\\\%(insert\|split\%(bot\|first\)mark\|vsplit\)\>' +syn match initexJobCommand display contains=@NoSpell + \ '\\\%(dump\|end\|jobname\)\>' +syn match initexKernCommand display contains=@NoSpell + \ '\\\%(kern\|lower\|move\%(left\|right\)\|raise\|unkern\)\>' +syn match initexLogicCommand display contains=@NoSpell + \ '\\\%(else\|fi\|if[a-zA-Z@]\+\|or\)\>' +" \ '\\\%(else\|fi\|if\%(case\|cat\|dim\|eof\|false\|[hv]box\|[hmv]mode\|inner\|num\|odd\|true\|void\|x\)\=\|or\)\>' +syn match initexMacroCommand display contains=@NoSpell + \ '\\\%(after\%(assignment\|group\)\|\%(begin\|end\)group\|\%(end\)\=csname\|e\=def\|expandafter\|futurelet\|global\|let\|long\|noexpand\|outer\|relax\|the\)\>' +syn match initexMarksCommand display contains=@NoSpell + \ '\\\%(bot\|first\|top\)\=mark\>' +syn match initexMathCommand display contains=@NoSpell + \ '\\\%(abovewithdelims\|delimiter\|display\%(limits\|style\)\|l\=eqno\|left\|\%(no\)\=limits\|math\%(accent\|bin\|char\|choice\|close\|code\|inner\|op\|open\|ord\|punct\|rel\)\|mkern\|mskip\|muskipdef\|nonscript\|\%(over\|under\)line\|radical\|right\|\%(\%(script\)\{1,2}\|text\)style\|vcenter\)\>' +syn match initexParagraphCommand display contains=@NoSpell + \ '\\\%(ignorespaces\|indent\|no\%(boundary\|indent\)\|par\|vadjust\)\>' +syn match initexPenaltiesCommand display contains=@NoSpell + \ '\\\%(un\)\=penalty\>' +syn match initexRegistersCommand display contains=@NoSpell + \ '\\\%(advance\|\%(count\|dimen\|skip\|toks\)def\|divide\|multiply\)\>' +syn match initexTablesCommand display contains=@NoSpell + \ '\\\%(cr\|crcr\|[hv]align\|noalign\|omit\|span\)\>' + +syn cluster initexDerivedCommand + \ contains=initexGlueDerivedCommand,initexHyphenationDerivedCommand, + \ initexMacroDerivedCommand,initexMathDerivedCommand + +syn match initexGlueDerivedCommand display contains=@NoSpell + \ '\\\%([hv]fil\%(l\|neg\)\=\|[hv]ss\)\>' +syn match initexHyphenationDerivedCommand display contains=@NoSpell + \ '\\-' +syn match initexMacroDerivedCommand display contains=@NoSpell + \ '\\[gx]def\>' +syn match initexMathDerivedCommand display contains=@NoSpell + \ '\\\%(above\|atop\%(withdelims\)\=\|mathchardef\|over\|overwithdelims\)\>' + +syn cluster initexInternalQuantity + \ contains=initexBoxInternalQuantity,initexCharacterInternalQuantity, + \ initexFileIOInternalQuantity,initexFontsInternalQuantity, + \ initexHyphenationInternalQuantity,initexJobInternalQuantity, + \ initexKernInternalQuantity,initexMathInternalQuantity, + \ initexPageInternalQuantity,initexParagraphInternalQuantity, + \ initexPenaltiesInternalQuantity,initexRegistersInternalQuantity + +syn match initexBoxInternalQuantity display contains=@NoSpell + \ '\\\%(badness\|dp\|ht\|prevdepth\|wd\)\>' +syn match initexCharacterInternalQuantity display contains=@NoSpell + \ '\\\%(catcode\|chardef\|\%([ul]c\|sf\)code\)\>' +syn match initexFileIOInternalQuantity display contains=@NoSpell + \ '\\inputlineno\>' +syn match initexFontsInternalQuantity display contains=@NoSpell + \ '\\\%(font\%(dimen\)\=\|nullfont\)\>' +syn match initexHyphenationInternalQuantity display contains=@NoSpell + \ '\\hyphenchar\>' +syn match initexJobInternalQuantity display contains=@NoSpell + \ '\\deadcycles\>' +syn match initexKernInternalQuantity display contains=@NoSpell + \ '\\lastkern\>' +syn match initexMathInternalQuantity display contains=@NoSpell + \ '\\\%(delcode\|mathcode\|muskip\|\%(\%(script\)\{1,2}\|text\)font\|skewchar\)\>' +syn match initexPageInternalQuantity display contains=@NoSpell + \ '\\page\%(depth\|fil\{1,3}stretch\|goal\|shrink\|stretch\|total\)\>' +syn match initexParagraphInternalQuantity display contains=@NoSpell + \ '\\\%(prevgraf\|spacefactor\)\>' +syn match initexPenaltiesInternalQuantity display contains=@NoSpell + \ '\\lastpenalty\>' +syn match initexRegistersInternalQuantity display contains=@NoSpell + \ '\\\%(count\|dimen\|skip\|toks\)\d\+\>' + +syn cluster initexParameterDimen + \ contains=initexBoxParameterDimen,initexInsertsParameterDimen, + \ initexMathParameterDimen,initexPageParameterDimen, + \ initexParagraphParameterDimen + +syn match initexBoxParameterDimen display contains=@NoSpell + \ '\\\%(boxmaxdepth\|[hv]fuzz\|overfullrule\)\>' +syn match initexInsertsParameterDimen display contains=@NoSpell + \ '\\splitmaxdepth\>' +syn match initexMathParameterDimen display contains=@NoSpell + \ '\\\%(delimitershortfall\|display\%(indent\|width\)\|mathsurround\|nulldelimiterspace\|predisplaysize\|scriptspace\)\>' +syn match initexPageParameterDimen display contains=@NoSpell + \ '\\\%([hv]offset\|maxdepth\|vsize\)\>' +syn match initexParagraphParameterDimen display contains=@NoSpell + \ '\\\%(emergencystretch\|\%(hang\|par\)indent\|hsize\|lineskiplimit\)\>' + +syn cluster initexParameterGlue + \ contains=initexInsertsParameterGlue,initexMathParameterGlue, + \ initexPageParameterGlue,initexParagraphParameterGlue, + \ initexTablesParameterGlue + +syn match initexInsertsParameterGlue display contains=@NoSpell + \ '\\splittopskip\>' +syn match initexMathParameterGlue display contains=@NoSpell + \ '\\\%(above\|below\)display\%(short\)\=skip\>' +syn match initexPageParameterGlue display contains=@NoSpell + \ '\\topskip\>' +syn match initexParagraphParameterGlue display contains=@NoSpell + \ '\\\%(baseline\|left\|line\|par\%(fill\)\=\|right\|x\=space\)skip\>' +syn match initexTablesParameterGlue display contains=@NoSpell + \ '\\tabskip\>' + +syn cluster initexParameterInteger + \ contains=initexBoxParameterInteger,initexCharacterParameterInteger, + \ initexDebuggingParameterInteger,initexHyphenationParameterInteger, + \ initexInsertsParameterInteger,initexJobParameterInteger, + \ initexMacroParameterInteger,initexMathParameterInteger, + \ initexParagraphParameterInteger,initexPenaltiesParameterInteger, + +syn match initexBoxParameterInteger display contains=@NoSpell + \ '\\[hv]badness\>' +syn match initexCharacterParameterInteger display contains=@NoSpell + \ '\\\%(\%(endline\|escape\|newline\)char\)\>' +syn match initexDebuggingParameterInteger display contains=@NoSpell + \ '\\\%(errorcontextlines\|pausing\|tracing\%(commands\|lostchars\|macros\|online\|output\|pages\|paragraphs\|restores|stats\)\)\>' +syn match initexHyphenationParameterInteger display contains=@NoSpell + \ '\\\%(defaulthyphenchar\|language\|\%(left\|right\)hyphenmin\|uchyph\)\>' +syn match initexInsertsParameterInteger display contains=@NoSpell + \ '\\\%(holdinginserts\)\>' +syn match initexJobParameterInteger display contains=@NoSpell + \ '\\\%(day\|mag\|maxdeadcycles\|month\|time\|year\)\>' +syn match initexMacroParameterInteger display contains=@NoSpell + \ '\\globaldefs\>' +syn match initexMathParameterInteger display contains=@NoSpell + \ '\\\%(binoppenalty\|defaultskewchar\|delimiterfactor\|displaywidowpenalty\|fam\|\%(post\|pre\)displaypenalty\|relpenalty\)\>' +syn match initexParagraphParameterInteger display contains=@NoSpell + \ '\\\%(\%(adj\|\%(double\|final\)hyphen\)demerits\|looseness\|\%(pre\)\=tolerance\)\>' +syn match initexPenaltiesParameterInteger display contains=@NoSpell + \ '\\\%(broken\|club\|exhyphen\|floating\|hyphen\|interline\|line\|output\|widow\)penalty\>' + +syn cluster initexParameterMuglue + \ contains=initexMathParameterMuglue + +syn match initexMathParameterMuglue display contains=@NoSpell + \ '\\\%(med\|thick\|thin\)muskip\>' + +syn cluster initexParameterDimen + \ contains=initexBoxParameterToken,initexDebuggingParameterToken, + \ initexFileIOParameterToken,initexMathParameterToken, + \ initexParagraphParameterToken,initexTablesParameterToken + +syn match initexBoxParameterToken display contains=@NoSpell + \ '\\every[hv]box\>' +syn match initexDebuggingParameterToken display contains=@NoSpell + \ '\\errhelp\>' +syn match initexFileIOParameterToken display contains=@NoSpell + \ '\\output\>' +syn match initexMathParameterToken display contains=@NoSpell + \ '\\every\%(display\|math\)\>' +syn match initexParagraphParameterToken display contains=@NoSpell + \ '\\everypar\>' +syn match initexTablesParameterToken display contains=@NoSpell + \ '\\everycr\>' + + +hi def link initexCharacter Character +hi def link initexNumber Number + +hi def link initexIdentifier Identifier + +hi def link initexStatement Statement +hi def link initexConditional Conditional + +hi def link initexPreProc PreProc +hi def link initexMacro Macro + +hi def link initexType Type + +hi def link initexDebug Debug + +hi def link initexTodo Todo +hi def link initexComment Comment +hi def link initexDimension initexNumber + +hi def link initexCommand initexStatement +hi def link initexBoxCommand initexCommand +hi def link initexCharacterCommand initexCharacter +hi def link initexDebuggingCommand initexDebug +hi def link initexFileIOCommand initexCommand +hi def link initexFontsCommand initexType +hi def link initexGlueCommand initexCommand +hi def link initexHyphenationCommand initexCommand +hi def link initexInsertsCommand initexCommand +hi def link initexJobCommand initexPreProc +hi def link initexKernCommand initexCommand +hi def link initexLogicCommand initexConditional +hi def link initexMacroCommand initexMacro +hi def link initexMarksCommand initexCommand +hi def link initexMathCommand initexCommand +hi def link initexParagraphCommand initexCommand +hi def link initexPenaltiesCommand initexCommand +hi def link initexRegistersCommand initexCommand +hi def link initexTablesCommand initexCommand + +hi def link initexDerivedCommand initexStatement +hi def link initexGlueDerivedCommand initexDerivedCommand +hi def link initexHyphenationDerivedCommand initexDerivedCommand +hi def link initexMacroDerivedCommand initexDerivedCommand +hi def link initexMathDerivedCommand initexDerivedCommand + +hi def link initexInternalQuantity initexIdentifier +hi def link initexBoxInternalQuantity initexInternalQuantity +hi def link initexCharacterInternalQuantity initexInternalQuantity +hi def link initexFileIOInternalQuantity initexInternalQuantity +hi def link initexFontsInternalQuantity initexInternalQuantity +hi def link initexHyphenationInternalQuantity initexInternalQuantity +hi def link initexJobInternalQuantity initexInternalQuantity +hi def link initexKernInternalQuantity initexInternalQuantity +hi def link initexMathInternalQuantity initexInternalQuantity +hi def link initexPageInternalQuantity initexInternalQuantity +hi def link initexParagraphInternalQuantity initexInternalQuantity +hi def link initexPenaltiesInternalQuantity initexInternalQuantity +hi def link initexRegistersInternalQuantity initexInternalQuantity + +hi def link initexParameterDimen initexNumber +hi def link initexBoxParameterDimen initexParameterDimen +hi def link initexInsertsParameterDimen initexParameterDimen +hi def link initexMathParameterDimen initexParameterDimen +hi def link initexPageParameterDimen initexParameterDimen +hi def link initexParagraphParameterDimen initexParameterDimen + +hi def link initexParameterGlue initexNumber +hi def link initexInsertsParameterGlue initexParameterGlue +hi def link initexMathParameterGlue initexParameterGlue +hi def link initexPageParameterGlue initexParameterGlue +hi def link initexParagraphParameterGlue initexParameterGlue +hi def link initexTablesParameterGlue initexParameterGlue + +hi def link initexParameterInteger initexNumber +hi def link initexBoxParameterInteger initexParameterInteger +hi def link initexCharacterParameterInteger initexParameterInteger +hi def link initexDebuggingParameterInteger initexParameterInteger +hi def link initexHyphenationParameterInteger initexParameterInteger +hi def link initexInsertsParameterInteger initexParameterInteger +hi def link initexJobParameterInteger initexParameterInteger +hi def link initexMacroParameterInteger initexParameterInteger +hi def link initexMathParameterInteger initexParameterInteger +hi def link initexParagraphParameterInteger initexParameterInteger +hi def link initexPenaltiesParameterInteger initexParameterInteger + +hi def link initexParameterMuglue initexNumber +hi def link initexMathParameterMuglue initexParameterMuglue + +hi def link initexParameterToken initexIdentifier +hi def link initexBoxParameterToken initexParameterToken +hi def link initexDebuggingParameterToken initexParameterToken +hi def link initexFileIOParameterToken initexParameterToken +hi def link initexMathParameterToken initexParameterToken +hi def link initexParagraphParameterToken initexParameterToken +hi def link initexTablesParameterToken initexParameterToken + +let b:current_syntax = "initex" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/initng.vim b/syntax/initng.vim new file mode 100644 index 0000000..a241957 --- /dev/null +++ b/syntax/initng.vim @@ -0,0 +1,95 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: initng .i files +" Maintainer: Elan Ruusamäe +" URL: http://glen.alkohol.ee/pld/initng/ +" License: GPL v2 +" Version: 0.13 +" Last Change: $Date: 2007/05/05 17:17:40 $ +" +" Syntax highlighting for initng .i files. Inherits from sh.vim and adds +" in the hiliting to start/stop {} blocks. Requires vim 6.3 or later. + +if &compatible || v:version < 603 + finish +endif + +if exists("b:current_syntax") + finish +endif + +syn case match + +let is_bash = 1 +unlet! b:current_syntax +syn include @shTop syntax/sh.vim + +syn region initngService matchgroup=initngServiceHeader start="^\s*\(service\|virtual\|daemon\|class\|cron\)\s\+\(\(\w\|[-/*]\)\+\(\s\+:\s\+\(\w\|[-/*]\)\+\)\?\)\s\+{" end="}" contains=@initngServiceCluster +syn cluster initngServiceCluster contains=initngComment,initngAction,initngServiceOption,initngServiceHeader,initngDelim,initngVariable + +syn region initngAction matchgroup=initngActionHeader start="^\s*\(script start\|script stop\|script run\)\s*=\s*{" end="}" contains=@initngActionCluster +syn cluster initngActionCluster contains=@shTop + +syn match initngDelim /[{}]/ contained + +syn region initngString start=/"/ end=/"/ skip=/\\"/ + +" option = value +syn match initngServiceOption /.\+\s*=.\+;/ contains=initngServiceKeywords,initngSubstMacro contained +" option without value +syn match initngServiceOption /\w\+;/ contains=initngServiceKeywords,initngSubstMacro contained + +" options with value +syn keyword initngServiceKeywords also_stop need use nice setuid contained +syn keyword initngServiceKeywords delay chdir suid sgid start_pause env_file env_parse pid_file pidfile contained +syn keyword initngServiceKeywords pid_of up_when_pid_set stdout stderr syncron just_before contained +syn keyword initngServiceKeywords provide lockfile daemon_stops_badly contained +syn match initngServiceKeywords /\(script\|exec\(_args\)\?\) \(start\|stop\|daemon\)/ contained +syn match initngServiceKeywords /env\s\+\w\+/ contained + +" rlimits +syn keyword initngServiceKeywords rlimit_cpu_hard rlimit_core_soft contained + +" single options +syn keyword initngServiceKeywords last respawn network_provider require_network require_file critical forks contained +" cron options +syn keyword initngServiceKeywords hourly contained +syn match initngVariable /\${\?\w\+\}\?/ + +" Substituted @foo@ macros: +" ========== +syn match initngSubstMacro /@[^@]\+@/ contained +syn cluster initngActionCluster add=initngSubstMacro +syn cluster shCommandSubList add=initngSubstMacro + +" Comments: +" ========== +syn cluster initngCommentGroup contains=initngTodo,@Spell +syn keyword initngTodo TODO FIXME XXX contained +syn match initngComment /#.*$/ contains=@initngCommentGroup + +" install_service #macros +" TODO: syntax check for ifd-endd pairs +" ========== +syn region initngDefine start="^#\(endd\|elsed\|exec\|ifd\|endexec\|endd\)\>" skip="\\$" end="$" end="#"me=s-1 +syn cluster shCommentGroup add=initngDefine +syn cluster initngCommentGroup add=initngDefine + +hi def link initngComment Comment +hi def link initngTodo Todo + +hi def link initngString String +hi def link initngServiceKeywords Define + +hi def link initngServiceHeader Keyword +hi def link initngActionHeader Type +hi def link initngDelim Delimiter + +hi def link initngVariable PreProc +hi def link initngSubstMacro Comment +hi def link initngDefine Macro + +let b:current_syntax = "initng" + +endif diff --git a/syntax/inittab.vim b/syntax/inittab.vim new file mode 100644 index 0000000..c50100b --- /dev/null +++ b/syntax/inittab.vim @@ -0,0 +1,67 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" This is a GENERATED FILE. Please always refer to source file at the URI below. +" Language: SysV-compatible init process control file `inittab' +" Maintainer: David Ne\v{c}as (Yeti) +" Last Change: 2002-09-13 +" URL: http://physics.muni.cz/~yeti/download/syntax/inittab.vim + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +" Base constructs +syn match inittabError "[^:]\+:"me=e-1 contained +syn match inittabError "[^:]\+$" contained +syn match inittabComment "^[#:].*$" contains=inittabFixme +syn match inittabComment "#.*$" contained contains=inittabFixme +syn keyword inittabFixme FIXME TODO XXX NOT + +" Shell +syn region inittabShString start=+"+ end=+"+ skip=+\\\\\|\\\"+ contained +syn region inittabShString start=+'+ end=+'+ contained +syn match inittabShOption "\s[-+][[:alnum:]]\+"ms=s+1 contained +syn match inittabShOption "\s--[:alnum:][-[:alnum:]]*"ms=s+1 contained +syn match inittabShCommand "/\S\+" contained +syn cluster inittabSh add=inittabShOption,inittabShString,inittabShCommand + +" Keywords +syn keyword inittabActionName respawn wait once boot bootwait off ondemand sysinit powerwait powerfail powerokwait powerfailnow ctrlaltdel kbrequest initdefault contained + +" Line parser +syn match inittabId "^[[:alnum:]~]\{1,4}" nextgroup=inittabColonRunLevels,inittabError +syn match inittabColonRunLevels ":" contained nextgroup=inittabRunLevels,inittabColonAction,inittabError +syn match inittabRunLevels "[0-6A-Ca-cSs]\+" contained nextgroup=inittabColonAction,inittabError +syn match inittabColonAction ":" contained nextgroup=inittabAction,inittabError +syn match inittabAction "\w\+" contained nextgroup=inittabColonProcess,inittabError contains=inittabActionName +syn match inittabColonProcess ":" contained nextgroup=inittabProcessPlus,inittabProcess,inittabError +syn match inittabProcessPlus "+" contained nextgroup=inittabProcess,inittabError +syn region inittabProcess start="/" end="$" transparent oneline contained contains=@inittabSh,inittabComment + +" Define the default highlighting + +hi def link inittabComment Comment +hi def link inittabFixme Todo +hi def link inittabActionName Type +hi def link inittabError Error +hi def link inittabId Identifier +hi def link inittabRunLevels Special + +hi def link inittabColonProcess inittabColon +hi def link inittabColonAction inittabColon +hi def link inittabColonRunLevels inittabColon +hi def link inittabColon PreProc + +hi def link inittabShString String +hi def link inittabShOption Special +hi def link inittabShCommand Statement + + +let b:current_syntax = "inittab" + +endif diff --git a/syntax/ipfilter.vim b/syntax/ipfilter.vim new file mode 100644 index 0000000..dda907f --- /dev/null +++ b/syntax/ipfilter.vim @@ -0,0 +1,58 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" ipfilter syntax file +" Language: ipfilter configuration file +" Maintainer: Hendrik Scholz +" Last Change: 2005 Jan 27 +" +" http://www.wormulon.net/files/misc/ipfilter.vim +" +" This will also work for OpenBSD pf but there might be some tags that are +" not correctly identified. +" Please send comments to hendrik@scholz.net + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Comment +syn match IPFComment /#.*$/ contains=ipfTodo +syn keyword IPFTodo TODO XXX FIXME contained + +syn keyword IPFActionBlock block +syn keyword IPFActionPass pass +syn keyword IPFProto tcp udp icmp +syn keyword IPFSpecial quick log first +" how could we use keyword for words with '-' ? +syn match IPFSpecial /return-rst/ +syn match IPFSpecial /dup-to/ +"syn match IPFSpecial /icmp-type unreach/ +syn keyword IPFAny all any +syn match IPFIPv4 /\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}/ +syn match IPFNetmask /\/\d\+/ + +" service name constants +syn keyword IPFService auth bgp domain finger ftp http https ident +syn keyword IPFService imap irc isakmp kerberos mail nameserver nfs +syn keyword IPFService nntp ntp pop3 portmap pptp rpcbind rsync smtp +syn keyword IPFService snmp snmptrap socks ssh sunrpc syslog telnet +syn keyword IPFService tftp www + +" Comment +hi def link IPFComment Comment +hi def link IPFTodo Todo + +hi def link IPFService Constant + +hi def link IPFAction Type +hi def link ipfActionBlock String +hi def link ipfActionPass Type +hi def link IPFSpecial Statement +hi def link IPFIPv4 Label +hi def link IPFNetmask String +hi def link IPFAny Statement +hi def link IPFProto Identifier + + +endif diff --git a/syntax/ishd.vim b/syntax/ishd.vim new file mode 100644 index 0000000..1abc590 --- /dev/null +++ b/syntax/ishd.vim @@ -0,0 +1,413 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: InstallShield Script +" Maintainer: Robert M. Cortopassi +" Last Change: 2001 May 09 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword ishdStatement abort begin case default downto else end +syn keyword ishdStatement endif endfor endwhile endswitch endprogram exit elseif +syn keyword ishdStatement error for function goto if +syn keyword ishdStatement program prototype return repeat string step switch +syn keyword ishdStatement struct then to typedef until while + +syn keyword ishdType BOOL BYREF CHAR GDI HWND INT KERNEL LIST LONG +syn keyword ishdType NUMBER POINTER SHORT STRING USER + +syn keyword ishdConstant _MAX_LENGTH _MAX_STRING +syn keyword ishdConstant AFTER ALLCONTENTS ALLCONTROLS APPEND ASKDESTPATH +syn keyword ishdConstant ASKOPTIONS ASKPATH ASKTEXT BATCH_INSTALL BACK +syn keyword ishdConstant BACKBUTTON BACKGROUND BACKGROUNDCAPTION BADPATH +syn keyword ishdConstant BADTAGFILE BASEMEMORY BEFORE BILLBOARD BINARY +syn keyword ishdConstant BITMAP256COLORS BITMAPFADE BITMAPICON BK_BLUE BK_GREEN +syn keyword ishdConstant BK_MAGENTA BK_MAGENTA1 BK_ORANGE BK_PINK BK_RED +syn keyword ishdConstant BK_SMOOTH BK_SOLIDBLACK BK_SOLIDBLUE BK_SOLIDGREEN +syn keyword ishdConstant BK_SOLIDMAGENTA BK_SOLIDORANGE BK_SOLIDPINK BK_SOLIDRED +syn keyword ishdConstant BK_SOLIDWHITE BK_SOLIDYELLOW BK_YELLOW BLACK BLUE +syn keyword ishdConstant BOOTUPDRIVE BUTTON_CHECKED BUTTON_ENTER BUTTON_UNCHECKED +syn keyword ishdConstant BUTTON_UNKNOWN CMDLINE COMMONFILES CANCEL CANCELBUTTON +syn keyword ishdConstant CC_ERR_FILEFORMATERROR CC_ERR_FILEREADERROR +syn keyword ishdConstant CC_ERR_NOCOMPONENTLIST CC_ERR_OUTOFMEMORY CDROM +syn keyword ishdConstant CDROM_DRIVE CENTERED CHANGEDIR CHECKBOX CHECKBOX95 +syn keyword ishdConstant CHECKLINE CHECKMARK CMD_CLOSE CMD_MAXIMIZE CMD_MINIMIZE +syn keyword ishdConstant CMD_PUSHDOWN CMD_RESTORE COLORMODE256 COLORS +syn keyword ishdConstant COMBOBOX_ENTER COMBOBOX_SELECT COMMAND COMMANDEX +syn keyword ishdConstant COMMON COMP_DONE COMP_ERR_CREATEDIR +syn keyword ishdConstant COMP_ERR_DESTCONFLICT COMP_ERR_FILENOTINLIB +syn keyword ishdConstant COMP_ERR_FILESIZE COMP_ERR_FILETOOLARGE +syn keyword ishdConstant COMP_ERR_HEADER COMP_ERR_INCOMPATIBLE +syn keyword ishdConstant COMP_ERR_INTPUTNOTCOMPRESSED COMP_ERR_INVALIDLIST +syn keyword ishdConstant COMP_ERR_LAUNCHSERVER COMP_ERR_MEMORY +syn keyword ishdConstant COMP_ERR_NODISKSPACE COMP_ERR_OPENINPUT +syn keyword ishdConstant COMP_ERR_OPENOUTPUT COMP_ERR_OPTIONS +syn keyword ishdConstant COMP_ERR_OUTPUTNOTCOMPRESSED COMP_ERR_SPLIT +syn keyword ishdConstant COMP_ERR_TARGET COMP_ERR_TARGETREADONLY COMP_ERR_WRITE +syn keyword ishdConstant COMP_INFO_ATTRIBUTE COMP_INFO_COMPSIZE COMP_INFO_DATE +syn keyword ishdConstant COMP_INFO_INVALIDATEPASSWORD COMP_INFO_ORIGSIZE +syn keyword ishdConstant COMP_INFO_SETPASSWORD COMP_INFO_TIME +syn keyword ishdConstant COMP_INFO_VERSIONLS COMP_INFO_VERSIONMS COMP_NORMAL +syn keyword ishdConstant COMP_UPDATE_DATE COMP_UPDATE_DATE_NEWER +syn keyword ishdConstant COMP_UPDATE_SAME COMP_UPDATE_VERSION COMPACT +syn keyword ishdConstant COMPARE_DATE COMPARE_SIZE COMPARE_VERSION +syn keyword ishdConstant COMPONENT_FIELD_CDROM_FOLDER +syn keyword ishdConstant COMPONENT_FIELD_DESCRIPTION COMPONENT_FIELD_DESTINATION +syn keyword ishdConstant COMPONENT_FIELD_DISPLAYNAME COMPONENT_FIELD_FILENEED +syn keyword ishdConstant COMPONENT_FIELD_FTPLOCATION +syn keyword ishdConstant COMPONENT_FIELD_HTTPLOCATION COMPONENT_FIELD_MISC +syn keyword ishdConstant COMPONENT_FIELD_OVERWRITE COMPONENT_FIELD_PASSWORD +syn keyword ishdConstant COMPONENT_FIELD_SELECTED COMPONENT_FIELD_SIZE +syn keyword ishdConstant COMPONENT_FIELD_STATUS COMPONENT_FIELD_VISIBLE +syn keyword ishdConstant COMPONENT_FILEINFO_COMPRESSED +syn keyword ishdConstant COMPONENT_FILEINFO_COMPRESSENGINE +syn keyword ishdConstant COMPONENT_FILEINFO_LANGUAGECOMPONENT_FILEINFO_OS +syn keyword ishdConstant COMPONENT_FILEINFO_POTENTIALLYLOCKED +syn keyword ishdConstant COMPONENT_FILEINFO_SELFREGISTERING +syn keyword ishdConstant COMPONENT_FILEINFO_SHARED COMPONENT_INFO_ATTRIBUTE +syn keyword ishdConstant COMPONENT_INFO_COMPSIZE COMPONENT_INFO_DATE +syn keyword ishdConstant COMPONENT_INFO_DATE_EX_EX COMPONENT_INFO_LANGUAGE +syn keyword ishdConstant COMPONENT_INFO_ORIGSIZE COMPONENT_INFO_OS +syn keyword ishdConstant COMPONENT_INFO_TIME COMPONENT_INFO_VERSIONLS +syn keyword ishdConstant COMPONENT_INFO_VERSIONMS COMPONENT_INFO_VERSIONSTR +syn keyword ishdConstant COMPONENT_VALUE_ALWAYSOVERWRITE +syn keyword ishdConstant COMPONENT_VALUE_CRITICAL +syn keyword ishdConstant COMPONENT_VALUE_HIGHLYRECOMMENDED +syn keyword ishdConstant COMPONENT_FILEINFO_LANGUAGE COMPONENT_FILEINFO_OS +syn keyword ishdConstant COMPONENT_VALUE_NEVEROVERWRITE +syn keyword ishdConstant COMPONENT_VALUE_NEWERDATE COMPONENT_VALUE_NEWERVERSION +syn keyword ishdConstant COMPONENT_VALUE_OLDERDATE COMPONENT_VALUE_OLDERVERSION +syn keyword ishdConstant COMPONENT_VALUE_SAMEORNEWDATE +syn keyword ishdConstant COMPONENT_VALUE_SAMEORNEWERVERSION +syn keyword ishdConstant COMPONENT_VALUE_STANDARD COMPONENT_VIEW_CHANGE +syn keyword ishdConstant COMPONENT_INFO_DATE_EX COMPONENT_VIEW_CHILDVIEW +syn keyword ishdConstant COMPONENT_VIEW_COMPONENT COMPONENT_VIEW_DESCRIPTION +syn keyword ishdConstant COMPONENT_VIEW_MEDIA COMPONENT_VIEW_PARENTVIEW +syn keyword ishdConstant COMPONENT_VIEW_SIZEAVAIL COMPONENT_VIEW_SIZETOTAL +syn keyword ishdConstant COMPONENT_VIEW_TARGETLOCATION COMPRESSHIGH COMPRESSLOW +syn keyword ishdConstant COMPRESSMED COMPRESSNONE CONTIGUOUS CONTINUE +syn keyword ishdConstant COPY_ERR_CREATEDIR COPY_ERR_NODISKSPACE +syn keyword ishdConstant COPY_ERR_OPENINPUT COPY_ERR_OPENOUTPUT +syn keyword ishdConstant COPY_ERR_TARGETREADONLY COPY_ERR_MEMORY +syn keyword ishdConstant CORECOMPONENTHANDLING CPU CUSTOM DATA_COMPONENT +syn keyword ishdConstant DATA_LIST DATA_NUMBER DATA_STRING DATE DEFAULT +syn keyword ishdConstant DEFWINDOWMODE DELETE_EOF DIALOG DIALOGCACHE +syn keyword ishdConstant DIALOGTHINFONT DIR_WRITEABLE DIRECTORY DISABLE DISK +syn keyword ishdConstant DISK_FREESPACE DISK_TOTALSPACE DISKID DLG_ASK_OPTIONS +syn keyword ishdConstant DLG_ASK_PATH DLG_ASK_TEXT DLG_ASK_YESNO DLG_CANCEL +syn keyword ishdConstant DLG_CDIR DLG_CDIR_MSG DLG_CENTERED DLG_CLOSE +syn keyword ishdConstant DLG_DIR_DIRECTORY DLG_DIR_FILE DLG_ENTER_DISK DLG_ERR +syn keyword ishdConstant DLG_ERR_ALREADY_EXISTS DLG_ERR_ENDDLG DLG_INFO_ALTIMAGE +syn keyword ishdConstant DLG_INFO_CHECKMETHOD DLG_INFO_CHECKSELECTION +syn keyword ishdConstant DLG_INFO_ENABLEIMAGE DLG_INFO_KUNITS +syn keyword ishdConstant DLG_INFO_USEDECIMAL DLG_INIT DLG_MSG_ALL +syn keyword ishdConstant DLG_MSG_INFORMATION DLG_MSG_NOT_HAND DLG_MSG_SEVERE +syn keyword ishdConstant DLG_MSG_STANDARD DLG_MSG_WARNING DLG_OK DLG_STATUS +syn keyword ishdConstant DLG_USER_CAPTION DRIVE DRIVEOPEN DLG_DIR_DRIVE +syn keyword ishdConstant EDITBOX_CHANGE EFF_BOXSTRIPE EFF_FADE EFF_HORZREVEAL +syn keyword ishdConstant EFF_HORZSTRIPE EFF_NONE EFF_REVEAL EFF_VERTSTRIPE +syn keyword ishdConstant ENABLE END_OF_FILE END_OF_LIST ENHANCED ENTERDISK +syn keyword ishdConstant ENTERDISK_ERRMSG ENTERDISKBEEP ENVSPACE EQUALS +syn keyword ishdConstant ERR_BADPATH ERR_BADTAGFILE ERR_BOX_BADPATH +syn keyword ishdConstant ERR_BOX_BADTAGFILE ERR_BOX_DISKID ERR_BOX_DRIVEOPEN +syn keyword ishdConstant ERR_BOX_EXIT ERR_BOX_HELP ERR_BOX_NOSPACE ERR_BOX_PAUSE +syn keyword ishdConstant ERR_BOX_READONLY ERR_DISKID ERR_DRIVEOPEN +syn keyword ishdConstant EXCLUDE_SUBDIR EXCLUSIVE EXISTS EXIT EXTENDEDMEMORY +syn keyword ishdConstant EXTENSION_ONLY ERRORFILENAME FADE_IN FADE_OUT +syn keyword ishdConstant FAILIFEXISTS FALSE FDRIVE_NUM FEEDBACK FEEDBACK_FULL +syn keyword ishdConstant FEEDBACK_OPERATION FEEDBACK_SPACE FILE_ATTR_ARCHIVED +syn keyword ishdConstant FILE_ATTR_DIRECTORY FILE_ATTR_HIDDEN FILE_ATTR_NORMAL +syn keyword ishdConstant FILE_ATTR_READONLY FILE_ATTR_SYSTEM FILE_ATTRIBUTE +syn keyword ishdConstant FILE_BIN_CUR FILE_BIN_END FILE_BIN_START FILE_DATE +syn keyword ishdConstant FILE_EXISTS FILE_INSTALLED FILE_INVALID FILE_IS_LOCKED +syn keyword ishdConstant FILE_LINE_LENGTH FILE_LOCKED FILE_MODE_APPEND +syn keyword ishdConstant FILE_MODE_BINARY FILE_MODE_BINARYREADONLY +syn keyword ishdConstant FILE_MODE_NORMAL FILE_NO_VERSION FILE_NOT_FOUND +syn keyword ishdConstant FILE_RD_ONLY FILE_SIZE FILE_SRC_EQUAL FILE_SRC_OLD +syn keyword ishdConstant FILE_TIME FILE_WRITEABLE FILENAME FILENAME_ONLY +syn keyword ishdConstant FINISHBUTTON FIXED_DRIVE FONT_TITLE FREEENVSPACE +syn keyword ishdConstant FS_CREATEDIR FS_DISKONEREQUIRED FS_DONE FS_FILENOTINLIB +syn keyword ishdConstant FS_GENERROR FS_INCORRECTDISK FS_LAUNCHPROCESS +syn keyword ishdConstant FS_OPERROR FS_OUTOFSPACE FS_PACKAGING FS_RESETREQUIRED +syn keyword ishdConstant FS_TARGETREADONLY FS_TONEXTDISK FULL FULLSCREEN +syn keyword ishdConstant FULLSCREENSIZE FULLWINDOWMODE FOLDER_DESKTOP +syn keyword ishdConstant FOLDER_PROGRAMS FOLDER_STARTMENU FOLDER_STARTUP +syn keyword ishdConstant GREATER_THAN GREEN HELP HKEY_CLASSES_ROOT +syn keyword ishdConstant HKEY_CURRENT_CONFIG HKEY_CURRENT_USER HKEY_DYN_DATA +syn keyword ishdConstant HKEY_LOCAL_MACHINE HKEY_PERFORMANCE_DATA HKEY_USERS +syn keyword ishdConstant HOURGLASS HWND_DESKTOP HWND_INSTALL IGNORE_READONLY +syn keyword ishdConstant INCLUDE_SUBDIR INDVFILESTATUS INFO INFO_DESCRIPTION +syn keyword ishdConstant INFO_IMAGE INFO_MISC INFO_SIZE INFO_SUBCOMPONENT +syn keyword ishdConstant INFO_VISIBLE INFORMATION INVALID_LIST IS_186 IS_286 +syn keyword ishdConstant IS_386 IS_486 IS_8514A IS_86 IS_ALPHA IS_CDROM IS_CGA +syn keyword ishdConstant IS_DOS IS_EGA IS_FIXED IS_FOLDER IS_ITEM ISLANG_ALL +syn keyword ishdConstant ISLANG_ARABIC ISLANG_ARABIC_SAUDIARABIA +syn keyword ishdConstant ISLANG_ARABIC_IRAQ ISLANG_ARABIC_EGYPT +syn keyword ishdConstant ISLANG_ARABIC_LIBYA ISLANG_ARABIC_ALGERIA +syn keyword ishdConstant ISLANG_ARABIC_MOROCCO ISLANG_ARABIC_TUNISIA +syn keyword ishdConstant ISLANG_ARABIC_OMAN ISLANG_ARABIC_YEMEN +syn keyword ishdConstant ISLANG_ARABIC_SYRIA ISLANG_ARABIC_JORDAN +syn keyword ishdConstant ISLANG_ARABIC_LEBANON ISLANG_ARABIC_KUWAIT +syn keyword ishdConstant ISLANG_ARABIC_UAE ISLANG_ARABIC_BAHRAIN +syn keyword ishdConstant ISLANG_ARABIC_QATAR ISLANG_AFRIKAANS +syn keyword ishdConstant ISLANG_AFRIKAANS_STANDARD ISLANG_ALBANIAN +syn keyword ishdConstant ISLANG_ENGLISH_TRINIDAD ISLANG_ALBANIAN_STANDARD +syn keyword ishdConstant ISLANG_BASQUE ISLANG_BASQUE_STANDARD ISLANG_BULGARIAN +syn keyword ishdConstant ISLANG_BULGARIAN_STANDARD ISLANG_BELARUSIAN +syn keyword ishdConstant ISLANG_BELARUSIAN_STANDARD ISLANG_CATALAN +syn keyword ishdConstant ISLANG_CATALAN_STANDARD ISLANG_CHINESE +syn keyword ishdConstant ISLANG_CHINESE_TAIWAN ISLANG_CHINESE_PRC +syn keyword ishdConstant ISLANG_SPANISH_PUERTORICO ISLANG_CHINESE_HONGKONG +syn keyword ishdConstant ISLANG_CHINESE_SINGAPORE ISLANG_CROATIAN +syn keyword ishdConstant ISLANG_CROATIAN_STANDARD ISLANG_CZECH +syn keyword ishdConstant ISLANG_CZECH_STANDARD ISLANG_DANISH +syn keyword ishdConstant ISLANG_DANISH_STANDARD ISLANG_DUTCH +syn keyword ishdConstant ISLANG_DUTCH_STANDARD ISLANG_DUTCH_BELGIAN +syn keyword ishdConstant ISLANG_ENGLISH ISLANG_ENGLISH_BELIZE +syn keyword ishdConstant ISLANG_ENGLISH_UNITEDSTATES +syn keyword ishdConstant ISLANG_ENGLISH_UNITEDKINGDOM ISLANG_ENGLISH_AUSTRALIAN +syn keyword ishdConstant ISLANG_ENGLISH_CANADIAN ISLANG_ENGLISH_NEWZEALAND +syn keyword ishdConstant ISLANG_ENGLISH_IRELAND ISLANG_ENGLISH_SOUTHAFRICA +syn keyword ishdConstant ISLANG_ENGLISH_JAMAICA ISLANG_ENGLISH_CARIBBEAN +syn keyword ishdConstant ISLANG_ESTONIAN ISLANG_ESTONIAN_STANDARD +syn keyword ishdConstant ISLANG_FAEROESE ISLANG_FAEROESE_STANDARD ISLANG_FARSI +syn keyword ishdConstant ISLANG_FINNISH ISLANG_FINNISH_STANDARD ISLANG_FRENCH +syn keyword ishdConstant ISLANG_FRENCH_STANDARD ISLANG_FRENCH_BELGIAN +syn keyword ishdConstant ISLANG_FRENCH_CANADIAN ISLANG_FRENCH_SWISS +syn keyword ishdConstant ISLANG_FRENCH_LUXEMBOURG ISLANG_FARSI_STANDARD +syn keyword ishdConstant ISLANG_GERMAN ISLANG_GERMAN_STANDARD +syn keyword ishdConstant ISLANG_GERMAN_SWISS ISLANG_GERMAN_AUSTRIAN +syn keyword ishdConstant ISLANG_GERMAN_LUXEMBOURG ISLANG_GERMAN_LIECHTENSTEIN +syn keyword ishdConstant ISLANG_GREEK ISLANG_GREEK_STANDARD ISLANG_HEBREW +syn keyword ishdConstant ISLANG_HEBREW_STANDARD ISLANG_HUNGARIAN +syn keyword ishdConstant ISLANG_HUNGARIAN_STANDARD ISLANG_ICELANDIC +syn keyword ishdConstant ISLANG_ICELANDIC_STANDARD ISLANG_INDONESIAN +syn keyword ishdConstant ISLANG_INDONESIAN_STANDARD ISLANG_ITALIAN +syn keyword ishdConstant ISLANG_ITALIAN_STANDARD ISLANG_ITALIAN_SWISS +syn keyword ishdConstant ISLANG_JAPANESE ISLANG_JAPANESE_STANDARD ISLANG_KOREAN +syn keyword ishdConstant ISLANG_KOREAN_STANDARD ISLANG_KOREAN_JOHAB +syn keyword ishdConstant ISLANG_LATVIAN ISLANG_LATVIAN_STANDARD +syn keyword ishdConstant ISLANG_LITHUANIAN ISLANG_LITHUANIAN_STANDARD +syn keyword ishdConstant ISLANG_NORWEGIAN ISLANG_NORWEGIAN_BOKMAL +syn keyword ishdConstant ISLANG_NORWEGIAN_NYNORSK ISLANG_POLISH +syn keyword ishdConstant ISLANG_POLISH_STANDARD ISLANG_PORTUGUESE +syn keyword ishdConstant ISLANG_PORTUGUESE_BRAZILIAN ISLANG_PORTUGUESE_STANDARD +syn keyword ishdConstant ISLANG_ROMANIAN ISLANG_ROMANIAN_STANDARD ISLANG_RUSSIAN +syn keyword ishdConstant ISLANG_RUSSIAN_STANDARD ISLANG_SLOVAK +syn keyword ishdConstant ISLANG_SLOVAK_STANDARD ISLANG_SLOVENIAN +syn keyword ishdConstant ISLANG_SLOVENIAN_STANDARD ISLANG_SERBIAN +syn keyword ishdConstant ISLANG_SERBIAN_LATIN ISLANG_SERBIAN_CYRILLIC +syn keyword ishdConstant ISLANG_SPANISH ISLANG_SPANISH_ARGENTINA +syn keyword ishdConstant ISLANG_SPANISH_BOLIVIA ISLANG_SPANISH_CHILE +syn keyword ishdConstant ISLANG_SPANISH_COLOMBIA ISLANG_SPANISH_COSTARICA +syn keyword ishdConstant ISLANG_SPANISH_DOMINICANREPUBLIC ISLANG_SPANISH_ECUADOR +syn keyword ishdConstant ISLANG_SPANISH_ELSALVADOR ISLANG_SPANISH_GUATEMALA +syn keyword ishdConstant ISLANG_SPANISH_HONDURAS ISLANG_SPANISH_MEXICAN +syn keyword ishdConstant ISLANG_THAI_STANDARD ISLANG_SPANISH_MODERNSORT +syn keyword ishdConstant ISLANG_SPANISH_NICARAGUA ISLANG_SPANISH_PANAMA +syn keyword ishdConstant ISLANG_SPANISH_PARAGUAY ISLANG_SPANISH_PERU +syn keyword ishdConstant IISLANG_SPANISH_PUERTORICO +syn keyword ishdConstant ISLANG_SPANISH_TRADITIONALSORT ISLANG_SPANISH_VENEZUELA +syn keyword ishdConstant ISLANG_SPANISH_URUGUAY ISLANG_SWEDISH +syn keyword ishdConstant ISLANG_SWEDISH_FINLAND ISLANG_SWEDISH_STANDARD +syn keyword ishdConstant ISLANG_THAI ISLANG_THA_STANDARDI ISLANG_TURKISH +syn keyword ishdConstant ISLANG_TURKISH_STANDARD ISLANG_UKRAINIAN +syn keyword ishdConstant ISLANG_UKRAINIAN_STANDARD ISLANG_VIETNAMESE +syn keyword ishdConstant ISLANG_VIETNAMESE_STANDARD IS_MIPS IS_MONO IS_OS2 +syn keyword ishdConstant ISOSL_ALL ISOSL_WIN31 ISOSL_WIN95 ISOSL_NT351 +syn keyword ishdConstant ISOSL_NT351_ALPHA ISOSL_NT351_MIPS ISOSL_NT351_PPC +syn keyword ishdConstant ISOSL_NT40 ISOSL_NT40_ALPHA ISOSL_NT40_MIPS +syn keyword ishdConstant ISOSL_NT40_PPC IS_PENTIUM IS_POWERPC IS_RAMDRIVE +syn keyword ishdConstant IS_REMOTE IS_REMOVABLE IS_SVGA IS_UNKNOWN IS_UVGA +syn keyword ishdConstant IS_VALID_PATH IS_VGA IS_WIN32S IS_WINDOWS IS_WINDOWS95 +syn keyword ishdConstant IS_WINDOWSNT IS_WINOS2 IS_XVGA ISTYPE INFOFILENAME +syn keyword ishdConstant ISRES ISUSER ISVERSION LANGUAGE LANGUAGE_DRV LESS_THAN +syn keyword ishdConstant LINE_NUMBER LISTBOX_ENTER LISTBOX_SELECT LISTFIRST +syn keyword ishdConstant LISTLAST LISTNEXT LISTPREV LOCKEDFILE LOGGING +syn keyword ishdConstant LOWER_LEFT LOWER_RIGHT LIST_NULL MAGENTA MAINCAPTION +syn keyword ishdConstant MATH_COPROCESSOR MAX_STRING MENU METAFILE MMEDIA_AVI +syn keyword ishdConstant MMEDIA_MIDI MMEDIA_PLAYASYNCH MMEDIA_PLAYCONTINUOUS +syn keyword ishdConstant MMEDIA_PLAYSYNCH MMEDIA_STOP MMEDIA_WAVE MOUSE +syn keyword ishdConstant MOUSE_DRV MEDIA MODE NETWORK NETWORK_DRV NEXT +syn keyword ishdConstant NEXTBUTTON NO NO_SUBDIR NO_WRITE_ACCESS NONCONTIGUOUS +syn keyword ishdConstant NONEXCLUSIVE NORMAL NORMALMODE NOSET NOTEXISTS NOTRESET +syn keyword ishdConstant NOWAIT NULL NUMBERLIST OFF OK ON ONLYDIR OS OSMAJOR +syn keyword ishdConstant OSMINOR OTHER_FAILURE OUT_OF_DISK_SPACE PARALLEL +syn keyword ishdConstant PARTIAL PATH PATH_EXISTS PAUSE PERSONAL PROFSTRING +syn keyword ishdConstant PROGMAN PROGRAMFILES RAM_DRIVE REAL RECORDMODE RED +syn keyword ishdConstant REGDB_APPPATH REGDB_APPPATH_DEFAULT REGDB_BINARY +syn keyword ishdConstant REGDB_ERR_CONNECTIONEXISTS REGDB_ERR_CORRUPTEDREGISTRY +syn keyword ishdConstant REGDB_ERR_FILECLOSE REGDB_ERR_FILENOTFOUND +syn keyword ishdConstant REGDB_ERR_FILEOPEN REGDB_ERR_FILEREAD +syn keyword ishdConstant REGDB_ERR_INITIALIZATION REGDB_ERR_INVALIDFORMAT +syn keyword ishdConstant REGDB_ERR_INVALIDHANDLE REGDB_ERR_INVALIDNAME +syn keyword ishdConstant REGDB_ERR_INVALIDPLATFORM REGDB_ERR_OUTOFMEMORY +syn keyword ishdConstant REGDB_ERR_REGISTRY REGDB_KEYS REGDB_NAMES REGDB_NUMBER +syn keyword ishdConstant REGDB_STRING REGDB_STRING_EXPAND REGDB_STRING_MULTI +syn keyword ishdConstant REGDB_UNINSTALL_NAME REGKEY_CLASSES_ROOT +syn keyword ishdConstant REGKEY_CURRENT_USER REGKEY_LOCAL_MACHINE REGKEY_USERS +syn keyword ishdConstant REMOTE_DRIVE REMOVE REMOVEABLE_DRIVE REPLACE +syn keyword ishdConstant REPLACE_ITEM RESET RESTART ROOT ROTATE RUN_MAXIMIZED +syn keyword ishdConstant RUN_MINIMIZED RUN_SEPARATEMEMORY SELECTFOLDER +syn keyword ishdConstant SELFREGISTER SELFREGISTERBATCH SELFREGISTRATIONPROCESS +syn keyword ishdConstant SERIAL SET SETUPTYPE SETUPTYPE_INFO_DESCRIPTION +syn keyword ishdConstant SETUPTYPE_INFO_DISPLAYNAME SEVERE SHARE SHAREDFILE +syn keyword ishdConstant SHELL_OBJECT_FOLDER SILENTMODE SPLITCOMPRESS SPLITCOPY +syn keyword ishdConstant SRCTARGETDIR STANDARD STATUS STATUS95 STATUSBAR +syn keyword ishdConstant STATUSDLG STATUSEX STATUSOLD STRINGLIST STYLE_BOLD +syn keyword ishdConstant STYLE_ITALIC STYLE_NORMAL STYLE_SHADOW STYLE_UNDERLINE +syn keyword ishdConstant SW_HIDE SW_MAXIMIZE SW_MINIMIZE SW_NORMAL SW_RESTORE +syn keyword ishdConstant SW_SHOW SW_SHOWMAXIMIZED SW_SHOWMINIMIZED +syn keyword ishdConstant SW_SHOWMINNOACTIVE SW_SHOWNA SW_SHOWNOACTIVATE +syn keyword ishdConstant SW_SHOWNORMAL SYS_BOOTMACHINE SYS_BOOTWIN +syn keyword ishdConstant SYS_BOOTWIN_INSTALL SYS_RESTART SYS_SHUTDOWN SYS_TODOS +syn keyword ishdConstant SELECTED_LANGUAGE SHELL_OBJECT_LANGUAGE SRCDIR SRCDISK +syn keyword ishdConstant SUPPORTDIR TEXT TILED TIME TRUE TYPICAL TARGETDIR +syn keyword ishdConstant TARGETDISK UPPER_LEFT UPPER_RIGHT USER_ADMINISTRATOR +syn keyword ishdConstant UNINST VALID_PATH VARIABLE_LEFT VARIABLE_UNDEFINED +syn keyword ishdConstant VER_DLL_NOT_FOUND VER_UPDATE_ALWAYS VER_UPDATE_COND +syn keyword ishdConstant VERSION VIDEO VOLUMELABEL WAIT WARNING WELCOME WHITE +syn keyword ishdConstant WIN32SINSTALLED WIN32SMAJOR WIN32SMINOR WINDOWS_SHARED +syn keyword ishdConstant WINMAJOR WINMINOR WINDIR WINDISK WINSYSDIR WINSYSDISK +syn keyword ishdConstant XCOPY_DATETIME YELLOW YES + +syn keyword ishdFunction AskDestPath AskOptions AskPath AskText AskYesNo +syn keyword ishdFunction AppCommand AddProfString AddFolderIcon BatchAdd +syn keyword ishdFunction BatchDeleteEx BatchFileLoad BatchFileSave BatchFind +syn keyword ishdFunction BatchGetFileName BatchMoveEx BatchSetFileName +syn keyword ishdFunction ComponentDialog ComponentAddItem +syn keyword ishdFunction ComponentCompareSizeRequired ComponentDialog +syn keyword ishdFunction ComponentError ComponentFileEnum ComponentFileInfo +syn keyword ishdFunction ComponentFilterLanguage ComponentFilterOS +syn keyword ishdFunction ComponentGetData ComponentGetItemSize +syn keyword ishdFunction ComponentInitialize ComponentIsItemSelected +syn keyword ishdFunction ComponentListItems ComponentMoveData +syn keyword ishdFunction ComponentSelectItem ComponentSetData ComponentSetTarget +syn keyword ishdFunction ComponentSetupTypeEnum ComponentSetupTypeGetData +syn keyword ishdFunction ComponentSetupTypeSet ComponentTotalSize +syn keyword ishdFunction ComponentValidate ConfigAdd ConfigDelete ConfigFileLoad +syn keyword ishdFunction ConfigFileSave ConfigFind ConfigGetFileName +syn keyword ishdFunction ConfigGetInt ConfigMove ConfigSetFileName ConfigSetInt +syn keyword ishdFunction CmdGetHwndDlg CtrlClear CtrlDir CtrlGetCurSel +syn keyword ishdFunction CtrlGetMLEText CtrlGetMultCurSel CtrlGetState +syn keyword ishdFunction CtrlGetSubCommand CtrlGetText CtrlPGroups +syn keyword ishdFunction CtrlSelectText CtrlSetCurSel CtrlSetFont CtrlSetList +syn keyword ishdFunction CtrlSetMLEText CtrlSetMultCurSel CtrlSetState +syn keyword ishdFunction CtrlSetText CallDLLFx ChangeDirectory CloseFile +syn keyword ishdFunction CopyFile CreateDir CreateFile CreateRegistrySet +syn keyword ishdFunction CommitSharedFiles CreateProgramFolder +syn keyword ishdFunction CreateShellObjects CopyBytes DefineDialog Delay +syn keyword ishdFunction DeleteDir DeleteFile Do DoInstall DeinstallSetReference +syn keyword ishdFunction DeinstallStart DialogSetInfo DeleteFolderIcon +syn keyword ishdFunction DeleteProgramFolder Disable EzBatchAddPath +syn keyword ishdFunction EzBatchAddString ExBatchReplace EnterDisk +syn keyword ishdFunction EzConfigAddDriver EzConfigAddString EzConfigGetValue +syn keyword ishdFunction EzConfigSetValue EndDialog EzDefineDialog ExistsDir +syn keyword ishdFunction ExistsDisk ExitProgMan Enable EzBatchReplace +syn keyword ishdFunction FileCompare FileDeleteLine FileGrep FileInsertLine +syn keyword ishdFunction FindAllDirs FindAllFiles FindFile FindWindow +syn keyword ishdFunction GetFileInfo GetLine GetFont GetDiskSpace GetEnvVar +syn keyword ishdFunction GetExtents GetMemFree GetMode GetSystemInfo +syn keyword ishdFunction GetValidDrivesList GetWindowHandle GetProfInt +syn keyword ishdFunction GetProfString GetFolderNameList GetGroupNameList +syn keyword ishdFunction GetItemNameList GetDir GetDisk HIWORD Handler Is +syn keyword ishdFunction ISCompareServicePack InstallationInfo LOWORD LaunchApp +syn keyword ishdFunction LaunchAppAndWait ListAddItem ListAddString ListCount +syn keyword ishdFunction ListCreate ListCurrentItem ListCurrentString +syn keyword ishdFunction ListDeleteItem ListDeleteString ListDestroy +syn keyword ishdFunction ListFindItem ListFindString ListGetFirstItem +syn keyword ishdFunction ListGetFirstString ListGetNextItem ListGetNextString +syn keyword ishdFunction ListReadFromFile ListSetCurrentItem +syn keyword ishdFunction ListSetCurrentString ListSetIndex ListWriteToFile +syn keyword ishdFunction LongPathFromShortPath LongPathToQuote +syn keyword ishdFunction LongPathToShortPath MessageBox MessageBeep NumToStr +syn keyword ishdFunction OpenFile OpenFileMode PathAdd PathDelete PathFind +syn keyword ishdFunction PathGet PathMove PathSet ProgDefGroupType ParsePath +syn keyword ishdFunction PlaceBitmap PlaceWindow PlayMMedia QueryProgGroup +syn keyword ishdFunction QueryProgItem QueryShellMgr RebootDialog ReleaseDialog +syn keyword ishdFunction ReadBytes RenameFile ReplaceProfString ReloadProgGroup +syn keyword ishdFunction ReplaceFolderIcon RGB RegDBConnectRegistry +syn keyword ishdFunction RegDBCreateKeyEx RegDBDeleteKey RegDBDeleteValue +syn keyword ishdFunction RegDBDisConnectRegistry RegDBGetAppInfo RegDBGetItem +syn keyword ishdFunction RegDBGetKeyValueEx RegDBKeyExist RegDBQueryKey +syn keyword ishdFunction RegDBSetAppInfo RegDBSetDefaultRoot RegDBSetItem +syn keyword ishdFunction RegDBSetKeyValueEx SeekBytes SelectDir SetFileInfo +syn keyword ishdFunction SelectDir SelectFolder SetupType SprintfBox SdSetupType +syn keyword ishdFunction SdSetupTypeEx SdMakeName SilentReadData SilentWriteData +syn keyword ishdFunction SendMessage Sprintf System SdAskDestPath SdAskOptions +syn keyword ishdFunction SdAskOptionsList SdBitmap SdComponentDialog +syn keyword ishdFunction SdComponentDialog2 SdComponentDialogAdv SdComponentMult +syn keyword ishdFunction SdConfirmNewDir SdConfirmRegistration SdDisplayTopics +syn keyword ishdFunction SdFinish SdFinishReboot SdInit SdLicense SdMakeName +syn keyword ishdFunction SdOptionsButtons SdProductName SdRegisterUser +syn keyword ishdFunction SdRegisterUserEx SdSelectFolder SdSetupType +syn keyword ishdFunction SdSetupTypeEx SdShowAnyDialog SdShowDlgEdit1 +syn keyword ishdFunction SdShowDlgEdit2 SdShowDlgEdit3 SdShowFileMods +syn keyword ishdFunction SdShowInfoList SdShowMsg SdStartCopy SdWelcome +syn keyword ishdFunction SelectFolder ShowGroup ShowProgamFolder SetColor +syn keyword ishdFunction SetDialogTitle SetDisplayEffect SetErrorMsg +syn keyword ishdFunction SetErrorTitle SetFont SetStatusWindow SetTitle +syn keyword ishdFunction SizeWindow StatusUpdate StrCompare StrFind StrGetTokens +syn keyword ishdFunction StrLength StrRemoveLastSlash StrSub StrToLower StrToNum +syn keyword ishdFunction StrToUpper ShowProgramFolder UnUseDLL UseDLL VarRestore +syn keyword ishdFunction VarSave VerUpdateFile VerCompare VerFindFileVersion +syn keyword ishdFunction VerGetFileVersion VerSearchAndUpdateFile VerUpdateFile +syn keyword ishdFunction Welcome WaitOnDialog WriteBytes WriteLine +syn keyword ishdFunction WriteProfString XCopyFile + +syn keyword ishdTodo contained TODO + +"integer number, or floating point number without a dot. +syn match ishdNumber "\<\d\+\>" +"floating point number, with dot +syn match ishdNumber "\<\d\+\.\d*\>" +"floating point number, starting with a dot +syn match ishdNumber "\.\d\+\>" + +" String constants +syn region ishdString start=+"+ skip=+\\\\\|\\"+ end=+"+ + +syn region ishdComment start="//" end="$" contains=ishdTodo +syn region ishdComment start="/\*" end="\*/" contains=ishdTodo + +" Pre-processor commands +syn region ishdPreCondit start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=ishdComment,ishdString +if !exists("ishd_no_if0") + syn region ishdHashIf0 start="^\s*#\s*if\s\+0\>" end=".\|$" contains=ishdHashIf0End + syn region ishdHashIf0End contained start="0" end="^\s*#\s*\(endif\>\|else\>\|elif\>\)" contains=ishdHashIf0Skip + syn region ishdHashIf0Skip contained start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*#\s*endif\>" contains=ishdHashIf0Skip +endif +syn region ishdIncluded contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match ishdInclude +^\s*#\s*include\>\s*"+ contains=ishdIncluded +syn cluster ishdPreProcGroup contains=ishdPreCondit,ishdIncluded,ishdInclude,ishdDefine,ishdHashIf0,ishdHashIf0End,ishdHashIf0Skip,ishdNumber +syn region ishdDefine start="^\s*#\s*\(define\|undef\)\>" end="$" contains=ALLBUT,@ishdPreProcGroup + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link ishdNumber Number +hi def link ishdError Error +hi def link ishdStatement Statement +hi def link ishdString String +hi def link ishdComment Comment +hi def link ishdTodo Todo +hi def link ishdFunction Identifier +hi def link ishdConstant PreProc +hi def link ishdType Type +hi def link ishdInclude Include +hi def link ishdDefine Macro +hi def link ishdIncluded String +hi def link ishdPreCondit PreCondit +hi def link ishdHashIf0Skip ishdHashIf0 +hi def link ishdHashIf0End ishdHashIf0 +hi def link ishdHashIf0 Comment + + +let b:current_syntax = "ishd" + +" vim: ts=8 + +endif diff --git a/syntax/iss.vim b/syntax/iss.vim new file mode 100644 index 0000000..4895456 --- /dev/null +++ b/syntax/iss.vim @@ -0,0 +1,140 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Inno Setup File (iss file) and My InnoSetup extension +" Maintainer: Jason Mills (jmills@cs.mun.ca) +" Previous Maintainer: Dominique Stéphan (dominique@mggen.com) +" Last Change: 2004 Dec 14 +" +" Todo: +" - The paramter String: is matched as flag string (because of case ignore). +" - Pascal scripting syntax is not recognized. +" - Embedded double quotes confuse string matches. e.g. "asfd""asfa" + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" shut case off +syn case ignore + +" Preprocessor +syn region issPreProc start="^\s*#" end="$" + +" Section +syn region issSection start="\[" end="\]" + +" Label in the [Setup] Section +syn match issDirective "^[^=]\+=" + +" URL +syn match issURL "http[s]\=:\/\/.*$" + +" Parameters used for any section. +" syn match issParam"[^: ]\+:" +syn match issParam "Name:" +syn match issParam "MinVersion:\|OnlyBelowVersion:\|Languages:" +syn match issParam "Source:\|DestDir:\|DestName:\|CopyMode:" +syn match issParam "Attribs:\|Permissions:\|FontInstall:\|Flags:" +syn match issParam "FileName:\|Parameters:\|WorkingDir:\|HotKey:\|Comment:" +syn match issParam "IconFilename:\|IconIndex:" +syn match issParam "Section:\|Key:\|String:" +syn match issParam "Root:\|SubKey:\|ValueType:\|ValueName:\|ValueData:" +syn match issParam "RunOnceId:" +syn match issParam "Type:\|Excludes:" +syn match issParam "Components:\|Description:\|GroupDescription:\|Types:\|ExtraDiskSpaceRequired:" +syn match issParam "StatusMsg:\|RunOnceId:\|Tasks:" +syn match issParam "MessagesFile:\|LicenseFile:\|InfoBeforeFile:\|InfoAfterFile:" + +syn match issComment "^\s*;.*$" + +" folder constant +syn match issFolder "{[^{]*}" + +" string +syn region issString start=+"+ end=+"+ contains=issFolder + +" [Dirs] +syn keyword issDirsFlags deleteafterinstall uninsalwaysuninstall uninsneveruninstall + +" [Files] +syn keyword issFilesCopyMode normal onlyifdoesntexist alwaysoverwrite alwaysskipifsameorolder dontcopy +syn keyword issFilesAttribs readonly hidden system +syn keyword issFilesPermissions full modify readexec +syn keyword issFilesFlags allowunsafefiles comparetimestampalso confirmoverwrite deleteafterinstall +syn keyword issFilesFlags dontcopy dontverifychecksum external fontisnttruetype ignoreversion +syn keyword issFilesFlags isreadme onlyifdestfileexists onlyifdoesntexist overwritereadonly +syn keyword issFilesFlags promptifolder recursesubdirs regserver regtypelib restartreplace +syn keyword issFilesFlags sharedfile skipifsourcedoesntexist sortfilesbyextension touch +syn keyword issFilesFlags uninsremovereadonly uninsrestartdelete uninsneveruninstall +syn keyword issFilesFlags replacesameversion nocompression noencryption noregerror + + +" [Icons] +syn keyword issIconsFlags closeonexit createonlyiffileexists dontcloseonexit +syn keyword issIconsFlags runmaximized runminimized uninsneveruninstall useapppaths + +" [INI] +syn keyword issINIFlags createkeyifdoesntexist uninsdeleteentry uninsdeletesection uninsdeletesectionifempty + +" [Registry] +syn keyword issRegRootKey HKCR HKCU HKLM HKU HKCC +syn keyword issRegValueType none string expandsz multisz dword binary +syn keyword issRegFlags createvalueifdoesntexist deletekey deletevalue dontcreatekey +syn keyword issRegFlags preservestringtype noerror uninsclearvalue +syn keyword issRegFlags uninsdeletekey uninsdeletekeyifempty uninsdeletevalue + +" [Run] and [UninstallRun] +syn keyword issRunFlags hidewizard nowait postinstall runhidden runmaximized +syn keyword issRunFlags runminimized shellexec skipifdoesntexist skipifnotsilent +syn keyword issRunFlags skipifsilent unchecked waituntilidle + +" [Types] +syn keyword issTypesFlags iscustom + +" [Components] +syn keyword issComponentsFlags dontinheritcheck exclusive fixed restart disablenouninstallwarning + +" [UninstallDelete] and [InstallDelete] +syn keyword issInstallDeleteType files filesandordirs dirifempty + +" [Tasks] +syn keyword issTasksFlags checkedonce dontinheritcheck exclusive restart unchecked + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link issSection Special +hi def link issComment Comment +hi def link issDirective Type +hi def link issParam Type +hi def link issFolder Special +hi def link issString String +hi def link issURL Include +hi def link issPreProc PreProc + +hi def link issDirsFlags Keyword +hi def link issFilesCopyMode Keyword +hi def link issFilesAttribs Keyword +hi def link issFilesPermissions Keyword +hi def link issFilesFlags Keyword +hi def link issIconsFlags Keyword +hi def link issINIFlags Keyword +hi def link issRegRootKey Keyword +hi def link issRegValueType Keyword +hi def link issRegFlags Keyword +hi def link issRunFlags Keyword +hi def link issTypesFlags Keyword +hi def link issComponentsFlags Keyword +hi def link issInstallDeleteType Keyword +hi def link issTasksFlags Keyword + + +let b:current_syntax = "iss" + +" vim:ts=8 + +endif diff --git a/syntax/ist.vim b/syntax/ist.vim new file mode 100644 index 0000000..344150d --- /dev/null +++ b/syntax/ist.vim @@ -0,0 +1,62 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Makeindex style file, *.ist +" Maintainer: Peter Meszaros +" Last Change: 2012 Jan 08 by Thilo Six + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword=$,@,48-57,_ + +syn case ignore +syn keyword IstInpSpec actual arg_close arg_open encap escape +syn keyword IstInpSpec keyword level quote range_close range_open +syn keyword IstInpSpec page_compositor + +syn keyword IstOutSpec preamble postamble setpage_prefix setpage_suffix group_skip +syn keyword IstOutSpec headings_flag heading_prefix heading_suffix +syn keyword IstOutSpec lethead_flag lethead_prefix lethead_suffix +syn keyword IstOutSpec symhead_positive symhead_negative numhead_positive numhead_negative +syn keyword IstOutSpec item_0 item_1 item_2 item_01 +syn keyword IstOutSpec item_x1 item_12 item_x2 +syn keyword IstOutSpec delim_0 delim_1 delim_2 +syn keyword IstOutSpec delim_n delim_r delim_t +syn keyword IstOutSpec encap_prefix encap_infix encap_suffix +syn keyword IstOutSpec line_max indent_space indent_length +syn keyword IstOutSpec suffix_2p suffix_3p suffix_mp + +syn region IstString matchgroup=IstDoubleQuote start=+"+ skip=+\\"+ end=+"+ contains=IstSpecial +syn match IstCharacter "'.'" +syn match IstNumber "\d\+" +syn match IstComment "^[\t ]*%.*$" contains=IstTodo +syn match IstSpecial "\\\\\|{\|}\|#\|\\n" contained +syn match IstTodo "DEBUG\|TODO" contained + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link IstInpSpec Type +hi def link IstOutSpec Identifier +hi def link IstString String +hi def link IstNumber Number +hi def link IstComment Comment +hi def link IstTodo Todo +hi def link IstSpecial Special +hi def link IstDoubleQuote Label +hi def link IstCharacter Label + + +let b:current_syntax = "ist" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 sw=2 + +endif diff --git a/syntax/j.vim b/syntax/j.vim new file mode 100644 index 0000000..b7ec960 --- /dev/null +++ b/syntax/j.vim @@ -0,0 +1,150 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: J +" Maintainer: David Bürgin <676c7473@gmail.com> +" URL: https://github.com/glts/vim-j +" Last Change: 2015-01-11 + +if exists('b:current_syntax') + finish +endif + +let s:save_cpo = &cpo +set cpo&vim + +syntax case match +syntax sync minlines=100 + +syntax cluster jStdlibItems contains=jStdlibNoun,jStdlibAdverb,jStdlibConjunction,jStdlibVerb +syntax cluster jPrimitiveItems contains=jNoun,jAdverb,jConjunction,jVerb,jCopula + +syntax match jControl /\<\%(assert\|break\|case\|catch[dt]\=\|continue\|do\|else\%(if\)\=\|end\|fcase\|for\|if\|return\|select\|throw\|try\|whil\%(e\|st\)\)\./ +syntax match jControl /\<\%(for\|goto\|label\)_\a\k*\./ + +" Standard library names. A few names need to be defined with ":syntax match" +" because they would otherwise take precedence over the corresponding jControl +" and jDefineExpression items. +syntax keyword jStdlibNoun ARGV BINPATH CR CRLF DEL Debug EAV EMPTY FF FHS IF64 IFIOS IFJCDROID IFJHS IFQT IFRASPI IFUNIX IFWIN IFWINCE IFWINE IFWOW64 JB01 JBOXED JCHAR JCMPX JFL JINT JPTR JSIZES JSTR JTYPES JVERSION LF LF2 TAB UNAME UNXLIB dbhelp libjqt +syntax keyword jStdlibAdverb define each every fapplylines inv inverse items leaf rows rxapply rxmerge table +syntax keyword jStdlibConjunction bind cuts def on +syntax keyword jStdlibVerb AND Endian IFDEF OR XOR anddf android_exec_am android_exec_host andunzip apply boxopen boxxopen bx calendar cd cdcb cder cderx cdf charsub chopstring cleartags clear coclass cocreate cocurrent codestroy coerase cofind cofindv cofullname coinfo coinsert compare coname conames conew conl conouns conounsx copath copathnl copathnlx coreset costate cut cutLF cutopen cutpara datatype dbctx dberm dberr dbg dbjmp dblocals dblxq dblxs dbnxt dbq dbr dbret dbrr dbrrx dbrun dbs dbsig dbsq dbss dbst dbstack dbstk dbstop dbstopme dbstopnext dbstops dbtrace dbview deb debc delstring detab dfh dir dircompare dircompares dirfind dirpath dirss dirssrplc dirtree dirused dlb dltb dltbs dquote drop dropafter dropto dtb dtbs echo empty endian erase evtloop exit expand f2utf8 fappend fappends fboxname fc fcompare fcompares fcopynew fdir ferase fetch fexist fexists fgets file2url fixdotdot fliprgb fmakex foldpara foldtext fpathcreate fpathname fputs fread freadblock freadr freads frename freplace fsize fss fssrplc fstamp fstringreplace ftype fview fwrite fwritenew fwrites getalpha getargs getdate getenv getqtbin hfd hostpathsep ic install iospath isatty isotimestamp isutf8 jcwdpath joinstring jpath jpathsep jsystemdefs launch list ljust load loadd loadtags mema memf memr memw nameclass namelist names nc nl pick quote require rjust rplc rxE rxall rxcomp rxcut rxeq rxerror rxfirst rxfree rxfrom rxhandles rxin rxindex rxinfo rxmatch rxmatches rxrplc rxutf8 script scriptd scripts setalpha setbreak shell show sign sminfo smoutput sort split splitnostring splitstring ss startupandroid startupconsole startupide stderr stdin stdout stringreplace symdat symget symset ta tagcp tagopen tagselect take takeafter taketo timespacex timestamp timex tmoutput toCRLF toHOST toJ todate todayno tolower topara toupper tsdiff tsrep tstamp type ucp ucpcount unxlib usleep utf8 uucp valdate wcsize weekday weeknumber weeksinyear winpathsep xedit +syntax match jStdlibNoun /\<\%(adverb\|conjunction\|dyad\|monad\|noun\|verb\)\>/ +syntax match jStdlibVerb /\<\%(Note\|\%(assert\|break\|do\)\.\@!\)\>/ + +" Numbers. Matching J numbers is difficult. In fact, the job cannot be done +" with regular expressions alone. Below is a sketch of the pattern used. It +" accepts most well-formed numbers and rejects most of the ill-formed ones. +" See http://www.jsoftware.com/help/dictionary/dcons.htm for reference. +" +" "double1" and "double2" patterns: +" (_?\d+(\.\d*)?|_\.\d+)([eE]_?\d+)? +" (_?\d+(\.\d*)?|_\.\d+|\.\d+)([eE]_?\d+)? +" +" "rational1" and "rational2" patterns: +" \k(r\k)?|__? +" \k(r\k)?|__? +" +" "complex1" and "complex2" patterns: +" \k((j|a[dr])\k)? +" \k((j|a[dr])\k)? +" +" "basevalue" pattern: +" _?[0-9a-z]+(\.[0-9a-z]*)?|_?\.[0-9a-z]+ +" +" all numbers: +" \b\k([px]\k)?(b\k)?(?![0-9A-Za-z_.]) +syntax match jNumber /\<_\.[0-9A-Za-z_.]\@!/ +syntax match jNumber /\<_\=\d\+x[0-9A-Za-z_.]\@!/ +syntax match jNumber /\<\%(__\=r_\=\d\+\|_\=\d\+r__\=\)[0-9A-Za-z_.]\@!/ +syntax match jNumber /\<\%(\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\)\%([eE]_\=\d\+\)\=\%(r\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\|\.\d\+\)\%([eE]_\=\d\+\)\=\)\=\|__\=\)\%(\%(j\|a[dr]\)\%(\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\|\.\d\+\)\%([eE]_\=\d\+\)\=\%(r\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\|\.\d\+\)\%([eE]_\=\d\+\)\=\)\=\|__\=\)\)\=\%([px]\%(\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\|\.\d\+\)\%([eE]_\=\d\+\)\=\%(r\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\|\.\d\+\)\%([eE]_\=\d\+\)\=\)\=\|__\=\)\%(\%(j\|a[dr]\)\%(\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\|\.\d\+\)\%([eE]_\=\d\+\)\=\%(r\%(_\=\d\+\%(\.\d*\)\=\|_\.\d\+\|\.\d\+\)\%([eE]_\=\d\+\)\=\)\=\|__\=\)\)\=\)\=\%(b\%(_\=[0-9a-z]\+\%(\.[0-9a-z]*\)\=\|_\=\.[0-9a-z]\+\)\)\=[0-9A-Za-z_.]\@!/ + +syntax region jString oneline start=/'/ skip=/''/ end=/'/ + +syntax keyword jArgument contained x y u v m n + +" Primitives. Order is significant both within the patterns and among +" ":syntax match" statements. Refer to "Parts of speech" in the J dictionary. +syntax match jNoun /\+*\-%$|,#][.:]\=\|[~}"][.:]\|{\%[::]\|\<\%([ACeEiIjLor]\.\|p\.\.\=\|[ipqsux]:\|0:\|_\=[1-9]:\)/ +syntax match jCopula /=[.:]/ +syntax match jConjunction /;\.\|\^:\|![.:]/ + +" Explicit noun definition. The difficulty is that the define expression can +" occur in the middle of a line but the jNounDefine region must only start on +" the next line. The trick is to split the problem into two regions and link +" them with "nextgroup=". The fold wrapper provides syntax folding. +syntax region jNounDefineFold + \ matchgroup=NONE start=/\%(\%(\%(^\s*Note\)\|\<\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\)\>\)\@=/ + \ keepend matchgroup=NONE end=/^\s*)\s*$/ + \ contains=jNounDefineStart + \ fold +syntax region jNounDefineStart + \ matchgroup=jDefineExpression start=/\%(\%(^\s*Note\)\|\<\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\)\>/ + \ keepend matchgroup=NONE end=/$/ + \ contains=@jStdlibItems,@jPrimitiveItems,jNumber,jString,jParenGroup,jParen,jComment + \ contained oneline skipempty nextgroup=jDefineEnd,jNounDefine +" These two items must have "contained", which allows them to match only after +" jNounDefineStart thanks to the "nextgroup=" above. +syntax region jNounDefine + \ matchgroup=NONE start=/^/ + \ matchgroup=jDefineEnd end=/^\s*)\s*$/ + \ contained +" This match is necessary in case of an empty noun definition +syntax match jDefineEnd contained /^\s*)\s*$/ + +" Explicit verb, adverb, and conjunction definition +syntax region jDefine + \ matchgroup=jDefineExpression start=/\<\%([1-4]\|13\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\>/ + \ matchgroup=jDefineEnd end=/^\s*)\s*$/ + \ contains=jControl,@jStdlibItems,@jPrimitiveItems,jNumber,jString,jArgument,jParenGroup,jParen,jComment,jDefineMonadDyad + \ fold +syntax match jDefineMonadDyad contained /^\s*:\s*$/ + +" Paired parentheses. When a jDefineExpression such as "3 : 0" is +" parenthesised it will erroneously extend jParenGroup to span over the whole +" definition body. This situation receives a special treatment here. +syntax match jParen /(\%(\s*\%([0-4]\|13\|noun\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\s*)\)\@=/ +syntax match jParen contained /\%((\s*\%([0-4]\|13\|noun\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\s*\)\@<=)/ +syntax region jParenGroup + \ matchgroup=jParen start=/(\%(\s*\%([0-4]\|13\|noun\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\>\)\@!/ + \ matchgroup=jParen end=/)/ + \ oneline transparent + +syntax keyword jTodo contained TODO FIXME XXX +syntax match jComment /\ +" This is a syntax definition for the JAL language. +" It is based on the Source Forge compiler source code. +" https://sourceforge.net/projects/jal/ +" +" TODO test. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore +syn sync lines=250 + +syn keyword picTodo NOTE TODO XXX contained + +syn match picIdentifier "[a-z_$][a-z0-9_$]*" +syn match picLabel "^[A-Z_$][A-Z0-9_$]*" +syn match picLabel "^[A-Z_$][A-Z0-9_$]*:"me=e-1 + +syn match picASCII "A\='.'" +syn match picBinary "B'[0-1]\+'" +syn match picDecimal "D'\d\+'" +syn match picDecimal "\d\+" +syn match picHexadecimal "0x\x\+" +syn match picHexadecimal "H'\x\+'" +syn match picHexadecimal "[0-9]\x*h" +syn match picOctal "O'[0-7]\o*'" + +syn match picComment ";.*" contains=picTodo + +syn region picString start=+"+ end=+"+ + +syn keyword picRegister indf tmr0 pcl status fsr port_a port_b port_c port_d port_e x84_eedata x84_eeadr pclath intcon +syn keyword picRegister f877_tmr1l f877_tmr1h f877_t1con f877_t2con f877_ccpr1l f877_ccpr1h f877_ccp1con +syn keyword picRegister f877_pir1 f877_pir2 f877_pie1 f877_adcon1 f877_adcon0 f877_pr2 f877_adresl f877_adresh +syn keyword picRegister f877_eeadr f877_eedath f877_eeadrh f877_eedata f877_eecon1 f877_eecon2 f628_EECON2 +syn keyword picRegister f877_rcsta f877_txsta f877_spbrg f877_txreg f877_rcreg f628_EEDATA f628_EEADR f628_EECON1 + +" Register --- bits +" STATUS +syn keyword picRegisterPart status_c status_dc status_z status_pd +syn keyword picRegisterPart status_to status_rp0 status_rp1 status_irp + +" pins +syn keyword picRegisterPart pin_a0 pin_a1 pin_a2 pin_a3 pin_a4 pin_a5 +syn keyword picRegisterPart pin_b0 pin_b1 pin_b2 pin_b3 pin_b4 pin_b5 pin_b6 pin_b7 +syn keyword picRegisterPart pin_c0 pin_c1 pin_c2 pin_c3 pin_c4 pin_c5 pin_c6 pin_c7 +syn keyword picRegisterPart pin_d0 pin_d1 pin_d2 pin_d3 pin_d4 pin_d5 pin_d6 pin_d7 +syn keyword picRegisterPart pin_e0 pin_e1 pin_e2 + +syn keyword picPortDir port_a_direction port_b_direction port_c_direction port_d_direction port_e_direction + +syn match picPinDir "pin_a[012345]_direction" +syn match picPinDir "pin_b[01234567]_direction" +syn match picPinDir "pin_c[01234567]_direction" +syn match picPinDir "pin_d[01234567]_direction" +syn match picPinDir "pin_e[012]_direction" + + +" INTCON +syn keyword picRegisterPart intcon_gie intcon_eeie intcon_peie intcon_t0ie intcon_inte +syn keyword picRegisterPart intcon_rbie intcon_t0if intcon_intf intcon_rbif + +" TIMER +syn keyword picRegisterPart t1ckps1 t1ckps0 t1oscen t1sync tmr1cs tmr1on tmr1ie tmr1if + +"cpp bits +syn keyword picRegisterPart ccp1x ccp1y + +" adcon bits +syn keyword picRegisterPart adcon0_go adcon0_ch0 adcon0_ch1 adcon0_ch2 + +" EECON +syn keyword picRegisterPart eecon1_rd eecon1_wr eecon1_wren eecon1_wrerr eecon1_eepgd +syn keyword picRegisterPart f628_eecon1_rd f628_eecon1_wr f628_eecon1_wren f628_eecon1_wrerr + +" usart +syn keyword picRegisterPart tx9 txen sync brgh tx9d +syn keyword picRegisterPart spen rx9 cren ferr oerr rx9d +syn keyword picRegisterPart TXIF RCIF + +" OpCodes... +syn keyword picOpcode addlw andlw call clrwdt goto iorlw movlw option retfie retlw return sleep sublw tris +syn keyword picOpcode xorlw addwf andwf clrf clrw comf decf decfsz incf incfsz retiw iorwf movf movwf nop +syn keyword picOpcode rlf rrf subwf swapf xorwf bcf bsf btfsc btfss skpz skpnz setz clrz skpc skpnc setc clrc +syn keyword picOpcode skpdc skpndc setdc clrdc movfw tstf bank page HPAGE mullw mulwf cpfseq cpfsgt cpfslt banka bankb + + +syn keyword jalBoolean true false +syn keyword jalBoolean off on +syn keyword jalBit high low +syn keyword jalConstant Input Output all_input all_output +syn keyword jalConditional if else then elsif end if +syn keyword jalLabel goto +syn keyword jalRepeat for while forever loop +syn keyword jalStatement procedure function +syn keyword jalStatement return end volatile const var +syn keyword jalType bit byte + +syn keyword jalModifier interrupt assembler asm put get +syn keyword jalStatement out in is begin at +syn keyword jalDirective pragma jump_table target target_clock target_chip name error test assert +syn keyword jalPredefined hs xt rc lp internal 16c84 16f84 16f877 sx18 sx28 12c509a 12c508 +syn keyword jalPredefined 12ce674 16f628 18f252 18f242 18f442 18f452 12f629 12f675 16f88 +syn keyword jalPredefined 16f876 16f873 sx_12 sx18 sx28 pic_12 pic_14 pic_16 + +syn keyword jalDirective chip osc clock fuses cpu watchdog powerup protection + +syn keyword jalFunction bank_0 bank_1 bank_2 bank_3 bank_4 bank_5 bank_6 bank_7 trisa trisb trisc trisd trise +syn keyword jalFunction _trisa_flush _trisb_flush _trisc_flush _trisd_flush _trise_flush + +syn keyword jalPIC local idle_loop + +syn region jalAsm matchgroup=jalAsmKey start="\" end="\" contains=jalComment,jalPreProc,jalLabel,picIdentifier, picLabel,picASCII,picDecimal,picHexadecimal,picOctal,picComment,picString,picRegister,picRigisterPart,picOpcode,picDirective,jalPIC +syn region jalAsm matchgroup=jalAsmKey start="\" end=/$/ contains=jalComment,jalPreProc,jalLabel,picIdentifier, picLabel,picASCII,picDecimal,picHexadecimal,picOctal,picComment,picString,picRegister,picRigisterPart,picOpcode,picDirective,jalPIC + +syn region jalPsudoVars matchgroup=jalPsudoVarsKey start="\<'put\>" end="/" contains=jalComment + +syn match jalStringEscape contained "#[12][0-9]\=[0-9]\=" +syn match jalIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>" +syn match jalSymbolOperator "[+\-/*=]" +syn match jalSymbolOperator "!" +syn match jalSymbolOperator "<" +syn match jalSymbolOperator ">" +syn match jalSymbolOperator "<=" +syn match jalSymbolOperator ">=" +syn match jalSymbolOperator "!=" +syn match jalSymbolOperator "==" +syn match jalSymbolOperator "<<" +syn match jalSymbolOperator ">>" +syn match jalSymbolOperator "|" +syn match jalSymbolOperator "&" +syn match jalSymbolOperator "%" +syn match jalSymbolOperator "?" +syn match jalSymbolOperator "[()]" +syn match jalSymbolOperator "[\^.]" +syn match jalLabel "[\^]*:" + +syn match jalNumber "-\=\<\d[0-9_]\+\>" +syn match jalHexNumber "0x[0-9A-Fa-f_]\+\>" +syn match jalBinNumber "0b[01_]\+\>" + +" String +"wrong strings +syn region jalStringError matchgroup=jalStringError start=+"+ end=+"+ end=+$+ contains=jalStringEscape + +"right strings +syn region jalString matchgroup=jalString start=+'+ end=+'+ oneline contains=jalStringEscape +" To see the start and end of strings: +syn region jalString matchgroup=jalString start=+"+ end=+"+ oneline contains=jalStringEscapeGPC + +syn keyword jalTodo contained TODO +syn region jalComment start=/-- / end=/$/ oneline contains=jalTodo +syn region jalComment start=/--\t/ end=/$/ oneline contains=jalTodo +syn match jalComment /--\_$/ +syn region jalPreProc start="include" end=/$/ contains=JalComment,jalToDo + + +if exists("jal_no_tabs") + syn match jalShowTab "\t" +endif + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link jalAcces jalStatement +hi def link jalBoolean Boolean +hi def link jalBit Boolean +hi def link jalComment Comment +hi def link jalConditional Conditional +hi def link jalConstant Constant +hi def link jalDelimiter Identifier +hi def link jalDirective PreProc +hi def link jalException Exception +hi def link jalFloat Float +hi def link jalFunction Function +hi def link jalPsudoVarsKey Function +hi def link jalLabel Label +hi def link jalMatrixDelimiter Identifier +hi def link jalModifier Type +hi def link jalNumber Number +hi def link jalBinNumber Number +hi def link jalHexNumber Number +hi def link jalOperator Operator +hi def link jalPredefined Constant +hi def link jalPreProc PreProc +hi def link jalRepeat Repeat +hi def link jalStatement Statement +hi def link jalString String +hi def link jalStringEscape Special +hi def link jalStringEscapeGPC Special +hi def link jalStringError Error +hi def link jalStruct jalStatement +hi def link jalSymbolOperator jalOperator +hi def link jalTodo Todo +hi def link jalType Type +hi def link jalUnclassified Statement +hi def link jalAsm Assembler +hi def link jalError Error +hi def link jalAsmKey Statement +hi def link jalPIC Statement + +hi def link jalShowTab Error + +hi def link picTodo Todo +hi def link picComment Comment +hi def link picDirective Statement +hi def link picLabel Label +hi def link picString String + +hi def link picOpcode Keyword +hi def link picRegister Structure +hi def link picRegisterPart Special +hi def link picPinDir SPecial +hi def link picPortDir SPecial + +hi def link picASCII String +hi def link picBinary Number +hi def link picDecimal Number +hi def link picHexadecimal Number +hi def link picOctal Number + +hi def link picIdentifier Identifier + + + +let b:current_syntax = "jal" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/jam.vim b/syntax/jam.vim new file mode 100644 index 0000000..5588bac --- /dev/null +++ b/syntax/jam.vim @@ -0,0 +1,244 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: JAM +" Maintainer: Ralf Lemke (ralflemk@t-online.de) +" Last change: 2012 Jan 08 by Thilo Six + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword=@,48-57,_,- + +" A bunch of useful jam keywords +syn keyword jamStatement break call dbms flush global include msg parms proc public receive return send unload vars +syn keyword jamConditional if else +syn keyword jamRepeat for while next step + +syn keyword jamTodo contained TODO FIXME XXX +syn keyword jamDBState1 alias binary catquery close close_all_connections column_names connection continue continue_bottom continue_down continue_top continue_up +syn keyword jamDBState2 cursor declare engine execute format occur onentry onerror onexit sql start store unique with +syn keyword jamSQLState1 all alter and any avg between by count create current data database delete distinct drop exists fetch from grant group +syn keyword jamSQLState2 having index insert into like load max min of open order revoke rollback runstats select set show stop sum synonym table to union update values view where bundle + +syn keyword jamLibFunc1 dm_bin_create_occur dm_bin_delete_occur dm_bin_get_dlength dm_bin_get_occur dm_bin_length dm_bin_max_occur dm_bin_set_dlength dm_convert_empty dm_cursor_connection dm_cursor_consistent dm_cursor_engine dm_dbi_init dm_dbms dm_dbms_noexp dm_disable_styles dm_enable_styles dm_exec_sql dm_expand dm_free_sql_info dm_gen_change_execute_using dm_gen_change_select_from dm_gen_change_select_group_by dm_gen_change_select_having dm_gen_change_select_list dm_gen_change_select_order_by dm_gen_change_select_suffix dm_gen_change_select_where dm_gen_get_tv_alias dm_gen_sql_info + +syn keyword jamLibFunc2 dm_get_db_conn_handle dm_get_db_cursor_handle dm_get_driver_option dm_getdbitext dm_init dm_is_connection dm_is_cursor dm_is_engine dm_odb_preserves_cursor dm_reset dm_set_driver_option dm_set_max_fetches dm_set_max_rows_per_fetch dm_set_tm_clear_fast dm_val_relative sm_adjust_area sm_allget sm_amt_format sm_e_amt_format sm_i_amt_format sm_n_amt_format sm_o_amt_format sm_append_bundle_data sm_append_bundle_done sm_append_bundle_item sm_d_at_cur sm_l_at_cur sm_r_at_cur sm_mw_attach_drawing_func sm_mwn_attach_drawing_func sm_mwe_attach_drawing_func sm_xm_attach_drawing_func sm_xmn_attach_drawing_func sm_xme_attach_drawing_func sm_backtab sm_bel sm_bi_comparesm_bi_copy sm_bi_initialize sm_bkrect sm_c_off sm_c_on sm_c_vis sm_calc sm_cancel sm_ckdigit sm_cl_all_mdts sm_cl_unprot sm_clear_array sm_n_clear_array sm_1clear_array sm_n_1clear_array sm_close_window sm_com_load_picture sm_com_QueryInterface sm_com_result sm_com_result_msg sm_com_set_handler sm_copyarray sm_n_copyarray sm_create_bundle + +syn keyword jamLibFunc3 sm_d_msg_line sm_dblval sm_e_dblval sm_i_dblval sm_n_dblval sm_o_dblval sm_dd_able sm_dde_client_connect_cold sm_dde_client_connect_hot sm_dde_client_connect_warm sm_dde_client_disconnect sm_dde_client_off sm_dde_client_on sm_dde_client_paste_link_cold sm_dde_client_paste_link_hot sm_dde_client_paste_link_warm sm_dde_client_request sm_dde_execute sm_dde_install_notify sm_dde_poke sm_dde_server_off sm_dde_server_on sm_delay_cursor sm_deselect sm_dicname sm_disp_off sm_dlength sm_e_dlength sm_i_dlength sm_n_dlength sm_o_dlength sm_do_uinstalls sm_i_doccur sm_o_doccur sm_drawingarea sm_xm_drawingarea sm_dtofield sm_e_dtofield sm_i_dtofield sm_n_dtofield sm_o_dtofield sm_femsg sm_ferr_reset sm_fi_path sm_file_copy sm_file_exists sm_file_move sm_file_remove sm_fi_open sm_fi_path sm_filebox sm_filetypes sm_fio_a2f sm_fio_close sm_fio_editor sm_fio_error sm_fio_error_set sm_fio_f2a sm_fio_getc sm_fio_gets sm_fio_handle sm_fio_open sm_fio_putc sm_fio_puts sm_fio_rewind sm_flush sm_d_form sm_l_form + +syn keyword jamLibFunc4 sm_r_form sm_formlist sm_fptr sm_e_fptr sm_i_fptr sm_n_fptr sm_o_fptr sm_fqui_msg sm_fquiet_err sm_free_bundle sm_ftog sm_e_ftog sm_i_ftog sm_n_ftog sm_o_ftog sm_fval sm_e_fval sm_i_fval sm_n_fval sm_o_fval sm_i_get_bi_data sm_o_get_bi_data sm_get_bundle_data sm_get_bundle_item_count sm_get_bundle_occur_count sm_get_next_bundle_name sm_i_get_tv_bi_data sm_o_get_tv_bi_data sm_getfield sm_e_getfield sm_i_getfield sm_n_getfield sm_o_getfield sm_getkey sm_gofield sm_e_gofield sm_i_gofield sm_n_gofield sm_o_gofield sm_gtof sm_gval sm_i_gtof sm_n_gval sm_hlp_by_name sm_home sm_inimsg sm_initcrt sm_jinitcrt sm_jxinitcrt sm_input sm_inquire sm_install sm_intval sm_e_intval sm_i_intval sm_n_intval sm_o_intval sm_i_ioccur sm_o_ioccur sm_is_bundle sm_is_no sm_e_is_no sm_i_is_no sm_n_is_no sm_o_is_no sm_is_yes sm_e_is_yes sm_i_is_yes sm_n_is_yes sm_o_is_yes sm_isabort sm_iset sm_issv sm_itofield sm_e_itofield sm_i_itofield sm_n_itofield sm_o_itofield sm_jclose sm_jfilebox sm_jform sm_djplcall sm_jplcall + +syn keyword jamLibFunc5 sm_sjplcall sm_jplpublic sm_jplunload sm_jtop sm_jwindow sm_key_integer sm_keyfilter sm_keyhit sm_keyinit sm_n_keyinit sm_keylabel sm_keyoption sm_l_close sm_l_open sm_l_open_syslib sm_last sm_launch sm_h_ldb_fld_get sm_n_ldb_fld_get sm_h_ldb_n_fld_get sm_n_ldb_n_fld_get sm_h_ldb_fld_store sm_n_ldb_fld_store sm_h_ldb_n_fld_store sm_n_ldb_n_fld_store sm_ldb_get_active sm_ldb_get_inactive sm_ldb_get_next_active sm_ldb_get_next_inactive sm_ldb_getfield sm_i_ldb_getfield sm_n_ldb_getfield sm_o_ldb_getfield sm_ldb_h_getfield sm_i_ldb_h_getfield sm_n_ldb_h_getfield sm_o_ldb_h_getfield sm_ldb_handle sm_ldb_init sm_ldb_is_loaded sm_ldb_load sm_ldb_name sm_ldb_next_handle sm_ldb_pop sm_ldb_push sm_ldb_putfield sm_i_ldb_putfield sm_n_ldb_putfield sm_o_ldb_putfield sm_ldb_h_putfield sm_i_ldb_h_putfield sm_n_ldb_h_putfield sm_o_ldb_h_putfield sm_ldb_state_get sm_ldb_h_state_get sm_ldb_state_set sm_ldb_h_state_set sm_ldb_unload sm_ldb_h_unload sm_leave sm_list_objects_count sm_list_objects_end sm_list_objects_next + +syn keyword jamLibFunc6 sm_list_objects_start sm_lngval sm_e_lngval sm_i_lngval sm_n_lngval sm_o_lngval sm_load_screen sm_log sm_lstore sm_ltofield sm_e_ltofield sm_i_ltofield sm_n_ltofield sm_o_ltofield sm_m_flush sm_menu_bar_error sm_menu_change sm_menu_create sm_menu_delete sm_menu_get_int sm_menu_get_str sm_menu_install sm_menu_remove sm_message_box sm_mncrinit6 sm_mnitem_change sm_n_mnitem_change sm_mnitem_create sm_n_mnitem_create sm_mnitem_delete sm_n_mnitem_delete sm_mnitem_get_int sm_n_mnitem_get_int sm_mnitem_get_str sm_n_mnitem_get_str sm_mnscript_load sm_mnscript_unload sm_ms_inquire sm_msg sm_msg_del sm_msg_get sm_msg_read sm_d_msg_read sm_n_msg_read sm_msgfind sm_mts_CreateInstance sm_mts_CreateProperty sm_mts_CreatePropertyGroup sm_mts_DisableCommit sm_mts_EnableCommit sm_mts_GetPropertyValue sm_mts_IsCallerInRole sm_mts_IsInTransaction sm_mts_IsSecurityEnabled sm_mts_PutPropertyValue sm_mts_SetAbort sm_mts_SetComplete sm_mus_time sm_mw_get_client_wnd sm_mw_get_cmd_show sm_mw_get_frame_wnd sm_mw_get_instance + +syn keyword jamLibFunc7 sm_mw_get_prev_instance sm_mw_PrintScreen sm_next_sync sm_nl sm_null sm_e_null sm_i_null sm_n_null sm_o_null sm_obj_call sm_obj_copy sm_obj_copy_id sm_obj_create sm_obj_delete sm_obj_delete_id sm_obj_get_property sm_obj_onerror sm_obj_set_property sm_obj_sort sm_obj_sort_auto sm_occur_no sm_off_gofield sm_e_off_gofield sm_i_off_gofield sm_n_off_gofield sm_o_off_gofield sm_option sm_optmnu_id sm_pinquire sm_popup_at_cur sm_prop_error sm_prop_get_int sm_prop_get_str sm_prop_get_dbl sm_prop_get_x_int sm_prop_get_x_str sm_prop_get_x_dbl sm_prop_get_m_int sm_prop_get_m_str sm_prop_get_m_dbl sm_prop_id sm_prop_name_to_id sm_prop_set_int sm_prop_set_str sm_prop_set_dbl sm_prop_set_x_int sm_prop_set_x_str sm_prop_set_x_dbl sm_prop_set_m_int sm_prop_set_m_str sm_prop_set_m_dbl sm_pset sm_putfield sm_e_putfield sm_i_putfield sm_n_putfield sm_o_putfield sm_raise_exception sm_receive sm_receive_args sm_rescreen sm_resetcrt sm_jresetcrt sm_jxresetcrt sm_resize sm_restore_data sm_return sm_return_args sm_rmformlist sm_rs_data + +syn keyword jamLibFunc8 sm_rw_error_message sm_rw_play_metafile sm_rw_runreport sm_s_val sm_save_data sm_sdtime sm_select sm_send sm_set_help sm_setbkstat sm_setsibling sm_setstatus sm_sh_off sm_shell sm_shrink_to_fit sm_slib_error sm_slib_install sm_slib_load sm_soption sm_strip_amt_ptr sm_e_strip_amt_ptr sm_i_strip_amt_ptr sm_n_strip_amt_ptr sm_o_strip_amt_ptr sm_sv_data sm_sv_free sm_svscreen sm_tab sm_tm_clear sm_tm_clear_model_events sm_tm_command sm_tm_command_emsgset sm_tm_command_errset sm_tm_continuation_validity sm_tm_dbi_checker sm_tm_error sm_tm_errorlog sm_tm_event sm_tm_event_name sm_tm_failure_message sm_tm_handling sm_tm_inquire sm_tm_iset sm_tm_msg_count_error sm_tm_msg_emsg sm_tm_msg_error sm_tm_old_bi_context sm_tm_pcopy sm_tm_pinquire sm_tm_pop_model_event sm_tm_pset sm_tm_push_model_event sm_tmpnam sm_tp_exec sm_tp_free_arg_buf sm_tp_gen_insert sm_tp_gen_sel_return sm_tp_gen_sel_where sm_tp_gen_val_link sm_tp_gen_val_return sm_tp_get_svc_alias sm_tp_get_tux_callid sm_translatecoords sm_tst_all_mdts + +syn keyword jamLibFunc9 sm_udtime sm_ungetkey sm_unload_screen sm_unsvscreen sm_upd_select sm_validate sm_n_validate sm_vinit sm_n_vinit sm_wcount sm_wdeselect sm_web_get_cookie sm_web_invoke_url sm_web_log_error sm_web_save_global sm_web_set_cookie sm_web_unsave_all_globals sm_web_unsave_global sm_mw_widget sm_mwe_widget sm_mwn_widget sm_xm_widget sm_xme_widget sm_xmn_widget sm_win_shrink sm_d_window sm_d_at_cur sm_l_window sm_l_at_cur sm_r_window sm_r_at_cur sm_winsize sm_wrotate sm_wselect sm_n_wselect sm_ww_length sm_n_ww_length sm_ww_read sm_n_ww_read sm_ww_write sm_n_ww_write sm_xlate_table sm_xm_get_base_window sm_xm_get_display + +syn keyword jamVariable1 SM_SCCS_ID SM_ENTERTERM SM_MALLOC SM_CANCEL SM_BADTERM SM_FNUM SM_DZERO SM_EXPONENT SM_INVDATE SM_MATHERR SM_FRMDATA SM_NOFORM SM_FRMERR SM_BADKEY SM_DUPKEY SM_ERROR SM_SP1 SM_SP2 SM_RENTRY SM_MUSTFILL SM_AFOVRFLW SM_TOO_FEW_DIGITS SM_CKDIGIT SM_HITANY SM_NOHELP SM_MAXHELP SM_OUTRANGE SM_ENTERTERM1 SM_SYSDATE SM_DATFRM SM_DATCLR SM_DATINV SM_KSDATA SM_KSERR SM_KSNONE SM_KSMORE SM_DAYA1 SM_DAYA2 SM_DAYA3 SM_DAYA4 SM_DAYA5 SM_DAYA6 SM_DAYA7 SM_DAYL1 SM_DAYL2 SM_DAYL3 SM_DAYL4 SM_DAYL5 SM_DAYL6 SM_DAYL7 SM_MNSCR_LOAD SM_MENU_INSTALL SM_INSTDEFSCRL SM_INSTSCROLL SM_MOREDATA SM_READY SM_WAIT SM_YES SM_NO SM_NOTEMP SM_FRMHELP SM_FILVER SM_ONLYONE SM_WMSMOVE SM_WMSSIZE SM_WMSOFF SM_LPRINT SM_FMODE SM_NOFILE SM_NOSECTN SM_FFORMAT SM_FREAD SM_RX1 SM_RX2 SM_RX3 SM_TABLOOK SM_MISKET SM_ILLKET SM_ILLBRA SM_MISDBLKET SM_ILLDBLKET SM_ILLDBLBRA SM_ILL_RIGHT SM_ILLELSE SM_NUMBER SM_EOT SM_BREAK SM_NOARGS SM_BIGVAR SM_EXCESS SM_EOL SM_FILEIO SM_FOR SM_RCURLY SM_NONAME SM_1JPL_ERR SM_2JPL_ERR SM_3JPL_ERR + +syn keyword jamVariable2 SM_JPLATCH SM_FORMAT SM_DESTINATION SM_ORAND SM_ORATOR SM_ILL_LEFT SM_MISSPARENS SM_ILLCLOSE_COMM SM_FUNCTION SM_EQUALS SM_MISMATCH SM_QUOTE SM_SYNTAX SM_NEXT SM_VERB_UNKNOWN SM_JPLFORM SM_NOT_LOADED SM_GA_FLG SM_GA_CHAR SM_GA_ARG SM_GA_DIG SM_NOFUNC SM_BADPROTO SM_JPLPUBLIC SM_NOCOMPILE SM_NULLEDIT SM_RP_NULL SM_DBI_NOT_INST SM_NOTJY SM_MAXLIB SM_FL_FLLIB SM_TPI_NOT_INST SM_RW_NOT_INST SM_MONA1 SM_MONA2 SM_MONA3 SM_MONA4 SM_MONA5 SM_MONA6 SM_MONA7 SM_MONA8 SM_MONA9 SM_MONA10 SM_MONA11 SM_MONA12 SM_MONL1 SM_MONL2 SM_MONL3 SM_MONL4 SM_MONL5 SM_MONL6 SM_MONL7 SM_MONL8 SM_MONL9 SM_MONL10 SM_MONL11 SM_MONL12 SM_AM SM_PM SM_0DEF_DTIME SM_1DEF_DTIME SM_2DEF_DTIME SM_3DEF_DTIME SM_4DEF_DTIME SM_5DEF_DTIME SM_6DEF_DTIME SM_7DEF_DTIME SM_8DEF_DTIME SM_9DEF_DTIME SM_CALC_DATE SM_BAD_DIGIT SM_BAD_YN SM_BAD_ALPHA SM_BAD_NUM SM_BAD_ALPHNUM SM_DECIMAL SM_1STATS SM_VERNO SM_DIG_ERR SM_YN_ERR SM_LET_ERR SM_NUM_ERR SM_ANUM_ERR SM_REXP_ERR SM_POSN_ERR SM_FBX_OPEN SM_FBX_WINDOW SM_FBX_SIBLING SM_OPENDIR + +syn keyword jamVariable3 SM_GETFILES SM_CHDIR SM_GETCWD SM_UNCLOSED_COMM SM_MB_OKLABEL SM_MB_CANCELLABEL SM_MB_YESLABEL SM_MB_NOLABEL SM_MB_RETRYLABEL SM_MB_IGNORELABEL SM_MB_ABORTLABEL SM_MB_HELPLABEL SM_MB_STOP SM_MB_QUESTION SM_MB_WARNING SM_MB_INFORMATION SM_MB_YESALLLABEL SM_0MN_CURRDEF SM_1MN_CURRDEF SM_2MN_CURRDEF SM_0DEF_CURR SM_1DEF_CURR SM_2DEF_CURR SM_3DEF_CURR SM_4DEF_CURR SM_5DEF_CURR SM_6DEF_CURR SM_7DEF_CURR SM_8DEF_CURR SM_9DEF_CURR SM_SEND_SYNTAX SM_SEND_ITEM SM_SEND_INVALID_BUNDLE SM_RECEIVE_SYNTAX SM_RECEIVE_ITEM_NUMBER SM_RECEIVE_OVERFLOW SM_RECEIVE_ITEM SM_SYNCH_RECEIVE SM_EXEC_FAIL SM_DYNA_HELP_NOT_AVAIL SM_DLL_LOAD_ERR SM_DLL_UNRESOLVED SM_DLL_VERSION_ERR SM_DLL_OPTION_ERR SM_DEMOERR SM_MB_OKALLLABEL SM_MB_NOALLLABEL SM_BADPROP SM_BETWEEN SM_ATLEAST SM_ATMOST SM_PR_ERROR SM_PR_OBJID SM_PR_OBJECT SM_PR_ITEM SM_PR_PROP SM_PR_PROP_ITEM SM_PR_PROP_VAL SM_PR_CONVERT SM_PR_OBJ_TYPE SM_PR_RANGE SM_PR_NO_SET SM_PR_BYND_SCRN SM_PR_WW_SCROLL SM_PR_NO_SYNC SM_PR_TOO_BIG SM_PR_BAD_MASK SM_EXEC_MEM_ERR + +syn keyword jamVariable4 SM_EXEC_NO_PROG SM_PR_NO_KEYSTRUCT SM_REOPEN_AS_SLIB SM_REOPEN_THE_SLIB SM_ERRLIB SM_WARNLIB SM_LIB_DOWNGRADE SM_OLDER SM_NEWER SM_UPGRADE SM_LIB_READONLY SM_LOPEN_ERR SM_LOPEN_WARN SM_MLOPEN_CREAT SM_MLOPEN_INIT SM_LIB_ERR SM_LIB_ISOLATE SM_LIB_NO_ERR SM_LIB_REC_ERR SM_LIB_FATAL_ERR SM_LIB_LERR_FILE SM_LIB_LERR_NOTLIB SM_LIB_LERR_BADVERS SM_LIB_LERR_FORMAT SM_LIB_LERR_BADCM SM_LIB_LERR_LOCK SM_LIB_LERR_RESERVED SM_LIB_LERR_READONLY SM_LIB_LERR_NOENTRY SM_LIB_LERR_BUSY SM_LIB_LERR_ROVERS SM_LIB_LERR_DEFAULT SM_LIB_BADCM SM_LIB_LERR_NEW SM_STANDALONE_MODE SM_FEATURE_RESTRICT FM_CH_LOST FM_JPL_PROMPT FM_YR4 FM_YR2 FM_MON FM_MON2 FM_DATE FM_DATE2 FM_HOUR FM_HOUR2 FM_MIN FM_MIN2 FM_SEC FM_SEC2 FM_YRDAY FM_AMPM FM_DAYA FM_DAYL FM_MONA FM_MONL FM_0MN_DEF_DT FM_1MN_DEF_DT FM_2MN_DEF_DT FM_DAY JM_QTERMINATE JM_HITSPACE JM_HITACK JM_NOJWIN UT_MEMERR UT_P_OPT UT_V_OPT UT_E_BINOPT UT_NO_INPUT UT_SECLONG UT_1FNAME UT_SLINE UT_FILE UT_ERROR UT_WARNING UT_MISSEQ UT_VOPT UT_M2_DESCR + +syn keyword jamVariable5 UT_M2_PROGNAME UT_M2_USAGE UT_M2_O_OPT UT_M2_COM UT_M2_BADTAG UT_M2_MSSQUOT UT_M2_AFTRQUOT UT_M2_DUPSECT UT_M2_BADUCLSS UT_M2_USECPRFX UT_M2_MPTYUSCT UT_M2_DUPMSGTG UT_M2_TOOLONG UT_M2_LONG UT_K2_DESCR UT_K2_PROGNAME UT_K2_USAGE UT_K2_MNEM UT_K2_NKEYDEF UT_K2_DUPKEY UT_K2_NOTFOUND UT_K2_1FNAME UT_K2_VOPT UT_K2_EXCHAR UT_V2_DESCR UT_V2_PROGNAME UT_V2_USAGE UT_V2_SLINE UT_V2_SEQUAL UT_V2_SVARNAME UT_V2_SNAME UT_V2_VOPT UT_V2_1REQ UT_CB_DESCR UT_CB_PROGNAME UT_CB_USAGE UT_CB_VOPT UT_CB_MIEXT UT_CB_AEXT UT_CB_UNKNOWN UT_CB_ISCHEME UT_CB_BKFGS UT_CB_ABGS UT_CB_REC UT_CB_GUI UT_CB_CONT UT_CB_CONTFG UT_CB_AFILE UT_CB_LEFT_QUOTE UT_CB_NO_EQUAL UT_CB_EXTRA_EQ UT_CB_BAD_LHS UT_CB_BAD_RHS UT_CB_BAD_QUOTED UT_CB_FILE UT_CB_FILE_LINE UT_CB_DUP_ALIAS UT_CB_LINE_LOOP UT_CB_BAD_STYLE UT_CB_DUP_STYLE UT_CB_NO_SECT UT_CB_DUP_SCHEME DM_ERROR DM_NODATABASE DM_NOTLOGGEDON DM_ALREADY_ON DM_ARGS_NEEDED DM_LOGON_DENIED DM_BAD_ARGS DM_BAD_CMD DM_NO_MORE_ROWS DM_ABORTED DM_NO_CURSOR DM_MANY_CURSORS DM_KEYWORD + +syn keyword jamVariable6 DM_INVALID_DATE DM_COMMIT DM_ROLLBACK DM_PARSE_ERROR DM_BIND_COUNT DM_BIND_VAR DM_DESC_COL DM_FETCH DM_NO_NAME DM_END_OF_PROC DM_NOCONNECTION DM_NOTSUPPORTED DM_TRAN_PEND DM_NO_TRANSACTION DM_ALREADY_INIT DM_INIT_ERROR DM_MAX_DEPTH DM_NO_PARENT DM_NO_CHILD DM_MODALITY_NOT_FOUND DM_NATIVE_NO_SUPPORT DM_NATIVE_CANCEL DM_TM_ALREADY DM_TM_IN_PROGRESS DM_TM_CLOSE_ERROR DM_TM_BAD_MODE DM_TM_BAD_CLOSE_ACTION DM_TM_INTERNAL DM_TM_MODEL_INTERNAL DM_TM_NO_ROOT DM_TM_NO_TRANSACTION DM_TM_INITIAL_MODE DM_TM_PARENT_NAME DM_TM_BAD_MEMBER DM_TM_FLD_NAM_LEN DM_TM_NO_PARENT DM_TM_BAD_REQUEST DM_TM_CANNOT_GEN_SQL DM_TM_CANNOT_EXEC_SQL DM_TM_DBI_ERROR DM_TM_DISCARD_ALL DM_TM_DISCARD_LATEST DM_TM_CALL_ERROR DM_TM_CALL_TYPE DM_TM_HOOK_MODEL DM_TM_ROOT_NAME DM_TM_TV_INVALID DM_TM_COL_NOT_FOUND DM_TM_BAD_LINK DM_TM_HOOK_MODEL_ERROR DM_TM_ONE_ROW DM_TM_SOME_ROWS DM_TM_GENERAL DM_TM_NO_HOOK DM_TM_NOSET DM_TM_TBLNAME DM_TM_PRIMARY_KEY DM_TM_INCOMPLETE_KEY DM_TM_CMD_MODE DM_TM_NO_SUCH_CMD DM_TM_NO_SUCH_SCOPE + +syn keyword jamVariable7 DM_TM_NO_SUCH_TV DM_TM_EVENT_LOOP DM_TM_UNSUPPORTED DM_TM_NO_MODEL DM_TM_SYNCH_SV DM_TM_WRONG_FORM DM_TM_VC_FIELD DM_TM_VC_DATE DM_TM_VC_TYPE DM_TM_BAD_CONTINUE DM_JDB_OUT_OF_MEMORY DM_JDB_DUPTABLEALIAS DM_JDB_DUPCURSORNAME DM_JDB_NODB DM_JDB_BINDCOUNT DM_JDB_NO_MORE_ROWS DM_JDB_AMBIGUOUS_COLUMN_REF DM_JDB_UNRESOLVED_COLUMN_REF DM_JDB_TABLE_READ_WRITE_CONFLICT DM_JDB_SYNTAX_ERROR DM_JDB_DUP_COLUMN_ASSIGNMENT DM_JDB_NO_MSG_FILE DM_JDB_NO_MSG DM_JDB_NOT_IMPLEMENTED DM_JDB_AGGREGATE_NOT_ALLOWED DM_JDB_TYPE_MISMATCH DM_JDB_NO_CURRENT_ROW DM_JDB_DB_CORRUPT DM_JDB_BUF_OVERFLOW DM_JDB_FILE_IO_ERR DM_JDB_BAD_HANDLE DM_JDB_DUP_TNAME DM_JDB_INVALID_TABLE_OP DM_JDB_TABLE_NOT_FOUND DM_JDB_CONVERSION_FAILED DM_JDB_INVALID_COLUMN_LIST DM_JDB_TABLE_OPEN DM_JDB_BAD_INPUT DM_JDB_DATATYPE_OVERFLOW DM_JDB_DATABASE_EXISTS DM_JDB_DATABASE_OPEN DM_JDB_DUP_CNAME DM_JDB_TMPDATABASE_ERR DM_JDB_INVALID_VALUES_COUNT DM_JDB_INVALID_COLUMN_COUNT DM_JDB_MAX_RECLEN_EXCEEDED DM_JDB_END_OF_GROUP + +syn keyword jamVariable8 TP_EXC_INVALID_CLIENT_COMMAND TP_EXC_INVALID_CLIENT_OPTION TP_EXC_INVALID_COMMAND TP_EXC_INVALID_COMMAND_SYNTAX TP_EXC_INVALID_CONNECTION TP_EXC_INVALID_CONTEXT TP_EXC_INVALID_FORWARD TP_EXC_INVALID_JAM_VARIABLE_REF TP_EXC_INVALID_MONITOR_COMMAND TP_EXC_INVALID_MONITOR_OPTION TP_EXC_INVALID_OPTION TP_EXC_INVALID_OPTION_VALUE TP_EXC_INVALID_SERVER_COMMAND TP_EXC_INVALID_SERVER_OPTION TP_EXC_INVALID_SERVICE TP_EXC_INVALID_TRANSACTION TP_EXC_JIF_ACCESS_FAILED TP_EXC_JIF_LOWER_VERSION TP_EXC_LOGFILE_ERROR TP_EXC_MONITOR_ERROR TP_EXC_NO_OUTSIDE_TRANSACTION TP_EXC_NO_OUTSTANDING_CALLS TP_EXC_NO_OUTSTANDING_MESSAGE TP_EXC_NO_SERVICES_ADVERTISED TP_EXC_NO_SIGNALS TP_EXC_NONTRANSACTIONAL_SERVICE TP_EXC_NONTRANSACTIONAL_ACTION TP_EXC_OUT_OF_MEMORY TP_EXC_POSTING_FAILED TP_EXC_PERMISSION_DENIED TP_EXC_REQUEST_LIMIT TP_EXC_ROLLBACK_COMMITTED TP_EXC_ROLLBACK_FAILED TP_EXC_SERVICE_FAILED TP_EXC_SERVICE_NOT_IN_JIF TP_EXC_SERVICE_PROTOCOL_ERROR TP_EXC_SUBSCRIPTION_LIMIT + +syn keyword jamVariable9 TP_EXC_SUBSCRIPTION_MATCH TP_EXC_SVC_ADVERTISE_LIMIT TP_EXC_SVC_WORK_OUTSTANDING TP_EXC_SVCROUTINE_MISSING TP_EXC_SVRINIT_WORK_OUTSTANDING TP_EXC_TIMEOUT TP_EXC_TRANSACTION_LIMIT TP_EXC_UNLOAD_FAILED TP_EXC_UNSUPPORTED_BUFFER TP_EXC_UNSUPPORTED_BUF_W_SUBT TP_EXC_USER_ABORT TP_EXC_WORK_OUTSTANDING TP_EXC_XA_CLOSE_FAILED TP_EXC_XA_OPEN_FAILED TP_EXC_QUEUE_BAD_MSGID TP_EXC_QUEUE_BAD_NAMESPACE TP_EXC_QUEUE_BAD_QUEUE TP_EXC_QUEUE_CANT_START_TRAN TP_EXC_QUEUE_FULL TP_EXC_QUEUE_MSG_IN_USE TP_EXC_QUEUE_NO_MSG TP_EXC_QUEUE_NOT_IN_QSPACE TP_EXC_QUEUE_RSRC_NOT_OPEN TP_EXC_QUEUE_SPACE_NOT_IN_JIF TP_EXC_QUEUE_TRAN_ABORTED TP_EXC_QUEUE_TRAN_ABSENT TP_EXC_QUEUE_UNEXPECTED TP_EXC_DCE_LOGIN_REQUIRED TP_EXC_ENC_CELL_NAME_REQUIRED TP_EXC_ENC_CONN_INFO_DIFFS TP_EXC_ENC_SVC_REGISTRY_ERROR TP_INVALID_START_ROUTINE TP_JIF_NOT_FOUND TP_JIF_OPEN_ERROR TP_NO_JIF TP_NO_MONITORS_ERROR TP_NO_SESSIONS_ERROR TP_NO_START_ROUTINE TP_ADV_SERVICE TP_ADV_SERVICE_IN_GROUP TP_PRE_SVCHDL_WINOPEN_FAILED + +syn keyword jamVariable10 PV_YES PV_NO TRUE FALSE TM_TRAN_NAME + +" jamCommentGroup allows adding matches for special things in comments +syn cluster jamCommentGroup contains=jamTodo + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match jamSpecial contained "\\\(x\x\+\|\o\{1,3}\|.\|$\)" +if !exists("c_no_utf") + syn match jamSpecial contained "\\\(u\x\{4}\|U\x\{8}\)" +endif +if exists("c_no_cformat") + syn region jamString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial +else + syn match jamFormat "%\(\d\+\$\)\=[-+' #0*]*\(\d*\|\*\|\*\d\+\$\)\(\.\(\d*\|\*\|\*\d\+\$\)\)\=\([hlL]\|ll\)\=\([diuoxXfeEgGcCsSpn]\|\[\^\=.[^]]*\]\)" contained + syn match jamFormat "%%" contained + syn region jamString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,cFormat + hi link jamFormat jamSpecial +endif +syn match jamCharacter "L\='[^\\]'" +syn match jamCharacter "L'[^']*'" contains=jamSpecial +syn match jamSpecialError "L\='\\[^'\"?\\abfnrtv]'" +syn match jamSpecialCharacter "L\='\\['\"?\\abfnrtv]'" +syn match jamSpecialCharacter "L\='\\\o\{1,3}'" +syn match jamSpecialCharacter "'\\x\x\{1,2}'" +syn match jamSpecialCharacter "L'\\x\x\+'" + +"catch errors caused by wrong parenthesis and brackets +syn cluster jamParenGroup contains=jamParenError,jamIncluded,jamSpecial,@jamCommentGroup,jamUserCont,jamUserLabel,jamBitField,jamCommentSkip,jamOctalZero,jamCppOut,jamCppOut2,jamCppSkip,jamFormat,jamNumber,jamFloat,jamOctal,jamOctalError,jamNumbersCom + +syn region jamParen transparent start='(' end=')' contains=ALLBUT,@jamParenGroup,jamErrInBracket +syn match jamParenError "[\])]" +syn match jamErrInParen contained "[\]{}]" +syn region jamBracket transparent start='\[' end=']' contains=ALLBUT,@jamParenGroup,jamErrInParen +syn match jamErrInBracket contained "[);{}]" + +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match jamNumbers transparent "\<\d\|\,\d" contains=jamNumber,jamFloat,jamOctalError,jamOctal +" Same, but without octal error (for comments) +syn match jamNumbersCom contained transparent "\<\d\|\,\d" contains=jamNumber,jamFloat,jamOctal +syn match jamNumber contained "\d\+\(u\=l\{0,2}\|ll\=u\)\>" +"hex number +syn match jamNumber contained "0x\x\+\(u\=l\{0,2}\|ll\=u\)\>" +" Flag the first zero of an octal number as something special +syn match jamOctal contained "0\o\+\(u\=l\{0,2}\|ll\=u\)\>" contains=cOctalZero +syn match jamOctalZero contained "\<0" +syn match jamFloat contained "\d\+f" +"floating point number, with dot, optional exponent +syn match jamFloat contained "\d\+\,\d*\(e[-+]\=\d\+\)\=[fl]\=" +"floating point number, starting with a dot, optional exponent +syn match jamFloat contained "\,\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match jamFloat contained "\d\+e[-+]\=\d\+[fl]\=\>" +" flag an octal number with wrong digits +syn match jamOctalError contained "0\o*[89]\d*" +syn case match + +syntax match jamOperator1 "\#\#" +syntax match jamOperator6 "/" +syntax match jamOperator2 "+" +syntax match jamOperator3 "*" +syntax match jamOperator4 "-" +syntax match jamOperator5 "|" +syntax match jamOperator6 "/" +syntax match jamOperator7 "&" +syntax match jamOperator8 ":" +syntax match jamOperator9 "<" +syntax match jamOperator10 ">" +syntax match jamOperator11 "!" +syntax match jamOperator12 "%" +syntax match jamOperator13 "^" +syntax match jamOperator14 "@" + +syntax match jamCommentL "//" + +if exists("jam_comment_strings") + " A comment can contain jamString, jamCharacter and jamNumber. + " But a "*/" inside a jamString in a jamComment DOES end the comment! So we + " need to use a special type of jamString: jamCommentString, which also ends on + " "*/", and sees a "*" at the start of the line as comment again. + " Unfortunately this doesn't very well work for // type of comments :-( + syntax match jamCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region jamCommentString contained start=+L\="+ skip=+\\\\\|\\"+ end=+"+ end=+\*/+me=s-1 contains=jamSpecial,jamCommentSkip + syntax region jamComment2String contained start=+L\="+ skip=+\\\\\|\\"+ end=+"+ end="$" contains=jamSpecial + syntax region jamCommentL start="//" skip="\\$" end="$" keepend contains=@jamCommentGroup,jamComment2String,jamCharacter,jamNumbersCom,jamSpaceError + syntax region jamCommentL2 start="^#\|^\s\+\#" skip="\\$" end="$" keepend contains=@jamCommentGroup,jamComment2String,jamCharacter,jamNumbersCom,jamSpaceError + syntax region jamComment start="/\*" end="\*/" contains=@jamCommentGroup,jamCommentString,jamCharacter,jamNumbersCom,jamSpaceError +else + syn region jamCommentL start="//" skip="\\$" end="$" keepend contains=@jamCommentGroup,jamSpaceError + syn region jamCommentL2 start="^\#\|^\s\+\#" skip="\\$" end="$" keepend contains=@jamCommentGroup,jamSpaceError + syn region jamComment start="/\*" end="\*/" contains=@jamCommentGroup,jamSpaceError +endif + +" keep a // comment separately, it terminates a preproc. conditional +syntax match jamCommentError "\*/" + +syntax match jamOperator3Error "*/" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link jamCommentL jamComment +hi def link jamCommentL2 jamComment +hi def link jamOperator3Error jamError +hi def link jamConditional Conditional +hi def link jamRepeat Repeat +hi def link jamCharacter Character +hi def link jamSpecialCharacter jamSpecial +hi def link jamNumber Number +hi def link jamParenError jamError +hi def link jamErrInParen jamError +hi def link jamErrInBracket jamError +hi def link jamCommentError jamError +hi def link jamSpaceError jamError +hi def link jamSpecialError jamError +hi def link jamOperator1 jamOperator +hi def link jamOperator2 jamOperator +hi def link jamOperator3 jamOperator +hi def link jamOperator4 jamOperator +hi def link jamOperator5 jamOperator +hi def link jamOperator6 jamOperator +hi def link jamOperator7 jamOperator +hi def link jamOperator8 jamOperator +hi def link jamOperator9 jamOperator +hi def link jamOperator10 jamOperator +hi def link jamOperator11 jamOperator +hi def link jamOperator12 jamOperator +hi def link jamOperator13 jamOperator +hi def link jamOperator14 jamOperator +hi def link jamError Error +hi def link jamStatement Statement +hi def link jamPreCondit PreCondit +hi def link jamCommentError jamError +hi def link jamCommentString jamString +hi def link jamComment2String jamString +hi def link jamCommentSkip jamComment +hi def link jamString String +hi def link jamComment Comment +hi def link jamSpecial SpecialChar +hi def link jamTodo Todo +hi def link jamCppSkip jamCppOut +hi def link jamCppOut2 jamCppOut +hi def link jamCppOut Comment +hi def link jamDBState1 Identifier +hi def link jamDBState2 Identifier +hi def link jamSQLState1 jamSQL +hi def link jamSQLState2 jamSQL +hi def link jamLibFunc1 jamLibFunc +hi def link jamLibFunc2 jamLibFunc +hi def link jamLibFunc3 jamLibFunc +hi def link jamLibFunc4 jamLibFunc +hi def link jamLibFunc5 jamLibFunc +hi def link jamLibFunc6 jamLibFunc +hi def link jamLibFunc7 jamLibFunc +hi def link jamLibFunc8 jamLibFunc +hi def link jamLibFunc9 jamLibFunc +hi def link jamVariable1 jamVariablen +hi def link jamVariable2 jamVariablen +hi def link jamVariable3 jamVariablen +hi def link jamVariable4 jamVariablen +hi def link jamVariable5 jamVariablen +hi def link jamVariable6 jamVariablen +hi def link jamVariable7 jamVariablen +hi def link jamVariable8 jamVariablen +hi def link jamVariable9 jamVariablen +hi def link jamVariable10 jamVariablen +hi def link jamVariablen Constant +hi def link jamSQL Type +hi def link jamLibFunc PreProc +hi def link jamOperator Special + + +let b:current_syntax = "jam" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 + +endif diff --git a/syntax/jargon.vim b/syntax/jargon.vim new file mode 100644 index 0000000..ff84783 --- /dev/null +++ b/syntax/jargon.vim @@ -0,0 +1,27 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Jargon File +" Maintainer: +" Last Change: 2001 May 26 +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match jargonChaptTitle /:[^:]*:/ +syn match jargonEmailAddr /[^<@ ^I]*@[^ ^I>]*/ +syn match jargonUrl +\(http\|ftp\)://[^\t )"]*+ +syn match jargonMark /{[^}]*}/ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link jargonChaptTitle Title +hi def link jargonEmailAddr Comment +hi def link jargonUrl Comment +hi def link jargonMark Label + +let b:current_syntax = "jargon" + +endif diff --git a/syntax/java.vim b/syntax/java.vim new file mode 100644 index 0000000..520f552 --- /dev/null +++ b/syntax/java.vim @@ -0,0 +1,346 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Java +" Maintainer: Claudio Fleiner +" URL: http://www.fleiner.com/vim/syntax/java.vim +" Last Change: 2015 March 01 + +" Please check :help java.vim for comments on some of the options available. + +" quit when a syntax file was already loaded +if !exists("main_syntax") + if exists("b:current_syntax") + finish + endif + " we define it here so that included files can test for it + let main_syntax='java' + syn region javaFold start="{" end="}" transparent fold +endif + +let s:cpo_save = &cpo +set cpo&vim + +" some characters that cannot be in a java program (outside a string) +syn match javaError "[\\@`]" +syn match javaError "<<<\|\.\.\|=>\|||=\|&&=\|\*\/" + +syn match javaOK "\.\.\." + +" use separate name so that it can be deleted in javacc.vim +syn match javaError2 "#\|=<" +hi def link javaError2 javaError + + + +" keyword definitions +syn keyword javaExternal native package +syn match javaExternal "\\(\s\+static\>\)\?" +syn keyword javaError goto const +syn keyword javaConditional if else switch +syn keyword javaRepeat while for do +syn keyword javaBoolean true false +syn keyword javaConstant null +syn keyword javaTypedef this super +syn keyword javaOperator new instanceof +syn keyword javaType boolean char byte short int long float double +syn keyword javaType void +syn keyword javaStatement return +syn keyword javaStorageClass static synchronized transient volatile final strictfp serializable +syn keyword javaExceptions throw try catch finally +syn keyword javaAssert assert +syn keyword javaMethodDecl synchronized throws +syn keyword javaClassDecl extends implements interface +" to differentiate the keyword class from MyClass.class we use a match here +syn match javaTypedef "\.\s*\"ms=s+1 +syn keyword javaClassDecl enum +syn match javaClassDecl "^class\>" +syn match javaClassDecl "[^.]\s*\"ms=s+1 +syn match javaAnnotation "@\([_$a-zA-Z][_$a-zA-Z0-9]*\.\)*[_$a-zA-Z][_$a-zA-Z0-9]*\>\(([^)]*)\)\=" contains=javaString +syn match javaClassDecl "@interface\>" +syn keyword javaBranch break continue nextgroup=javaUserLabelRef skipwhite +syn match javaUserLabelRef "\k\+" contained +syn match javaVarArg "\.\.\." +syn keyword javaScopeDecl public protected private abstract + +if exists("java_highlight_java_lang_ids") + let java_highlight_all=1 +endif +if exists("java_highlight_all") || exists("java_highlight_java") || exists("java_highlight_java_lang") + " java.lang.* + syn match javaLangClass "\" + syn keyword javaR_JavaLang NegativeArraySizeException ArrayStoreException IllegalStateException RuntimeException IndexOutOfBoundsException UnsupportedOperationException ArrayIndexOutOfBoundsException ArithmeticException ClassCastException EnumConstantNotPresentException StringIndexOutOfBoundsException IllegalArgumentException IllegalMonitorStateException IllegalThreadStateException NumberFormatException NullPointerException TypeNotPresentException SecurityException + syn cluster javaTop add=javaR_JavaLang + syn cluster javaClasses add=javaR_JavaLang + hi def link javaR_JavaLang javaR_Java + syn keyword javaC_JavaLang Process RuntimePermission StringKeySet CharacterData01 Class ThreadLocal ThreadLocalMap CharacterData0E Package Character StringCoding Long ProcessImpl ProcessEnvironment Short AssertionStatusDirectives 1PackageInfoProxy UnicodeBlock InheritableThreadLocal AbstractStringBuilder StringEnvironment ClassLoader ConditionalSpecialCasing CharacterDataPrivateUse StringBuffer StringDecoder Entry StringEntry WrappedHook StringBuilder StrictMath State ThreadGroup Runtime CharacterData02 MethodArray Object CharacterDataUndefined Integer Gate Boolean Enum Variable Subset StringEncoder Void Terminator CharsetSD IntegerCache CharacterCache Byte CharsetSE Thread SystemClassLoaderAction CharacterDataLatin1 StringValues StackTraceElement Shutdown ShortCache String ConverterSD ByteCache Lock EnclosingMethodInfo Math Float Value Double SecurityManager LongCache ProcessBuilder StringEntrySet Compiler Number UNIXProcess ConverterSE ExternalData CaseInsensitiveComparator CharacterData00 NativeLibrary + syn cluster javaTop add=javaC_JavaLang + syn cluster javaClasses add=javaC_JavaLang + hi def link javaC_JavaLang javaC_Java + syn keyword javaE_JavaLang IncompatibleClassChangeError InternalError UnknownError ClassCircularityError AssertionError ThreadDeath IllegalAccessError NoClassDefFoundError ClassFormatError UnsupportedClassVersionError NoSuchFieldError VerifyError ExceptionInInitializerError InstantiationError LinkageError NoSuchMethodError Error UnsatisfiedLinkError StackOverflowError AbstractMethodError VirtualMachineError OutOfMemoryError + syn cluster javaTop add=javaE_JavaLang + syn cluster javaClasses add=javaE_JavaLang + hi def link javaE_JavaLang javaE_Java + syn keyword javaX_JavaLang CloneNotSupportedException Exception NoSuchMethodException IllegalAccessException NoSuchFieldException Throwable InterruptedException ClassNotFoundException InstantiationException + syn cluster javaTop add=javaX_JavaLang + syn cluster javaClasses add=javaX_JavaLang + hi def link javaX_JavaLang javaX_Java + + hi def link javaR_Java javaR_ + hi def link javaC_Java javaC_ + hi def link javaE_Java javaE_ + hi def link javaX_Java javaX_ + hi def link javaX_ javaExceptions + hi def link javaR_ javaExceptions + hi def link javaE_ javaExceptions + hi def link javaC_ javaConstant + + syn keyword javaLangObject clone equals finalize getClass hashCode + syn keyword javaLangObject notify notifyAll toString wait + hi def link javaLangObject javaConstant + syn cluster javaTop add=javaLangObject +endif + +if filereadable(expand(":p:h")."/javaid.vim") + source :p:h/javaid.vim +endif + +if exists("java_space_errors") + if !exists("java_no_trail_space_error") + syn match javaSpaceError "\s\+$" + endif + if !exists("java_no_tab_space_error") + syn match javaSpaceError " \+\t"me=e-1 + endif +endif + +syn region javaLabelRegion transparent matchgroup=javaLabel start="\" matchgroup=NONE end=":" contains=javaNumber,javaCharacter,javaString +syn match javaUserLabel "^\s*[_$a-zA-Z][_$a-zA-Z0-9_]*\s*:"he=e-1 contains=javaLabel +syn keyword javaLabel default + +" highlighting C++ keywords as errors removed, too many people find it +" annoying. Was: if !exists("java_allow_cpp_keywords") + +" The following cluster contains all java groups except the contained ones +syn cluster javaTop add=javaExternal,javaError,javaError,javaBranch,javaLabelRegion,javaLabel,javaConditional,javaRepeat,javaBoolean,javaConstant,javaTypedef,javaOperator,javaType,javaType,javaStatement,javaStorageClass,javaAssert,javaExceptions,javaMethodDecl,javaClassDecl,javaClassDecl,javaClassDecl,javaScopeDecl,javaError,javaError2,javaUserLabel,javaLangObject,javaAnnotation,javaVarArg + + +" Comments +syn keyword javaTodo contained TODO FIXME XXX +if exists("java_comment_strings") + syn region javaCommentString contained start=+"+ end=+"+ end=+$+ end=+\*/+me=s-1,he=s-1 contains=javaSpecial,javaCommentStar,javaSpecialChar,@Spell + syn region javaComment2String contained start=+"+ end=+$\|"+ contains=javaSpecial,javaSpecialChar,@Spell + syn match javaCommentCharacter contained "'\\[^']\{1,6\}'" contains=javaSpecialChar + syn match javaCommentCharacter contained "'\\''" contains=javaSpecialChar + syn match javaCommentCharacter contained "'[^\\]'" + syn cluster javaCommentSpecial add=javaCommentString,javaCommentCharacter,javaNumber + syn cluster javaCommentSpecial2 add=javaComment2String,javaCommentCharacter,javaNumber +endif +syn region javaComment start="/\*" end="\*/" contains=@javaCommentSpecial,javaTodo,@Spell +syn match javaCommentStar contained "^\s*\*[^/]"me=e-1 +syn match javaCommentStar contained "^\s*\*$" +syn match javaLineComment "//.*" contains=@javaCommentSpecial2,javaTodo,@Spell +hi def link javaCommentString javaString +hi def link javaComment2String javaString +hi def link javaCommentCharacter javaCharacter + +syn cluster javaTop add=javaComment,javaLineComment + +if !exists("java_ignore_javadoc") && main_syntax != 'jsp' + syntax case ignore + " syntax coloring for javadoc comments (HTML) + syntax include @javaHtml :p:h/html.vim + unlet b:current_syntax + " HTML enables spell checking for all text that is not in a syntax item. This + " is wrong for Java (all identifiers would be spell-checked), so it's undone + " here. + syntax spell default + + syn region javaDocComment start="/\*\*" end="\*/" keepend contains=javaCommentTitle,@javaHtml,javaDocTags,javaDocSeeTag,javaTodo,@Spell + syn region javaCommentTitle contained matchgroup=javaDocComment start="/\*\*" matchgroup=javaCommentTitle keepend end="\.$" end="\.[ \t\r<&]"me=e-1 end="[^{]@"me=s-2,he=s-1 end="\*/"me=s-1,he=s-1 contains=@javaHtml,javaCommentStar,javaTodo,@Spell,javaDocTags,javaDocSeeTag + + syn region javaDocTags contained start="{@\(code\|link\|linkplain\|inherit[Dd]oc\|doc[rR]oot\|value\)" end="}" + syn match javaDocTags contained "@\(param\|exception\|throws\|since\)\s\+\S\+" contains=javaDocParam + syn match javaDocParam contained "\s\S\+" + syn match javaDocTags contained "@\(version\|author\|return\|deprecated\|serial\|serialField\|serialData\)\>" + syn region javaDocSeeTag contained matchgroup=javaDocTags start="@see\s\+" matchgroup=NONE end="\_."re=e-1 contains=javaDocSeeTagParam + syn match javaDocSeeTagParam contained @"\_[^"]\+"\|\|\(\k\|\.\)*\(#\k\+\((\_[^)]\+)\)\=\)\=@ extend + syntax case match +endif + +" match the special comment /**/ +syn match javaComment "/\*\*/" + +" Strings and constants +syn match javaSpecialError contained "\\." +syn match javaSpecialCharError contained "[^']" +syn match javaSpecialChar contained "\\\([4-9]\d\|[0-3]\d\d\|[\"\\'ntbrf]\|u\x\{4\}\)" +syn region javaString start=+"+ end=+"+ end=+$+ contains=javaSpecialChar,javaSpecialError,@Spell +" next line disabled, it can cause a crash for a long line +"syn match javaStringError +"\([^"\\]\|\\.\)*$+ +syn match javaCharacter "'[^']*'" contains=javaSpecialChar,javaSpecialCharError +syn match javaCharacter "'\\''" contains=javaSpecialChar +syn match javaCharacter "'[^\\]'" +syn match javaNumber "\<\(0[bB][0-1]\+\|0[0-7]*\|0[xX]\x\+\|\d\(\d\|_\d\)*\)[lL]\=\>" +syn match javaNumber "\(\<\d\(\d\|_\d\)*\.\(\d\(\d\|_\d\)*\)\=\|\.\d\(\d\|_\d\)*\)\([eE][-+]\=\d\(\d\|_\d\)*\)\=[fFdD]\=" +syn match javaNumber "\<\d\(\d\|_\d\)*[eE][-+]\=\d\(\d\|_\d\)*[fFdD]\=\>" +syn match javaNumber "\<\d\(\d\|_\d\)*\([eE][-+]\=\d\(\d\|_\d\)*\)\=[fFdD]\>" + +" unicode characters +syn match javaSpecial "\\u\d\{4\}" + +syn cluster javaTop add=javaString,javaCharacter,javaNumber,javaSpecial,javaStringError + +if exists("java_highlight_functions") + if java_highlight_functions == "indent" + syn match javaFuncDef "^\(\t\| \{8\}\)[_$a-zA-Z][_$a-zA-Z0-9_. \[\]<>]*([^-+*/]*)" contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation + syn region javaFuncDef start=+^\(\t\| \{8\}\)[$_a-zA-Z][$_a-zA-Z0-9_. \[\]<>]*([^-+*/]*,\s*+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation + syn match javaFuncDef "^ [$_a-zA-Z][$_a-zA-Z0-9_. \[\]<>]*([^-+*/]*)" contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation + syn region javaFuncDef start=+^ [$_a-zA-Z][$_a-zA-Z0-9_. \[\]<>]*([^-+*/]*,\s*+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,@javaClasses,javaAnnotation + else + " This line catches method declarations at any indentation>0, but it assumes + " two things: + " 1. class names are always capitalized (ie: Button) + " 2. method names are never capitalized (except constructors, of course) + "syn region javaFuncDef start=+^\s\+\(\(public\|protected\|private\|static\|abstract\|final\|native\|synchronized\)\s\+\)*\(\(void\|boolean\|char\|byte\|short\|int\|long\|float\|double\|\([A-Za-z_][A-Za-z0-9_$]*\.\)*[A-Z][A-Za-z0-9_$]*\)\(<[^>]*>\)\=\(\[\]\)*\s\+[a-z][A-Za-z0-9_$]*\|[A-Z][A-Za-z0-9_$]*\)\s*([^0-9]+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,javaComment,javaLineComment,@javaClasses + syn region javaFuncDef start=+^\s\+\(\(public\|protected\|private\|static\|abstract\|final\|native\|synchronized\)\s\+\)*\(<.*>\s\+\)\?\(\(void\|boolean\|char\|byte\|short\|int\|long\|float\|double\|\([A-Za-z_][A-Za-z0-9_$]*\.\)*[A-Z][A-Za-z0-9_$]*\)\(<[^(){}]*>\)\=\(\[\]\)*\s\+[a-z][A-Za-z0-9_$]*\|[A-Z][A-Za-z0-9_$]*\)\s*(+ end=+)+ contains=javaScopeDecl,javaType,javaStorageClass,javaComment,javaLineComment,@javaClasses,javaAnnotation + endif + syn match javaLambdaDef "[a-zA-Z_][a-zA-Z0-9_]*\s*->" + syn match javaBraces "[{}]" + syn cluster javaTop add=javaFuncDef,javaBraces,javaLambdaDef +endif + +if exists("java_highlight_debug") + + " Strings and constants + syn match javaDebugSpecial contained "\\\d\d\d\|\\." + syn region javaDebugString contained start=+"+ end=+"+ contains=javaDebugSpecial + syn match javaDebugStringError +"\([^"\\]\|\\.\)*$+ + syn match javaDebugCharacter contained "'[^\\]'" + syn match javaDebugSpecialCharacter contained "'\\.'" + syn match javaDebugSpecialCharacter contained "'\\''" + syn match javaDebugNumber contained "\<\(0[0-7]*\|0[xX]\x\+\|\d\+\)[lL]\=\>" + syn match javaDebugNumber contained "\(\<\d\+\.\d*\|\.\d\+\)\([eE][-+]\=\d\+\)\=[fFdD]\=" + syn match javaDebugNumber contained "\<\d\+[eE][-+]\=\d\+[fFdD]\=\>" + syn match javaDebugNumber contained "\<\d\+\([eE][-+]\=\d\+\)\=[fFdD]\>" + syn keyword javaDebugBoolean contained true false + syn keyword javaDebugType contained null this super + syn region javaDebugParen start=+(+ end=+)+ contained contains=javaDebug.*,javaDebugParen + + " to make this work you must define the highlighting for these groups + syn match javaDebug "\\[\], \t]*)\s*->" + " needs to be defined after the parenthesis error catcher to work +endif + +if !exists("java_minlines") + let java_minlines = 10 +endif +exec "syn sync ccomment javaComment minlines=" . java_minlines + +" The default highlighting. +hi def link javaLambdaDef Function +hi def link javaFuncDef Function +hi def link javaVarArg Function +hi def link javaBraces Function +hi def link javaBranch Conditional +hi def link javaUserLabelRef javaUserLabel +hi def link javaLabel Label +hi def link javaUserLabel Label +hi def link javaConditional Conditional +hi def link javaRepeat Repeat +hi def link javaExceptions Exception +hi def link javaAssert Statement +hi def link javaStorageClass StorageClass +hi def link javaMethodDecl javaStorageClass +hi def link javaClassDecl javaStorageClass +hi def link javaScopeDecl javaStorageClass +hi def link javaBoolean Boolean +hi def link javaSpecial Special +hi def link javaSpecialError Error +hi def link javaSpecialCharError Error +hi def link javaString String +hi def link javaCharacter Character +hi def link javaSpecialChar SpecialChar +hi def link javaNumber Number +hi def link javaError Error +hi def link javaStringError Error +hi def link javaStatement Statement +hi def link javaOperator Operator +hi def link javaComment Comment +hi def link javaDocComment Comment +hi def link javaLineComment Comment +hi def link javaConstant Constant +hi def link javaTypedef Typedef +hi def link javaTodo Todo +hi def link javaAnnotation PreProc + +hi def link javaCommentTitle SpecialComment +hi def link javaDocTags Special +hi def link javaDocParam Function +hi def link javaDocSeeTagParam Function +hi def link javaCommentStar javaComment + +hi def link javaType Type +hi def link javaExternal Include + +hi def link htmlComment Special +hi def link htmlCommentPart Special +hi def link javaSpaceError Error + +let b:current_syntax = "java" + +if main_syntax == 'java' + unlet main_syntax +endif + +let b:spell_options="contained" +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/javacc.vim b/syntax/javacc.vim new file mode 100644 index 0000000..93b3a9f --- /dev/null +++ b/syntax/javacc.vim @@ -0,0 +1,69 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: JavaCC, a Java Compiler Compiler written by JavaSoft +" Maintainer: Claudio Fleiner +" URL: http://www.fleiner.com/vim/syntax/javacc.vim +" Last Change: 2012 Oct 05 + +" Uses java.vim, and adds a few special things for JavaCC Parser files. +" Those files usually have the extension *.jj + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" source the java.vim file +runtime! syntax/java.vim +unlet b:current_syntax + +"remove catching errors caused by wrong parenthesis (does not work in javacc +"files) (first define them in case they have not been defined in java) +syn match javaParen "--" +syn match javaParenError "--" +syn match javaInParen "--" +syn match javaError2 "--" +syn clear javaParen +syn clear javaParenError +syn clear javaInParen +syn clear javaError2 + +" remove function definitions (they look different) (first define in +" in case it was not defined in java.vim) +"syn match javaFuncDef "--" +syn clear javaFuncDef +syn match javaFuncDef "[$_a-zA-Z][$_a-zA-Z0-9_. \[\]]*([^-+*/()]*)[ \t]*:" contains=javaType + +syn keyword javaccPackages options DEBUG_PARSER DEBUG_LOOKAHEAD DEBUG_TOKEN_MANAGER +syn keyword javaccPackages COMMON_TOKEN_ACTION IGNORE_CASE CHOICE_AMBIGUITY_CHECK +syn keyword javaccPackages OTHER_AMBIGUITY_CHECK STATIC LOOKAHEAD ERROR_REPORTING +syn keyword javaccPackages USER_TOKEN_MANAGER USER_CHAR_STREAM JAVA_UNICODE_ESCAPE +syn keyword javaccPackages UNICODE_INPUT JDK_VERSION +syn match javaccPackages "PARSER_END([^)]*)" +syn match javaccPackages "PARSER_BEGIN([^)]*)" +syn match javaccSpecToken "" +" the dot is necessary as otherwise it will be matched as a keyword. +syn match javaccSpecToken ".LOOKAHEAD("ms=s+1,me=e-1 +syn match javaccToken "<[^> \t]*>" +syn keyword javaccActionToken TOKEN SKIP MORE SPECIAL_TOKEN +syn keyword javaccError DEBUG IGNORE_IN_BNF + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link javaccSpecToken Statement +hi def link javaccActionToken Type +hi def link javaccPackages javaScopeDecl +hi def link javaccToken String +hi def link javaccError Error + +let b:current_syntax = "javacc" +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/javascript.vim b/syntax/javascript.vim index 2461833..76735fc 100644 --- a/syntax/javascript.vim +++ b/syntax/javascript.vim @@ -1,3 +1,132 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: JavaScript +" Maintainer: Claudio Fleiner +" Updaters: Scott Shattuck (ss) +" URL: http://www.fleiner.com/vim/syntax/javascript.vim +" Changes: (ss) added keywords, reserved words, and other identifiers +" (ss) repaired several quoting and grouping glitches +" (ss) fixed regex parsing issue with multiple qualifiers [gi] +" (ss) additional factoring of keywords, globals, and members +" Last Change: 2012 Oct 05 +" 2013 Jun 12: adjusted javaScriptRegexpString (Kevin Locke) + +" tuning parameters: +" unlet javaScript_fold + +if !exists("main_syntax") + " quit when a syntax file was already loaded + if exists("b:current_syntax") + finish + endif + let main_syntax = 'javascript' +elseif exists("b:current_syntax") && b:current_syntax == "javascript" + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + + +syn keyword javaScriptCommentTodo TODO FIXME XXX TBD contained +syn match javaScriptLineComment "\/\/.*" contains=@Spell,javaScriptCommentTodo +syn match javaScriptCommentSkip "^[ \t]*\*\($\|[ \t]\+\)" +syn region javaScriptComment start="/\*" end="\*/" contains=@Spell,javaScriptCommentTodo +syn match javaScriptSpecial "\\\d\d\d\|\\." +syn region javaScriptStringD start=+"+ skip=+\\\\\|\\"+ end=+"\|$+ contains=javaScriptSpecial,@htmlPreproc +syn region javaScriptStringS start=+'+ skip=+\\\\\|\\'+ end=+'\|$+ contains=javaScriptSpecial,@htmlPreproc + +syn match javaScriptSpecialCharacter "'\\.'" +syn match javaScriptNumber "-\=\<\d\+L\=\>\|0[xX][0-9a-fA-F]\+\>" +syn region javaScriptRegexpString start=+/[^/*]+me=e-1 skip=+\\\\\|\\/+ end=+/[gim]\{0,2\}\s*$+ end=+/[gim]\{0,2\}\s*[;.,)\]}]+me=e-1 contains=@htmlPreproc oneline + +syn keyword javaScriptConditional if else switch +syn keyword javaScriptRepeat while for do in +syn keyword javaScriptBranch break continue +syn keyword javaScriptOperator new delete instanceof typeof +syn keyword javaScriptType Array Boolean Date Function Number Object String RegExp +syn keyword javaScriptStatement return with +syn keyword javaScriptBoolean true false +syn keyword javaScriptNull null undefined +syn keyword javaScriptIdentifier arguments this var let +syn keyword javaScriptLabel case default +syn keyword javaScriptException try catch finally throw +syn keyword javaScriptMessage alert confirm prompt status +syn keyword javaScriptGlobal self window top parent +syn keyword javaScriptMember document event location +syn keyword javaScriptDeprecated escape unescape +syn keyword javaScriptReserved abstract boolean byte char class const debugger double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile + +if exists("javaScript_fold") + syn match javaScriptFunction "\" + syn region javaScriptFunctionFold start="\.*[^};]$" end="^\z1}.*$" transparent fold keepend + + syn sync match javaScriptSync grouphere javaScriptFunctionFold "\" + syn sync match javaScriptSync grouphere NONE "^}" + + setlocal foldmethod=syntax + setlocal foldtext=getline(v:foldstart) +else + syn keyword javaScriptFunction function + syn match javaScriptBraces "[{}\[\]]" + syn match javaScriptParens "[()]" +endif + +syn sync fromstart +syn sync maxlines=100 + +if main_syntax == "javascript" + syn sync ccomment javaScriptComment +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link javaScriptComment Comment +hi def link javaScriptLineComment Comment +hi def link javaScriptCommentTodo Todo +hi def link javaScriptSpecial Special +hi def link javaScriptStringS String +hi def link javaScriptStringD String +hi def link javaScriptCharacter Character +hi def link javaScriptSpecialCharacter javaScriptSpecial +hi def link javaScriptNumber javaScriptValue +hi def link javaScriptConditional Conditional +hi def link javaScriptRepeat Repeat +hi def link javaScriptBranch Conditional +hi def link javaScriptOperator Operator +hi def link javaScriptType Type +hi def link javaScriptStatement Statement +hi def link javaScriptFunction Function +hi def link javaScriptBraces Function +hi def link javaScriptError Error +hi def link javaScrParenError javaScriptError +hi def link javaScriptNull Keyword +hi def link javaScriptBoolean Boolean +hi def link javaScriptRegexpString String + +hi def link javaScriptIdentifier Identifier +hi def link javaScriptLabel Label +hi def link javaScriptException Exception +hi def link javaScriptMessage Keyword +hi def link javaScriptGlobal Keyword +hi def link javaScriptMember Keyword +hi def link javaScriptDeprecated Exception +hi def link javaScriptReserved Keyword +hi def link javaScriptDebug Debug +hi def link javaScriptConstant Label + + +let b:current_syntax = "javascript" +if main_syntax == 'javascript' + unlet main_syntax +endif +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'javascript') == -1 " Vim syntax file diff --git a/syntax/jess.vim b/syntax/jess.vim new file mode 100644 index 0000000..90d6ef2 --- /dev/null +++ b/syntax/jess.vim @@ -0,0 +1,148 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Jess +" Maintainer: Paul Baleme +" Last change: September 14, 2000 +" Based on lisp.vim by : Dr. Charles E. Campbell, Jr. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=42,43,45,47-58,60-62,64-90,97-122,_ + +" Lists +syn match jessSymbol ![^()'`,"; \t]\+! contained +syn match jessBarSymbol !|..\{-}|! contained +syn region jessList matchgroup=Delimiter start="(" skip="|.\{-}|" matchgroup=Delimiter end=")" contains=jessAtom,jessBQList,jessConcat,jessDeclaration,jessList,jessNumber,jessSymbol,jessSpecial,jessFunc,jessKey,jessAtomMark,jessString,jessComment,jessBarSymbol,jessAtomBarSymbol,jessVar +syn region jessBQList matchgroup=PreProc start="`(" skip="|.\{-}|" matchgroup=PreProc end=")" contains=jessAtom,jessBQList,jessConcat,jessDeclaration,jessList,jessNumber,jessSpecial,jessSymbol,jessFunc,jessKey,jessVar,jessAtomMark,jessString,jessComment,jessBarSymbol,jessAtomBarSymbol + +" Atoms +syn match jessAtomMark "'" +syn match jessAtom "'("me=e-1 contains=jessAtomMark nextgroup=jessAtomList +syn match jessAtom "'[^ \t()]\+" contains=jessAtomMark +syn match jessAtomBarSymbol !'|..\{-}|! contains=jessAtomMark +syn region jessAtom start=+'"+ skip=+\\"+ end=+"+ +syn region jessAtomList matchgroup=Special start="(" skip="|.\{-}|" matchgroup=Special end=")" contained contains=jessAtomList,jessAtomNmbr0,jessString,jessComment,jessAtomBarSymbol +syn match jessAtomNmbr "\<[0-9]\+" contained + +" Standard jess Functions and Macros +syn keyword jessFunc * + ** - / < > <= >= <> = +syn keyword jessFunc long longp +syn keyword jessFunc abs agenda and +syn keyword jessFunc assert assert-string bag +syn keyword jessFunc batch bind bit-and +syn keyword jessFunc bit-not bit-or bload +syn keyword jessFunc bsave build call +syn keyword jessFunc clear clear-storage close +syn keyword jessFunc complement$ context count-query-results +syn keyword jessFunc create$ +syn keyword jessFunc delete$ div +syn keyword jessFunc do-backward-chaining e +syn keyword jessFunc engine eq eq* +syn keyword jessFunc eval evenp exit +syn keyword jessFunc exp explode$ external-addressp +syn keyword jessFunc fact-slot-value facts fetch +syn keyword jessFunc first$ float floatp +syn keyword jessFunc foreach format gensym* +syn keyword jessFunc get get-fact-duplication +syn keyword jessFunc get-member get-multithreaded-io +syn keyword jessFunc get-reset-globals get-salience-evaluation +syn keyword jessFunc halt if implode$ +syn keyword jessFunc import insert$ integer +syn keyword jessFunc integerp intersection$ jess-version-number +syn keyword jessFunc jess-version-string length$ +syn keyword jessFunc lexemep list-function$ load-facts +syn keyword jessFunc load-function load-package log +syn keyword jessFunc log10 lowcase matches +syn keyword jessFunc max member$ min +syn keyword jessFunc mod modify multifieldp +syn keyword jessFunc neq new not +syn keyword jessFunc nth$ numberp oddp +syn keyword jessFunc open or pi +syn keyword jessFunc ppdeffunction ppdefglobal ddpefrule +syn keyword jessFunc printout random read +syn keyword jessFunc readline replace$ reset +syn keyword jessFunc rest$ retract retract-string +syn keyword jessFunc return round rules +syn keyword jessFunc run run-query run-until-halt +syn keyword jessFunc save-facts set set-fact-duplication +syn keyword jessFunc set-factory set-member set-multithreaded-io +syn keyword jessFunc set-node-index-hash set-reset-globals +syn keyword jessFunc set-salience-evaluation set-strategy +syn keyword jessFunc setgen show-deffacts show-deftemplates +syn keyword jessFunc show-jess-listeners socket +syn keyword jessFunc sqrt store str-cat +syn keyword jessFunc str-compare str-index str-length +syn keyword jessFunc stringp sub-string subseq$ +syn keyword jessFunc subsetp sym-cat symbolp +syn keyword jessFunc system throw time +syn keyword jessFunc try undefadvice undefinstance +syn keyword jessFunc undefrule union$ unwatch +syn keyword jessFunc upcase view watch +syn keyword jessFunc while +syn match jessFunc "\" + +" jess Keywords (modifiers) +syn keyword jessKey defglobal deffunction defrule +syn keyword jessKey deffacts +syn keyword jessKey defadvice defclass definstance + +" Standard jess Variables +syn region jessVar start="?" end="[^a-zA-Z0-9]"me=e-1 + +" Strings +syn region jessString start=+"+ skip=+\\"+ end=+"+ + +" Shared with Declarations, Macros, Functions +"syn keyword jessDeclaration + +syn match jessNumber "[0-9]\+" + +syn match jessSpecial "\*[a-zA-Z_][a-zA-Z_0-9-]*\*" +syn match jessSpecial !#|[^()'`,"; \t]\+|#! +syn match jessSpecial !#x[0-9a-fA-F]\+! +syn match jessSpecial !#o[0-7]\+! +syn match jessSpecial !#b[01]\+! +syn match jessSpecial !#\\[ -\~]! +syn match jessSpecial !#[':][^()'`,"; \t]\+! +syn match jessSpecial !#([^()'`,"; \t]\+)! + +syn match jessConcat "\s\.\s" +syntax match jessParenError ")" + +" Comments +syn match jessComment ";.*$" + +" synchronization +syn sync lines=100 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link jessAtomNmbr jessNumber +hi def link jessAtomMark jessMark + +hi def link jessAtom Identifier +hi def link jessAtomBarSymbol Special +hi def link jessBarSymbol Special +hi def link jessComment Comment +hi def link jessConcat Statement +hi def link jessDeclaration Statement +hi def link jessFunc Statement +hi def link jessKey Type +hi def link jessMark Delimiter +hi def link jessNumber Number +hi def link jessParenError Error +hi def link jessSpecial Type +hi def link jessString String +hi def link jessVar Identifier + + +let b:current_syntax = "jess" + +" vim: ts=18 + +endif diff --git a/syntax/jgraph.vim b/syntax/jgraph.vim new file mode 100644 index 0000000..8c14451 --- /dev/null +++ b/syntax/jgraph.vim @@ -0,0 +1,49 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: jgraph (graph plotting utility) +" Maintainer: Jonas Munsin jmunsin@iki.fi +" Last Change: 2003 May 04 +" this syntax file is not yet complete + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +" comments +syn region jgraphComment start="(\* " end=" \*)" + +syn keyword jgraphCmd newcurve newgraph marktype +syn keyword jgraphType xaxis yaxis + +syn keyword jgraphType circle box diamond triangle x cross ellipse +syn keyword jgraphType xbar ybar text postscript eps none general + +syn keyword jgraphType solid dotted dashed longdash dotdash dodotdash +syn keyword jgraphType dotdotdashdash pts + +"integer number, or floating point number without a dot. - or no - +syn match jgraphNumber "\<-\=\d\+\>" +"floating point number, with dot - or no - +syn match jgraphNumber "\<-\=\d\+\.\d*\>" +"floating point number, starting with a dot - or no - +syn match jgraphNumber "\-\=\.\d\+\>" + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link jgraphComment Comment +hi def link jgraphCmd Identifier +hi def link jgraphType Type +hi def link jgraphNumber Number + + + +let b:current_syntax = "jgraph" + +endif diff --git a/syntax/jovial.vim b/syntax/jovial.vim new file mode 100644 index 0000000..bb88dfc --- /dev/null +++ b/syntax/jovial.vim @@ -0,0 +1,114 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: JOVIAL J73 +" Version: 1.2 +" Maintainer: Paul McGinnis +" Last Change: 2011/06/17 +" Remark: Based on MIL-STD-1589C for JOVIAL J73 language + +" Quit when a (custom) syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +syn keyword jovialTodo TODO FIXME XXX contained + +" JOVIAL beads - first digit is number of bits, [0-9A-V] is the bit value +" representing 0-31 (for 5 bits on the bead) +syn match jovialBitConstant "[1-5]B'[0-9A-V]'" + +syn match jovialNumber "\<\d\+\>" + +syn match jovialFloat "\d\+E[-+]\=\d\+" +syn match jovialFloat "\d\+\.\d*\(E[-+]\=\d\+\)\=" +syn match jovialFloat "\.\d\+\(E[-+]\=\d\+\)\=" + +syn region jovialComment start=/"/ end=/"/ contains=jovialTodo +syn region jovialComment start=/%/ end=/%/ contains=jovialTodo + +" JOVIAL variable names. This rule is to prevent conflicts with strings. +" Handle special case where ' character can be part of a JOVIAL variable name. +syn match jovialIdentifier "[A-Z\$][A-Z0-9'\$]\+" + +syn region jovialString start="\s*'" skip=/''/ end=/'/ oneline + +" JOVIAL compiler directives -- see Section 9 in MIL-STD-1589C +syn region jovialPreProc start="\s*![A-Z]\+" end=/;/ + +syn keyword jovialOperator AND OR NOT XOR EQV MOD + +" See Section 2.1 in MIL-STD-1589C for data types +syn keyword jovialType ITEM B C P V +syn match jovialType "\" +syn match jovialType "\" +syn match jovialType "\" +syn match jovialType "\" + +syn keyword jovialStorageClass STATIC CONSTANT PARALLEL BLOCK N M D W + +syn keyword jovialStructure TABLE STATUS + +syn keyword jovialConstant NULL + +syn keyword jovialBoolean FALSE TRUE + +syn keyword jovialTypedef TYPE + +syn keyword jovialStatement ABORT BEGIN BY BYREF BYRES BYVAL CASE COMPOOL +syn keyword jovialStatement DEF DEFAULT DEFINE ELSE END EXIT FALLTHRU FOR +syn keyword jovialStatement GOTO IF INLINE INSTANCE LABEL LIKE OVERLAY POS +syn keyword jovialStatement PROC PROGRAM REC REF RENT REP RETURN START STOP +syn keyword jovialStatement TERM THEN WHILE + +" JOVIAL extensions, see section 8.2.2 in MIL-STD-1589C +syn keyword jovialStatement CONDITION ENCAPSULATION EXPORTS FREE HANDLER IN INTERRUPT NEW +syn keyword jovialStatement PROTECTED READONLY REGISTER SIGNAL TO UPDATE WITH WRITEONLY ZONE + +" implementation specific constants and functions, see section 1.4 in MIL-STD-1589C +syn keyword jovialConstant BITSINBYTE BITSINWORD LOCSINWORD +syn keyword jovialConstant BYTESINWORD BITSINPOINTER INTPRECISION +syn keyword jovialConstant FLOATPRECISION FIXEDPRECISION FLOATRADIX +syn keyword jovialConstant MAXFLOATPRECISION MAXFIXEDPRECISION +syn keyword jovialConstant MAXINTSIZE MAXBYTES MAXBITS +syn keyword jovialConstant MAXTABLESIZE MAXSTOP MINSTOP MAXSIGDIGITS +syn keyword jovialFunction BYTEPOS MAXINT MININT +syn keyword jovialFunction IMPLFLOATPRECISION IMPLFIXEDPRECISION IMPLINTSIZE +syn keyword jovialFunction MINSIZE MINFRACTION MINSCALE MINRELPRECISION +syn keyword jovialFunction MAXFLOAT MINFLOAT FLOATRELPRECISION +syn keyword jovialFunction FLOATUNDERFLOW MAXFIXED MINFIXED + +" JOVIAL built-in functions +syn keyword jovialFunction LOC NEXT BIT BYTE SHIFTL SHIFTR ABS SGN BITSIZE +syn keyword jovialFunction BYTESIZE WORDSIZE LBOUND UBOUND NWDSEN FIRST +syn keyword jovialFunction LAST NENT + +" Define the default highlighting. +hi def link jovialBitConstant Number +hi def link jovialBoolean Boolean +hi def link jovialComment Comment +hi def link jovialConstant Constant +hi def link jovialFloat Float +hi def link jovialFunction Function +" No color highlighting for JOVIAL identifiers. See above, +" this is to prevent confusion with JOVIAL strings +"hi def link jovialIdentifier Identifier +hi def link jovialNumber Number +hi def link jovialOperator Operator +hi def link jovialPreProc PreProc +hi def link jovialStatement Statement +hi def link jovialStorageClass StorageClass +hi def link jovialString String +hi def link jovialStructure Structure +hi def link jovialTodo Todo +hi def link jovialType Type +hi def link jovialTypedef Typedef + + +let b:current_syntax = "jovial" + +" vim: ts=8 + +endif diff --git a/syntax/jproperties.vim b/syntax/jproperties.vim new file mode 100644 index 0000000..e51ea76 --- /dev/null +++ b/syntax/jproperties.vim @@ -0,0 +1,139 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Java Properties resource file (*.properties[_*]) +" Maintainer: Simon Baldwin +" Last change: 26th Mar 2000 + +" ============================================================================= + +" Optional and tuning variables: + +" jproperties_lines +" ----------------- +" Set a value for the sync block that we use to find long continuation lines +" in properties; the value is already large - if you have larger continuation +" sets you may need to increase it further - if not, and you find editing is +" slow, reduce the value of jproperties_lines. +if !exists("jproperties_lines") + let jproperties_lines = 256 +endif + +" jproperties_strict_syntax +" ------------------------- +" Most properties files assign values with "id=value" or "id:value". But, +" strictly, the Java properties parser also allows "id value", "id", and +" even more bizarrely "=value", ":value", " value", and so on. These latter +" ones, however, are rarely used, if ever, and handling them in the high- +" lighting can obscure errors in the more normal forms. So, in practice +" we take special efforts to pick out only "id=value" and "id:value" forms +" by default. If you want strict compliance, set jproperties_strict_syntax +" to non-zero (and good luck). +if !exists("jproperties_strict_syntax") + let jproperties_strict_syntax = 0 +endif + +" jproperties_show_messages +" ------------------------- +" If this properties file contains messages for use with MessageFormat, +" setting a non-zero value will highlight them. Messages are of the form +" "{...}". Highlighting doesn't go to the pains of picking apart what is +" in the format itself - just the basics for now. +if !exists("jproperties_show_messages") + let jproperties_show_messages = 0 +endif + +" ============================================================================= + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" switch case sensitivity off +syn case ignore + +" set the block +exec "syn sync lines=" . jproperties_lines + +" switch between 'normal' and 'strict' syntax +if jproperties_strict_syntax != 0 + + " an assignment is pretty much any non-empty line at this point, + " trying to not think about continuation lines + syn match jpropertiesAssignment "^\s*[^[:space:]]\+.*$" contains=jpropertiesIdentifier + + " an identifier is anything not a space character, pretty much; it's + " followed by = or :, or space or tab. Or end-of-line. + syn match jpropertiesIdentifier "[^=:[:space:]]*" contained nextgroup=jpropertiesDelimiter + + " treat the delimiter specially to get colours right + syn match jpropertiesDelimiter "\s*[=:[:space:]]\s*" contained nextgroup=jpropertiesString + + " catch the bizarre case of no identifier; a special case of delimiter + syn match jpropertiesEmptyIdentifier "^\s*[=:]\s*" nextgroup=jpropertiesString +else + + " here an assignment is id=value or id:value, and we conveniently + " ignore continuation lines for the present + syn match jpropertiesAssignment "^\s*[^=:[:space:]]\+\s*[=:].*$" contains=jpropertiesIdentifier + + " an identifier is anything not a space character, pretty much; it's + " always followed by = or :, and we find it in an assignment + syn match jpropertiesIdentifier "[^=:[:space:]]\+" contained nextgroup=jpropertiesDelimiter + + " treat the delimiter specially to get colours right; this time the + " delimiter must contain = or : + syn match jpropertiesDelimiter "\s*[=:]\s*" contained nextgroup=jpropertiesString +endif + +" a definition is all up to the last non-\-terminated line; strictly, Java +" properties tend to ignore leading whitespace on all lines of a multi-line +" definition, but we don't look for that here (because it's a major hassle) +syn region jpropertiesString start="" skip="\\$" end="$" contained contains=jpropertiesSpecialChar,jpropertiesError,jpropertiesSpecial + +" {...} is a Java Message formatter - add a minimal recognition of these +" if required +if jproperties_show_messages != 0 + syn match jpropertiesSpecial "{[^}]*}\{-1,\}" contained + syn match jpropertiesSpecial "'{" contained + syn match jpropertiesSpecial "''" contained +endif + +" \uABCD are unicode special characters +syn match jpropertiesSpecialChar "\\u\x\{1,4}" contained + +" ...and \u not followed by a hex digit is an error, though the properties +" file parser won't issue an error on it, just set something wacky like zero +syn match jpropertiesError "\\u\X\{1,4}" contained +syn match jpropertiesError "\\u$"me=e-1 contained + +" other things of note are the \t,r,n,\, and the \ preceding line end +syn match jpropertiesSpecial "\\[trn\\]" contained +syn match jpropertiesSpecial "\\\s" contained +syn match jpropertiesSpecial "\\$" contained + +" comments begin with # or !, and persist to end of line; put here since +" they may have been caught by patterns above us +syn match jpropertiesComment "^\s*[#!].*$" contains=jpropertiesTODO +syn keyword jpropertiesTodo TODO FIXME XXX contained + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link jpropertiesComment Comment +hi def link jpropertiesTodo Todo +hi def link jpropertiesIdentifier Identifier +hi def link jpropertiesString String +hi def link jpropertiesExtendString String +hi def link jpropertiesCharacter Character +hi def link jpropertiesSpecial Special +hi def link jpropertiesSpecialChar SpecialChar +hi def link jpropertiesError Error + + +let b:current_syntax = "jproperties" + +" vim:ts=8 + +endif diff --git a/syntax/json.vim b/syntax/json.vim index 48bc18e..51b09ac 100644 --- a/syntax/json.vim +++ b/syntax/json.vim @@ -1,3 +1,139 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: JSON +" Maintainer: Eli Parra +" Last Change: 2014 Aug 23 +" Version: 0.12 + +if !exists("main_syntax") + " quit when a syntax file was already loaded + if exists("b:current_syntax") + finish + endif + let main_syntax = 'json' +endif + +syntax match jsonNoise /\%(:\|,\)/ + +" NOTE that for the concealing to work your conceallevel should be set to 2 + +" Syntax: Strings +" Separated into a match and region because a region by itself is always greedy +syn match jsonStringMatch /"\([^"]\|\\\"\)\+"\ze[[:blank:]\r\n]*[,}\]]/ contains=jsonString +if has('conceal') + syn region jsonString oneline matchgroup=jsonQuote start=/"/ skip=/\\\\\|\\"/ end=/"/ concealends contains=jsonEscape contained +else + syn region jsonString oneline matchgroup=jsonQuote start=/"/ skip=/\\\\\|\\"/ end=/"/ contains=jsonEscape contained +endif + +" Syntax: JSON does not allow strings with single quotes, unlike JavaScript. +syn region jsonStringSQError oneline start=+'+ skip=+\\\\\|\\"+ end=+'+ + +" Syntax: JSON Keywords +" Separated into a match and region because a region by itself is always greedy +syn match jsonKeywordMatch /"\([^"]\|\\\"\)\+"[[:blank:]\r\n]*\:/ contains=jsonKeyword +if has('conceal') + syn region jsonKeyword matchgroup=jsonQuote start=/"/ end=/"\ze[[:blank:]\r\n]*\:/ concealends contained +else + syn region jsonKeyword matchgroup=jsonQuote start=/"/ end=/"\ze[[:blank:]\r\n]*\:/ contained +endif + +" Syntax: Escape sequences +syn match jsonEscape "\\["\\/bfnrt]" contained +syn match jsonEscape "\\u\x\{4}" contained + +" Syntax: Numbers +syn match jsonNumber "-\=\<\%(0\|[1-9]\d*\)\%(\.\d\+\)\=\%([eE][-+]\=\d\+\)\=\>\ze[[:blank:]\r\n]*[,}\]]" + +" ERROR WARNINGS ********************************************** +if (!exists("g:vim_json_warnings") || g:vim_json_warnings==1) + " Syntax: Strings should always be enclosed with quotes. + syn match jsonNoQuotesError "\<[[:alpha:]][[:alnum:]]*\>" + syn match jsonTripleQuotesError /"""/ + + " Syntax: An integer part of 0 followed by other digits is not allowed. + syn match jsonNumError "-\=\<0\d\.\d*\>" + + " Syntax: Decimals smaller than one should begin with 0 (so .1 should be 0.1). + syn match jsonNumError "\:\@<=[[:blank:]\r\n]*\zs\.\d\+" + + " Syntax: No comments in JSON, see http://stackoverflow.com/questions/244777/can-i-comment-a-json-file + syn match jsonCommentError "//.*" + syn match jsonCommentError "\(/\*\)\|\(\*/\)" + + " Syntax: No semicolons in JSON + syn match jsonSemicolonError ";" + + " Syntax: No trailing comma after the last element of arrays or objects + syn match jsonTrailingCommaError ",\_s*[}\]]" + + " Syntax: Watch out for missing commas between elements + syn match jsonMissingCommaError /\("\|\]\|\d\)\zs\_s\+\ze"/ + syn match jsonMissingCommaError /\(\]\|\}\)\_s\+\ze"/ "arrays/objects as values + syn match jsonMissingCommaError /}\_s\+\ze{/ "objects as elements in an array + syn match jsonMissingCommaError /\(true\|false\)\_s\+\ze"/ "true/false as value +endif + +" ********************************************** END OF ERROR WARNINGS +" Allowances for JSONP: function call at the beginning of the file, +" parenthesis and semicolon at the end. +" Function name validation based on +" http://stackoverflow.com/questions/2008279/validate-a-javascript-function-name/2008444#2008444 +syn match jsonPadding "\%^[[:blank:]\r\n]*[_$[:alpha:]][_$[:alnum:]]*[[:blank:]\r\n]*(" +syn match jsonPadding ");[[:blank:]\r\n]*\%$" + +" Syntax: Boolean +syn match jsonBoolean /\(true\|false\)\(\_s\+\ze"\)\@!/ + +" Syntax: Null +syn keyword jsonNull null + +" Syntax: Braces +syn region jsonFold matchgroup=jsonBraces start="{" end=/}\(\_s\+\ze\("\|{\)\)\@!/ transparent fold +syn region jsonFold matchgroup=jsonBraces start="\[" end=/]\(\_s\+\ze"\)\@!/ transparent fold + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link jsonPadding Operator +hi def link jsonString String +hi def link jsonTest Label +hi def link jsonEscape Special +hi def link jsonNumber Number +hi def link jsonBraces Delimiter +hi def link jsonNull Function +hi def link jsonBoolean Boolean +hi def link jsonKeyword Label + +if (!exists("g:vim_json_warnings") || g:vim_json_warnings==1) +hi def link jsonNumError Error +hi def link jsonCommentError Error +hi def link jsonSemicolonError Error +hi def link jsonTrailingCommaError Error +hi def link jsonMissingCommaError Error +hi def link jsonStringSQError Error +hi def link jsonNoQuotesError Error +hi def link jsonTripleQuotesError Error +endif +hi def link jsonQuote Quote +hi def link jsonNoise Noise + +let b:current_syntax = "json" +if main_syntax == 'json' + unlet main_syntax +endif + +" Vim settings +" vim: ts=8 fdm=marker + +" MIT License +" Copyright (c) 2013, Jeroen Ruigrok van der Werven, Eli Parra +"Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the Software), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: +"The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. +"THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +"See https://twitter.com/elzr/status/294964017926119424 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'json') == -1 " Vim syntax file diff --git a/syntax/jsp.vim b/syntax/jsp.vim new file mode 100644 index 0000000..5bad4b9 --- /dev/null +++ b/syntax/jsp.vim @@ -0,0 +1,72 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: JSP (Java Server Pages) +" Maintainer: Rafael Garcia-Suarez +" URL: http://rgarciasuarez.free.fr/vim/syntax/jsp.vim +" Last change: 2004 Feb 02 +" Credits : Patch by Darren Greaves (recognizes tags) +" Patch by Thomas Kimpton (recognizes jspExpr inside HTML tags) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'jsp' +endif + +" Source HTML syntax +runtime! syntax/html.vim +unlet b:current_syntax + +" Next syntax items are case-sensitive +syn case match + +" Include Java syntax +syn include @jspJava syntax/java.vim + +syn region jspScriptlet matchgroup=jspTag start=/<%/ keepend end=/%>/ contains=@jspJava +syn region jspComment start=/<%--/ end=/--%>/ +syn region jspDecl matchgroup=jspTag start=/<%!/ keepend end=/%>/ contains=@jspJava +syn region jspExpr matchgroup=jspTag start=/<%=/ keepend end=/%>/ contains=@jspJava +syn region jspDirective start=/<%@/ end=/%>/ contains=htmlString,jspDirName,jspDirArg + +syn keyword jspDirName contained include page taglib +syn keyword jspDirArg contained file uri prefix language extends import session buffer autoFlush +syn keyword jspDirArg contained isThreadSafe info errorPage contentType isErrorPage +syn region jspCommand start=// end=/\/>/ contains=htmlString,jspCommandName,jspCommandArg +syn keyword jspCommandName contained include forward getProperty plugin setProperty useBean param params fallback +syn keyword jspCommandArg contained id scope class type beanName page flush name value property +syn keyword jspCommandArg contained code codebase name archive align height +syn keyword jspCommandArg contained width hspace vspace jreversion nspluginurl iepluginurl + +" Redefine htmlTag so that it can contain jspExpr +syn clear htmlTag +syn region htmlTag start=+<[^/%]+ end=+>+ contains=htmlTagN,htmlString,htmlArg,htmlValue,htmlTagError,htmlEvent,htmlCssDefinition,@htmlPreproc,@htmlArgCluster,jspExpr,javaScript + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +" java.vim has redefined htmlComment highlighting +hi def link htmlComment Comment +hi def link htmlCommentPart Comment +" Be consistent with html highlight settings +hi def link jspComment htmlComment +hi def link jspTag htmlTag +hi def link jspDirective jspTag +hi def link jspDirName htmlTagName +hi def link jspDirArg htmlArg +hi def link jspCommand jspTag +hi def link jspCommandName htmlTagName +hi def link jspCommandArg htmlArg + +if main_syntax == 'jsp' + unlet main_syntax +endif + +let b:current_syntax = "jsp" + +" vim: ts=8 + +endif diff --git a/syntax/kconfig.vim b/syntax/kconfig.vim new file mode 100644 index 0000000..4c753a1 --- /dev/null +++ b/syntax/kconfig.vim @@ -0,0 +1,743 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Maintainer: Christian Brabandt +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2015-05-29 +" License: Vim (see :h license) +" Repository: https://github.com/chrisbra/vim-kconfig + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +if exists("g:kconfig_syntax_heavy") + +syn match kconfigBegin '^' nextgroup=kconfigKeyword + \ skipwhite + +syn keyword kconfigTodo contained TODO FIXME XXX NOTE + +syn match kconfigComment display '#.*$' contains=kconfigTodo + +syn keyword kconfigKeyword config nextgroup=kconfigSymbol + \ skipwhite + +syn keyword kconfigKeyword menuconfig nextgroup=kconfigSymbol + \ skipwhite + +syn keyword kconfigKeyword comment menu mainmenu + \ nextgroup=kconfigKeywordPrompt + \ skipwhite + +syn keyword kconfigKeyword choice + \ nextgroup=@kconfigConfigOptions + \ skipwhite skipnl + +syn keyword kconfigKeyword endmenu endchoice + +syn keyword kconfigPreProc source + \ nextgroup=kconfigPath + \ skipwhite + +" TODO: This is a hack. The who .*Expr stuff should really be generated so +" that we can reuse it for various nextgroups. +syn keyword kconfigConditional if endif + \ nextgroup=@kconfigConfigOptionIfExpr + \ skipwhite + +syn match kconfigKeywordPrompt '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=@kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigPath '"[^"\\]*\%(\\.[^"\\]*\)*"\|\S\+' + \ contained + +syn match kconfigSymbol '\<\k\+\>' + \ contained + \ nextgroup=@kconfigConfigOptions + \ skipwhite skipnl + +" FIXME: There is – probably – no reason to cluster these instead of just +" defining them in the same group. +syn cluster kconfigConfigOptions contains=kconfigTypeDefinition, + \ kconfigInputPrompt, + \ kconfigDefaultValue, + \ kconfigDependencies, + \ kconfigReverseDependencies, + \ kconfigNumericalRanges, + \ kconfigHelpText, + \ kconfigDefBool, + \ kconfigOptional + +syn keyword kconfigTypeDefinition bool boolean tristate string hex int + \ contained + \ nextgroup=kconfigTypeDefPrompt, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigTypeDefPrompt '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigTypeDefPrompt "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn keyword kconfigInputPrompt prompt + \ contained + \ nextgroup=kconfigPromptPrompt + \ skipwhite + +syn match kconfigPromptPrompt '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigPromptPrompt "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn keyword kconfigDefaultValue default + \ contained + \ nextgroup=@kconfigConfigOptionExpr + \ skipwhite + +syn match kconfigDependencies 'depends on\|requires' + \ contained + \ nextgroup=@kconfigConfigOptionIfExpr + \ skipwhite + +syn keyword kconfigReverseDependencies select + \ contained + \ nextgroup=@kconfigRevDepSymbol + \ skipwhite + +syn cluster kconfigRevDepSymbol contains=kconfigRevDepCSymbol, + \ kconfigRevDepNCSymbol + +syn match kconfigRevDepCSymbol '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigRevDepCSymbol "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigRevDepNCSymbol '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn keyword kconfigNumericalRanges range + \ contained + \ nextgroup=@kconfigRangeSymbol + \ skipwhite + +syn cluster kconfigRangeSymbol contains=kconfigRangeCSymbol, + \ kconfigRangeNCSymbol + +syn match kconfigRangeCSymbol '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=@kconfigRangeSymbol2 + \ skipwhite skipnl + +syn match kconfigRangeCSymbol "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=@kconfigRangeSymbol2 + \ skipwhite skipnl + +syn match kconfigRangeNCSymbol '\<\k\+\>' + \ contained + \ nextgroup=@kconfigRangeSymbol2 + \ skipwhite skipnl + +syn cluster kconfigRangeSymbol2 contains=kconfigRangeCSymbol2, + \ kconfigRangeNCSymbol2 + +syn match kconfigRangeCSymbol2 "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigRangeNCSymbol2 '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn region kconfigHelpText contained + \ matchgroup=kconfigConfigOption + \ start='\%(help\|---help---\)\ze\s*\n\z(\s\+\)' + \ skip='^$' + \ end='^\z1\@!' + \ nextgroup=@kconfigConfigOptions + \ skipwhite skipnl + +" XXX: Undocumented +syn keyword kconfigDefBool def_bool + \ contained + \ nextgroup=@kconfigDefBoolSymbol + \ skipwhite + +syn cluster kconfigDefBoolSymbol contains=kconfigDefBoolCSymbol, + \ kconfigDefBoolNCSymbol + +syn match kconfigDefBoolCSymbol '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigDefBoolCSymbol "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigDefBoolNCSymbol '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ @kconfigConfigOptions + \ skipwhite skipnl + +" XXX: This is actually only a valid option for “choiceâ€, but treating it +" specially would require a lot of extra groups. +syn keyword kconfigOptional optional + \ contained + \ nextgroup=@kconfigConfigOptions + \ skipwhite skipnl + +syn keyword kconfigConfigOptionIf if + \ contained + \ nextgroup=@kconfigConfigOptionIfExpr + \ skipwhite + +syn cluster kconfigConfigOptionIfExpr contains=@kconfigConfOptIfExprSym, + \ kconfigConfOptIfExprNeg, + \ kconfigConfOptIfExprGroup + +syn cluster kconfigConfOptIfExprSym contains=kconfigConfOptIfExprCSym, + \ kconfigConfOptIfExprNCSym + +syn match kconfigConfOptIfExprCSym '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=@kconfigConfigOptions, + \ kconfigConfOptIfExprAnd, + \ kconfigConfOptIfExprOr, + \ kconfigConfOptIfExprEq, + \ kconfigConfOptIfExprNEq + \ skipwhite skipnl + +syn match kconfigConfOptIfExprCSym "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=@kconfigConfigOptions, + \ kconfigConfOptIfExprAnd, + \ kconfigConfOptIfExprOr, + \ kconfigConfOptIfExprEq, + \ kconfigConfOptIfExprNEq + \ skipwhite skipnl + +syn match kconfigConfOptIfExprNCSym '\<\k\+\>' + \ contained + \ nextgroup=@kconfigConfigOptions, + \ kconfigConfOptIfExprAnd, + \ kconfigConfOptIfExprOr, + \ kconfigConfOptIfExprEq, + \ kconfigConfOptIfExprNEq + \ skipwhite skipnl + +syn cluster kconfigConfOptIfExprSym2 contains=kconfigConfOptIfExprCSym2, + \ kconfigConfOptIfExprNCSym2 + +syn match kconfigConfOptIfExprEq '=' + \ contained + \ nextgroup=@kconfigConfOptIfExprSym2 + \ skipwhite + +syn match kconfigConfOptIfExprNEq '!=' + \ contained + \ nextgroup=@kconfigConfOptIfExprSym2 + \ skipwhite + +syn match kconfigConfOptIfExprCSym2 "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=@kconfigConfigOptions, + \ kconfigConfOptIfExprAnd, + \ kconfigConfOptIfExprOr + \ skipwhite skipnl + +syn match kconfigConfOptIfExprNCSym2 '\<\k\+\>' + \ contained + \ nextgroup=@kconfigConfigOptions, + \ kconfigConfOptIfExprAnd, + \ kconfigConfOptIfExprOr + \ skipwhite skipnl + +syn match kconfigConfOptIfExprNeg '!' + \ contained + \ nextgroup=@kconfigConfigOptionIfExpr + \ skipwhite + +syn match kconfigConfOptIfExprAnd '&&' + \ contained + \ nextgroup=@kconfigConfigOptionIfExpr + \ skipwhite + +syn match kconfigConfOptIfExprOr '||' + \ contained + \ nextgroup=@kconfigConfigOptionIfExpr + \ skipwhite + +syn match kconfigConfOptIfExprGroup '(' + \ contained + \ nextgroup=@kconfigConfigOptionIfGExp + \ skipwhite + +" TODO: hm, this kind of recursion doesn't work right. We need another set of +" expressions that have kconfigConfigOPtionIfGExp as nextgroup and a matcher +" for '(' that sets it all off. +syn cluster kconfigConfigOptionIfGExp contains=@kconfigConfOptIfGExpSym, + \ kconfigConfOptIfGExpNeg, + \ kconfigConfOptIfExprGroup + +syn cluster kconfigConfOptIfGExpSym contains=kconfigConfOptIfGExpCSym, + \ kconfigConfOptIfGExpNCSym + +syn match kconfigConfOptIfGExpCSym '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=@kconfigConfigIf, + \ kconfigConfOptIfGExpAnd, + \ kconfigConfOptIfGExpOr, + \ kconfigConfOptIfGExpEq, + \ kconfigConfOptIfGExpNEq + \ skipwhite skipnl + +syn match kconfigConfOptIfGExpCSym "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=@kconfigConfigIf, + \ kconfigConfOptIfGExpAnd, + \ kconfigConfOptIfGExpOr, + \ kconfigConfOptIfGExpEq, + \ kconfigConfOptIfGExpNEq + \ skipwhite skipnl + +syn match kconfigConfOptIfGExpNCSym '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfOptIfExprGrpE, + \ kconfigConfOptIfGExpAnd, + \ kconfigConfOptIfGExpOr, + \ kconfigConfOptIfGExpEq, + \ kconfigConfOptIfGExpNEq + \ skipwhite skipnl + +syn cluster kconfigConfOptIfGExpSym2 contains=kconfigConfOptIfGExpCSym2, + \ kconfigConfOptIfGExpNCSym2 + +syn match kconfigConfOptIfGExpEq '=' + \ contained + \ nextgroup=@kconfigConfOptIfGExpSym2 + \ skipwhite + +syn match kconfigConfOptIfGExpNEq '!=' + \ contained + \ nextgroup=@kconfigConfOptIfGExpSym2 + \ skipwhite + +syn match kconfigConfOptIfGExpCSym2 '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfOptIfExprGrpE, + \ kconfigConfOptIfGExpAnd, + \ kconfigConfOptIfGExpOr + \ skipwhite skipnl + +syn match kconfigConfOptIfGExpCSym2 "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfOptIfExprGrpE, + \ kconfigConfOptIfGExpAnd, + \ kconfigConfOptIfGExpOr + \ skipwhite skipnl + +syn match kconfigConfOptIfGExpNCSym2 '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfOptIfExprGrpE, + \ kconfigConfOptIfGExpAnd, + \ kconfigConfOptIfGExpOr + \ skipwhite skipnl + +syn match kconfigConfOptIfGExpNeg '!' + \ contained + \ nextgroup=@kconfigConfigOptionIfGExp + \ skipwhite + +syn match kconfigConfOptIfGExpAnd '&&' + \ contained + \ nextgroup=@kconfigConfigOptionIfGExp + \ skipwhite + +syn match kconfigConfOptIfGExpOr '||' + \ contained + \ nextgroup=@kconfigConfigOptionIfGExp + \ skipwhite + +syn match kconfigConfOptIfExprGrpE ')' + \ contained + \ nextgroup=@kconfigConfigOptions, + \ kconfigConfOptIfExprAnd, + \ kconfigConfOptIfExprOr + \ skipwhite skipnl + + +syn cluster kconfigConfigOptionExpr contains=@kconfigConfOptExprSym, + \ kconfigConfOptExprNeg, + \ kconfigConfOptExprGroup + +syn cluster kconfigConfOptExprSym contains=kconfigConfOptExprCSym, + \ kconfigConfOptExprNCSym + +syn match kconfigConfOptExprCSym '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ kconfigConfOptExprAnd, + \ kconfigConfOptExprOr, + \ kconfigConfOptExprEq, + \ kconfigConfOptExprNEq, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigConfOptExprCSym "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ kconfigConfOptExprAnd, + \ kconfigConfOptExprOr, + \ kconfigConfOptExprEq, + \ kconfigConfOptExprNEq, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigConfOptExprNCSym '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ kconfigConfOptExprAnd, + \ kconfigConfOptExprOr, + \ kconfigConfOptExprEq, + \ kconfigConfOptExprNEq, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn cluster kconfigConfOptExprSym2 contains=kconfigConfOptExprCSym2, + \ kconfigConfOptExprNCSym2 + +syn match kconfigConfOptExprEq '=' + \ contained + \ nextgroup=@kconfigConfOptExprSym2 + \ skipwhite + +syn match kconfigConfOptExprNEq '!=' + \ contained + \ nextgroup=@kconfigConfOptExprSym2 + \ skipwhite + +syn match kconfigConfOptExprCSym2 '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ kconfigConfOptExprAnd, + \ kconfigConfOptExprOr, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigConfOptExprCSym2 "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ kconfigConfOptExprAnd, + \ kconfigConfOptExprOr, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigConfOptExprNCSym2 '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ kconfigConfOptExprAnd, + \ kconfigConfOptExprOr, + \ @kconfigConfigOptions + \ skipwhite skipnl + +syn match kconfigConfOptExprNeg '!' + \ contained + \ nextgroup=@kconfigConfigOptionExpr + \ skipwhite + +syn match kconfigConfOptExprAnd '&&' + \ contained + \ nextgroup=@kconfigConfigOptionExpr + \ skipwhite + +syn match kconfigConfOptExprOr '||' + \ contained + \ nextgroup=@kconfigConfigOptionExpr + \ skipwhite + +syn match kconfigConfOptExprGroup '(' + \ contained + \ nextgroup=@kconfigConfigOptionGExp + \ skipwhite + +syn cluster kconfigConfigOptionGExp contains=@kconfigConfOptGExpSym, + \ kconfigConfOptGExpNeg, + \ kconfigConfOptGExpGroup + +syn cluster kconfigConfOptGExpSym contains=kconfigConfOptGExpCSym, + \ kconfigConfOptGExpNCSym + +syn match kconfigConfOptGExpCSym '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfOptExprGrpE, + \ kconfigConfOptGExpAnd, + \ kconfigConfOptGExpOr, + \ kconfigConfOptGExpEq, + \ kconfigConfOptGExpNEq + \ skipwhite skipnl + +syn match kconfigConfOptGExpCSym "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfOptExprGrpE, + \ kconfigConfOptGExpAnd, + \ kconfigConfOptGExpOr, + \ kconfigConfOptGExpEq, + \ kconfigConfOptGExpNEq + \ skipwhite skipnl + +syn match kconfigConfOptGExpNCSym '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfOptExprGrpE, + \ kconfigConfOptGExpAnd, + \ kconfigConfOptGExpOr, + \ kconfigConfOptGExpEq, + \ kconfigConfOptGExpNEq + \ skipwhite skipnl + +syn cluster kconfigConfOptGExpSym2 contains=kconfigConfOptGExpCSym2, + \ kconfigConfOptGExpNCSym2 + +syn match kconfigConfOptGExpEq '=' + \ contained + \ nextgroup=@kconfigConfOptGExpSym2 + \ skipwhite + +syn match kconfigConfOptGExpNEq '!=' + \ contained + \ nextgroup=@kconfigConfOptGExpSym2 + \ skipwhite + +syn match kconfigConfOptGExpCSym2 '"[^"\\]*\%(\\.[^"\\]*\)*"' + \ contained + \ nextgroup=kconfigConfOptExprGrpE, + \ kconfigConfOptGExpAnd, + \ kconfigConfOptGExpOr + \ skipwhite skipnl + +syn match kconfigConfOptGExpCSym2 "'[^'\\]*\%(\\.[^'\\]*\)*'" + \ contained + \ nextgroup=kconfigConfOptExprGrpE, + \ kconfigConfOptGExpAnd, + \ kconfigConfOptGExpOr + \ skipwhite skipnl + +syn match kconfigConfOptGExpNCSym2 '\<\k\+\>' + \ contained + \ nextgroup=kconfigConfOptExprGrpE, + \ kconfigConfOptGExpAnd, + \ kconfigConfOptGExpOr + \ skipwhite skipnl + +syn match kconfigConfOptGExpNeg '!' + \ contained + \ nextgroup=@kconfigConfigOptionGExp + \ skipwhite + +syn match kconfigConfOptGExpAnd '&&' + \ contained + \ nextgroup=@kconfigConfigOptionGExp + \ skipwhite + +syn match kconfigConfOptGExpOr '||' + \ contained + \ nextgroup=@kconfigConfigOptionGExp + \ skipwhite + +syn match kconfigConfOptExprGrpE ')' + \ contained + \ nextgroup=kconfigConfigOptionIf, + \ kconfigConfOptExprAnd, + \ kconfigConfOptExprOr + \ skipwhite skipnl + +syn sync minlines=50 + +hi def link kconfigTodo Todo +hi def link kconfigComment Comment +hi def link kconfigKeyword Keyword +hi def link kconfigPreProc PreProc +hi def link kconfigConditional Conditional +hi def link kconfigPrompt String +hi def link kconfigKeywordPrompt kconfigPrompt +hi def link kconfigPath String +hi def link kconfigSymbol String +hi def link kconfigConstantSymbol Constant +hi def link kconfigConfigOption Type +hi def link kconfigTypeDefinition kconfigConfigOption +hi def link kconfigTypeDefPrompt kconfigPrompt +hi def link kconfigInputPrompt kconfigConfigOption +hi def link kconfigPromptPrompt kconfigPrompt +hi def link kconfigDefaultValue kconfigConfigOption +hi def link kconfigDependencies kconfigConfigOption +hi def link kconfigReverseDependencies kconfigConfigOption +hi def link kconfigRevDepCSymbol kconfigConstantSymbol +hi def link kconfigRevDepNCSymbol kconfigSymbol +hi def link kconfigNumericalRanges kconfigConfigOption +hi def link kconfigRangeCSymbol kconfigConstantSymbol +hi def link kconfigRangeNCSymbol kconfigSymbol +hi def link kconfigRangeCSymbol2 kconfigConstantSymbol +hi def link kconfigRangeNCSymbol2 kconfigSymbol +hi def link kconfigHelpText Normal +hi def link kconfigDefBool kconfigConfigOption +hi def link kconfigDefBoolCSymbol kconfigConstantSymbol +hi def link kconfigDefBoolNCSymbol kconfigSymbol +hi def link kconfigOptional kconfigConfigOption +hi def link kconfigConfigOptionIf Conditional +hi def link kconfigConfOptIfExprCSym kconfigConstantSymbol +hi def link kconfigConfOptIfExprNCSym kconfigSymbol +hi def link kconfigOperator Operator +hi def link kconfigConfOptIfExprEq kconfigOperator +hi def link kconfigConfOptIfExprNEq kconfigOperator +hi def link kconfigConfOptIfExprCSym2 kconfigConstantSymbol +hi def link kconfigConfOptIfExprNCSym2 kconfigSymbol +hi def link kconfigConfOptIfExprNeg kconfigOperator +hi def link kconfigConfOptIfExprAnd kconfigOperator +hi def link kconfigConfOptIfExprOr kconfigOperator +hi def link kconfigDelimiter Delimiter +hi def link kconfigConfOptIfExprGroup kconfigDelimiter +hi def link kconfigConfOptIfGExpCSym kconfigConstantSymbol +hi def link kconfigConfOptIfGExpNCSym kconfigSymbol +hi def link kconfigConfOptIfGExpEq kconfigOperator +hi def link kconfigConfOptIfGExpNEq kconfigOperator +hi def link kconfigConfOptIfGExpCSym2 kconfigConstantSymbol +hi def link kconfigConfOptIfGExpNCSym2 kconfigSymbol +hi def link kconfigConfOptIfGExpNeg kconfigOperator +hi def link kconfigConfOptIfGExpAnd kconfigOperator +hi def link kconfigConfOptIfGExpOr kconfigOperator +hi def link kconfigConfOptIfExprGrpE kconfigDelimiter +hi def link kconfigConfOptExprCSym kconfigConstantSymbol +hi def link kconfigConfOptExprNCSym kconfigSymbol +hi def link kconfigConfOptExprEq kconfigOperator +hi def link kconfigConfOptExprNEq kconfigOperator +hi def link kconfigConfOptExprCSym2 kconfigConstantSymbol +hi def link kconfigConfOptExprNCSym2 kconfigSymbol +hi def link kconfigConfOptExprNeg kconfigOperator +hi def link kconfigConfOptExprAnd kconfigOperator +hi def link kconfigConfOptExprOr kconfigOperator +hi def link kconfigConfOptExprGroup kconfigDelimiter +hi def link kconfigConfOptGExpCSym kconfigConstantSymbol +hi def link kconfigConfOptGExpNCSym kconfigSymbol +hi def link kconfigConfOptGExpEq kconfigOperator +hi def link kconfigConfOptGExpNEq kconfigOperator +hi def link kconfigConfOptGExpCSym2 kconfigConstantSymbol +hi def link kconfigConfOptGExpNCSym2 kconfigSymbol +hi def link kconfigConfOptGExpNeg kconfigOperator +hi def link kconfigConfOptGExpAnd kconfigOperator +hi def link kconfigConfOptGExpOr kconfigOperator +hi def link kconfigConfOptExprGrpE kconfigConfOptIfExprGroup + +else + +syn keyword kconfigTodo contained TODO FIXME XXX NOTE + +syn match kconfigComment display '#.*$' contains=kconfigTodo + +syn keyword kconfigKeyword config menuconfig comment mainmenu + +syn keyword kconfigConditional menu endmenu choice endchoice if endif + +syn keyword kconfigPreProc source + \ nextgroup=kconfigPath + \ skipwhite + +syn keyword kconfigTriState y m n + +syn match kconfigSpecialChar contained '\\.' +syn match kconfigSpecialChar '\\$' + +syn region kconfigPath matchgroup=kconfigPath + \ start=+"+ skip=+\\\\\|\\\"+ end=+"+ + \ contains=kconfigSpecialChar + +syn region kconfigPath matchgroup=kconfigPath + \ start=+'+ skip=+\\\\\|\\\'+ end=+'+ + \ contains=kconfigSpecialChar + +syn match kconfigPath '\S\+' + \ contained + +syn region kconfigString matchgroup=kconfigString + \ start=+"+ skip=+\\\\\|\\\"+ end=+"+ + \ contains=kconfigSpecialChar + +syn region kconfigString matchgroup=kconfigString + \ start=+'+ skip=+\\\\\|\\\'+ end=+'+ + \ contains=kconfigSpecialChar + +syn keyword kconfigType bool boolean tristate string hex int + +syn keyword kconfigOption prompt default requires select range + \ optional +syn match kconfigOption 'depends\%( on\)\=' + +syn keyword kconfigMacro def_bool def_tristate + +syn region kconfigHelpText + \ matchgroup=kconfigOption + \ start='\%(help\|---help---\)\ze\s*\n\z(\s\+\)' + \ skip='^$' + \ end='^\z1\@!' + +syn sync match kconfigSyncHelp grouphere kconfigHelpText 'help\|---help---' + +hi def link kconfigTodo Todo +hi def link kconfigComment Comment +hi def link kconfigKeyword Keyword +hi def link kconfigConditional Conditional +hi def link kconfigPreProc PreProc +hi def link kconfigTriState Boolean +hi def link kconfigSpecialChar SpecialChar +hi def link kconfigPath String +hi def link kconfigString String +hi def link kconfigType Type +hi def link kconfigOption Identifier +hi def link kconfigHelpText Normal +hi def link kconfigmacro Macro + +endif + +let b:current_syntax = "kconfig" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/kivy.vim b/syntax/kivy.vim new file mode 100644 index 0000000..96d0023 --- /dev/null +++ b/syntax/kivy.vim @@ -0,0 +1,40 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Kivy +" Maintainer: Corey Prophitt +" Last Change: May 29th, 2014 +" Version: 1 +" URL: http://kivy.org/ + +if exists("b:current_syntax") + finish +endif + +" Load Python syntax first (Python can be used within Kivy) +syn include @pyth $VIMRUNTIME/syntax/python.vim + +" Kivy language rules can be found here +" http://kivy.org/docs/guide/lang.html + +" Define Kivy syntax +syn match kivyPreProc /#:.*/ +syn match kivyComment /#.*/ +syn match kivyRule /<\I\i*\(,\s*\I\i*\)*>:/ +syn match kivyAttribute /\<\I\i*\>/ nextgroup=kivyValue + +syn region kivyValue start=":" end=/$/ contains=@pyth skipwhite + +syn region kivyAttribute matchgroup=kivyIdent start=/[\a_][\a\d_]*:/ end=/$/ contains=@pyth skipwhite + +hi def link kivyPreproc PreProc +hi def link kivyComment Comment +hi def link kivyRule Function +hi def link kivyIdent Statement +hi def link kivyAttribute Label + +let b:current_syntax = "kivy" + +" vim: ts=8 + +endif diff --git a/syntax/kix.vim b/syntax/kix.vim new file mode 100644 index 0000000..94d2f0e --- /dev/null +++ b/syntax/kix.vim @@ -0,0 +1,174 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: KixTart 95, Kix2001 Windows script language http://kixtart.org/ +" Maintainer: Richard Howarth +" Last Change: 2003 May 11 +" URL: http://www.howsoft.demon.co.uk/ + +" KixTart files identified by *.kix extension. + +" Amendment History: +" 26 April 2001: RMH +" Removed development comments from distro version +" Renamed "Kix*" to "kix*" for consistancy +" Changes made in preperation for VIM version 5.8/6.00 + +" TODO: +" Handle arrays highlighting +" Handle object highlighting +" The next two may not be possible: +" Work out how to error too many "(", i.e. (() should be an error. +" Similarly, "if" without "endif" and similar constructs should error. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match +syn keyword kixTODO TODO FIX XXX contained + +" Case insensitive language. +syn case ignore + +" Kix statements +syn match kixStatement "?" +syn keyword kixStatement beep big break +syn keyword kixStatement call cd cls color cookie1 copy +syn keyword kixStatement del dim display +syn keyword kixStatement exit +syn keyword kixStatement flushkb +syn keyword kixStatement get gets global go gosub goto +syn keyword kixStatement md +syn keyword kixStatement password play +syn keyword kixStatement quit +syn keyword kixStatement rd return run +syn keyword kixStatement set setl setm settime shell sleep small +syn keyword kixStatement use + +" Kix2001 +syn keyword kixStatement debug function endfunction redim + +" Simple variables +syn match kixNotVar "\$\$\|@@\|%%" transparent contains=NONE +syn match kixLocalVar "\$\w\+" +syn match kixMacro "@\w\+" +syn match kixEnvVar "%\w\+" + +" Destination labels +syn match kixLabel ":\w\+\>" + +" Identify strings, trap unterminated strings +syn match kixStringError +".*\|'.*+ +syn region kixDoubleString oneline start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=kixLocalVar,kixMacro,kixEnvVar,kixNotVar +syn region kixSingleString oneline start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=kixLocalVar,kixMacro,kixEnvVar,kixNotVar + +" Operators +syn match kixOperator "+\|-\|\*\|/\|=\|&\||" +syn keyword kixOperator and or +" Kix2001 +syn match kixOperator "==" +syn keyword kixOperator not + +" Numeric constants +syn match kixInteger "-\=\<\d\+\>" contains=NONE +syn match kixFloat "-\=\.\d\+\>\|-\=\<\d\+\.\d\+\>" contains=NONE + +" Hex numeric constants +syn match kixHex "\&\x\+\>" contains=NONE + +" Other contants +" Kix2001 +syn keyword kixConstant on off + +" Comments +syn match kixComment ";.*$" contains=kixTODO + +" Trap unmatched parenthesis +syn match kixParenCloseError ")" +syn region kixParen oneline transparent start="(" end=")" contains=ALLBUT,kixParenCloseError + +" Functions (Builtin + UDF) +syn match kixFunction "\w\+("he=e-1,me=e-1 contains=ALL + +" Trap unmatched brackets +syn match kixBrackCloseError "\]" +syn region kixBrack transparent start="\[" end="\]" contains=ALLBUT,kixBrackCloseError + +" Clusters for ALLBUT shorthand +syn cluster kixIfBut contains=kixIfError,kixSelectOK,kixDoOK,kixWhileOK,kixForEachOK,kixForNextOK +syn cluster kixSelectBut contains=kixSelectError,kixIfOK,kixDoOK,kixWhileOK,kixForEachOK,kixForNextOK +syn cluster kixDoBut contains=kixDoError,kixSelectOK,kixIfOK,kixWhileOK,kixForEachOK,kixForNextOK +syn cluster kixWhileBut contains=kixWhileError,kixSelectOK,kixIfOK,kixDoOK,kixForEachOK,kixForNextOK +syn cluster kixForEachBut contains=kixForEachError,kixSelectOK,kixIfOK,kixDoOK,kixForNextOK,kixWhileOK +syn cluster kixForNextBut contains=kixForNextError,kixSelectOK,kixIfOK,kixDoOK,kixForEachOK,kixWhileOK +" Condtional construct errors. +syn match kixIfError "\\|\\|\" +syn match kixIfOK contained "\\|\\|\" +syn region kixIf transparent matchgroup=kixIfOK start="\" end="\" contains=ALLBUT,@kixIfBut +syn match kixSelectError "\\|\\|\" +syn match kixSelectOK contained "\\|\\|\" +syn region kixSelect transparent matchgroup=kixSelectOK start="\" end="\" contains=ALLBUT,@kixSelectBut + +" Program control constructs. +syn match kixDoError "\\|\" +syn match kixDoOK contained "\\|\" +syn region kixDo transparent matchgroup=kixDoOK start="\" end="\" contains=ALLBUT,@kixDoBut +syn match kixWhileError "\\|\" +syn match kixWhileOK contained "\\|\" +syn region kixWhile transparent matchgroup=kixWhileOK start="\" end="\" contains=ALLBUT,@kixWhileBut +syn match kixForNextError "\\|\\|\\|\" +syn match kixForNextOK contained "\\|\\|\\|\" +syn region kixForNext transparent matchgroup=kixForNextOK start="\" end="\" contains=ALLBUT,@kixForBut +syn match kixForEachError "\\|\\|\" +syn match kixForEachOK contained "\\|\\|\" +syn region kixForEach transparent matchgroup=kixForEachOK start="\" end="\" contains=ALLBUT,@kixForEachBut + +" Expressions +syn match kixExpression "<\|>\|<=\|>=\|<>" + + +" Default highlighting. +" Set default highlight only if it doesn't already have a value. + +hi def link kixDoubleString String +hi def link kixSingleString String +hi def link kixStatement Statement +hi def link kixRepeat Repeat +hi def link kixComment Comment +hi def link kixBuiltin Function +hi def link kixLocalVar Special +hi def link kixMacro Special +hi def link kixEnvVar Special +hi def link kixLabel Type +hi def link kixFunction Function +hi def link kixInteger Number +hi def link kixHex Number +hi def link kixFloat Number +hi def link kixOperator Operator +hi def link kixExpression Operator + +hi def link kixParenCloseError Error +hi def link kixBrackCloseError Error +hi def link kixStringError Error + +hi def link kixWhileError Error +hi def link kixWhileOK Conditional +hi def link kixDoError Error +hi def link kixDoOK Conditional +hi def link kixIfError Error +hi def link kixIfOK Conditional +hi def link kixSelectError Error +hi def link kixSelectOK Conditional +hi def link kixForNextError Error +hi def link kixForNextOK Conditional +hi def link kixForEachError Error +hi def link kixForEachOK Conditional + + +let b:current_syntax = "kix" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/kscript.vim b/syntax/kscript.vim new file mode 100644 index 0000000..432e2e0 --- /dev/null +++ b/syntax/kscript.vim @@ -0,0 +1,61 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: kscript +" Maintainer: Thomas Capricelli +" URL: http://aquila.rezel.enst.fr/thomas/vim/kscript.vim +" CVS: $Id: kscript.vim,v 1.1 2004/06/13 17:40:02 vimboss Exp $ + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword kscriptPreCondit import from + +syn keyword kscriptHardCoded print println connect length arg mid upper lower isEmpty toInt toFloat findApplication +syn keyword kscriptConditional if else switch +syn keyword kscriptRepeat while for do foreach +syn keyword kscriptExceptions emit catch raise try signal +syn keyword kscriptFunction class struct enum +syn keyword kscriptConst FALSE TRUE false true +syn keyword kscriptStatement return delete +syn keyword kscriptLabel case default +syn keyword kscriptStorageClass const +syn keyword kscriptType in out inout var + +syn keyword kscriptTodo contained TODO FIXME XXX + +syn region kscriptComment start="/\*" end="\*/" contains=kscriptTodo +syn match kscriptComment "//.*" contains=kscriptTodo +syn match kscriptComment "#.*$" contains=kscriptTodo + +syn region kscriptString start=+'+ end=+'+ skip=+\\\\\|\\'+ +syn region kscriptString start=+"+ end=+"+ skip=+\\\\\|\\"+ +syn region kscriptString start=+"""+ end=+"""+ +syn region kscriptString start=+'''+ end=+'''+ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link kscriptConditional Conditional +hi def link kscriptRepeat Repeat +hi def link kscriptExceptions Statement +hi def link kscriptFunction Function +hi def link kscriptConst Constant +hi def link kscriptStatement Statement +hi def link kscriptLabel Label +hi def link kscriptStorageClass StorageClass +hi def link kscriptType Type +hi def link kscriptTodo Todo +hi def link kscriptComment Comment +hi def link kscriptString String +hi def link kscriptPreCondit PreCondit +hi def link kscriptHardCoded Statement + + +let b:current_syntax = "kscript" + +" vim: ts=8 + +endif diff --git a/syntax/kwt.vim b/syntax/kwt.vim new file mode 100644 index 0000000..5efeda8 --- /dev/null +++ b/syntax/kwt.vim @@ -0,0 +1,74 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: kimwitu++ +" Maintainer: Michael Piefel +" Last Change: 2 May 2001 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read the C++ syntax to start with +runtime! syntax/cpp.vim +unlet b:current_syntax + +" kimwitu++ extentions + +" Don't stop at eol, messes around with CPP mode, but gives line spanning +" strings in unparse rules +syn region cCppString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial,cFormat +syn keyword cType integer real casestring nocasestring voidptr list +syn keyword cType uview rview uview_enum rview_enum + +" avoid unparsing rule sth:view being scanned as label +syn clear cUserCont +syn match cUserCont "^\s*\I\i*\s*:$" contains=cUserLabel contained +syn match cUserCont ";\s*\I\i*\s*:$" contains=cUserLabel contained +syn match cUserCont "^\s*\I\i*\s*:[^:]"me=e-1 contains=cUserLabel contained +syn match cUserCont ";\s*\I\i*\s*:[^:]"me=e-1 contains=cUserLabel contained + +" highlight phylum decls +syn match kwtPhylum "^\I\i*:$" +syn match kwtPhylum "^\I\i*\s*{\s*\(!\|\I\)\i*\s*}\s*:$" + +syn keyword kwtStatement with foreach afterforeach provided +syn match kwtDecl "%\(uviewvar\|rviewvar\)" +syn match kwtDecl "^%\(uview\|rview\|ctor\|dtor\|base\|storageclass\|list\|attr\|member\|option\)" +syn match kwtOption "no-csgio\|no-unparse\|no-rewrite\|no-printdot\|no-hashtables\|smart-pointer\|weak-pointer" +syn match kwtSep "^%}$" +syn match kwtSep "^%{\(\s\+\I\i*\)*$" +syn match kwtCast "\ +" Last Change: 2001 May 09 + +" Copyright Interactive Software Engineering, 1998 +" You are free to use this file as you please, but +" if you make a change or improvement you must send +" it to the maintainer at + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" LACE is case insensitive, but the style guide lines are not. + +if !exists("lace_case_insensitive") + syn case match +else + syn case ignore +endif + +" A bunch of useful LACE keywords +syn keyword laceTopStruct system root default option visible cluster +syn keyword laceTopStruct external generate end +syn keyword laceOptionClause collect assertion debug optimize trace +syn keyword laceOptionClause profile inline precompiled multithreaded +syn keyword laceOptionClause exception_trace dead_code_removal +syn keyword laceOptionClause array_optimization +syn keyword laceOptionClause inlining_size inlining +syn keyword laceOptionClause console_application dynamic_runtime +syn keyword laceOptionClause line_generation +syn keyword laceOptionMark yes no all +syn keyword laceOptionMark require ensure invariant loop check +syn keyword laceClusterProp use include exclude +syn keyword laceAdaptClassName adapt ignore rename as +syn keyword laceAdaptClassName creation export visible +syn keyword laceExternal include_path object makefile + +" Operators +syn match laceOperator "\$" +syn match laceBrackets "[[\]]" +syn match laceExport "[{}]" + +" Constants +syn keyword laceBool true false +syn keyword laceBool True False +syn region laceString start=+"+ skip=+%"+ end=+"+ contains=laceEscape,laceStringError +syn match laceEscape contained "%[^/]" +syn match laceEscape contained "%/\d\+/" +syn match laceEscape contained "^[ \t]*%" +syn match laceEscape contained "%[ \t]*$" +syn match laceStringError contained "%/[^0-9]" +syn match laceStringError contained "%/\d\+[^0-9/]" +syn match laceStringError "'\(%[^/]\|%/\d\+/\|[^'%]\)\+'" +syn match laceCharacter "'\(%[^/]\|%/\d\+/\|[^'%]\)'" contains=laceEscape +syn match laceNumber "-\=\<\d\+\(_\d\+\)*\>" +syn match laceNumber "\<[01]\+[bB]\>" +syn match laceNumber "-\=\<\d\+\(_\d\+\)*\.\(\d\+\(_\d\+\)*\)\=\([eE][-+]\=\d\+\(_\d\+\)*\)\=" +syn match laceNumber "-\=\.\d\+\(_\d\+\)*\([eE][-+]\=\d\+\(_\d\+\)*\)\=" +syn match laceComment "--.*" contains=laceTodo + + +syn case match + +" Case sensitive stuff + +syn keyword laceTodo TODO XXX FIXME +syn match laceClassName "\<[A-Z][A-Z0-9_]*\>" +syn match laceCluster "[a-zA-Z][a-zA-Z0-9_]*\s*:" +syn match laceCluster "[a-zA-Z][a-zA-Z0-9_]*\s*(\s*[a-zA-Z][a-zA-Z0-9_]*\s*)\s*:" + +" Catch mismatched parentheses +syn match laceParenError ")" +syn match laceBracketError "\]" +syn region laceGeneric transparent matchgroup=laceBrackets start="\[" end="\]" contains=ALLBUT,laceBracketError +syn region laceParen transparent start="(" end=")" contains=ALLBUT,laceParenError + +" Should suffice for even very long strings and expressions +syn sync lines=40 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link laceTopStruct PreProc + +hi def link laceOptionClause Statement +hi def link laceOptionMark Constant +hi def link laceClusterProp Label +hi def link laceAdaptClassName Label +hi def link laceExternal Statement +hi def link laceCluster ModeMsg + +hi def link laceEscape Special + +hi def link laceBool Boolean +hi def link laceString String +hi def link laceCharacter Character +hi def link laceClassName Type +hi def link laceNumber Number + +hi def link laceOperator Special +hi def link laceArray Special +hi def link laceExport Special +hi def link laceCreation Special +hi def link laceBrackets Special +hi def link laceConstraint Special + +hi def link laceComment Comment + +hi def link laceError Error +hi def link laceStringError Error +hi def link laceParenError Error +hi def link laceBracketError Error +hi def link laceTodo Todo + + +let b:current_syntax = "lace" + +" vim: ts=4 + +endif diff --git a/syntax/latte.vim b/syntax/latte.vim new file mode 100644 index 0000000..f0258fd --- /dev/null +++ b/syntax/latte.vim @@ -0,0 +1,85 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Latte +" Maintainer: Nick Moffitt, +" Last Change: 14 June, 2000 +" +" Notes: +" I based this on the TeX and Scheme syntax files (but mostly scheme). +" See http://www.latte.org for info on the language. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match latteError "[{}\\]" +syn match latteOther "\\{" +syn match latteOther "\\}" +syn match latteOther "\\\\" + +setlocal iskeyword=33,43,45,48-57,63,65-90,95,97-122,_ + +syn region latteVar matchgroup=SpecialChar start=!\\[A-Za-z_]!rs=s+1 end=![^A-Za-z0-9?!+_-]!me=e-1 contains=ALLBUT,latteNumber,latteOther +syn region latteVar matchgroup=SpecialChar start=!\\[=\&][A-Za-z_]!rs=s+2 end=![^A-Za-z0-9?!+_-]!me=e-1 contains=ALLBUT,latteNumber,latteOther +syn region latteString start=+\\"+ skip=+\\\\"+ end=+\\"+ + +syn region latteGroup matchgroup=Delimiter start="{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=ALLBUT,latteSyntax + +syn region latteUnquote matchgroup=Delimiter start="\\,{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=ALLBUT,latteSyntax +syn region latteSplice matchgroup=Delimiter start="\\,@{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=ALLBUT,latteSyntax +syn region latteQuote matchgroup=Delimiter start="\\'{" skip="\\[{}]" matchgroup=Delimiter end="}" +syn region latteQuote matchgroup=Delimiter start="\\`{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=latteUnquote,latteSplice + +syn match latteOperator '\\/' +syn match latteOperator '=' + +syn match latteComment "\\;.*$" + +" This was gathered by slurping in the index. + +syn keyword latteSyntax __FILE__ __latte-version__ contained +syn keyword latteSyntax _bal-tag _pre _tag add and append apply back contained +syn keyword latteSyntax caar cadr car cdar cddr cdr ceil compose contained +syn keyword latteSyntax concat cons def defmacro divide downcase contained +syn keyword latteSyntax empty? equal? error explode file-contents contained +syn keyword latteSyntax floor foreach front funcall ge? getenv contained +syn keyword latteSyntax greater-equal? greater? group group? gt? html contained +syn keyword latteSyntax if include lambda le? length less-equal? contained +syn keyword latteSyntax less? let lmap load-file load-library lt? macro contained +syn keyword latteSyntax member? modulo multiply not nth operator? contained +syn keyword latteSyntax or ordinary quote process-output push-back contained +syn keyword latteSyntax push-front quasiquote quote random rdc reverse contained +syn keyword latteSyntax set! snoc splicing unquote strict-html4 contained +syn keyword latteSyntax string-append string-ge? string-greater-equal? contained +syn keyword latteSyntax string-greater? string-gt? string-le? contained +syn keyword latteSyntax string-less-equal? string-less? string-lt? contained +syn keyword latteSyntax string? subseq substr subtract contained +syn keyword latteSyntax upcase useless warn while zero? contained + + +" If it's good enough for scheme... + +syn sync match matchPlace grouphere NONE "^[^ \t]" +" ... i.e. synchronize on a line that starts at the left margin + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link latteSyntax Statement +hi def link latteVar Function + +hi def link latteString String +hi def link latteQuote String + +hi def link latteDelimiter Delimiter +hi def link latteOperator Operator + +hi def link latteComment Comment +hi def link latteError Error + + +let b:current_syntax = "latte" + +endif diff --git a/syntax/ld.vim b/syntax/ld.vim new file mode 100644 index 0000000..aa97255 --- /dev/null +++ b/syntax/ld.vim @@ -0,0 +1,85 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: ld(1) script +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword ldTodo contained TODO FIXME XXX NOTE + +syn region ldComment start='/\*' end='\*/' contains=ldTodo,@Spell + +syn region ldFileName start=+"+ end=+"+ + +syn keyword ldPreProc SECTIONS MEMORY OVERLAY PHDRS VERSION INCLUDE +syn match ldPreProc '\' + +syn match ldNumber display '\<0[xX]\x\+\>' +syn match ldNumber display '\d\+[KM]\>' contains=ldNumberMult +syn match ldNumberMult display '[KM]\>' +syn match ldOctal contained display '\<0\o\+\>' + \ contains=ldOctalZero +syn match ldOctalZero contained display '\<0' +syn match ldOctalError contained display '\<0\o*[89]\d*\>' + + +hi def link ldTodo Todo +hi def link ldComment Comment +hi def link ldFileName String +hi def link ldPreProc PreProc +hi def link ldFunction Identifier +hi def link ldKeyword Keyword +hi def link ldType Type +hi def link ldDataType ldType +hi def link ldOutputType ldType +hi def link ldPTType ldType +hi def link ldSpecial Special +hi def link ldIdentifier Identifier +hi def link ldSections Constant +hi def link ldSpecSections Special +hi def link ldNumber Number +hi def link ldNumberMult PreProc +hi def link ldOctal ldNumber +hi def link ldOctalZero PreProc +hi def link ldOctalError Error + +let b:current_syntax = "ld" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/ldapconf.vim b/syntax/ldapconf.vim new file mode 100644 index 0000000..30be6c4 --- /dev/null +++ b/syntax/ldapconf.vim @@ -0,0 +1,342 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: ldap.conf(5) configuration file. +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-12-11 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword ldapconfTodo contained TODO FIXME XXX NOTE + +syn region ldapconfComment display oneline start='^\s*#' end='$' + \ contains=ldapconfTodo, + \ @Spell + +syn match ldapconfBegin display '^' + \ nextgroup=ldapconfOption, + \ ldapconfDeprOption, + \ ldapconfComment + +syn case ignore + +syn keyword ldapconfOption contained URI + \ nextgroup=ldapconfURI + \ skipwhite + +syn keyword ldapconfOption contained + \ BASE + \ BINDDN + \ nextgroup=ldapconfDNAttrType + \ skipwhite + +syn keyword ldapconfDeprOption contained + \ HOST + \ nextgroup=ldapconfHost + \ skipwhite + +syn keyword ldapconfDeprOption contained + \ PORT + \ nextgroup=ldapconfPort + \ skipwhite + +syn keyword ldapconfOption contained + \ REFERRALS + \ nextgroup=ldapconfBoolean + \ skipwhite + +syn keyword ldapconfOption contained + \ SIZELIMIT + \ TIMELIMIT + \ nextgroup=ldapconfInteger + \ skipwhite + +syn keyword ldapconfOption contained + \ DEREF + \ nextgroup=ldapconfDerefWhen + \ skipwhite + +syn keyword ldapconfOption contained + \ SASL_MECH + \ nextgroup=ldapconfSASLMechanism + \ skipwhite + +syn keyword ldapconfOption contained + \ SASL_REALM + \ nextgroup=ldapconfSASLRealm + \ skipwhite + +syn keyword ldapconfOption contained + \ SASL_AUTHCID + \ SASL_AUTHZID + \ nextgroup=ldapconfSASLAuthID + \ skipwhite + +syn keyword ldapconfOption contained + \ SASL_SECPROPS + \ nextgroup=ldapconfSASLSecProps + \ skipwhite + +syn keyword ldapconfOption contained + \ TLS_CACERT + \ TLS_CERT + \ TLS_KEY + \ TLS_RANDFILE + \ nextgroup=ldapconfFilename + \ skipwhite + +syn keyword ldapconfOption contained + \ TLS_CACERTDIR + \ nextgroup=ldapconfPath + \ skipwhite + +syn keyword ldapconfOption contained + \ TLS_CIPHER_SUITE + \ nextgroup=@ldapconfTLSCipher + \ skipwhite + +syn keyword ldapconfOption contained + \ TLS_REQCERT + \ nextgroup=ldapconfTLSCertCheck + \ skipwhite + +syn keyword ldapconfOption contained + \ TLS_CRLCHECK + \ nextgroup=ldapconfTLSCRLCheck + \ skipwhite + +syn case match + +syn match ldapconfURI contained display + \ 'ldaps\=://[^[:space:]:]\+\%(:\d\+\)\=' + \ nextgroup=ldapconfURI + \ skipwhite + +" LDAP Distinguished Names are defined in Section 3 of RFC 2253: +" http://www.ietf.org/rfc/rfc2253.txt. +syn match ldapconfDNAttrType contained display + \ '\a[a-zA-Z0-9-]\+\|\d\+\%(\.\d\+\)*' + \ nextgroup=ldapconfDNAttrTypeEq + +syn match ldapconfDNAttrTypeEq contained display + \ '=' + \ nextgroup=ldapconfDNAttrValue + +syn match ldapconfDNAttrValue contained display + \ '\%([^,=+<>#;\\"]\|\\\%([,=+<>#;\\"]\|\x\x\)\)*\|#\%(\x\x\)\+\|"\%([^\\"]\|\\\%([,=+<>#;\\"]\|\x\x\)\)*"' + \ nextgroup=ldapconfDNSeparator + +syn match ldapconfDNSeparator contained display + \ '[+,]' + \ nextgroup=ldapconfDNAttrType + +syn match ldapconfHost contained display + \ '[^[:space:]:]\+\%(:\d\+\)\=' + \ nextgroup=ldapconfHost + \ skipwhite + +syn match ldapconfPort contained display + \ '\d\+' + +syn keyword ldapconfBoolean contained + \ on + \ true + \ yes + \ off + \ false + \ no + +syn match ldapconfInteger contained display + \ '\d\+' + +syn keyword ldapconfDerefWhen contained + \ never + \ searching + \ finding + \ always + +" Taken from http://www.iana.org/assignments/sasl-mechanisms. +syn keyword ldapconfSASLMechanism contained + \ KERBEROS_V4 + \ GSSAPI + \ SKEY + \ EXTERNAL + \ ANONYMOUS + \ OTP + \ PLAIN + \ SECURID + \ NTLM + \ NMAS_LOGIN + \ NMAS_AUTHEN + \ KERBEROS_V5 + +syn match ldapconfSASLMechanism contained display + \ 'CRAM-MD5\|GSS-SPNEGO\|DIGEST-MD5\|9798-[UM]-\%(RSA-SHA1-ENC\|\%(EC\)\=DSA-SHA1\)\|NMAS-SAMBA-AUTH' + +" TODO: I have been unable to find a definition for a SASL realm, +" authentication identity, and proxy authorization identity. +syn match ldapconfSASLRealm contained display + \ '\S\+' + +syn match ldapconfSASLAuthID contained display + \ '\S\+' + +syn keyword ldapconfSASLSecProps contained + \ none + \ noplain + \ noactive + \ nodict + \ noanonymous + \ forwardsec + \ passcred + \ nextgroup=ldapconfSASLSecPSep + +syn keyword ldapconfSASLSecProps contained + \ minssf + \ maxssf + \ maxbufsize + \ nextgroup=ldapconfSASLSecPEq + +syn match ldapconfSASLSecPEq contained display + \ '=' + \ nextgroup=ldapconfSASLSecFactor + +syn match ldapconfSASLSecFactor contained display + \ '\d\+' + \ nextgroup=ldapconfSASLSecPSep + +syn match ldapconfSASLSecPSep contained display + \ ',' + \ nextgroup=ldapconfSASLSecProps + +syn match ldapconfFilename contained display + \ '.\+' + +syn match ldapconfPath contained display + \ '.\+' + +" Defined in openssl-ciphers(1). +" TODO: Should we include the stuff under CIPHER SUITE NAMES? +syn cluster ldapconfTLSCipher contains=ldapconfTLSCipherOp, + \ ldapconfTLSCipherName, + \ ldapconfTLSCipherSort + +syn match ldapconfTLSCipherOp contained display + \ '[+!-]' + \ nextgroup=ldapconfTLSCipherName + +syn keyword ldapconfTLSCipherName contained + \ DEFAULT + \ COMPLEMENTOFDEFAULT + \ ALL + \ COMPLEMENTOFALL + \ HIGH + \ MEDIUM + \ LOW + \ EXP + \ EXPORT + \ EXPORT40 + \ EXPORT56 + \ eNULL + \ NULL + \ aNULL + \ kRSA + \ RSA + \ kEDH + \ kDHr + \ kDHd + \ aRSA + \ aDSS + \ DSS + \ aDH + \ kFZA + \ aFZA + \ eFZA + \ FZA + \ TLSv1 + \ SSLv3 + \ SSLv2 + \ DH + \ ADH + \ AES + \ 3DES + \ DES + \ RC4 + \ RC2 + \ IDEA + \ MD5 + \ SHA1 + \ SHA + \ Camellia + \ nextgroup=ldapconfTLSCipherSep + +syn match ldapconfTLSCipherSort contained display + \ '@STRENGTH' + \ nextgroup=ldapconfTLSCipherSep + +syn match ldapconfTLSCipherSep contained display + \ '[:, ]' + \ nextgroup=@ldapconfTLSCipher + +syn keyword ldapconfTLSCertCheck contained + \ never + \ allow + \ try + \ demand + \ hard + +syn keyword ldapconfTLSCRLCheck contained + \ none + \ peer + \ all + +hi def link ldapconfTodo Todo +hi def link ldapconfComment Comment +hi def link ldapconfOption Keyword +hi def link ldapconfDeprOption Error +hi def link ldapconfString String +hi def link ldapconfURI ldapconfString +hi def link ldapconfDNAttrType Identifier +hi def link ldapconfOperator Operator +hi def link ldapconfEq ldapconfOperator +hi def link ldapconfDNAttrTypeEq ldapconfEq +hi def link ldapconfValue ldapconfString +hi def link ldapconfDNAttrValue ldapconfValue +hi def link ldapconfSeparator ldapconfOperator +hi def link ldapconfDNSeparator ldapconfSeparator +hi def link ldapconfHost ldapconfURI +hi def link ldapconfNumber Number +hi def link ldapconfPort ldapconfNumber +hi def link ldapconfBoolean Boolean +hi def link ldapconfInteger ldapconfNumber +hi def link ldapconfType Type +hi def link ldapconfDerefWhen ldapconfType +hi def link ldapconfDefine Define +hi def link ldapconfSASLMechanism ldapconfDefine +hi def link ldapconfSASLRealm ldapconfURI +hi def link ldapconfSASLAuthID ldapconfValue +hi def link ldapconfSASLSecProps ldapconfType +hi def link ldapconfSASLSecPEq ldapconfEq +hi def link ldapconfSASLSecFactor ldapconfNumber +hi def link ldapconfSASLSecPSep ldapconfSeparator +hi def link ldapconfFilename ldapconfString +hi def link ldapconfPath ldapconfFilename +hi def link ldapconfTLSCipherOp ldapconfOperator +hi def link ldapconfTLSCipherName ldapconfDefine +hi def link ldapconfSpecial Special +hi def link ldapconfTLSCipherSort ldapconfSpecial +hi def link ldapconfTLSCipherSep ldapconfSeparator +hi def link ldapconfTLSCertCheck ldapconfType +hi def link ldapconfTLSCRLCheck ldapconfType + +let b:current_syntax = "ldapconf" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/ldif.vim b/syntax/ldif.vim new file mode 100644 index 0000000..9f6967e --- /dev/null +++ b/syntax/ldif.vim @@ -0,0 +1,37 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: LDAP LDIF +" Maintainer: Zak Johnson +" Last Change: 2003-12-30 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn sync minlines=10 linebreaks=1 + +syn match ldifAttribute /^[^ #][^:]*/ contains=ldifOption display +syn match ldifOption /;[^:]\+/ contained contains=ldifPunctuation display +syn match ldifPunctuation /;/ contained display + +syn region ldifStringValue matchgroup=ldifPunctuation start=/: / end=/\_$/ skip=/\n / +syn region ldifBase64Value matchgroup=ldifPunctuation start=/:: / end=/\_$/ skip=/\n / +syn region ldifFileValue matchgroup=ldifPunctuation start=/:< / end=/\_$/ skip=/\n / + +syn region ldifComment start=/^#/ end=/\_$/ skip=/\n / + + +hi def link ldifAttribute Type +hi def link ldifOption Identifier +hi def link ldifPunctuation Normal +hi def link ldifStringValue String +hi def link ldifBase64Value Special +hi def link ldifFileValue Special +hi def link ldifComment Comment + + +let b:current_syntax = "ldif" + +endif diff --git a/syntax/less.vim b/syntax/less.vim index c856e6a..048a6c8 100644 --- a/syntax/less.vim +++ b/syntax/less.vim @@ -1,3 +1,86 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: less +" Maintainer: Alessandro Vioni +" URL: https://github.com/genoma/vim-less +" Last Change: 2014 November 24 + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/css.vim +runtime! after/syntax/css.vim + +syn case ignore + +syn cluster lessCssProperties contains=cssFontProp,cssFontDescriptorProp,cssColorProp,cssTextProp,cssBoxProp,cssGeneratedContentProp,cssPagingProp,cssUIProp,cssRenderProp,cssAuralProp,cssTableProp +syn cluster lessCssAttributes contains=css.*Attr,lessEndOfLineComment,lessComment,cssValue.*,cssColor,cssURL,lessDefault,cssImportant,cssError,cssStringQ,cssStringQQ,cssFunction,cssUnicodeEscape,cssRenderProp + +syn region lessDefinition matchgroup=cssBraces start="{" end="}" contains=TOP + +syn match lessProperty "\%([{};]\s*\|^\)\@<=\%([[:alnum:]-]\|#{[^{}]*}\)\+\s*:" contains=css.*Prop skipwhite nextgroup=lessCssAttribute contained containedin=lessDefinition +syn match lessProperty "^\s*\zs\s\%(\%([[:alnum:]-]\|#{[^{}]*}\)\+\s*:\|:[[:alnum:]-]\+\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=lessCssAttribute +syn match lessProperty "^\s*\zs\s\%(:\=[[:alnum:]-]\+\s*=\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=lessCssAttribute +syn match lessCssAttribute +\%("\%([^"]\|\\"\)*"\|'\%([^']\|\\'\)*'\|#{[^{}]*}\|[^{};]\)*+ contained contains=@lessCssAttributes,lessVariable,lessFunction,lessInterpolation +syn match lessDefault "!default\>" contained + +" less variables and media queries +syn match lessVariable "@[[:alnum:]_-]\+" nextgroup=lessCssAttribute skipwhite +syn match lessMedia "@media" nextgroup=lessCssAttribute skipwhite + +" Less functions +syn match lessFunction "\<\%(escape\|e\|unit\)\>(\@=" contained +syn match lessFunction "\<\%(ceil\|floor\|percentage\|round\|sqrt\|abs\|sin\|asin\|cos\|acos\|tan\|atan\|pi\|pow\|min\|max\)\>(\@=" contained +syn match lessFunction "\<\%(rgb\|rgba\|argb\|argb\|hsl\|hsla\|hsv\|hsva\)\>(\@=" contained +syn match lessFunction "\<\%(hue\|saturation\|lightness\|red\|green\|blue\|alpha\|luma\)\>(\@=" contained +syn match lessFunction "\<\%(saturate\|desaturate\|lighten\|darken\|fadein\|fadeout\|fade\|spin\|mix\|greyscale\|contrast\)\>(\@=" contained +syn match lessFunction "\<\%(multiply\|screen\|overlay\|softlight\|hardlight\|difference\|exclusion\|average\|negation\)\>(\@=" contained + +" Less id class visualization +syn match lessIdChar "#[[:alnum:]_-]\@=" nextgroup=lessId,lessClassIdCall +syn match lessId "[[:alnum:]_-]\+" contained +syn match lessClassIdCall "[[:alnum:]_-]\+()" contained + +syn match lessClassChar "\.[[:alnum:]_-]\@=" nextgroup=lessClass,lessClassCall +syn match lessClass "[[:alnum:]_-]\+" contained +syn match lessClassCall "[[:alnum:]_-]\+()" contained + +syn match lessAmpersand "&" contains=lessIdChar,lessClassChar + +syn region lessInclude start="@import" end=";\|$" contains=lessComment,cssURL,cssUnicodeEscape,cssMediaType,cssStringQ,cssStringQQ + +syn keyword lessTodo FIXME NOTE TODO OPTIMIZE XXX contained +syn region lessComment start="^\z(\s*\)//" end="^\%(\z1 \)\@!" contains=lessTodo,@Spell +syn region lessCssComment start="^\z(\s*\)/\*" end="^\%(\z1 \)\@!" contains=lessTodo,@Spell +syn match lessEndOfLineComment "//.*" contains=lessComment,lessTodo,@Spell + +hi def link lessEndOfLineComment lessComment +hi def link lessCssComment lessComment +hi def link lessComment Comment +hi def link lessDefault cssImportant +hi def link lessVariable Identifier +hi def link lessFunction PreProc +hi def link lessTodo Todo +hi def link lessInclude Include +hi def link lessIdChar Special +hi def link lessClassChar Special +hi def link lessAmpersand Character +hi def link lessId Identifier +hi def link lessClass Type +hi def link lessCssAttribute PreProc +hi def link lessClassCall Type +hi def link lessClassIdCall Type +hi def link lessTagName cssTagName +hi def link lessDeprecated cssDeprecated +hi def link lessMedia cssMedia + +let b:current_syntax = "less" + +" vim:set sw=2: + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'less') == -1 if exists("b:current_syntax") diff --git a/syntax/lex.vim b/syntax/lex.vim new file mode 100644 index 0000000..1c535e7 --- /dev/null +++ b/syntax/lex.vim @@ -0,0 +1,147 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Lex +" Maintainer: Charles E. Campbell +" Last Change: Aug 31, 2016 +" Version: 16 +" URL: http://mysite.verizon.net/astronaut/vim/index.html#SYNTAX_LEX +" +" Option: +" lex_uses_cpp : if this variable exists, then C++ is loaded rather than C + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read the C/C++ syntax to start with +let s:Cpath= fnameescape(expand(":p:h").(exists("g:lex_uses_cpp")? "/cpp.vim" : "/c.vim")) +if !filereadable(s:Cpath) + for s:Cpath in split(globpath(&rtp,(exists("g:lex_uses_cpp")? "syntax/cpp.vim" : "syntax/c.vim")),"\n") + if filereadable(fnameescape(s:Cpath)) + let s:Cpath= fnameescape(s:Cpath) + break + endif + endfor +endif +exe "syn include @lexCcode ".s:Cpath + +" --- ========= --- +" --- Lex stuff --- +" --- ========= --- + +" Options Section +syn match lexOptions '^%\s*option\>.*$' contains=lexPatString + +" Abbreviations Section +if has("folding") + syn region lexAbbrvBlock fold start="^\(\h\+\s\|%{\)" end="^\ze%%$" skipnl nextgroup=lexPatBlock contains=lexAbbrv,lexInclude,lexAbbrvComment,lexStartState +else + syn region lexAbbrvBlock start="^\(\h\+\s\|%{\)" end="^\ze%%$" skipnl nextgroup=lexPatBlock contains=lexAbbrv,lexInclude,lexAbbrvComment,lexStartState +endif +syn match lexAbbrv "^\I\i*\s"me=e-1 skipwhite contained nextgroup=lexAbbrvRegExp +syn match lexAbbrv "^%[sx]" contained +syn match lexAbbrvRegExp "\s\S.*$"lc=1 contained nextgroup=lexAbbrv,lexInclude +if has("folding") + syn region lexInclude fold matchgroup=lexSep start="^%{" end="%}" contained contains=@lexCcode + syn region lexAbbrvComment fold start="^\s\+/\*" end="\*/" contains=@Spell + syn region lexAbbrvComment fold start="\%^/\*" end="\*/" contains=@Spell + syn region lexStartState fold matchgroup=lexAbbrv start="^%\a\+" end="$" contained +else + syn region lexInclude matchgroup=lexSep start="^%{" end="%}" contained contains=@lexCcode + syn region lexAbbrvComment start="^\s\+/\*" end="\*/" contains=@Spell + syn region lexAbbrvComment start="\%^/\*" end="\*/" contains=@Spell + syn region lexStartState matchgroup=lexAbbrv start="^%\a\+" end="$" contained +endif + +"%% : Patterns {Actions} +if has("folding") + syn region lexPatBlock fold matchgroup=Todo start="^%%$" matchgroup=Todo end="^%\ze%$" skipnl skipwhite nextgroup=lexFinalCodeBlock contains=lexPatTag,lexPatTagZone,lexPatComment,lexPat,lexPatInclude + syn region lexPat fold start=+\S+ skip="\\\\\|\\." end="\s"me=e-1 skipwhite contained nextgroup=lexMorePat,lexPatSep,lexPattern contains=lexPatTag,lexPatString,lexSlashQuote,lexBrace + syn region lexPatInclude fold matchgroup=lexSep start="^%{" end="%}" contained contains=lexPatCode + syn region lexBrace fold start="\[" skip=+\\\\\|\\+ end="]" contained + syn region lexPatString fold matchgroup=String start=+"+ skip=+\\\\\|\\"+ matchgroup=String end=+"+ contained +else + syn region lexPatBlock matchgroup=Todo start="^%%$" matchgroup=Todo end="^%%$" skipnl skipwhite nextgroup=lexFinalCodeBlock contains=lexPatTag,lexPatTagZone,lexPatComment,lexPat,lexPatInclude + syn region lexPat start=+\S+ skip="\\\\\|\\." end="\s"me=e-1 skipwhite contained nextgroup=lexMorePat,lexPatSep,lexPattern contains=lexPatTag,lexPatString,lexSlashQuote,lexBrace + syn region lexPatInclude matchgroup=lexSep start="^%{" end="%}" contained contains=lexPatCode + syn region lexBrace start="\[" skip=+\\\\\|\\+ end="]" contained + syn region lexPatString matchgroup=String start=+"+ skip=+\\\\\|\\"+ matchgroup=String end=+"+ contained +endif +syn match lexPatTag "^<\I\i*\(,\I\i*\)*>" contained nextgroup=lexPat,lexPatTag,lexMorePat,lexPatSep +syn match lexPatTagZone "^<\I\i*\(,\I\i*\)*>\s\+\ze{" contained nextgroup=lexPatTagZoneStart +syn match lexPatTag +^<\I\i*\(,\I\i*\)*>*\(\\\\\)*\\"+ contained nextgroup=lexPat,lexPatTag,lexMorePat,lexPatSep + +" Lex Patterns +syn region lexPattern start='[^ \t{}]' end="$" contained contains=lexPatRange +syn region lexPatRange matchgroup=Delimiter start='\[' skip='\\\\\|\\.' end='\]' contains=lexEscape +syn match lexEscape '\%(\\\\\)*\\.' contained + +if has("folding") + syn region lexPatTagZoneStart matchgroup=lexPatTag fold start='{' end='}' contained contains=lexPat,lexPatComment + syn region lexPatComment start="\s\+/\*" end="\*/" fold skipnl contained contains=cTodo skipwhite nextgroup=lexPatComment,lexPat,@Spell +else + syn region lexPatTagZoneStart matchgroup=lexPatTag start='{' end='}' contained contains=lexPat,lexPatComment + syn region lexPatComment start="\s\+/\*" end="\*/" skipnl contained contains=cTodo skipwhite nextgroup=lexPatComment,lexPat,@Spell +endif +syn match lexPatCodeLine "[^{\[].*" contained contains=@lexCcode +syn match lexMorePat "\s*|\s*$" skipnl contained nextgroup=lexPat,lexPatTag,lexPatComment +syn match lexPatSep "\s\+" contained nextgroup=lexMorePat,lexPatCode,lexPatCodeLine +syn match lexSlashQuote +\(\\\\\)*\\"+ contained +if has("folding") + syn region lexPatCode matchgroup=Delimiter start="{" end="}" fold skipnl contained contains=@lexCcode,lexCFunctions +else + syn region lexPatCode matchgroup=Delimiter start="{" end="}" skipnl contained contains=@lexCcode,lexCFunctions +endif + +" Lex "functions" which may appear in C/C++ code blocks +syn keyword lexCFunctions BEGIN input unput woutput yyleng yylook yytext +syn keyword lexCFunctions ECHO output winput wunput yyless yymore yywrap + +" %% +" lexAbbrevBlock +" %% +" lexPatBlock +" %% +" lexFinalCodeBlock +syn region lexFinalCodeBlock matchgroup=Todo start="%$"me=e-1 end="\%$" contained contains=@lexCcode + +" includes several ALLBUTs; these have to be treated so as to exclude lex* groups +syn cluster cParenGroup add=lex.* +syn cluster cDefineGroup add=lex.* +syn cluster cPreProcGroup add=lex.* +syn cluster cMultiGroup add=lex.* + +" Synchronization +syn sync clear +syn sync minlines=500 +syn sync match lexSyncPat grouphere lexPatBlock "^%[a-zA-Z]" +syn sync match lexSyncPat groupthere lexPatBlock "^<$" +syn sync match lexSyncPat groupthere lexPatBlock "^%%$" + +" The default highlighting. +if !exists("skip_lex_syntax_inits") + hi def link lexAbbrvComment lexPatComment + hi def link lexAbbrvRegExp Macro + hi def link lexAbbrv SpecialChar + hi def link lexBrace lexPat + hi def link lexCFunctions Function + hi def link lexCstruct cStructure + hi def link lexMorePat SpecialChar + hi def link lexOptions PreProc + hi def link lexPatComment Comment + hi def link lexPat Function + hi def link lexPatString Function + hi def link lexPatTag Special + hi def link lexPatTagZone lexPatTag + hi def link lexSep Delimiter + hi def link lexSlashQuote lexPat + hi def link lexStartState Statement +endif + +let b:current_syntax = "lex" + +" vim:ts=10 + +endif diff --git a/syntax/lftp.vim b/syntax/lftp.vim new file mode 100644 index 0000000..990e71a --- /dev/null +++ b/syntax/lftp.vim @@ -0,0 +1,156 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: lftp(1) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2007-06-17 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword+=- + +syn region lftpComment display oneline start='#' end='$' + \ contains=lftpTodo,@Spell + +syn keyword lftpTodo contained TODO FIXME XXX NOTE + +syn region lftpString contained display + \ start=+"+ skip=+\\$\|\\"+ end=+"+ end=+$+ + +syn match lftpNumber contained display '\<\d\+\(\.\d\+\)\=\>' + +syn keyword lftpBoolean contained yes no on off true false + +syn keyword lftpInterval contained infinity inf never forever +syn match lftpInterval contained '\<\(\d\+\(\.\d\+\)\=[dhms]\)\+\>' + +syn keyword lftpKeywords alias anon at bookmark cache cat cd chmod close + \ cls command debug du echo exit fg find get + \ get1 glob help history jobs kill lcd lftp + \ lpwd ls mget mirror mkdir module more mput + \ mrm mv nlist open pget put pwd queue quote + \ reget recls rels renlist repeat reput rm + \ rmdir scache site source suspend user version + \ wait zcat zmore + +syn region lftpSet matchgroup=lftpKeywords + \ start="set" end=";" end="$" + \ contains=lftpString,lftpNumber,lftpBoolean, + \ lftpInterval,lftpSettingsPrefix,lftpSettings +syn match lftpSettingsPrefix contained '\<\%(bmk\|cache\|cmd\|color\|dns\):' +syn match lftpSettingsPrefix contained '\<\%(file\|fish\|ftp\|hftp\):' +syn match lftpSettingsPrefix contained '\<\%(http\|https\|mirror\|module\):' +syn match lftpSettingsPrefix contained '\<\%(net\|sftp\|ssl\|xfer\):' +" bmk: +syn keyword lftpSettings contained save-p[asswords] +" cache: +syn keyword lftpSettings contained cache-em[pty-listings] en[able] + \ exp[ire] siz[e] +" cmd: +syn keyword lftpSettings contained at[-exit] cls-c[ompletion-default] + \ cls-d[efault] cs[h-history] + \ default-p[rotocol] default-t[itle] +syn keyword lftpSettings contained fai[l-exit] in[teractive] + \ lo[ng-running] ls[-default] mo[ve-background] + \ prom[pt] + \ rem[ote-completion] + \ save-c[wd-history] save-r[l-history] + \ set-t[erm-status] statu[s-interval] + \ te[rm-status] verb[ose] verify-h[ost] + \ verify-path verify-path[-cached] +" color: +syn keyword lftpSettings contained dir[-colors] use-c[olor] +" dns: +syn keyword lftpSettings contained S[RV-query] cache-en[able] + \ cache-ex[pire] cache-s[ize] + \ fat[al-timeout] o[rder] use-fo[rk] +" file: +syn keyword lftpSettings contained ch[arset] +" fish: +syn keyword lftpSettings contained connect[-program] sh[ell] +" ftp: +syn keyword lftpSettings contained acct anon-p[ass] anon-u[ser] + \ au[to-sync-mode] b[ind-data-socket] + \ ch[arset] cli[ent] dev[ice-prefix] + \ fi[x-pasv-address] fxp-f[orce] + \ fxp-p[assive-source] h[ome] la[ng] + \ list-e[mpty-ok] list-o[ptions] + \ nop[-interval] pas[sive-mode] + \ port-i[pv4] port-r[ange] prox[y] + \ rest-l[ist] rest-s[tor] + \ retry-530 retry-530[-anonymous] + \ sit[e-group] skey-a[llow] + \ skey-f[orce] ssl-allow + \ ssl-allow[-anonymous] ssl-au[th] + \ ssl-f[orce] ssl-protect-d[ata] + \ ssl-protect-l[ist] stat-[interval] + \ sy[nc-mode] timez[one] use-a[bor] + \ use-fe[at] use-fx[p] use-hf[tp] + \ use-mdtm use-mdtm[-overloaded] + \ use-ml[sd] use-p[ret] use-q[uit] + \ use-site-c[hmod] use-site-i[dle] + \ use-site-u[time] use-siz[e] + \ use-st[at] use-te[lnet-iac] + \ verify-a[ddress] verify-p[ort] + \ w[eb-mode] +" hftp: +syn keyword lftpSettings contained w[eb-mode] cache prox[y] + \ use-au[thorization] use-he[ad] use-ty[pe] +" http: +syn keyword lftpSettings contained accept accept-c[harset] + \ accept-l[anguage] cache coo[kie] + \ pos[t-content-type] prox[y] + \ put-c[ontent-type] put-m[ethod] ref[erer] + \ set-c[ookies] user[-agent] +" https: +syn keyword lftpSettings contained prox[y] +" mirror: +syn keyword lftpSettings contained exc[lude-regex] o[rder] + \ parallel-d[irectories] + \ parallel-t[ransfer-count] use-p[get-n] +" module: +syn keyword lftpSettings contained pat[h] +" net: +syn keyword lftpSettings contained connection-l[imit] + \ connection-t[akeover] id[le] limit-m[ax] + \ limit-r[ate] limit-total-m[ax] + \ limit-total-r[ate] max-ret[ries] no-[proxy] + \ pe[rsist-retries] reconnect-interval-b[ase] + \ reconnect-interval-ma[x] + \ reconnect-interval-mu[ltiplier] + \ socket-bind-ipv4 socket-bind-ipv6 + \ socket-bu[ffer] socket-m[axseg] timeo[ut] +" sftp: +syn keyword lftpSettings contained connect[-program] + \ max-p[ackets-in-flight] prot[ocol-version] + \ ser[ver-program] size-r[ead] size-w[rite] +" ssl: +syn keyword lftpSettings contained ca-f[ile] ca-p[ath] ce[rt-file] + \ crl-f[ile] crl-p[ath] k[ey-file] + \ verify-c[ertificate] +" xfer: +syn keyword lftpSettings contained clo[bber] dis[k-full-fatal] + \ eta-p[eriod] eta-t[erse] mak[e-backup] + \ max-red[irections] ra[te-period] + +hi def link lftpComment Comment +hi def link lftpTodo Todo +hi def link lftpString String +hi def link lftpNumber Number +hi def link lftpBoolean Boolean +hi def link lftpInterval Number +hi def link lftpKeywords Keyword +hi def link lftpSettingsPrefix PreProc +hi def link lftpSettings Type + +let b:current_syntax = "lftp" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/lhaskell.vim b/syntax/lhaskell.vim new file mode 100644 index 0000000..3aa2f9c --- /dev/null +++ b/syntax/lhaskell.vim @@ -0,0 +1,127 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Haskell with literate comments, Bird style, +" TeX style and plain text surrounding +" \begin{code} \end{code} blocks +" Maintainer: Haskell Cafe mailinglist +" Original Author: Arthur van Leeuwen +" Last Change: 2010 Apr 11 +" Version: 1.04 +" +" Thanks to Ian Lynagh for thoughtful comments on initial versions and +" for the inspiration for writing this in the first place. +" +" This style guesses as to the type of markup used in a literate haskell +" file and will highlight (La)TeX markup if it finds any +" This behaviour can be overridden, both glabally and locally using +" the lhs_markup variable or b:lhs_markup variable respectively. +" +" lhs_markup must be set to either tex or none to indicate that +" you always want (La)TeX highlighting or no highlighting +" must not be set to let the highlighting be guessed +" b:lhs_markup must be set to eiterh tex or none to indicate that +" you want (La)TeX highlighting or no highlighting for +" this particular buffer +" must not be set to let the highlighting be guessed +" +" +" 2004 February 18: New version, based on Ian Lynagh's TeX guessing +" lhaskell.vim, cweb.vim, tex.vim, sh.vim and fortran.vim +" 2004 February 20: Cleaned up the guessing and overriding a bit +" 2004 February 23: Cleaned up syntax highlighting for \begin{code} and +" \end{code}, added some clarification to the attributions +" 2008 July 1: Removed % from guess list, as it totally breaks plain +" text markup guessing +" 2009 April 29: Fixed highlighting breakage in TeX mode, +" thanks to Kalman Noel +" + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" First off, see if we can inherit a user preference for lhs_markup +if !exists("b:lhs_markup") + if exists("lhs_markup") + if lhs_markup =~ '\<\%(tex\|none\)\>' + let b:lhs_markup = matchstr(lhs_markup,'\<\%(tex\|none\)\>') + else + echohl WarningMsg | echo "Unknown value of lhs_markup" | echohl None + let b:lhs_markup = "unknown" + endif + else + let b:lhs_markup = "unknown" + endif +else + if b:lhs_markup !~ '\<\%(tex\|none\)\>' + let b:lhs_markup = "unknown" + endif +endif + +" Remember where the cursor is, and go to upperleft +let s:oldline=line(".") +let s:oldcolumn=col(".") +call cursor(1,1) + +" If no user preference, scan buffer for our guess of the markup to +" highlight. We only differentiate between TeX and plain markup, where +" plain is not highlighted. The heuristic for finding TeX markup is if +" one of the following occurs anywhere in the file: +" - \documentclass +" - \begin{env} (for env != code) +" - \part, \chapter, \section, \subsection, \subsubsection, etc +if b:lhs_markup == "unknown" + if search('\\documentclass\|\\begin{\(code}\)\@!\|\\\(sub\)*section\|\\chapter|\\part','W') != 0 + let b:lhs_markup = "tex" + else + let b:lhs_markup = "plain" + endif +endif + +" If user wants us to highlight TeX syntax or guess thinks it's TeX, read it. +if b:lhs_markup == "tex" + runtime! syntax/tex.vim + unlet b:current_syntax + " Tex.vim removes "_" from 'iskeyword', but we need it for Haskell. + setlocal isk+=_ + syntax cluster lhsTeXContainer contains=tex.*Zone,texAbstract +else + syntax cluster lhsTeXContainer contains=.* +endif + +" Literate Haskell is Haskell in between text, so at least read Haskell +" highlighting +syntax include @haskellTop syntax/haskell.vim + +syntax region lhsHaskellBirdTrack start="^>" end="\%(^[^>]\)\@=" contains=@haskellTop,lhsBirdTrack containedin=@lhsTeXContainer +syntax region lhsHaskellBeginEndBlock start="^\\begin{code}\s*$" matchgroup=NONE end="\%(^\\end{code}.*$\)\@=" contains=@haskellTop,beginCodeBegin containedin=@lhsTeXContainer + +syntax match lhsBirdTrack "^>" contained + +syntax match beginCodeBegin "^\\begin" nextgroup=beginCodeCode contained +syntax region beginCodeCode matchgroup=texDelimiter start="{" end="}" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link lhsBirdTrack Comment + +hi def link beginCodeBegin texCmdName +hi def link beginCodeCode texSection + + +" Restore cursor to original position, as it may have been disturbed +" by the searches in our guessing code +call cursor (s:oldline, s:oldcolumn) + +unlet s:oldline +unlet s:oldcolumn + +let b:current_syntax = "lhaskell" + +" vim: ts=8 + +endif diff --git a/syntax/libao.vim b/syntax/libao.vim new file mode 100644 index 0000000..4366fe2 --- /dev/null +++ b/syntax/libao.vim @@ -0,0 +1,31 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: libao.conf(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword libaoTodo contained TODO FIXME XXX NOTE + +syn region libaoComment display oneline start='^\s*#' end='$' + \ contains=libaoTodo,@Spell + +syn keyword libaoKeyword default_driver + +hi def link libaoTodo Todo +hi def link libaoComment Comment +hi def link libaoKeyword Keyword + +let b:current_syntax = "libao" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/lifelines.vim b/syntax/lifelines.vim new file mode 100644 index 0000000..5acab57 --- /dev/null +++ b/syntax/lifelines.vim @@ -0,0 +1,158 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: LifeLines (v 3.0.62) +" Maintainer: Patrick Texier +" Location: +" Last Change: 2010 May 7 + +" option to highlight error obsolete statements +" add the following line to your .vimrc file : +" let lifelines_deprecated = 1 + +" For version 5.x: Clear all syntax items +" For version 6.x: Quit when a syntax file was already loaded + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful LifeLines keywords 3.0.62 + +syn keyword lifelinesDecl char_encoding require option include +syn keyword lifelinesStatement set +syn keyword lifelinesUser getindi geindiset getfam getint getstr choosechild +syn keyword lifelinesUser chooseindi choosespouse choosesubset menuchoose +syn keyword lifelinesUser choosefam +syn keyword lifelinesProc proc func return call +syn keyword lifelinesInclude include +syn keyword lifelinesDef global +syn keyword lifelinesConditional if else elsif switch +syn keyword lifelinesRepeat continue break while +syn keyword lifelinesLogical and or not eq ne lt gt le ge strcmp eqstr nestr +syn keyword lifelinesArithm add sub mul div mod exp neg incr decr +syn keyword lifelinesArithm cos sin tan arccos arcsin arctan +syn keyword lifelinesArithm deg2dms dms2deg spdist +syn keyword lifelinesIndi name fullname surname givens trimname birth +syn keyword lifelinesIndi death burial baptism +syn keyword lifelinesIndi father mother nextsib prevsib sex male female +syn keyword lifelinesIndi pn nspouses nfamilies parents title key +syn keyword lifelinesIndi soundex inode root indi firstindi nextindi +syn keyword lifelinesIndi previndi spouses families forindi indiset +syn keyword lifelinesIndi addtoset deletefromset union intersect +syn keyword lifelinesIndi difference parentset childset spouseset siblingset +syn keyword lifelinesIndi ancestorset descendentset descendantset uniqueset +syn keyword lifelinesIndi namesort keysort valuesort genindiset getindiset +syn keyword lifelinesIndi forindiset lastindi writeindi +syn keyword lifelinesIndi inset +syn keyword lifelinesFam marriage husband wife nchildren firstchild +syn keyword lifelinesFam lastchild fnode fam firstfam nextfam lastfam +syn keyword lifelinesFam prevfam children forfam writefam +syn keyword lifelinesFam fathers mothers Parents +syn keyword lifelinesList list empty length enqueue dequeue requeue +syn keyword lifelinesList push pop setel getel forlist inlist dup clear +syn keyword lifelinesTable table insert lookup +syn keyword lifelinesGedcom xref tag value parent child sibling savenode +syn keyword lifelinesGedcom fornodes traverse createnode addnode +syn keyword lifelinesGedcom detachnode foreven fornotes forothr forsour +syn keyword lifelinesGedcom reference dereference getrecord +syn keyword lifelinesGedcom gengedcomstrong +syn keyword lifelinesFunct date place year long short gettoday dayformat +syn keyword lifelinesFunct monthformat dateformat extractdate eraformat +syn keyword lifelinesFunct complexdate complexformat complexpic datepic +syn keyword lifelinesFunct extractnames extractplaces extracttokens lower +syn keyword lifelinesFunct yearformat +syn keyword lifelinesFunct upper capitalize trim rjustify +syn keyword lifelinesFunct concat strconcat strlen substring index +syn keyword lifelinesFunct titlecase gettext +syn keyword lifelinesFunct d card ord alpha roman strsoundex strtoint +syn keyword lifelinesFunct atoi linemode pagemod col row pos pageout nl +syn keyword lifelinesFunct sp qt newfile outfile copyfile print lock unlock test +syn keyword lifelinesFunct database version system stddate program +syn keyword lifelinesFunct pvalue pagemode level extractdatestr debug +syn keyword lifelinesFunct f float int free getcol getproperty heapused +syn keyword lifelinesFunct sort rsort +syn keyword lifelinesFunct deleteel +syn keyword lifelinesFunct bytecode convertcode setlocale +" New dates functions (since 3.0.51) +syn keyword lifelinesFunct jd2date date2jd dayofweek setdate + +" options to highlight as error obsolete statements +" please read ll-reportmanual. + +if exists("lifelines_deprecated") + syn keyword lifelinesError getintmsg getindimsg getstrmsg + syn keyword lifelinesError gengedcom gengedcomweak deletenode + syn keyword lifelinesError save strsave + syn keyword lifelinesError lengthset + if version >= 700 + let g:omni_syntax_group_exclude_lifelines = 'lifelinesError' + endif +else + syn keyword lifelinesUser getintmsg getindimsg getstrmsg + syn keyword lifelinesGedcom gengedcom gengedcomweak deletenode + syn keyword lifelinesFunct save strsave + syn keyword lifelinesIndi lengthset +endif + +syn region lifelinesString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=lifelinesSpecial + +syn match lifelinesSpecial "\\\(\\\|\(n\|t\)\)" contained + +syn keyword lifelinesTodo contained TODO FIXME XXX +syn region lifelinesComment start="/\*" end="\*/" contains=lifelinesTodo + +" integers +syn match lifelinesNumber "-\=\<\d\+\>" +"floats, with dot +syn match lifelinesNumber "-\=\<\d\+\.\d*\>" +"floats, starting with a dot +syn match lifelinesNumber "-\=\.\d\+\>" + +" folding using {} +syn region lifelinesFoldBlock start="{" end="}" transparent fold + +"catch errors caused by wrong parenthesis +"adapted from original c.vim written by Bram Moolenaar + +syn cluster lifelinesParenGroup contains=lifelinesParenError +syn region lifelinesParen transparent start='(' end=')' contains=ALLBUT,@lifelinesParenGroup +syn match lifelinesParenError ")" +syn match lifelinesErrInParen contained "[{}]" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + + +hi def link lifelinesConditional Conditional +hi def link lifelinesArithm Operator +hi def link lifelinesLogical Conditional +hi def link lifelinesInclude Include +hi def link lifelinesComment Comment +hi def link lifelinesStatement Statement +hi def link lifelinesUser Statement +hi def link lifelinesFunct Statement +hi def link lifelinesTable Statement +hi def link lifelinesGedcom Statement +hi def link lifelinesList Statement +hi def link lifelinesRepeat Repeat +hi def link lifelinesFam Statement +hi def link lifelinesIndi Statement +hi def link lifelinesProc Statement +hi def link lifelinesDef Statement +hi def link lifelinesString String +hi def link lifelinesSpecial Special +hi def link lifelinesNumber Number +hi def link lifelinesParenError Error +hi def link lifelinesErrInParen Error +hi def link lifelinesError Error +hi def link lifelinesTodo Todo +hi def link lifelinesDecl PreProc + + +let b:current_syntax = "lifelines" + +" vim: ts=8 sw=4 + +endif diff --git a/syntax/lilo.vim b/syntax/lilo.vim new file mode 100644 index 0000000..aa531a3 --- /dev/null +++ b/syntax/lilo.vim @@ -0,0 +1,178 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: lilo configuration (lilo.conf) +" Maintainer: Niels Horn +" Previous Maintainer: David Necas (Yeti) +" Last Change: 2010-02-03 + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=@,48-57,.,-,_ + +syn case ignore + +" Base constructs +syn match liloError "\S\+" +syn match liloComment "#.*$" +syn match liloEnviron "\$\w\+" contained +syn match liloEnviron "\${[^}]\+}" contained +syn match liloDecNumber "\d\+" contained +syn match liloHexNumber "0[xX]\x\+" contained +syn match liloDecNumberP "\d\+p\=" contained +syn match liloSpecial contained "\\\(\"\|\\\|$\)" +syn region liloString start=+"+ skip=+\\\\\|\\"+ end=+"+ contained contains=liloSpecial,liloEnviron +syn match liloLabel :[^ "]\+: contained contains=liloSpecial,liloEnviron +syn region liloPath start=+[$/]+ skip=+\\\\\|\\ \|\\$"+ end=+ \|$+ contained contains=liloSpecial,liloEnviron +syn match liloDecNumberList "\(\d\|,\)\+" contained contains=liloDecNumber +syn match liloDecNumberPList "\(\d\|[,p]\)\+" contained contains=liloDecNumberP,liloDecNumber +syn region liloAnything start=+[^[:space:]#]+ skip=+\\\\\|\\ \|\\$+ end=+ \|$+ contained contains=liloSpecial,liloEnviron,liloString + +" Path +syn keyword liloOption backup bitmap boot disktab force-backup keytable map message nextgroup=liloEqPath,liloEqPathComment,liloError skipwhite skipempty +syn keyword liloKernelOpt initrd root nextgroup=liloEqPath,liloEqPathComment,liloError skipwhite skipempty +syn keyword liloImageOpt path loader table nextgroup=liloEqPath,liloEqPathComment,liloError skipwhite skipempty +syn keyword liloDiskOpt partition nextgroup=liloEqPath,liloEqPathComment,liloError skipwhite skipempty + +" Other +syn keyword liloOption menu-scheme raid-extra-boot serial install nextgroup=liloEqAnything,liloEqAnythingComment,liloError skipwhite skipempty +syn keyword liloOption bios-passes-dl nextgroup=liloEqAnything,liloEqAnythingComment,liloError skipwhite skipempty +syn keyword liloOption default label alias wmdefault nextgroup=liloEqLabelString,liloEqLabelStringComment,liloError skipwhite skipempty +syn keyword liloKernelOpt ramdisk nextgroup=liloEqAnything,liloEqAnythingComment,liloError skipwhite skipempty +syn keyword liloImageOpt password range nextgroup=liloEqAnything,liloEqAnythingComment,liloError skipwhite skipempty +syn keyword liloDiskOpt set type nextgroup=liloEqAnything,liloEqAnythingComment,liloError skipwhite skipempty + +" Symbolic +syn keyword liloKernelOpt vga nextgroup=liloEqVga,liloEqVgaComment,liloError skipwhite skipempty + +" Number +syn keyword liloOption delay timeout verbose nextgroup=liloEqDecNumber,liloEqDecNumberComment,liloError skipwhite skipempty +syn keyword liloDiskOpt sectors heads cylinders start nextgroup=liloEqDecNumber,liloEqDecNumberComment,liloError skipwhite skipempty + +" String +syn keyword liloOption menu-title nextgroup=liloEqString,liloEqStringComment,liloError skipwhite skipempty +syn keyword liloKernelOpt append addappend nextgroup=liloEqString,liloEqStringComment,liloError skipwhite skipempty +syn keyword liloImageOpt fallback literal nextgroup=liloEqString,liloEqStringComment,liloError skipwhite skipempty + +" Hex number +syn keyword liloImageOpt map-drive to boot-as nextgroup=liloEqHexNumber,liloEqHexNumberComment,liloError skipwhite skipempty +syn keyword liloDiskOpt bios normal hidden nextgroup=liloEqNumber,liloEqNumberComment,liloError skipwhite skipempty + +" Number list +syn keyword liloOption bmp-colors nextgroup=liloEqNumberList,liloEqNumberListComment,liloError skipwhite skipempty + +" Number list, some of the numbers followed by p +syn keyword liloOption bmp-table bmp-timer nextgroup=liloEqDecNumberPList,liloEqDecNumberPListComment,liloError skipwhite skipempty + +" Flag +syn keyword liloOption compact fix-table geometric ignore-table lba32 linear mandatory nowarn prompt +syn keyword liloOption bmp-retain el-torito-bootable-CD large-memory suppress-boot-time-BIOS-data +syn keyword liloKernelOpt read-only read-write +syn keyword liloImageOpt bypass lock mandatory optional restricted single-key unsafe +syn keyword liloImageOpt master-boot wmwarn wmdisable +syn keyword liloDiskOpt change activate deactivate inaccessible reset + +" Image +syn keyword liloImage image other nextgroup=liloEqPath,liloEqPathComment,liloError skipwhite skipempty +syn keyword liloDisk disk nextgroup=liloEqPath,liloEqPathComment,liloError skipwhite skipempty +syn keyword liloChRules change-rules + +" Vga keywords +syn keyword liloVgaKeyword ask ext extended normal contained + +" Comment followed by equal sign and ... +syn match liloEqPathComment "#.*$" contained nextgroup=liloEqPath,liloEqPathComment,liloError skipwhite skipempty +syn match liloEqVgaComment "#.*$" contained nextgroup=liloEqVga,liloEqVgaComment,liloError skipwhite skipempty +syn match liloEqNumberComment "#.*$" contained nextgroup=liloEqNumber,liloEqNumberComment,liloError skipwhite skipempty +syn match liloEqDecNumberComment "#.*$" contained nextgroup=liloEqDecNumber,liloEqDecNumberComment,liloError skipwhite skipempty +syn match liloEqHexNumberComment "#.*$" contained nextgroup=liloEqHexNumber,liloEqHexNumberComment,liloError skipwhite skipempty +syn match liloEqStringComment "#.*$" contained nextgroup=liloEqString,liloEqStringComment,liloError skipwhite skipempty +syn match liloEqLabelStringComment "#.*$" contained nextgroup=liloEqLabelString,liloEqLabelStringComment,liloError skipwhite skipempty +syn match liloEqNumberListComment "#.*$" contained nextgroup=liloEqNumberList,liloEqNumberListComment,liloError skipwhite skipempty +syn match liloEqDecNumberPListComment "#.*$" contained nextgroup=liloEqDecNumberPList,liloEqDecNumberPListComment,liloError skipwhite skipempty +syn match liloEqAnythingComment "#.*$" contained nextgroup=liloEqAnything,liloEqAnythingComment,liloError skipwhite skipempty + +" Equal sign followed by ... +syn match liloEqPath "=" contained nextgroup=liloPath,liloPathComment,liloError skipwhite skipempty +syn match liloEqVga "=" contained nextgroup=liloVgaKeyword,liloHexNumber,liloDecNumber,liloVgaComment,liloError skipwhite skipempty +syn match liloEqNumber "=" contained nextgroup=liloDecNumber,liloHexNumber,liloNumberComment,liloError skipwhite skipempty +syn match liloEqDecNumber "=" contained nextgroup=liloDecNumber,liloDecNumberComment,liloError skipwhite skipempty +syn match liloEqHexNumber "=" contained nextgroup=liloHexNumber,liloHexNumberComment,liloError skipwhite skipempty +syn match liloEqString "=" contained nextgroup=liloString,liloStringComment,liloError skipwhite skipempty +syn match liloEqLabelString "=" contained nextgroup=liloString,liloLabel,liloLabelStringComment,liloError skipwhite skipempty +syn match liloEqNumberList "=" contained nextgroup=liloDecNumberList,liloDecNumberListComment,liloError skipwhite skipempty +syn match liloEqDecNumberPList "=" contained nextgroup=liloDecNumberPList,liloDecNumberPListComment,liloError skipwhite skipempty +syn match liloEqAnything "=" contained nextgroup=liloAnything,liloAnythingComment,liloError skipwhite skipempty + +" Comment followed by ... +syn match liloPathComment "#.*$" contained nextgroup=liloPath,liloPathComment,liloError skipwhite skipempty +syn match liloVgaComment "#.*$" contained nextgroup=liloVgaKeyword,liloHexNumber,liloVgaComment,liloError skipwhite skipempty +syn match liloNumberComment "#.*$" contained nextgroup=liloDecNumber,liloHexNumber,liloNumberComment,liloError skipwhite skipempty +syn match liloDecNumberComment "#.*$" contained nextgroup=liloDecNumber,liloDecNumberComment,liloError skipwhite skipempty +syn match liloHexNumberComment "#.*$" contained nextgroup=liloHexNumber,liloHexNumberComment,liloError skipwhite skipempty +syn match liloStringComment "#.*$" contained nextgroup=liloString,liloStringComment,liloError skipwhite skipempty +syn match liloLabelStringComment "#.*$" contained nextgroup=liloString,liloLabel,liloLabelStringComment,liloError skipwhite skipempty +syn match liloDecNumberListComment "#.*$" contained nextgroup=liloDecNumberList,liloDecNumberListComment,liloError skipwhite skipempty +syn match liloDecNumberPListComment "#.*$" contained nextgroup=liloDecNumberPList,liloDecNumberPListComment,liloError skipwhite skipempty +syn match liloAnythingComment "#.*$" contained nextgroup=liloAnything,liloAnythingComment,liloError skipwhite skipempty + +" Define the default highlighting + +hi def link liloEqPath liloEquals +hi def link liloEqWord liloEquals +hi def link liloEqVga liloEquals +hi def link liloEqDecNumber liloEquals +hi def link liloEqHexNumber liloEquals +hi def link liloEqNumber liloEquals +hi def link liloEqString liloEquals +hi def link liloEqAnything liloEquals +hi def link liloEquals Special + +hi def link liloError Error + +hi def link liloEqPathComment liloComment +hi def link liloEqVgaComment liloComment +hi def link liloEqDecNumberComment liloComment +hi def link liloEqHexNumberComment liloComment +hi def link liloEqStringComment liloComment +hi def link liloEqAnythingComment liloComment +hi def link liloPathComment liloComment +hi def link liloVgaComment liloComment +hi def link liloDecNumberComment liloComment +hi def link liloHexNumberComment liloComment +hi def link liloNumberComment liloComment +hi def link liloStringComment liloComment +hi def link liloAnythingComment liloComment +hi def link liloComment Comment + +hi def link liloDiskOpt liloOption +hi def link liloKernelOpt liloOption +hi def link liloImageOpt liloOption +hi def link liloOption Keyword + +hi def link liloDecNumber liloNumber +hi def link liloHexNumber liloNumber +hi def link liloDecNumberP liloNumber +hi def link liloNumber Number +hi def link liloString String +hi def link liloPath Constant + +hi def link liloSpecial Special +hi def link liloLabel Title +hi def link liloDecNumberList Special +hi def link liloDecNumberPList Special +hi def link liloAnything Normal +hi def link liloEnviron Identifier +hi def link liloVgaKeyword Identifier +hi def link liloImage Type +hi def link liloChRules Preproc +hi def link liloDisk Preproc + + +let b:current_syntax = "lilo" + +endif diff --git a/syntax/limits.vim b/syntax/limits.vim new file mode 100644 index 0000000..feabd98 --- /dev/null +++ b/syntax/limits.vim @@ -0,0 +1,48 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: limits(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword limitsTodo contained TODO FIXME XXX NOTE + +syn region limitsComment display oneline start='^\s*#' end='$' + \ contains=limitsTodo,@Spell + +syn match limitsBegin display '^' + \ nextgroup=limitsUser,limitsDefault,limitsComment + \ skipwhite + +syn match limitsUser contained '[^ \t#*]\+' + \ nextgroup=limitsLimit,limitsDeLimit skipwhite + +syn match limitsDefault contained '*' + \ nextgroup=limitsLimit,limitsDeLimit skipwhite + +syn match limitsLimit contained '[ACDFMNRSTUKLP]' nextgroup=limitsNumber +syn match limitsDeLimit contained '-' + +syn match limitsNumber contained '\d\+\>' nextgroup=limitsLimit skipwhite + +hi def link limitsTodo Todo +hi def link limitsComment Comment +hi def link limitsUser Keyword +hi def link limitsDefault Macro +hi def link limitsLimit Identifier +hi def link limitsDeLimit Special +hi def link limitsNumber Number + +let b:current_syntax = "limits" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/liquid.vim b/syntax/liquid.vim index fd09c7c..5a48f2a 100644 --- a/syntax/liquid.vim +++ b/syntax/liquid.vim @@ -1,3 +1,145 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Liquid +" Maintainer: Tim Pope +" Filenames: *.liquid +" Last Change: 2013 May 30 + +if exists('b:current_syntax') + finish +endif + +if !exists('main_syntax') + let main_syntax = 'liquid' +endif + +if !exists('g:liquid_default_subtype') + let g:liquid_default_subtype = 'html' +endif + +if !exists('b:liquid_subtype') && main_syntax == 'liquid' + let s:lines = getline(1)."\n".getline(2)."\n".getline(3)."\n".getline(4)."\n".getline(5)."\n".getline("$") + let b:liquid_subtype = matchstr(s:lines,'liquid_subtype=\zs\w\+') + if b:liquid_subtype == '' + let b:liquid_subtype = matchstr(&filetype,'^liquid\.\zs\w\+') + endif + if b:liquid_subtype == '' + let b:liquid_subtype = matchstr(substitute(expand('%:t'),'\c\%(\.liquid\)\+$','',''),'\.\zs\w\+$') + endif + if b:liquid_subtype == '' + let b:liquid_subtype = g:liquid_default_subtype + endif +endif + +if exists('b:liquid_subtype') && b:liquid_subtype != '' + exe 'runtime! syntax/'.b:liquid_subtype.'.vim' + unlet! b:current_syntax +endif + +syn case match + +if exists('b:liquid_subtype') && b:liquid_subtype != 'yaml' + " YAML Front Matter + syn include @liquidYamlTop syntax/yaml.vim + unlet! b:current_syntax + syn region liquidYamlHead start="\%^---$" end="^---\s*$" keepend contains=@liquidYamlTop,@Spell +endif + +if !exists('g:liquid_highlight_types') + let g:liquid_highlight_types = [] +endif + +if !exists('s:subtype') + let s:subtype = exists('b:liquid_subtype') ? b:liquid_subtype : '' + + for s:type in map(copy(g:liquid_highlight_types),'matchstr(v:val,"[^=]*$")') + if s:type =~ '\.' + let b:{matchstr(s:type,'[^.]*')}_subtype = matchstr(s:type,'\.\zs.*') + endif + exe 'syn include @liquidHighlight'.substitute(s:type,'\.','','g').' syntax/'.matchstr(s:type,'[^.]*').'.vim' + unlet! b:current_syntax + endfor + unlet! s:type + + if s:subtype == '' + unlet! b:liquid_subtype + else + let b:liquid_subtype = s:subtype + endif + unlet s:subtype +endif + +syn region liquidStatement matchgroup=liquidDelimiter start="{%" end="%}" contains=@liquidStatement containedin=ALLBUT,@liquidExempt keepend +syn region liquidExpression matchgroup=liquidDelimiter start="{{" end="}}" contains=@liquidExpression containedin=ALLBUT,@liquidExempt keepend +syn region liquidComment matchgroup=liquidDelimiter start="{%\s*comment\s*%}" end="{%\s*endcomment\s*%}" contains=liquidTodo,@Spell containedin=ALLBUT,@liquidExempt keepend +syn region liquidRaw matchgroup=liquidDelimiter start="{%\s*raw\s*%}" end="{%\s*endraw\s*%}" contains=TOP,@liquidExempt containedin=ALLBUT,@liquidExempt keepend + +syn cluster liquidExempt contains=liquidStatement,liquidExpression,liquidComment,liquidRaw,@liquidStatement,liquidYamlHead +syn cluster liquidStatement contains=liquidConditional,liquidRepeat,liquidKeyword,@liquidExpression +syn cluster liquidExpression contains=liquidOperator,liquidString,liquidNumber,liquidFloat,liquidBoolean,liquidNull,liquidEmpty,liquidPipe,liquidForloop + +syn keyword liquidKeyword highlight nextgroup=liquidTypeHighlight skipwhite contained +syn keyword liquidKeyword endhighlight contained +syn region liquidHighlight start="{%\s*highlight\s\+\w\+\s*%}" end="{% endhighlight %}" keepend + +for s:type in g:liquid_highlight_types + exe 'syn match liquidTypeHighlight "\<'.matchstr(s:type,'[^=]*').'\>" contained' + exe 'syn region liquidHighlight'.substitute(matchstr(s:type,'[^=]*$'),'\..*','','').' start="{%\s*highlight\s\+'.matchstr(s:type,'[^=]*').'\s*%}" end="{% endhighlight %}" keepend contains=@liquidHighlight'.substitute(matchstr(s:type,'[^=]*$'),'\.','','g') +endfor +unlet! s:type + +syn region liquidString matchgroup=liquidQuote start=+"+ end=+"+ contained +syn region liquidString matchgroup=liquidQuote start=+'+ end=+'+ contained +syn match liquidNumber "-\=\<\d\+\>" contained +syn match liquidFloat "-\=\<\d\+\>\.\.\@!\%(\d\+\>\)\=" contained +syn keyword liquidBoolean true false contained +syn keyword liquidNull null nil contained +syn match liquidEmpty "\" contained + +syn keyword liquidOperator and or not contained +syn match liquidPipe '|' contained skipwhite nextgroup=liquidFilter + +syn keyword liquidFilter date capitalize downcase upcase first last join sort size strip_html strip_newlines newline_to_br replace replace_first remove remove_first truncate truncatewords prepend append minus plus times divided_by contained + +syn keyword liquidConditional if elsif else endif unless endunless case when endcase ifchanged endifchanged contained +syn keyword liquidRepeat for endfor tablerow endtablerow in contained +syn match liquidRepeat "\%({%\s*\)\@<=empty\>" contained +syn keyword liquidKeyword assign cycle include with contained + +syn keyword liquidForloop forloop nextgroup=liquidForloopDot contained +syn match liquidForloopDot "\." nextgroup=liquidForloopAttribute contained +syn keyword liquidForloopAttribute length index index0 rindex rindex0 first last contained + +syn keyword liquidTablerowloop tablerowloop nextgroup=liquidTablerowloopDot contained +syn match liquidTablerowloopDot "\." nextgroup=liquidTableForloopAttribute contained +syn keyword liquidTablerowloopAttribute length index index0 col col0 index0 rindex rindex0 first last col_first col_last contained + +hi def link liquidDelimiter PreProc +hi def link liquidComment Comment +hi def link liquidTypeHighlight Type +hi def link liquidConditional Conditional +hi def link liquidRepeat Repeat +hi def link liquidKeyword Keyword +hi def link liquidOperator Operator +hi def link liquidString String +hi def link liquidQuote Delimiter +hi def link liquidNumber Number +hi def link liquidFloat Float +hi def link liquidEmpty liquidNull +hi def link liquidNull liquidBoolean +hi def link liquidBoolean Boolean +hi def link liquidFilter Function +hi def link liquidForloop Identifier +hi def link liquidForloopAttribute Identifier + +let b:current_syntax = 'liquid' + +if exists('main_syntax') && main_syntax == 'liquid' + unlet main_syntax +endif + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'liquid') == -1 " Vim syntax file diff --git a/syntax/lisp.vim b/syntax/lisp.vim new file mode 100644 index 0000000..66f97e3 --- /dev/null +++ b/syntax/lisp.vim @@ -0,0 +1,622 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Lisp +" Maintainer: Charles E. Campbell +" Last Change: May 02, 2016 +" Version: 26 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_LISP +" +" Thanks to F Xavier Noria for a list of 978 Common Lisp symbols taken from HyperSpec +" Clisp additions courtesy of http://clisp.cvs.sourceforge.net/*checkout*/clisp/clisp/emacs/lisp.vim + +" --------------------------------------------------------------------- +" Load Once: {{{1 +if exists("b:current_syntax") + finish +endif + +if exists("g:lisp_isk") + exe "setl isk=".g:lisp_isk +elseif !has("patch-7.4.1142") + setl isk=38,42,43,45,47-58,60-62,64-90,97-122,_ +else + syn iskeyword 38,42,43,45,47-58,60-62,64-90,97-122,_ +endif + +if exists("g:lispsyntax_ignorecase") || exists("g:lispsyntax_clisp") + set ignorecase +endif + +" --------------------------------------------------------------------- +" Clusters: {{{1 +syn cluster lispAtomCluster contains=lispAtomBarSymbol,lispAtomList,lispAtomNmbr0,lispComment,lispDecl,lispFunc,lispLeadWhite +syn cluster lispBaseListCluster contains=lispAtom,lispAtomBarSymbol,lispAtomMark,lispBQList,lispBarSymbol,lispComment,lispConcat,lispDecl,lispFunc,lispKey,lispList,lispNumber,lispEscapeSpecial,lispSymbol,lispVar,lispLeadWhite +if exists("g:lisp_instring") + syn cluster lispListCluster contains=@lispBaseListCluster,lispString,lispInString,lispInStringString +else + syn cluster lispListCluster contains=@lispBaseListCluster,lispString +endif + +syn case ignore + +" --------------------------------------------------------------------- +" Lists: {{{1 +syn match lispSymbol contained ![^()'`,"; \t]\+! +syn match lispBarSymbol contained !|..\{-}|! +if exists("g:lisp_rainbow") && g:lisp_rainbow != 0 + syn region lispParen0 matchgroup=hlLevel0 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen1 + syn region lispParen1 contained matchgroup=hlLevel1 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen2 + syn region lispParen2 contained matchgroup=hlLevel2 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen3 + syn region lispParen3 contained matchgroup=hlLevel3 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen4 + syn region lispParen4 contained matchgroup=hlLevel4 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen5 + syn region lispParen5 contained matchgroup=hlLevel5 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen6 + syn region lispParen6 contained matchgroup=hlLevel6 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen7 + syn region lispParen7 contained matchgroup=hlLevel7 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen8 + syn region lispParen8 contained matchgroup=hlLevel8 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen9 + syn region lispParen9 contained matchgroup=hlLevel9 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen0 +else + syn region lispList matchgroup=Delimiter start="(" skip="|.\{-}|" matchgroup=Delimiter end=")" contains=@lispListCluster + syn region lispBQList matchgroup=PreProc start="`(" skip="|.\{-}|" matchgroup=PreProc end=")" contains=@lispListCluster +endif + +" --------------------------------------------------------------------- +" Atoms: {{{1 +syn match lispAtomMark "'" +syn match lispAtom "'("me=e-1 contains=lispAtomMark nextgroup=lispAtomList +syn match lispAtom "'[^ \t()]\+" contains=lispAtomMark +syn match lispAtomBarSymbol !'|..\{-}|! contains=lispAtomMark +syn region lispAtom start=+'"+ skip=+\\"+ end=+"+ +syn region lispAtomList contained matchgroup=Special start="(" skip="|.\{-}|" matchgroup=Special end=")" contains=@lispAtomCluster,lispString,lispEscapeSpecial +syn match lispAtomNmbr contained "\<\d\+" +syn match lispLeadWhite contained "^\s\+" + +" --------------------------------------------------------------------- +" Standard Lisp Functions and Macros: {{{1 +syn keyword lispFunc * find-method pprint-indent +syn keyword lispFunc ** find-package pprint-linear +syn keyword lispFunc *** find-restart pprint-logical-block +syn keyword lispFunc + find-symbol pprint-newline +syn keyword lispFunc ++ finish-output pprint-pop +syn keyword lispFunc +++ first pprint-tab +syn keyword lispFunc - fixnum pprint-tabular +syn keyword lispFunc / flet prin1 +syn keyword lispFunc // float prin1-to-string +syn keyword lispFunc /// float-digits princ +syn keyword lispFunc /= float-precision princ-to-string +syn keyword lispFunc 1+ float-radix print +syn keyword lispFunc 1- float-sign print-not-readable +syn keyword lispFunc < floating-point-inexact print-not-readable-object +syn keyword lispFunc <= floating-point-invalid-operation print-object +syn keyword lispFunc = floating-point-overflow print-unreadable-object +syn keyword lispFunc > floating-point-underflow probe-file +syn keyword lispFunc >= floatp proclaim +syn keyword lispFunc abort floor prog +syn keyword lispFunc abs fmakunbound prog* +syn keyword lispFunc access force-output prog1 +syn keyword lispFunc acons format prog2 +syn keyword lispFunc acos formatter progn +syn keyword lispFunc acosh fourth program-error +syn keyword lispFunc add-method fresh-line progv +syn keyword lispFunc adjoin fround provide +syn keyword lispFunc adjust-array ftruncate psetf +syn keyword lispFunc adjustable-array-p ftype psetq +syn keyword lispFunc allocate-instance funcall push +syn keyword lispFunc alpha-char-p function pushnew +syn keyword lispFunc alphanumericp function-keywords putprop +syn keyword lispFunc and function-lambda-expression quote +syn keyword lispFunc append functionp random +syn keyword lispFunc apply gbitp random-state +syn keyword lispFunc applyhook gcd random-state-p +syn keyword lispFunc apropos generic-function rassoc +syn keyword lispFunc apropos-list gensym rassoc-if +syn keyword lispFunc aref gentemp rassoc-if-not +syn keyword lispFunc arithmetic-error get ratio +syn keyword lispFunc arithmetic-error-operands get-decoded-time rational +syn keyword lispFunc arithmetic-error-operation get-dispatch-macro-character rationalize +syn keyword lispFunc array get-internal-real-time rationalp +syn keyword lispFunc array-dimension get-internal-run-time read +syn keyword lispFunc array-dimension-limit get-macro-character read-byte +syn keyword lispFunc array-dimensions get-output-stream-string read-char +syn keyword lispFunc array-displacement get-properties read-char-no-hang +syn keyword lispFunc array-element-type get-setf-expansion read-delimited-list +syn keyword lispFunc array-has-fill-pointer-p get-setf-method read-eval-print +syn keyword lispFunc array-in-bounds-p get-universal-time read-from-string +syn keyword lispFunc array-rank getf read-line +syn keyword lispFunc array-rank-limit gethash read-preserving-whitespace +syn keyword lispFunc array-row-major-index go read-sequence +syn keyword lispFunc array-total-size graphic-char-p reader-error +syn keyword lispFunc array-total-size-limit handler-bind readtable +syn keyword lispFunc arrayp handler-case readtable-case +syn keyword lispFunc ash hash-table readtablep +syn keyword lispFunc asin hash-table-count real +syn keyword lispFunc asinh hash-table-p realp +syn keyword lispFunc assert hash-table-rehash-size realpart +syn keyword lispFunc assoc hash-table-rehash-threshold reduce +syn keyword lispFunc assoc-if hash-table-size reinitialize-instance +syn keyword lispFunc assoc-if-not hash-table-test rem +syn keyword lispFunc atan host-namestring remf +syn keyword lispFunc atanh identity remhash +syn keyword lispFunc atom if remove +syn keyword lispFunc base-char if-exists remove-duplicates +syn keyword lispFunc base-string ignorable remove-if +syn keyword lispFunc bignum ignore remove-if-not +syn keyword lispFunc bit ignore-errors remove-method +syn keyword lispFunc bit-and imagpart remprop +syn keyword lispFunc bit-andc1 import rename-file +syn keyword lispFunc bit-andc2 in-package rename-package +syn keyword lispFunc bit-eqv in-package replace +syn keyword lispFunc bit-ior incf require +syn keyword lispFunc bit-nand initialize-instance rest +syn keyword lispFunc bit-nor inline restart +syn keyword lispFunc bit-not input-stream-p restart-bind +syn keyword lispFunc bit-orc1 inspect restart-case +syn keyword lispFunc bit-orc2 int-char restart-name +syn keyword lispFunc bit-vector integer return +syn keyword lispFunc bit-vector-p integer-decode-float return-from +syn keyword lispFunc bit-xor integer-length revappend +syn keyword lispFunc block integerp reverse +syn keyword lispFunc boole interactive-stream-p room +syn keyword lispFunc boole-1 intern rotatef +syn keyword lispFunc boole-2 internal-time-units-per-second round +syn keyword lispFunc boole-and intersection row-major-aref +syn keyword lispFunc boole-andc1 invalid-method-error rplaca +syn keyword lispFunc boole-andc2 invoke-debugger rplacd +syn keyword lispFunc boole-c1 invoke-restart safety +syn keyword lispFunc boole-c2 invoke-restart-interactively satisfies +syn keyword lispFunc boole-clr isqrt sbit +syn keyword lispFunc boole-eqv keyword scale-float +syn keyword lispFunc boole-ior keywordp schar +syn keyword lispFunc boole-nand labels search +syn keyword lispFunc boole-nor lambda second +syn keyword lispFunc boole-orc1 lambda-list-keywords sequence +syn keyword lispFunc boole-orc2 lambda-parameters-limit serious-condition +syn keyword lispFunc boole-set last set +syn keyword lispFunc boole-xor lcm set-char-bit +syn keyword lispFunc boolean ldb set-difference +syn keyword lispFunc both-case-p ldb-test set-dispatch-macro-character +syn keyword lispFunc boundp ldiff set-exclusive-or +syn keyword lispFunc break least-negative-double-float set-macro-character +syn keyword lispFunc broadcast-stream least-negative-long-float set-pprint-dispatch +syn keyword lispFunc broadcast-stream-streams least-negative-normalized-double-float set-syntax-from-char +syn keyword lispFunc built-in-class least-negative-normalized-long-float setf +syn keyword lispFunc butlast least-negative-normalized-short-float setq +syn keyword lispFunc byte least-negative-normalized-single-float seventh +syn keyword lispFunc byte-position least-negative-short-float shadow +syn keyword lispFunc byte-size least-negative-single-float shadowing-import +syn keyword lispFunc call-arguments-limit least-positive-double-float shared-initialize +syn keyword lispFunc call-method least-positive-long-float shiftf +syn keyword lispFunc call-next-method least-positive-normalized-double-float short-float +syn keyword lispFunc capitalize least-positive-normalized-long-float short-float-epsilon +syn keyword lispFunc car least-positive-normalized-short-float short-float-negative-epsilon +syn keyword lispFunc case least-positive-normalized-single-float short-site-name +syn keyword lispFunc catch least-positive-short-float signal +syn keyword lispFunc ccase least-positive-single-float signed-byte +syn keyword lispFunc cdr length signum +syn keyword lispFunc ceiling let simple-condition +syn keyword lispFunc cell-error let* simple-array +syn keyword lispFunc cell-error-name lisp simple-base-string +syn keyword lispFunc cerror lisp-implementation-type simple-bit-vector +syn keyword lispFunc change-class lisp-implementation-version simple-bit-vector-p +syn keyword lispFunc char list simple-condition-format-arguments +syn keyword lispFunc char-bit list* simple-condition-format-control +syn keyword lispFunc char-bits list-all-packages simple-error +syn keyword lispFunc char-bits-limit list-length simple-string +syn keyword lispFunc char-code listen simple-string-p +syn keyword lispFunc char-code-limit listp simple-type-error +syn keyword lispFunc char-control-bit load simple-vector +syn keyword lispFunc char-downcase load-logical-pathname-translations simple-vector-p +syn keyword lispFunc char-equal load-time-value simple-warning +syn keyword lispFunc char-font locally sin +syn keyword lispFunc char-font-limit log single-flaot-epsilon +syn keyword lispFunc char-greaterp logand single-float +syn keyword lispFunc char-hyper-bit logandc1 single-float-epsilon +syn keyword lispFunc char-int logandc2 single-float-negative-epsilon +syn keyword lispFunc char-lessp logbitp sinh +syn keyword lispFunc char-meta-bit logcount sixth +syn keyword lispFunc char-name logeqv sleep +syn keyword lispFunc char-not-equal logical-pathname slot-boundp +syn keyword lispFunc char-not-greaterp logical-pathname-translations slot-exists-p +syn keyword lispFunc char-not-lessp logior slot-makunbound +syn keyword lispFunc char-super-bit lognand slot-missing +syn keyword lispFunc char-upcase lognor slot-unbound +syn keyword lispFunc char/= lognot slot-value +syn keyword lispFunc char< logorc1 software-type +syn keyword lispFunc char<= logorc2 software-version +syn keyword lispFunc char= logtest some +syn keyword lispFunc char> logxor sort +syn keyword lispFunc char>= long-float space +syn keyword lispFunc character long-float-epsilon special +syn keyword lispFunc characterp long-float-negative-epsilon special-form-p +syn keyword lispFunc check-type long-site-name special-operator-p +syn keyword lispFunc cis loop speed +syn keyword lispFunc class loop-finish sqrt +syn keyword lispFunc class-name lower-case-p stable-sort +syn keyword lispFunc class-of machine-instance standard +syn keyword lispFunc clear-input machine-type standard-char +syn keyword lispFunc clear-output machine-version standard-char-p +syn keyword lispFunc close macro-function standard-class +syn keyword lispFunc clrhash macroexpand standard-generic-function +syn keyword lispFunc code-char macroexpand-1 standard-method +syn keyword lispFunc coerce macroexpand-l standard-object +syn keyword lispFunc commonp macrolet step +syn keyword lispFunc compilation-speed make-array storage-condition +syn keyword lispFunc compile make-array store-value +syn keyword lispFunc compile-file make-broadcast-stream stream +syn keyword lispFunc compile-file-pathname make-char stream-element-type +syn keyword lispFunc compiled-function make-concatenated-stream stream-error +syn keyword lispFunc compiled-function-p make-condition stream-error-stream +syn keyword lispFunc compiler-let make-dispatch-macro-character stream-external-format +syn keyword lispFunc compiler-macro make-echo-stream streamp +syn keyword lispFunc compiler-macro-function make-hash-table streamup +syn keyword lispFunc complement make-instance string +syn keyword lispFunc complex make-instances-obsolete string-capitalize +syn keyword lispFunc complexp make-list string-char +syn keyword lispFunc compute-applicable-methods make-load-form string-char-p +syn keyword lispFunc compute-restarts make-load-form-saving-slots string-downcase +syn keyword lispFunc concatenate make-method string-equal +syn keyword lispFunc concatenated-stream make-package string-greaterp +syn keyword lispFunc concatenated-stream-streams make-pathname string-left-trim +syn keyword lispFunc cond make-random-state string-lessp +syn keyword lispFunc condition make-sequence string-not-equal +syn keyword lispFunc conjugate make-string string-not-greaterp +syn keyword lispFunc cons make-string-input-stream string-not-lessp +syn keyword lispFunc consp make-string-output-stream string-right-strim +syn keyword lispFunc constantly make-symbol string-right-trim +syn keyword lispFunc constantp make-synonym-stream string-stream +syn keyword lispFunc continue make-two-way-stream string-trim +syn keyword lispFunc control-error makunbound string-upcase +syn keyword lispFunc copy-alist map string/= +syn keyword lispFunc copy-list map-into string< +syn keyword lispFunc copy-pprint-dispatch mapc string<= +syn keyword lispFunc copy-readtable mapcan string= +syn keyword lispFunc copy-seq mapcar string> +syn keyword lispFunc copy-structure mapcon string>= +syn keyword lispFunc copy-symbol maphash stringp +syn keyword lispFunc copy-tree mapl structure +syn keyword lispFunc cos maplist structure-class +syn keyword lispFunc cosh mask-field structure-object +syn keyword lispFunc count max style-warning +syn keyword lispFunc count-if member sublim +syn keyword lispFunc count-if-not member-if sublis +syn keyword lispFunc ctypecase member-if-not subseq +syn keyword lispFunc debug merge subsetp +syn keyword lispFunc decf merge-pathname subst +syn keyword lispFunc declaim merge-pathnames subst-if +syn keyword lispFunc declaration method subst-if-not +syn keyword lispFunc declare method-combination substitute +syn keyword lispFunc decode-float method-combination-error substitute-if +syn keyword lispFunc decode-universal-time method-qualifiers substitute-if-not +syn keyword lispFunc defclass min subtypep +syn keyword lispFunc defconstant minusp svref +syn keyword lispFunc defgeneric mismatch sxhash +syn keyword lispFunc define-compiler-macro mod symbol +syn keyword lispFunc define-condition most-negative-double-float symbol-function +syn keyword lispFunc define-method-combination most-negative-fixnum symbol-macrolet +syn keyword lispFunc define-modify-macro most-negative-long-float symbol-name +syn keyword lispFunc define-setf-expander most-negative-short-float symbol-package +syn keyword lispFunc define-setf-method most-negative-single-float symbol-plist +syn keyword lispFunc define-symbol-macro most-positive-double-float symbol-value +syn keyword lispFunc defmacro most-positive-fixnum symbolp +syn keyword lispFunc defmethod most-positive-long-float synonym-stream +syn keyword lispFunc defpackage most-positive-short-float synonym-stream-symbol +syn keyword lispFunc defparameter most-positive-single-float sys +syn keyword lispFunc defsetf muffle-warning system +syn keyword lispFunc defstruct multiple-value-bind t +syn keyword lispFunc deftype multiple-value-call tagbody +syn keyword lispFunc defun multiple-value-list tailp +syn keyword lispFunc defvar multiple-value-prog1 tan +syn keyword lispFunc delete multiple-value-seteq tanh +syn keyword lispFunc delete-duplicates multiple-value-setq tenth +syn keyword lispFunc delete-file multiple-values-limit terpri +syn keyword lispFunc delete-if name-char the +syn keyword lispFunc delete-if-not namestring third +syn keyword lispFunc delete-package nbutlast throw +syn keyword lispFunc denominator nconc time +syn keyword lispFunc deposit-field next-method-p trace +syn keyword lispFunc describe nil translate-logical-pathname +syn keyword lispFunc describe-object nintersection translate-pathname +syn keyword lispFunc destructuring-bind ninth tree-equal +syn keyword lispFunc digit-char no-applicable-method truename +syn keyword lispFunc digit-char-p no-next-method truncase +syn keyword lispFunc directory not truncate +syn keyword lispFunc directory-namestring notany two-way-stream +syn keyword lispFunc disassemble notevery two-way-stream-input-stream +syn keyword lispFunc division-by-zero notinline two-way-stream-output-stream +syn keyword lispFunc do nreconc type +syn keyword lispFunc do* nreverse type-error +syn keyword lispFunc do-all-symbols nset-difference type-error-datum +syn keyword lispFunc do-exeternal-symbols nset-exclusive-or type-error-expected-type +syn keyword lispFunc do-external-symbols nstring type-of +syn keyword lispFunc do-symbols nstring-capitalize typecase +syn keyword lispFunc documentation nstring-downcase typep +syn keyword lispFunc dolist nstring-upcase unbound-slot +syn keyword lispFunc dotimes nsublis unbound-slot-instance +syn keyword lispFunc double-float nsubst unbound-variable +syn keyword lispFunc double-float-epsilon nsubst-if undefined-function +syn keyword lispFunc double-float-negative-epsilon nsubst-if-not unexport +syn keyword lispFunc dpb nsubstitute unintern +syn keyword lispFunc dribble nsubstitute-if union +syn keyword lispFunc dynamic-extent nsubstitute-if-not unless +syn keyword lispFunc ecase nth unread +syn keyword lispFunc echo-stream nth-value unread-char +syn keyword lispFunc echo-stream-input-stream nthcdr unsigned-byte +syn keyword lispFunc echo-stream-output-stream null untrace +syn keyword lispFunc ed number unuse-package +syn keyword lispFunc eighth numberp unwind-protect +syn keyword lispFunc elt numerator update-instance-for-different-class +syn keyword lispFunc encode-universal-time nunion update-instance-for-redefined-class +syn keyword lispFunc end-of-file oddp upgraded-array-element-type +syn keyword lispFunc endp open upgraded-complex-part-type +syn keyword lispFunc enough-namestring open-stream-p upper-case-p +syn keyword lispFunc ensure-directories-exist optimize use-package +syn keyword lispFunc ensure-generic-function or use-value +syn keyword lispFunc eq otherwise user +syn keyword lispFunc eql output-stream-p user-homedir-pathname +syn keyword lispFunc equal package values +syn keyword lispFunc equalp package-error values-list +syn keyword lispFunc error package-error-package vector +syn keyword lispFunc etypecase package-name vector-pop +syn keyword lispFunc eval package-nicknames vector-push +syn keyword lispFunc eval-when package-shadowing-symbols vector-push-extend +syn keyword lispFunc evalhook package-use-list vectorp +syn keyword lispFunc evenp package-used-by-list warn +syn keyword lispFunc every packagep warning +syn keyword lispFunc exp pairlis when +syn keyword lispFunc export parse-error wild-pathname-p +syn keyword lispFunc expt parse-integer with-accessors +syn keyword lispFunc extended-char parse-namestring with-compilation-unit +syn keyword lispFunc fboundp pathname with-condition-restarts +syn keyword lispFunc fceiling pathname-device with-hash-table-iterator +syn keyword lispFunc fdefinition pathname-directory with-input-from-string +syn keyword lispFunc ffloor pathname-host with-open-file +syn keyword lispFunc fifth pathname-match-p with-open-stream +syn keyword lispFunc file-author pathname-name with-output-to-string +syn keyword lispFunc file-error pathname-type with-package-iterator +syn keyword lispFunc file-error-pathname pathname-version with-simple-restart +syn keyword lispFunc file-length pathnamep with-slots +syn keyword lispFunc file-namestring peek-char with-standard-io-syntax +syn keyword lispFunc file-position phase write +syn keyword lispFunc file-stream pi write-byte +syn keyword lispFunc file-string-length plusp write-char +syn keyword lispFunc file-write-date pop write-line +syn keyword lispFunc fill position write-sequence +syn keyword lispFunc fill-pointer position-if write-string +syn keyword lispFunc find position-if-not write-to-string +syn keyword lispFunc find-all-symbols pprint y-or-n-p +syn keyword lispFunc find-class pprint-dispatch yes-or-no-p +syn keyword lispFunc find-if pprint-exit-if-list-exhausted zerop +syn keyword lispFunc find-if-not pprint-fill + +syn match lispFunc "\" +if exists("g:lispsyntax_clisp") + " CLISP FFI: + syn match lispFunc "\<\(ffi:\)\?with-c-\(place\|var\)\>" + syn match lispFunc "\<\(ffi:\)\?with-foreign-\(object\|string\)\>" + syn match lispFunc "\<\(ffi:\)\?default-foreign-\(language\|library\)\>" + syn match lispFunc "\<\([us]_\?\)\?\(element\|deref\|cast\|slot\|validp\)\>" + syn match lispFunc "\<\(ffi:\)\?set-foreign-pointer\>" + syn match lispFunc "\<\(ffi:\)\?allocate-\(deep\|shallow\)\>" + syn match lispFunc "\<\(ffi:\)\?c-lines\>" + syn match lispFunc "\<\(ffi:\)\?foreign-\(value\|free\|variable\|function\|object\)\>" + syn match lispFunc "\<\(ffi:\)\?foreign-address\(-null\|unsigned\)\?\>" + syn match lispFunc "\<\(ffi:\)\?undigned-foreign-address\>" + syn match lispFunc "\<\(ffi:\)\?c-var-\(address\|object\)\>" + syn match lispFunc "\<\(ffi:\)\?typeof\>" + syn match lispFunc "\<\(ffi:\)\?\(bit\)\?sizeof\>" +" CLISP Macros, functions et al: + syn match lispFunc "\<\(ext:\)\?with-collect\>" + syn match lispFunc "\<\(ext:\)\?letf\*\?\>" + syn match lispFunc "\<\(ext:\)\?finalize\>\>" + syn match lispFunc "\<\(ext:\)\?memoized\>" + syn match lispFunc "\<\(ext:\)\?getenv\>" + syn match lispFunc "\<\(ext:\)\?convert-string-\(to\|from\)-bytes\>" + syn match lispFunc "\<\(ext:\)\?ethe\>" + syn match lispFunc "\<\(ext:\)\?with-gensyms\>" + syn match lispFunc "\<\(ext:\)\?open-http\>" + syn match lispFunc "\<\(ext:\)\?string-concat\>" + syn match lispFunc "\<\(ext:\)\?with-http-\(in\|out\)put\>" + syn match lispFunc "\<\(ext:\)\?with-html-output\>" + syn match lispFunc "\<\(ext:\)\?expand-form\>" + syn match lispFunc "\<\(ext:\)\?\(without-\)\?package-lock\>" + syn match lispFunc "\<\(ext:\)\?re-export\>" + syn match lispFunc "\<\(ext:\)\?saveinitmem\>" + syn match lispFunc "\<\(ext:\)\?\(read\|write\)-\(integer\|float\)\>" + syn match lispFunc "\<\(ext:\)\?\(read\|write\)-\(char\|byte\)-sequence\>" + syn match lispFunc "\<\(custom:\)\?\*system-package-list\*\>" + syn match lispFunc "\<\(custom:\)\?\*ansi\*\>" +endif + +" --------------------------------------------------------------------- +" Lisp Keywords (modifiers): {{{1 +syn keyword lispKey :abort :from-end :overwrite +syn keyword lispKey :adjustable :gensym :predicate +syn keyword lispKey :append :host :preserve-whitespace +syn keyword lispKey :array :if-does-not-exist :pretty +syn keyword lispKey :base :if-exists :print +syn keyword lispKey :case :include :print-function +syn keyword lispKey :circle :index :probe +syn keyword lispKey :conc-name :inherited :radix +syn keyword lispKey :constructor :initial-contents :read-only +syn keyword lispKey :copier :initial-element :rehash-size +syn keyword lispKey :count :initial-offset :rehash-threshold +syn keyword lispKey :create :initial-value :rename +syn keyword lispKey :default :input :rename-and-delete +syn keyword lispKey :defaults :internal :size +syn keyword lispKey :device :io :start +syn keyword lispKey :direction :junk-allowed :start1 +syn keyword lispKey :directory :key :start2 +syn keyword lispKey :displaced-index-offset :length :stream +syn keyword lispKey :displaced-to :level :supersede +syn keyword lispKey :element-type :name :test +syn keyword lispKey :end :named :test-not +syn keyword lispKey :end1 :new-version :type +syn keyword lispKey :end2 :nicknames :use +syn keyword lispKey :error :output :verbose +syn keyword lispKey :escape :output-file :version +syn keyword lispKey :external +" defpackage arguments +syn keyword lispKey :documentation :shadowing-import-from :modern :export +syn keyword lispKey :case-sensitive :case-inverted :shadow :import-from :intern +" lambda list keywords +syn keyword lispKey &allow-other-keys &aux &body +syn keyword lispKey &environment &key &optional &rest &whole +" make-array argument +syn keyword lispKey :fill-pointer +" readtable-case values +syn keyword lispKey :upcase :downcase :preserve :invert +" eval-when situations +syn keyword lispKey :load-toplevel :compile-toplevel :execute +" ANSI Extended LOOP: +syn keyword lispKey :while :until :for :do :if :then :else :when :unless :in +syn keyword lispKey :across :finally :collect :nconc :maximize :minimize :sum +syn keyword lispKey :and :with :initially :append :into :count :end :repeat +syn keyword lispKey :always :never :thereis :from :to :upto :downto :below +syn keyword lispKey :above :by :on :being :each :the :hash-key :hash-keys +syn keyword lispKey :hash-value :hash-values :using :of-type :upfrom :downfrom +if exists("g:lispsyntax_clisp") + " CLISP FFI: + syn keyword lispKey :arguments :return-type :library :full :malloc-free + syn keyword lispKey :none :alloca :in :out :in-out :stdc-stdcall :stdc :c + syn keyword lispKey :language :built-in :typedef :external + syn keyword lispKey :fini :init-once :init-always +endif + +" --------------------------------------------------------------------- +" Standard Lisp Variables: {{{1 +syn keyword lispVar *applyhook* *load-pathname* *print-pprint-dispatch* +syn keyword lispVar *break-on-signals* *load-print* *print-pprint-dispatch* +syn keyword lispVar *break-on-signals* *load-truename* *print-pretty* +syn keyword lispVar *break-on-warnings* *load-verbose* *print-radix* +syn keyword lispVar *compile-file-pathname* *macroexpand-hook* *print-readably* +syn keyword lispVar *compile-file-pathname* *modules* *print-right-margin* +syn keyword lispVar *compile-file-truename* *package* *print-right-margin* +syn keyword lispVar *compile-file-truename* *print-array* *query-io* +syn keyword lispVar *compile-print* *print-base* *random-state* +syn keyword lispVar *compile-verbose* *print-case* *read-base* +syn keyword lispVar *compile-verbose* *print-circle* *read-default-float-format* +syn keyword lispVar *debug-io* *print-escape* *read-eval* +syn keyword lispVar *debugger-hook* *print-gensym* *read-suppress* +syn keyword lispVar *default-pathname-defaults* *print-length* *readtable* +syn keyword lispVar *error-output* *print-level* *standard-input* +syn keyword lispVar *evalhook* *print-lines* *standard-output* +syn keyword lispVar *features* *print-miser-width* *terminal-io* +syn keyword lispVar *gensym-counter* *print-miser-width* *trace-output* + +" --------------------------------------------------------------------- +" Strings: {{{1 +syn region lispString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@Spell +if exists("g:lisp_instring") + syn region lispInString keepend matchgroup=Delimiter start=+"(+rs=s+1 skip=+|.\{-}|+ matchgroup=Delimiter end=+)"+ contains=@lispBaseListCluster,lispInStringString + syn region lispInStringString start=+\\"+ skip=+\\\\+ end=+\\"+ contained +endif + +" --------------------------------------------------------------------- +" Shared with Xlisp, Declarations, Macros, Functions: {{{1 +syn keyword lispDecl defmacro do-all-symbols labels +syn keyword lispDecl defsetf do-external-symbols let +syn keyword lispDecl deftype do-symbols locally +syn keyword lispDecl defun dotimes macrolet +syn keyword lispDecl do* flet multiple-value-bind +if exists("g:lispsyntax_clisp") + " CLISP FFI: + syn match lispDecl "\<\(ffi:\)\?def-c-\(var\|const\|enum\|type\|struct\)\>" + syn match lispDecl "\<\(ffi:\)\?def-call-\(out\|in\)\>" + syn match lispDecl "\<\(ffi:\)\?c-\(function\|struct\|pointer\|string\)\>" + syn match lispDecl "\<\(ffi:\)\?c-ptr\(-null\)\?\>" + syn match lispDecl "\<\(ffi:\)\?c-array\(-ptr\|-max\)\?\>" + syn match lispDecl "\<\(ffi:\)\?[us]\?\(char\|short\|int\|long\)\>" + syn match lispDecl "\<\(win32:\|w32\)\?d\?word\>" + syn match lispDecl "\<\([us]_\?\)\?int\(8\|16\|32\|64\)\(_t\)\?\>" + syn keyword lispDecl size_t off_t time_t handle +endif + +" --------------------------------------------------------------------- +" Numbers: supporting integers and floating point numbers {{{1 +syn match lispNumber "-\=\(\.\d\+\|\d\+\(\.\d*\)\=\)\([dDeEfFlL][-+]\=\d\+\)\=" +syn match lispNumber "-\=\(\d\+/\d\+\)" + +syn match lispEscapeSpecial "\*\w[a-z_0-9-]*\*" +syn match lispEscapeSpecial !#|[^()'`,"; \t]\+|#! +syn match lispEscapeSpecial !#x\x\+! +syn match lispEscapeSpecial !#o\o\+! +syn match lispEscapeSpecial !#b[01]\+! +syn match lispEscapeSpecial !#\\[ -}\~]! +syn match lispEscapeSpecial !#[':][^()'`,"; \t]\+! +syn match lispEscapeSpecial !#([^()'`,"; \t]\+)! +syn match lispEscapeSpecial !#\\\%(Space\|Newline\|Tab\|Page\|Rubout\|Linefeed\|Return\|Backspace\)! +syn match lispEscapeSpecial "\<+[a-zA-Z_][a-zA-Z_0-9-]*+\>" + +syn match lispConcat "\s\.\s" +syn match lispParenError ")" + +" --------------------------------------------------------------------- +" Comments: {{{1 +syn cluster lispCommentGroup contains=lispTodo,@Spell +syn match lispComment ";.*$" contains=@lispCommentGroup +syn region lispCommentRegion start="#|" end="|#" contains=lispCommentRegion,@lispCommentGroup +syn keyword lispTodo contained combak combak: todo todo: + +" --------------------------------------------------------------------- +" Synchronization: {{{1 +syn sync lines=100 + +" --------------------------------------------------------------------- +" Define Highlighting: {{{1 +if !exists("skip_lisp_syntax_inits") + + hi def link lispCommentRegion lispComment + hi def link lispAtomNmbr lispNumber + hi def link lispAtomMark lispMark + hi def link lispInStringString lispString + + hi def link lispAtom Identifier + hi def link lispAtomBarSymbol Special + hi def link lispBarSymbol Special + hi def link lispComment Comment + hi def link lispConcat Statement + hi def link lispDecl Statement + hi def link lispFunc Statement + hi def link lispKey Type + hi def link lispMark Delimiter + hi def link lispNumber Number + hi def link lispParenError Error + hi def link lispEscapeSpecial Type + hi def link lispString String + hi def link lispTodo Todo + hi def link lispVar Statement + + if exists("g:lisp_rainbow") && g:lisp_rainbow != 0 + if &bg == "dark" + hi def hlLevel0 ctermfg=red guifg=red1 + hi def hlLevel1 ctermfg=yellow guifg=orange1 + hi def hlLevel2 ctermfg=green guifg=yellow1 + hi def hlLevel3 ctermfg=cyan guifg=greenyellow + hi def hlLevel4 ctermfg=magenta guifg=green1 + hi def hlLevel5 ctermfg=red guifg=springgreen1 + hi def hlLevel6 ctermfg=yellow guifg=cyan1 + hi def hlLevel7 ctermfg=green guifg=slateblue1 + hi def hlLevel8 ctermfg=cyan guifg=magenta1 + hi def hlLevel9 ctermfg=magenta guifg=purple1 + else + hi def hlLevel0 ctermfg=red guifg=red3 + hi def hlLevel1 ctermfg=darkyellow guifg=orangered3 + hi def hlLevel2 ctermfg=darkgreen guifg=orange2 + hi def hlLevel3 ctermfg=blue guifg=yellow3 + hi def hlLevel4 ctermfg=darkmagenta guifg=olivedrab4 + hi def hlLevel5 ctermfg=red guifg=green4 + hi def hlLevel6 ctermfg=darkyellow guifg=paleturquoise3 + hi def hlLevel7 ctermfg=darkgreen guifg=deepskyblue4 + hi def hlLevel8 ctermfg=blue guifg=darkslateblue + hi def hlLevel9 ctermfg=darkmagenta guifg=darkviolet + endif + endif + +endif + +let b:current_syntax = "lisp" + +" --------------------------------------------------------------------- +" vim: ts=8 nowrap fdm=marker + +endif diff --git a/syntax/lite.vim b/syntax/lite.vim new file mode 100644 index 0000000..ca9181a --- /dev/null +++ b/syntax/lite.vim @@ -0,0 +1,172 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: lite +" Maintainer: Lutz Eymers +" URL: http://www.isp.de/data/lite.vim +" Email: Subject: send syntax_vim.tgz +" Last Change: 2001 Mai 01 +" +" Options lite_sql_query = 1 for SQL syntax highligthing inside strings +" lite_minlines = x to sync at least x lines backwards + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'lite' +endif + +if main_syntax == 'lite' + if exists("lite_sql_query") + if lite_sql_query == 1 + syn include @liteSql :p:h/sql.vim + unlet b:current_syntax + endif + endif +endif + +if main_syntax == 'msql' + if exists("msql_sql_query") + if msql_sql_query == 1 + syn include @liteSql :p:h/sql.vim + unlet b:current_syntax + endif + endif +endif + +syn cluster liteSql remove=sqlString,sqlComment + +syn case match + +" Internal Variables +syn keyword liteIntVar ERRMSG contained + +" Comment +syn region liteComment start="/\*" end="\*/" contains=liteTodo + +" Function names +syn keyword liteFunctions echo printf fprintf open close read +syn keyword liteFunctions readln readtok +syn keyword liteFunctions split strseg chop tr sub substr +syn keyword liteFunctions test unlink umask chmod mkdir chdir rmdir +syn keyword liteFunctions rename truncate link symlink stat +syn keyword liteFunctions sleep system getpid getppid kill +syn keyword liteFunctions time ctime time2unixtime unixtime2year +syn keyword liteFunctions unixtime2year unixtime2month unixtime2day +syn keyword liteFunctions unixtime2hour unixtime2min unixtime2sec +syn keyword liteFunctions strftime +syn keyword liteFunctions getpwnam getpwuid +syn keyword liteFunctions gethostbyname gethostbyaddress +syn keyword liteFunctions urlEncode setContentType includeFile +syn keyword liteFunctions msqlConnect msqlClose msqlSelectDB +syn keyword liteFunctions msqlQuery msqlStoreResult msqlFreeResult +syn keyword liteFunctions msqlFetchRow msqlDataSeek msqlListDBs +syn keyword liteFunctions msqlListTables msqlInitFieldList msqlListField +syn keyword liteFunctions msqlFieldSeek msqlNumRows msqlEncode +syn keyword liteFunctions exit fatal typeof +syn keyword liteFunctions crypt addHttpHeader + +" Conditional +syn keyword liteConditional if else + +" Repeat +syn keyword liteRepeat while + +" Operator +syn keyword liteStatement break return continue + +" Operator +syn match liteOperator "[-+=#*]" +syn match liteOperator "/[^*]"me=e-1 +syn match liteOperator "\$" +syn match liteRelation "&&" +syn match liteRelation "||" +syn match liteRelation "[!=<>]=" +syn match liteRelation "[<>]" + +" Identifier +syn match liteIdentifier "$\h\w*" contains=liteIntVar,liteOperator +syn match liteGlobalIdentifier "@\h\w*" contains=liteIntVar + +" Include +syn keyword liteInclude load + +" Define +syn keyword liteDefine funct + +" Type +syn keyword liteType int uint char real + +" String +syn region liteString keepend matchgroup=None start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=liteIdentifier,liteSpecialChar,@liteSql + +" Number +syn match liteNumber "-\=\<\d\+\>" + +" Float +syn match liteFloat "\(-\=\<\d+\|-\=\)\.\d\+\>" + +" SpecialChar +syn match liteSpecialChar "\\[abcfnrtv\\]" contained + +syn match liteParentError "[)}\]]" + +" Todo +syn keyword liteTodo TODO Todo todo contained + +" dont syn #!... +syn match liteExec "^#!.*$" + +" Parents +syn cluster liteInside contains=liteComment,liteFunctions,liteIdentifier,liteGlobalIdentifier,liteConditional,liteRepeat,liteStatement,liteOperator,liteRelation,liteType,liteString,liteNumber,liteFloat,liteParent + +syn region liteParent matchgroup=Delimiter start="(" end=")" contains=@liteInside +syn region liteParent matchgroup=Delimiter start="{" end="}" contains=@liteInside +syn region liteParent matchgroup=Delimiter start="\[" end="\]" contains=@liteInside + +" sync +if main_syntax == 'lite' + if exists("lite_minlines") + exec "syn sync minlines=" . lite_minlines + else + syn sync minlines=100 + endif +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link liteComment Comment +hi def link liteString String +hi def link liteNumber Number +hi def link liteFloat Float +hi def link liteIdentifier Identifier +hi def link liteGlobalIdentifier Identifier +hi def link liteIntVar Identifier +hi def link liteFunctions Function +hi def link liteRepeat Repeat +hi def link liteConditional Conditional +hi def link liteStatement Statement +hi def link liteType Type +hi def link liteInclude Include +hi def link liteDefine Define +hi def link liteSpecialChar SpecialChar +hi def link liteParentError liteError +hi def link liteError Error +hi def link liteTodo Todo +hi def link liteOperator Operator +hi def link liteRelation Operator + + +let b:current_syntax = "lite" + +if main_syntax == 'lite' + unlet main_syntax +endif + +" vim: ts=8 + +endif diff --git a/syntax/litestep.vim b/syntax/litestep.vim new file mode 100644 index 0000000..32c7cb6 --- /dev/null +++ b/syntax/litestep.vim @@ -0,0 +1,273 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: LiteStep RC file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2007-02-22 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword litestepTodo + \ contained + \ TODO FIXME XXX NOTE + +syn match litestepComment + \ contained display contains=litestepTodo,@Spell + \ ';.*$' + +syn case ignore + +syn cluster litestepBeginnings + \ contains= + \ litestepComment, + \ litestepPreProc, + \ litestepMultiCommandStart, + \ litestepBangCommandStart, + \ litestepGenericDirective + +syn match litestepGenericDirective + \ contained display + \ '\<\h\w\+\>' + +syn match litestepBeginning + \ nextgroup=@litestepBeginnings skipwhite + \ '^' + +syn keyword litestepPreProc + \ contained + \ Include + \ If + \ ElseIf + \ Else + \ EndIf + +syn cluster litestepMultiCommands + \ contains= + \ litestepMultiCommand + +syn match litestepMultiCommandStart + \ nextgroup=@litestepMultiCommands + \ '\*' + +syn match litestepMultiCommand + \ contained display + \ '\<\h\w\+\>' + +syn cluster litestepVariables + \ contains= + \ litestepBuiltinFolderVariable, + \ litestepBuiltinConditionalVariable, + \ litestepBuiltinResourceVariable, + \ litestepBuiltinGUIDFolderMappingVariable, + \ litestepVariable + +syn region litestepVariableExpansion + \ display oneline transparent + \ contains= + \ @litestepVariables, + \ litestepNumber, + \ litestepMathOperator + \ matchgroup=litestepVariableExpansion + \ start='\$' + \ end='\$' + +syn match litestepNumber + \ display + \ '\<\d\+\>' + +syn region litestepString + \ display oneline contains=litestepVariableExpansion + \ start=+"+ end=+"+ + +" TODO: unsure about this one. +syn region litestepSubValue + \ display oneline contains=litestepVariableExpansion + \ start=+'+ end=+'+ + +syn keyword litestepBoolean + \ true + \ false + +"syn keyword litestepLine +" \ ? + +"syn match litestepColor +" \ display +" \ '\<\x\+\>' + +syn match litestepRelationalOperator + \ display + \ '=\|<[>=]\=\|>=\=' + +syn keyword litestepLogicalOperator + \ and + \ or + \ not + +syn match litestepMathOperator + \ contained display + \ '[+*/-]' + +syn keyword litestepBuiltinDirective + \ LoadModule + \ LSNoStartup + \ LSAutoHideModules + \ LSNoShellWarning + \ LSSetAsShell + \ LSUseSystemDDE + \ LSDisableTrayService + \ LSImageFolder + \ ThemeAuthor + \ ThemeName + +syn keyword litestepDeprecatedBuiltinDirective + \ LSLogLevel + \ LSLogFile + +syn match litestepVariable + \ contained display + \ '\<\h\w\+\>' + +syn keyword litestepBuiltinFolderVariable + \ contained + \ AdminToolsDir + \ CommonAdminToolsDir + \ CommonDesktopDir + \ CommonFavorites + \ CommonPrograms + \ CommonStartMenu + \ CommonStartup + \ Cookies + \ Desktop + \ DesktopDir + \ DocumentsDir + \ Favorites + \ Fonts + \ History + \ Internet + \ InternetCache + \ LitestepDir + \ Nethood + \ Printhood + \ Programs + \ QuickLaunch + \ Recent + \ Sendto + \ Startmenu + \ Startup + \ Templates + \ WinDir + \ LitestepDir + +syn keyword litestepBuiltinConditionalVariable + \ contained + \ Win2000 + \ Win95 + \ Win98 + \ Win9X + \ WinME + \ WinNT + \ WinNT4 + \ WinXP + +syn keyword litestepBuiltinResourceVariable + \ contained + \ CompileDate + \ ResolutionX + \ ResolutionY + \ UserName + +syn keyword litestepBuiltinGUIDFolderMappingVariable + \ contained + \ AdminTools + \ BitBucket + \ Controls + \ Dialup + \ Documents + \ Drives + \ Network + \ NetworkAndDialup + \ Printers + \ Scheduled + +syn cluster litestepBangs + \ contains= + \ litestepBuiltinBang, + \ litestepBang + +syn match litestepBangStart + \ nextgroup=@litestepBangs + \ '!' + +syn match litestepBang + \ contained display + \ '\<\h\w\+\>' + +syn keyword litestepBuiltinBang + \ contained + \ About + \ Alert + \ CascadeWindows + \ Confirm + \ Execute + \ Gather + \ HideModules + \ LogOff + \ MinimizeWindows + \ None + \ Quit + \ Recycle + \ Refresh + \ Reload + \ ReloadModule + \ RestoreWindows + \ Run + \ ShowModules + \ Shutdown + \ Switchuser + \ TileWindowsH + \ TileWindowsV + \ ToggleModules + \ UnloadModule + +hi def link litestepTodo Todo +hi def link litestepComment Comment +hi def link litestepDirective Keyword +hi def link litestepGenericDirective litestepDirective +hi def link litestepPreProc PreProc +hi def link litestepMultiCommandStart litestepPreProc +hi def link litestepMultiCommand litestepDirective +hi def link litestepDelimiter Delimiter +hi def link litestepVariableExpansion litestepDelimiter +hi def link litestepNumber Number +hi def link litestepString String +hi def link litestepSubValue litestepString +hi def link litestepBoolean Boolean +"hi def link litestepLine +"hi def link litestepColor Type +hi def link litestepOperator Operator +hi def link litestepRelationalOperator litestepOperator +hi def link litestepLogicalOperator litestepOperator +hi def link litestepMathOperator litestepOperator +hi def link litestepBuiltinDirective litestepDirective +hi def link litestepDeprecatedBuiltinDirective Error +hi def link litestepVariable Identifier +hi def link litestepBuiltinFolderVariable Identifier +hi def link litestepBuiltinConditionalVariable Identifier +hi def link litestepBuiltinResourceVariable Identifier +hi def link litestepBuiltinGUIDFolderMappingVariable Identifier +hi def link litestepBangStart litestepPreProc +hi def link litestepBang litestepDirective +hi def link litestepBuiltinBang litestepBang + +let b:current_syntax = "litestep" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/loginaccess.vim b/syntax/loginaccess.vim new file mode 100644 index 0000000..465fbe9 --- /dev/null +++ b/syntax/loginaccess.vim @@ -0,0 +1,100 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: login.access(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword loginaccessTodo contained TODO FIXME XXX NOTE + +syn region loginaccessComment display oneline start='^#' end='$' + \ contains=loginaccessTodo,@Spell + +syn match loginaccessBegin display '^' + \ nextgroup=loginaccessPermission, + \ loginaccessComment skipwhite + +syn match loginaccessPermission contained display '[^#]' + \ contains=loginaccessPermError + \ nextgroup=loginaccessUserSep + +syn match loginaccessPermError contained display '[^+-]' + +syn match loginaccessUserSep contained display ':' + \ nextgroup=loginaccessUsers, + \ loginaccessAllUsers, + \ loginaccessExceptUsers + +syn match loginaccessUsers contained display '[^, \t:]\+' + \ nextgroup=loginaccessUserIntSep, + \ loginaccessOriginSep + +syn match loginaccessAllUsers contained display '\' + \ nextgroup=loginaccessUserIntSep, + \ loginaccessOriginSep + +syn match loginaccessLocalUsers contained display '\' + \ nextgroup=loginaccessUserIntSep, + \ loginaccessOriginSep + +syn match loginaccessExceptUsers contained display '\' + \ nextgroup=loginaccessUserIntSep, + \ loginaccessOriginSep + +syn match loginaccessUserIntSep contained display '[, \t]' + \ nextgroup=loginaccessUsers, + \ loginaccessAllUsers, + \ loginaccessExceptUsers + +syn match loginaccessOriginSep contained display ':' + \ nextgroup=loginaccessOrigins, + \ loginaccessAllOrigins, + \ loginaccessExceptOrigins + +syn match loginaccessOrigins contained display '[^, \t]\+' + \ nextgroup=loginaccessOriginIntSep + +syn match loginaccessAllOrigins contained display '\' + \ nextgroup=loginaccessOriginIntSep + +syn match loginaccessLocalOrigins contained display '\' + \ nextgroup=loginaccessOriginIntSep + +syn match loginaccessExceptOrigins contained display '\' + \ nextgroup=loginaccessOriginIntSep + +syn match loginaccessOriginIntSep contained display '[, \t]' + \ nextgroup=loginaccessOrigins, + \ loginaccessAllOrigins, + \ loginaccessExceptOrigins + +hi def link loginaccessTodo Todo +hi def link loginaccessComment Comment +hi def link loginaccessPermission Type +hi def link loginaccessPermError Error +hi def link loginaccessUserSep Delimiter +hi def link loginaccessUsers Identifier +hi def link loginaccessAllUsers Macro +hi def link loginaccessLocalUsers Macro +hi def link loginaccessExceptUsers Operator +hi def link loginaccessUserIntSep loginaccessUserSep +hi def link loginaccessOriginSep loginaccessUserSep +hi def link loginaccessOrigins Identifier +hi def link loginaccessAllOrigins Macro +hi def link loginaccessLocalOrigins Macro +hi def link loginaccessExceptOrigins loginaccessExceptUsers +hi def link loginaccessOriginIntSep loginaccessUserSep + +let b:current_syntax = "loginaccess" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/logindefs.vim b/syntax/logindefs.vim new file mode 100644 index 0000000..e1202ba --- /dev/null +++ b/syntax/logindefs.vim @@ -0,0 +1,178 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: login.defs(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2010-11-29 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match logindefsBegin display '^' + \ nextgroup= + \ logindefsComment, + \ @logindefsKeyword + \ skipwhite + +syn region logindefsComment display oneline start='^\s*#' end='$' + \ contains=logindefsTodo,@Spell + +syn keyword logindefsTodo contained TODO FIXME XXX NOTE + +syn cluster logindefsKeyword contains= + \ logindefsBooleanKeyword, + \ logindefsEncryptKeyword, + \ logindefsNumberKeyword, + \ logindefsPathKeyword, + \ logindefsPathsKeyword, + \ logindefsStringKeyword + +syn keyword logindefsBooleanKeyword contained + \ CHFN_AUTH + \ CHSH_AUTH + \ CREATE_HOME + \ DEFAULT_HOME + \ FAILLOG_ENAB + \ LASTLOG_ENAB + \ LOG_OK_LOGINS + \ LOG_UNKFAIL_ENAB + \ MAIL_CHECK_ENAB + \ MD5_CRYPT_ENAB + \ OBSCURE_CHECKS_ENAB + \ PASS_ALWAYS_WARN + \ PORTTIME_CHECKS_ENAB + \ QUOTAS_ENAB + \ SU_WHEEL_ONLY + \ SYSLOG_SG_ENAB + \ SYSLOG_SU_ENAB + \ USERGROUPS_ENAB + \ nextgroup=logindefsBoolean skipwhite + +syn keyword logindefsBoolean contained yes no + +syn keyword logindefsEncryptKeyword contained + \ ENCRYPT_METHOD + \ nextgroup=logindefsEncryptMethod skipwhite + +syn keyword logindefsEncryptMethod contained + \ DES + \ MD5 + \ SHA256 + \ SHA512 + +syn keyword logindefsNumberKeyword contained + \ ERASECHAR + \ FAIL_DELAY + \ GID_MAX + \ GID_MIN + \ KILLCHAR + \ LOGIN_RETRIES + \ LOGIN_TIMEOUT + \ MAX_MEMBERS_PER_GROUP + \ PASS_CHANGE_TRIES + \ PASS_MAX_DAYS + \ PASS_MIN_DAYS + \ PASS_WARN_AGE + \ PASS_MAX_LEN + \ PASS_MIN_LEN + \ SHA_CRYPT_MAX_ROUNDS + \ SHA_CRYPT_MIN_ROUNDS + \ SYS_GID_MAX + \ SYS_GID_MIN + \ SYS_UID_MAX + \ SYS_UID_MIN + \ UID_MAX + \ UID_MIN + \ ULIMIT + \ UMASK + \ nextgroup=@logindefsNumber skipwhite + +syn cluster logindefsNumber contains= + \ logindefsDecimal, + \ logindefsHex, + \ logindefsOctal, + \ logindefsOctalError + +syn match logindefsDecimal contained '\<\d\+\>' + +syn match logindefsHex contained display '\<0x\x\+\>' + +syn match logindefsOctal contained display '\<0\o\+\>' + \ contains=logindefsOctalZero +syn match logindefsOctalZero contained display '\<0' + +syn match logindefsOctalError contained display '\<0\o*[89]\d*\>' + +syn keyword logindefsPathKeyword contained + \ ENVIRON_FILE + \ FAKE_SHELL + \ FTMP_FILE + \ HUSHLOGIN_FILE + \ ISSUE_FILE + \ MAIL_DIR + \ MAIL_FILE + \ NOLOGINS_FILE + \ SULOG_FILE + \ TTYTYPE_FILE + \ nextgroup=logindefsPath skipwhite + +syn match logindefsPath contained '[[:graph:]]\+' + +syn keyword logindefsPathsKeyword contained + \ CONSOLE + \ ENV_PATH + \ ENV_SUPATH + \ MOTD_FILE + \ nextgroup=logindefsPaths skipwhite + +syn match logindefsPaths contained '[^:]\+' + \ nextgroup=logindefsPathDelim + +syn match logindefsPathDelim contained ':' nextgroup=logindefsPaths + +syn keyword logindefsStringKeyword contained + \ CHFN_RESTRICT + \ CONSOLE_GROUPS + \ ENV_HZ + \ ENV_TZ + \ LOGIN_STRING + \ SU_NAME + \ TTYGROUP + \ TTYPERM + \ USERDEL_CMD + \ nextgroup=logindefsString skipwhite + +syn match logindefsString contained '[[:graph:]]\+' + +hi def link logindefsComment Comment +hi def link logindefsTodo Todo +hi def link logindefsKeyword Keyword +hi def link logindefsBooleanKeyword logindefsKeyword +hi def link logindefsEncryptKeyword logindefsKeyword +hi def link logindefsNumberKeyword logindefsKeyword +hi def link logindefsPathKeyword logindefsKeyword +hi def link logindefsPathsKeyword logindefsKeyword +hi def link logindefsStringKeyword logindefsKeyword +hi def link logindefsBoolean Boolean +hi def link logindefsEncryptMethod Type +hi def link logindefsNumber Number +hi def link logindefsDecimal logindefsNumber +hi def link logindefsHex logindefsNumber +hi def link logindefsOctal logindefsNumber +hi def link logindefsOctalZero PreProc +hi def link logindefsOctalError Error +hi def link logindefsPath String +hi def link logindefsPaths logindefsPath +hi def link logindefsPathDelim Delimiter +hi def link logindefsString String + +let b:current_syntax = "logindefs" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/logtalk.vim b/syntax/logtalk.vim new file mode 100644 index 0000000..4b49572 --- /dev/null +++ b/syntax/logtalk.vim @@ -0,0 +1,439 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" +" Language: Logtalk +" Maintainer: Paulo Moura +" Last Change: February 4, 2012 + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Logtalk is case sensitive: + +syn case match + + +" Logtalk variables + +syn match logtalkVariable "\<\(\u\|_\)\(\w\)*\>" + + +" Logtalk clause functor + +syn match logtalkOperator ":-" + + +" Logtalk quoted atoms and strings + +syn region logtalkString start=+"+ skip=+\\"+ end=+"+ +syn region logtalkAtom start=+'+ skip=+\\'+ end=+'+ contains=logtalkEscapeSequence + +syn match logtalkEscapeSequence contained "\\\([\\abfnrtv\"\']\|\(x[a-fA-F0-9]\+\|[0-7]\+\)\\\)" + + +" Logtalk message sending operators + +syn match logtalkOperator "::" +syn match logtalkOperator ":" +syn match logtalkOperator "\^\^" + + +" Logtalk external call + +syn region logtalkExtCall matchgroup=logtalkExtCallTag start="{" matchgroup=logtalkExtCallTag end="}" contains=ALL + + +" Logtalk opening entity directives + +syn region logtalkOpenEntityDir matchgroup=logtalkOpenEntityDirTag start=":- object(" matchgroup=logtalkOpenEntityDirTag end=")\." contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkString,logtalkAtom,logtalkEntityRel,logtalkLineComment +syn region logtalkOpenEntityDir matchgroup=logtalkOpenEntityDirTag start=":- protocol(" matchgroup=logtalkOpenEntityDirTag end=")\." contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkEntityRel,logtalkLineComment +syn region logtalkOpenEntityDir matchgroup=logtalkOpenEntityDirTag start=":- category(" matchgroup=logtalkOpenEntityDirTag end=")\." contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkEntityRel,logtalkLineComment + + +" Logtalk closing entity directives + +syn match logtalkCloseEntityDir ":- end_object\." +syn match logtalkCloseEntityDir ":- end_protocol\." +syn match logtalkCloseEntityDir ":- end_category\." + + +" Logtalk entity relations + +syn region logtalkEntityRel matchgroup=logtalkEntityRelTag start="instantiates(" matchgroup=logtalkEntityRelTag end=")" contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkString,logtalkAtom contained +syn region logtalkEntityRel matchgroup=logtalkEntityRelTag start="specializes(" matchgroup=logtalkEntityRelTag end=")" contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkString,logtalkAtom contained +syn region logtalkEntityRel matchgroup=logtalkEntityRelTag start="extends(" matchgroup=logtalkEntityRelTag end=")" contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkString,logtalkAtom contained +syn region logtalkEntityRel matchgroup=logtalkEntityRelTag start="imports(" matchgroup=logtalkEntityRelTag end=")" contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkString,logtalkAtom contained +syn region logtalkEntityRel matchgroup=logtalkEntityRelTag start="implements(" matchgroup=logtalkEntityRelTag end=")" contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkString,logtalkAtom contained +syn region logtalkEntityRel matchgroup=logtalkEntityRelTag start="complements(" matchgroup=logtalkEntityRelTag end=")" contains=logtalkEntity,logtalkVariable,logtalkNumber,logtalkOperator,logtalkString,logtalkAtom contained + + +" Logtalk directives + +syn region logtalkDir matchgroup=logtalkDirTag start=":- if(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- elif(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn match logtalkDirTag ":- else\." +syn match logtalkDirTag ":- endif\." +syn region logtalkDir matchgroup=logtalkDirTag start=":- alias(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- calls(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- coinductive(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- encoding(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- initialization(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- info(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- mode(" matchgroup=logtalkDirTag end=")\." contains=logtalkOperator, logtalkAtom +syn region logtalkDir matchgroup=logtalkDirTag start=":- dynamic(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn match logtalkDirTag ":- dynamic\." +syn region logtalkDir matchgroup=logtalkDirTag start=":- discontiguous(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- multifile(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- public(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- protected(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- private(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- meta_predicate(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- meta_non_terminal(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- op(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- set_logtalk_flag(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- synchronized(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn match logtalkDirTag ":- synchronized\." +syn region logtalkDir matchgroup=logtalkDirTag start=":- uses(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn match logtalkDirTag ":- threaded\." + + +" Prolog directives + +syn region logtalkDir matchgroup=logtalkDirTag start=":- ensure_loaded(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- include(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- set_prolog_flag(" matchgroup=logtalkDirTag end=")\." contains=ALL + + +" Module directives + +syn region logtalkDir matchgroup=logtalkDirTag start=":- module(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- export(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- reexport(" matchgroup=logtalkDirTag end=")\." contains=ALL +syn region logtalkDir matchgroup=logtalkDirTag start=":- use_module(" matchgroup=logtalkDirTag end=")\." contains=ALL + + +" Logtalk built-in predicates + +syn match logtalkBuiltIn "\<\(abolish\|c\(reate\|urrent\)\)_\(object\|protocol\|category\)\ze(" + +syn match logtalkBuiltIn "\<\(object\|protocol\|category\)_property\ze(" + +syn match logtalkBuiltIn "\" +syn match logtalkKeyword "\" +syn match logtalkKeyword "\" +syn match logtalkOperator "->" +syn match logtalkKeyword "\" +syn match logtalkOperator "@>=" + + +" Term creation and decomposition + +syn match logtalkKeyword "\" + + +" Arithemtic comparison + +syn match logtalkOperator "=:=" +syn match logtalkOperator "=\\=" +syn match logtalkOperator "<" +syn match logtalkOperator "=<" +syn match logtalkOperator ">" +syn match logtalkOperator ">=" + + +" Stream selection and control + +syn match logtalkKeyword "\<\(curren\|se\)t_\(in\|out\)put\ze(" +syn match logtalkKeyword "\" +syn match logtalkKeyword "\" +syn match logtalkKeyword "\" + + +" Term input/output + +syn match logtalkKeyword "\" + + +" Atomic term processing + +syn match logtalkKeyword "\" + + +" Sorting + +syn match logtalkKeyword "\<\(key\)\?sort\ze(" + + +" Evaluable functors + +syn match logtalkOperator "+" +syn match logtalkOperator "-" +syn match logtalkOperator "\*" +syn match logtalkOperator "//" +syn match logtalkOperator "/" +syn match logtalkKeyword "\" +syn match logtalkKeyword "\" +syn match logtalkKeyword "\" +syn match logtalkKeyword "\" +syn match logtalkKeyword "\>" +syn match logtalkOperator "<<" +syn match logtalkOperator "/\\" +syn match logtalkOperator "\\/" +syn match logtalkOperator "\\" + + +" Logtalk list operator + +syn match logtalkOperator "|" + + +" Logtalk existential quantifier operator + +syn match logtalkOperator "\^" + + +" Logtalk numbers + +syn match logtalkNumber "\<\d\+\>" +syn match logtalkNumber "\<\d\+\.\d\+\>" +syn match logtalkNumber "\<\d\+[eE][-+]\=\d\+\>" +syn match logtalkNumber "\<\d\+\.\d\+[eE][-+]\=\d\+\>" +syn match logtalkNumber "\<0'.\|0''\|0'\"\>" +syn match logtalkNumber "\<0b[0-1]\+\>" +syn match logtalkNumber "\<0o\o\+\>" +syn match logtalkNumber "\<0x\x\+\>" + + +" Logtalk end-of-clause + +syn match logtalkOperator "\." + + +" Logtalk comments + +syn region logtalkBlockComment start="/\*" end="\*/" fold +syn match logtalkLineComment "%.*" + +syn cluster logtalkComment contains=logtalkBlockComment,logtalkLineComment + + +" Logtalk conditional compilation folding + +syn region logtalkIfContainer transparent keepend extend start=":- if(" end=":- endif\." containedin=ALLBUT,@logtalkComment contains=NONE +syn region logtalkIf transparent fold keepend start=":- if(" end=":- \(else\.\|elif(\)"ms=s-1,me=s-1 contained containedin=logtalkIfContainer nextgroup=logtalkElseIf,logtalkElse contains=TOP +syn region logtalkElseIf transparent fold keepend start=":- elif(" end=":- \(else\.\|elif(\)"ms=s-1,me=s-1 contained containedin=logtalkIfContainer nextgroup=logtalkElseIf,logtalkElse contains=TOP +syn region logtalkElse transparent fold keepend start=":- else\." end=":- endif\." contained containedin=logtalkIfContainer contains=TOP + + + +" Logtalk entity folding + +syn region logtalkEntity transparent fold keepend start=":- object(" end=":- end_object\." contains=ALL +syn region logtalkEntity transparent fold keepend start=":- protocol(" end=":- end_protocol\." contains=ALL +syn region logtalkEntity transparent fold keepend start=":- category(" end=":- end_category\." contains=ALL + + +syn sync ccomment logtalkBlockComment maxlines=50 + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link logtalkBlockComment Comment +hi def link logtalkLineComment Comment + +hi def link logtalkOpenEntityDir Normal +hi def link logtalkOpenEntityDirTag PreProc + +hi def link logtalkIfContainer PreProc +hi def link logtalkIf PreProc +hi def link logtalkElseIf PreProc +hi def link logtalkElse PreProc + +hi def link logtalkEntity Normal + +hi def link logtalkEntityRel Normal +hi def link logtalkEntityRelTag PreProc + +hi def link logtalkCloseEntityDir PreProc + +hi def link logtalkDir Normal +hi def link logtalkDirTag PreProc + +hi def link logtalkAtom String +hi def link logtalkString String +hi def link logtalkEscapeSequence SpecialChar + +hi def link logtalkNumber Number + +hi def link logtalkKeyword Keyword + +hi def link logtalkBuiltIn Keyword +hi def link logtalkBuiltInMethod Keyword + +hi def link logtalkOperator Operator + +hi def link logtalkExtCall Normal +hi def link logtalkExtCallTag Operator + +hi def link logtalkVariable Identifier + + + +let b:current_syntax = "logtalk" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/lotos.vim b/syntax/lotos.vim new file mode 100644 index 0000000..4838c2d --- /dev/null +++ b/syntax/lotos.vim @@ -0,0 +1,73 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: LOTOS (Language Of Temporal Ordering Specifications, IS8807) +" Maintainer: Daniel Amyot +" Last Change: Wed Aug 19 1998 +" URL: http://lotos.csi.uottawa.ca/~damyot/vim/lotos.vim +" This file is an adaptation of pascal.vim by Mario Eusebio +" I'm not sure I understand all of the syntax highlight language, +" but this file seems to do the job for standard LOTOS. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +"Comments in LOTOS are between (* and *) +syn region lotosComment start="(\*" end="\*)" contains=lotosTodo + +"Operators [], [...], >>, ->, |||, |[...]|, ||, ;, !, ?, :, =, ,, := +syn match lotosDelimiter "[][]" +syn match lotosDelimiter ">>" +syn match lotosDelimiter "->" +syn match lotosDelimiter "\[>" +syn match lotosDelimiter "[|;!?:=,]" + +"Regular keywords +syn keyword lotosStatement specification endspec process endproc +syn keyword lotosStatement where behaviour behavior +syn keyword lotosStatement any let par accept choice hide of in +syn keyword lotosStatement i stop exit noexit + +"Operators from the Abstract Data Types in IS8807 +syn keyword lotosOperator eq ne succ and or xor implies iff +syn keyword lotosOperator not true false +syn keyword lotosOperator Insert Remove IsIn NotIn Union Ints +syn keyword lotosOperator Minus Includes IsSubsetOf +syn keyword lotosOperator lt le ge gt 0 + +"Sorts in IS8807 +syn keyword lotosSort Boolean Bool FBoolean FBool Element +syn keyword lotosSort Set String NaturalNumber Nat HexString +syn keyword lotosSort HexDigit DecString DecDigit +syn keyword lotosSort OctString OctDigit BitString Bit +syn keyword lotosSort Octet OctetString + +"Keywords for ADTs +syn keyword lotosType type endtype library endlib sorts formalsorts +syn keyword lotosType eqns formaleqns opns formalopns forall ofsort is +syn keyword lotosType for renamedby actualizedby sortnames opnnames +syn keyword lotosType using + +syn sync lines=250 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link lotosStatement Statement +hi def link lotosProcess Label +hi def link lotosOperator Operator +hi def link lotosSort Function +hi def link lotosType Type +hi def link lotosComment Comment +hi def link lotosDelimiter String + + +let b:current_syntax = "lotos" + +" vim: ts=8 + +endif diff --git a/syntax/lout.vim b/syntax/lout.vim new file mode 100644 index 0000000..28916f0 --- /dev/null +++ b/syntax/lout.vim @@ -0,0 +1,139 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Lout +" Maintainer: Christian V. J. Brüssow +" Last Change: So 12 Feb 2012 15:15:03 CET +" Filenames: *.lout,*.lt +" URL: http://www.cvjb.de/comp/vim/lout.vim + +" $Id: lout.vim,v 1.4 2012/02/12 15:16:17 bruessow Exp $ +" +" Lout: Basser Lout document formatting system. + +" Many Thanks to... +" +" 2012-02-12: +" Thilo Six send a patch for cpoptions. +" See the discussion at http://thread.gmane.org/gmane.editors.vim.devel/32151 + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save=&cpo +set cpo&vim + +" Lout is case sensitive +syn case match + +" Synchronization, I know it is a huge number, but normal texts can be +" _very_ long ;-) +syn sync lines=1000 + +" Characters allowed in keywords +" I don't know if 128-255 are allowed in ANS-FORHT +setlocal iskeyword=@,48-57,.,@-@,_,192-255 + +" Some special keywords +syn keyword loutTodo contained TODO lout Lout LOUT +syn keyword loutDefine def macro + +" Some big structures +syn keyword loutKeyword @Begin @End @Figure @Tab +syn keyword loutKeyword @Book @Doc @Document @Report +syn keyword loutKeyword @Introduction @Abstract @Appendix +syn keyword loutKeyword @Chapter @Section @BeginSections @EndSections + +" All kind of Lout keywords +syn match loutFunction '\<@[^ \t{}]\+\>' + +" Braces -- Don`t edit these lines! +syn match loutMBraces '[{}]' +syn match loutIBraces '[{}]' +syn match loutBBrace '[{}]' +syn match loutBIBraces '[{}]' +syn match loutHeads '[{}]' + +" Unmatched braces. +syn match loutBraceError '}' + +" End of multi-line definitions, like @Document, @Report and @Book. +syn match loutEOmlDef '^//$' + +" Grouping of parameters and objects. +syn region loutObject transparent matchgroup=Delimiter start='{' matchgroup=Delimiter end='}' contains=ALLBUT,loutBraceError + +" The NULL object has a special meaning +syn keyword loutNULL {} + +" Comments +syn region loutComment start='\#' end='$' contains=loutTodo + +" Double quotes +syn region loutSpecial start=+"+ skip=+\\\\\|\\"+ end=+"+ + +" ISO-LATIN-1 characters created with @Char, or Adobe symbols +" created with @Sym +syn match loutSymbols '@\(\(Char\)\|\(Sym\)\)\s\+[A-Za-z]\+' + +" Include files +syn match loutInclude '@IncludeGraphic\s\+\k\+' +syn region loutInclude start='@\(\(SysInclude\)\|\(IncludeGraphic\)\|\(Include\)\)\s*{' end='}' + +" Tags +syn match loutTag '@\(\(Tag\)\|\(PageMark\)\|\(PageOf\)\|\(NumberOf\)\)\s\+\k\+' +syn region loutTag start='@Tag\s*{' end='}' + +" Equations +syn match loutMath '@Eq\s\+\k\+' +syn region loutMath matchgroup=loutMBraces start='@Eq\s*{' matchgroup=loutMBraces end='}' contains=ALLBUT,loutBraceError +" +" Fonts +syn match loutItalic '@I\s\+\k\+' +syn region loutItalic matchgroup=loutIBraces start='@I\s*{' matchgroup=loutIBraces end='}' contains=ALLBUT,loutBraceError +syn match loutBold '@B\s\+\k\+' +syn region loutBold matchgroup=loutBBraces start='@B\s*{' matchgroup=loutBBraces end='}' contains=ALLBUT,loutBraceError +syn match loutBoldItalic '@BI\s\+\k\+' +syn region loutBoldItalic matchgroup=loutBIBraces start='@BI\s*{' matchgroup=loutBIBraces end='}' contains=ALLBUT,loutBraceError +syn region loutHeadings matchgroup=loutHeads start='@\(\(Title\)\|\(Caption\)\)\s*{' matchgroup=loutHeads end='}' contains=ALLBUT,loutBraceError + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overrriden later. +hi def link loutTodo Todo +hi def link loutDefine Define +hi def link loutEOmlDef Define +hi def link loutFunction Function +hi def link loutBraceError Error +hi def link loutNULL Special +hi def link loutComment Comment +hi def link loutSpecial Special +hi def link loutSymbols Character +hi def link loutInclude Include +hi def link loutKeyword Keyword +hi def link loutTag Tag +hi def link loutMath Number + +hi def link loutMBraces loutMath +hi loutItalic term=italic cterm=italic gui=italic +hi def link loutIBraces loutItalic +hi loutBold term=bold cterm=bold gui=bold +hi def link loutBBraces loutBold +hi loutBoldItalic term=bold,italic cterm=bold,italic gui=bold,italic +hi def link loutBIBraces loutBoldItalic +hi loutHeadings term=bold cterm=bold guifg=indianred +hi def link loutHeads loutHeadings + + +let b:current_syntax = "lout" + +let &cpo=s:cpo_save +unlet s:cpo_save + +" vim:ts=8:sw=4:nocindent:smartindent: + +endif diff --git a/syntax/lpc.vim b/syntax/lpc.vim new file mode 100644 index 0000000..b5f018a --- /dev/null +++ b/syntax/lpc.vim @@ -0,0 +1,451 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: LPC +" Maintainer: Shizhu Pan +" URL: http://poet.tomud.com/pub/lpc.vim.bz2 +" Last Change: 2016 Aug 31 +" Comments: If you are using Vim 6.2 or later, see :h lpc.vim for +" file type recognizing, if not, you had to use modeline. + + +" Nodule: This is the start nodule. {{{1 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Nodule: Keywords {{{1 + +" LPC keywords +" keywords should always be highlighted so "contained" is not used. +syn cluster lpcKeywdGrp contains=lpcConditional,lpcLabel,lpcOperator,lpcRepeat,lpcStatement,lpcModifier,lpcReserved + +syn keyword lpcConditional if else switch +syn keyword lpcLabel case default +syn keyword lpcOperator catch efun in inherit +syn keyword lpcRepeat do for foreach while +syn keyword lpcStatement break continue return + +syn match lpcEfunError /efun[^:]/ display + +" Illegal to use keyword as function +" It's not working, maybe in the next version. +syn keyword lpcKeywdError contained if for foreach return switch while + +" These are keywords only because they take lvalue or type as parameter, +" so these keywords should only be used as function but cannot be names of +" user-defined functions. +syn keyword lpcKeywdFunc new parse_command sscanf time_expression + +" Nodule: Type and modifiers {{{1 + +" Type names list. + +" Special types +syn keyword lpcType void mixed unknown +" Scalar/Value types. +syn keyword lpcType int float string +" Pointer types. +syn keyword lpcType array buffer class function mapping object +" Other types. +if exists("lpc_compat_32") + syn keyword lpcType closure status funcall +else + syn keyword lpcError closure status + syn keyword lpcType multiset +endif + +" Type modifier. +syn keyword lpcModifier nomask private public +syn keyword lpcModifier varargs virtual + +" sensible modifiers +if exists("lpc_pre_v22") + syn keyword lpcReserved nosave protected ref + syn keyword lpcModifier static +else + syn keyword lpcError static + syn keyword lpcModifier nosave protected ref +endif + +" Nodule: Applies {{{1 + +" Match a function declaration or function pointer +syn match lpcApplyDecl excludenl /->\h\w*(/me=e-1 contains=lpcApplies transparent display + +" We should note that in func_spec.c the efun definition syntax is so +" complicated that I use such a long regular expression to describe. +syn match lpcLongDecl excludenl /\(\s\|\*\)\h\+\s\h\+(/me=e-1 contains=@lpcEfunGroup,lpcType,@lpcKeywdGrp transparent display + +" this is form for all functions +" ->foo() form had been excluded +syn match lpcFuncDecl excludenl /\h\w*(/me=e-1 contains=lpcApplies,@lpcEfunGroup,lpcKeywdError transparent display + +" The (: :) parenthesis or $() forms a function pointer +syn match lpcFuncName /(:\s*\h\+\s*:)/me=e-1 contains=lpcApplies,@lpcEfunGroup transparent display contained +syn match lpcFuncName /(:\s*\h\+,/ contains=lpcApplies,@lpcEfunGroup transparent display contained +syn match lpcFuncName /\$(\h\+)/ contains=lpcApplies,@lpcEfunGroup transparent display contained + +" Applies list. +" system applies +syn keyword lpcApplies contained __INIT clean_up create destructor heart_beat id init move_or_destruct reset +" interactive +syn keyword lpcApplies contained catch_tell logon net_dead process_input receive_message receive_snoop telnet_suboption terminal_type window_size write_prompt +" master applies +syn keyword lpcApplies contained author_file compile_object connect crash creator_file domain_file epilog error_handler flag get_bb_uid get_root_uid get_save_file_name log_error make_path_absolute object_name preload privs_file retrieve_ed_setup save_ed_setup slow_shutdown +syn keyword lpcApplies contained valid_asm valid_bind valid_compile_to_c valid_database valid_hide valid_link valid_object valid_override valid_read valid_save_binary valid_seteuid valid_shadow valid_socket valid_write +" parsing +syn keyword lpcApplies contained inventory_accessible inventory_visible is_living parse_command_adjectiv_id_list parse_command_adjective_id_list parse_command_all_word parse_command_id_list parse_command_plural_id_list parse_command_prepos_list parse_command_users parse_get_environment parse_get_first_inventory parse_get_next_inventory parser_error_message + + +" Nodule: Efuns {{{1 + +syn cluster lpcEfunGroup contains=lpc_efuns,lpcOldEfuns,lpcNewEfuns,lpcKeywdFunc + +" Compat32 efuns +if exists("lpc_compat_32") + syn keyword lpc_efuns contained closurep heart_beat_info m_delete m_values m_indices query_once_interactive strstr +else + syn match lpcErrFunc /#`\h\w*/ + " Shell compatible first line comment. + syn region lpcCommentFunc start=/^#!/ end=/$/ +endif + +" pre-v22 efuns which are removed in newer versions. +syn keyword lpcOldEfuns contained tail dump_socket_status + +" new efuns after v22 should be added here! +syn keyword lpcNewEfuns contained socket_status + +" LPC efuns list. +" DEBUG efuns Not included. +" New efuns should NOT be added to this list, see v22 efuns above. +" Efuns list {{{2 +syn keyword lpc_efuns contained acos add_action all_inventory all_previous_objects allocate allocate_buffer allocate_mapping apply arrayp asin atan author_stats +syn keyword lpc_efuns contained bind break_string bufferp +syn keyword lpc_efuns contained cache_stats call_other call_out call_out_info call_stack capitalize catch ceil check_memory children classp clear_bit clone_object clonep command commands copy cos cp crc32 crypt ctime +syn keyword lpc_efuns contained db_close db_commit db_connect db_exec db_fetch db_rollback db_status debug_info debugmalloc debug_message deep_inherit_list deep_inventory destruct disable_commands disable_wizard domain_stats dumpallobj dump_file_descriptors dump_prog +syn keyword lpc_efuns contained each ed ed_cmd ed_start enable_commands enable_wizard environment error errorp eval_cost evaluate exec exp explode export_uid external_start +syn keyword lpc_efuns contained fetch_variable file_length file_name file_size filter filter_array filter_mapping find_call_out find_living find_object find_player first_inventory floatp floor flush_messages function_exists function_owner function_profile functionp functions +syn keyword lpc_efuns contained generate_source get_char get_config get_dir geteuid getuid +syn keyword lpc_efuns contained heart_beats +syn keyword lpc_efuns contained id_matrix implode in_edit in_input inherit_list inherits input_to interactive intp +syn keyword lpc_efuns contained keys +syn keyword lpc_efuns contained link living livings load_object localtime log log10 lookat_rotate lower_case lpc_info +syn keyword lpc_efuns contained malloc_check malloc_debug malloc_status map map_array map_delete map_mapping mapp master match_path max_eval_cost member_array memory_info memory_summary message mkdir moncontrol move_object mud_status +syn keyword lpc_efuns contained named_livings network_stats next_bit next_inventory notify_fail nullp +syn keyword lpc_efuns contained objectp objects oldcrypt opcprof origin +syn keyword lpc_efuns contained parse_add_rule parse_add_synonym parse_command parse_dump parse_init parse_my_rules parse_refresh parse_remove parse_sentence pluralize pointerp pow present previous_object printf process_string process_value program_info +syn keyword lpc_efuns contained query_ed_mode query_heart_beat query_host_name query_idle query_ip_name query_ip_number query_ip_port query_load_average query_notify_fail query_privs query_replaced_program query_shadowing query_snoop query_snooping query_verb +syn keyword lpc_efuns contained random read_buffer read_bytes read_file receive reclaim_objects refs regexp reg_assoc reload_object remove_action remove_call_out remove_interactive remove_shadow rename repeat_string replace_program replace_string replaceable reset_eval_cost resolve restore_object restore_variable rm rmdir rotate_x rotate_y rotate_z rusage +syn keyword lpc_efuns contained save_object save_variable say scale set_author set_bit set_eval_limit set_heart_beat set_hide set_light set_living_name set_malloc_mask set_privs set_reset set_this_player set_this_user seteuid shadow shallow_inherit_list shout shutdown sin sizeof snoop socket_accept socket_acquire socket_address socket_bind socket_close socket_connect socket_create socket_error socket_listen socket_release socket_write sort_array sprintf sqrt stat store_variable strcmp stringp strlen strsrch +syn keyword lpc_efuns contained tan tell_object tell_room terminal_colour test_bit this_interactive this_object this_player this_user throw time to_float to_int trace traceprefix translate typeof +syn keyword lpc_efuns contained undefinedp unique_array unique_mapping upper_case uptime userp users +syn keyword lpc_efuns contained values variables virtualp +syn keyword lpc_efuns contained wizardp write write_buffer write_bytes write_file + +" Nodule: Constants {{{1 + +" LPC Constants. +" like keywords, constants are always highlighted, be careful to choose only +" the constants we used to add to this list. +syn keyword lpcConstant __ARCH__ __COMPILER__ __DIR__ __FILE__ __OPTIMIZATION__ __PORT__ __VERSION__ +" Defines in options.h are all predefined in LPC sources surrounding by +" two underscores. Do we need to include all of that? +syn keyword lpcConstant __SAVE_EXTENSION__ __HEARTBEAT_INTERVAL__ +" from the documentation we know that these constants remains only for +" backward compatibility and should not be used any more. +syn keyword lpcConstant HAS_ED HAS_PRINTF HAS_RUSAGE HAS_DEBUG_LEVEL +syn keyword lpcConstant MUD_NAME F__THIS_OBJECT + +" Nodule: Todo for this file. {{{1 + +" TODO : need to check for LPC4 syntax and other series of LPC besides +" v22, b21 and l32, if you had a good idea, contact me at poet@mudbuilder.net +" and I will be appreciated about that. + +" Notes about some FAQ: +" +" About variables : We adopts the same behavior for C because almost all the +" LPC programmers are also C programmers, so we don't need separate settings +" for C and LPC. That is the reason why I don't change variables like +" "c_no_utf"s to "lpc_no_utf"s. +" +" Copy : Some of the following seems to be copied from c.vim but not quite +" the same in details because the syntax for C and LPC is different. +" +" Color scheme : this syntax file had been thouroughly tested to work well +" for all of the dark-backgrounded color schemes Vim has provided officially, +" and it should be quite Ok for all of the bright-backgrounded color schemes, +" of course it works best for the color scheme that I am using, download it +" from http://poet.tomud.com/pub/ps_color.vim.bz2 if you want to try it. +" + +" Nodule: String and Character {{{1 + + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match lpcSpecial display contained "\\\(x\x\+\|\o\{1,3}\|.\|$\)" +if !exists("c_no_utf") + syn match lpcSpecial display contained "\\\(u\x\{4}\|U\x\{8}\)" +endif + +" LPC version of sprintf() format, +syn match lpcFormat display "%\(\d\+\)\=[-+ |=#@:.]*\(\d\+\)\=\('\I\+'\|'\I*\\'\I*'\)\=[OsdicoxXf]" contained +syn match lpcFormat display "%%" contained +syn region lpcString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=lpcSpecial,lpcFormat +" lpcCppString: same as lpcString, but ends at end of line +syn region lpcCppString start=+L\="+ skip=+\\\\\|\\"\|\\$+ excludenl end=+"+ end='$' contains=lpcSpecial,lpcFormat + +" LPC preprocessor for the text formatting short cuts +" Thanks to Dr. Charles E. Campbell +" he suggests the best way to do this. +syn region lpcTextString start=/@\z(\h\w*\)$/ end=/^\z1/ contains=lpcSpecial +syn region lpcArrayString start=/@@\z(\h\w*\)$/ end=/^\z1/ contains=lpcSpecial + +" Character +syn match lpcCharacter "L\='[^\\]'" +syn match lpcCharacter "L'[^']*'" contains=lpcSpecial +syn match lpcSpecialError "L\='\\[^'\"?\\abefnrtv]'" +syn match lpcSpecialCharacter "L\='\\['\"?\\abefnrtv]'" +syn match lpcSpecialCharacter display "L\='\\\o\{1,3}'" +syn match lpcSpecialCharacter display "'\\x\x\{1,2}'" +syn match lpcSpecialCharacter display "L'\\x\x\+'" + +" Nodule: White space {{{1 + +" when wanted, highlight trailing white space +if exists("c_space_errors") + if !exists("c_no_trail_space_error") + syn match lpcSpaceError display excludenl "\s\+$" + endif + if !exists("c_no_tab_space_error") + syn match lpcSpaceError display " \+\t"me=e-1 + endif +endif + +" Nodule: Parenthesis and brackets {{{1 + +" catch errors caused by wrong parenthesis and brackets +syn cluster lpcParenGroup contains=lpcParenError,lpcIncluded,lpcSpecial,lpcCommentSkip,lpcCommentString,lpcComment2String,@lpcCommentGroup,lpcCommentStartError,lpcUserCont,lpcUserLabel,lpcBitField,lpcCommentSkip,lpcOctalZero,lpcCppOut,lpcCppOut2,lpcCppSkip,lpcFormat,lpcNumber,lpcFloat,lpcOctal,lpcOctalError,lpcNumbersCom +syn region lpcParen transparent start='(' end=')' contains=ALLBUT,@lpcParenGroup,lpcCppParen,lpcErrInBracket,lpcCppBracket,lpcCppString,@lpcEfunGroup,lpcApplies,lpcKeywdError +" lpcCppParen: same as lpcParen but ends at end-of-line; used in lpcDefine +syn region lpcCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@lpcParenGroup,lpcErrInBracket,lpcParen,lpcBracket,lpcString,@lpcEfunGroup,lpcApplies,lpcKeywdError +syn match lpcParenError display ")" +syn match lpcParenError display "\]" +" for LPC: +" Here we should consider the array ({ }) parenthesis and mapping ([ ]) +" parenthesis and multiset (< >) parenthesis. +syn match lpcErrInParen display contained "[^^]{"ms=s+1 +syn match lpcErrInParen display contained "\(}\|\]\)[^)]"me=e-1 +syn region lpcBracket transparent start='\[' end=']' contains=ALLBUT,@lpcParenGroup,lpcErrInParen,lpcCppParen,lpcCppBracket,lpcCppString,@lpcEfunGroup,lpcApplies,lpcFuncName,lpcKeywdError +" lpcCppBracket: same as lpcParen but ends at end-of-line; used in lpcDefine +syn region lpcCppBracket transparent start='\[' skip='\\$' excludenl end=']' end='$' contained contains=ALLBUT,@lpcParenGroup,lpcErrInParen,lpcParen,lpcBracket,lpcString,@lpcEfunGroup,lpcApplies,lpcFuncName,lpcKeywdError +syn match lpcErrInBracket display contained "[);{}]" + +" Nodule: Numbers {{{1 + +" integer number, or floating point number without a dot and with "f". +syn case ignore +syn match lpcNumbers display transparent "\<\d\|\.\d" contains=lpcNumber,lpcFloat,lpcOctalError,lpcOctal +" Same, but without octal error (for comments) +syn match lpcNumbersCom display contained transparent "\<\d\|\.\d" contains=lpcNumber,lpcFloat,lpcOctal +syn match lpcNumber display contained "\d\+\(u\=l\{0,2}\|ll\=u\)\>" +" hex number +syn match lpcNumber display contained "0x\x\+\(u\=l\{0,2}\|ll\=u\)\>" +" Flag the first zero of an octal number as something special +syn match lpcOctal display contained "0\o\+\(u\=l\{0,2}\|ll\=u\)\>" contains=lpcOctalZero +syn match lpcOctalZero display contained "\<0" +syn match lpcFloat display contained "\d\+f" +" floating point number, with dot, optional exponent +syn match lpcFloat display contained "\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=" +" floating point number, starting with a dot, optional exponent +syn match lpcFloat display contained "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +" floating point number, without dot, with exponent +syn match lpcFloat display contained "\d\+e[-+]\=\d\+[fl]\=\>" +" flag an octal number with wrong digits +syn match lpcOctalError display contained "0\o*[89]\d*" +syn case match + +" Nodule: Comment string {{{1 + +" lpcCommentGroup allows adding matches for special things in comments +syn keyword lpcTodo contained TODO FIXME XXX +syn cluster lpcCommentGroup contains=lpcTodo + +if exists("c_comment_strings") + " A comment can contain lpcString, lpcCharacter and lpcNumber. + syntax match lpcCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region lpcCommentString contained start=+L\=\\\@" skip="\\$" end="$" end="//"me=s-1 contains=lpcComment,lpcCppString,lpcCharacter,lpcCppParen,lpcParenError,lpcNumbers,lpcCommentError,lpcSpaceError +syn match lpcPreCondit display "^\s*#\s*\(else\|endif\)\>" +if !exists("c_no_if0") + syn region lpcCppOut start="^\s*#\s*if\s\+0\+\>" end=".\|$" contains=lpcCppOut2 + syn region lpcCppOut2 contained start="0" end="^\s*#\s*\(endif\>\|else\>\|elif\>\)" contains=lpcSpaceError,lpcCppSkip + syn region lpcCppSkip contained start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*#\s*endif\>" contains=lpcSpaceError,lpcCppSkip +endif +syn region lpcIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match lpcIncluded display contained "<[^>]*>" +syn match lpcInclude display "^\s*#\s*include\>\s*["<]" contains=lpcIncluded +syn match lpcLineSkip "\\$" +syn cluster lpcPreProcGroup contains=lpcPreCondit,lpcIncluded,lpcInclude,lpcDefine,lpcErrInParen,lpcErrInBracket,lpcUserLabel,lpcSpecial,lpcOctalZero,lpcCppOut,lpcCppOut2,lpcCppSkip,lpcFormat,lpcNumber,lpcFloat,lpcOctal,lpcOctalError,lpcNumbersCom,lpcString,lpcCommentSkip,lpcCommentString,lpcComment2String,@lpcCommentGroup,lpcCommentStartError,lpcParen,lpcBracket,lpcMulti,lpcKeywdError +syn region lpcDefine start="^\s*#\s*\(define\|undef\)\>" skip="\\$" end="$" end="//"me=s-1 contains=ALLBUT,@lpcPreProcGroup + +if exists("lpc_pre_v22") + syn region lpcPreProc start="^\s*#\s*\(pragma\>\|echo\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@lpcPreProcGroup +else + syn region lpcPreProc start="^\s*#\s*\(pragma\>\|echo\>\|warn\>\|error\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@lpcPreProcGroup +endif + +" Nodule: User labels {{{1 + +" Highlight Labels +" User labels in LPC is not allowed, only "case x" and "default" is supported +syn cluster lpcMultiGroup contains=lpcIncluded,lpcSpecial,lpcCommentSkip,lpcCommentString,lpcComment2String,@lpcCommentGroup,lpcCommentStartError,lpcUserCont,lpcUserLabel,lpcBitField,lpcOctalZero,lpcCppOut,lpcCppOut2,lpcCppSkip,lpcFormat,lpcNumber,lpcFloat,lpcOctal,lpcOctalError,lpcNumbersCom,lpcCppParen,lpcCppBracket,lpcCppString,lpcKeywdError +syn region lpcMulti transparent start='\(case\|default\|public\|protected\|private\)' skip='::' end=':' contains=ALLBUT,@lpcMultiGroup + +syn cluster lpcLabelGroup contains=lpcUserLabel +syn match lpcUserCont display "^\s*lpc:$" contains=@lpcLabelGroup + +" Don't want to match anything +syn match lpcUserLabel display "lpc" contained + +" Nodule: Initializations {{{1 + +if exists("c_minlines") + let b:c_minlines = c_minlines +else + if !exists("c_no_if0") + let b:c_minlines = 50 " #if 0 constructs can be long + else + let b:c_minlines = 15 " mostly for () constructs + endif +endif +exec "syn sync ccomment lpcComment minlines=" . b:c_minlines + +" Make sure these options take place since we no longer depend on file type +" plugin for C +setlocal cindent +setlocal fo-=t fo+=croql +setlocal comments=sO:*\ -,mO:*\ \ ,exO:*/,s1:/*,mb:*,ex:*/,:// + +" Win32 can filter files in the browse dialog +if has("gui_win32") && !exists("b:browsefilter") + let b:browsefilter = "LPC Source Files (*.c *.d *.h)\t*.c;*.d;*.h\n" . + \ "LPC Data Files (*.scr *.o *.dat)\t*.scr;*.o;*.dat\n" . + \ "Text Documentation (*.txt)\t*.txt\n" . + \ "All Files (*.*)\t*.*\n" +endif + +" Nodule: Highlight links {{{1 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link lpcModifier lpcStorageClass + +hi def link lpcQuotedFmt lpcFormat +hi def link lpcFormat lpcSpecial +hi def link lpcCppString lpcString " Cpp means + " C Pre-Processor +hi def link lpcCommentL lpcComment +hi def link lpcCommentStart lpcComment +hi def link lpcUserLabel lpcLabel +hi def link lpcSpecialCharacter lpcSpecial +hi def link lpcOctal lpcPreProc +hi def link lpcOctalZero lpcSpecial " LPC will treat octal numbers + " as decimals, programmers should + " be aware of that. +hi def link lpcEfunError lpcError +hi def link lpcKeywdError lpcError +hi def link lpcOctalError lpcError +hi def link lpcParenError lpcError +hi def link lpcErrInParen lpcError +hi def link lpcErrInBracket lpcError +hi def link lpcCommentError lpcError +hi def link lpcCommentStartError lpcError +hi def link lpcSpaceError lpcError +hi def link lpcSpecialError lpcError +hi def link lpcErrFunc lpcError + +if exists("lpc_pre_v22") + hi def link lpcOldEfuns lpc_efuns + hi def link lpcNewEfuns lpcError +else + hi def link lpcOldEfuns lpcReserved + hi def link lpcNewEfuns lpc_efuns +endif +hi def link lpc_efuns lpcFunction + +hi def link lpcReserved lpcPreProc +hi def link lpcTextString lpcString " This should be preprocessors, but +hi def link lpcArrayString lpcPreProc " let's make some difference + " between text and array + +hi def link lpcIncluded lpcString +hi def link lpcCommentString lpcString +hi def link lpcComment2String lpcString +hi def link lpcCommentSkip lpcComment +hi def link lpcCommentFunc lpcComment + +hi def link lpcCppSkip lpcCppOut +hi def link lpcCppOut2 lpcCppOut +hi def link lpcCppOut lpcComment + +" Standard type below +hi def link lpcApplies Special +hi def link lpcCharacter Character +hi def link lpcComment Comment +hi def link lpcConditional Conditional +hi def link lpcConstant Constant +hi def link lpcDefine Macro +hi def link lpcError Error +hi def link lpcFloat Float +hi def link lpcFunction Function +hi def link lpcIdentifier Identifier +hi def link lpcInclude Include +hi def link lpcLabel Label +hi def link lpcNumber Number +hi def link lpcOperator Operator +hi def link lpcPreCondit PreCondit +hi def link lpcPreProc PreProc +hi def link lpcRepeat Repeat +hi def link lpcStatement Statement +hi def link lpcStorageClass StorageClass +hi def link lpcString String +hi def link lpcStructure Structure +hi def link lpcSpecial LineNr +hi def link lpcTodo Todo +hi def link lpcType Type + + +" Nodule: This is the end nodule. {{{1 + +let b:current_syntax = "lpc" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim:ts=8:nosta:sw=2:ai:si: +" vim600:set fdm=marker: }}}1 + +endif diff --git a/syntax/lprolog.vim b/syntax/lprolog.vim new file mode 100644 index 0000000..7baf53e --- /dev/null +++ b/syntax/lprolog.vim @@ -0,0 +1,128 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: LambdaProlog (Teyjus) +" Filenames: *.mod *.sig +" Maintainer: Markus Mottl +" URL: http://www.ocaml.info/vim/syntax/lprolog.vim +" Last Change: 2006 Feb 05 +" 2001 Apr 26 - Upgraded for new Vim version +" 2000 Jun 5 - Initial release + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Lambda Prolog is case sensitive. +syn case match + +syn match lprologBrackErr "\]" +syn match lprologParenErr ")" + +syn cluster lprologContained contains=lprologTodo,lprologModuleName,lprologTypeNames,lprologTypeName + +" Enclosing delimiters +syn region lprologEncl transparent matchgroup=lprologKeyword start="(" matchgroup=lprologKeyword end=")" contains=ALLBUT,@lprologContained,lprologParenErr +syn region lprologEncl transparent matchgroup=lprologKeyword start="\[" matchgroup=lprologKeyword end="\]" contains=ALLBUT,@lprologContained,lprologBrackErr + +" General identifiers +syn match lprologIdentifier "\<\(\w\|[-+*/\\^<>=`'~?@#$&!_]\)*\>" +syn match lprologVariable "\<\(\u\|_\)\(\w\|[-+*/\\^<>=`'~?@#$&!]\)*\>" + +syn match lprologOperator "/" + +" Comments +syn region lprologComment start="/\*" end="\*/" contains=lprologComment,lprologTodo +syn region lprologComment start="%" end="$" contains=lprologTodo +syn keyword lprologTodo contained TODO FIXME XXX + +syn match lprologInteger "\<\d\+\>" +syn match lprologReal "\<\(\d\+\)\=\.\d+\>" +syn region lprologString start=+"+ skip=+\\\\\|\\"+ end=+"+ + +" Clause definitions +syn region lprologClause start="^\w\+" end=":-\|\." + +" Modules +syn region lprologModule matchgroup=lprologKeyword start="^\" matchgroup=lprologKeyword end="\." + +" Types +syn match lprologKeyword "^\" skipwhite nextgroup=lprologTypeNames +syn region lprologTypeNames matchgroup=lprologBraceErr start="\<\w\+\>" matchgroup=lprologKeyword end="\." contained contains=lprologTypeName,lprologOperator +syn match lprologTypeName "\<\w\+\>" contained + +" Keywords +syn keyword lprologKeyword end import accumulate accum_sig +syn keyword lprologKeyword local localkind closed sig +syn keyword lprologKeyword kind exportdef useonly +syn keyword lprologKeyword infixl infixr infix prefix +syn keyword lprologKeyword prefixr postfix postfixl + +syn keyword lprologSpecial pi sigma is true fail halt stop not + +" Operators +syn match lprologSpecial ":-" +syn match lprologSpecial "->" +syn match lprologSpecial "=>" +syn match lprologSpecial "\\" +syn match lprologSpecial "!" + +syn match lprologSpecial "," +syn match lprologSpecial ";" +syn match lprologSpecial "&" + +syn match lprologOperator "+" +syn match lprologOperator "-" +syn match lprologOperator "*" +syn match lprologOperator "\~" +syn match lprologOperator "\^" +syn match lprologOperator "<" +syn match lprologOperator ">" +syn match lprologOperator "=<" +syn match lprologOperator ">=" +syn match lprologOperator "::" +syn match lprologOperator "=" + +syn match lprologOperator "\." +syn match lprologOperator ":" +syn match lprologOperator "|" + +syn match lprologCommentErr "\*/" + +syn sync minlines=50 +syn sync maxlines=500 + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link lprologComment Comment +hi def link lprologTodo Todo + +hi def link lprologKeyword Keyword +hi def link lprologSpecial Special +hi def link lprologOperator Operator +hi def link lprologIdentifier Normal + +hi def link lprologInteger Number +hi def link lprologReal Number +hi def link lprologString String + +hi def link lprologCommentErr Error +hi def link lprologBrackErr Error +hi def link lprologParenErr Error + +hi def link lprologModuleName Special +hi def link lprologTypeName Identifier + +hi def link lprologVariable Keyword +hi def link lprologAtom Normal +hi def link lprologClause Type + + +let b:current_syntax = "lprolog" + +" vim: ts=8 + +endif diff --git a/syntax/lscript.vim b/syntax/lscript.vim new file mode 100644 index 0000000..3c25891 --- /dev/null +++ b/syntax/lscript.vim @@ -0,0 +1,204 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: LotusScript +" Maintainer: Taryn East (taryneast@hotmail.com) +" Last Change: 2003 May 11 + +" This is a rough amalgamation of the visual basic syntax file, and the UltraEdit +" and Textpad syntax highlighters. +" It's not too brilliant given that a) I've never written a syntax.vim file before +" and b) I'm not so crash hot at LotusScript either. If you see any problems +" feel free to email me with them. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" LotusScript is case insensitive +syn case ignore + +" These are Notes thingies that had an equivalent in the vb highlighter +" or I was already familiar with them +syn keyword lscriptStatement ActivateApp As And Base Beep Call Case ChDir ChDrive Class +syn keyword lscriptStatement Const Dim Declare DefCur DefDbl DefInt DefLng DefSng DefStr +syn keyword lscriptStatement DefVar Do Else %Else ElseIf %ElseIf End %End Erase Event Exit +syn keyword lscriptStatement Explicit FileCopy FALSE For ForAll Function Get GoTo GoSub +syn keyword lscriptStatement If %If In Is Kill Let List Lock Loop MkDir +syn keyword lscriptStatement Name Next New NoCase NoPitch Not Nothing NULL +syn keyword lscriptStatement On Option Or PI Pitch Preserve Private Public +syn keyword lscriptStatement Property Public Put +syn keyword lscriptStatement Randomize ReDim Reset Resume Return RmDir +syn keyword lscriptStatement Select SendKeys SetFileAttr Set Static Sub Then To TRUE +syn keyword lscriptStatement Type Unlock Until While WEnd With Write XOr + +syn keyword lscriptDatatype Array Currency Double Integer Long Single String String$ Variant + +syn keyword lscriptNotesType Field Button Navigator +syn keyword lscriptNotesType NotesACL NotesACLEntry NotesAgent NotesDatabase NotesDateRange +syn keyword lscriptNotesType NotesDateTime NotesDbDirectory NotesDocument +syn keyword lscriptNotesType NotesDocumentCollection NotesEmbeddedObject NotesForm +syn keyword lscriptNotesType NotesInternational NotesItem NotesLog NotesName NotesNewsLetter +syn keyword lscriptNotesType NotesMIMEEntry NotesOutline NotesOutlineEntry NotesRegistration +syn keyword lscriptNotesType NotesReplication NotesRichTextItem NotesRichTextParagraphStyle +syn keyword lscriptNotesType NotesRichTextStyle NotesRichTextTab +syn keyword lscriptNotesType NotesSession NotesTimer NotesView NotesViewColumn NotesViewEntry +syn keyword lscriptNotesType NotesViewEntryCollection NotesViewNavigator NotesUIDatabase +syn keyword lscriptNotesType NotesUIDocument NotesUIView NotesUIWorkspace + +syn keyword lscriptNotesConst ACLLEVEL_AUTHOR ACLLEVEL_DEPOSITOR ACLLEVEL_DESIGNER +syn keyword lscriptNotesConst ACLLEVEL_EDITOR ACLLEVEL_MANAGER ACLLEVEL_NOACCESS +syn keyword lscriptNotesConst ACLLEVEL_READER ACLTYPE_MIXED_GROUP ACLTYPE_PERSON +syn keyword lscriptNotesConst ACLTYPE_PERSON_GROUP ACLTYPE_SERVER ACLTYPE_SERVER_GROUP +syn keyword lscriptNotesConst ACLTYPE_UNSPECIFIED ACTIONCD ALIGN_CENTER +syn keyword lscriptNotesConst ALIGN_FULL ALIGN_LEFT ALIGN_NOWRAP ALIGN_RIGHT +syn keyword lscriptNotesConst ASSISTANTINFO ATTACHMENT AUTHORS COLOR_BLACK +syn keyword lscriptNotesConst COLOR_BLUE COLOR_CYAN COLOR_DARK_BLUE COLOR_DARK_CYAN +syn keyword lscriptNotesConst COLOR_DARK_GREEN COLOR_DARK_MAGENTA COLOR_DARK_RED +syn keyword lscriptNotesConst COLOR_DARK_YELLOW COLOR_GRAY COLOR_GREEN COLOR_LIGHT_GRAY +syn keyword lscriptNotesConst COLOR_MAGENTA COLOR_RED COLOR_WHITE COLOR_YELLOW +syn keyword lscriptNotesConst DATABASE DATETIMES DB_REPLICATION_PRIORITY_HIGH +syn keyword lscriptNotesConst DB_REPLICATION_PRIORITY_LOW DB_REPLICATION_PRIORITY_MED +syn keyword lscriptNotesConst DB_REPLICATION_PRIORITY_NOTSET EFFECTS_EMBOSS +syn keyword lscriptNotesConst EFFECTS_EXTRUDE EFFECTS_NONE EFFECTS_SHADOW +syn keyword lscriptNotesConst EFFECTS_SUBSCRIPT EFFECTS_SUPERSCRIPT EMBED_ATTACHMENT +syn keyword lscriptNotesConst EMBED_OBJECT EMBED_OBJECTLINK EMBEDDEDOBJECT ERRORITEM +syn keyword lscriptNotesConst EV_ALARM EV_COMM EV_MAIL EV_MISC EV_REPLICA EV_RESOURCE +syn keyword lscriptNotesConst EV_SECURITY EV_SERVER EV_UNKNOWN EV_UPDATE FONT_COURIER +syn keyword lscriptNotesConst FONT_HELV FONT_ROMAN FORMULA FT_DATABASE FT_DATE_ASC +syn keyword lscriptNotesConst FT_DATE_DES FT_FILESYSTEM FT_FUZZY FT_SCORES FT_STEMS +syn keyword lscriptNotesConst FT_THESAURUS HTML ICON ID_CERTIFIER ID_FLAT +syn keyword lscriptNotesConst ID_HIERARCHICAL LSOBJECT MIME_PART NAMES NOTESLINKS +syn keyword lscriptNotesConst NOTEREFS NOTES_DESKTOP_CLIENT NOTES_FULL_CLIENT +syn keyword lscriptNotesConst NOTES_LIMITED_CLIENT NUMBERS OTHEROBJECT +syn keyword lscriptNotesConst OUTLINE_CLASS_DATABASE OUTLINE_CLASS_DOCUMENT +syn keyword lscriptNotesConst OUTLINE_CLASS_FOLDER OUTLINE_CLASS_FORM +syn keyword lscriptNotesConst OUTLINE_CLASS_FRAMESET OUTLINE_CLASS_NAVIGATOR +syn keyword lscriptNotesConst OUTLINE_CLASS_PAGE OUTLINE_CLASS_UNKNOWN +syn keyword lscriptNotesConst OUTLINE_CLASS_VIEW OUTLINE_OTHER_FOLDERS_TYPE +syn keyword lscriptNotesConst OUTLINE_OTHER_UNKNOWN_TYPE OUTLINE_OTHER_VIEWS_TYPE +syn keyword lscriptNotesConst OUTLINE_TYPE_ACTION OUTLINE_TYPE_NAMEDELEMENT +syn keyword lscriptNotesConst OUTLINE_TYPE_NOTELINK OUTLINE_TYPE_URL PAGINATE_BEFORE +syn keyword lscriptNotesConst PAGINATE_DEFAULT PAGINATE_KEEP_TOGETHER +syn keyword lscriptNotesConst PAGINATE_KEEP_WITH_NEXT PICKLIST_CUSTOM PICKLIST_NAMES +syn keyword lscriptNotesConst PICKLIST_RESOURCES PICKLIST_ROOMS PROMPT_OK PROMPT_OKCANCELCOMBO +syn keyword lscriptNotesConst PROMPT_OKCANCELEDIT PROMPT_OKCANCELEDITCOMBO PROMPT_OKCANCELLIST +syn keyword lscriptNotesConst PROMPT_OKCANCELLISTMULT PROMPT_PASSWORD PROMPT_YESNO +syn keyword lscriptNotesConst PROMPT_YESNOCANCEL QUERYCD READERS REPLICA_CANDIDATE +syn keyword lscriptNotesConst RICHTEXT RULER_ONE_CENTIMETER RULER_ONE_INCH SEV_FAILURE +syn keyword lscriptNotesConst SEV_FATAL SEV_NORMAL SEV_WARNING1 SEV_WARNING2 +syn keyword lscriptNotesConst SIGNATURE SPACING_DOUBLE SPACING_ONE_POINT_50 +syn keyword lscriptNotesConst SPACING_SINGLE STYLE_NO_CHANGE TAB_CENTER TAB_DECIMAL +syn keyword lscriptNotesConst TAB_LEFT TAB_RIGHT TARGET_ALL_DOCS TARGET_ALL_DOCS_IN_VIEW +syn keyword lscriptNotesConst TARGET_NEW_DOCS TARGET_NEW_OR_MODIFIED_DOCS TARGET_NONE +syn keyword lscriptNotesConst TARGET_RUN_ONCE TARGET_SELECTED_DOCS TARGET_UNREAD_DOCS_IN_VIEW +syn keyword lscriptNotesConst TEMPLATE TEMPLATE_CANDIDATE TEXT TRIGGER_AFTER_MAIL_DELIVERY +syn keyword lscriptNotesConst TRIGGER_BEFORE_MAIL_DELIVERY TRIGGER_DOC_PASTED +syn keyword lscriptNotesConst TRIGGER_DOC_UPDATE TRIGGER_MANUAL TRIGGER_NONE +syn keyword lscriptNotesConst TRIGGER_SCHEDULED UNAVAILABLE UNKNOWN USERDATA +syn keyword lscriptNotesConst USERID VC_ALIGN_CENTER VC_ALIGN_LEFT VC_ALIGN_RIGHT +syn keyword lscriptNotesConst VC_ATTR_PARENS VC_ATTR_PUNCTUATED VC_ATTR_PERCENT +syn keyword lscriptNotesConst VC_FMT_ALWAYS VC_FMT_CURRENCY VC_FMT_DATE VC_FMT_DATETIME +syn keyword lscriptNotesConst VC_FMT_FIXED VC_FMT_GENERAL VC_FMT_HM VC_FMT_HMS +syn keyword lscriptNotesConst VC_FMT_MD VC_FMT_NEVER VC_FMT_SCIENTIFIC +syn keyword lscriptNotesConst VC_FMT_SOMETIMES VC_FMT_TIME VC_FMT_TODAYTIME VC_FMT_YM +syn keyword lscriptNotesConst VC_FMT_YMD VC_FMT_Y4M VC_FONT_BOLD VC_FONT_ITALIC +syn keyword lscriptNotesConst VC_FONT_STRIKEOUT VC_FONT_UNDERLINE VC_SEP_COMMA +syn keyword lscriptNotesConst VC_SEP_NEWLINE VC_SEP_SEMICOLON VC_SEP_SPACE +syn keyword lscriptNotesConst VIEWMAPDATA VIEWMAPLAYOUT VW_SPACING_DOUBLE +syn keyword lscriptNotesConst VW_SPACING_ONE_POINT_25 VW_SPACING_ONE_POINT_50 +syn keyword lscriptNotesConst VW_SPACING_ONE_POINT_75 VW_SPACING_SINGLE + +syn keyword lscriptFunction Abs Asc Atn Atn2 ACos ASin +syn keyword lscriptFunction CCur CDat CDbl Chr Chr$ CInt CLng Command Command$ +syn keyword lscriptFunction Cos CSng CStr +syn keyword lscriptFunction CurDir CurDir$ CVar Date Date$ DateNumber DateSerial DateValue +syn keyword lscriptFunction Day Dir Dir$ Environ$ Environ EOF Error Error$ Evaluate Exp +syn keyword lscriptFunction FileAttr FileDateTime FileLen Fix Format Format$ FreeFile +syn keyword lscriptFunction GetFileAttr GetThreadInfo Hex Hex$ Hour +syn keyword lscriptFunction IMESetMode IMEStatus Input Input$ InputB InputB$ +syn keyword lscriptFunction InputBP InputBP$ InputBox InputBox$ InStr InStrB InStrBP InstrC +syn keyword lscriptFunction IsA IsArray IsDate IsElement IsList IsNumeric +syn keyword lscriptFunction IsObject IsResponse IsScalar IsUnknown LCase LCase$ +syn keyword lscriptFunction Left Left$ LeftB LeftB$ LeftC +syn keyword lscriptFunction LeftBP LeftBP$ Len LenB LenBP LenC Loc LOF Log +syn keyword lscriptFunction LSet LTrim LTrim$ MessageBox Mid Mid$ MidB MidB$ MidC +syn keyword lscriptFunction Minute Month Now Oct Oct$ Responses Right Right$ +syn keyword lscriptFunction RightB RightB$ RightBP RightBP$ RightC Round Rnd RSet RTrim RTrim$ +syn keyword lscriptFunction Second Seek Sgn Shell Sin Sleep Space Space$ Spc Sqr Str Str$ +syn keyword lscriptFunction StrConv StrLeft StrleftBack StrRight StrRightBack +syn keyword lscriptFunction StrCompare Tab Tan Time Time$ TimeNumber Timer +syn keyword lscriptFunction TimeValue Trim Trim$ Today TypeName UCase UCase$ +syn keyword lscriptFunction UniversalID Val Weekday Year + +syn keyword lscriptMethods AppendToTextList ArrayAppend ArrayReplace ArrayGetIndex +syn keyword lscriptMethods Append Bind Close +"syn keyword lscriptMethods Contains +syn keyword lscriptMethods CopyToDatabase CopyAllItems Count CurrentDatabase Delete Execute +syn keyword lscriptMethods GetAllDocumentsByKey GetDatabase GetDocumentByKey +syn keyword lscriptMethods GetDocumentByUNID GetFirstDocument GetFirstItem +syn keyword lscriptMethods GetItems GetItemValue GetNthDocument GetView +syn keyword lscriptMethods IsEmpty IsNull %Include Items +syn keyword lscriptMethods Line LBound LoadMsgText Open Print +syn keyword lscriptMethods RaiseEvent ReplaceItemValue Remove RemoveItem Responses +syn keyword lscriptMethods Save Stop UBound UnprocessedDocuments Write + +syn keyword lscriptEvents Compare OnError + +"************************************************************************************* +"These are Notes thingies that I'm not sure how to classify as they had no vb equivalent +" At a wild guess I'd put them as Functions... +" if anyone sees something really out of place... tell me! + +syn keyword lscriptFunction Access Alias Any Bin Bin$ Binary ByVal +syn keyword lscriptFunction CodeLock CodeLockCheck CodeUnlock CreateLock +syn keyword lscriptFunction CurDrive CurDrive$ DataType DestroyLock Eqv +syn keyword lscriptFunction Erl Err Fraction From FromFunction FullTrim +syn keyword lscriptFunction Imp Int Lib Like ListTag LMBCS LSServer Me +syn keyword lscriptFunction Mod MsgDescription MsgText Output Published +syn keyword lscriptFunction Random Read Shared Step UChr UChr$ Uni Unicode +syn keyword lscriptFunction Until Use UseLSX UString UString$ Width Yield + + +syn keyword lscriptTodo contained TODO + +"integer number, or floating point number without a dot. +syn match lscriptNumber "\<\d\+\>" +"floating point number, with dot +syn match lscriptNumber "\<\d\+\.\d*\>" +"floating point number, starting with a dot +syn match lscriptNumber "\.\d\+\>" + +" String and Character constants +syn region lscriptString start=+"+ end=+"+ +syn region lscriptComment start="REM" end="$" contains=lscriptTodo +syn region lscriptComment start="'" end="$" contains=lscriptTodo +syn region lscriptLineNumber start="^\d" end="\s" +syn match lscriptTypeSpecifier "[a-zA-Z0-9][\$%&!#]"ms=s+1 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi lscriptNotesType term=underline ctermfg=DarkGreen guifg=SeaGreen gui=bold + +hi def link lscriptNotesConst lscriptNotesType +hi def link lscriptLineNumber Comment +hi def link lscriptDatatype Type +hi def link lscriptNumber Number +hi def link lscriptError Error +hi def link lscriptStatement Statement +hi def link lscriptString String +hi def link lscriptComment Comment +hi def link lscriptTodo Todo +hi def link lscriptFunction Identifier +hi def link lscriptMethods PreProc +hi def link lscriptEvents Special +hi def link lscriptTypeSpecifier Type + + +let b:current_syntax = "lscript" + +" vim: ts=8 + +endif diff --git a/syntax/lsl.vim b/syntax/lsl.vim new file mode 100644 index 0000000..5fb6331 --- /dev/null +++ b/syntax/lsl.vim @@ -0,0 +1,281 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Linden Scripting Language +" Maintainer: Timo Frenay +" Last Change: 2012 Apr 30 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +" Initializations +syn case match + +" Keywords +syn keyword lslKeyword default do else for if jump return state while + +" Types +syn keyword lslType float integer key list quaternion rotation string vector + +" Labels +syn match lslLabel +@\h\w*+ display + +" Constants +syn keyword lslConstant +\ ACTIVE AGENT AGENT_ALWAYS_RUN AGENT_ATTACHMENTS AGENT_AWAY AGENT_BUSY +\ AGENT_CROUCHING AGENT_FLYING AGENT_IN_AIR AGENT_MOUSELOOK AGENT_ON_OBJECT +\ AGENT_SCRIPTED AGENT_SITTING AGENT_TYPING AGENT_WALKING ALL_SIDES ANIM_ON +\ ATTACH_BACK ATTACH_BELLY ATTACH_CHEST ATTACH_CHIN ATTACH_HEAD +\ ATTACH_HUD_BOTTOM ATTACH_HUD_BOTTOM_LEFT ATTACH_HUD_BOTTOM_RIGHT +\ ATTACH_HUD_CENTER_1 ATTACH_HUD_CENTER_2 ATTACH_HUD_TOP_CENTER +\ ATTACH_HUD_TOP_LEFT ATTACH_HUD_TOP_RIGHT ATTACH_LEAR ATTACH_LEYE ATTACH_LFOOT +\ ATTACH_LHAND ATTACH_LHIP ATTACH_LLARM ATTACH_LLLEG ATTACH_LPEC +\ ATTACH_LSHOULDER ATTACH_LUARM ATTACH_LULEG ATTACH_MOUTH ATTACH_NOSE +\ ATTACH_PELVIS ATTACH_REAR ATTACH_REYE ATTACH_RFOOT ATTACH_RHAND ATTACH_RHIP +\ ATTACH_RLARM ATTACH_RLLEG ATTACH_RPEC ATTACH_RSHOULDER ATTACH_RUARM +\ ATTACH_RULEG CAMERA_ACTIVE CAMERA_BEHINDNESS_ANGLE CAMERA_BEHINDNESS_LAG +\ CAMERA_DISTANCE CAMERA_FOCUS CAMERA_FOCUS_LAG CAMERA_FOCUS_LOCKED +\ CAMERA_FOCUS_OFFSET CAMERA_FOCUS_THRESHOLD CAMERA_PITCH CAMERA_POSITION +\ CAMERA_POSITION_LAG CAMERA_POSITION_LOCKED CAMERA_POSITION_THRESHOLD +\ CHANGED_ALLOWED_DROP CHANGED_COLOR CHANGED_INVENTORY CHANGED_LINK +\ CHANGED_OWNER CHANGED_REGION CHANGED_SCALE CHANGED_SHAPE CHANGED_TELEPORT +\ CHANGED_TEXTURE CLICK_ACTION_BUY CLICK_ACTION_NONE CLICK_ACTION_OPEN +\ CLICK_ACTION_OPEN_MEDIA CLICK_ACTION_PAY CLICK_ACTION_PLAY CLICK_ACTION_SIT +\ CLICK_ACTION_TOUCH CONTROL_BACK CONTROL_DOWN CONTROL_FWD CONTROL_LBUTTON +\ CONTROL_LEFT CONTROL_ML_LBUTTON CONTROL_RIGHT CONTROL_ROT_LEFT +\ CONTROL_ROT_RIGHT CONTROL_UP DATA_BORN DATA_NAME DATA_ONLINE DATA_PAYINFO +\ DATA_RATING DATA_SIM_POS DATA_SIM_RATING DATA_SIM_STATUS DEBUG_CHANNEL +\ DEG_TO_RAD EOF FALSE HTTP_BODY_MAXLENGTH HTTP_BODY_TRUNCATED HTTP_METHOD +\ HTTP_MIMETYPE HTTP_VERIFY_CERT INVENTORY_ALL INVENTORY_ANIMATION +\ INVENTORY_BODYPART INVENTORY_CLOTHING INVENTORY_GESTURE INVENTORY_LANDMARK +\ INVENTORY_NONE INVENTORY_NOTECARD INVENTORY_OBJECT INVENTORY_SCRIPT +\ INVENTORY_SOUND INVENTORY_TEXTURE LAND_LARGE_BRUSH LAND_LEVEL LAND_LOWER +\ LAND_MEDIUM_BRUSH LAND_NOISE LAND_RAISE LAND_REVERT LAND_SMALL_BRUSH +\ LAND_SMOOTH LINK_ALL_CHILDREN LINK_ALL_OTHERS LINK_ROOT LINK_SET LINK_THIS +\ LIST_STAT_GEOMETRIC_MEAN LIST_STAT_MAX LIST_STAT_MEAN LIST_STAT_MEDIAN +\ LIST_STAT_MIN LIST_STAT_NUM_COUNT LIST_STAT_RANGE LIST_STAT_STD_DEV +\ LIST_STAT_SUM LIST_STAT_SUM_SQUARES LOOP MASK_BASE MASK_EVERYONE MASK_GROUP +\ MASK_NEXT MASK_OWNER NULL_KEY OBJECT_CREATOR OBJECT_DESC OBJECT_GROUP +\ OBJECT_NAME OBJECT_OWNER OBJECT_POS OBJECT_ROT OBJECT_UNKNOWN_DETAIL +\ OBJECT_VELOCITY PARCEL_COUNT_GROUP PARCEL_COUNT_OTHER PARCEL_COUNT_OWNER +\ PARCEL_COUNT_SELECTED PARCEL_COUNT_TEMP PARCEL_COUNT_TOTAL PARCEL_DETAILS_AREA +\ PARCEL_DETAILS_DESC PARCEL_DETAILS_GROUP PARCEL_DETAILS_NAME +\ PARCEL_DETAILS_OWNER PARCEL_FLAG_ALLOW_ALL_OBJECT_ENTRY +\ PARCEL_FLAG_ALLOW_CREATE_GROUP_OBJECTS PARCEL_FLAG_ALLOW_CREATE_OBJECTS +\ PARCEL_FLAG_ALLOW_DAMAGE PARCEL_FLAG_ALLOW_FLY +\ PARCEL_FLAG_ALLOW_GROUP_OBJECT_ENTRY PARCEL_FLAG_ALLOW_GROUP_SCRIPTS +\ PARCEL_FLAG_ALLOW_LANDMARK PARCEL_FLAG_ALLOW_SCRIPTS +\ PARCEL_FLAG_ALLOW_TERRAFORM PARCEL_FLAG_LOCAL_SOUND_ONLY +\ PARCEL_FLAG_RESTRICT_PUSHOBJECT PARCEL_FLAG_USE_ACCESS_GROUP +\ PARCEL_FLAG_USE_ACCESS_LIST PARCEL_FLAG_USE_BAN_LIST +\ PARCEL_FLAG_USE_LAND_PASS_LIST PARCEL_MEDIA_COMMAND_AGENT +\ PARCEL_MEDIA_COMMAND_AUTO_ALIGN PARCEL_MEDIA_COMMAND_DESC +\ PARCEL_MEDIA_COMMAND_LOOP PARCEL_MEDIA_COMMAND_LOOP_SET +\ PARCEL_MEDIA_COMMAND_PAUSE PARCEL_MEDIA_COMMAND_PLAY PARCEL_MEDIA_COMMAND_SIZE +\ PARCEL_MEDIA_COMMAND_STOP PARCEL_MEDIA_COMMAND_TEXTURE +\ PARCEL_MEDIA_COMMAND_TIME PARCEL_MEDIA_COMMAND_TYPE +\ PARCEL_MEDIA_COMMAND_UNLOAD PARCEL_MEDIA_COMMAND_URL PASSIVE +\ PAYMENT_INFO_ON_FILE PAYMENT_INFO_USED PAY_DEFAULT PAY_HIDE PERM_ALL PERM_COPY +\ PERM_MODIFY PERM_MOVE PERM_TRANSFER PERMISSION_ATTACH PERMISSION_CHANGE_LINKS +\ PERMISSION_CONTROL_CAMERA PERMISSION_DEBIT PERMISSION_TAKE_CONTROLS +\ PERMISSION_TRACK_CAMERA PERMISSION_TRIGGER_ANIMATION PI PI_BY_TWO PING_PONG +\ PRIM_BUMP_BARK PRIM_BUMP_BLOBS PRIM_BUMP_BRICKS PRIM_BUMP_BRIGHT +\ PRIM_BUMP_CHECKER PRIM_BUMP_CONCRETE PRIM_BUMP_DARK PRIM_BUMP_DISKS +\ PRIM_BUMP_GRAVEL PRIM_BUMP_LARGETILE PRIM_BUMP_NONE PRIM_BUMP_SHINY +\ PRIM_BUMP_SIDING PRIM_BUMP_STONE PRIM_BUMP_STUCCO PRIM_BUMP_SUCTION +\ PRIM_BUMP_TILE PRIM_BUMP_WEAVE PRIM_BUMP_WOOD PRIM_CAST_SHADOWS PRIM_COLOR +\ PRIM_FLEXIBLE PRIM_FULLBRIGHT PRIM_HOLE_CIRCLE PRIM_HOLE_DEFAULT +\ PRIM_HOLE_SQUARE PRIM_HOLE_TRIANGLE PRIM_MATERIAL PRIM_MATERIAL_FLESH +\ PRIM_MATERIAL_GLASS PRIM_MATERIAL_LIGHT PRIM_MATERIAL_METAL +\ PRIM_MATERIAL_PLASTIC PRIM_MATERIAL_RUBBER PRIM_MATERIAL_STONE +\ PRIM_MATERIAL_WOOD PRIM_PHANTOM PRIM_PHYSICS PRIM_POINT_LIGHT PRIM_POSITION +\ PRIM_ROTATION PRIM_SCULPT_TYPE_CYLINDER PRIM_SCULPT_TYPE_PLANE +\ PRIM_SCULPT_TYPE_SPHERE PRIM_SCULPT_TYPE_TORUS PRIM_SHINY_HIGH PRIM_SHINY_LOW +\ PRIM_SHINY_MEDIUM PRIM_SHINY_NONE PRIM_SIZE PRIM_TEMP_ON_REZ PRIM_TEXGEN +\ PRIM_TEXGEN_DEFAULT PRIM_TEXGEN_PLANAR PRIM_TEXTURE PRIM_TYPE PRIM_TYPE_BOX +\ PRIM_TYPE_BOX PRIM_TYPE_CYLINDER PRIM_TYPE_CYLINDER PRIM_TYPE_LEGACY +\ PRIM_TYPE_PRISM PRIM_TYPE_PRISM PRIM_TYPE_RING PRIM_TYPE_SCULPT +\ PRIM_TYPE_SPHERE PRIM_TYPE_SPHERE PRIM_TYPE_TORUS PRIM_TYPE_TORUS +\ PRIM_TYPE_TUBE PRIM_TYPE_TUBE PSYS_PART_BEAM_MASK PSYS_PART_BOUNCE_MASK +\ PSYS_PART_DEAD_MASK PSYS_PART_EMISSIVE_MASK PSYS_PART_END_ALPHA +\ PSYS_PART_END_COLOR PSYS_PART_END_SCALE PSYS_PART_FLAGS +\ PSYS_PART_FOLLOW_SRC_MASK PSYS_PART_FOLLOW_VELOCITY_MASK +\ PSYS_PART_INTERP_COLOR_MASK PSYS_PART_INTERP_SCALE_MASK PSYS_PART_MAX_AGE +\ PSYS_PART_RANDOM_ACCEL_MASK PSYS_PART_RANDOM_VEL_MASK PSYS_PART_START_ALPHA +\ PSYS_PART_START_COLOR PSYS_PART_START_SCALE PSYS_PART_TARGET_LINEAR_MASK +\ PSYS_PART_TARGET_POS_MASK PSYS_PART_TRAIL_MASK PSYS_PART_WIND_MASK +\ PSYS_SRC_ACCEL PSYS_SRC_ANGLE_BEGIN PSYS_SRC_ANGLE_END +\ PSYS_SRC_BURST_PART_COUNT PSYS_SRC_BURST_RADIUS PSYS_SRC_BURST_RATE +\ PSYS_SRC_BURST_SPEED_MAX PSYS_SRC_BURST_SPEED_MIN PSYS_SRC_INNERANGLE +\ PSYS_SRC_MAX_AGE PSYS_SRC_OMEGA PSYS_SRC_OUTERANGLE PSYS_SRC_PATTERN +\ PSYS_SRC_PATTERN_ANGLE PSYS_SRC_PATTERN_ANGLE_CONE +\ PSYS_SRC_PATTERN_ANGLE_CONE_EMPTY PSYS_SRC_PATTERN_DROP +\ PSYS_SRC_PATTERN_EXPLODE PSYS_SRC_TARGET_KEY PSYS_SRC_TEXTURE PUBLIC_CHANNEL +\ RAD_TO_DEG REGION_FLAG_ALLOW_DAMAGE REGION_FLAG_ALLOW_DIRECT_TELEPORT +\ REGION_FLAG_BLOCK_FLY REGION_FLAG_BLOCK_TERRAFORM +\ REGION_FLAG_DISABLE_COLLISIONS REGION_FLAG_DISABLE_PHYSICS +\ REGION_FLAG_FIXED_SUN REGION_FLAG_RESTRICT_PUSHOBJECT REGION_FLAG_SANDBOX +\ REMOTE_DATA_CHANNEL REMOTE_DATA_REPLY REMOTE_DATA_REQUEST REVERSE ROTATE SCALE +\ SCRIPTED SMOOTH SQRT2 STATUS_BLOCK_GRAB STATUS_CAST_SHADOWS STATUS_DIE_AT_EDGE +\ STATUS_PHANTOM STATUS_PHYSICS STATUS_RETURN_AT_EDGE STATUS_ROTATE_X +\ STATUS_ROTATE_Y STATUS_ROTATE_Z STATUS_SANDBOX STRING_TRIM STRING_TRIM_HEAD +\ STRING_TRIM_TAIL TRUE TWO_PI TYPE_FLOAT TYPE_INTEGER TYPE_INVALID TYPE_KEY +\ TYPE_ROTATION TYPE_STRING TYPE_VECTOR VEHICLE_ANGULAR_DEFLECTION_EFFICIENCY +\ VEHICLE_ANGULAR_DEFLECTION_TIMESCALE VEHICLE_ANGULAR_FRICTION_TIMESCALE +\ VEHICLE_ANGULAR_MOTOR_DECAY_TIMESCALE VEHICLE_ANGULAR_MOTOR_DIRECTION +\ VEHICLE_ANGULAR_MOTOR_TIMESCALE VEHICLE_BANKING_EFFICIENCY VEHICLE_BANKING_MIX +\ VEHICLE_BANKING_TIMESCALE VEHICLE_BUOYANCY VEHICLE_FLAG_CAMERA_DECOUPLED +\ VEHICLE_FLAG_HOVER_GLOBAL_HEIGHT VEHICLE_FLAG_HOVER_TERRAIN_ONLY +\ VEHICLE_FLAG_HOVER_UP_ONLY VEHICLE_FLAG_HOVER_WATER_ONLY +\ VEHICLE_FLAG_LIMIT_MOTOR_UP VEHICLE_FLAG_LIMIT_ROLL_ONLY +\ VEHICLE_FLAG_MOUSELOOK_BANK VEHICLE_FLAG_MOUSELOOK_STEER +\ VEHICLE_FLAG_NO_DEFLECTION_UP VEHICLE_HOVER_EFFICIENCY VEHICLE_HOVER_HEIGHT +\ VEHICLE_HOVER_TIMESCALE VEHICLE_LINEAR_DEFLECTION_EFFICIENCY +\ VEHICLE_LINEAR_DEFLECTION_TIMESCALE VEHICLE_LINEAR_FRICTION_TIMESCALE +\ VEHICLE_LINEAR_MOTOR_DECAY_TIMESCALE VEHICLE_LINEAR_MOTOR_TIMESCALE +\ VEHICLE_LINEAR_MOTOR_DIRECTION VEHICLE_LINEAR_MOTOR_OFFSET +\ VEHICLE_REFERENCE_FRAME VEHICLE_TYPE_AIRPLANE VEHICLE_TYPE_BALLOON +\ VEHICLE_TYPE_BOAT VEHICLE_TYPE_CAR VEHICLE_TYPE_NONE VEHICLE_TYPE_SLED +\ VEHICLE_VERTICAL_ATTRACTION_EFFICIENCY VEHICLE_VERTICAL_ATTRACTION_TIMESCALE +\ ZERO_ROTATION ZERO_VECTOR + +" Events +syn keyword lslEvent +\ attach at_rot_target at_target changed collision collision_end collision_start +\ control dataserver email http_response land_collision land_collision_end +\ land_collision_start link_message listen money moving_end moving_start +\ not_at_rot_target no_sensor object_rez on_rez remote_data run_time_permissions +\ sensor state_entry state_exit timer touch touch_end touch_start not_at_target + +" Functions +syn keyword lslFunction +\ llAbs llAcos llAddToLandBanList llAddToLandPassList llAdjustSoundVolume +\ llAllowInventoryDrop llAngleBetween llApplyImpulse llApplyRotationalImpulse +\ llAsin llAtan2 llAttachToAvatar llAvatarOnSitTarget llAxes2Rot llAxisAngle2Rot +\ llBase64ToInteger llBase64ToString llBreakAllLinks llBreakLink llCSV2List +\ llCeil llClearCameraParams llCloseRemoteDataChannel llCloud llCollisionFilter +\ llCollisionSound llCollisionSprite llCos llCreateLink llDeleteSubList +\ llDeleteSubString llDetachFromAvatar llDetectedGrab llDetectedGroup +\ llDetectedKey llDetectedLinkNumber llDetectedName llDetectedOwner +\ llDetectedPos llDetectedRot llDetectedType llDetectedVel llDialog llDie +\ llDumpList2String llEdgeOfWorld llEjectFromLand llEmail llEscapeURL +\ llEuler2Rot llFabs llFloor llForceMouselook llFrand llGetAccel llGetAgentInfo +\ llGetAgentSize llGetAlpha llGetAndResetTime llGetAnimation llGetAnimationList +\ llGetAttached llGetBoundingBox llGetCameraPos llGetCameraRot llGetCenterOfMass +\ llGetColor llGetCreator llGetDate llGetEnergy llGetForce llGetFreeMemory +\ llGetGMTclock llGetGeometricCenter llGetInventoryCreator llGetInventoryKey +\ llGetInventoryName llGetInventoryNumber llGetInventoryPermMask +\ llGetInventoryType llGetKey llGetLandOwnerAt llGetLinkKey llGetLinkName +\ llGetLinkNumber llGetListEntryType llGetListLength llGetLocalPos llGetLocalRot +\ llGetMass llGetNextEmail llGetNotecardLine llGetNumberOfNotecardLines +\ llGetNumberOfPrims llGetNumberOfSides llGetObjectDesc llGetObjectDetails +\ llGetObjectMass llGetObjectName llGetObjectPermMask llGetObjectPrimCount +\ llGetOmega llGetOwner llGetOwnerKey llGetParcelDetails llGetParcelFlags +\ llGetParcelMaxPrims llGetParcelPrimCount llGetParcelPrimOwners +\ llGetPermissions llGetPermissionsKey llGetPos llGetPrimitiveParams +\ llGetRegionCorner llGetRegionFPS llGetRegionFlags llGetRegionName +\ llGetRegionTimeDilation llGetRootPosition llGetRootRotation llGetRot +\ llGetScale llGetScriptName llGetScriptState llGetSimulatorHostname +\ llGetStartParameter llGetStatus llGetSubString llGetSunDirection llGetTexture +\ llGetTextureOffset llGetTextureRot llGetTextureScale llGetTime llGetTimeOfDay +\ llGetTimestamp llGetTorque llGetUnixTime llGetVel llGetWallclock +\ llGiveInventory llGiveInventoryList llGiveMoney llGodLikeRezObject llGround +\ llGroundContour llGroundNormal llGroundRepel llGroundSlope llHTTPRequest +\ llInsertString llInstantMessage llIntegerToBase64 llKey2Name llList2CSV +\ llList2Float llList2Integer llList2Key llList2List llList2ListStrided +\ llList2Rot llList2String llList2Vector llListFindList llListInsertList +\ llListRandomize llListReplaceList llListSort llListStatistics llListen +\ llListenControl llListenRemove llLoadURL llLog llLog10 llLookAt llLoopSound +\ llLoopSoundMaster llLoopSoundSlave llMD5String llMakeExplosion llMakeFire +\ llMakeFountain llMakeSmoke llMapDestination llMessageLinked llMinEventDelay +\ llModPow llModifyLand llMoveToTarget llOffsetTexture llOpenRemoteDataChannel +\ llOverMyLand llOwnerSay llParcelMediaCommandList llParcelMediaQuery +\ llParseString2List llParseStringKeepNulls llParticleSystem llPassCollisions +\ llPassTouches llPlaySound llPlaySoundSlave llPointAt llPow llPreloadSound +\ llPushObject llRefreshPrimURL llRegionSay llReleaseCamera llReleaseControls +\ llRemoteDataReply llRemoteDataSetRegion llRemoteLoadScript +\ llRemoteLoadScriptPin llRemoveFromLandBanList llRemoveFromLandPassList +\ llRemoveInventory llRemoveVehicleFlags llRequestAgentData +\ llRequestInventoryData llRequestPermissions llRequestSimulatorData +\ llResetLandBanList llResetLandPassList llResetOtherScript llResetScript +\ llResetTime llRezAtRoot llRezObject llRot2Angle llRot2Axis llRot2Euler +\ llRot2Fwd llRot2Left llRot2Up llRotBetween llRotLookAt llRotTarget +\ llRotTargetRemove llRotateTexture llRound llSameGroup llSay llScaleTexture +\ llScriptDanger llSendRemoteData llSensor llSensorRemove llSensorRepeat +\ llSetAlpha llSetBuoyancy llSetCameraAtOffset llSetCameraEyeOffset +\ llSetCameraParams llSetClickAction llSetColor llSetDamage llSetForce +\ llSetForceAndTorque llSetHoverHeight llSetInventoryPermMask llSetLinkAlpha +\ llSetLinkColor llSetLinkPrimitiveParams llSetLinkTexture llSetLocalRot +\ llSetObjectDesc llSetObjectName llSetObjectPermMask llSetParcelMusicURL +\ llSetPayPrice llSetPos llSetPrimURL llSetPrimitiveParams +\ llSetRemoteScriptAccessPin llSetRot llSetScale llSetScriptState llSetSitText +\ llSetSoundQueueing llSetSoundRadius llSetStatus llSetText llSetTexture +\ llSetTextureAnim llSetTimerEvent llSetTorque llSetTouchText llSetVehicleFlags +\ llSetVehicleFloatParam llSetVehicleRotationParam llSetVehicleType +\ llSetVehicleVectorParam llShout llSin llSitTarget llSleep llSound +\ llSoundPreload llSqrt llStartAnimation llStopAnimation llStopHover +\ llStopLookAt llStopMoveToTarget llStopPointAt llStopSound llStringLength +\ llStringToBase64 llStringTrim llSubStringIndex llTakeCamera llTakeControls +\ llTan llTarget llTargetOmega llTargetRemove llTeleportAgentHome llToLower +\ llToUpper llTriggerSound llTriggerSoundLimited llUnSit llUnescapeURL llVecDist +\ llVecMag llVecNorm llVolumeDetect llWater llWhisper llWind llXorBase64Strings +\ llXorBase64StringsCorrect + +" Operators +syn match lslOperator +[-!%&*+/<=>^|~]+ display + +" Numbers +syn match lslNumber +-\=\%(\<\d\+\|\%(\<\d\+\)\=\.\d\+\)\%([Ee][-+]\=\d\+\)\=\>\|\<0x\x\+\>+ display + +" Vectors and rotations +syn match lslVectorRot +<[-\t +.0-9A-Za-z_]\+\%(,[-\t +.0-9A-Za-z_]\+\)\{2,3}>+ contains=lslNumber display + +" Vector and rotation properties +syn match lslProperty +\.\@<=[sxyz]\>+ display + +" Strings +syn region lslString start=+"+ skip=+\\.+ end=+"+ contains=lslSpecialChar,@Spell +syn match lslSpecialChar +\\.+ contained display + +" Keys +syn match lslKey +"\x\{8}-\x\{4}-\x\{4}-\x\{4}-\x\{12}"+ display + +" Parentheses, braces and brackets +syn match lslBlock +[][(){}]+ display + +" Typecast operators +syn match lslTypecast +(\%(float\|integer\|key\|list\|quaternion\|rotation\|string\|vector\))+ contains=lslType display + +" Comments +syn match lslComment +//.*+ contains=@Spell + +" Define the default highlighting. +hi def link lslKeyword Keyword +hi def link lslType Type +hi def link lslLabel Label +hi def link lslConstant Constant +hi def link lslEvent PreProc +hi def link lslFunction Function +hi def link lslOperator Operator +hi def link lslNumber Number +hi def link lslVectorRot Special +hi def link lslProperty Identifier +hi def link lslString String +hi def link lslSpecialChar SpecialChar +hi def link lslKey Special +hi def link lslBlock Special +hi def link lslTypecast Operator +hi def link lslComment Comment + +let b:current_syntax = "lsl" + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim: ts=8 + +endif diff --git a/syntax/lss.vim b/syntax/lss.vim new file mode 100644 index 0000000..bf99de2 --- /dev/null +++ b/syntax/lss.vim @@ -0,0 +1,127 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Lynx 2.7.1 style file +" Maintainer: Scott Bigham +" Last Change: 2004 Oct 06 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" This setup is probably atypical for a syntax highlighting file, because +" most of it is not really intended to be overrideable. Instead, the +" highlighting is supposed to correspond to the highlighting specified by +" the .lss file entries themselves; ie. the "bold" keyword should be bold, +" the "red" keyword should be red, and so forth. The exceptions to this +" are comments, of course, and the initial keyword identifying the affected +" element, which will inherit the usual Identifier highlighting. + +syn match lssElement "^[^:]\+" nextgroup=lssMono + +syn match lssMono ":[^:]\+" contained nextgroup=lssFgColor contains=lssReverse,lssUnderline,lssBold,lssStandout + +syn keyword lssBold bold contained +syn keyword lssReverse reverse contained +syn keyword lssUnderline underline contained +syn keyword lssStandout standout contained + +syn match lssFgColor ":[^:]\+" contained nextgroup=lssBgColor contains=lssRedFg,lssBlueFg,lssGreenFg,lssBrownFg,lssMagentaFg,lssCyanFg,lssLightgrayFg,lssGrayFg,lssBrightredFg,lssBrightgreenFg,lssYellowFg,lssBrightblueFg,lssBrightmagentaFg,lssBrightcyanFg + +syn case ignore +syn keyword lssRedFg red contained +syn keyword lssBlueFg blue contained +syn keyword lssGreenFg green contained +syn keyword lssBrownFg brown contained +syn keyword lssMagentaFg magenta contained +syn keyword lssCyanFg cyan contained +syn keyword lssLightgrayFg lightgray contained +syn keyword lssGrayFg gray contained +syn keyword lssBrightredFg brightred contained +syn keyword lssBrightgreenFg brightgreen contained +syn keyword lssYellowFg yellow contained +syn keyword lssBrightblueFg brightblue contained +syn keyword lssBrightmagentaFg brightmagenta contained +syn keyword lssBrightcyanFg brightcyan contained +syn case match + +syn match lssBgColor ":[^:]\+" contained contains=lssRedBg,lssBlueBg,lssGreenBg,lssBrownBg,lssMagentaBg,lssCyanBg,lssLightgrayBg,lssGrayBg,lssBrightredBg,lssBrightgreenBg,lssYellowBg,lssBrightblueBg,lssBrightmagentaBg,lssBrightcyanBg,lssWhiteBg + +syn case ignore +syn keyword lssRedBg red contained +syn keyword lssBlueBg blue contained +syn keyword lssGreenBg green contained +syn keyword lssBrownBg brown contained +syn keyword lssMagentaBg magenta contained +syn keyword lssCyanBg cyan contained +syn keyword lssLightgrayBg lightgray contained +syn keyword lssGrayBg gray contained +syn keyword lssBrightredBg brightred contained +syn keyword lssBrightgreenBg brightgreen contained +syn keyword lssYellowBg yellow contained +syn keyword lssBrightblueBg brightblue contained +syn keyword lssBrightmagentaBg brightmagenta contained +syn keyword lssBrightcyanBg brightcyan contained +syn keyword lssWhiteBg white contained +syn case match + +syn match lssComment "#.*$" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link lssComment Comment +hi def link lssElement Identifier + +hi def lssBold term=bold cterm=bold +hi def lssReverse term=reverse cterm=reverse +hi def lssUnderline term=underline cterm=underline +hi def lssStandout term=standout cterm=standout + +hi def lssRedFg ctermfg=red +hi def lssBlueFg ctermfg=blue +hi def lssGreenFg ctermfg=green +hi def lssBrownFg ctermfg=brown +hi def lssMagentaFg ctermfg=magenta +hi def lssCyanFg ctermfg=cyan +hi def lssGrayFg ctermfg=gray +if $COLORTERM == "rxvt" + " On rxvt's, bright colors are activated by setting the bold attribute. + hi def lssLightgrayFg ctermfg=gray cterm=bold + hi def lssBrightredFg ctermfg=red cterm=bold + hi def lssBrightgreenFg ctermfg=green cterm=bold + hi def lssYellowFg ctermfg=yellow cterm=bold + hi def lssBrightblueFg ctermfg=blue cterm=bold + hi def lssBrightmagentaFg ctermfg=magenta cterm=bold + hi def lssBrightcyanFg ctermfg=cyan cterm=bold +else + hi def lssLightgrayFg ctermfg=lightgray + hi def lssBrightredFg ctermfg=lightred + hi def lssBrightgreenFg ctermfg=lightgreen + hi def lssYellowFg ctermfg=yellow + hi def lssBrightblueFg ctermfg=lightblue + hi def lssBrightmagentaFg ctermfg=lightmagenta + hi def lssBrightcyanFg ctermfg=lightcyan +endif + +hi def lssRedBg ctermbg=red +hi def lssBlueBg ctermbg=blue +hi def lssGreenBg ctermbg=green +hi def lssBrownBg ctermbg=brown +hi def lssMagentaBg ctermbg=magenta +hi def lssCyanBg ctermbg=cyan +hi def lssLightgrayBg ctermbg=lightgray +hi def lssGrayBg ctermbg=gray +hi def lssBrightredBg ctermbg=lightred +hi def lssBrightgreenBg ctermbg=lightgreen +hi def lssYellowBg ctermbg=yellow +hi def lssBrightblueBg ctermbg=lightblue +hi def lssBrightmagentaBg ctermbg=lightmagenta +hi def lssBrightcyanBg ctermbg=lightcyan +hi def lssWhiteBg ctermbg=white ctermfg=black + +let b:current_syntax = "lss" + +" vim: ts=8 + +endif diff --git a/syntax/lua.vim b/syntax/lua.vim index 9ef55e4..3df48ef 100644 --- a/syntax/lua.vim +++ b/syntax/lua.vim @@ -1,3 +1,361 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Lua 4.0, Lua 5.0, Lua 5.1 and Lua 5.2 +" Maintainer: Marcus Aurelius Farias +" First Author: Carlos Augusto Teixeira Mendes +" Last Change: 2012 Aug 12 +" Options: lua_version = 4 or 5 +" lua_subversion = 0 (4.0, 5.0) or 1 (5.1) or 2 (5.2) +" default 5.2 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +if !exists("lua_version") + " Default is lua 5.2 + let lua_version = 5 + let lua_subversion = 2 +elseif !exists("lua_subversion") + " lua_version exists, but lua_subversion doesn't. So, set it to 0 + let lua_subversion = 0 +endif + +syn case match + +" syncing method +syn sync minlines=100 + +" Comments +syn keyword luaTodo contained TODO FIXME XXX +syn match luaComment "--.*$" contains=luaTodo,@Spell +if lua_version == 5 && lua_subversion == 0 + syn region luaComment matchgroup=luaComment start="--\[\[" end="\]\]" contains=luaTodo,luaInnerComment,@Spell + syn region luaInnerComment contained transparent start="\[\[" end="\]\]" +elseif lua_version > 5 || (lua_version == 5 && lua_subversion >= 1) + " Comments in Lua 5.1: --[[ ... ]], [=[ ... ]=], [===[ ... ]===], etc. + syn region luaComment matchgroup=luaComment start="--\[\z(=*\)\[" end="\]\z1\]" contains=luaTodo,@Spell +endif + +" First line may start with #! +syn match luaComment "\%^#!.*" + +" catch errors caused by wrong parenthesis and wrong curly brackets or +" keywords placed outside their respective blocks +syn region luaParen transparent start='(' end=')' contains=ALLBUT,luaParenError,luaTodo,luaSpecial,luaIfThen,luaElseifThen,luaElse,luaThenEnd,luaBlock,luaLoopBlock,luaIn,luaStatement +syn region luaTableBlock transparent matchgroup=luaTable start="{" end="}" contains=ALLBUT,luaBraceError,luaTodo,luaSpecial,luaIfThen,luaElseifThen,luaElse,luaThenEnd,luaBlock,luaLoopBlock,luaIn,luaStatement + +syn match luaParenError ")" +syn match luaBraceError "}" +syn match luaError "\<\%(end\|else\|elseif\|then\|until\|in\)\>" + +" function ... end +syn region luaFunctionBlock transparent matchgroup=luaFunction start="\" end="\" contains=ALLBUT,luaTodo,luaSpecial,luaElseifThen,luaElse,luaThenEnd,luaIn + +" if ... then +syn region luaIfThen transparent matchgroup=luaCond start="\" end="\"me=e-4 contains=ALLBUT,luaTodo,luaSpecial,luaElseifThen,luaElse,luaIn nextgroup=luaThenEnd skipwhite skipempty + +" then ... end +syn region luaThenEnd contained transparent matchgroup=luaCond start="\" end="\" contains=ALLBUT,luaTodo,luaSpecial,luaThenEnd,luaIn + +" elseif ... then +syn region luaElseifThen contained transparent matchgroup=luaCond start="\" end="\" contains=ALLBUT,luaTodo,luaSpecial,luaElseifThen,luaElse,luaThenEnd,luaIn + +" else +syn keyword luaElse contained else + +" do ... end +syn region luaBlock transparent matchgroup=luaStatement start="\" end="\" contains=ALLBUT,luaTodo,luaSpecial,luaElseifThen,luaElse,luaThenEnd,luaIn + +" repeat ... until +syn region luaLoopBlock transparent matchgroup=luaRepeat start="\" end="\" contains=ALLBUT,luaTodo,luaSpecial,luaElseifThen,luaElse,luaThenEnd,luaIn + +" while ... do +syn region luaLoopBlock transparent matchgroup=luaRepeat start="\" end="\"me=e-2 contains=ALLBUT,luaTodo,luaSpecial,luaIfThen,luaElseifThen,luaElse,luaThenEnd,luaIn nextgroup=luaBlock skipwhite skipempty + +" for ... do and for ... in ... do +syn region luaLoopBlock transparent matchgroup=luaRepeat start="\" end="\"me=e-2 contains=ALLBUT,luaTodo,luaSpecial,luaIfThen,luaElseifThen,luaElse,luaThenEnd nextgroup=luaBlock skipwhite skipempty + +syn keyword luaIn contained in + +" other keywords +syn keyword luaStatement return local break +if lua_version > 5 || (lua_version == 5 && lua_subversion >= 2) + syn keyword luaStatement goto + syn match luaLabel "::\I\i*::" +endif +syn keyword luaOperator and or not +syn keyword luaConstant nil +if lua_version > 4 + syn keyword luaConstant true false +endif + +" Strings +if lua_version < 5 + syn match luaSpecial contained "\\[\\abfnrtv\'\"]\|\\[[:digit:]]\{,3}" +elseif lua_version == 5 + if lua_subversion == 0 + syn match luaSpecial contained #\\[\\abfnrtv'"[\]]\|\\[[:digit:]]\{,3}# + syn region luaString2 matchgroup=luaString start=+\[\[+ end=+\]\]+ contains=luaString2,@Spell + else + if lua_subversion == 1 + syn match luaSpecial contained #\\[\\abfnrtv'"]\|\\[[:digit:]]\{,3}# + else " Lua 5.2 + syn match luaSpecial contained #\\[\\abfnrtvz'"]\|\\x[[:xdigit:]]\{2}\|\\[[:digit:]]\{,3}# + endif + syn region luaString2 matchgroup=luaString start="\[\z(=*\)\[" end="\]\z1\]" contains=@Spell + endif +endif +syn region luaString start=+'+ end=+'+ skip=+\\\\\|\\'+ contains=luaSpecial,@Spell +syn region luaString start=+"+ end=+"+ skip=+\\\\\|\\"+ contains=luaSpecial,@Spell + +" integer number +syn match luaNumber "\<\d\+\>" +" floating point number, with dot, optional exponent +syn match luaNumber "\<\d\+\.\d*\%([eE][-+]\=\d\+\)\=\>" +" floating point number, starting with a dot, optional exponent +syn match luaNumber "\.\d\+\%([eE][-+]\=\d\+\)\=\>" +" floating point number, without dot, with exponent +syn match luaNumber "\<\d\+[eE][-+]\=\d\+\>" + +" hex numbers +if lua_version >= 5 + if lua_subversion == 1 + syn match luaNumber "\<0[xX]\x\+\>" + elseif lua_subversion >= 2 + syn match luaNumber "\<0[xX][[:xdigit:].]\+\%([pP][-+]\=\d\+\)\=\>" + endif +endif + +syn keyword luaFunc assert collectgarbage dofile error next +syn keyword luaFunc print rawget rawset tonumber tostring type _VERSION + +if lua_version == 4 + syn keyword luaFunc _ALERT _ERRORMESSAGE gcinfo + syn keyword luaFunc call copytagmethods dostring + syn keyword luaFunc foreach foreachi getglobal getn + syn keyword luaFunc gettagmethod globals newtag + syn keyword luaFunc setglobal settag settagmethod sort + syn keyword luaFunc tag tinsert tremove + syn keyword luaFunc _INPUT _OUTPUT _STDIN _STDOUT _STDERR + syn keyword luaFunc openfile closefile flush seek + syn keyword luaFunc setlocale execute remove rename tmpname + syn keyword luaFunc getenv date clock exit + syn keyword luaFunc readfrom writeto appendto read write + syn keyword luaFunc PI abs sin cos tan asin + syn keyword luaFunc acos atan atan2 ceil floor + syn keyword luaFunc mod frexp ldexp sqrt min max log + syn keyword luaFunc log10 exp deg rad random + syn keyword luaFunc randomseed strlen strsub strlower strupper + syn keyword luaFunc strchar strrep ascii strbyte + syn keyword luaFunc format strfind gsub + syn keyword luaFunc getinfo getlocal setlocal setcallhook setlinehook +elseif lua_version == 5 + syn keyword luaFunc getmetatable setmetatable + syn keyword luaFunc ipairs pairs + syn keyword luaFunc pcall xpcall + syn keyword luaFunc _G loadfile rawequal require + if lua_subversion == 0 + syn keyword luaFunc getfenv setfenv + syn keyword luaFunc loadstring unpack + syn keyword luaFunc gcinfo loadlib LUA_PATH _LOADED _REQUIREDNAME + else + syn keyword luaFunc load select + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + if lua_subversion == 1 + syn keyword luaFunc getfenv setfenv + syn keyword luaFunc loadstring module unpack + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + elseif lua_subversion == 2 + syn keyword luaFunc _ENV rawlen + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + endif + syn match luaFunc /\/ + endif + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + if lua_subversion == 0 + syn match luaFunc /\/ + else + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + endif + if lua_subversion == 0 + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + elseif lua_subversion == 1 + syn match luaFunc /\/ + elseif lua_subversion == 2 + syn match luaFunc /\/ + syn match luaFunc /\/ + endif + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + if lua_subversion == 0 + syn match luaFunc /\/ + syn match luaFunc /\/ + else + if lua_subversion == 1 + syn match luaFunc /\/ + endif + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + endif + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + if lua_subversion == 1 + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + elseif lua_subversion == 2 + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + syn match luaFunc /\/ + endif +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link luaStatement Statement +hi def link luaRepeat Repeat +hi def link luaFor Repeat +hi def link luaString String +hi def link luaString2 String +hi def link luaNumber Number +hi def link luaOperator Operator +hi def link luaIn Operator +hi def link luaConstant Constant +hi def link luaCond Conditional +hi def link luaElse Conditional +hi def link luaFunction Function +hi def link luaComment Comment +hi def link luaTodo Todo +hi def link luaTable Structure +hi def link luaError Error +hi def link luaParenError Error +hi def link luaBraceError Error +hi def link luaSpecial SpecialChar +hi def link luaFunc Identifier +hi def link luaLabel Label + + +let b:current_syntax = "lua" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: et ts=8 sw=2 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'lua') == -1 " Vim syntax file diff --git a/syntax/lynx.vim b/syntax/lynx.vim new file mode 100644 index 0000000..092e2af --- /dev/null +++ b/syntax/lynx.vim @@ -0,0 +1,144 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Lynx configuration file (lynx.cfg) +" Maintainer: Doug Kearns +" Last Change: 2013 Jun 20 + +" Lynx 2.8.7 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match lynxStart "^" transparent skipwhite nextgroup=lynxOption + +syn match lynxComment "\(^\|\s\+\)#.*$" contains=lynxTodo + +syn keyword lynxTodo TODO NOTE FIXME XXX contained + +syn match lynxDelimiter ":" skipwhite nextgroup=lynxBoolean,lynxNumber,lynxNone,lynxRCOption + +syn case ignore +syn keyword lynxBoolean TRUE FALSE ON OFF contained +syn keyword lynxNone NONE contained +syn case match + +syn match lynxNumber "-\=\<\d\+\>" contained + +"{{{ Options +syn case ignore +syn keyword lynxOption ACCEPT_ALL_COOKIES ALERTSECS ALWAYS_RESUBMIT_POSTS + \ ALWAYS_TRUSTED_EXEC ANONFTP_PASSWORD ASSUMED_COLOR + \ ASSUMED_DOC_CHARSET_CHOICE ASSUME_CHARSET ASSUME_LOCAL_CHARSET + \ ASSUME_UNREC_CHARSET AUTO_SESSION AUTO_UNCACHE_DIRLISTS BAD_HTML + \ BIBP_BIBHOST BIBP_GLOBAL_SERVER BLOCK_MULTI_BOOKMARKS BOLD_H1 + \ BOLD_HEADERS BOLD_NAME_ANCHORS BOOKMARK_FILE BROKEN_FTP_EPSV + \ BROKEN_FTP_RETR BZIP2_PATH CASE_SENSITIVE_ALWAYS_ON + \ CASE_SENSITIVE_SEARCHING CHARACTER_SET CHARSETS_DIRECTORY + \ CHARSET_SWITCH_RULES CHECKMAIL CHMOD_PATH COLLAPSE_BR_TAGS COLOR + \ COLOR_STYLE COMPRESS_PATH CONNECT_TIMEOUT COOKIE_ACCEPT_DOMAINS + \ COOKIE_FILE COOKIE_LOOSE_INVALID_DOMAINS + \ COOKIE_QUERY_INVALID_DOMAINS COOKIE_REJECT_DOMAINS COOKIE_SAVE_FILE + \ COOKIE_STRICT_INVALID_DOMAINS COPY_PATH CSO_PROXY CSWING_PATH + \ DEBUGSECS DEFAULT_BOOKMARK_FILE DEFAULT_CACHE_SIZE DEFAULT_COLORS + \ DEFAULT_EDITOR DEFAULT_INDEX_FILE DEFAULT_KEYPAD_MODE + \ DEFAULT_KEYPAD_MODE_IS_NUMBERS_AS_ARROWS DEFAULT_USER_MODE + \ DEFAULT_VIRTUAL_MEMORY_SIZE DELAYSECS DIRED_MENU DIR_LIST_ORDER + \ DIR_LIST_STYLE DISPLAY DISPLAY_CHARSET_CHOICE DOWNLOADER EMACS_KEYS + \ EMACS_KEYS_ALWAYS_ON ENABLE_LYNXRC ENABLE_SCROLLBACK EXTERNAL + \ FILE_EDITOR FILE_SORTING_METHOD FINGER_PROXY FOCUS_WINDOW + \ FORCE_8BIT_TOUPPER FORCE_COOKIE_PROMPT FORCE_EMPTY_HREFLESS_A + \ FORCE_SSL_COOKIES_SECURE FORCE_SSL_PROMPT FORMS_OPTIONS FTP_FORMAT + \ FTP_PASSIVE FTP_PROXY GLOBAL_EXTENSION_MAP GLOBAL_MAILCAP + \ GOPHER_PROXY GOTOBUFFER GZIP_PATH HELPFILE HIDDEN_LINK_MARKER + \ HISTORICAL_COMMENTS HTMLSRC_ATTRNAME_XFORM HTMLSRC_TAGNAME_XFORM + \ HTTPS_PROXY HTTP_PROXY INCLUDE INFLATE_PATH INFOSECS INSTALL_PATH + \ JUMPBUFFER JUMPFILE JUMP_PROMPT JUSTIFY JUSTIFY_MAX_VOID_PERCENT + \ KBLAYOUT KEYBOARD_LAYOUT KEYMAP KEYPAD_MODE + \ LEFTARROW_IN_TEXTFIELD_PROMPT LINEEDIT_MODE LIST_FORMAT + \ LIST_NEWS_DATES LIST_NEWS_NUMBERS LOCALE_CHARSET LOCALHOST_ALIAS + \ LOCAL_DOMAIN LOCAL_EXECUTION_LINKS_ALWAYS_ON + \ LOCAL_EXECUTION_LINKS_ON_BUT_NOT_REMOTE LYNXCGI_DOCUMENT_ROOT + \ LYNXCGI_ENVIRONMENT LYNX_HOST_NAME LYNX_SIG_FILE MAIL_ADRS + \ MAIL_SYSTEM_ERROR_LOGGING MAKE_LINKS_FOR_ALL_IMAGES + \ MAKE_PSEUDO_ALTS_FOR_INLINES MAX_COOKIES_BUFFER MAX_COOKIES_DOMAIN + \ MAX_COOKIES_GLOBAL MESSAGESECS MINIMAL_COMMENTS MKDIR_PATH + \ MULTI_BOOKMARK MULTI_BOOKMARK_SUPPORT MV_PATH NCR_IN_BOOKMARKS + \ NESTED_TABLES NEWSPOST_PROXY NEWSREPLY_PROXY NEWS_CHUNK_SIZE + \ NEWS_MAX_CHUNK NEWS_POSTING NEWS_PROXY NNTPSERVER NNTP_PROXY + \ NONRESTARTING_SIGWINCH NO_DOT_FILES NO_FILE_REFERER + \ NO_FORCED_CORE_DUMP NO_FROM_HEADER NO_ISMAP_IF_USEMAP NO_MARGINS + \ NO_PAUSE NO_PROXY NO_REFERER_HEADER NO_TABLE_CENTER NO_TITLE + \ NUMBER_FIELDS_ON_LEFT NUMBER_LINKS_ON_LEFT OUTGOING_MAIL_CHARSET + \ PARTIAL PARTIAL_THRES PERSISTENT_COOKIES PERSONAL_EXTENSION_MAP + \ PERSONAL_MAILCAP PERSONAL_MAIL_ADDRESS POSITIONABLE_EDITOR + \ PREFERRED_CHARSET PREFERRED_ENCODING PREFERRED_LANGUAGE + \ PREFERRED_MEDIA_TYPES PREPEND_BASE_TO_SOURCE + \ PREPEND_CHARSET_TO_SOURCE PRETTYSRC PRETTYSRC_SPEC + \ PRETTYSRC_VIEW_NO_ANCHOR_NUMBERING PRINTER QUIT_DEFAULT_YES RAW_MODE + \ READ_TIMEOUT REFERER_WITH_QUERY REPLAYSECS REUSE_TEMPFILES + \ RLOGIN_PATH RM_PATH RMDIR_PATH RULE RULESFILE + \ RUN_ALL_EXECUTION_LINKS RUN_EXECUTION_LINKS_LOCAL SAVE_SPACE + \ SCAN_FOR_BURIED_NEWS_REFS SCREEN_SIZE SCROLLBAR SCROLLBAR_ARROW + \ SEEK_FRAG_AREA_IN_CUR SEEK_FRAG_MAP_IN_CUR SELECT_POPUPS + \ SEND_USERAGENT SESSION_FILE SESSION_LIMIT SET_COOKIES SETFONT_PATH + \ SHOW_COLOR SHOW_CURSOR SHOW_DOTFILES SHOW_KB_NAME SHOW_KB_RATE + \ SNEWSPOST_PROXY SNEWSREPLY_PROXY SNEWS_PROXY SOFT_DQUOTES + \ SOURCE_CACHE SOURCE_CACHE_FOR_ABORTED SSL_CERT_FILE STARTFILE + \ STATUS_BUFFER_SIZE STRIP_DOTDOT_URLS SUBSTITUTE_UNDERSCORES + \ SUB_BOOKMARKS SUFFIX SUFFIX_ORDER SYSLOG_REQUESTED_URLS SYSLOG_TEXT + \ SYSTEM_EDITOR SYSTEM_MAIL SYSTEM_MAIL_FLAGS TAGSOUP TAR_PATH + \ TELNET_PATH TEXTFIELDS_NEED_ACTIVATION TIMEOUT TN3270_PATH + \ TOUCH_PATH TRIM_INPUT_FIELDS TRUSTED_EXEC TRUSTED_LYNXCGI + \ UNCOMPRESS_PATH UNDERLINE_LINKS UNZIP_PATH UPLOADER + \ URL_DOMAIN_PREFIXES URL_DOMAIN_SUFFIXES USERAGENT USER_MODE + \ USE_FIXED_RECORDS USE_MOUSE USE_SELECT_POPUPS UUDECODE_PATH + \ VERBOSE_IMAGES VIEWER VISITED_LINKS VI_KEYS VI_KEYS_ALWAYS_ON + \ WAIS_PROXY XHTML_PARSING XLOADIMAGE_COMMAND ZCAT_PATH ZIP_PATH + \ contained nextgroup=lynxDelimiter +syn keyword lynxRCOption accept_all_cookies assume_charset auto_session + \ bookmark_file case_sensitive_searching character_set + \ cookie_accept_domains cookie_file cookie_loose_invalid_domains + \ cookie_query_invalid_domains cookie_reject_domains + \ cookie_strict_invalid_domains dir_list_style display emacs_keys + \ file_editor file_sorting_method force_cookie_prompt force_ssl_prompt + \ ftp_passive kblayout keypad_mode lineedit_mode locale_charset + \ make_links_for_all_images make_pseudo_alts_for_inlines + \ multi_bookmark no_pause personal_mail_address preferred_charset + \ preferred_encoding preferred_language preferred_media_types raw_mode + \ run_all_execution_links run_execution_links_on_local_files scrollbar + \ select_popups send_useragent session_file set_cookies show_color + \ show_cursor show_dotfiles show_kb_rate sub_bookmarks tagsoup + \ underline_links user_mode useragent verbose_images vi_keys + \ visited_links + \ contained nextgroup=lynxDelimiter +syn case match +" }}} + +" cfg2html.pl formatting directives +syn match lynxFormatDir "^\.h\d\s.*$" +syn match lynxFormatDir "^\.\(ex\|nf\)\(\s\+\d\+\)\=$" +syn match lynxFormatDir "^\.fi$" + +hi def link lynxBoolean Boolean +hi def link lynxComment Comment +hi def link lynxDelimiter Special +hi def link lynxFormatDir Special +hi def link lynxNone Constant +hi def link lynxNumber Number +hi def link lynxOption Identifier +hi def link lynxRCOption lynxOption +hi def link lynxTodo Todo + +let b:current_syntax = "lynx" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 fdm=marker: + +endif diff --git a/syntax/m4.vim b/syntax/m4.vim new file mode 100644 index 0000000..4669674 --- /dev/null +++ b/syntax/m4.vim @@ -0,0 +1,64 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: M4 +" Maintainer: Claudio Fleiner (claudio@fleiner.com) +" URL: http://www.fleiner.com/vim/syntax/m4.vim +" Last Change: 2005 Jan 15 + +" This file will highlight user function calls if they use only +" capital letters and have at least one argument (i.e. the '(' +" must be there). Let me know if this is a problem. + +" quit when a syntax file was already loaded +if !exists("main_syntax") + if exists("b:current_syntax") + finish + endif + " we define it here so that included files can test for it + let main_syntax='m4' +endif + +" define the m4 syntax +syn match m4Variable contained "\$\d\+" +syn match m4Special contained "$[@*#]" +syn match m4Comment "\<\(m4_\)\=dnl\>.*" contains=SpellErrors +syn match m4Constants "\<\(m4_\)\=__file__" +syn match m4Constants "\<\(m4_\)\=__line__" +syn keyword m4Constants divnum sysval m4_divnum m4_sysval +syn region m4Paren matchgroup=m4Delimiter start="(" end=")" contained contains=@m4Top +syn region m4Command matchgroup=m4Function start="\<\(m4_\)\=\(define\|defn\|pushdef\)(" end=")" contains=@m4Top +syn region m4Command matchgroup=m4Preproc start="\<\(m4_\)\=\(include\|sinclude\)("he=e-1 end=")" contains=@m4Top +syn region m4Command matchgroup=m4Statement start="\<\(m4_\)\=\(syscmd\|esyscmd\|ifdef\|ifelse\|indir\|builtin\|shift\|errprint\|m4exit\|changecom\|changequote\|changeword\|m4wrap\|debugfile\|divert\|undivert\)("he=e-1 end=")" contains=@m4Top +syn region m4Command matchgroup=m4builtin start="\<\(m4_\)\=\(len\|index\|regexp\|substr\|translit\|patsubst\|format\|incr\|decr\|eval\|maketemp\)("he=e-1 end=")" contains=@m4Top +syn keyword m4Statement divert undivert +syn region m4Command matchgroup=m4Type start="\<\(m4_\)\=\(undefine\|popdef\)("he=e-1 end=")" contains=@m4Top +syn region m4Function matchgroup=m4Type start="\<[_A-Z][_A-Z0-9]*("he=e-1 end=")" contains=@m4Top +syn region m4String start="`" end="'" contained contains=@m4Top,@m4StringContents,SpellErrors +syn cluster m4Top contains=m4Comment,m4Constants,m4Special,m4Variable,m4String,m4Paren,m4Command,m4Statement,m4Function + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link m4Delimiter Delimiter +hi def link m4Comment Comment +hi def link m4Function Function +hi def link m4Keyword Keyword +hi def link m4Special Special +hi def link m4String String +hi def link m4Statement Statement +hi def link m4Preproc PreProc +hi def link m4Type Type +hi def link m4Special Special +hi def link m4Variable Special +hi def link m4Constants Constant +hi def link m4Builtin Statement + +let b:current_syntax = "m4" + +if main_syntax == 'm4' + unlet main_syntax +endif + +" vim: ts=4 + +endif diff --git a/syntax/mail.vim b/syntax/mail.vim new file mode 100644 index 0000000..6c3cd7b --- /dev/null +++ b/syntax/mail.vim @@ -0,0 +1,116 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Mail file +" Previous Maintainer: Felix von Leitner +" Maintainer: GI , where a='gi1242+vim', b='gmail', c='com' +" Last Change: Wed 14 Aug 2013 08:24:52 AM PDT + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" The mail header is recognized starting with a "keyword:" line and ending +" with an empty line or other line that can't be in the header. All lines of +" the header are highlighted. Headers of quoted messages (quoted with >) are +" also highlighted. + +" Syntax clusters +syn cluster mailHeaderFields contains=mailHeaderKey,mailSubject,mailHeaderEmail,@mailLinks +syn cluster mailLinks contains=mailURL,mailEmail +syn cluster mailQuoteExps contains=mailQuoteExp1,mailQuoteExp2,mailQuoteExp3,mailQuoteExp4,mailQuoteExp5,mailQuoteExp6 + +syn case match +" For "From " matching case is required. The "From " is not matched in quoted +" emails +" According to RFC 2822 any printable ASCII character can appear in a field +" name, except ':'. +syn region mailHeader contains=@mailHeaderFields,@NoSpell start="^From .*\d\d\d\d$" skip="^\s" end="\v^[!-9;-~]*([^!-~]|$)"me=s-1 fold +syn match mailHeaderKey contained contains=mailEmail,@NoSpell "^From\s.*\d\d\d\d$" + +" Nothing else depends on case. +syn case ignore + +" Headers in properly quoted (with "> " or ">") emails are matched +syn region mailHeader keepend contains=@mailHeaderFields,@mailQuoteExps,@NoSpell start="^\z(\(> \?\)*\)\v(newsgroups|x-([a-z\-])*|path|xref|message-id|from|((in-)?reply-)?to|b?cc|subject|return-path|received|date|replied):" skip="^\z1\s" end="\v^\z1[!-9;-~]*([^!-~]|$)"me=s-1 end="\v^\z1@!"me=s-1 end="\v^\z1(\> ?)+"me=s-1 fold + +" Usenet headers +syn match mailHeaderKey contained contains=mailHeaderEmail,mailEmail,@NoSpell "\v(^(\> ?)*)@<=(Newsgroups|Followup-To|Message-ID|Supersedes|Control):.*$" + + +syn region mailHeaderKey contained contains=mailHeaderEmail,mailEmail,@mailQuoteExps,@NoSpell start="\v(^(\> ?)*)@<=(to|b?cc):" skip=",$" end="$" +syn match mailHeaderKey contained contains=mailHeaderEmail,mailEmail,@NoSpell "\v(^(\> ?)*)@<=(from|reply-to):.*$" fold +syn match mailHeaderKey contained contains=@NoSpell "\v(^(\> ?)*)@<=date:" +syn match mailSubject contained "\v^subject:.*$" fold +syn match mailSubject contained contains=@NoSpell "\v(^(\> ?)+)@<=subject:.*$" + +" Anything in the header between < and > is an email address +syn match mailHeaderEmail contained contains=@NoSpell "<.\{-}>" + +" Mail Signatures. (Begin with "-- ", end with change in quote level) +syn region mailSignature keepend contains=@mailLinks,@mailQuoteExps start="^--\s$" end="^$" end="^\(> \?\)\+"me=s-1 fold +syn region mailSignature keepend contains=@mailLinks,@mailQuoteExps,@NoSpell start="^\z(\(> \?\)\+\)--\s$" end="^\z1$" end="^\z1\@!"me=s-1 end="^\z1\(> \?\)\+"me=s-1 fold + +" Treat verbatim Text special. +syn region mailVerbatim contains=@NoSpell keepend start="^#v+$" end="^#v-$" fold +syn region mailVerbatim contains=@mailQuoteExps,@NoSpell keepend start="^\z(\(> \?\)\+\)#v+$" end="\z1#v-$" fold + +" URLs start with a known protocol or www,web,w3. +syn match mailURL contains=@NoSpell `\v<(((https?|ftp|gopher)://|(mailto|file|news):)[^' <>"]+|(www|web|w3)[a-z0-9_-]*\.[a-z0-9._-]+\.[^' <>"]+)[a-z0-9/]` +syn match mailEmail contains=@NoSpell "\v[_=a-z\./+0-9-]+\@[a-z0-9._-]+\a{2}" + +" Make sure quote markers in regions (header / signature) have correct color +syn match mailQuoteExp1 contained "\v^(\> ?)" +syn match mailQuoteExp2 contained "\v^(\> ?){2}" +syn match mailQuoteExp3 contained "\v^(\> ?){3}" +syn match mailQuoteExp4 contained "\v^(\> ?){4}" +syn match mailQuoteExp5 contained "\v^(\> ?){5}" +syn match mailQuoteExp6 contained "\v^(\> ?){6}" + +" Even and odd quoted lines. Order is important here! +syn region mailQuoted6 keepend contains=mailVerbatim,mailHeader,@mailLinks,mailSignature,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{5}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold +syn region mailQuoted5 keepend contains=mailQuoted6,mailVerbatim,mailHeader,@mailLinks,mailSignature,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{4}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold +syn region mailQuoted4 keepend contains=mailQuoted5,mailQuoted6,mailVerbatim,mailHeader,@mailLinks,mailSignature,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{3}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold +syn region mailQuoted3 keepend contains=mailQuoted4,mailQuoted5,mailQuoted6,mailVerbatim,mailHeader,@mailLinks,mailSignature,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{2}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold +syn region mailQuoted2 keepend contains=mailQuoted3,mailQuoted4,mailQuoted5,mailQuoted6,mailVerbatim,mailHeader,@mailLinks,mailSignature,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{1}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold +syn region mailQuoted1 keepend contains=mailQuoted2,mailQuoted3,mailQuoted4,mailQuoted5,mailQuoted6,mailVerbatim,mailHeader,@mailLinks,mailSignature,@NoSpell start="^\z([a-z]\+>\|[]|}>]\)" end="^\z1\@!" fold + +" Need to sync on the header. Assume we can do that within 100 lines +if exists("mail_minlines") + exec "syn sync minlines=" . mail_minlines +else + syn sync minlines=100 +endif + +" Define the default highlighting. +hi def link mailVerbatim Special +hi def link mailHeader Statement +hi def link mailHeaderKey Type +hi def link mailSignature PreProc +hi def link mailHeaderEmail mailEmail +hi def link mailEmail Special +hi def link mailURL String +hi def link mailSubject Title +hi def link mailQuoted1 Comment +hi def link mailQuoted3 mailQuoted1 +hi def link mailQuoted5 mailQuoted1 +hi def link mailQuoted2 Identifier +hi def link mailQuoted4 mailQuoted2 +hi def link mailQuoted6 mailQuoted2 +hi def link mailQuoteExp1 mailQuoted1 +hi def link mailQuoteExp2 mailQuoted2 +hi def link mailQuoteExp3 mailQuoted3 +hi def link mailQuoteExp4 mailQuoted4 +hi def link mailQuoteExp5 mailQuoted5 +hi def link mailQuoteExp6 mailQuoted6 + +let b:current_syntax = "mail" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/mailaliases.vim b/syntax/mailaliases.vim new file mode 100644 index 0000000..8da3982 --- /dev/null +++ b/syntax/mailaliases.vim @@ -0,0 +1,75 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: aliases(5) local alias database file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2008-04-14 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword mailaliasesTodo contained TODO FIXME XXX NOTE + +syn region mailaliasesComment display oneline start='^\s*#' end='$' + \ contains=mailaliasesTodo,@Spell + +syn match mailaliasesBegin display '^' + \ nextgroup=mailaliasesName, + \ mailaliasesComment + +syn match mailaliasesName contained '[[:alnum:]\._-]\+' + \ nextgroup=mailaliasesColon + +syn region mailaliasesName contained oneline start=+"+ + \ skip=+\\\\\|\\"+ end=+"+ + \ nextgroup=mailaliasesColon + +syn match mailaliasesColon contained ':' + \ nextgroup=@mailaliasesValue + \ skipwhite skipnl + +syn cluster mailaliasesValue contains=mailaliasesValueAddress, + \ mailaliasesValueFile, + \ mailaliasesValueCommand, + \ mailaliasesValueInclude + +syn match mailaliasesValueAddress contained '[^ \t/|,]\+' + \ nextgroup=mailaliasesValueSep + \ skipwhite skipnl + +syn match mailaliasesValueFile contained '/[^,]*' + \ nextgroup=mailaliasesValueSep + \ skipwhite skipnl + +syn match mailaliasesValueCommand contained '|[^,]*' + \ nextgroup=mailaliasesValueSep + \ skipwhite skipnl + +syn match mailaliasesValueInclude contained ':include:[^,]*' + \ nextgroup=mailaliasesValueSep + \ skipwhite skipnl + +syn match mailaliasesValueSep contained ',' + \ nextgroup=@mailaliasesValue + \ skipwhite skipnl + +hi def link mailaliasesTodo Todo +hi def link mailaliasesComment Comment +hi def link mailaliasesName Identifier +hi def link mailaliasesColon Delimiter +hi def link mailaliasesValueAddress String +hi def link mailaliasesValueFile String +hi def link mailaliasesValueCommand String +hi def link mailaliasesValueInclude PreProc +hi def link mailaliasesValueSep Delimiter + +let b:current_syntax = "mailaliases" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/mailcap.vim b/syntax/mailcap.vim new file mode 100644 index 0000000..3f14f96 --- /dev/null +++ b/syntax/mailcap.vim @@ -0,0 +1,39 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Mailcap configuration file +" Maintainer: Doug Kearns +" Last Change: 2013 Jun 01 + +if exists("b:current_syntax") + finish +endif + +syn match mailcapComment "^#.*" + +syn region mailcapString start=+"+ end=+"+ contains=mailcapSpecial oneline + +syn match mailcapDelimiter "\\\@" +syn match mailcapFieldname "\<\(compose\|composetyped\|print\|edit\|test\|x11-bitmap\|nametemplate\|textualnewlines\|description\|x-\w+\)\>\ze\s*=" +syn match mailcapTypeField "^\(text\|image\|audio\|video\|application\|message\|multipart\|model\|x-[[:graph:]]\+\)\(/\(\*\|[[:graph:]]\+\)\)\=\ze\s*;" +syn case match + +hi def link mailcapComment Comment +hi def link mailcapDelimiter Delimiter +hi def link mailcapFlag Statement +hi def link mailcapFieldname Statement +hi def link mailcapSpecial Identifier +hi def link mailcapTypeField Type +hi def link mailcapString String + +let b:current_syntax = "mailcap" + +" vim: ts=8 + +endif diff --git a/syntax/make.vim b/syntax/make.vim new file mode 100644 index 0000000..ff77296 --- /dev/null +++ b/syntax/make.vim @@ -0,0 +1,134 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Makefile +" Maintainer: Claudio Fleiner +" URL: http://www.fleiner.com/vim/syntax/make.vim +" Last Change: 2015 Feb 28 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + + +" some special characters +syn match makeSpecial "^\s*[@+-]\+" +syn match makeNextLine "\\\n\s*" + +" some directives +syn match makePreCondit "^ *\(ifeq\>\|else\>\|endif\>\|ifneq\>\|ifdef\>\|ifndef\>\)" +syn match makeInclude "^ *[-s]\=include" +syn match makeStatement "^ *vpath" +syn match makeExport "^ *\(export\|unexport\)\>" +syn match makeOverride "^ *override" +hi link makeOverride makeStatement +hi link makeExport makeStatement + +" catch unmatched define/endef keywords. endef only matches it is by itself on a line, possibly followed by a commend +syn region makeDefine start="^\s*define\s" end="^\s*endef\s*\(#.*\)\?$" contains=makeStatement,makeIdent,makePreCondit,makeDefine + +" Microsoft Makefile specials +syn case ignore +syn match makeInclude "^! *include" +syn match makePreCondit "! *\(cmdswitches\|error\|message\|include\|if\|ifdef\|ifndef\|else\|elseif\|else if\|else\s*ifdef\|else\s*ifndef\|endif\|undef\)\>" +syn case match + +" identifiers +syn region makeIdent start="\$(" skip="\\)\|\\\\" end=")" contains=makeStatement,makeIdent,makeSString,makeDString +syn region makeIdent start="\${" skip="\\}\|\\\\" end="}" contains=makeStatement,makeIdent,makeSString,makeDString +syn match makeIdent "\$\$\w*" +syn match makeIdent "\$[^({]" +syn match makeIdent "^ *[^:#= \t]*\s*[:+?!*]="me=e-2 +syn match makeIdent "^ *[^:#= \t]*\s*="me=e-1 +syn match makeIdent "%" + +" Makefile.in variables +syn match makeConfig "@[A-Za-z0-9_]\+@" + +" make targets +" syn match makeSpecTarget "^\.\(SUFFIXES\|PHONY\|DEFAULT\|PRECIOUS\|IGNORE\|SILENT\|EXPORT_ALL_VARIABLES\|KEEP_STATE\|LIBPATTERNS\|NOTPARALLEL\|DELETE_ON_ERROR\|INTERMEDIATE\|POSIX\|SECONDARY\)\>" +syn match makeImplicit "^\.[A-Za-z0-9_./\t -]\+\s*:$"me=e-1 nextgroup=makeSource +syn match makeImplicit "^\.[A-Za-z0-9_./\t -]\+\s*:[^=]"me=e-2 nextgroup=makeSource + +syn region makeTarget transparent matchgroup=makeTarget start="^[~A-Za-z0-9_./$()%-][A-Za-z0-9_./\t $()%-]*:\{1,2}[^:=]"rs=e-1 end=";"re=e-1,me=e-1 end="[^\\]$" keepend contains=makeIdent,makeSpecTarget,makeNextLine,makeComment skipnl nextGroup=makeCommands +syn match makeTarget "^[~A-Za-z0-9_./$()%*@-][A-Za-z0-9_./\t $()%*@-]*::\=\s*$" contains=makeIdent,makeSpecTarget,makeComment skipnl nextgroup=makeCommands,makeCommandError + +syn region makeSpecTarget transparent matchgroup=makeSpecTarget start="^\.\(SUFFIXES\|PHONY\|DEFAULT\|PRECIOUS\|IGNORE\|SILENT\|EXPORT_ALL_VARIABLES\|KEEP_STATE\|LIBPATTERNS\|NOTPARALLEL\|DELETE_ON_ERROR\|INTERMEDIATE\|POSIX\|SECONDARY\)\>\s*:\{1,2}[^:=]"rs=e-1 end="[^\\]$" keepend contains=makeIdent,makeSpecTarget,makeNextLine,makeComment skipnl nextGroup=makeCommands +syn match makeSpecTarget "^\.\(SUFFIXES\|PHONY\|DEFAULT\|PRECIOUS\|IGNORE\|SILENT\|EXPORT_ALL_VARIABLES\|KEEP_STATE\|LIBPATTERNS\|NOTPARALLEL\|DELETE_ON_ERROR\|INTERMEDIATE\|POSIX\|SECONDARY\)\>\s*::\=\s*$" contains=makeIdent,makeComment skipnl nextgroup=makeCommands,makeCommandError + +syn match makeCommandError "^\s\+\S.*" contained +syn region makeCommands start=";"hs=s+1 start="^\t" end="^[^\t#]"me=e-1,re=e-1 end="^$" contained contains=makeCmdNextLine,makeSpecial,makeComment,makeIdent,makePreCondit,makeDefine,makeDString,makeSString nextgroup=makeCommandError +syn match makeCmdNextLine "\\\n."he=e-1 contained + + +" Statements / Functions (GNU make) +syn match makeStatement contained "(\(subst\|abspath\|addprefix\|addsuffix\|and\|basename\|call\|dir\|error\|eval\|filter-out\|filter\|findstring\|firstword\|flavor\|foreach\|if\|info\|join\|lastword\|notdir\|or\|origin\|patsubst\|realpath\|shell\|sort\|strip\|suffix\|value\|warning\|wildcard\|word\|wordlist\|words\)\>"ms=s+1 + +" Comment +if exists("make_microsoft") + syn match makeComment "#.*" contains=@Spell,makeTodo +elseif !exists("make_no_comments") + syn region makeComment start="#" end="^$" end="[^\\]$" keepend contains=@Spell,makeTodo + syn match makeComment "#$" contains=@Spell +endif +syn keyword makeTodo TODO FIXME XXX contained + +" match escaped quotes and any other escaped character +" except for $, as a backslash in front of a $ does +" not make it a standard character, but instead it will +" still act as the beginning of a variable +" The escaped char is not highlightet currently +syn match makeEscapedChar "\\[^$]" + + +syn region makeDString start=+\(\\\)\@ +" URL: https://github.com/jhradilek/vim-syntax +" Last Change: 11 February 2013 +" Description: A syntax file for the Mallard markup language according to +" Mallard 1.0 DRAFT as of 2013-02-11. + +if exists("b:current_syntax") + finish +endif + +do Syntax xml +syn cluster xmlTagHook add=mallardTagName +syn spell toplevel +syn case match + +syn keyword mallardTagName app cite cmd code col colgroup comment contained +syn keyword mallardTagName credit desc em email example figure contained +syn keyword mallardTagName file gui guiseq info input item key contained +syn keyword mallardTagName keyseq license link links list listing contained +syn keyword mallardTagName media name note output p page quote contained +syn keyword mallardTagName revision screen section span steps contained +syn keyword mallardTagName subtitle synopsis sys table tbody td contained +syn keyword mallardTagName terms tfoot thead title tr tree var contained +syn keyword mallardTagName years contained + +syn region mallardComment start="" end=""me=e-10 contains=xmlTag,xmlNamespace,xmlTagName,xmlEndTag,xmlRegion,xmlEntity,@Spell keepend +syn region mallardEmphasis start="" end=""me=e-5 contains=xmlTag,xmlNamespace,xmlTagName,xmlEndTag,xmlRegion,xmlEntity,@Spell keepend +syn region mallardTitle start="" end=""me=e-8 contains=xmlTag,xmlNamespace,xmlTagName,xmlEndTag,xmlRegion,xmlEntity,@Spell keepend + +hi def link mallardComment Comment +hi def link mallardTagName Statement +hi def link mallardTitle Title +hi def mallardEmphasis term=italic cterm=italic gui=italic + +let b:current_syntax = "mallard" + +endif diff --git a/syntax/man.vim b/syntax/man.vim new file mode 100644 index 0000000..cf24d3e --- /dev/null +++ b/syntax/man.vim @@ -0,0 +1,54 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Man page +" Maintainer: SungHyun Nam +" Previous Maintainer: Gautam H. Mudunuri +" Version Info: +" Last Change: 2015 Nov 24 + +" Additional highlighting by Johannes Tanzler : +" * manSubHeading +" * manSynopsis (only for sections 2 and 3) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Get the CTRL-H syntax to handle backspaced text +runtime! syntax/ctrlh.vim + +syn case ignore +syn match manReference "\f\+([1-9][a-z]\=)" +syn match manTitle "^\f\+([0-9]\+[a-z]\=).*" +syn match manSectionHeading "^[a-z][a-z -]*[a-z]$" +syn match manSubHeading "^\s\{3\}[a-z][a-z -]*[a-z]$" +syn match manOptionDesc "^\s*[+-][a-z0-9]\S*" +syn match manLongOptionDesc "^\s*--[a-z0-9-]\S*" +" syn match manHistory "^[a-z].*last change.*$" + +if getline(1) =~ '^[a-zA-Z_]\+([23])' + syntax include @cCode :p:h/c.vim + syn match manCFuncDefinition display "\<\h\w*\>\s*("me=e-1 contained + syn region manSynopsis start="^SYNOPSIS"hs=s+8 end="^\u\+\s*$"me=e-12 keepend contains=manSectionHeading,@cCode,manCFuncDefinition +endif + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link manTitle Title +hi def link manSectionHeading Statement +hi def link manOptionDesc Constant +hi def link manLongOptionDesc Constant +hi def link manReference PreProc +hi def link manSubHeading Function +hi def link manCFuncDefinition Function + + +let b:current_syntax = "man" + +" vim:ts=8 sts=2 sw=2: + +endif diff --git a/syntax/manconf.vim b/syntax/manconf.vim new file mode 100644 index 0000000..03f1b21 --- /dev/null +++ b/syntax/manconf.vim @@ -0,0 +1,121 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: man.conf(5) - man configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword manconfTodo contained TODO FIXME XXX NOTE + +syn region manconfComment display oneline start='^#' end='$' + \ contains=manconfTodo,@Spell + +if !has("win32") && $OSTYPE =~ 'bsd' + syn match manconfBegin display '^' + \ nextgroup=manconfKeyword,manconfSection, + \ manconfComment skipwhite + + syn keyword manconfKeyword contained _build _crunch + \ nextgroup=manconfExtCmd skipwhite + + syn keyword manconfKeyword contained _suffix + \ nextgroup=manconfExt skipwhite + + syn keyword manconfKeyword contained _crunch + + syn keyword manconfKeyword contained _subdir _version _whatdb + \ nextgroup=manconfPaths skipwhite + + syn match manconfExtCmd contained display '\.\S\+' + \ nextgroup=manconfPaths skipwhite + + syn match manconfSection contained '[^#_ \t]\S*' + \ nextgroup=manconfPaths skipwhite + + syn keyword manconfSection contained _default + \ nextgroup=manconfPaths skipwhite + + syn match manconfPaths contained display '\S\+' + \ nextgroup=manconfPaths skipwhite + + syn match manconfExt contained display '\.\S\+' + + hi def link manconfExtCmd Type + hi def link manconfSection Identifier + hi def link manconfPaths String +else + syn match manconfBegin display '^' + \ nextgroup=manconfBoolean,manconfKeyword, + \ manconfDecompress,manconfComment skipwhite + + syn keyword manconfBoolean contained FSSTND FHS NOAUTOPATH NOCACHE + + syn keyword manconfKeyword contained MANBIN + \ nextgroup=manconfPath skipwhite + + syn keyword manconfKeyword contained MANPATH MANPATH_MAP + \ nextgroup=manconfFirstPath skipwhite + + syn keyword manconfKeyword contained APROPOS WHATIS TROFF NROFF JNROFF EQN + \ NEQN JNEQN TBL COL REFER PIC VGRIND GRAP + \ PAGER BROWSER HTMLPAGER CMP CAT COMPRESS + \ DECOMPRESS MANDEFOPTIONS + \ nextgroup=manconfCommand skipwhite + + syn keyword manconfKeyword contained COMPRESS_EXT + \ nextgroup=manconfExt skipwhite + + syn keyword manconfKeyword contained MANSECT + \ nextgroup=manconfManSect skipwhite + + syn match manconfPath contained display '\S\+' + + syn match manconfFirstPath contained display '\S\+' + \ nextgroup=manconfSecondPath skipwhite + + syn match manconfSecondPath contained display '\S\+' + + syn match manconfCommand contained display '\%(/[^/ \t]\+\)\+' + \ nextgroup=manconfCommandOpt skipwhite + + syn match manconfCommandOpt contained display '\S\+' + \ nextgroup=manconfCommandOpt skipwhite + + syn match manconfExt contained display '\.\S\+' + + syn match manconfManSect contained '[^:]\+' nextgroup=manconfManSectSep + + syn match manconfManSectSep contained ':' nextgroup=manconfManSect + + syn match manconfDecompress contained '\.\S\+' + \ nextgroup=manconfCommand skipwhite + + hi def link manconfBoolean Boolean + hi def link manconfPath String + hi def link manconfFirstPath manconfPath + hi def link manconfSecondPath manconfPath + hi def link manconfCommand String + hi def link manconfCommandOpt Special + hi def link manconfManSect Identifier + hi def link manconfManSectSep Delimiter + hi def link manconfDecompress Type +endif + +hi def link manconfTodo Todo +hi def link manconfComment Comment +hi def link manconfKeyword Keyword +hi def link manconfExt Type + +let b:current_syntax = "manconf" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/manual.vim b/syntax/manual.vim new file mode 100644 index 0000000..eb3f6e7 --- /dev/null +++ b/syntax/manual.vim @@ -0,0 +1,33 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax support file +" Maintainer: Bram Moolenaar +" Last Change: 2016 Feb 01 + +" This file is used for ":syntax manual". +" It installs the Syntax autocommands, but no the FileType autocommands. + +if !has("syntax") + finish +endif + +" Load the Syntax autocommands and set the default methods for highlighting. +if !exists("syntax_on") + so :p:h/synload.vim +endif + +let syntax_manual = 1 + +" Overrule the connection between FileType and Syntax autocommands. This sets +" the syntax when the file type is detected, without changing the value. +augroup syntaxset + au! FileType * exe "set syntax=" . &syntax +augroup END + +" If the GUI is already running, may still need to install the FileType menu. +" Don't do it when the 'M' flag is included in 'guioptions'. +if has("menu") && has("gui_running") && !exists("did_install_syntax_menu") && &guioptions !~# 'M' + source $VIMRUNTIME/menu.vim +endif + +endif diff --git a/syntax/maple.vim b/syntax/maple.vim new file mode 100644 index 0000000..ac3b7a0 --- /dev/null +++ b/syntax/maple.vim @@ -0,0 +1,626 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Maple V (based on release 4) +" Maintainer: Charles E. Campbell +" Last Change: Aug 31, 2016 +" Version: 15 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_MAPLE +" +" Package Function Selection: {{{1 +" Because there are a lot of packages, and because of the potential for namespace +" clashes, this version of needs the user to select which, if any, +" package functions should be highlighted. Select your packages and put into your +" <.vimrc> none or more of the lines following let ...=1 lines: +" +" if exists("mvpkg_all") +" ... +" endif +" +" *OR* let mvpkg_all=1 + +" This syntax file contains all the keywords and top-level packages of Maple 9.5 +" but only the contents of packages of Maple V Release 4, and the top-level +" routines of Release 4. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Iskeyword Effects: {{{1 +if !has("patch-7.4.1142") + setl isk=$,48-57,_,a-z,@-Z +else + syn iskeyword $,48-57,_,a-z,@-Z +endif + +" Package Selection: {{{1 +" allow user to simply select all packages for highlighting +if exists("mvpkg_all") + let mv_DEtools = 1 + let mv_Galois = 1 + let mv_GaussInt = 1 + let mv_LREtools = 1 + let mv_combinat = 1 + let mv_combstruct = 1 + let mv_difforms = 1 + let mv_finance = 1 + let mv_genfunc = 1 + let mv_geometry = 1 + let mv_grobner = 1 + let mv_group = 1 + let mv_inttrans = 1 + let mv_liesymm = 1 + let mv_linalg = 1 + let mv_logic = 1 + let mv_networks = 1 + let mv_numapprox = 1 + let mv_numtheory = 1 + let mv_orthopoly = 1 + let mv_padic = 1 + let mv_plots = 1 + let mv_plottools = 1 + let mv_powseries = 1 + let mv_process = 1 + let mv_simplex = 1 + let mv_stats = 1 + let mv_student = 1 + let mv_sumtools = 1 + let mv_tensor = 1 + let mv_totorder = 1 +endif + +" Parenthesis/curly/brace sanity checker: {{{1 +syn case match + +" parenthesis/curly/brace sanity checker +syn region mvZone matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" transparent contains=ALLBUT,mvError,mvBraceError,mvCurlyError +syn region mvZone matchgroup=Delimiter start="{" matchgroup=Delimiter end="}" transparent contains=ALLBUT,mvError,mvBraceError,mvParenError +syn region mvZone matchgroup=Delimiter start="\[" matchgroup=Delimiter end="]" transparent contains=ALLBUT,mvError,mvCurlyError,mvParenError +syn match mvError "[)\]}]" +syn match mvBraceError "[)}]" contained +syn match mvCurlyError "[)\]]" contained +syn match mvParenError "[\]}]" contained +syn match mvComma "[,;:]" +syn match mvSemiError "[;:]" contained +syn match mvDcolon "::" + +" Maple Packages, updated for Maple 9.5 +syn keyword mvPackage algcurves ArrayTools Cache codegen +syn keyword mvPackage CodeGeneration CodeTools combinat combstruct +syn keyword mvPackage ContextMenu CurveFitting DEtools diffalg +syn keyword mvPackage difforms DiscreteTransforms Domains ExternalCalling +syn keyword mvPackage FileTools finance GaussInt genfunc +syn keyword mvPackage geom3d geometry gfun Groebner +syn keyword mvPackage group hashmset IntegerRelations inttrans +syn keyword mvPackage LargeExpressions LibraryTools liesymm linalg +syn keyword mvPackage LinearAlgebra LinearFunctionalSystems LinearOperators +syn keyword mvPackage ListTools Logic LREtools Maplets +syn keyword mvPackage MathematicalFunctions MathML Matlab +syn keyword mvPackage MatrixPolynomialAlgebra MmaTranslator networks +syn keyword mvPackage numapprox numtheory Optimization OreTools +syn keyword mvPackage Ore_algebra OrthogonalSeries orthopoly padic +syn keyword mvPackage PDEtools plots plottools PolynomialIdeals +syn keyword mvPackage PolynomialTools powseries process QDifferenceEquations +syn keyword mvPackage RandomTools RationalNormalForms RealDomain RootFinding +syn keyword mvPackage ScientificConstants ScientificErrorAnalysis simplex +syn keyword mvPackage Slode SNAP Sockets SoftwareMetrics +syn keyword mvPackage SolveTools Spread stats StringTools +syn keyword mvPackage Student student sumtools SumTools +syn keyword mvPackage tensor TypeTools Units VariationalCalculus +syn keyword mvPackage VectorCalculus Worksheet XMLTools + +" Language Support: {{{1 +syn keyword mvTodo contained COMBAK FIXME TODO XXX +if exists("g:mapleversion") && g:mapleversion < 9 + syn region mvString start=+`+ skip=+``+ end=+`+ keepend contains=mvTodo,@Spell + syn region mvString start=+"+ skip=+""+ end=+"+ keepend contains=@Spell + syn region mvDelayEval start=+'+ end=+'+ keepend contains=ALLBUT,mvError,mvBraceError,mvCurlyError,mvParenError,mvSemiError + syn match mvVarAssign "[a-zA-Z_][a-zA-Z_0-9]*[ \t]*:=" contains=mvAssign + syn match mvAssign ":=" contained +else + syn region mvName start=+`+ skip=+``+ end=+`+ keepend contains=mvTodo + syn region mvString start=+"+ skip=+""+ end=+"+ keepend contains=@Spell + syn region mvDelayEval start=+'+ end=+'+ keepend contains=ALLBUT,mvError,mvBraceError,mvCurlyError,mvParenError + syn match mvDelim "[;:]" display + syn match mvAssign ":=" +endif + +" Lower-Priority Operators: {{{1 +syn match mvOper "\." + +" Number handling: {{{1 +syn match mvNumber "\<\d\+" " integer + syn match mvNumber "[-+]\=\.\d\+" " . integer +syn match mvNumber "\<\d\+\.\d\+" " integer . integer +syn match mvNumber "\<\d\+\." " integer . +syn match mvNumber "\<\d\+\.\." contains=mvRange " integer .. + +syn match mvNumber "\<\d\+e[-+]\=\d\+" " integer e [-+] integer +syn match mvNumber "[-+]\=\.\d\+e[-+]\=\d\+" " . integer e [-+] integer +syn match mvNumber "\<\d\+\.\d*e[-+]\=\d\+" " integer . [integer] e [-+] integer + +syn match mvNumber "[-+]\d\+" " integer +syn match mvNumber "[-+]\d\+\.\d\+" " integer . integer +syn match mvNumber "[-+]\d\+\." " integer . +syn match mvNumber "[-+]\d\+\.\." contains=mvRange " integer .. + +syn match mvNumber "[-+]\d\+e[-+]\=\d\+" " integer e [-+] integer +syn match mvNumber "[-+]\d\+\.\d*e[-+]\=\d\+" " integer . [integer] e [-+] integer + +syn match mvRange "\.\." + +" Operators: {{{1 +syn keyword mvOper and not or xor implies union intersect subset minus mod +syn match mvOper "<>\|[<>]=\|[<>]\|=" +syn match mvOper "&+\|&-\|&\*\|&\/\|&" +syn match mvError "\.\.\." + +" MapleV Statements: ? statement {{{1 + +" MapleV Statements: ? statement +" Split into booleans, conditionals, operators, repeat-logic, etc +syn keyword mvBool true false FAIL +syn keyword mvCond elif else fi if then +syn match mvCond "end\s\+if" + +syn keyword mvRepeat by for in to +syn keyword mvRepeat do from od while +syn match mvRepeat "end\s\+do" + +syn keyword mvSpecial NULL +syn match mvSpecial "\[\]\|{}" + +if exists("g:mapleversion") && g:mapleversion < 9 + syn keyword mvStatement Order fail options read save + syn keyword mvStatement break local point remember stop + syn keyword mvStatement done mod proc restart with + syn keyword mvStatement end mods quit return + syn keyword mvStatement error next +else + syn keyword mvStatement option options read save + syn keyword mvStatement break local remember stop + syn keyword mvStatement done mod proc restart + syn keyword mvStatement end mods quit return + syn keyword mvStatement error next try catch + syn keyword mvStatement finally assuming global export + syn keyword mvStatement module description use +endif + +" Builtin Constants: ? constants {{{1 +syn keyword mvConstant Catalan I gamma infinity +syn keyword mvConstant Pi + +" Comments: DEBUG, if in a comment, is specially highlighted. {{{1 +syn keyword mvDebug contained DEBUG +syn cluster mvCommentGroup contains=mvTodo,mvDebug,@Spell +syn match mvComment "#.*$" contains=@mvCommentGroup + +" Basic Library Functions: ? index[function] +syn keyword mvLibrary $ @ @@ ERROR +syn keyword mvLibrary AFactor KelvinHer arctan factor log rhs +syn keyword mvLibrary AFactors KelvinKei arctanh factors log10 root +syn keyword mvLibrary AiryAi KelvinKer argument fclose lprint roots +syn keyword mvLibrary AiryBi LambertW array feof map round +syn keyword mvLibrary AngerJ Lcm assign fflush map2 rsolve +syn keyword mvLibrary Berlekamp LegendreE assigned filepos match savelib +syn keyword mvLibrary BesselI LegendreEc asspar fixdiv matrix scanf +syn keyword mvLibrary BesselJ LegendreEc1 assume float max searchtext +syn keyword mvLibrary BesselK LegendreF asubs floor maximize sec +syn keyword mvLibrary BesselY LegendreKc asympt fnormal maxnorm sech +syn keyword mvLibrary Beta LegendreKc1 attribute fopen maxorder select +syn keyword mvLibrary C LegendrePi bernstein forget member seq +syn keyword mvLibrary Chi LegendrePic branches fortran min series +syn keyword mvLibrary Ci LegendrePic1 bspline fprintf minimize setattribute +syn keyword mvLibrary CompSeq Li cat frac minpoly shake +syn keyword mvLibrary Content Linsolve ceil freeze modp showprofile +syn keyword mvLibrary D MOLS chrem fremove modp1 showtime +syn keyword mvLibrary DESol Maple_floats close frontend modp2 sign +syn keyword mvLibrary Det MeijerG close fscanf modpol signum +syn keyword mvLibrary Diff Norm coeff fsolve mods simplify +syn keyword mvLibrary Dirac Normal coeffs galois msolve sin +syn keyword mvLibrary DistDeg Nullspace coeftayl gc mtaylor singular +syn keyword mvLibrary Divide Power collect gcd mul sinh +syn keyword mvLibrary Ei Powmod combine gcdex nextprime sinterp +syn keyword mvLibrary Eigenvals Prem commutat genpoly nops solve +syn keyword mvLibrary EllipticCE Primfield comparray harmonic norm sort +syn keyword mvLibrary EllipticCK Primitive compoly has normal sparse +syn keyword mvLibrary EllipticCPi Primpart conjugate hasfun numboccur spline +syn keyword mvLibrary EllipticE ProbSplit content hasoption numer split +syn keyword mvLibrary EllipticF Product convergs hastype op splits +syn keyword mvLibrary EllipticK Psi convert heap open sprem +syn keyword mvLibrary EllipticModulus Quo coords history optimize sprintf +syn keyword mvLibrary EllipticNome RESol copy hypergeom order sqrfree +syn keyword mvLibrary EllipticPi Randpoly cos iFFT parse sqrt +syn keyword mvLibrary Eval Randprime cosh icontent pclose sscanf +syn keyword mvLibrary Expand Ratrecon cost identity pclose ssystem +syn keyword mvLibrary FFT Re cot igcd pdesolve stack +syn keyword mvLibrary Factor Rem coth igcdex piecewise sturm +syn keyword mvLibrary Factors Resultant csc ilcm plot sturmseq +syn keyword mvLibrary FresnelC RootOf csch ilog plot3d subs +syn keyword mvLibrary FresnelS Roots csgn ilog10 plotsetup subsop +syn keyword mvLibrary Fresnelf SPrem dawson implicitdiff pochhammer substring +syn keyword mvLibrary Fresnelg Searchtext define indets pointto sum +syn keyword mvLibrary Frobenius Shi degree index poisson surd +syn keyword mvLibrary GAMMA Si denom indexed polar symmdiff +syn keyword mvLibrary GaussAGM Smith depends indices polylog symmetric +syn keyword mvLibrary Gaussejord Sqrfree diagonal inifcn polynom system +syn keyword mvLibrary Gausselim Ssi diff ininame powmod table +syn keyword mvLibrary Gcd StruveH dilog initialize prem tan +syn keyword mvLibrary Gcdex StruveL dinterp insert prevprime tanh +syn keyword mvLibrary HankelH1 Sum disassemble int primpart testeq +syn keyword mvLibrary HankelH2 Svd discont interface print testfloat +syn keyword mvLibrary Heaviside TEXT discrim interp printf thaw +syn keyword mvLibrary Hermite Trace dismantle invfunc procbody thiele +syn keyword mvLibrary Im WeberE divide invztrans procmake time +syn keyword mvLibrary Indep WeierstrassP dsolve iostatus product translate +syn keyword mvLibrary Interp WeierstrassPPrime eliminate iperfpow proot traperror +syn keyword mvLibrary Inverse WeierstrassSigma ellipsoid iquo property trigsubs +syn keyword mvLibrary Irreduc WeierstrassZeta entries iratrecon protect trunc +syn keyword mvLibrary Issimilar Zeta eqn irem psqrt type +syn keyword mvLibrary JacobiAM abs erf iroot quo typematch +syn keyword mvLibrary JacobiCD add erfc irreduc radnormal unames +syn keyword mvLibrary JacobiCN addcoords eulermac iscont radsimp unapply +syn keyword mvLibrary JacobiCS addressof eval isdifferentiable rand unassign +syn keyword mvLibrary JacobiDC algebraic evala isolate randomize unload +syn keyword mvLibrary JacobiDN algsubs evalapply ispoly randpoly unprotect +syn keyword mvLibrary JacobiDS alias evalb isqrfree range updatesR4 +syn keyword mvLibrary JacobiNC allvalues evalc isqrt rationalize userinfo +syn keyword mvLibrary JacobiND anames evalf issqr ratrecon value +syn keyword mvLibrary JacobiNS antisymm evalfint latex readbytes vector +syn keyword mvLibrary JacobiSC applyop evalgf lattice readdata verify +syn keyword mvLibrary JacobiSD arccos evalhf lcm readlib whattype +syn keyword mvLibrary JacobiSN arccosh evalm lcoeff readline with +syn keyword mvLibrary JacobiTheta1 arccot evaln leadterm readstat writebytes +syn keyword mvLibrary JacobiTheta2 arccoth evalr length realroot writedata +syn keyword mvLibrary JacobiTheta3 arccsc exp lexorder recipoly writeline +syn keyword mvLibrary JacobiTheta4 arccsch expand lhs rem writestat +syn keyword mvLibrary JacobiZeta arcsec expandoff limit remove writeto +syn keyword mvLibrary KelvinBei arcsech expandon ln residue zip +syn keyword mvLibrary KelvinBer arcsin extract lnGAMMA resultant ztrans +syn keyword mvLibrary KelvinHei arcsinh + + +" == PACKAGES ======================================================= {{{1 +" Note: highlighting of package functions is now user-selectable by package. + +" Package: DEtools differential equations tools {{{2 +if exists("mv_DEtools") + syn keyword mvPkg_DEtools DEnormal Dchangevar autonomous dfieldplot reduceOrder untranslate + syn keyword mvPkg_DEtools DEplot PDEchangecoords convertAlg indicialeq regularsp varparam + syn keyword mvPkg_DEtools DEplot3d PDEplot convertsys phaseportrait translate +endif + +" Package: Domains: create domains of computation {{{2 +if exists("mv_Domains") +endif + +" Package: GF: Galois Fields {{{2 +if exists("mv_GF") + syn keyword mvPkg_Galois galois +endif + +" Package: GaussInt: Gaussian Integers {{{2 +if exists("mv_GaussInt") + syn keyword mvPkg_GaussInt GIbasis GIfactor GIissqr GInorm GIquadres GIsmith + syn keyword mvPkg_GaussInt GIchrem GIfactors GIlcm GInormal GIquo GIsqrfree + syn keyword mvPkg_GaussInt GIdivisor GIgcd GImcmbine GIorder GIrem GIsqrt + syn keyword mvPkg_GaussInt GIfacpoly GIgcdex GInearest GIphi GIroots GIunitnormal + syn keyword mvPkg_GaussInt GIfacset GIhermite GInodiv GIprime GIsieve +endif + +" Package: LREtools: manipulate linear recurrence relations {{{2 +if exists("mv_LREtools") + syn keyword mvPkg_LREtools REcontent REprimpart REtodelta delta hypergeomsols ratpolysols + syn keyword mvPkg_LREtools REcreate REreduceorder REtoproc dispersion polysols shift + syn keyword mvPkg_LREtools REplot REtoDE constcoeffsol +endif + +" Package: combinat: combinatorial functions {{{2 +if exists("mv_combinat") + syn keyword mvPkg_combinat Chi composition graycode numbcomb permute randperm + syn keyword mvPkg_combinat bell conjpart inttovec numbcomp powerset stirling1 + syn keyword mvPkg_combinat binomial decodepart lastpart numbpart prevpart stirling2 + syn keyword mvPkg_combinat cartprod encodepart multinomial numbperm randcomb subsets + syn keyword mvPkg_combinat character fibonacci nextpart partition randpart vectoint + syn keyword mvPkg_combinat choose firstpart +endif + +" Package: combstruct: combinatorial structures {{{2 +if exists("mv_combstruct") + syn keyword mvPkg_combstruct allstructs draw iterstructs options specification structures + syn keyword mvPkg_combstruct count finished nextstruct +endif + +" Package: difforms: differential forms {{{2 +if exists("mv_difforms") + syn keyword mvPkg_difforms const defform formpart parity scalarpart wdegree + syn keyword mvPkg_difforms d form mixpar scalar simpform wedge +endif + +" Package: finance: financial mathematics {{{2 +if exists("mv_finance") + syn keyword mvPkg_finance amortization cashflows futurevalue growingperpetuity mv_finance presentvalue + syn keyword mvPkg_finance annuity effectiverate growingannuity levelcoupon perpetuity yieldtomaturity + syn keyword mvPkg_finance blackscholes +endif + +" Package: genfunc: rational generating functions {{{2 +if exists("mv_genfunc") + syn keyword mvPkg_genfunc rgf_charseq rgf_expand rgf_hybrid rgf_pfrac rgf_sequence rgf_term + syn keyword mvPkg_genfunc rgf_encode rgf_findrecur rgf_norm rgf_relate rgf_simp termscale +endif + +" Package: geometry: Euclidean geometry {{{2 +if exists("mv_geometry") + syn keyword mvPkg_geometry circle dsegment hyperbola parabola segment triangle + syn keyword mvPkg_geometry conic ellipse line point square +endif + +" Package: grobner: Grobner bases {{{2 +if exists("mv_grobner") + syn keyword mvPkg_grobner finduni gbasis leadmon normalf solvable spoly + syn keyword mvPkg_grobner finite gsolve +endif + +" Package: group: permutation and finitely-presented groups {{{2 +if exists("mv_group") + syn keyword mvPkg_group DerivedS areconjugate cosets grouporder issubgroup permrep + syn keyword mvPkg_group LCS center cosrep inter mulperms pres + syn keyword mvPkg_group NormalClosure centralizer derived invperm normalizer subgrel + syn keyword mvPkg_group RandElement convert grelgroup isabelian orbit type + syn keyword mvPkg_group Sylow core groupmember isnormal permgroup +endif + +" Package: inttrans: integral transforms {{{2 +if exists("mv_inttrans") + syn keyword mvPkg_inttrans addtable fouriercos hankel invfourier invlaplace mellin + syn keyword mvPkg_inttrans fourier fouriersin hilbert invhilbert laplace +endif + +" Package: liesymm: Lie symmetries {{{2 +if exists("mv_liesymm") + syn keyword mvPkg_liesymm &^ TD depvars getform mixpar vfix + syn keyword mvPkg_liesymm &mod annul determine hasclosure prolong wcollect + syn keyword mvPkg_liesymm Eta autosimp dvalue hook reduce wdegree + syn keyword mvPkg_liesymm Lie close extvars indepvars setup wedgeset + syn keyword mvPkg_liesymm Lrank d getcoeff makeforms translate wsubs +endif + +" Package: linalg: Linear algebra {{{2 +if exists("mv_linalg") + syn keyword mvPkg_linalg GramSchmidt coldim equal indexfunc mulcol singval + syn keyword mvPkg_linalg JordanBlock colspace exponential innerprod multiply smith + syn keyword mvPkg_linalg LUdecomp colspan extend intbasis norm stack + syn keyword mvPkg_linalg QRdecomp companion ffgausselim inverse normalize submatrix + syn keyword mvPkg_linalg addcol cond fibonacci ismith orthog subvector + syn keyword mvPkg_linalg addrow copyinto forwardsub issimilar permanent sumbasis + syn keyword mvPkg_linalg adjoint crossprod frobenius iszero pivot swapcol + syn keyword mvPkg_linalg angle curl gausselim jacobian potential swaprow + syn keyword mvPkg_linalg augment definite gaussjord jordan randmatrix sylvester + syn keyword mvPkg_linalg backsub delcols geneqns kernel randvector toeplitz + syn keyword mvPkg_linalg band delrows genmatrix laplacian rank trace + syn keyword mvPkg_linalg basis det grad leastsqrs references transpose + syn keyword mvPkg_linalg bezout diag hadamard linsolve row vandermonde + syn keyword mvPkg_linalg blockmatrix diverge hermite matadd rowdim vecpotent + syn keyword mvPkg_linalg charmat dotprod hessian matrix rowspace vectdim + syn keyword mvPkg_linalg charpoly eigenval hilbert minor rowspan vector + syn keyword mvPkg_linalg cholesky eigenvect htranspose minpoly scalarmul wronskian + syn keyword mvPkg_linalg col entermatrix ihermite +endif + +" Package: logic: Boolean logic {{{2 +if exists("mv_logic") + syn keyword mvPkg_logic MOD2 bsimp distrib environ randbool tautology + syn keyword mvPkg_logic bequal canon dual frominert satisfy toinert +endif + +" Package: networks: graph networks {{{2 +if exists("mv_networks") + syn keyword mvPkg_networks acycpoly connect dinic graph mincut show + syn keyword mvPkg_networks addedge connectivity djspantree graphical mindegree shrink + syn keyword mvPkg_networks addvertex contract dodecahedron gsimp neighbors span + syn keyword mvPkg_networks adjacency countcuts draw gunion new spanpoly + syn keyword mvPkg_networks allpairs counttrees duplicate head octahedron spantree + syn keyword mvPkg_networks ancestor cube edges icosahedron outdegree tail + syn keyword mvPkg_networks arrivals cycle ends incidence path tetrahedron + syn keyword mvPkg_networks bicomponents cyclebase eweight incident petersen tuttepoly + syn keyword mvPkg_networks charpoly daughter flow indegree random vdegree + syn keyword mvPkg_networks chrompoly degreeseq flowpoly induce rank vertices + syn keyword mvPkg_networks complement delete fundcyc isplanar rankpoly void + syn keyword mvPkg_networks complete departures getlabel maxdegree shortpathtree vweight + syn keyword mvPkg_networks components diameter girth +endif + +" Package: numapprox: numerical approximation {{{2 +if exists("mv_numapprox") + syn keyword mvPkg_numapprox chebdeg chebsort fnorm laurent minimax remez + syn keyword mvPkg_numapprox chebmult chebyshev hornerform laurent pade taylor + syn keyword mvPkg_numapprox chebpade confracform infnorm minimax +endif + +" Package: numtheory: number theory {{{2 +if exists("mv_numtheory") + syn keyword mvPkg_numtheory B cyclotomic invcfrac mcombine nthconver primroot + syn keyword mvPkg_numtheory F divisors invphi mersenne nthdenom quadres + syn keyword mvPkg_numtheory GIgcd euler isolve minkowski nthnumer rootsunity + syn keyword mvPkg_numtheory J factorEQ isprime mipolys nthpow safeprime + syn keyword mvPkg_numtheory L factorset issqrfree mlog order sigma + syn keyword mvPkg_numtheory M fermat ithprime mobius pdexpand sq2factor + syn keyword mvPkg_numtheory bernoulli ifactor jacobi mroot phi sum2sqr + syn keyword mvPkg_numtheory bigomega ifactors kronecker msqrt pprimroot tau + syn keyword mvPkg_numtheory cfrac imagunit lambda nearestp prevprime thue + syn keyword mvPkg_numtheory cfracpol index legendre nextprime +endif + +" Package: orthopoly: orthogonal polynomials {{{2 +if exists("mv_orthopoly") + syn keyword mvPkg_orthopoly G H L P T U +endif + +" Package: padic: p-adic numbers {{{2 +if exists("mv_padic") + syn keyword mvPkg_padic evalp function orderp ratvaluep rootp valuep + syn keyword mvPkg_padic expansion lcoeffp ordp +endif + +" Package: plots: graphics package {{{2 +if exists("mv_plots") + syn keyword mvPkg_plots animate coordplot3d gradplot3d listplot3d polarplot setoptions3d + syn keyword mvPkg_plots animate3d cylinderplot implicitplot loglogplot polygonplot spacecurve + syn keyword mvPkg_plots changecoords densityplot implicitplot3d logplot polygonplot3d sparsematrixplot + syn keyword mvPkg_plots complexplot display inequal matrixplot polyhedraplot sphereplot + syn keyword mvPkg_plots complexplot3d display3d listcontplot odeplot replot surfdata + syn keyword mvPkg_plots conformal fieldplot listcontplot3d pareto rootlocus textplot + syn keyword mvPkg_plots contourplot fieldplot3d listdensityplot pointplot semilogplot textplot3d + syn keyword mvPkg_plots contourplot3d gradplot listplot pointplot3d setoptions tubeplot + syn keyword mvPkg_plots coordplot +endif + +" Package: plottools: basic graphical objects {{{2 +if exists("mv_plottools") + syn keyword mvPkg_plottools arc curve dodecahedron hyperbola pieslice semitorus + syn keyword mvPkg_plottools arrow cutin ellipse icosahedron point sphere + syn keyword mvPkg_plottools circle cutout ellipticArc line polygon tetrahedron + syn keyword mvPkg_plottools cone cylinder hemisphere octahedron rectangle torus + syn keyword mvPkg_plottools cuboid disk hexahedron +endif + +" Package: powseries: formal power series {{{2 +if exists("mv_powseries") + syn keyword mvPkg_powseries compose multiply powcreate powlog powsolve reversion + syn keyword mvPkg_powseries evalpow negative powdiff powpoly powsqrt subtract + syn keyword mvPkg_powseries inverse powadd powexp powseries quotient tpsform + syn keyword mvPkg_powseries multconst powcos powint powsin +endif + +" Package: process: (Unix)-multi-processing {{{2 +if exists("mv_process") + syn keyword mvPkg_process block fork pclose pipe popen wait + syn keyword mvPkg_process exec kill +endif + +" Package: simplex: linear optimization {{{2 +if exists("mv_simplex") + syn keyword mvPkg_simplex NONNEGATIVE cterm dual maximize pivoteqn setup + syn keyword mvPkg_simplex basis define_zero equality minimize pivotvar standardize + syn keyword mvPkg_simplex convexhull display feasible pivot ratio +endif + +" Package: stats: statistics {{{2 +if exists("mv_stats") + syn keyword mvPkg_stats anova describe fit random statevalf statplots +endif + +" Package: student: student calculus {{{2 +if exists("mv_student") + syn keyword mvPkg_student D Product distance isolate middlesum rightsum + syn keyword mvPkg_student Diff Sum equate leftbox midpoint showtangent + syn keyword mvPkg_student Doubleint Tripleint extrema leftsum minimize simpson + syn keyword mvPkg_student Int changevar integrand makeproc minimize slope + syn keyword mvPkg_student Limit combine intercept maximize powsubs trapezoid + syn keyword mvPkg_student Lineint completesquare intparts middlebox rightbox value + syn keyword mvPkg_student Point +endif + +" Package: sumtools: indefinite and definite sums {{{2 +if exists("mv_sumtools") + syn keyword mvPkg_sumtools Hypersum extended_gosper hyperrecursion hyperterm sumrecursion sumtohyper + syn keyword mvPkg_sumtools Sumtohyper gosper hypersum simpcomb +endif + +" Package: tensor: tensor computations and General Relativity {{{2 +if exists("mv_tensor") + syn keyword mvPkg_tensor Christoffel1 Riemann connexF display_allGR get_compts partial_diff + syn keyword mvPkg_tensor Christoffel2 RiemannF contract dual get_rank permute_indices + syn keyword mvPkg_tensor Einstein Weyl convertNP entermetric invars petrov + syn keyword mvPkg_tensor Jacobian act cov_diff exterior_diff invert prod + syn keyword mvPkg_tensor Killing_eqns antisymmetrize create exterior_prod lin_com raise + syn keyword mvPkg_tensor Levi_Civita change_basis d1metric frame lower symmetrize + syn keyword mvPkg_tensor Lie_diff commutator d2metric geodesic_eqns npcurve tensorsGR + syn keyword mvPkg_tensor Ricci compare directional_diff get_char npspin transform + syn keyword mvPkg_tensor Ricciscalar conj displayGR +endif + +" Package: totorder: total orders on names {{{2 +if exists("mv_totorder") + syn keyword mvPkg_totorder forget init ordering tassume tis +endif +" ===================================================================== + +" Highlighting: Define the default highlighting. {{{1 +" Only when an item doesn't have highlighting yet +if !exists("skip_maplev_syntax_inits") + + " Maple->Maple Links {{{2 + hi def link mvBraceError mvError + hi def link mvCurlyError mvError + hi def link mvDebug mvTodo + hi def link mvParenError mvError + hi def link mvPkg_DEtools mvPkgFunc + hi def link mvPkg_Galois mvPkgFunc + hi def link mvPkg_GaussInt mvPkgFunc + hi def link mvPkg_LREtools mvPkgFunc + hi def link mvPkg_combinat mvPkgFunc + hi def link mvPkg_combstruct mvPkgFunc + hi def link mvPkg_difforms mvPkgFunc + hi def link mvPkg_finance mvPkgFunc + hi def link mvPkg_genfunc mvPkgFunc + hi def link mvPkg_geometry mvPkgFunc + hi def link mvPkg_grobner mvPkgFunc + hi def link mvPkg_group mvPkgFunc + hi def link mvPkg_inttrans mvPkgFunc + hi def link mvPkg_liesymm mvPkgFunc + hi def link mvPkg_linalg mvPkgFunc + hi def link mvPkg_logic mvPkgFunc + hi def link mvPkg_networks mvPkgFunc + hi def link mvPkg_numapprox mvPkgFunc + hi def link mvPkg_numtheory mvPkgFunc + hi def link mvPkg_orthopoly mvPkgFunc + hi def link mvPkg_padic mvPkgFunc + hi def link mvPkg_plots mvPkgFunc + hi def link mvPkg_plottools mvPkgFunc + hi def link mvPkg_powseries mvPkgFunc + hi def link mvPkg_process mvPkgFunc + hi def link mvPkg_simplex mvPkgFunc + hi def link mvPkg_stats mvPkgFunc + hi def link mvPkg_student mvPkgFunc + hi def link mvPkg_sumtools mvPkgFunc + hi def link mvPkg_tensor mvPkgFunc + hi def link mvPkg_totorder mvPkgFunc + hi def link mvRange mvOper + hi def link mvSemiError mvError + hi def link mvDelim Delimiter + + " Maple->Standard Links {{{2 + hi def link mvAssign Delimiter + hi def link mvBool Boolean + hi def link mvComma Delimiter + hi def link mvComment Comment + hi def link mvCond Conditional + hi def link mvConstant Number + hi def link mvDelayEval Label + hi def link mvDcolon Delimiter + hi def link mvError Error + hi def link mvLibrary Statement + hi def link mvNumber Number + hi def link mvOper Operator + hi def link mvAssign Delimiter + hi def link mvPackage Type + hi def link mvPkgFunc Function + hi def link mvPktOption Special + hi def link mvRepeat Repeat + hi def link mvSpecial Special + hi def link mvStatement Statement + hi def link mvName String + hi def link mvString String + hi def link mvTodo Todo + +endif + +" Current Syntax: {{{1 +let b:current_syntax = "maple" +" vim: ts=20 fdm=marker + +endif diff --git a/syntax/markdown.vim b/syntax/markdown.vim index 2d2ee52..ebd1cae 100644 --- a/syntax/markdown.vim +++ b/syntax/markdown.vim @@ -1,3 +1,152 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Markdown +" Maintainer: Tim Pope +" Filenames: *.markdown +" Last Change: 2016 Aug 29 + +if exists("b:current_syntax") + finish +endif + +if !exists('main_syntax') + let main_syntax = 'markdown' +endif + +runtime! syntax/html.vim +unlet! b:current_syntax + +if !exists('g:markdown_fenced_languages') + let g:markdown_fenced_languages = [] +endif +for s:type in map(copy(g:markdown_fenced_languages),'matchstr(v:val,"[^=]*$")') + if s:type =~ '\.' + let b:{matchstr(s:type,'[^.]*')}_subtype = matchstr(s:type,'\.\zs.*') + endif + exe 'syn include @markdownHighlight'.substitute(s:type,'\.','','g').' syntax/'.matchstr(s:type,'[^.]*').'.vim' + unlet! b:current_syntax +endfor +unlet! s:type + +syn sync minlines=10 +syn case ignore + +syn match markdownValid '[<>]\c[a-z/$!]\@!' +syn match markdownValid '&\%(#\=\w*;\)\@!' + +syn match markdownLineStart "^[<@]\@!" nextgroup=@markdownBlock,htmlSpecialChar + +syn cluster markdownBlock contains=markdownH1,markdownH2,markdownH3,markdownH4,markdownH5,markdownH6,markdownBlockquote,markdownListMarker,markdownOrderedListMarker,markdownCodeBlock,markdownRule +syn cluster markdownInline contains=markdownLineBreak,markdownLinkText,markdownItalic,markdownBold,markdownCode,markdownEscape,@htmlTop,markdownError + +syn match markdownH1 "^.\+\n=\+$" contained contains=@markdownInline,markdownHeadingRule,markdownAutomaticLink +syn match markdownH2 "^.\+\n-\+$" contained contains=@markdownInline,markdownHeadingRule,markdownAutomaticLink + +syn match markdownHeadingRule "^[=-]\+$" contained + +syn region markdownH1 matchgroup=markdownHeadingDelimiter start="##\@!" end="#*\s*$" keepend oneline contains=@markdownInline,markdownAutomaticLink contained +syn region markdownH2 matchgroup=markdownHeadingDelimiter start="###\@!" end="#*\s*$" keepend oneline contains=@markdownInline,markdownAutomaticLink contained +syn region markdownH3 matchgroup=markdownHeadingDelimiter start="####\@!" end="#*\s*$" keepend oneline contains=@markdownInline,markdownAutomaticLink contained +syn region markdownH4 matchgroup=markdownHeadingDelimiter start="#####\@!" end="#*\s*$" keepend oneline contains=@markdownInline,markdownAutomaticLink contained +syn region markdownH5 matchgroup=markdownHeadingDelimiter start="######\@!" end="#*\s*$" keepend oneline contains=@markdownInline,markdownAutomaticLink contained +syn region markdownH6 matchgroup=markdownHeadingDelimiter start="#######\@!" end="#*\s*$" keepend oneline contains=@markdownInline,markdownAutomaticLink contained + +syn match markdownBlockquote ">\%(\s\|$\)" contained nextgroup=@markdownBlock + +syn region markdownCodeBlock start=" \|\t" end="$" contained + +" TODO: real nesting +syn match markdownListMarker "\%(\t\| \{0,4\}\)[-*+]\%(\s\+\S\)\@=" contained +syn match markdownOrderedListMarker "\%(\t\| \{0,4}\)\<\d\+\.\%(\s\+\S\)\@=" contained + +syn match markdownRule "\* *\* *\*[ *]*$" contained +syn match markdownRule "- *- *-[ -]*$" contained + +syn match markdownLineBreak " \{2,\}$" + +syn region markdownIdDeclaration matchgroup=markdownLinkDelimiter start="^ \{0,3\}!\=\[" end="\]:" oneline keepend nextgroup=markdownUrl skipwhite +syn match markdownUrl "\S\+" nextgroup=markdownUrlTitle skipwhite contained +syn region markdownUrl matchgroup=markdownUrlDelimiter start="<" end=">" oneline keepend nextgroup=markdownUrlTitle skipwhite contained +syn region markdownUrlTitle matchgroup=markdownUrlTitleDelimiter start=+"+ end=+"+ keepend contained +syn region markdownUrlTitle matchgroup=markdownUrlTitleDelimiter start=+'+ end=+'+ keepend contained +syn region markdownUrlTitle matchgroup=markdownUrlTitleDelimiter start=+(+ end=+)+ keepend contained + +syn region markdownLinkText matchgroup=markdownLinkTextDelimiter start="!\=\[\%(\_[^]]*]\%( \=[[(]\)\)\@=" end="\]\%( \=[[(]\)\@=" nextgroup=markdownLink,markdownId skipwhite contains=@markdownInline,markdownLineStart +syn region markdownLink matchgroup=markdownLinkDelimiter start="(" end=")" contains=markdownUrl keepend contained +syn region markdownId matchgroup=markdownIdDelimiter start="\[" end="\]" keepend contained +syn region markdownAutomaticLink matchgroup=markdownUrlDelimiter start="<\%(\w\+:\|[[:alnum:]_+-]\+@\)\@=" end=">" keepend oneline + +let s:concealends = has('conceal') ? ' concealends' : '' +exe 'syn region markdownItalic matchgroup=markdownItalicDelimiter start="\S\@<=\*\|\*\S\@=" end="\S\@<=\*\|\*\S\@=" keepend contains=markdownLineStart' . s:concealends +exe 'syn region markdownItalic matchgroup=markdownItalicDelimiter start="\S\@<=_\|_\S\@=" end="\S\@<=_\|_\S\@=" keepend contains=markdownLineStart' . s:concealends +exe 'syn region markdownBold matchgroup=markdownBoldDelimiter start="\S\@<=\*\*\|\*\*\S\@=" end="\S\@<=\*\*\|\*\*\S\@=" keepend contains=markdownLineStart,markdownItalic' . s:concealends +exe 'syn region markdownBold matchgroup=markdownBoldDelimiter start="\S\@<=__\|__\S\@=" end="\S\@<=__\|__\S\@=" keepend contains=markdownLineStart,markdownItalic' . s:concealends +exe 'syn region markdownBoldItalic matchgroup=markdownBoldItalicDelimiter start="\S\@<=\*\*\*\|\*\*\*\S\@=" end="\S\@<=\*\*\*\|\*\*\*\S\@=" keepend contains=markdownLineStart' . s:concealends +exe 'syn region markdownBoldItalic matchgroup=markdownBoldItalicDelimiter start="\S\@<=___\|___\S\@=" end="\S\@<=___\|___\S\@=" keepend contains=markdownLineStart' . s:concealends + +syn region markdownCode matchgroup=markdownCodeDelimiter start="`" end="`" keepend contains=markdownLineStart +syn region markdownCode matchgroup=markdownCodeDelimiter start="`` \=" end=" \=``" keepend contains=markdownLineStart +syn region markdownCode matchgroup=markdownCodeDelimiter start="^\s*```.*$" end="^\s*```\ze\s*$" keepend + +syn match markdownFootnote "\[^[^\]]\+\]" +syn match markdownFootnoteDefinition "^\[^[^\]]\+\]:" + +if main_syntax ==# 'markdown' + for s:type in g:markdown_fenced_languages + exe 'syn region markdownHighlight'.substitute(matchstr(s:type,'[^=]*$'),'\..*','','').' matchgroup=markdownCodeDelimiter start="^\s*```\s*'.matchstr(s:type,'[^=]*').'\>.*$" end="^\s*```\ze\s*$" keepend contains=@markdownHighlight'.substitute(matchstr(s:type,'[^=]*$'),'\.','','g') + endfor + unlet! s:type +endif + +syn match markdownEscape "\\[][\\`*_{}()<>#+.!-]" +syn match markdownError "\w\@<=_\w\@=" + +hi def link markdownH1 htmlH1 +hi def link markdownH2 htmlH2 +hi def link markdownH3 htmlH3 +hi def link markdownH4 htmlH4 +hi def link markdownH5 htmlH5 +hi def link markdownH6 htmlH6 +hi def link markdownHeadingRule markdownRule +hi def link markdownHeadingDelimiter Delimiter +hi def link markdownOrderedListMarker markdownListMarker +hi def link markdownListMarker htmlTagName +hi def link markdownBlockquote Comment +hi def link markdownRule PreProc + +hi def link markdownFootnote Typedef +hi def link markdownFootnoteDefinition Typedef + +hi def link markdownLinkText htmlLink +hi def link markdownIdDeclaration Typedef +hi def link markdownId Type +hi def link markdownAutomaticLink markdownUrl +hi def link markdownUrl Float +hi def link markdownUrlTitle String +hi def link markdownIdDelimiter markdownLinkDelimiter +hi def link markdownUrlDelimiter htmlTag +hi def link markdownUrlTitleDelimiter Delimiter + +hi def link markdownItalic htmlItalic +hi def link markdownItalicDelimiter markdownItalic +hi def link markdownBold htmlBold +hi def link markdownBoldDelimiter markdownBold +hi def link markdownBoldItalic htmlBoldItalic +hi def link markdownBoldItalicDelimiter markdownBoldItalic +hi def link markdownCodeDelimiter Delimiter + +hi def link markdownEscape Special +hi def link markdownError Error + +let b:current_syntax = "markdown" +if main_syntax ==# 'markdown' + unlet main_syntax +endif + +" vim:set sw=2: + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'markdown') == -1 " Vim syntax file diff --git a/syntax/masm.vim b/syntax/masm.vim new file mode 100644 index 0000000..bd72dc8 --- /dev/null +++ b/syntax/masm.vim @@ -0,0 +1,379 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Microsoft Macro Assembler (80x86) +" Orig Author: Rob Brady +" Maintainer: Wu Yongwei +" Last Change: $Date: 2013/11/13 11:49:24 $ +" $Revision: 1.48 $ + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case ignore + + +syn match masmIdentifier "[@a-z_$?][@a-z0-9_$?]*" +syn match masmLabel "^\s*[@a-z_$?][@a-z0-9_$?]*:"he=e-1 + +syn match masmDecimal "[-+]\?\d\+[dt]\?" +syn match masmBinary "[-+]\?[0-1]\+[by]" "put this before hex or 0bfh dies! +syn match masmOctal "[-+]\?[0-7]\+[oq]" +syn match masmHexadecimal "[-+]\?[0-9]\x*h" +syn match masmFloatRaw "[-+]\?[0-9]\x*r" +syn match masmFloat "[-+]\?\d\+\.\(\d*\(E[-+]\?\d\+\)\?\)\?" + +syn match masmComment ";.*" contains=@Spell +syn region masmComment start=+COMMENT\s*\z(\S\)+ end=+\z1.*+ contains=@Spell +syn region masmString start=+'+ end=+'+ oneline contains=@Spell +syn region masmString start=+"+ end=+"+ oneline contains=@Spell + +syn region masmTitleArea start=+\" +syn match masmOperator "CARRY?" +syn match masmOperator "OVERFLOW?" +syn match masmOperator "PARITY?" +syn match masmOperator "SIGN?" +syn match masmOperator "ZERO?" +syn keyword masmDirective ALIAS ASSUME CATSTR COMM DB DD DF DOSSEG DQ DT +syn keyword masmDirective DW ECHO ELSE ELSEIF ELSEIF1 ELSEIF2 ELSEIFB +syn keyword masmDirective ELSEIFDEF ELSEIFDIF ELSEIFDIFI ELSEIFE +syn keyword masmDirective ELSEIFIDN ELSEIFIDNI ELSEIFNB ELSEIFNDEF END +syn keyword masmDirective ENDIF ENDM ENDP ENDS EQU EVEN EXITM EXTERN +syn keyword masmDirective EXTERNDEF EXTRN FOR FORC GOTO GROUP IF IF1 IF2 +syn keyword masmDirective IFB IFDEF IFDIF IFDIFI IFE IFIDN IFIDNI IFNB +syn keyword masmDirective IFNDEF INCLUDE INCLUDELIB INSTR INVOKE IRP +syn keyword masmDirective IRPC LABEL LOCAL MACRO NAME OPTION ORG PAGE +syn keyword masmDirective POPCONTEXT PROC PROTO PUBLIC PURGE PUSHCONTEXT +syn keyword masmDirective RECORD REPEAT REPT SEGMENT SIZESTR STRUC +syn keyword masmDirective STRUCT SUBSTR SUBTITLE SUBTTL TEXTEQU TITLE +syn keyword masmDirective TYPEDEF UNION WHILE +syn match masmDirective "\.8086\>" +syn match masmDirective "\.8087\>" +syn match masmDirective "\.NO87\>" +syn match masmDirective "\.186\>" +syn match masmDirective "\.286\>" +syn match masmDirective "\.286C\>" +syn match masmDirective "\.286P\>" +syn match masmDirective "\.287\>" +syn match masmDirective "\.386\>" +syn match masmDirective "\.386C\>" +syn match masmDirective "\.386P\>" +syn match masmDirective "\.387\>" +syn match masmDirective "\.486\>" +syn match masmDirective "\.486P\>" +syn match masmDirective "\.586\>" +syn match masmDirective "\.586P\>" +syn match masmDirective "\.686\>" +syn match masmDirective "\.686P\>" +syn match masmDirective "\.K3D\>" +syn match masmDirective "\.MMX\>" +syn match masmDirective "\.XMM\>" +syn match masmDirective "\.ALPHA\>" +syn match masmDirective "\.DOSSEG\>" +syn match masmDirective "\.SEQ\>" +syn match masmDirective "\.CODE\>" +syn match masmDirective "\.CONST\>" +syn match masmDirective "\.DATA\>" +syn match masmDirective "\.DATA?" +syn match masmDirective "\.EXIT\>" +syn match masmDirective "\.FARDATA\>" +syn match masmDirective "\.FARDATA?" +syn match masmDirective "\.MODEL\>" +syn match masmDirective "\.STACK\>" +syn match masmDirective "\.STARTUP\>" +syn match masmDirective "\.IF\>" +syn match masmDirective "\.ELSE\>" +syn match masmDirective "\.ELSEIF\>" +syn match masmDirective "\.ENDIF\>" +syn match masmDirective "\.REPEAT\>" +syn match masmDirective "\.UNTIL\>" +syn match masmDirective "\.UNTILCXZ\>" +syn match masmDirective "\.WHILE\>" +syn match masmDirective "\.ENDW\>" +syn match masmDirective "\.BREAK\>" +syn match masmDirective "\.CONTINUE\>" +syn match masmDirective "\.ERR\>" +syn match masmDirective "\.ERR1\>" +syn match masmDirective "\.ERR2\>" +syn match masmDirective "\.ERRB\>" +syn match masmDirective "\.ERRDEF\>" +syn match masmDirective "\.ERRDIF\>" +syn match masmDirective "\.ERRDIFI\>" +syn match masmDirective "\.ERRE\>" +syn match masmDirective "\.ERRIDN\>" +syn match masmDirective "\.ERRIDNI\>" +syn match masmDirective "\.ERRNB\>" +syn match masmDirective "\.ERRNDEF\>" +syn match masmDirective "\.ERRNZ\>" +syn match masmDirective "\.LALL\>" +syn match masmDirective "\.SALL\>" +syn match masmDirective "\.XALL\>" +syn match masmDirective "\.LFCOND\>" +syn match masmDirective "\.SFCOND\>" +syn match masmDirective "\.TFCOND\>" +syn match masmDirective "\.CREF\>" +syn match masmDirective "\.NOCREF\>" +syn match masmDirective "\.XCREF\>" +syn match masmDirective "\.LIST\>" +syn match masmDirective "\.NOLIST\>" +syn match masmDirective "\.XLIST\>" +syn match masmDirective "\.LISTALL\>" +syn match masmDirective "\.LISTIF\>" +syn match masmDirective "\.NOLISTIF\>" +syn match masmDirective "\.LISTMACRO\>" +syn match masmDirective "\.NOLISTMACRO\>" +syn match masmDirective "\.LISTMACROALL\>" +syn match masmDirective "\.FPO\>" +syn match masmDirective "\.RADIX\>" +syn match masmDirective "\.SAFESEH\>" +syn match masmDirective "%OUT\>" +syn match masmDirective "ALIGN\>" +syn match masmOption "ALIGN([0-9]\+)" + +syn keyword masmRegister AX BX CX DX SI DI BP SP +syn keyword masmRegister CS DS SS ES FS GS +syn keyword masmRegister AH BH CH DH AL BL CL DL +syn keyword masmRegister EAX EBX ECX EDX ESI EDI EBP ESP +syn keyword masmRegister CR0 CR2 CR3 CR4 +syn keyword masmRegister DR0 DR1 DR2 DR3 DR6 DR7 +syn keyword masmRegister TR3 TR4 TR5 TR6 TR7 +syn match masmRegister "ST([0-7])" + +" x86-64 registers +syn keyword masmRegister RAX RBX RCX RDX RSI RDI RBP RSP +syn keyword masmRegister R8 R9 R10 R11 R12 R13 R14 R15 +syn keyword masmRegister R8D R9D R10D R11D R12D R13D R14D R15D +syn keyword masmRegister R8W R9W R10W R11W R12W R13W R14W R15W +syn keyword masmRegister R8B R9B R10B R11B R12B R13B R14B R15B + +" SSE/AVX registers +syn match masmRegister "\(X\|Y\)MM[0-9]\>" +syn match masmRegister "\(X\|Y\)MM1[0-5]\>" + +" Instruction prefixes +syn keyword masmOpcode LOCK REP REPE REPNE REPNZ REPZ + +" 8086/8088 opcodes +syn keyword masmOpcode AAA AAD AAM AAS ADC ADD AND CALL CBW CLC CLD +syn keyword masmOpcode CLI CMC CMP CMPS CMPSB CMPSW CWD DAA DAS DEC +syn keyword masmOpcode DIV ESC HLT IDIV IMUL IN INC INT INTO IRET +syn keyword masmOpcode JCXZ JMP LAHF LDS LEA LES LODS LODSB LODSW +syn keyword masmOpcode LOOP LOOPE LOOPEW LOOPNE LOOPNEW LOOPNZ +syn keyword masmOpcode LOOPNZW LOOPW LOOPZ LOOPZW MOV MOVS MOVSB +syn keyword masmOpcode MOVSW MUL NEG NOP NOT OR OUT POP POPF PUSH +syn keyword masmOpcode PUSHF RCL RCR RET RETF RETN ROL ROR SAHF SAL +syn keyword masmOpcode SAR SBB SCAS SCASB SCASW SHL SHR STC STD STI +syn keyword masmOpcode STOS STOSB STOSW SUB TEST WAIT XCHG XLAT XLATB +syn keyword masmOpcode XOR +syn match masmOpcode "J\(P[EO]\|\(N\?\([ABGL]E\?\|[CEOPSZ]\)\)\)\>" + +" 80186 opcodes +syn keyword masmOpcode BOUND ENTER INS INSB INSW LEAVE OUTS OUTSB +syn keyword masmOpcode OUTSW POPA PUSHA PUSHW + +" 80286 opcodes +syn keyword masmOpcode ARPL LAR LSL SGDT SIDT SLDT SMSW STR VERR VERW + +" 80286/80386 privileged opcodes +syn keyword masmOpcode CLTS LGDT LIDT LLDT LMSW LTR + +" 80386 opcodes +syn keyword masmOpcode BSF BSR BT BTC BTR BTS CDQ CMPSD CWDE INSD +syn keyword masmOpcode IRETD IRETDF IRETF JECXZ LFS LGS LODSD LOOPD +syn keyword masmOpcode LOOPED LOOPNED LOOPNZD LOOPZD LSS MOVSD MOVSX +syn keyword masmOpcode MOVZX OUTSD POPAD POPFD PUSHAD PUSHD PUSHFD +syn keyword masmOpcode SCASD SHLD SHRD STOSD +syn match masmOpcode "SET\(P[EO]\|\(N\?\([ABGL]E\?\|[CEOPSZ]\)\)\)\>" + +" 80486 opcodes +syn keyword masmOpcode BSWAP CMPXCHG INVD INVLPG WBINVD XADD + +" Floating-point opcodes as of 487 +syn keyword masmOpFloat F2XM1 FABS FADD FADDP FBLD FBSTP FCHS FCLEX +syn keyword masmOpFloat FNCLEX FCOM FCOMP FCOMPP FCOS FDECSTP FDISI +syn keyword masmOpFloat FNDISI FDIV FDIVP FDIVR FDIVRP FENI FNENI +syn keyword masmOpFloat FFREE FIADD FICOM FICOMP FIDIV FIDIVR FILD +syn keyword masmOpFloat FIMUL FINCSTP FINIT FNINIT FIST FISTP FISUB +syn keyword masmOpFloat FISUBR FLD FLDCW FLDENV FLDLG2 FLDLN2 FLDL2E +syn keyword masmOpFloat FLDL2T FLDPI FLDZ FLD1 FMUL FMULP FNOP FPATAN +syn keyword masmOpFloat FPREM FPREM1 FPTAN FRNDINT FRSTOR FSAVE FNSAVE +syn keyword masmOpFloat FSCALE FSETPM FSIN FSINCOS FSQRT FST FSTCW +syn keyword masmOpFloat FNSTCW FSTENV FNSTENV FSTP FSTSW FNSTSW FSUB +syn keyword masmOpFloat FSUBP FSUBR FSUBRP FTST FUCOM FUCOMP FUCOMPP +syn keyword masmOpFloat FWAIT FXAM FXCH FXTRACT FYL2X FYL2XP1 + +" Floating-point opcodes in Pentium and later processors +syn keyword masmOpFloat FCMOVE FCMOVNE FCMOVB FCMOVBE FCMOVNB FCMOVNBE +syn keyword masmOpFloat FCMOVU FCMOVNU FCOMI FUCOMI FCOMIP FUCOMIP +syn keyword masmOpFloat FXSAVE FXRSTOR + +" MMX opcodes (Pentium w/ MMX, Pentium II, and later) +syn keyword masmOpcode MOVD MOVQ PACKSSWB PACKSSDW PACKUSWB +syn keyword masmOpcode PUNPCKHBW PUNPCKHWD PUNPCKHDQ +syn keyword masmOpcode PUNPCKLBW PUNPCKLWD PUNPCKLDQ +syn keyword masmOpcode PADDB PADDW PADDD PADDSB PADDSW PADDUSB PADDUSW +syn keyword masmOpcode PSUBB PSUBW PSUBD PSUBSB PSUBSW PSUBUSB PSUBUSW +syn keyword masmOpcode PMULHW PMULLW PMADDWD +syn keyword masmOpcode PCMPEQB PCMPEQW PCMPEQD PCMPGTB PCMPGTW PCMPGTD +syn keyword masmOpcode PAND PANDN POR PXOR +syn keyword masmOpcode PSLLW PSLLD PSLLQ PSRLW PSRLD PSRLQ PSRAW PSRAD +syn keyword masmOpcode EMMS + +" SSE opcodes (Pentium III and later) +syn keyword masmOpcode MOVAPS MOVUPS MOVHPS MOVHLPS MOVLPS MOVLHPS +syn keyword masmOpcode MOVMSKPS MOVSS +syn keyword masmOpcode ADDPS ADDSS SUBPS SUBSS MULPS MULSS DIVPS DIVSS +syn keyword masmOpcode RCPPS RCPSS SQRTPS SQRTSS RSQRTPS RSQRTSS +syn keyword masmOpcode MAXPS MAXSS MINPS MINSS +syn keyword masmOpcode CMPPS CMPSS COMISS UCOMISS +syn keyword masmOpcode ANDPS ANDNPS ORPS XORPS +syn keyword masmOpcode SHUFPS UNPCKHPS UNPCKLPS +syn keyword masmOpcode CVTPI2PS CVTSI2SS CVTPS2PI CVTTPS2PI +syn keyword masmOpcode CVTSS2SI CVTTSS2SI +syn keyword masmOpcode LDMXCSR STMXCSR +syn keyword masmOpcode PAVGB PAVGW PEXTRW PINSRW PMAXUB PMAXSW +syn keyword masmOpcode PMINUB PMINSW PMOVMSKB PMULHUW PSADBW PSHUFW +syn keyword masmOpcode MASKMOVQ MOVNTQ MOVNTPS SFENCE +syn keyword masmOpcode PREFETCHT0 PREFETCHT1 PREFETCHT2 PREFETCHNTA + +" SSE2 opcodes (Pentium 4 and later) +syn keyword masmOpcode MOVAPD MOVUPD MOVHPD MOVLPD MOVMSKPD MOVSD +syn keyword masmOpcode ADDPD ADDSD SUBPD SUBSD MULPD MULSD DIVPD DIVSD +syn keyword masmOpcode SQRTPD SQRTSD MAXPD MAXSD MINPD MINSD +syn keyword masmOpcode ANDPD ANDNPD ORPD XORPD +syn keyword masmOpcode CMPPD CMPSD COMISD UCOMISD +syn keyword masmOpcode SHUFPD UNPCKHPD UNPCKLPD +syn keyword masmOpcode CVTPD2PI CVTTPD2PI CVTPI2PD CVTPD2DQ +syn keyword masmOpcode CVTTPD2DQ CVTDQ2PD CVTPS2PD CVTPD2PS +syn keyword masmOpcode CVTSS2SD CVTSD2SS CVTSD2SI CVTTSD2SI CVTSI2SD +syn keyword masmOpcode CVTDQ2PS CVTPS2DQ CVTTPS2DQ +syn keyword masmOpcode MOVDQA MOVDQU MOVQ2DQ MOVDQ2Q PMULUDQ +syn keyword masmOpcode PADDQ PSUBQ PSHUFLW PSHUFHW PSHUFD +syn keyword masmOpcode PSLLDQ PSRLDQ PUNPCKHQDQ PUNPCKLQDQ +syn keyword masmOpcode CLFLUSH LFENCE MFENCE PAUSE MASKMOVDQU +syn keyword masmOpcode MOVNTPD MOVNTDQ MOVNTI + +" SSE3 opcodes (Pentium 4 w/ Hyper-Threading and later) +syn keyword masmOpcode FISTTP LDDQU ADDSUBPS ADDSUBPD +syn keyword masmOpcode HADDPS HSUBPS HADDPD HSUBPD +syn keyword masmOpcode MOVSHDUP MOVSLDUP MOVDDUP MONITOR MWAIT + +" SSSE3 opcodes (Core and later) +syn keyword masmOpcode PSIGNB PSIGNW PSIGND PABSB PABSW PABSD +syn keyword masmOpcode PALIGNR PSHUFB PMULHRSW PMADDUBSW +syn keyword masmOpcode PHSUBW PHSUBD PHSUBSW PHADDW PHADDD PHADDSW + +" SSE 4.1 opcodes (Penryn and later) +syn keyword masmOpcode MPSADBW PHMINPOSUW PMULDQ PMULLD DPPS DPPD +syn keyword masmOpcode BLENDPS BLENDPD BLENDVPS BLENDVPD +syn keyword masmOpcode PBLENDVB PBLENDW +syn keyword masmOpcode PMINSB PMAXSB PMINSD PMAXSD +syn keyword masmOpcode PMINUW PMAXUW PMINUD PMAXUD +syn keyword masmOpcode ROUNDPS ROUNDSS ROUNDPD ROUNDSD +syn keyword masmOpcode INSERTPS PINSRB PINSRD PINSRQ +syn keyword masmOpcode EXTRACTPS PEXTRB PEXTRD PEXTRQ +syn keyword masmOpcode PMOVSXBW PMOVZXBW PMOVSXBD PMOVZXBD +syn keyword masmOpcode PMOVSXBQ PMOVZXBQ PMOVSXWD PMOVZXWD +syn keyword masmOpcode PMOVSXWQ PMOVZXWQ PMOVSXDQ PMOVZXDQ +syn keyword masmOpcode PTEST PCMPEQQ PACKUSDW MOVNTDQA + +" SSE 4.2 opcodes (Nehalem and later) +syn keyword masmOpcode PCMPESTRI PCMPESTRM PCMPISTRI PCMPISTRM PCMPGTQ +syn keyword masmOpcode CRC32 POPCNT LZCNT + +" AES-NI (Westmere (2010) and later) +syn keyword masmOpcode AESENC AESENCLAST AESDEC AESDECLAST +syn keyword masmOpcode AESKEYGENASSIST AESIMC PCLMULQDQ + +" AVX (Sandy Bridge (2011) and later) +syn keyword masmOpcode VBROADCASTSS VBROADCASTSD VBROADCASTF128 +syn keyword masmOpcode VINSERTF128 VEXTRACTF128 VMASKMOVPS VMASKMOVPD +syn keyword masmOpcode VPERMILPS VPERMILPD VPERM2F128 +syn keyword masmOpcode VZEROALL VZEROUPPER + +" Other opcodes in Pentium and later processors +syn keyword masmOpcode CMPXCHG8B CPUID UD2 +syn keyword masmOpcode RSM RDMSR WRMSR RDPMC RDTSC SYSENTER SYSEXIT +syn match masmOpcode "CMOV\(P[EO]\|\(N\?\([ABGL]E\?\|[CEOPSZ]\)\)\)\>" + + +" The default highlighting +hi def link masmLabel PreProc +hi def link masmComment Comment +hi def link masmDirective Statement +hi def link masmType Type +hi def link masmOperator Type +hi def link masmOption Special +hi def link masmRegister Special +hi def link masmString String +hi def link masmText String +hi def link masmTitle Title +hi def link masmOpcode Statement +hi def link masmOpFloat Statement + +hi def link masmHexadecimal Number +hi def link masmDecimal Number +hi def link masmOctal Number +hi def link masmBinary Number +hi def link masmFloatRaw Number +hi def link masmFloat Number + +hi def link masmIdentifier Identifier + +syntax sync minlines=50 + +let b:current_syntax = "masm" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/mason.vim b/syntax/mason.vim index a7b2119..e202455 100644 --- a/syntax/mason.vim +++ b/syntax/mason.vim @@ -1,3 +1,90 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Mason (Perl embedded in HTML) +" Maintainer: vim-perl +" Homepage: http://github.com/vim-perl/vim-perl/tree/master +" Bugs/requests: http://github.com/vim-perl/vim-perl/issues +" Last Change: 2017-09-12 +" Contributors: Hinrik Örn Sigurðsson +" Andrew Smith +" +" TODO: +" - Fix <%text> blocks to show HTML tags but ignore Mason tags. +" + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" The HTML syntax file included below uses this variable. +" +if !exists("main_syntax") + let main_syntax = 'mason' +endif + +" First pull in the HTML syntax. +" +runtime! syntax/html.vim +unlet b:current_syntax + +syn cluster htmlPreproc add=@masonTop + +" Now pull in the Perl syntax. +" +syn include @perlTop syntax/perl.vim +unlet b:current_syntax +syn include @podTop syntax/pod.vim + +" It's hard to reduce down to the correct sub-set of Perl to highlight in some +" of these cases so I've taken the safe option of just using perlTop in all of +" them. If you have any suggestions, please let me know. +" +syn region masonPod start="^=[a-z]" end="^=cut" keepend contained contains=@podTop +syn cluster perlTop remove=perlBraces +syn region masonLine matchgroup=Delimiter start="^%" end="$" keepend contains=@perlTop +syn region masonPerlComment start="#" end="\%(%>\)\@=\|$" contained contains=perlTodo,@Spell +syn region masonExpr matchgroup=Delimiter start="<%" end="%>" contains=@perlTop,masonPerlComment +syn region masonPerl matchgroup=Delimiter start="<%perl>" end="" contains=masonPod,@perlTop +syn region masonComp keepend matchgroup=Delimiter start="<&\s*\%([-._/[:alnum:]]\+:\)\?[-._/[:alnum:]]*" end="&>" contains=@perlTop +syn region masonComp keepend matchgroup=Delimiter skipnl start="<&|\s*\%([-._/[:alnum:]]\+:\)\?[-._/[:alnum:]]*" end="&>" contains=@perlTop nextgroup=masonCompContent +syn region masonCompContent matchgroup=Delimiter start="" end="" contained contains=@masonTop + +syn region masonArgs matchgroup=Delimiter start="<%args>" end="" contains=masonPod,@perlTop + +syn region masonInit matchgroup=Delimiter start="<%init>" end="" contains=masonPod,@perlTop +syn region masonCleanup matchgroup=Delimiter start="<%cleanup>" end="" contains=masonPod,@perlTop +syn region masonOnce matchgroup=Delimiter start="<%once>" end="" contains=masonPod,@perlTop +syn region masonClass matchgroup=Delimiter start="<%class>" end="" contains=masonPod,@perlTop +syn region masonShared matchgroup=Delimiter start="<%shared>" end="" contains=masonPod,@perlTop + +syn region masonDef matchgroup=Delimiter start="<%def\s*[-._/[:alnum:]]\+\s*>" end="" contains=@htmlTop +syn region masonMethod matchgroup=Delimiter start="<%method\s*[-._/[:alnum:]]\+\s*>" end="" contains=@htmlTop + +syn region masonFlags matchgroup=Delimiter start="<%flags>" end="" contains=masonPod,@perlTop +syn region masonAttr matchgroup=Delimiter start="<%attr>" end="" contains=masonPod,@perlTop + +syn region masonFilter matchgroup=Delimiter start="<%filter>" end="" contains=masonPod,@perlTop + +syn region masonDoc matchgroup=Delimiter start="<%doc>" end="" +syn region masonText matchgroup=Delimiter start="<%text>" end="" + +syn cluster masonTop contains=masonLine,masonExpr,masonPerl,masonComp,masonArgs,masonInit,masonCleanup,masonOnce,masonShared,masonDef,masonMethod,masonFlags,masonAttr,masonFilter,masonDoc,masonText + +" Set up default highlighting. Almost all of this is done in the included +" syntax files. +hi def link masonDoc Comment +hi def link masonPod Comment +hi def link masonPerlComment perlComment + +let b:current_syntax = "mason" + +if main_syntax == 'mason' + unlet main_syntax +endif + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Vim syntax file diff --git a/syntax/master.vim b/syntax/master.vim new file mode 100644 index 0000000..6743cce --- /dev/null +++ b/syntax/master.vim @@ -0,0 +1,41 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Focus Master File +" Maintainer: Rob Brady +" Last Change: $Date: 2004/06/13 15:54:03 $ +" URL: http://www.datatone.com/~robb/vim/syntax/master.vim +" $Revision: 1.1 $ + +" this is a very simple syntax file - I will be improving it +" add entire DEFINE syntax + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +" A bunch of useful keywords +syn keyword masterKeyword FILENAME SUFFIX SEGNAME SEGTYPE PARENT FIELDNAME +syn keyword masterKeyword FIELD ALIAS USAGE INDEX MISSING ON +syn keyword masterKeyword FORMAT CRFILE CRKEY +syn keyword masterDefine DEFINE DECODE EDIT +syn region masterString start=+"+ end=+"+ +syn region masterString start=+'+ end=+'+ +syn match masterComment "\$.*" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link masterKeyword Keyword +hi def link masterComment Comment +hi def link masterString String + + +let b:current_syntax = "master" + +" vim: ts=8 + +endif diff --git a/syntax/matlab.vim b/syntax/matlab.vim new file mode 100644 index 0000000..d1c4236 --- /dev/null +++ b/syntax/matlab.vim @@ -0,0 +1,120 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Matlab +" Maintainer: Alex Burka +" Credits: Preben 'Peppe' Guldberg +" Maurizio Tranchero - maurizio(.)tranchero(@)gmail(.)com +" Original author: Mario Eusebio +" Last Change: Mon Jan 23 2017 +" added support for cell mode +" Change History: +" - now highlights cell-mode separator comments +" - 'global' and 'persistent' keyword are now recognized + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword matlabStatement return +syn keyword matlabLabel case switch +syn keyword matlabConditional else elseif end if otherwise +syn keyword matlabRepeat do for while +" MT_ADDON - added exception-specific keywords +syn keyword matlabExceptions try catch +syn keyword matlabOO classdef properties events methods + +syn keyword matlabTodo contained TODO +syn keyword matlabScope global persistent + +" If you do not want these operators lit, uncommment them and the "hi link" below +syn match matlabArithmeticOperator "[-+]" +syn match matlabArithmeticOperator "\.\=[*/\\^]" +syn match matlabRelationalOperator "[=~]=" +syn match matlabRelationalOperator "[<>]=\=" +syn match matlabLogicalOperator "[&|~]" + +syn match matlabLineContinuation "\.\{3}" + +"syn match matlabIdentifier "\<\a\w*\>" + +" String +" MT_ADDON - added 'skip' in order to deal with 'tic' escaping sequence +syn region matlabString start=+'+ end=+'+ oneline skip=+''+ + +" If you don't like tabs +syn match matlabTab "\t" + +" Standard numbers +syn match matlabNumber "\<\d\+[ij]\=\>" +" floating point number, with dot, optional exponent +syn match matlabFloat "\<\d\+\(\.\d*\)\=\([edED][-+]\=\d\+\)\=[ij]\=\>" +" floating point number, starting with a dot, optional exponent +syn match matlabFloat "\.\d\+\([edED][-+]\=\d\+\)\=[ij]\=\>" + +" Transpose character and delimiters: Either use just [...] or (...) aswell +syn match matlabDelimiter "[][]" +"syn match matlabDelimiter "[][()]" +syn match matlabTransposeOperator "[])a-zA-Z0-9.]'"lc=1 + +syn match matlabSemicolon ";" + +syn match matlabComment "%.*$" contains=matlabTodo,matlabTab +" MT_ADDON - correctly highlights words after '...' as comments +syn match matlabComment "\.\.\..*$" contains=matlabTodo,matlabTab +syn region matlabMultilineComment start=+%{+ end=+%}+ contains=matlabTodo,matlabTab +syn match matlabCellComment "^%%.*$" + +syn keyword matlabOperator break zeros default margin round ones rand +syn keyword matlabOperator ceil floor size clear zeros eye mean std cov + +syn keyword matlabFunction error eval function + +syn keyword matlabImplicit abs acos atan asin cos cosh exp log prod sum +syn keyword matlabImplicit log10 max min sign sin sinh sqrt tan reshape + +syn match matlabError "-\=\<\d\+\.\d\+\.[^*/\\^]" +syn match matlabError "-\=\<\d\+\.\d\+[eEdD][-+]\=\d\+\.\([^*/\\^]\)" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link matlabTransposeOperator matlabOperator +hi def link matlabOperator Operator +hi def link matlabLineContinuation Special +hi def link matlabLabel Label +hi def link matlabConditional Conditional +hi def link matlabExceptions Conditional +hi def link matlabRepeat Repeat +hi def link matlabTodo Todo +hi def link matlabString String +hi def link matlabDelimiter Identifier +hi def link matlabTransposeOther Identifier +hi def link matlabNumber Number +hi def link matlabFloat Float +hi def link matlabFunction Function +hi def link matlabError Error +hi def link matlabImplicit matlabStatement +hi def link matlabStatement Statement +hi def link matlabOO Statement +hi def link matlabSemicolon SpecialChar +hi def link matlabComment Comment +hi def link matlabMultilineComment Comment +hi def link matlabCellComment Todo +hi def link matlabScope Type + +hi def link matlabArithmeticOperator matlabOperator +hi def link matlabRelationalOperator matlabOperator +hi def link matlabLogicalOperator matlabOperator + +"optional highlighting +"hi def link matlabIdentifier Identifier +"hi def link matlabTab Error + + +let b:current_syntax = "matlab" + +"EOF vim: ts=8 noet tw=100 sw=8 sts=0 + +endif diff --git a/syntax/maxima.vim b/syntax/maxima.vim new file mode 100644 index 0000000..0eea7e0 --- /dev/null +++ b/syntax/maxima.vim @@ -0,0 +1,265 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Maxima (symbolic algebra program) +" Maintainer: Robert Dodier (robert.dodier@gmail.com) +" Last Change: April 6, 2006 +" Version: 1 +" Adapted mostly from xmath.vim +" Number formats adapted from r.vim +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn sync lines=1000 + +" parenthesis sanity checker +syn region maximaZone matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" transparent contains=ALLBUT,maximaError,maximaBraceError,maximaCurlyError +syn region maximaZone matchgroup=Delimiter start="{" matchgroup=Delimiter end="}" transparent contains=ALLBUT,maximaError,maximaBraceError,maximaParenError +syn region maximaZone matchgroup=Delimiter start="\[" matchgroup=Delimiter end="]" transparent contains=ALLBUT,maximaError,maximaCurlyError,maximaParenError +syn match maximaError "[)\]}]" +syn match maximaBraceError "[)}]" contained +syn match maximaCurlyError "[)\]]" contained +syn match maximaParenError "[\]}]" contained +syn match maximaComma "[\[\](),;]" +syn match maximaComma "\.\.\.$" + +" A bunch of useful maxima keywords +syn keyword maximaConditional if then else elseif and or not +syn keyword maximaRepeat do for thru + +" ---------------------- BEGIN LIST OF ALL FUNCTIONS (EXCEPT KEYWORDS) ---------------------- +syn keyword maximaFunc abasep abs absboxchar absint acos acosh acot acoth acsc +syn keyword maximaFunc acsch activate activecontexts addcol additive addrow adim +syn keyword maximaFunc adjoint af aform airy algebraic algepsilon algexact algsys +syn keyword maximaFunc alg_type alias aliases allbut all_dotsimp_denoms allroots allsym +syn keyword maximaFunc alphabetic antid antidiff antisymmetric append appendfile +syn keyword maximaFunc apply apply1 apply2 applyb1 apropos args array arrayapply +syn keyword maximaFunc arrayinfo arraymake arrays asec asech asin asinh askexp +syn keyword maximaFunc askinteger asksign assoc assoc_legendre_p assoc_legendre_q assume +syn keyword maximaFunc assume_pos assume_pos_pred assumescalar asymbol asympa at atan +syn keyword maximaFunc atan2 atanh atensimp atom atomgrad atrig1 atvalue augcoefmatrix +syn keyword maximaFunc av backsubst backtrace bashindices batch batchload bc2 bdvac +syn keyword maximaFunc berlefact bern bernpoly bessel besselexpand bessel_i bessel_j +syn keyword maximaFunc bessel_k bessel_y beta bezout bffac bfhzeta bfloat bfloatp +syn keyword maximaFunc bfpsi bfpsi0 bftorat bftrunc bfzeta bimetric binomial block +syn keyword maximaFunc bothcoef box boxchar break breakup bug_report build_info buildq +syn keyword maximaFunc burn cabs canform canten carg cartan catch cauchysum cbffac +syn keyword maximaFunc cdisplay cf cfdisrep cfexpand cflength cframe_flag cgeodesic +syn keyword maximaFunc changename changevar charpoly checkdiv check_overlaps christof +syn keyword maximaFunc clear_rules closefile closeps cmetric cnonmet_flag coeff +syn keyword maximaFunc coefmatrix cograd col collapse columnvector combine commutative +syn keyword maximaFunc comp2pui compfile compile compile_file components concan concat +syn keyword maximaFunc conj conjugate conmetderiv cons constant constantp cont2part +syn keyword maximaFunc content context contexts contortion contract contragrad coord +syn keyword maximaFunc copylist copymatrix cos cosh cosnpiflag cot coth covdiff +syn keyword maximaFunc covect create_list csc csch csetup ctaylor ctaypov ctaypt +syn keyword maximaFunc ctayswitch ctayvar ct_coords ct_coordsys ctorsion_flag ctransform +syn keyword maximaFunc ctrgsimp current_let_rule_package dblint deactivate debugmode +syn keyword maximaFunc declare declare_translated declare_weight decsym +syn keyword maximaFunc default_let_rule_package defcon define define_variable defint +syn keyword maximaFunc defmatch defrule deftaylor del delete deleten delta demo +syn keyword maximaFunc demoivre denom dependencies depends derivabbrev derivdegree +syn keyword maximaFunc derivlist derivsubst describe desolve determinant detout +syn keyword maximaFunc diagmatrix diagmatrixp diagmetric diff dim dimension direct +syn keyword maximaFunc disolate disp dispcon dispflag dispform dispfun display +syn keyword maximaFunc display2d display_format_internal disprule dispterms distrib +syn keyword maximaFunc divide divsum doallmxops domain domxexpt domxmxops domxnctimes +syn keyword maximaFunc dontfactor doscmxops doscmxplus dot0nscsimp dot0simp dot1simp +syn keyword maximaFunc dotassoc dotconstrules dotdistrib dotexptsimp dotident dotscrules +syn keyword maximaFunc dotsimp dpart dscalar %e echelon %edispflag eigenvalues +syn keyword maximaFunc eigenvectors eighth einstein eivals eivects ele2comp +syn keyword maximaFunc ele2polynome ele2pui elem eliminate elliptic_e elliptic_ec +syn keyword maximaFunc elliptic_eu elliptic_f elliptic_kc elliptic_pi ematrix %emode +syn keyword maximaFunc endcons entermatrix entertensor entier %enumer equal equalp erf +syn keyword maximaFunc erfflag errcatch error errormsg error_size error_syms +syn keyword maximaFunc %e_to_numlog euler ev eval evenp every evflag evfun evundiff +syn keyword maximaFunc example exp expand expandwrt expandwrt_denom expandwrt_factored +syn keyword maximaFunc explose expon exponentialize expop express expt exptdispflag +syn keyword maximaFunc exptisolate exptsubst extdiff extract_linear_equations ezgcd +syn keyword maximaFunc facexpand factcomb factlim factor factorflag factorial factorout +syn keyword maximaFunc factorsum facts false fast_central_elements fast_linsolve +syn keyword maximaFunc fasttimes fb feature featurep features fft fib fibtophi fifth +syn keyword maximaFunc filename_merge file_search file_search_demo file_search_lisp +syn keyword maximaFunc file_search_maxima file_type fillarray findde first fix flatten +syn keyword maximaFunc flipflag float float2bf floatnump flush flush1deriv flushd +syn keyword maximaFunc flushnd forget fortindent fortran fortspaces fourcos fourexpand +syn keyword maximaFunc fourier fourint fourintcos fourintsin foursimp foursin fourth +syn keyword maximaFunc fpprec fpprintprec frame_bracket freeof fullmap fullmapl +syn keyword maximaFunc fullratsimp fullratsubst funcsolve functions fundef funmake funp +syn keyword maximaFunc gamma %gamma gammalim gauss gcd gcdex gcfactor gdet genfact +syn keyword maximaFunc genindex genmatrix gensumnum get getchar gfactor gfactorsum +syn keyword maximaFunc globalsolve go gradef gradefs gramschmidt grind grobner_basis +syn keyword maximaFunc gschmit hach halfangles hermite hipow hodge horner i0 i1 +syn keyword maximaFunc *read-base* ic1 ic2 icc1 icc2 ic_convert ichr1 ichr2 icounter +syn keyword maximaFunc icurvature ident idiff idim idummy idummyx ieqn ieqnprint ifb +syn keyword maximaFunc ifc1 ifc2 ifg ifgi ifr iframe_bracket_form iframes ifri ift +syn keyword maximaFunc igeodesic_coords igeowedge_flag ikt1 ikt2 ilt imagpart imetric +syn keyword maximaFunc inchar indexed_tensor indices inf %inf infeval infinity infix +syn keyword maximaFunc inflag infolists init_atensor init_ctensor inm inmc1 inmc2 +syn keyword maximaFunc innerproduct in_netmath inpart inprod inrt integerp integrate +syn keyword maximaFunc integrate_use_rootsof integration_constant_counter interpolate +syn keyword maximaFunc intfaclim intopois intosum intpolabs intpolerror intpolrel +syn keyword maximaFunc invariant1 invariant2 inverse_jacobi_cd inverse_jacobi_cn +syn keyword maximaFunc inverse_jacobi_cs inverse_jacobi_dc inverse_jacobi_dn +syn keyword maximaFunc inverse_jacobi_ds inverse_jacobi_nc inverse_jacobi_nd +syn keyword maximaFunc inverse_jacobi_ns inverse_jacobi_sc inverse_jacobi_sd +syn keyword maximaFunc inverse_jacobi_sn invert is ishow isolate isolate_wrt_times +syn keyword maximaFunc isqrt itr j0 j1 jacobi jacobi_cd jacobi_cn jacobi_cs jacobi_dc +syn keyword maximaFunc jacobi_dn jacobi_ds jacobi_nc jacobi_nd jacobi_ns jacobi_sc +syn keyword maximaFunc jacobi_sd jacobi_sn jn kdels kdelta keepfloat kill killcontext +syn keyword maximaFunc kinvariant kostka kt labels lambda laplace lassociative last +syn keyword maximaFunc lc2kdt lc_l lcm lc_u ldefint ldisp ldisplay leinstein length +syn keyword maximaFunc let letrat let_rule_packages letrules letsimp levi_civita lfg +syn keyword maximaFunc lfreeof lg lgtreillis lhospitallim lhs liediff limit limsubst +syn keyword maximaFunc linear linechar linel linenum linsolve linsolve_params +syn keyword maximaFunc linsolvewarn listarith listarray listconstvars listdummyvars +syn keyword maximaFunc list_nc_monomials listoftens listofvars listp lmxchar load +syn keyword maximaFunc loadfile loadprint local log logabs logarc logconcoeffp +syn keyword maximaFunc logcontract logexpand lognegint lognumer logsimp lopow +syn keyword maximaFunc lorentz_gauge lpart lratsubst lriem lriemann lsum ltreillis +syn keyword maximaFunc m1pbranch macroexpansion mainvar make_array makebox makefact +syn keyword maximaFunc makegamma makelist make_random_state make_transform map mapatom +syn keyword maximaFunc maperror maplist matchdeclare matchfix matrix matrix_element_add +syn keyword maximaFunc matrix_element_mult matrix_element_transpose matrixmap matrixp +syn keyword maximaFunc mattrace max maxapplydepth maxapplyheight maxnegex maxposex +syn keyword maximaFunc maxtayorder member min %minf minfactorial minor mod +syn keyword maximaFunc mode_check_errorp mode_checkp mode_check_warnp mode_declare +syn keyword maximaFunc mode_identity modulus mon2schur mono monomial_dimensions +syn keyword maximaFunc multi_elem multinomial multi_orbit multiplicative multiplicities +syn keyword maximaFunc multi_pui multsym multthru myoptions nc_degree ncexpt ncharpoly +syn keyword maximaFunc negdistrib negsumdispflag newcontext newdet newton niceindices +syn keyword maximaFunc niceindicespref ninth nm nmc noeval nolabels nonmetricity +syn keyword maximaFunc nonscalar nonscalarp noun noundisp nounify nouns np npi +syn keyword maximaFunc nptetrad nroots nterms ntermst nthroot ntrig num numberp numer +syn keyword maximaFunc numerval numfactor nusum obase oddp ode2 op openplot_curves +syn keyword maximaFunc operatorp opproperties opsubst optimize optimprefix optionset +syn keyword maximaFunc orbit ordergreat ordergreatp orderless orderlessp outative +syn keyword maximaFunc outchar outermap outofpois packagefile pade part part2cont +syn keyword maximaFunc partfrac partition partpol partswitch permanent permut petrov +syn keyword maximaFunc pfeformat pi pickapart piece playback plog plot2d plot2d_ps +syn keyword maximaFunc plot3d plot_options poisdiff poisexpt poisint poislim poismap +syn keyword maximaFunc poisplus poissimp poisson poissubst poistimes poistrim polarform +syn keyword maximaFunc polartorect polynome2ele posfun potential powerdisp powers +syn keyword maximaFunc powerseries pred prederror primep print printpois printprops +syn keyword maximaFunc prodhack prodrac product programmode prompt properties props +syn keyword maximaFunc propvars pscom psdraw_curve psexpand psi pui pui2comp pui2ele +syn keyword maximaFunc pui2polynome pui_direct puireduc put qput qq quad_qag quad_qagi +syn keyword maximaFunc quad_qags quad_qawc quad_qawf quad_qawo quad_qaws quanc8 quit +syn keyword maximaFunc qunit quotient radcan radexpand radsubstflag random rank +syn keyword maximaFunc rassociative rat ratalgdenom ratchristof ratcoef ratdenom +syn keyword maximaFunc ratdenomdivide ratdiff ratdisrep rateinstein ratepsilon ratexpand +syn keyword maximaFunc ratfac ratmx ratnumer ratnump ratp ratprint ratriemann ratsimp +syn keyword maximaFunc ratsimpexpons ratsubst ratvars ratweight ratweights ratweyl +syn keyword maximaFunc ratwtlvl read readonly realonly realpart realroots rearray +syn keyword maximaFunc rectform recttopolar rediff refcheck rem remainder remarray +syn keyword maximaFunc rembox remcomps remcon remcoord remfun remfunction remlet +syn keyword maximaFunc remove remrule remsym remvalue rename reset residue resolvante +syn keyword maximaFunc resolvante_alternee1 resolvante_bipartite resolvante_diedrale +syn keyword maximaFunc resolvante_klein resolvante_klein3 resolvante_produit_sym +syn keyword maximaFunc resolvante_unitaire resolvante_vierer rest resultant return +syn keyword maximaFunc reveal reverse revert revert2 rhs ric ricci riem riemann +syn keyword maximaFunc rinvariant risch rmxchar rncombine %rnum_list romberg rombergabs +syn keyword maximaFunc rombergit rombergmin rombergtol room rootsconmode rootscontract +syn keyword maximaFunc rootsepsilon round row run_testsuite save savedef savefactors +syn keyword maximaFunc scalarmatrixp scalarp scalefactors scanmap schur2comp sconcat +syn keyword maximaFunc scsimp scurvature sec sech second setcheck setcheckbreak +syn keyword maximaFunc setelmx set_plot_option set_random_state setup_autoload +syn keyword maximaFunc set_up_dot_simplifications setval seventh sf show showcomps +syn keyword maximaFunc showratvars showtime sign signum similaritytransform simpsum +syn keyword maximaFunc simtran sin sinh sinnpiflag sixth solve solvedecomposes +syn keyword maximaFunc solveexplicit solvefactors solve_inconsistent_error solvenullwarn +syn keyword maximaFunc solveradcan solvetrigwarn somrac sort sparse spherical_bessel_j +syn keyword maximaFunc spherical_bessel_y spherical_hankel1 spherical_hankel2 +syn keyword maximaFunc spherical_harmonic splice sqfr sqrt sqrtdispflag sstatus +syn keyword maximaFunc stardisp status string stringout sublis sublis_apply_lambda +syn keyword maximaFunc sublist submatrix subst substinpart substpart subvarp sum +syn keyword maximaFunc sumcontract sumexpand sumhack sumsplitfact supcontext symbolp +syn keyword maximaFunc symmetric symmetricp system tan tanh taylor taylordepth +syn keyword maximaFunc taylorinfo taylor_logexpand taylor_order_coefficients taylorp +syn keyword maximaFunc taylor_simplifier taylor_truncate_polynomials taytorat tcl_output +syn keyword maximaFunc tcontract tellrat tellsimp tellsimpafter tensorkill tentex tenth +syn keyword maximaFunc tex %th third throw time timer timer_devalue timer_info +syn keyword maximaFunc tldefint tlimit tlimswitch todd_coxeter to_lisp totaldisrep +syn keyword maximaFunc totalfourier totient tpartpol tr trace trace_options +syn keyword maximaFunc transcompile translate translate_file transpose transrun +syn keyword maximaFunc tr_array_as_ref tr_bound_function_applyp treillis treinat +syn keyword maximaFunc tr_file_tty_messagesp tr_float_can_branch_complex +syn keyword maximaFunc tr_function_call_default triangularize trigexpand trigexpandplus +syn keyword maximaFunc trigexpandtimes triginverses trigrat trigreduce trigsign trigsimp +syn keyword maximaFunc tr_numer tr_optimize_max_loop tr_semicompile tr_state_vars true +syn keyword maximaFunc trunc truncate tr_warn_bad_function_calls tr_warn_fexpr +syn keyword maximaFunc tr_warnings_get tr_warn_meval tr_warn_mode tr_warn_undeclared +syn keyword maximaFunc tr_warn_undefined_variable tr_windy ttyoff ueivects ufg ug +syn keyword maximaFunc ultraspherical undiff uniteigenvectors unitvector unknown unorder +syn keyword maximaFunc unsum untellrat untimer untrace uric uricci uriem uriemann +syn keyword maximaFunc use_fast_arrays uvect values vect_cross vectorpotential +syn keyword maximaFunc vectorsimp verb verbify verbose weyl with_stdout writefile +syn keyword maximaFunc xgraph_curves xthru zerobern zeroequiv zeromatrix zeta zeta%pi +syn match maximaOp "[\*\/\+\-\#\!\~\^\=\:\<\>\@]" +" ---------------------- END LIST OF ALL FUNCTIONS (EXCEPT KEYWORDS) ---------------------- + + +syn case match + +" Labels (supports maxima's goto) +syn match maximaLabel "^\s*<[a-zA-Z_][a-zA-Z0-9%_]*>" + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match maximaSpecial contained "\\\d\d\d\|\\." +syn region maximaString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=maximaSpecial +syn match maximaCharacter "'[^\\]'" +syn match maximaSpecialChar "'\\.'" + +" number with no fractional part or exponent +syn match maximaNumber /\<\d\+\>/ +" floating point number with integer and fractional parts and optional exponent +syn match maximaFloat /\<\d\+\.\d*\([BbDdEeSs][-+]\=\d\+\)\=\>/ +" floating point number with no integer part and optional exponent +syn match maximaFloat /\<\.\d\+\([BbDdEeSs][-+]\=\d\+\)\=\>/ +" floating point number with no fractional part and optional exponent +syn match maximaFloat /\<\d\+[BbDdEeSs][-+]\=\d\+\>/ + +" Comments: +" maxima supports /* ... */ (like C) +syn keyword maximaTodo contained TODO Todo DEBUG +syn region maximaCommentBlock start="/\*" end="\*/" contains=maximaString,maximaTodo,maximaCommentBlock + +" synchronizing +syn sync match maximaSyncComment grouphere maximaCommentBlock "/*" +syn sync match maximaSyncComment groupthere NONE "*/" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link maximaBraceError maximaError +hi def link maximaCmd maximaStatement +hi def link maximaCurlyError maximaError +hi def link maximaFuncCmd maximaStatement +hi def link maximaParenError maximaError + +" The default methods for highlighting. Can be overridden later +hi def link maximaCharacter Character +hi def link maximaComma Function +hi def link maximaCommentBlock Comment +hi def link maximaConditional Conditional +hi def link maximaError Error +hi def link maximaFunc Delimiter +hi def link maximaOp Delimiter +hi def link maximaLabel PreProc +hi def link maximaNumber Number +hi def link maximaFloat Float +hi def link maximaRepeat Repeat +hi def link maximaSpecial Type +hi def link maximaSpecialChar SpecialChar +hi def link maximaStatement Statement +hi def link maximaString String +hi def link maximaTodo Todo + + +let b:current_syntax = "maxima" + +endif diff --git a/syntax/mel.vim b/syntax/mel.vim new file mode 100644 index 0000000..d00289d --- /dev/null +++ b/syntax/mel.vim @@ -0,0 +1,112 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MEL (Maya Extension Language) +" Maintainer: Robert Minsk +" Last Change: May 27 1999 +" Based on: Bram Moolenaar C syntax file + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" when wanted, highlight trailing white space and spaces before tabs +if exists("mel_space_errors") + sy match melSpaceError "\s\+$" + sy match melSpaceError " \+\t"me=e-1 +endif + +" A bunch of usefull MEL keyworks +sy keyword melBoolean true false yes no on off + +sy keyword melFunction proc +sy match melIdentifier "\$\(\a\|_\)\w*" + +sy keyword melStatement break continue return +sy keyword melConditional if else switch +sy keyword melRepeat while for do in +sy keyword melLabel case default +sy keyword melOperator size eval env exists whatIs +sy keyword melKeyword alias +sy keyword melException catch error warning + +sy keyword melInclude source + +sy keyword melType int float string vector matrix +sy keyword melStorageClass global + +sy keyword melDebug trace + +sy keyword melTodo contained TODO FIXME XXX + +" MEL data types +sy match melCharSpecial contained "\\[ntr\\"]" +sy match melCharError contained "\\[^ntr\\"]" + +sy region melString start=+"+ skip=+\\"+ end=+"+ contains=melCharSpecial,melCharError + +sy case ignore +sy match melInteger "\<\d\+\(e[-+]\=\d\+\)\=\>" +sy match melFloat "\<\d\+\(e[-+]\=\d\+\)\=f\>" +sy match melFloat "\<\d\+\.\d*\(e[-+]\=\d\+\)\=f\=\>" +sy match melFloat "\.\d\+\(e[-+]\=\d\+\)\=f\=\>" +sy case match + +sy match melCommaSemi contained "[,;]" +sy region melMatrixVector start=/<>/ contains=melInteger,melFloat,melIdentifier,melCommaSemi + +sy cluster melGroup contains=melFunction,melStatement,melConditional,melLabel,melKeyword,melStorageClass,melTODO,melCharSpecial,melCharError,melCommaSemi + +" catch errors caused by wrong parenthesis +sy region melParen transparent start='(' end=')' contains=ALLBUT,@melGroup,melParenError,melInParen +sy match melParenError ")" +sy match melInParen contained "[{}]" + +" comments +sy region melComment start="/\*" end="\*/" contains=melTodo,melSpaceError +sy match melComment "//.*" contains=melTodo,melSpaceError +sy match melCommentError "\*/" + +sy region melQuestionColon matchgroup=melConditional transparent start='?' end=':' contains=ALLBUT,@melGroup + +if !exists("mel_minlines") + let mel_minlines=15 +endif +exec "sy sync ccomment melComment minlines=" . mel_minlines + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link melBoolean Boolean +hi def link melFunction Function +hi def link melIdentifier Identifier +hi def link melStatement Statement +hi def link melConditional Conditional +hi def link melRepeat Repeat +hi def link melLabel Label +hi def link melOperator Operator +hi def link melKeyword Keyword +hi def link melException Exception +hi def link melInclude Include +hi def link melType Type +hi def link melStorageClass StorageClass +hi def link melDebug Debug +hi def link melTodo Todo +hi def link melCharSpecial SpecialChar +hi def link melString String +hi def link melInteger Number +hi def link melFloat Float +hi def link melMatrixVector Float +hi def link melComment Comment +hi def link melError Error +hi def link melSpaceError melError +hi def link melCharError melError +hi def link melParenError melError +hi def link melInParen melError +hi def link melCommentError melError + + +let b:current_syntax = "mel" + +endif diff --git a/syntax/messages.vim b/syntax/messages.vim new file mode 100644 index 0000000..d524ae2 --- /dev/null +++ b/syntax/messages.vim @@ -0,0 +1,77 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: /var/log/messages file +" Maintainer: Yakov Lerner +" Latest Revision: 2008-06-29 +" Changes: 2008-06-29 support for RFC3339 tuimestamps James Vega +" 2016 Jan 19: messagesDate changed by Bram + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match messagesBegin display '^' nextgroup=messagesDate,messagesDateRFC3339 + +syn match messagesDate contained display '[[:lower:][:upper:]][[:lower:][:upper:]][[:lower:][:upper:]] [ 0-9]\d *' + \ nextgroup=messagesHour + +syn match messagesHour contained display '\d\d:\d\d:\d\d\s*' + \ nextgroup=messagesHost + +syn match messagesDateRFC3339 contained display '\d\{4}-\d\d-\d\d' + \ nextgroup=messagesRFC3339T + +syn match messagesRFC3339T contained display '\cT' + \ nextgroup=messagesHourRFC3339 + +syn match messagesHourRFC3339 contained display '\c\d\d:\d\d:\d\d\(\.\d\+\)\=\([+-]\d\d:\d\d\|Z\)' + \ nextgroup=messagesHost + +syn match messagesHost contained display '\S*\s*' + \ nextgroup=messagesLabel + +syn match messagesLabel contained display '\s*[^:]*:\s*' + \ nextgroup=messagesText contains=messagesKernel,messagesPID + +syn match messagesPID contained display '\[\zs\d\+\ze\]' + +syn match messagesKernel contained display 'kernel:' + + +syn match messagesIP '\d\+\.\d\+\.\d\+\.\d\+' + +syn match messagesURL '\w\+://\S\+' + +syn match messagesText contained display '.*' + \ contains=messagesNumber,messagesIP,messagesURL,messagesError + +syn match messagesNumber contained '0x[0-9a-fA-F]*\|\[<[0-9a-f]\+>\]\|\<\d[0-9a-fA-F]*' + +syn match messagesError contained '\c.*\<\(FATAL\|ERROR\|ERRORS\|FAILED\|FAILURE\).*' + + +hi def link messagesDate Constant +hi def link messagesHour Type +hi def link messagesDateRFC3339 Constant +hi def link messagesHourRFC3339 Type +hi def link messagesRFC3339T Normal +hi def link messagesHost Identifier +hi def link messagesLabel Operator +hi def link messagesPID Constant +hi def link messagesKernel Special +hi def link messagesError ErrorMsg +hi def link messagesIP Constant +hi def link messagesURL Underlined +hi def link messagesText Normal +hi def link messagesNumber Number + +let b:current_syntax = "messages" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/mf.vim b/syntax/mf.vim new file mode 100644 index 0000000..52425dc --- /dev/null +++ b/syntax/mf.vim @@ -0,0 +1,299 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: METAFONT +" Maintainer: Nicola Vitacolonna +" Former Maintainers: Andreas Scherer +" Last Change: 2016 Oct 1 + +if exists("b:current_syntax") + finish +endif + +syn iskeyword @,_ + +" METAFONT 'primitives' as defined in chapter 25 of 'The METAFONTbook' +" Page 210: 'boolean expressions' +syn keyword mfBoolExp and charexists false known not odd or true unknown + +" Page 210: 'numeric expression' +syn keyword mfNumExp ASCII angle cosd directiontime floor hex length +syn keyword mfNumExp mexp mlog normaldeviate oct sind sqrt totalweight +syn keyword mfNumExp turningnumber uniformdeviate xpart xxpart xypart +syn keyword mfNumExp ypart yxpart yypart + +" Page 211: 'internal quantities' +syn keyword mfInternal autorounding boundarychar charcode chardp chardx +syn keyword mfInternal chardy charext charht charic charwd day designsize +syn keyword mfInternal fillin fontmaking granularity hppp jobname month +syn keyword mfInternal pausing proofing showstopping smoothing time +syn keyword mfInternal tracingcapsules tracingchoices tracingcommands +syn keyword mfInternal tracingedges tracingequations tracingmacros +syn keyword mfInternal tracingonline tracingoutput tracingpens +syn keyword mfInternal tracingrestores tracingspecs tracingstats +syn keyword mfInternal tracingtitles turningcheck vppp warningcheck +syn keyword mfInternal xoffset year yoffset + +" Page 212: 'pair expressions' +syn keyword mfPairExp of penoffset point postcontrol precontrol rotated +syn keyword mfPairExp scaled shifted slanted transformed xscaled yscaled +syn keyword mfPairExp zscaled + +" Page 213: 'path expressions' +syn keyword mfPathExp atleast controls curl cycle makepath reverse +syn keyword mfPathExp subpath tension + +" Page 214: 'pen expressions' +syn keyword mfPenExp makepen nullpen pencircle + +" Page 214: 'picture expressions' +syn keyword mfPicExp nullpicture + +" Page 214: 'string expressions' +syn keyword mfStringExp char decimal readstring str substring + +" Page 217: 'commands and statements' +syn keyword mfCommand addto also at batchmode contour cull delimiters +syn keyword mfCommand display doublepath dropping dump end errhelp +syn keyword mfCommand errmessage errorstopmode everyjob from interim +syn keyword mfCommand inwindow keeping let message newinternal +syn keyword mfCommand nonstopmode numspecial openwindow outer randomseed +syn keyword mfCommand save scrollmode shipout show showdependencies +syn keyword mfCommand showstats showtoken showvariable special to withpen +syn keyword mfCommand withweight + +" Page 56: 'types' +syn keyword mfType boolean numeric pair path pen picture string +syn keyword mfType transform + +" Page 155: 'grouping' +syn keyword mfStatement begingroup endgroup + +" Page 165: 'definitions' +syn keyword mfDefinition def enddef expr primary primarydef secondary +syn keyword mfDefinition secondarydef suffix tertiary tertiarydef text +syn keyword mfDefinition vardef + +" Page 169: 'conditions and loops' +syn keyword mfCondition else elseif endfor exitif fi for forever +syn keyword mfCondition forsuffixes if step until + +" Other primitives listed in the index +syn keyword mfPrimitive charlist endinput expandafter extensible fontdimen +syn keyword mfPrimitive headerbyte inner input intersectiontimes kern +syn keyword mfPrimitive ligtable quote scantokens skipto + +" Implicit suffix parameters +syn match mfSuffixParam "@#\|#@\|@" + +" These are just tags, but given their special status, we +" highlight them as variables +syn keyword mfVariable x y + +" Keywords defined by plain.mf (defined on pp.262-278) +if get(g:, "plain_mf_macros", 1) + syn keyword mfDef addto_currentpicture beginchar capsule_def + syn keyword mfDef change_width clear_pen_memory clearit clearpen + syn keyword mfDef clearxy culldraw cullit cutdraw + syn keyword mfDef define_blacker_pixels define_corrected_pixels + syn keyword mfDef define_good_x_pixels define_good_y_pixels + syn keyword mfDef define_horizontal_corrected_pixels define_pixels + syn keyword mfDef define_whole_blacker_pixels define_whole_pixels + syn keyword mfDef define_whole_vertical_blacker_pixels + syn keyword mfDef define_whole_vertical_pixels downto draw drawdot + syn keyword mfDef endchar erase exitunless fill filldraw fix_units + syn keyword mfDef flex font_coding_scheme font_extra_space + syn keyword mfDef font_identifier font_normal_shrink + syn keyword mfDef font_normal_space font_normal_stretch font_quad + syn keyword mfDef font_size font_slant font_x_height gfcorners gobble + syn keyword mfDef hide imagerules interact italcorr killtext + syn keyword mfDef loggingall lowres_fix makebox makegrid maketicks + syn keyword mfDef mode_def mode_setup nodisplays notransforms numtok + syn keyword mfDef openit penrazor pensquare penstroke pickup + syn keyword mfDef proofoffset proofrule range reflectedabout + syn keyword mfDef rotatedaround screenchars screenrule screenstrokes + syn keyword mfDef shipit showit smode stop superellipse takepower + syn keyword mfDef tracingall tracingnone undraw undrawdot unfill + syn keyword mfDef unfilldraw upto z + syn match mfDef "???" + syn keyword mfVardef bot byte ceiling counterclockwise cutoff decr dir + syn keyword mfVardef direction directionpoint grayfont hround incr + syn keyword mfVardef interpath inverse labelfont labels lft magstep + " Note: nodot is not a vardef, it is used as in makelabel.lft.nodot("5",z5) + " (METAFONT only) + syn keyword mfVardef makelabel max min nodot penlabels penpos + syn keyword mfVardef proofrulethickness round rt savepen slantfont solve + syn keyword mfVardef tensepath titlefont top unitvector vround whatever + syn match mpVardef "\" + syn keyword mfPrimaryDef div dotprod gobbled mod + syn keyword mfSecondaryDef intersectionpoint + syn keyword mfTertiaryDef softjoin thru + syn keyword mfNewInternal blacker currentwindow displaying eps epsilon + syn keyword mfNewInternal infinity join_radius number_of_modes o_correction + syn keyword mfNewInternal pen_bot pen_lft pen_rt pen_top pixels_per_inch + syn keyword mfNewInternal screen_cols screen_rows tolerance + " Predefined constants + syn keyword mfConstant base_name base_version blankpicture ditto down + syn keyword mfConstant fullcircle halfcircle identity left lowres origin + syn keyword mfConstant penspeck proof quartercircle right rulepen smoke + syn keyword mfConstant unitpixel unitsquare up + " Other predefined variables + syn keyword mfVariable aspect_ratio currentpen extra_beginchar + syn keyword mfVariable extra_endchar currentpen_path currentpicture + syn keyword mfVariable currenttransform d extra_setup h localfont mag mode + syn keyword mfVariable mode_name w + " let statements: + syn keyword mfnumExp abs + syn keyword mfPairExp rotatedabout + syn keyword mfCommand bye relax +endif + +" By default, METAFONT loads modes.mf, too +if get(g:, "plain_mf_modes", 1) + syn keyword mfConstant APSSixMed AgfaFourZeroZero AgfaThreeFourZeroZero + syn keyword mfConstant AtariNineFive AtariNineSix AtariSLMEightZeroFour + syn keyword mfConstant AtariSMOneTwoFour CItohEightFiveOneZero + syn keyword mfConstant CItohThreeOneZero CanonBJCSixZeroZero CanonCX + syn keyword mfConstant CanonEX CanonLBPLX CanonLBPTen CanonSX ChelgraphIBX + syn keyword mfConstant CompugraphicEightSixZeroZero + syn keyword mfConstant CompugraphicNineSixZeroZero DD DEClarge DECsmall + syn keyword mfConstant DataDiscNew EightThree EpsonAction + syn keyword mfConstant EpsonLQFiveZeroZeroLo EpsonLQFiveZeroZeroMed + syn keyword mfConstant EpsonMXFX EpsonSQEightSevenZero EpsonStylusPro + syn keyword mfConstant EpsonStylusProHigh EpsonStylusProLow + syn keyword mfConstant EpsonStylusProMed FourFour GThreefax HPDeskJet + syn keyword mfConstant HPLaserJetIIISi IBMFourTwoFiveZero IBMFourTwoOneSix + syn keyword mfConstant IBMFourTwoThreeZero IBMFourZeroOneNine + syn keyword mfConstant IBMFourZeroThreeNine IBMFourZeroTwoNine + syn keyword mfConstant IBMProPrinter IBMSixOneFiveFour IBMSixSixSevenZero + syn keyword mfConstant IBMThreeEightOneTwo IBMThreeEightTwoZero + syn keyword mfConstant IBMThreeOneNineThree IBMThreeOneSevenNine + syn keyword mfConstant IBMUlfHolleberg LASevenFive LNOthreR LNOthree + syn keyword mfConstant LNZeroOne LNZeroThree LPSFourZero LPSTwoZero + syn keyword mfConstant LexmarkFourZeroThreeNine LexmarkOptraR + syn keyword mfConstant LexmarkOptraS LinotypeLThreeThreeZero + syn keyword mfConstant LinotypeOneZeroZero LinotypeOneZeroZeroLo + syn keyword mfConstant LinotypeThreeZeroZeroHi MacTrueSize NeXTprinter + syn keyword mfConstant NeXTscreen NecTwoZeroOne Newgen NineOne + syn keyword mfConstant OCESixSevenFiveZeroPS OneTwoZero OneZeroZero + syn keyword mfConstant PrintwareSevenTwoZeroIQ Prism QMSOneSevenTwoFive + syn keyword mfConstant QMSOneSevenZeroZero QMSTwoFourTwoFive RicohA + syn keyword mfConstant RicohFortyEighty RicohFourZeroEightZero RicohLP + syn keyword mfConstant SparcPrinter StarNLOneZero VAXstation VTSix + syn keyword mfConstant VarityperFiveZeroSixZeroW + syn keyword mfConstant VarityperFourThreeZeroZeroHi + syn keyword mfConstant VarityperFourThreeZeroZeroLo + syn keyword mfConstant VarityperFourTwoZeroZero VarityperSixZeroZero + syn keyword mfConstant XeroxDocutech XeroxEightSevenNineZero + syn keyword mfConstant XeroxFourZeroFiveZero XeroxNineSevenZeroZero + syn keyword mfConstant XeroxPhaserSixTwoZeroZeroDP XeroxThreeSevenZeroZero + syn keyword mfConstant Xerox_world agfafzz agfatfzz amiga aps apssixhi + syn keyword mfConstant aselect atariezf atarinf atarins atariotf bitgraph + syn keyword mfConstant bjtenex bjtzzex bjtzzl bjtzzs boise canonbjc + syn keyword mfConstant canonex canonlbp cg cgl cgnszz citohtoz corona crs + syn keyword mfConstant cthreeten cx datadisc declarge decsmall deskjet + syn keyword mfConstant docutech dover dp dpdfezzz eighthre elvira epscszz + syn keyword mfConstant epsdraft epsdrft epsdrftl epsfast epsfastl epshi + syn keyword mfConstant epslo epsmed epsmedl epson epsonact epsonfx epsonl + syn keyword mfConstant epsonlo epsonlol epsonlq epsonsq epstylus epstylwr + syn keyword mfConstant epstyplo epstypmd epstypml epstypro epswlo epswlol + syn keyword mfConstant esphi fourfour gpx gtfax gtfaxhi gtfaxl gtfaxlo + syn keyword mfConstant gtfaxlol help hifax highfax hplaser hprugged ibm_a + syn keyword mfConstant ibmd ibmega ibmegal ibmfzon ibmfztn ibmpp ibmppl + syn keyword mfConstant ibmsoff ibmteot ibmtetz ibmtont ibmtosn ibmtosnl + syn keyword mfConstant ibmvga ibx imagen imagewriter itoh itohl itohtoz + syn keyword mfConstant itohtozl iw jetiiisi kyocera laserjet laserjetfive + syn keyword mfConstant laserjetfivemp laserjetfour laserjetfourthousand + syn keyword mfConstant laserjetfourzerozerozero laserjethi laserjetlo + syn keyword mfConstant laserjettwoonezerozero + syn keyword mfConstant laserjettwoonezerozerofastres lasermaster + syn keyword mfConstant laserwriter lasf lexmarkr lexmarks lexmarku + syn keyword mfConstant linohalf linohi linolo linolttz linoone linosuper + syn keyword mfConstant linothree linothreelo linotzzh ljfive ljfivemp + syn keyword mfConstant ljfour ljfzzz ljfzzzfr ljlo ljtozz ljtozzfr lmaster + syn keyword mfConstant lnotr lnzo lps lpstz lqhires lqlores lqmed lqmedl + syn keyword mfConstant lqmedres lview lviewl lwpro macmag mactrue modes_mf + syn keyword mfConstant ncd nec nechi neclm nectzo newdd newddl nexthi + syn keyword mfConstant nextscreen nextscrn nineone nullmode ocessfz + syn keyword mfConstant okidata okidatal okifourten okifte okihi onetz + syn keyword mfConstant onezz pcprevw pcscreen phaser phaserfs phasertf + syn keyword mfConstant phasertfl phasertl pixpt printware prntware + syn keyword mfConstant proprinter qms qmsesz qmsostf qmsoszz qmstftf ricoh + syn keyword mfConstant ricoha ricohlp ricohsp sherpa sparcptr starnlt + syn keyword mfConstant starnltl styletwo stylewr stylewri stylewriter sun + syn keyword mfConstant supre swtwo toshiba ultre varityper vs vtftzz + syn keyword mfConstant vtftzzhi vtftzzlo vtfzszw vtszz xpstzz xpstzzl + syn keyword mfConstant xrxesnz xrxfzfz xrxnszz xrxtszz + syn keyword mfDef BCPL_string coding_scheme font_face_byte + syn keyword mfDef font_family landscape + syn keyword mfDef mode_extra_info mode_help mode_param + syn keyword mfNewInternal blacker_min +endif + +" Some other basic macro names, e.g., from cmbase, logo, etc. +if get(g:, "other_mf_macros", 1) + syn keyword mfDef beginlogochar + syn keyword mfDef font_setup + syn keyword mfPrimitive generate +endif + +" Numeric tokens +syn match mfNumeric "[-]\=\d\+" +syn match mfNumeric "[-]\=\.\d\+" +syn match mfNumeric "[-]\=\d\+\.\d\+" + +" METAFONT lengths +syn match mfLength "\<\(bp\|cc\|cm\|dd\|in\|mm\|pc\|pt\)\>" +syn match mfLength "[-]\=\d\+\(bp\|cc\|cm\|dd\|in\|mm\|pc\|pt\)\#\=" +syn match mfLength "[-]\=\.\d\+\(bp\|cc\|cm\|dd\|in\|mm\|pc\|pt\)\#\=" +syn match mfLength "[-]\=\d\+\.\d\+\(bp\|cc\|cm\|dd\|in\|mm\|pc\|pt\)\#\=" + +" String constants +syn match mfOpenString /"[^"]*/ +syn region mfString oneline keepend start=+"+ end=+"+ + +" Comments: +syn keyword mfTodoComment contained TODO FIXME XXX DEBUG NOTE +syn match mfComment "%.*$" contains=mfTodoComment,@Spell + +" synchronizing +syn sync maxlines=50 + +" Define the default highlighting +hi def link mfBoolExp Statement +hi def link mfNumExp Statement +hi def link mfPairExp Statement +hi def link mfPathExp Statement +hi def link mfPenExp Statement +hi def link mfPicExp Statement +hi def link mfStringExp Statement +hi def link mfInternal Identifier +hi def link mfCommand Statement +hi def link mfType Type +hi def link mfStatement Statement +hi def link mfDefinition Statement +hi def link mfCondition Conditional +hi def link mfPrimitive Statement +hi def link mfDef Function +hi def link mfVardef mfDef +hi def link mfPrimaryDef mfDef +hi def link mfSecondaryDef mfDef +hi def link mfTertiaryDef mfDef +hi def link mfCoord Identifier +hi def link mfPoint Identifier +hi def link mfNumeric Number +hi def link mfLength Number +hi def link mfComment Comment +hi def link mfString String +hi def link mfOpenString Todo +hi def link mfSuffixParam Label +hi def link mfNewInternal mfInternal +hi def link mfVariable Identifier +hi def link mfConstant Constant +hi def link mfTodoComment Todo + +let b:current_syntax = "mf" + +" vim:sw=2 + +endif diff --git a/syntax/mgl.vim b/syntax/mgl.vim new file mode 100644 index 0000000..d4a046e --- /dev/null +++ b/syntax/mgl.vim @@ -0,0 +1,121 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MGL +" Version: 1.0 +" Last Change: 2006 Feb 21 +" Maintainer: Gero Kuhlmann +" +" $Id: mgl.vim,v 1.1 2006/02/21 22:08:20 vimboss Exp $ +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +syn sync lines=250 + +syn keyword mglBoolean true false +syn keyword mglConditional if else then +syn keyword mglConstant nil +syn keyword mglPredefined maxint +syn keyword mglLabel case goto label +syn keyword mglOperator to downto in of with +syn keyword mglOperator and not or xor div mod +syn keyword mglRepeat do for repeat while to until +syn keyword mglStatement procedure function break continue return restart +syn keyword mglStatement program begin end const var type +syn keyword mglStruct record +syn keyword mglType integer string char boolean char ipaddr array + + +" String +if !exists("mgl_one_line_string") + syn region mglString matchgroup=mglString start=+'+ end=+'+ contains=mglStringEscape + syn region mglString matchgroup=mglString start=+"+ end=+"+ contains=mglStringEscapeGPC +else + "wrong strings + syn region mglStringError matchgroup=mglStringError start=+'+ end=+'+ end=+$+ contains=mglStringEscape + syn region mglStringError matchgroup=mglStringError start=+"+ end=+"+ end=+$+ contains=mglStringEscapeGPC + "right strings + syn region mglString matchgroup=mglString start=+'+ end=+'+ oneline contains=mglStringEscape + syn region mglString matchgroup=mglString start=+"+ end=+"+ oneline contains=mglStringEscapeGPC +end +syn match mglStringEscape contained "''" +syn match mglStringEscapeGPC contained '""' + + +if exists("mgl_symbol_operator") + syn match mglSymbolOperator "[+\-/*=\%]" + syn match mglSymbolOperator "[<>]=\=" + syn match mglSymbolOperator "<>" + syn match mglSymbolOperator ":=" + syn match mglSymbolOperator "[()]" + syn match mglSymbolOperator "\.\." + syn match mglMatrixDelimiter "(." + syn match mglMatrixDelimiter ".)" + syn match mglMatrixDelimiter "[][]" +endif + +syn match mglNumber "-\=\<\d\+\>" +syn match mglHexNumber "\$[0-9a-fA-F]\+\>" +syn match mglCharacter "\#[0-9]\+\>" +syn match mglIpAddr "[0-9]\+\.[0-9]\+\.[0-9]\+\.[0-9]\+\>" + +syn region mglComment start="(\*" end="\*)" +syn region mglComment start="{" end="}" +syn region mglComment start="//" end="$" + +if !exists("mgl_no_functions") + syn keyword mglFunction dispose new + syn keyword mglFunction get load print select + syn keyword mglFunction odd pred succ + syn keyword mglFunction chr ord abs sqr + syn keyword mglFunction exit + syn keyword mglOperator at timeout +endif + + +syn region mglPreProc start="(\*\$" end="\*)" +syn region mglPreProc start="{\$" end="}" + +syn keyword mglException try except raise +syn keyword mglPredefined exception + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link mglBoolean Boolean +hi def link mglComment Comment +hi def link mglConditional Conditional +hi def link mglConstant Constant +hi def link mglException Exception +hi def link mglFunction Function +hi def link mglLabel Label +hi def link mglMatrixDelimiter Identifier +hi def link mglNumber Number +hi def link mglHexNumber Number +hi def link mglCharacter Number +hi def link mglIpAddr Number +hi def link mglOperator Operator +hi def link mglPredefined mglFunction +hi def link mglPreProc PreProc +hi def link mglRepeat Repeat +hi def link mglStatement Statement +hi def link mglString String +hi def link mglStringEscape Special +hi def link mglStringEscapeGPC Special +hi def link mglStringError Error +hi def link mglStruct mglStatement +hi def link mglSymbolOperator mglOperator +hi def link mglType Type + + + +let b:current_syntax = "mgl" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/mgp.vim b/syntax/mgp.vim new file mode 100644 index 0000000..afe5885 --- /dev/null +++ b/syntax/mgp.vim @@ -0,0 +1,73 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: mgp - MaGic Point +" Maintainer: Gerfried Fuchs +" Filenames: *.mgp +" Last Change: 25 Apr 2001 +" URL: http://alfie.ist.org/vim/syntax/mgp.vim +" +" Comments are very welcome - but please make sure that you are commenting on +" the latest version of this file. +" SPAM is _NOT_ welcome - be ready to be reported! + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +syn match mgpLineSkip "\\$" + +" all the commands that are currently recognized +syn keyword mgpCommand contained size fore back bgrad left leftfill center +syn keyword mgpCommand contained right shrink lcutin rcutin cont xfont vfont +syn keyword mgpCommand contained tfont tmfont tfont0 bar image newimage +syn keyword mgpCommand contained prefix icon bimage default tab vgap hgap +syn keyword mgpCommand contained pause mark again system filter endfilter +syn keyword mgpCommand contained vfcap tfdir deffont font embed endembed +syn keyword mgpCommand contained noop pcache include + +" charset is not yet supported :-) +" syn keyword mgpCommand contained charset + +syn region mgpFile contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match mgpValue contained "\d\+" +syn match mgpSize contained "\d\+x\d\+" +syn match mgpLine +^%.*$+ contains=mgpCommand,mgpFile,mgpSize,mgpValue + +" Comments +syn match mgpPercent +^%%.*$+ +syn match mgpHash +^#.*$+ + +" these only work alone +syn match mgpPage +^%page$+ +syn match mgpNoDefault +^%nodefault$+ + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link mgpLineSkip Special + +hi def link mgpHash mgpComment +hi def link mgpPercent mgpComment +hi def link mgpComment Comment + +hi def link mgpCommand Identifier + +hi def link mgpLine Type + +hi def link mgpFile String +hi def link mgpSize Number +hi def link mgpValue Number + +hi def link mgpPage mgpDefine +hi def link mgpNoDefault mgpDefine +hi def link mgpDefine Define + + +let b:current_syntax = "mgp" + +endif diff --git a/syntax/mib.vim b/syntax/mib.vim new file mode 100644 index 0000000..79b12a7 --- /dev/null +++ b/syntax/mib.vim @@ -0,0 +1,61 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Vim syntax file for SNMPv1 and SNMPv2 MIB and SMI files +" Maintainer: Martin Smat +" Original Author: David Pascoe +" Written: Wed Jan 28 14:37:23 GMT--8:00 1998 +" Last Changed: Mon Mar 23 2010 + +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=@,48-57,_,128-167,224-235,- + +syn keyword mibImplicit ACCESS ANY AUGMENTS BEGIN BIT BITS BOOLEAN CHOICE +syn keyword mibImplicit COMPONENTS CONTACT-INFO DEFINITIONS DEFVAL +syn keyword mibImplicit DESCRIPTION DISPLAY-HINT END ENTERPRISE EXTERNAL FALSE +syn keyword mibImplicit FROM GROUP IMPLICIT IMPLIED IMPORTS INDEX +syn keyword mibImplicit LAST-UPDATED MANDATORY-GROUPS MAX-ACCESS +syn keyword mibImplicit MIN-ACCESS MODULE MODULE-COMPLIANCE MODULE-IDENTITY +syn keyword mibImplicit NOTIFICATION-GROUP NOTIFICATION-TYPE NOTIFICATIONS +syn keyword mibImplicit NULL OBJECT-GROUP OBJECT-IDENTITY OBJECT-TYPE +syn keyword mibImplicit OBJECTS OF OPTIONAL ORGANIZATION REFERENCE +syn keyword mibImplicit REVISION SEQUENCE SET SIZE STATUS SYNTAX +syn keyword mibImplicit TEXTUAL-CONVENTION TRAP-TYPE TRUE UNITS VARIABLES +syn keyword mibImplicit WRITE-SYNTAX +syn keyword mibValue accessible-for-notify current DisplayString +syn keyword mibValue deprecated mandatory not-accessible obsolete optional +syn keyword mibValue read-create read-only read-write write-only INTEGER +syn keyword mibValue Counter Gauge IpAddress OCTET STRING experimental mib-2 +syn keyword mibValue TimeTicks RowStatus TruthValue UInteger32 snmpModules +syn keyword mibValue Integer32 Counter32 TestAndIncr TimeStamp InstancePointer +syn keyword mibValue OBJECT IDENTIFIER Gauge32 AutonomousType Counter64 +syn keyword mibValue PhysAddress TimeInterval MacAddress StorageType RowPointer +syn keyword mibValue TDomain TAddress ifIndex + +" Epilogue SMI extensions +syn keyword mibEpilogue FORCE-INCLUDE EXCLUDE cookie get-function set-function +syn keyword mibEpilogue test-function get-function-async set-function-async +syn keyword mibEpilogue test-function-async next-function next-function-async +syn keyword mibEpilogue leaf-name +syn keyword mibEpilogue DEFAULT contained + +syn match mibOperator "::=" +syn match mibComment "\ *--.\{-}\(--\|$\)" +syn match mibNumber "\<['0-9a-fA-FhH]*\>" +syn region mibDescription start="\"" end="\"" contains=DEFAULT + +hi def link mibImplicit Statement +hi def link mibOperator Statement +hi def link mibComment Comment +hi def link mibConstants String +hi def link mibNumber Number +hi def link mibDescription Identifier +hi def link mibEpilogue SpecialChar +hi def link mibValue Structure + +let b:current_syntax = "mib" + +endif diff --git a/syntax/mix.vim b/syntax/mix.vim new file mode 100644 index 0000000..0993793 --- /dev/null +++ b/syntax/mix.vim @@ -0,0 +1,87 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MIX (Donald Knuth's assembly language used in TAOCP) +" Maintainer: Wu Yongwei +" Filenames: *.mixal *.mix +" Last Change: 2013 Nov 13 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case ignore + +" Special processing of ALF directive: implementations vary whether quotation +" marks are needed +syn match mixAlfParam #\s\{1,2\}"\?[^"]\{,5\}"\?# contains=mixAlfDirective,mixString nextgroup=mixEndComment contained + +" Region for parameters +syn match mixParam #[-+*/:=0-9a-z,()"]\+# contains=mixIdentifier,mixSpecial,mixNumber,mixString,mixLabel nextgroup=mixEndComment contained + +" Comment at the line end +syn match mixEndComment ".*" contains=mixRegister contained + +" Identifier; must go before literals +syn match mixIdentifier "[a-z0-9_]\+" contained + +" Literals +syn match mixSpecial "[-+*/:=]" contained +syn match mixNumber "[0-9]\+\>" contained +syn region mixString start=+"+ skip=+\\"+ end=+"+ contained + +" Labels +syn match mixLabel "^[a-z0-9_]\{,10\}\s\+" nextgroup=mixAlfSpecial,mixOpcode,mixDirective +syn match mixLabel "[0-9][BF]" contained + +" Comments +syn match mixComment "^\*.*" contains=mixRegister + +" Directives +syn keyword mixDirective ORIG EQU CON END nextgroup=mixParam contained skipwhite +syn keyword mixDirective ALF nextgroup=mixAlfParam contained + +" Opcodes +syn keyword mixOpcode NOP HLT NUM CHAR FLOT FIX nextgroup=mixEndComment contained +syn keyword mixOpcode FADD FSUB FMUL FDIV FCMP MOVE ADD SUB MUL DIV IOC IN OUT JRED JBUS JMP JSJ JOV JNOV JL JE JG JLE JNE JGE SLA SRA SLAX SRAX SLC SRC nextgroup=mixParam contained skipwhite + +syn match mixOpcode "LD[AX1-6]N\?\>" nextgroup=mixParam contained skipwhite +syn match mixOpcode "ST[AX1-6JZ]\>" nextgroup=mixParam contained skipwhite +syn match mixOpcode "EN[TN][AX1-6]\>" nextgroup=mixParam contained skipwhite +syn match mixOpcode "INC[AX1-6]\>" nextgroup=mixParam contained skipwhite +syn match mixOpcode "DEC[AX1-6]\>" nextgroup=mixParam contained skipwhite +syn match mixOpcode "CMP[AX1-6]\>" nextgroup=mixParam contained skipwhite +syn match mixOpcode "J[AX1-6]N\?[NZP]\>" nextgroup=mixParam contained skipwhite + +" Switch back to being case sensitive +syn case match + +" Registers (only to used in comments now) +syn keyword mixRegister rA rX rI1 rI2 rI3 rI4 rI5 rI6 rJ contained + +" The default highlighting +hi def link mixRegister Special +hi def link mixLabel Define +hi def link mixComment Comment +hi def link mixEndComment Comment +hi def link mixDirective Keyword +hi def link mixOpcode Keyword + +hi def link mixSpecial Special +hi def link mixNumber Number +hi def link mixString String +hi def link mixAlfParam String +hi def link mixIdentifier Identifier + +let b:current_syntax = "mix" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/mma.vim b/syntax/mma.vim index ceba976..0850e0b 100644 --- a/syntax/mma.vim +++ b/syntax/mma.vim @@ -1,3 +1,328 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Mathematica +" Maintainer: steve layland +" Last Change: 2012 Feb 03 by Thilo Six +" Source: http://members.wri.com/layland/vim/syntax/mma.vim +" http://vim.sourceforge.net/scripts/script.php?script_id=1273 +" Id: $Id: mma.vim,v 1.4 2006/04/14 20:40:38 vimboss Exp $ +" NOTE: +" +" Empty .m files will automatically be presumed as Matlab files +" unless you have the following in your .vimrc: +" +" let filetype_m="mma" +" +" I also recommend setting the default 'Comment' hilighting to something +" other than the color used for 'Function', since both are plentiful in +" most mathematica files, and they are often the same color (when using +" background=dark). +" +" Credits: +" o Original Mathematica syntax version written by +" Wolfgang Waltenberger +" o Some ideas like the CommentStar,CommentTitle were adapted +" from the Java vim syntax file by Claudio Fleiner. Thanks! +" o Everything else written by steve +" +" Bugs: +" o Vim 6.1 didn't really have support for character classes +" of other named character classes. For example, [\a\d] +" didn't work. Therefore, a lot of this code uses explicit +" character classes instead: [0-9a-zA-Z] +" +" TODO: +" folding +" fix nesting +" finish populating popular symbols + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Group Definitions: +syntax cluster mmaNotes contains=mmaTodo,mmaFixme +syntax cluster mmaComments contains=mmaComment,mmaFunctionComment,mmaItem,mmaFunctionTitle,mmaCommentStar +syntax cluster mmaCommentStrings contains=mmaLooseQuote,mmaCommentString,mmaUnicode +syntax cluster mmaStrings contains=@mmaCommentStrings,mmaString +syntax cluster mmaTop contains=mmaOperator,mmaGenericFunction,mmaPureFunction,mmaVariable + +" Predefined Constants: +" to list all predefined Symbols would be too insane... +" it's probably smarter to define a select few, and get the rest from +" context if absolutely necessary. +" TODO - populate this with other often used Symbols + +" standard fixed symbols: +syntax keyword mmaVariable True False None Automatic All Null C General + +" mathematical constants: +syntax keyword mmaVariable Pi I E Infinity ComplexInfinity Indeterminate GoldenRatio EulerGamma Degree Catalan Khinchin Glaisher + +" stream data / atomic heads: +syntax keyword mmaVariable Byte Character Expression Number Real String Word EndOfFile Integer Symbol + +" sets: +syntax keyword mmaVariable Integers Complexes Reals Booleans Rationals + +" character classes: +syntax keyword mmaPattern DigitCharacter LetterCharacter WhitespaceCharacter WordCharacter EndOfString StartOfString EndOfLine StartOfLine WordBoundary + +" SelectionMove directions/units: +syntax keyword mmaVariable Next Previous After Before Character Word Expression TextLine CellContents Cell CellGroup EvaluationCell ButtonCell GeneratedCell Notebook +syntax keyword mmaVariable CellTags CellStyle CellLabel + +" TableForm positions: +syntax keyword mmaVariable Above Below Left Right + +" colors: +syntax keyword mmaVariable Black Blue Brown Cyan Gray Green Magenta Orange Pink Purple Red White Yellow + +" function attributes +syntax keyword mmaVariable Protected Listable OneIdentity Orderless Flat Constant NumericFunction Locked ReadProtected HoldFirst HoldRest HoldAll HoldAllComplete SequenceHold NHoldFirst NHoldRest NHoldAll Temporary Stub + +" Comment Sections: +" this: +" :that: +syntax match mmaItem "\%(^[( |*\t]*\)\@<=\%(:\+\|\w\)\w\+\%( \w\+\)\{0,3}:" contained contains=@mmaNotes + +" Comment Keywords: +syntax keyword mmaTodo TODO NOTE HEY contained +syntax match mmaTodo "X\{3,}" contained +syntax keyword mmaFixme FIX[ME] FIXTHIS BROKEN contained +syntax match mmaFixme "BUG\%( *\#\=[0-9]\+\)\=" contained +" yay pirates... +syntax match mmaFixme "\%(Y\=A\+R\+G\+\|GRR\+\|CR\+A\+P\+\)\%(!\+\)\=" contained + +" EmPHAsis: +" this unnecessary, but whatever :) +syntax match mmaemPHAsis "\%(^\|\s\)\([_/]\)[a-zA-Z0-9]\+\%([- \t':]\+[a-zA-Z0-9]\+\)*\1\%(\s\|$\)" contained contains=mmaemPHAsis +syntax match mmaemPHAsis "\%(^\|\s\)(\@]\@!" contains=mmaOperator +"pattern default: +syntax match mmaPattern ": *[^ ,]\+[\], ]\@=" contains=@mmaCommentStrings,@mmaTop,mmaOperator +"pattern head/test: +syntax match mmaPattern "[A-Za-z0-9`]*_\+\%(\a\+\)\=\%(?([^)]\+)\|?[^\]},]\+\)\=" contains=@mmaTop,@mmaCommentStrings,mmaPatternError + +" Operators: +" /: ^= ^:= UpValue +" /; Conditional +" := = DownValue +" == === || +" != =!= && Logic +" >= <= < > +" += -= *= +" /= ++ -- Math +" ^* +" -> :> Rules +" @@ @@@ Apply +" /@ //@ Map +" /. //. Replace +" // @ Function application +" <> ~~ String/Pattern join +" ~ infix operator +" . : Pattern operators +syntax match mmaOperator "\%(@\{1,3}\|//[.@]\=\)" +syntax match mmaOperator "\%(/[;:@.]\=\|\^\=:\==\)" +syntax match mmaOperator "\%([-:=]\=>\|<=\=\)" +"syntax match mmaOperator "\%(++\=\|--\=\|[/+-*]=\|[^*]\)" +syntax match mmaOperator "[*+=^.:?-]" +syntax match mmaOperator "\%(\~\~\=\)" +syntax match mmaOperator "\%(=\{2,3}\|=\=!=\|||\=\|&&\|!\)" contains=ALLBUT,mmaPureFunction + +" Symbol Tags: +" "SymbolName::item" +"syntax match mmaSymbol "`\=[a-zA-Z$]\+[0-9a-zA-Z$]*\%(`\%([a-zA-Z$]\+[0-9a-zA-Z$]*\)\=\)*" contained +syntax match mmaMessage "`\=\([a-zA-Z$]\+[0-9a-zA-Z$]*\)\%(`\%([a-zA-Z$]\+[0-9a-zA-Z$]*\)\=\)*::\a\+" contains=mmaMessageType +syntax match mmaMessageType "::\a\+"hs=s+2 contained + +" Pure Functions: +syntax match mmaPureFunction "#\%(#\|\d\+\)\=" +syntax match mmaPureFunction "&" + +" Named Functions: +" Since everything is pretty much a function, get this straight +" from context +syntax match mmaGenericFunction "[A-Za-z0-9`]\+\s*\%([@[]\|/:\|/\=/@\)\@=" contains=mmaOperator +syntax match mmaGenericFunction "\~\s*[^~]\+\s*\~"hs=s+1,he=e-1 contains=mmaOperator,mmaBoring +syntax match mmaGenericFunction "//\s*[A-Za-z0-9`]\+"hs=s+2 contains=mmaOperator + +" Numbers: +syntax match mmaNumber "\<\%(\d\+\.\=\d*\|\d*\.\=\d\+\)\>" +syntax match mmaNumber "`\d\+\%(\d\@!\.\|\>\)" + +" Special Characters: +" \[Name] named character +" \ooo octal +" \.xx 2 digit hex +" \:xxxx 4 digit hex (multibyte unicode) +syntax match mmaUnicode "\\\[\w\+\d*\]" +syntax match mmaUnicode "\\\%(\x\{3}\|\.\x\{2}\|:\x\{4}\)" + +" Syntax Errors: +syntax match mmaError "\*)" containedin=ALLBUT,@mmaComments,@mmaStrings +syntax match mmaError "\%([/]{3,}\|[&:|+*?~-]\{3,}\|[.=]\{4,}\|_\@<=\.\{2,}\|`\{2,}\)" containedin=ALLBUT,@mmaComments,@mmaStrings + +" Punctuation: +" things that shouldn't really be highlighted, or highlighted +" in they're own group if you _really_ want. :) +" ( ) { } +" TODO - use Delimiter group? +syntax match mmaBoring "[(){}]" contained + +" ------------------------------------ +" future explorations... +" ------------------------------------ +" Function Arguments: +" anything between brackets [] +" (fold) +"syntax region mmaArgument start="\[" end="\]" containedin=ALLBUT,@mmaComments,@mmaStrings transparent fold + +" Lists: +" (fold) +"syntax region mmaLists start="{" end="}" containedin=ALLBUT,@mmaComments,@mmaStrings transparent fold + +" Regions: +" (fold) +"syntax region mmaRegion start="(\*\+[^<]* \*)" containedin=ALLBUT,@mmaStrings transparent fold keepend + +" show fold text +set commentstring='(*%s*)' +"set foldtext=MmaFoldText() + +"function MmaFoldText() +" let line = getline(v:foldstart) +" +" let lines = v:foldend-v:foldstart+1 +" +" let sub = substitute(line, '(\*\+|\*\+)|[-*_]\+', '', 'g') +" +" if match(line, '(\*') != -1 +" let lines = lines.' line comment' +" else +" let lines = lines.' lines' +" endif +" +" return v:folddashes.' '.lines.' '.sub +"endf + +"this is slow for computing folds, but it does so accurately +syntax sync fromstart + +" but this seems to do alright for non fold syntax coloring. +" for folding, however, it doesn't get the nesting right. +" TODO - find sync group for multiline modules? ick... + +" sync multi line comments +"syntax sync match syncComments groupthere NONE "\*)" +"syntax sync match syncComments groupthere mmaComment "(\*" + +"set foldmethod=syntax +"set foldnestmax=1 +"set foldminlines=15 + + +" NOTE - the following links are not guaranteed to +" look good under all colorschemes. You might need to +" :so $VIMRUNTIME/syntax/hitest.vim and tweak these to +" look good in yours + + +hi def link mmaComment Comment +hi def link mmaCommentStar Comment +hi def link mmaFunctionComment Comment +hi def link mmaLooseQuote Comment +hi def link mmaGenericFunction Function +hi def link mmaVariable Identifier +" hi def link mmaSymbol Identifier +hi def link mmaOperator Operator +hi def link mmaPatternOp Operator +hi def link mmaPureFunction Operator +hi def link mmaString String +hi def link mmaCommentString String +hi def link mmaUnicode String +hi def link mmaMessage Type +hi def link mmaNumber Type +hi def link mmaPattern Type +hi def link mmaError Error +hi def link mmaFixme Error +hi def link mmaPatternError Error +hi def link mmaTodo Todo +hi def link mmaemPHAsis Special +hi def link mmaFunctionTitle Special +hi def link mmaMessageType Special +hi def link mmaItem Preproc + + +let b:current_syntax = "mma" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'mathematica') == -1 "Vim syntax file diff --git a/syntax/mmix.vim b/syntax/mmix.vim new file mode 100644 index 0000000..75297f2 --- /dev/null +++ b/syntax/mmix.vim @@ -0,0 +1,156 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MMIX +" Maintainer: Dirk Hüsken, +" Last Change: 2012 Jun 01 +" (Dominique Pelle added @Spell) +" Filenames: *.mms +" URL: http://homepages.uni-tuebingen.de/student/dirk.huesken/vim/syntax/mmix.vim + +" Limitations: Comments must start with either % or // +" (preferably %, Knuth-Style) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" MMIX data types +syn keyword mmixType byte wyde tetra octa + +" different literals... +syn match decNumber "[0-9]*" +syn match octNumber "0[0-7][0-7]\+" +syn match hexNumber "#[0-9a-fA-F]\+" +syn region mmixString start=+"+ skip=+\\"+ end=+"+ contains=@Spell +syn match mmixChar "'.'" + +" ...and more special MMIX stuff +syn match mmixAt "@" +syn keyword mmixSegments Data_Segment Pool_Segment Stack_Segment + +syn match mmixIdentifier "[a-z_][a-z0-9_]*" + +" labels (for branches etc) +syn match mmixLabel "^[a-z0-9_:][a-z0-9_]*" +syn match mmixLabel "[0-9][HBF]" + +" pseudo-operations +syn keyword mmixPseudo is loc greg + +" comments +syn match mmixComment "%.*" contains=@Spell +syn match mmixComment "//.*" contains=@Spell +syn match mmixComment "^\*.*" contains=@Spell + + +syn keyword mmixOpcode trap fcmp fun feql fadd fix fsub fixu +syn keyword mmixOpcode fmul fcmpe fune feqle fdiv fsqrt frem fint + +syn keyword mmixOpcode floti flotui sfloti sflotui i +syn keyword mmixOpcode muli mului divi divui +syn keyword mmixOpcode addi addui subi subui +syn keyword mmixOpcode 2addui 4addui 8addui 16addui +syn keyword mmixOpcode cmpi cmpui negi negui +syn keyword mmixOpcode sli slui sri srui +syn keyword mmixOpcode bnb bzb bpb bodb +syn keyword mmixOpcode bnnb bnzb bnpb bevb +syn keyword mmixOpcode pbnb pbzb pbpb pbodb +syn keyword mmixOpcode pbnnb pbnzb pbnpb pbevb +syn keyword mmixOpcode csni cszi cspi csodi +syn keyword mmixOpcode csnni csnzi csnpi csevi +syn keyword mmixOpcode zsni zszi zspi zsodi +syn keyword mmixOpcode zsnni zsnzi zsnpi zsevi +syn keyword mmixOpcode ldbi ldbui ldwi ldwui +syn keyword mmixOpcode ldti ldtui ldoi ldoui +syn keyword mmixOpcode ldsfi ldhti cswapi ldunci +syn keyword mmixOpcode ldvtsi preldi pregoi goi +syn keyword mmixOpcode stbi stbui stwi stwui +syn keyword mmixOpcode stti sttui stoi stoui +syn keyword mmixOpcode stsfi sthti stcoi stunci +syn keyword mmixOpcode syncdi presti syncidi pushgoi +syn keyword mmixOpcode ori orni nori xori +syn keyword mmixOpcode andi andni nandi nxori +syn keyword mmixOpcode bdifi wdifi tdifi odifi +syn keyword mmixOpcode muxi saddi mori mxori +syn keyword mmixOpcode muli mului divi divui + +syn keyword mmixOpcode flot flotu sflot sflotu +syn keyword mmixOpcode mul mulu div divu +syn keyword mmixOpcode add addu sub subu +syn keyword mmixOpcode 2addu 4addu 8addu 16addu +syn keyword mmixOpcode cmp cmpu neg negu +syn keyword mmixOpcode sl slu sr sru +syn keyword mmixOpcode bn bz bp bod +syn keyword mmixOpcode bnn bnz bnp bev +syn keyword mmixOpcode pbn pbz pbp pbod +syn keyword mmixOpcode pbnn pbnz pbnp pbev +syn keyword mmixOpcode csn csz csp csod +syn keyword mmixOpcode csnn csnz csnp csev +syn keyword mmixOpcode zsn zsz zsp zsod +syn keyword mmixOpcode zsnn zsnz zsnp zsev +syn keyword mmixOpcode ldb ldbu ldw ldwu +syn keyword mmixOpcode ldt ldtu ldo ldou +syn keyword mmixOpcode ldsf ldht cswap ldunc +syn keyword mmixOpcode ldvts preld prego go +syn keyword mmixOpcode stb stbu stw stwu +syn keyword mmixOpcode stt sttu sto stou +syn keyword mmixOpcode stsf stht stco stunc +syn keyword mmixOpcode syncd prest syncid pushgo +syn keyword mmixOpcode or orn nor xor +syn keyword mmixOpcode and andn nand nxor +syn keyword mmixOpcode bdif wdif tdif odif +syn keyword mmixOpcode mux sadd mor mxor + +syn keyword mmixOpcode seth setmh setml setl inch incmh incml incl +syn keyword mmixOpcode orh ormh orml orl andh andmh andml andnl +syn keyword mmixOpcode jmp pushj geta put +syn keyword mmixOpcode pop resume save unsave sync swym get trip +syn keyword mmixOpcode set lda + +" switch back to being case sensitive +syn case match + +" general-purpose and special-purpose registers +syn match mmixRegister "$[0-9]*" +syn match mmixRegister "r[A-Z]" +syn keyword mmixRegister rBB rTT rWW rXX rYY rZZ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link mmixAt Type +hi def link mmixPseudo Type +hi def link mmixRegister Special +hi def link mmixSegments Type + +hi def link mmixLabel Special +hi def link mmixComment Comment +hi def link mmixOpcode Keyword + +hi def link hexNumber Number +hi def link decNumber Number +hi def link octNumber Number + +hi def link mmixString String +hi def link mmixChar String + +hi def link mmixType Type +hi def link mmixIdentifier Normal +hi def link mmixSpecialComment Comment + +" My default color overrides: +" hi mmixSpecialComment ctermfg=red +"hi mmixLabel ctermfg=lightcyan +" hi mmixType ctermbg=black ctermfg=brown + + +let b:current_syntax = "mmix" + +" vim: ts=8 + +endif diff --git a/syntax/mmp.vim b/syntax/mmp.vim new file mode 100644 index 0000000..e6934b3 --- /dev/null +++ b/syntax/mmp.vim @@ -0,0 +1,53 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Symbian meta-makefile definition (MMP) +" Maintainer: Ron Aaron +" Last Change: 2007/11/07 +" URL: http://ronware.org/wiki/vim/mmp +" Filetypes: *.mmp + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +syn match mmpComment "//.*" +syn region mmpComment start="/\*" end="\*\/" + +syn keyword mmpKeyword aif asspabi assplibrary aaspexports baseaddress +syn keyword mmpKeyword debuglibrary deffile document epocheapsize +syn keyword mmpKeyword epocprocesspriority epocstacksize exportunfrozen +syn keyword mmpStorage lang library linkas macro nostrictdef option +syn keyword mmpStorage resource source sourcepath srcdbg startbitmap +syn keyword mmpStorage start end staticlibrary strictdepend systeminclude +syn keyword mmpStorage systemresource target targettype targetpath uid +syn keyword mmpStorage userinclude win32_library + +syn match mmpIfdef "\#\(include\|ifdef\|ifndef\|if\|endif\|else\|elif\)" + +syn match mmpNumber "\d+" +syn match mmpNumber "0x\x\+" + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +if !exists("did_mmp_syntax_inits") + let did_mmp_syntax_inits=1 + + hi def link mmpComment Comment + hi def link mmpKeyword Keyword + hi def link mmpStorage StorageClass + hi def link mmpString String + hi def link mmpNumber Number + hi def link mmpOrdinal Operator + hi def link mmpIfdef PreCondit +endif + +let b:current_syntax = "mmp" + +" vim: ts=8 + +endif diff --git a/syntax/modconf.vim b/syntax/modconf.vim new file mode 100644 index 0000000..3adf47d --- /dev/null +++ b/syntax/modconf.vim @@ -0,0 +1,48 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: modules.conf(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2007-10-25 + +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword+=- + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword modconfTodo FIXME TODO XXX NOTE + +syn region modconfComment start='#' skip='\\$' end='$' + \ contains=modconfTodo,@Spell + +syn keyword modconfConditional if else elseif endif + +syn keyword modconfPreProc alias define include keep prune + \ post-install post-remove pre-install + \ pre-remove persistdir blacklist + +syn keyword modconfKeyword add above below install options probe probeall + \ remove + +syn keyword modconfIdentifier depfile insmod_opt path generic_stringfile + \ pcimapfile isapnpmapfile usbmapfile + \ parportmapfile ieee1394mapfile pnpbiosmapfile +syn match modconfIdentifier 'path\[[^]]\+\]' + +hi def link modconfTodo Todo +hi def link modconfComment Comment +hi def link modconfConditional Conditional +hi def link modconfPreProc PreProc +hi def link modconfKeyword Keyword +hi def link modconfIdentifier Identifier + +let b:current_syntax = "modconf" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/model.vim b/syntax/model.vim new file mode 100644 index 0000000..10c0cb8 --- /dev/null +++ b/syntax/model.vim @@ -0,0 +1,48 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Model +" Maintainer: Bram Moolenaar +" Last Change: 2005 Jun 20 + +" very basic things only (based on the vgrindefs file). +" If you use this language, please improve it, and send me the patches! + +" Quit when a (custom) syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of keywords +syn keyword modelKeyword abs and array boolean by case cdnl char copied dispose +syn keyword modelKeyword div do dynamic else elsif end entry external FALSE false +syn keyword modelKeyword fi file for formal fortran global if iff ift in integer include +syn keyword modelKeyword inline is lbnd max min mod new NIL nil noresult not notin od of +syn keyword modelKeyword or procedure public read readln readonly record recursive rem rep +syn keyword modelKeyword repeat res result return set space string subscript such then TRUE +syn keyword modelKeyword true type ubnd union until varies while width + +" Special keywords +syn keyword modelBlock beginproc endproc + +" Comments +syn region modelComment start="\$" end="\$" end="$" + +" Strings +syn region modelString start=+"+ end=+"+ + +" Character constant (is this right?) +syn match modelString "'." + +" Define the default highlighting. +" Only used when an item doesn't have highlighting yet +hi def link modelKeyword Statement +hi def link modelBlock PreProc +hi def link modelComment Comment +hi def link modelString String + +let b:current_syntax = "model" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/modsim3.vim b/syntax/modsim3.vim new file mode 100644 index 0000000..88eeac0 --- /dev/null +++ b/syntax/modsim3.vim @@ -0,0 +1,101 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Modsim III, by compuware corporation (www.compuware.com) +" Maintainer: Philipp Jocham +" Extension: *.mod +" Last Change: 2001 May 10 +" +" 2001 March 24: +" - Modsim III is a registered trademark from compuware corporation +" - made compatible with Vim 6.0 +" +" 1999 Apr 22 : Changed modsim3Literal from region to match +" +" very basic things only (based on the modula2 and c files). + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +" syn case match " case sensitiv match is default + +" A bunch of keywords +syn keyword modsim3Keyword ACTID ALL AND AS ASK +syn keyword modsim3Keyword BY CALL CASE CLASS CONST DIV +syn keyword modsim3Keyword DOWNTO DURATION ELSE ELSIF EXIT FALSE FIXED FOR +syn keyword modsim3Keyword FOREACH FORWARD IF IN INHERITED INOUT +syn keyword modsim3Keyword INTERRUPT LOOP +syn keyword modsim3Keyword MOD MONITOR NEWVALUE +syn keyword modsim3Keyword NONMODSIM NOT OBJECT OF ON OR ORIGINAL OTHERWISE OUT +syn keyword modsim3Keyword OVERRIDE PRIVATE PROTO REPEAT +syn keyword modsim3Keyword RETURN REVERSED SELF STRERR TELL +syn keyword modsim3Keyword TERMINATE THISMETHOD TO TRUE TYPE UNTIL VALUE VAR +syn keyword modsim3Keyword WAIT WAITFOR WHEN WHILE WITH + +" Builtin functions and procedures +syn keyword modsim3Builtin ABS ACTIVATE ADDMONITOR CAP CHARTOSTR CHR CLONE +syn keyword modsim3Builtin DEACTIVATE DEC DISPOSE FLOAT GETMONITOR HIGH INC +syn keyword modsim3Builtin INPUT INSERT INTTOSTR ISANCESTOR LOW LOWER MAX MAXOF +syn keyword modsim3Builtin MIN MINOF NEW OBJTYPEID OBJTYPENAME OBJVARID ODD +syn keyword modsim3Builtin ONERROR ONEXIT ORD OUTPUT POSITION PRINT REALTOSTR +syn keyword modsim3Builtin REPLACE REMOVEMONITOR ROUND SCHAR SIZEOF SPRINT +syn keyword modsim3Builtin STRLEN STRTOCHAR STRTOINT STRTOREAL SUBSTR TRUNC +syn keyword modsim3Builtin UPDATEVALUE UPPER VAL + +syn keyword modsim3BuiltinNoParen HALT TRACE + +" Special keywords +syn keyword modsim3Block PROCEDURE METHOD MODULE MAIN DEFINITION IMPLEMENTATION +syn keyword modsim3Block BEGIN END + +syn keyword modsim3Include IMPORT FROM + +syn keyword modsim3Type ANYARRAY ANYOBJ ANYREC ARRAY BOOLEAN CHAR INTEGER +syn keyword modsim3Type LMONITORED LRMONITORED NILARRAY NILOBJ NILREC REAL +syn keyword modsim3Type RECORD RMONITOR RMONITORED STRING + +" catch errros cause by wrong parenthesis +" slight problem with "( *)" or "(* )". Hints? +syn region modsim3Paren transparent start='(' end=')' contains=ALLBUT,modsim3ParenError +syn match modsim3ParenError ")" + +" Comments +syn region modsim3Comment1 start="{" end="}" contains=modsim3Comment1,modsim3Comment2 +syn region modsim3Comment2 start="(\*" end="\*)" contains=modsim3Comment1,modsim3Comment2 +" highlighting is wrong for constructs like "{ (* } *)", +" which are allowed in Modsim III, but +" I think something like that shouldn't be used anyway. + +" Strings +syn region modsim3String start=+"+ end=+"+ + +" Literals +"syn region modsim3Literal start=+'+ end=+'+ +syn match modsim3Literal "'[^']'\|''''" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link modsim3Keyword Statement +hi def link modsim3Block Statement +hi def link modsim3Comment1 Comment +hi def link modsim3Comment2 Comment +hi def link modsim3String String +hi def link modsim3Literal Character +hi def link modsim3Include Statement +hi def link modsim3Type Type +hi def link modsim3ParenError Error +hi def link modsim3Builtin Function +hi def link modsim3BuiltinNoParen Function + + +let b:current_syntax = "modsim3" + +" vim: ts=8 sw=2 + + +endif diff --git a/syntax/modula2.vim b/syntax/modula2.vim new file mode 100644 index 0000000..f70b8d5 --- /dev/null +++ b/syntax/modula2.vim @@ -0,0 +1,77 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Modula 2 +" Maintainer: pf@artcom0.north.de (Peter Funk) +" based on original work of Bram Moolenaar +" Last Change: 2001 May 09 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Don't ignore case (Modula-2 is case significant). This is the default in vim + +" Especially emphasize headers of procedures and modules: +syn region modula2Header matchgroup=modula2Header start="PROCEDURE " end="(" contains=modula2Ident oneline +syn region modula2Header matchgroup=modula2Header start="MODULE " end=";" contains=modula2Ident oneline +syn region modula2Header matchgroup=modula2Header start="BEGIN (\*" end="\*)" contains=modula2Ident oneline +syn region modula2Header matchgroup=modula2Header start="END " end=";" contains=modula2Ident oneline +syn region modula2Keyword start="END" end=";" contains=ALLBUT,modula2Ident oneline + +" Some very important keywords which should be emphasized more than others: +syn keyword modula2AttKeyword CONST EXIT HALT RETURN TYPE VAR +" All other keywords in alphabetical order: +syn keyword modula2Keyword AND ARRAY BY CASE DEFINITION DIV DO ELSE +syn keyword modula2Keyword ELSIF EXPORT FOR FROM IF IMPLEMENTATION IMPORT +syn keyword modula2Keyword IN LOOP MOD NOT OF OR POINTER QUALIFIED RECORD +syn keyword modula2Keyword SET THEN TO UNTIL WHILE WITH + +syn keyword modula2Type ADDRESS BITSET BOOLEAN CARDINAL CHAR INTEGER REAL WORD +syn keyword modula2StdFunc ABS CAP CHR DEC EXCL INC INCL ORD SIZE TSIZE VAL +syn keyword modula2StdConst FALSE NIL TRUE +" The following may be discussed, since NEW and DISPOSE are some kind of +" special builtin macro functions: +syn keyword modula2StdFunc NEW DISPOSE +" The following types are added later on and may be missing from older +" Modula-2 Compilers (they are at least missing from the original report +" by N.Wirth from March 1980 ;-) Highlighting should apply nevertheless: +syn keyword modula2Type BYTE LONGCARD LONGINT LONGREAL PROC SHORTCARD SHORTINT +" same note applies to min and max, which were also added later to m2: +syn keyword modula2StdFunc MAX MIN +" The underscore was originally disallowed in m2 ids, it was also added later: +syn match modula2Ident " [A-Z,a-z][A-Z,a-z,0-9,_]*" contained + +" Comments may be nested in Modula-2: +syn region modula2Comment start="(\*" end="\*)" contains=modula2Comment,modula2Todo +syn keyword modula2Todo contained TODO FIXME XXX + +" Strings +syn region modula2String start=+"+ end=+"+ +syn region modula2String start="'" end="'" +syn region modula2Set start="{" end="}" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link modula2Ident Identifier +hi def link modula2StdConst Boolean +hi def link modula2Type Identifier +hi def link modula2StdFunc Identifier +hi def link modula2Header Type +hi def link modula2Keyword Statement +hi def link modula2AttKeyword PreProc +hi def link modula2Comment Comment +" The following is just a matter of taste (you want to try this instead): +" hi modula2Comment term=bold ctermfg=DarkBlue guifg=Blue gui=bold +hi def link modula2Todo Todo +hi def link modula2String String +hi def link modula2Set String + + +let b:current_syntax = "modula2" + +" vim: ts=8 + +endif diff --git a/syntax/modula3.vim b/syntax/modula3.vim new file mode 100644 index 0000000..2872857 --- /dev/null +++ b/syntax/modula3.vim @@ -0,0 +1,63 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Modula-3 +" Maintainer: Timo Pedersen +" Last Change: 2001 May 10 + +" Basic things only... +" Based on the modula 2 syntax file + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Modula-3 is case-sensitive +" syn case ignore + +" Modula-3 keywords +syn keyword modula3Keyword ABS ADDRES ADR ADRSIZE AND ANY +syn keyword modula3Keyword ARRAY AS BITS BITSIZE BOOLEAN BRANDED BY BYTESIZE +syn keyword modula3Keyword CARDINAL CASE CEILING CHAR CONST DEC DEFINITION +syn keyword modula3Keyword DISPOSE DIV +syn keyword modula3Keyword EVAL EXIT EXCEPT EXCEPTION +syn keyword modula3Keyword EXIT EXPORTS EXTENDED FALSE FINALLY FIRST FLOAT +syn keyword modula3Keyword FLOOR FROM GENERIC IMPORT +syn keyword modula3Keyword IN INC INTEGER ISTYPE LAST LOCK +syn keyword modula3Keyword LONGREAL LOOPHOLE MAX METHOD MIN MOD MUTEX +syn keyword modula3Keyword NARROW NEW NIL NOT NULL NUMBER OF OR ORD RAISE +syn keyword modula3Keyword RAISES READONLY REAL RECORD REF REFANY +syn keyword modula3Keyword RETURN ROOT +syn keyword modula3Keyword ROUND SET SUBARRAY TEXT TRUE TRUNC TRY TYPE +syn keyword modula3Keyword TYPECASE TYPECODE UNSAFE UNTRACED VAL VALUE VAR WITH + +" Special keywords, block delimiters etc +syn keyword modula3Block PROCEDURE FUNCTION MODULE INTERFACE REPEAT THEN +syn keyword modula3Block BEGIN END OBJECT METHODS OVERRIDES RECORD REVEAL +syn keyword modula3Block WHILE UNTIL DO TO IF FOR ELSIF ELSE LOOP + +" Comments +syn region modula3Comment start="(\*" end="\*)" + +" Strings +syn region modula3String start=+"+ end=+"+ +syn region modula3String start=+'+ end=+'+ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link modula3Keyword Statement +hi def link modula3Block PreProc +hi def link modula3Comment Comment +hi def link modula3String String + + +let b:current_syntax = "modula3" + +"I prefer to use this... +"set ai +"vim: ts=8 + +endif diff --git a/syntax/monk.vim b/syntax/monk.vim new file mode 100644 index 0000000..815e210 --- /dev/null +++ b/syntax/monk.vim @@ -0,0 +1,221 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Monk (See-Beyond Technologies) +" Maintainer: Mike Litherland +" Last Change: 2012 Feb 03 by Thilo Six + +" This syntax file is good enough for my needs, but others +" may desire more features. Suggestions and bug reports +" are solicited by the author (above). + +" Originally based on the Scheme syntax file by: + +" Maintainer: Dirk van Deun +" Last Change: April 30, 1998 + +" In fact it's almost identical. :) + +" The original author's notes: +" This script incorrectly recognizes some junk input as numerals: +" parsing the complete system of Scheme numerals using the pattern +" language is practically impossible: I did a lax approximation. + +" Initializing: + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case ignore + +" Fascist highlighting: everything that doesn't fit the rules is an error... + +syn match monkError oneline ![^ \t()";]*! +syn match monkError oneline ")" + +" Quoted and backquoted stuff + +syn region monkQuoted matchgroup=Delimiter start="['`]" end=![ \t()";]!me=e-1 contains=ALLBUT,monkStruc,monkSyntax,monkFunc + +syn region monkQuoted matchgroup=Delimiter start="['`](" matchgroup=Delimiter end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc +syn region monkQuoted matchgroup=Delimiter start="['`]#(" matchgroup=Delimiter end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc + +syn region monkStrucRestricted matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc +syn region monkStrucRestricted matchgroup=Delimiter start="#(" matchgroup=Delimiter end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc + +syn region monkUnquote matchgroup=Delimiter start="," end=![ \t()";]!me=e-1 contains=ALLBUT,monkStruc,monkSyntax,monkFunc +syn region monkUnquote matchgroup=Delimiter start=",@" end=![ \t()";]!me=e-1 contains=ALLBUT,monkStruc,monkSyntax,monkFunc + +syn region monkUnquote matchgroup=Delimiter start=",(" end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc +syn region monkUnquote matchgroup=Delimiter start=",@(" end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc + +syn region monkUnquote matchgroup=Delimiter start=",#(" end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc +syn region monkUnquote matchgroup=Delimiter start=",@#(" end=")" contains=ALLBUT,monkStruc,monkSyntax,monkFunc + +" R5RS Scheme Functions and Syntax: + +setlocal iskeyword=33,35-39,42-58,60-90,94,95,97-122,126,_ + +syn keyword monkSyntax lambda and or if cond case define let let* letrec +syn keyword monkSyntax begin do delay set! else => +syn keyword monkSyntax quote quasiquote unquote unquote-splicing +syn keyword monkSyntax define-syntax let-syntax letrec-syntax syntax-rules + +syn keyword monkFunc not boolean? eq? eqv? equal? pair? cons car cdr set-car! +syn keyword monkFunc set-cdr! caar cadr cdar cddr caaar caadr cadar caddr +syn keyword monkFunc cdaar cdadr cddar cdddr caaaar caaadr caadar caaddr +syn keyword monkFunc cadaar cadadr caddar cadddr cdaaar cdaadr cdadar cdaddr +syn keyword monkFunc cddaar cddadr cdddar cddddr null? list? list length +syn keyword monkFunc append reverse list-ref memq memv member assq assv assoc +syn keyword monkFunc symbol? symbol->string string->symbol number? complex? +syn keyword monkFunc real? rational? integer? exact? inexact? = < > <= >= +syn keyword monkFunc zero? positive? negative? odd? even? max min + * - / abs +syn keyword monkFunc quotient remainder modulo gcd lcm numerator denominator +syn keyword monkFunc floor ceiling truncate round rationalize exp log sin cos +syn keyword monkFunc tan asin acos atan sqrt expt make-rectangular make-polar +syn keyword monkFunc real-part imag-part magnitude angle exact->inexact +syn keyword monkFunc inexact->exact number->string string->number char=? +syn keyword monkFunc char-ci=? char? char-ci>? char<=? +syn keyword monkFunc char-ci<=? char>=? char-ci>=? char-alphabetic? char? +syn keyword monkFunc char-numeric? char-whitespace? char-upper-case? +syn keyword monkFunc char-lower-case? +syn keyword monkFunc char->integer integer->char char-upcase char-downcase +syn keyword monkFunc string? make-string string string-length string-ref +syn keyword monkFunc string-set! string=? string-ci=? string? string-ci>? string<=? string-ci<=? string>=? +syn keyword monkFunc string-ci>=? substring string-append vector? make-vector +syn keyword monkFunc vector vector-length vector-ref vector-set! procedure? +syn keyword monkFunc apply map for-each call-with-current-continuation +syn keyword monkFunc call-with-input-file call-with-output-file input-port? +syn keyword monkFunc output-port? current-input-port current-output-port +syn keyword monkFunc open-input-file open-output-file close-input-port +syn keyword monkFunc close-output-port eof-object? read read-char peek-char +syn keyword monkFunc write display newline write-char call/cc +syn keyword monkFunc list-tail string->list list->string string-copy +syn keyword monkFunc string-fill! vector->list list->vector vector-fill! +syn keyword monkFunc force with-input-from-file with-output-to-file +syn keyword monkFunc char-ready? load transcript-on transcript-off eval +syn keyword monkFunc dynamic-wind port? values call-with-values +syn keyword monkFunc monk-report-environment null-environment +syn keyword monkFunc interaction-environment + +" Keywords specific to STC's implementation + +syn keyword monkFunc $event-clear $event-parse $event->string $make-event-map +syn keyword monkFunc $resolve-event-definition change-pattern copy copy-strip +syn keyword monkFunc count-data-children count-map-children count-rep data-map +syn keyword monkFunc duplicate duplicate-strip file-check file-lookup get +syn keyword monkFunc insert list-lookup node-has-data? not-verify path? +syn keyword monkFunc path-defined-as-repeating? path-nodeclear path-nodedepth +syn keyword monkFunc path-nodename path-nodeparentname path->string path-valid? +syn keyword monkFunc regex string->path timestamp uniqueid verify + +" Keywords from the Monk function library (from e*Gate 4.1 programmers ref) +syn keyword monkFunc allcap? capitalize char-punctuation? char-substitute +syn keyword monkFunc char-to-char conv count-used-children degc->degf +syn keyword monkFunc diff-two-dates display-error empty-string? fail_id +syn keyword monkFunc fail_id_if fail_translation fail_translation_if +syn keyword monkFunc find-get-after find-get-before get-timestamp julian-date? +syn keyword monkFunc julian->standard leap-year? map-string not-empty-string? +syn keyword monkFunc standard-date? standard->julian string-begins-with? +syn keyword monkFunc string-contains? string-ends-with? string-search-from-left +syn keyword monkFunc string-search-from-right string->ssn strip-punct +syn keyword monkFunc strip-string substring=? symbol-table-get symbol-table-put +syn keyword monkFunc trim-string-left trim-string-right valid-decimal? +syn keyword monkFunc valid-integer? verify-type + +" Writing out the complete description of Scheme numerals without +" using variables is a day's work for a trained secretary... +" This is a useful lax approximation: + +syn match monkNumber oneline "[-#+0-9.][-#+/0-9a-f@i.boxesfdl]*" +syn match monkError oneline ![-#+0-9.][-#+/0-9a-f@i.boxesfdl]*[^-#+/0-9a-f@i.boxesfdl \t()";][^ \t()";]*! + +syn match monkOther oneline ![+-][ \t()";]!me=e-1 +syn match monkOther oneline ![+-]$! +" ... so that a single + or -, inside a quoted context, would not be +" interpreted as a number (outside such contexts, it's a monkFunc) + +syn match monkDelimiter oneline !\.[ \t()";]!me=e-1 +syn match monkDelimiter oneline !\.$! +" ... and a single dot is not a number but a delimiter + +" Simple literals: + +syn match monkBoolean oneline "#[tf]" +syn match monkError oneline !#[tf][^ \t()";]\+! + +syn match monkChar oneline "#\\" +syn match monkChar oneline "#\\." +syn match monkError oneline !#\\.[^ \t()";]\+! +syn match monkChar oneline "#\\space" +syn match monkError oneline !#\\space[^ \t()";]\+! +syn match monkChar oneline "#\\newline" +syn match monkError oneline !#\\newline[^ \t()";]\+! + +" This keeps all other stuff unhighlighted, except *stuff* and : + +syn match monkOther oneline ,[a-z!$%&*/:<=>?^_~][-a-z!$%&*/:<=>?^_~0-9+.@]*, +syn match monkError oneline ,[a-z!$%&*/:<=>?^_~][-a-z!$%&*/:<=>?^_~0-9+.@]*[^-a-z!$%&*/:<=>?^_~0-9+.@ \t()";]\+[^ \t()";]*, + +syn match monkOther oneline "\.\.\." +syn match monkError oneline !\.\.\.[^ \t()";]\+! +" ... a special identifier + +syn match monkConstant oneline ,\*[-a-z!$%&*/:<=>?^_~0-9+.@]*\*[ \t()";],me=e-1 +syn match monkConstant oneline ,\*[-a-z!$%&*/:<=>?^_~0-9+.@]*\*$, +syn match monkError oneline ,\*[-a-z!$%&*/:<=>?^_~0-9+.@]*\*[^-a-z!$%&*/:<=>?^_~0-9+.@ \t()";]\+[^ \t()";]*, + +syn match monkConstant oneline ,<[-a-z!$%&*/:<=>?^_~0-9+.@]*>[ \t()";],me=e-1 +syn match monkConstant oneline ,<[-a-z!$%&*/:<=>?^_~0-9+.@]*>$, +syn match monkError oneline ,<[-a-z!$%&*/:<=>?^_~0-9+.@]*>[^-a-z!$%&*/:<=>?^_~0-9+.@ \t()";]\+[^ \t()";]*, + +" Monk input and output structures +syn match monkSyntax oneline "\(\~input\|\[I\]->\)[^ \t]*" +syn match monkFunc oneline "\(\~output\|\[O\]->\)[^ \t]*" + +" Non-quoted lists, and strings: + +syn region monkStruc matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" contains=ALL +syn region monkStruc matchgroup=Delimiter start="#(" matchgroup=Delimiter end=")" contains=ALL + +syn region monkString start=+"+ skip=+\\[\\"]+ end=+"+ + +" Comments: + +syn match monkComment ";.*$" + +" Synchronization and the wrapping up... + +syn sync match matchPlace grouphere NONE "^[^ \t]" +" ... i.e. synchronize on a line that starts at the left margin + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link monkSyntax Statement +hi def link monkFunc Function + +hi def link monkString String +hi def link monkChar Character +hi def link monkNumber Number +hi def link monkBoolean Boolean + +hi def link monkDelimiter Delimiter +hi def link monkConstant Constant + +hi def link monkComment Comment +hi def link monkError Error + + +let b:current_syntax = "monk" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/moo.vim b/syntax/moo.vim new file mode 100644 index 0000000..577e0db --- /dev/null +++ b/syntax/moo.vim @@ -0,0 +1,177 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MOO +" Maintainer: Timo Frenay +" Last Change: 2001 Oct 06 +" Note: Requires Vim 6.0 or above + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Initializations +syn case ignore + +" C-style comments +syn match mooUncommentedError display ~\*/~ +syn match mooCStyleCommentError display ~/\ze\*~ contained +syn region mooCStyleComment matchgroup=mooComment start=~/\*~ end=~\*/~ contains=mooCStyleCommentError + +" Statements +if exists("moo_extended_cstyle_comments") + syn match mooIdentifier display ~\%(\%(/\*.\{-}\*/\s*\)*\)\@>\<\h\w*\>~ contained transparent contains=mooCStyleComment,@mooKeyword,mooType,mooVariable +else + syn match mooIdentifier display ~\<\h\w*\>~ contained transparent contains=@mooKeyword,mooType,mooVariable +endif +syn keyword mooStatement break continue else elseif endfor endfork endif endtry endwhile finally for if try +syn keyword mooStatement except fork while nextgroup=mooIdentifier skipwhite +syn keyword mooStatement return nextgroup=mooString skipwhite + +" Operators +syn keyword mooOperatorIn in + +" Error constants +syn keyword mooAny ANY +syn keyword mooErrorConstant E_ARGS E_INVARG E_DIV E_FLOAT E_INVIND E_MAXREC E_NACC E_NONE E_PERM E_PROPNF E_QUOTA E_RANGE E_RECMOVE E_TYPE E_VARNF E_VERBNF + +" Builtin variables +syn match mooType display ~\<\%(ERR\|FLOAT\|INT\|LIST\|NUM\|OBJ\|STR\)\>~ +syn match mooVariable display ~\<\%(args\%(tr\)\=\|caller\|dobj\%(str\)\=\|iobj\%(str\)\=\|player\|prepstr\|this\|verb\)\>~ + +" Strings +syn match mooStringError display ~[^\t -[\]-~]~ contained +syn match mooStringSpecialChar display ~\\["\\]~ contained +if !exists("moo_no_regexp") + " Regular expressions + syn match mooRegexp display ~%%~ contained containedin=mooString,mooRegexpParentheses transparent contains=NONE + syn region mooRegexpParentheses display matchgroup=mooRegexpOr start=~%(~ skip=~%%~ end=~%)~ contained containedin=mooString,mooRegexpParentheses transparent oneline + syn match mooRegexpOr display ~%|~ contained containedin=mooString,mooRegexpParentheses +endif +if !exists("moo_no_pronoun_sub") + " Pronoun substitutions + syn match mooPronounSub display ~%%~ contained containedin=mooString transparent contains=NONE + syn match mooPronounSub display ~%[#dilnopqrst]~ contained containedin=mooString + syn match mooPronounSub display ~%\[#[dilnt]\]~ contained containedin=mooString + syn match mooPronounSub display ~%(\h\w*)~ contained containedin=mooString + syn match mooPronounSub display ~%\[[dilnt]\h\w*\]~ contained containedin=mooString + syn match mooPronounSub display ~%<\%([dilnt]:\)\=\a\+>~ contained containedin=mooString +endif +if exists("moo_unmatched_quotes") + syn region mooString matchgroup=mooStringError start=~"~ end=~$~ contains=@mooStringContents keepend + syn region mooString start=~"~ skip=~\\.~ end=~"~ contains=@mooStringContents oneline keepend +else + syn region mooString start=~"~ skip=~\\.~ end=~"\|$~ contains=@mooStringContents keepend +endif + +" Numbers and object numbers +syn match mooNumber display ~\%(\%(\<\d\+\)\=\.\d\+\|\<\d\+\)\%(e[+\-]\=\d\+\)\=\>~ +syn match mooObject display ~#-\=\d\+\>~ + +" Properties and verbs +if exists("moo_builtin_properties") + "Builtin properties + syn keyword mooBuiltinProperty contents f location name owner programmer r w wizard contained containedin=mooPropRef +endif +if exists("moo_extended_cstyle_comments") + syn match mooPropRef display ~\.\s*\%(\%(/\*.\{-}\*/\s*\)*\)\@>\h\w*\>~ transparent contains=mooCStyleComment,@mooKeyword + syn match mooVerbRef display ~:\s*\%(\%(/\*.\{-}\*/\s*\)*\)\@>\h\w*\>~ transparent contains=mooCStyleComment,@mooKeyword +else + syn match mooPropRef display ~\.\s*\h\w*\>~ transparent contains=@mooKeyword + syn match mooVerbRef display ~:\s*\h\w*\>~ transparent contains=@mooKeyword +endif + +" Builtin functions, core properties and core verbs +if exists("moo_extended_cstyle_comments") + syn match mooBuiltinFunction display ~\<\h\w*\s*\%(\%(/\*.\{-}\*/\s*\)*\)\@>\ze(~ contains=mooCStyleComment + syn match mooCorePropOrVerb display ~\$\s*\%(\%(/\*.\{-}\*/\s*\)*\)\@>\%(in\>\)\@!\h\w*\>~ contains=mooCStyleComment,@mooKeyword +else + syn match mooBuiltinFunction display ~\<\h\w*\s*\ze(~ contains=NONE + syn match mooCorePropOrVerb display ~\$\s*\%(in\>\)\@!\h\w*\>~ contains=@mooKeyword +endif +if exists("moo_unknown_builtin_functions") + syn match mooUnknownBuiltinFunction ~\<\h\w*\>~ contained containedin=mooBuiltinFunction contains=mooKnownBuiltinFunction + " Known builtin functions as of version 1.8.1 of the server + " Add your own extensions to this group if you like + syn keyword mooKnownBuiltinFunction abs acos add_property add_verb asin atan binary_hash boot_player buffered_output_length callers caller_perms call_function ceil children chparent clear_property connected_players connected_seconds connection_name connection_option connection_options cos cosh create crypt ctime db_disk_size decode_binary delete_property delete_verb disassemble dump_database encode_binary equal eval exp floatstr floor flush_input force_input function_info idle_seconds index is_clear_property is_member is_player kill_task length listappend listdelete listen listeners listinsert listset log log10 match max max_object memory_usage min move notify object_bytes open_network_connection output_delimiters parent pass players properties property_info queued_tasks queue_info raise random read recycle renumber reset_max_object resume rindex rmatch seconds_left server_log server_version setadd setremove set_connection_option set_player_flag set_property_info set_task_perms set_verb_args set_verb_code set_verb_info shutdown sin sinh sqrt strcmp string_hash strsub substitute suspend tan tanh task_id task_stack ticks_left time tofloat toint toliteral tonum toobj tostr trunc typeof unlisten valid value_bytes value_hash verbs verb_args verb_code verb_info contained +endif + +" Enclosed expressions +syn match mooUnenclosedError display ~[')\]|}]~ +syn match mooParenthesesError display ~[';\]|}]~ contained +syn region mooParentheses start=~(~ end=~)~ transparent contains=@mooEnclosedContents,mooParenthesesError +syn match mooBracketsError display ~[');|}]~ contained +syn region mooBrackets start=~\[~ end=~\]~ transparent contains=@mooEnclosedContents,mooBracketsError +syn match mooBracesError display ~[');\]|]~ contained +syn region mooBraces start=~{~ end=~}~ transparent contains=@mooEnclosedContents,mooBracesError +syn match mooQuestionError display ~[');\]}]~ contained +syn region mooQuestion start=~?~ end=~|~ transparent contains=@mooEnclosedContents,mooQuestionError +syn match mooCatchError display ~[);\]|}]~ contained +syn region mooCatch matchgroup=mooExclamation start=~`~ end=~'~ transparent contains=@mooEnclosedContents,mooCatchError,mooExclamation +if exists("moo_extended_cstyle_comments") + syn match mooExclamation display ~[\t !%&(*+,\-/<=>?@[^`{|]\@!=\@!~ contained contains=mooCStyleComment +else + syn match mooExclamation display ~[\t !%&(*+,\-/<=>?@[^`{|]\@?@^|]\@?~ transparent contains=mooCStyleComment +else + syn match mooScattering ~[,{]\@<=\s*?~ transparent contains=NONE +endif + +" Clusters +syn cluster mooKeyword contains=mooStatement,mooOperatorIn,mooAny,mooErrorConstant +syn cluster mooStringContents contains=mooStringError,mooStringSpecialChar +syn cluster mooEnclosedContents contains=TOP,mooUnenclosedError,mooComment,mooNonCode + +" Define the default highlighting. +hi def link mooUncommentedError Error +hi def link mooCStyleCommentError Error +hi def link mooCStyleComment Comment +hi def link mooStatement Statement +hi def link mooOperatorIn Operator +hi def link mooAny Constant " link this to Keyword if you want +hi def link mooErrorConstant Constant +hi def link mooType Type +hi def link mooVariable Type +hi def link mooStringError Error +hi def link mooStringSpecialChar SpecialChar +hi def link mooRegexpOr SpecialChar +hi def link mooPronounSub SpecialChar +hi def link mooString String +hi def link mooNumber Number +hi def link mooObject Number +hi def link mooBuiltinProperty Type +hi def link mooBuiltinFunction Function +hi def link mooUnknownBuiltinFunction Error +hi def link mooKnownBuiltinFunction Function +hi def link mooCorePropOrVerb Identifier +hi def link mooUnenclosedError Error +hi def link mooParenthesesError Error +hi def link mooBracketsError Error +hi def link mooBracesError Error +hi def link mooQuestionError Error +hi def link mooCatchError Error +hi def link mooExclamation Exception +hi def link mooComment Comment +hi def link mooNonCode PreProc + +let b:current_syntax = "moo" + +" vim: ts=8 + +endif diff --git a/syntax/mp.vim b/syntax/mp.vim new file mode 100644 index 0000000..d648ce8 --- /dev/null +++ b/syntax/mp.vim @@ -0,0 +1,773 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MetaPost +" Maintainer: Nicola Vitacolonna +" Former Maintainers: Andreas Scherer +" Last Change: 2016 Oct 14 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_sav = &cpo +set cpo&vim + +if exists("g:plain_mf_macros") + let s:plain_mf_macros = g:plain_mf_macros +endif +if exists("g:plain_mf_modes") + let s:plain_mf_modes = g:plain_mf_modes +endif +if exists("g:other_mf_macros") + let s:other_mf_macros = g:other_mf_macros +endif + +let g:plain_mf_macros = 0 " plain.mf has no special meaning for MetaPost +let g:plain_mf_modes = 0 " No METAFONT modes +let g:other_mf_macros = 0 " cmbase.mf, logo.mf, ... neither + +" Read the METAFONT syntax to start with +runtime! syntax/mf.vim +unlet b:current_syntax " Necessary for syn include below + +" Restore the value of existing global variables +if exists("s:plain_mf_macros") + let g:plain_mf_macros = s:plain_mf_macros +else + unlet g:plain_mf_macros +endif +if exists("s:plain_mf_modes") + let g:plain_mf_modes = s:plain_mf_modes +else + unlet g:plain_mf_modes +endif +if exists("s:other_mf_macros") + let g:other_mf_macros = s:other_mf_macros +else + unlet g:other_mf_macros +endif + +" Use TeX highlighting inside verbatimtex/btex... etex +syn include @MPTeX syntax/tex.vim +unlet b:current_syntax +" These are defined as keywords rather than using matchgroup +" in order to make them available to syntaxcomplete. +syn keyword mpTeXdelim btex etex verbatimtex contained +syn region mpTeXinsert + \ start=/\\|\/rs=e+1 + \ end=/\/re=s-1 keepend + \ contains=@MPTeX,mpTeXdelim + +" iskeyword must be set after the syn include above, because tex.vim sets `syn +" iskeyword`. Note that keywords do not contain numbers (numbers are +" subscripts) +syntax iskeyword @,_ + +" MetaPost primitives not found in METAFONT +syn keyword mpBoolExp bounded clipped filled stroked textual arclength +syn keyword mpNumExp arctime blackpart bluepart colormodel cyanpart +syn keyword mpNumExp fontsize greenpart greypart magentapart redpart +syn keyword mpPairExp yellowpart llcorner lrcorner ulcorner urcorner +" envelope is seemingly undocumented, but it exists since mpost 1.003. +" The syntax is: envelope of . For example, +" path p; +" p := envelope pensquare of (up--left); +" (Thanks to Daniel H. Luecking for the example!) +syn keyword mpPathExp envelope pathpart +syn keyword mpPenExp penpart +syn keyword mpPicExp dashpart glyph infont +syn keyword mpStringExp fontpart readfrom textpart +syn keyword mpType cmykcolor color rgbcolor +" Other MetaPost primitives listed in the manual +syn keyword mpPrimitive mpxbreak within +" Internal quantities not found in METAFONT +" (Table 6 in MetaPost: A User's Manual) +syn keyword mpInternal defaultcolormodel hour minute linecap linejoin +syn keyword mpInternal miterlimit mpprocset mpversion numberprecision +syn keyword mpInternal numbersystem outputfilename outputformat +syn keyword mpInternal outputformatoptions outputtemplate prologues +syn keyword mpInternal restoreclipcolor tracinglostchars troffmode +syn keyword mpInternal truecorners +" List of commands not found in METAFONT (from MetaPost: A User's Manual) +syn keyword mpCommand clip closefrom dashed filenametemplate fontmapfile +syn keyword mpCommand fontmapline setbounds withcmykcolor withcolor +syn keyword mpCommand withgreyscale withoutcolor withpostscript +syn keyword mpCommand withprescript withrgbcolor write +" METAFONT internal variables not found in MetaPost +syn keyword notDefined autorounding chardx chardy fillin granularity +syn keyword notDefined proofing smoothing tracingedges tracingpens +syn keyword notDefined turningcheck xoffset yoffset +" Suffix defined only in METAFONT: +syn keyword notDefined nodot +" Other not implemented primitives (see MetaPost: A User's Manual, §C.1) +syn keyword notDefined cull display openwindow numspecial totalweight +syn keyword notDefined withweight + +" Keywords defined by plain.mp +if get(g:, "plain_mp_macros", 1) || get(g:, "mp_metafun_macros", 0) + syn keyword mpDef beginfig clear_pen_memory clearit clearpen clearpen + syn keyword mpDef clearxy colorpart cutdraw downto draw drawarrow + syn keyword mpDef drawdblarrow drawdot drawoptions endfig erase + syn keyword mpDef exitunless fill filldraw flex gobble hide interact + syn keyword mpDef label loggingall makelabel numtok penstroke pickup + syn keyword mpDef range reflectedabout rotatedaround shipit + syn keyword mpDef stop superellipse takepower tracingall tracingnone + syn keyword mpDef undraw undrawdot unfill unfilldraw upto + syn match mpDef "???" + syn keyword mpVardef arrowhead bbox bot buildcycle byte ceiling center + syn keyword mpVardef counterclockwise decr dir direction directionpoint + syn keyword mpVardef dotlabel dotlabels image incr interpath inverse + syn keyword mpVardef labels lft magstep max min penlabels penpos round + syn keyword mpVardef rt savepen solve tensepath thelabel top unitvector + syn keyword mpVardef whatever z + syn keyword mpPrimaryDef div dotprod gobbled mod + syn keyword mpSecondaryDef intersectionpoint + syn keyword mpTertiaryDef cutafter cutbefore softjoin thru + syn keyword mpNewInternal ahangle ahlength bboxmargin beveled butt defaultpen + syn keyword mpNewInternal defaultscale dotlabeldiam eps epsilon infinity + syn keyword mpNewInternal join_radius labeloffset mitered pen_bot pen_lft + syn keyword mpNewInternal pen_rt pen_top rounded squared tolerance + " Predefined constants + syn keyword mpConstant EOF background base_name base_version black + syn keyword mpConstant blankpicture blue ditto down evenly fullcircle + syn keyword mpConstant green halfcircle identity left origin penrazor + syn keyword mpConstant penspeck pensquare quartercircle red right + syn keyword mpConstant unitsquare up white withdots + " Other predefined variables + syn keyword mpVariable currentpen currentpen_path currentpicture cuttings + syn keyword mpVariable defaultfont extra_beginfig extra_endfig + syn match mpVariable /\<\%(laboff\|labxf\|labyf\)\>/ + syn match mpVariable /\<\%(laboff\|labxf\|labyf\)\.\%(lft\|rt\|bot\|top\|ulft\|urt\|llft\|lrt\)\>/ + " let statements: + syn keyword mpnumExp abs + syn keyword mpDef rotatedabout + syn keyword mpCommand bye relax + " on and off are not technically keywords, but it is nice to highlight them + " inside dashpattern(). + syn keyword mpOnOff off on contained + syn keyword mpDash dashpattern contained + syn region mpDashPattern + \ start="dashpattern\s*" + \ end=")"he=e-1 + \ contains=mfNumeric,mfLength,mpOnOff,mpDash +endif + +" Keywords defined by mfplain.mp +if get(g:, "mfplain_mp_macros", 0) + syn keyword mpDef beginchar capsule_def change_width + syn keyword mpDef define_blacker_pixels define_corrected_pixels + syn keyword mpDef define_good_x_pixels define_good_y_pixels + syn keyword mpDef define_horizontal_corrected_pixels define_pixels + syn keyword mpDef define_whole_blacker_pixels define_whole_pixels + syn keyword mpDef define_whole_vertical_blacker_pixels + syn keyword mpDef define_whole_vertical_pixels endchar + syn keyword mpDef font_coding_scheme font_extra_space font_identifier + syn keyword mpDef font_normal_shrink font_normal_space + syn keyword mpDef font_normal_stretch font_quad font_size font_slant + syn keyword mpDef font_x_height italcorr labelfont lowres_fix makebox + syn keyword mpDef makegrid maketicks mode_def mode_setup proofrule + syn keyword mpDef smode + syn keyword mpVardef hround proofrulethickness vround + syn keyword mpNewInternal blacker o_correction + syn keyword mpVariable extra_beginchar extra_endchar extra_setup rulepen + " plus some no-ops, also from mfplain.mp + syn keyword mpDef cull cullit gfcorners imagerules nodisplays + syn keyword mpDef notransforms openit proofoffset screenchars + syn keyword mpDef screenrule screenstrokes showit + syn keyword mpVardef grayfont slantfont titlefont + syn keyword mpVariable currenttransform + syn keyword mpConstant unitpixel + " These are not listed in the MetaPost manual, and some are ignored by + " MetaPost, but are nonetheless defined in mfplain.mp + syn keyword mpDef killtext + syn match mpVardef "\" + syn keyword mpVariable aspect_ratio localfont mag mode mode_name + syn keyword mpVariable proofcolor + syn keyword mpConstant lowres proof smoke + syn keyword mpNewInternal autorounding bp_per_pixel granularity + syn keyword mpNewInternal number_of_modes proofing smoothing turningcheck +endif + +" Keywords defined by all base macro packages: +" - (r)boxes.mp +" - format.mp +" - graph.mp +" - marith.mp +" - sarith.mp +" - string.mp +" - TEX.mp +if get(g:, "other_mp_macros", 1) + " boxes and rboxes + syn keyword mpDef boxjoin drawboxed drawboxes drawunboxed + syn keyword mpNewInternal circmargin defaultdx defaultdy rbox_radius + syn keyword mpVardef boxit bpath circleit fixpos fixsize generic_declare + syn keyword mpVardef generic_redeclare generisize pic rboxit str_prefix + " format + syn keyword mpVardef Mformat format init_numbers roundd + syn keyword mpVariable Fe_base Fe_plus + syn keyword mpConstant Ten_to + " graph + syn keyword mpDef Gfor Gxyscale OUT auto begingraph endgraph gdata + syn keyword mpDef gdraw gdrawarrow gdrawdblarrow gfill plot + syn keyword mpVardef augment autogrid frame gdotlabel glabel grid itick + syn keyword mpVardef otick + syn keyword mpVardef Mreadpath setcoords setrange + syn keyword mpNewInternal Gmarks Gminlog Gpaths linear log + syn keyword mpVariable Autoform Gemarks Glmarks Gumarks + syn keyword mpConstant Gtemplate + syn match mpVariable /Gmargin\.\%(low\|high\)/ + " marith + syn keyword mpVardef Mabs Meform Mexp Mexp_str Mlog Mlog_Str Mlog_str + syn keyword mpPrimaryDef Mdiv Mmul + syn keyword mpSecondaryDef Madd Msub + syn keyword mpTertiaryDef Mleq + syn keyword mpNewInternal Mten Mzero + " sarith + syn keyword mpVardef Sabs Scvnum + syn keyword mpPrimaryDef Sdiv Smul + syn keyword mpSecondaryDef Sadd Ssub + syn keyword mpTertiaryDef Sleq Sneq + " string + syn keyword mpVardef cspan isdigit loptok + " TEX + syn keyword mpVardef TEX TEXPOST TEXPRE +endif + +" Up to date as of 23-Sep-2016. +if get(b:, 'mp_metafun_macros', get(g:, 'mp_metafun_macros', 0)) + " Highlight TeX keywords (for use in ConTeXt documents) + syn match mpTeXKeyword '\\[a-zA-Z@]\+' + + " These keywords have been added manually. + syn keyword mpPrimitive runscript + + " The following MetaFun keywords have been extracted automatically from + " ConTeXt source code. They include all "public" macros (where a macro is + " considered public if and only if it does not start with _, mfun_, mlib_, or + " do_, and it does not end with _), all "public" unsaved variables, and all + " `let` statements. + + " mp-abck.mpiv + syn keyword mpDef abck_grid_line anchor_box box_found boxfilloptions + syn keyword mpDef boxgridoptions boxlineoptions draw_multi_pars + syn keyword mpDef draw_multi_side draw_multi_side_path freeze_box + syn keyword mpDef initialize_box initialize_box_pos + syn keyword mpDef multi_side_draw_options show_multi_kind + syn keyword mpDef show_multi_pars + syn keyword mpVardef abck_baseline_grid abck_draw_path abck_graphic_grid + syn keyword mpVariable boxdashtype boxfilloffset boxfilltype + syn keyword mpVariable boxgriddirection boxgriddistance boxgridshift + syn keyword mpVariable boxgridtype boxgridwidth boxlineoffset + syn keyword mpVariable boxlineradius boxlinetype boxlinewidth multikind + syn keyword mpConstant context_abck + " mp-apos.mpiv + syn keyword mpDef anch_sidebars_draw boxfilloptions boxlineoptions + syn keyword mpDef connect_positions + syn keyword mpConstant context_apos + " mp-asnc.mpiv + syn keyword mpDef FlushSyncTasks ProcessSyncTask ResetSyncTasks + syn keyword mpDef SetSyncColor SetSyncThreshold SyncTask + syn keyword mpVardef PrepareSyncTasks SyncBox TheSyncColor + syn keyword mpVardef TheSyncThreshold + syn keyword mpVariable CurrentSyncClass NOfSyncPaths SyncColor + syn keyword mpVariable SyncLeftOffset SyncPaths SyncTasks SyncThreshold + syn keyword mpVariable SyncThresholdMethod SyncWidth + syn keyword mpConstant context_asnc + " mp-back.mpiv + syn keyword mpDef some_double_back some_hash + syn keyword mpVariable back_nillcolor + syn keyword mpConstant context_back + " mp-bare.mpiv + syn keyword mpVardef colordecimals rawtextext + syn keyword mpPrimaryDef infont + syn keyword mpConstant context_bare + " mp-base.mpiv + " This is essentially plain.mp with only a few keywords added + syn keyword mpNumExp graypart + syn keyword mpType graycolor greycolor + syn keyword mpConstant cyan magenta yellow + " mp-butt.mpiv + syn keyword mpDef predefinedbutton some_button + syn keyword mpConstant context_butt + " mp-char.mpiv + syn keyword mpDef flow_begin_chart flow_begin_sub_chart + syn keyword mpDef flow_chart_draw_comment flow_chart_draw_exit + syn keyword mpDef flow_chart_draw_label flow_chart_draw_text + syn keyword mpDef flow_clip_chart flow_collapse_points + syn keyword mpDef flow_connect_bottom_bottom flow_connect_bottom_left + syn keyword mpDef flow_connect_bottom_right flow_connect_bottom_top + syn keyword mpDef flow_connect_left_bottom flow_connect_left_left + syn keyword mpDef flow_connect_left_right flow_connect_left_top + syn keyword mpDef flow_connect_right_bottom flow_connect_right_left + syn keyword mpDef flow_connect_right_right flow_connect_right_top + syn keyword mpDef flow_connect_top_bottom flow_connect_top_left + syn keyword mpDef flow_connect_top_right flow_connect_top_top + syn keyword mpDef flow_draw_connection flow_draw_connection_point + syn keyword mpDef flow_draw_midpoint flow_draw_shape + syn keyword mpDef flow_draw_test_area flow_draw_test_shape + syn keyword mpDef flow_draw_test_shapes flow_end_chart + syn keyword mpDef flow_end_sub_chart flow_flush_connections + syn keyword mpDef flow_flush_picture flow_flush_pictures + syn keyword mpDef flow_flush_shape flow_flush_shapes + syn keyword mpDef flow_initialize_grid flow_new_chart flow_new_shape + syn keyword mpDef flow_scaled_to_grid flow_show_connection + syn keyword mpDef flow_show_connections flow_show_shapes + syn keyword mpDef flow_xy_offset flow_y_pos + syn keyword mpVardef flow_connection_path flow_down_on_grid + syn keyword mpVardef flow_down_to_grid flow_i_point flow_left_on_grid + syn keyword mpVardef flow_left_to_grid flow_offset + syn keyword mpVardef flow_points_initialized flow_right_on_grid + syn keyword mpVardef flow_right_to_grid flow_smooth_connection + syn keyword mpVardef flow_trim_points flow_trimmed flow_up_on_grid + syn keyword mpVardef flow_up_to_grid flow_valid_connection + syn keyword mpVardef flow_x_on_grid flow_xy_bottom flow_xy_left + syn keyword mpVardef flow_xy_on_grid flow_xy_right flow_xy_top + syn keyword mpVardef flow_y_on_grid + syn keyword mpVariable flow_arrowtip flow_chart_background_color + syn keyword mpVariable flow_chart_offset flow_comment_offset + syn keyword mpVariable flow_connection_arrow_size + syn keyword mpVariable flow_connection_dash_size + syn keyword mpVariable flow_connection_line_color + syn keyword mpVariable flow_connection_line_width + syn keyword mpVariable flow_connection_smooth_size flow_connections + syn keyword mpVariable flow_cpath flow_dash_pattern flow_dashline + syn keyword mpVariable flow_exit_offset flow_forcevalid flow_grid_height + syn keyword mpVariable flow_grid_width flow_label_offset flow_max_x + syn keyword mpVariable flow_max_y flow_peepshape flow_reverse_connection + syn keyword mpVariable flow_reverse_y flow_shape_action flow_shape_archive + syn keyword mpVariable flow_shape_decision flow_shape_down + syn keyword mpVariable flow_shape_fill_color flow_shape_height + syn keyword mpVariable flow_shape_left flow_shape_line_color + syn keyword mpVariable flow_shape_line_width flow_shape_loop + syn keyword mpVariable flow_shape_multidocument flow_shape_node + syn keyword mpVariable flow_shape_procedure flow_shape_product + syn keyword mpVariable flow_shape_right flow_shape_singledocument + syn keyword mpVariable flow_shape_subprocedure flow_shape_up + syn keyword mpVariable flow_shape_wait flow_shape_width + syn keyword mpVariable flow_show_all_points flow_show_con_points + syn keyword mpVariable flow_show_mid_points flow_showcrossing flow_smooth + syn keyword mpVariable flow_touchshape flow_xypoint flow_zfactor + syn keyword mpConstant context_flow + " mp-chem.mpiv + syn keyword mpDef chem_init_all chem_reset chem_start_structure + syn keyword mpDef chem_transformed + syn keyword mpVardef chem_ad chem_adj chem_align chem_arrow chem_au + syn keyword mpVardef chem_b chem_bb chem_bd chem_bw chem_c chem_cc + syn keyword mpVardef chem_ccd chem_cd chem_crz chem_cz chem_dash chem_db + syn keyword mpVardef chem_diff chem_dir chem_do chem_dr chem_draw + syn keyword mpVardef chem_drawarrow chem_eb chem_ed chem_ep chem_er + syn keyword mpVardef chem_es chem_et chem_fill chem_hb chem_init_some + syn keyword mpVardef chem_label chem_ldb chem_ldd chem_line chem_lr + syn keyword mpVardef chem_lrb chem_lrbd chem_lrd chem_lrh chem_lrn + syn keyword mpVardef chem_lrt chem_lrz chem_lsr chem_lsub chem_mark + syn keyword mpVardef chem_marked chem_mid chem_mids chem_midz chem_mir + syn keyword mpVardef chem_mov chem_move chem_number chem_oe chem_off + syn keyword mpVardef chem_pb chem_pe chem_r chem_r_fragment chem_rb + syn keyword mpVardef chem_rbd chem_rd chem_rdb chem_rdd chem_restore + syn keyword mpVardef chem_rh chem_rm chem_rn chem_rot chem_rr chem_rrb + syn keyword mpVardef chem_rrbd chem_rrd chem_rrh chem_rrn chem_rrt + syn keyword mpVardef chem_rrz chem_rsr chem_rsub chem_rt chem_rz chem_s + syn keyword mpVardef chem_save chem_sb chem_sd chem_set chem_sr chem_ss + syn keyword mpVardef chem_start_component chem_stop_component + syn keyword mpVardef chem_stop_structure chem_sub chem_symbol chem_tb + syn keyword mpVardef chem_text chem_z chem_zln chem_zlt chem_zn chem_zrn + syn keyword mpVardef chem_zrt chem_zt + syn keyword mpVariable chem_mark_pair chem_stack_mirror chem_stack_origin + syn keyword mpVariable chem_stack_p chem_stack_previous + syn keyword mpVariable chem_stack_rotation chem_trace_boundingbox + syn keyword mpVariable chem_trace_nesting chem_trace_text + syn keyword mpConstant context_chem + " mp-core.mpiv + syn keyword mpDef FlushSyncTasks ProcessSyncTask + syn keyword mpDef RegisterLocalTextArea RegisterPlainTextArea + syn keyword mpDef RegisterRegionTextArea RegisterTextArea + syn keyword mpDef ResetLocalTextArea ResetSyncTasks ResetTextAreas + syn keyword mpDef SaveTextAreas SetSyncColor SetSyncThreshold + syn keyword mpDef SyncTask anchor_box box_found boxfilloptions + syn keyword mpDef boxgridoptions boxlineoptions collapse_multi_pars + syn keyword mpDef draw_box draw_multi_pars draw_par freeze_box + syn keyword mpDef initialize_area initialize_area_par initialize_box + syn keyword mpDef initialize_box_pos initialize_par + syn keyword mpDef prepare_multi_pars relocate_multipars save_multipar + syn keyword mpDef set_par_line_height show_multi_pars show_par + syn keyword mpDef simplify_multi_pars sort_multi_pars + syn keyword mpVardef InsideSavedTextArea InsideSomeSavedTextArea + syn keyword mpVardef InsideSomeTextArea InsideTextArea PrepareSyncTasks + syn keyword mpVardef SyncBox TextAreaH TextAreaW TextAreaWH TextAreaX + syn keyword mpVardef TextAreaXY TextAreaY TheSyncColor TheSyncThreshold + syn keyword mpVardef baseline_grid graphic_grid multi_par_at_top + syn keyword mpVariable CurrentSyncClass NOfSavedTextAreas + syn keyword mpVariable NOfSavedTextColumns NOfSyncPaths NOfTextAreas + syn keyword mpVariable NOfTextColumns PlainTextArea RegionTextArea + syn keyword mpVariable SavedTextColumns SyncColor SyncLeftOffset SyncPaths + syn keyword mpVariable SyncTasks SyncThreshold SyncThresholdMethod + syn keyword mpVariable SyncWidth TextAreas TextColumns + syn keyword mpVariable auto_multi_par_hsize boxdashtype boxfilloffset + syn keyword mpVariable boxfilltype boxgriddirection boxgriddistance + syn keyword mpVariable boxgridshift boxgridtype boxgridwidth boxlineradius + syn keyword mpVariable boxlinetype boxlinewidth check_multi_par_chain + syn keyword mpVariable compensate_multi_par_topskip + syn keyword mpVariable enable_multi_par_fallback force_multi_par_chain + syn keyword mpVariable ignore_multi_par_page last_multi_par_shift lefthang + syn keyword mpVariable local_multi_par_area multi_column_first_page_hack + syn keyword mpVariable multi_par_pages multiloc multilocs multipar + syn keyword mpVariable multipars multiref multirefs nofmultipars + syn keyword mpVariable obey_multi_par_hang obey_multi_par_more + syn keyword mpVariable one_piece_multi_par par_hang_after par_hang_indent + syn keyword mpVariable par_indent par_left_skip par_line_height + syn keyword mpVariable par_right_skip par_start_pos par_stop_pos + syn keyword mpVariable par_strut_depth par_strut_height ppos righthang + syn keyword mpVariable snap_multi_par_tops somehang span_multi_column_pars + syn keyword mpVariable use_multi_par_region + syn keyword mpConstant context_core + syn keyword LET anchor_area anchor_par draw_area + " mp-cows.mpiv + syn keyword mpConstant context_cows cow + " mp-crop.mpiv + syn keyword mpDef page_marks_add_color page_marks_add_lines + syn keyword mpDef page_marks_add_marking page_marks_add_number + syn keyword mpVardef crop_color crop_gray crop_marks_cmyk + syn keyword mpVardef crop_marks_cmykrgb crop_marks_gray crop_marks_lines + syn keyword mpVariable crop_colors more page + syn keyword mpConstant context_crop + " mp-figs.mpiv + syn keyword mpDef naturalfigure registerfigure + syn keyword mpVardef figuredimensions figureheight figuresize + syn keyword mpVardef figurewidth + syn keyword mpConstant context_figs + " mp-fobg.mpiv + syn keyword mpDef DrawFoFrame + syn keyword mpVardef equalpaths + syn keyword mpPrimaryDef inset outset + syn keyword mpVariable FoBackground FoBackgroundColor FoFrame FoLineColor + syn keyword mpVariable FoLineStyle FoLineWidth FoSplit + syn keyword mpConstant FoAll FoBottom FoDash FoDotted FoDouble FoGroove + syn keyword mpConstant FoHidden FoInset FoLeft FoMedium FoNoColor FoNone + syn keyword mpConstant FoOutset FoRidge FoRight FoSolid FoThick FoThin + syn keyword mpConstant FoTop context_fobg + " mp-form.mpiv + syn keyword mpConstant context_form + " mp-func.mpiv + syn keyword mpDef constructedfunction constructedpairs + syn keyword mpDef constructedpath curvedfunction curvedpairs + syn keyword mpDef curvedpath function pathconnectors straightfunction + syn keyword mpDef straightpairs straightpath + syn keyword mpConstant context_func + " mp-grap.mpiv + syn keyword mpDef Gfor OUT auto begingraph circles crosses diamonds + syn keyword mpDef downtriangles endgraph gdata gdraw gdrawarrow + syn keyword mpDef gdrawdblarrow gfill graph_addto + syn keyword mpDef graph_addto_currentpicture graph_comma + syn keyword mpDef graph_coordinate_multiplication graph_draw + syn keyword mpDef graph_draw_label graph_errorbar_text graph_fill + syn keyword mpDef graph_generate_exponents + syn keyword mpDef graph_generate_label_position + syn keyword mpDef graph_generate_numbers graph_label_location + syn keyword mpDef graph_scan_mark graph_scan_marks graph_setbounds + syn keyword mpDef graph_suffix graph_tick_label + syn keyword mpDef graph_with_pen_and_color graph_withlist + syn keyword mpDef graph_xyscale lefttriangles makefunctionpath plot + syn keyword mpDef plotsymbol points rainbow righttriangles smoothpath + syn keyword mpDef squares stars uptriangles witherrorbars + syn keyword mpVardef addtopath augment autogrid constant_fit + syn keyword mpVardef constant_function det escaped_format exp + syn keyword mpVardef exponential_fit exponential_function format + syn keyword mpVardef formatted frame functionpath gaussian_fit + syn keyword mpVardef gaussian_function gdotlabel glabel graph_Feform + syn keyword mpVardef graph_Meform graph_arrowhead_extent graph_bounds + syn keyword mpVardef graph_clear_bounds + syn keyword mpVardef graph_convert_user_path_to_internal graph_cspan + syn keyword mpVardef graph_draw_arrowhead graph_error graph_errorbars + syn keyword mpVardef graph_exp graph_factor_and_exponent_to_string + syn keyword mpVardef graph_gridline_picture graph_is_null + syn keyword mpVardef graph_label_convert_user_to_internal graph_loptok + syn keyword mpVardef graph_match_exponents graph_mlog + syn keyword mpVardef graph_modified_exponent_ypart graph_pair_adjust + syn keyword mpVardef graph_picture_conversion graph_post_draw + syn keyword mpVardef graph_read_line graph_readpath graph_remap + syn keyword mpVardef graph_scan_path graph_select_exponent_mark + syn keyword mpVardef graph_select_mark graph_set_bounds + syn keyword mpVardef graph_set_default_bounds graph_shapesize + syn keyword mpVardef graph_stash_label graph_tick_mark_spacing + syn keyword mpVardef graph_unknown_pair_bbox grid isdigit itick + syn keyword mpVardef linear_fit linear_function ln logten lorentzian_fit + syn keyword mpVardef lorentzian_function otick polynomial_fit + syn keyword mpVardef polynomial_function power_law_fit + syn keyword mpVardef power_law_function powten setcoords setrange + syn keyword mpVardef sortpath strfmt tick varfmt + syn keyword mpNewInternal Mzero doubleinfinity graph_log_minimum + syn keyword mpNewInternal graph_minimum_number_of_marks largestmantissa + syn keyword mpNewInternal linear lntwo log mlogten singleinfinity + syn keyword mpVariable Autoform determinant fit_chi_squared + syn keyword mpVariable graph_errorbar_picture graph_exp_marks + syn keyword mpVariable graph_frame_pair_a graph_frame_pair_b + syn keyword mpVariable graph_lin_marks graph_log_marks graph_modified_bias + syn keyword mpVariable graph_modified_higher graph_modified_lower + syn keyword mpVariable graph_shape r_s resistance_color resistance_name + syn keyword mpConstant context_grap + " mp-grid.mpiv + syn keyword mpDef hlingrid hloggrid vlingrid vloggrid + syn keyword mpVardef hlinlabel hlintext hlogtext linlin linlinpath + syn keyword mpVardef linlog linlogpath loglin loglinpath loglog + syn keyword mpVardef loglogpath processpath vlinlabel vlintext vlogtext + syn keyword mpVariable fmt_initialize fmt_pictures fmt_precision + syn keyword mpVariable fmt_separator fmt_zerocheck grid_eps + syn keyword mpConstant context_grid + " mp-grph.mpiv + syn keyword mpDef beginfig begingraphictextfig data_mpo_file + syn keyword mpDef data_mpy_file doloadfigure draw endfig + syn keyword mpDef endgraphictextfig fill fixedplace graphictext + syn keyword mpDef loadfigure new_graphictext normalwithshade number + syn keyword mpDef old_graphictext outlinefill protectgraphicmacros + syn keyword mpDef resetfig reversefill withdrawcolor withfillcolor + syn keyword mpDef withshade + syn keyword mpVariable currentgraphictext figureshift + syn keyword mpConstant context_grph + " mp-idea.mpiv + syn keyword mpVardef bcomponent ccomponent gcomponent mcomponent + syn keyword mpVardef rcomponent somecolor ycomponent + " mp-luas.mpiv + syn keyword mpDef luacall message + syn keyword mpVardef MP lua lualist + syn keyword mpConstant context_luas + " mp-mlib.mpiv + syn keyword mpDef autoalign bitmapimage circular_shade cmyk comment + syn keyword mpDef defineshade eofill eofillup externalfigure figure + syn keyword mpDef fillup label linear_shade multitonecolor namedcolor + syn keyword mpDef nofill onlayer passarrayvariable passvariable + syn keyword mpDef plain_label register resolvedcolor scantokens + syn keyword mpDef set_circular_vector set_linear_vector shaded + syn keyword mpDef spotcolor startpassingvariable stoppassingvariable + syn keyword mpDef thelabel transparent[] usemetafunlabels + syn keyword mpDef useplainlabels withcircularshade withlinearshade + syn keyword mpDef withmask withproperties withshadecenter + syn keyword mpDef withshadecolors withshadedirection withshadedomain + syn keyword mpDef withshadefactor withshadefraction withshadeorigin + syn keyword mpDef withshaderadius withshadestep withshadetransform + syn keyword mpDef withshadevector withtransparency + syn keyword mpVardef anchored checkbounds checkedbounds + syn keyword mpVardef define_circular_shade define_linear_shade dotlabel + syn keyword mpVardef escaped_format fmttext fontsize format formatted + syn keyword mpVardef installlabel onetimefmttext onetimetextext + syn keyword mpVardef outlinetext plain_thelabel properties rawfmttext + syn keyword mpVardef rawtexbox rawtextext rule strfmt strut texbox + syn keyword mpVardef textext thefmttext thelabel thetexbox thetextext + syn keyword mpVardef tostring transparency_alternative_to_number + syn keyword mpVardef validtexbox varfmt verbatim + syn keyword mpPrimaryDef asgroup infont normalinfont shadedinto + syn keyword mpPrimaryDef shownshadecenter shownshadedirection + syn keyword mpPrimaryDef shownshadeorigin shownshadevector withshade + syn keyword mpPrimaryDef withshademethod + syn keyword mpNewInternal colorburntransparent colordodgetransparent + syn keyword mpNewInternal colortransparent darkentransparent + syn keyword mpNewInternal differencetransparent exclusiontransparent + syn keyword mpNewInternal hardlighttransparent huetransparent + syn keyword mpNewInternal lightentransparent luminositytransparent + syn keyword mpNewInternal multiplytransparent normaltransparent + syn keyword mpNewInternal overlaytransparent saturationtransparent + syn keyword mpNewInternal screentransparent shadefactor softlighttransparent + syn keyword mpNewInternal textextoffset + syn keyword mpType property transparency + syn keyword mpVariable currentoutlinetext shadeddown shadedleft + syn keyword mpVariable shadedright shadedup shadeoffset trace_shades + syn keyword mpConstant context_mlib + " mp-page.mpiv + syn keyword mpDef BoundCoverAreas BoundPageAreas Enlarged FakeRule + syn keyword mpDef FakeWord LoadPageState OverlayBox RuleColor + syn keyword mpDef SetAreaVariables SetPageArea SetPageBackPage + syn keyword mpDef SetPageCoverPage SetPageField SetPageFrontPage + syn keyword mpDef SetPageHsize SetPageHstep SetPageLocation + syn keyword mpDef SetPagePage SetPageSpine SetPageVariables + syn keyword mpDef SetPageVsize SetPageVstep StartCover StartPage + syn keyword mpDef StopCover StopPage SwapPageState innerenlarged + syn keyword mpDef llEnlarged lrEnlarged outerenlarged ulEnlarged + syn keyword mpDef urEnlarged + syn keyword mpVardef BackPageHeight BackPageWidth BackSpace BaseLineSkip + syn keyword mpVardef BodyFontSize BottomDistance BottomHeight + syn keyword mpVardef BottomSpace CoverHeight CoverWidth CurrentColumn + syn keyword mpVardef CurrentHeight CurrentWidth CutSpace EmWidth + syn keyword mpVardef ExHeight FooterDistance FooterHeight + syn keyword mpVardef FrontPageHeight FrontPageWidth HSize HeaderDistance + syn keyword mpVardef HeaderHeight InPageBody InnerEdgeDistance + syn keyword mpVardef InnerEdgeWidth InnerMarginDistance InnerMarginWidth + syn keyword mpVardef InnerSpaceWidth LastPageNumber LayoutColumnDistance + syn keyword mpVardef LayoutColumnWidth LayoutColumns LeftEdgeDistance + syn keyword mpVardef LeftEdgeWidth LeftMarginDistance LeftMarginWidth + syn keyword mpVardef LineHeight MakeupHeight MakeupWidth NOfColumns + syn keyword mpVardef NOfPages OnOddPage OnRightPage OuterEdgeDistance + syn keyword mpVardef OuterEdgeWidth OuterMarginDistance OuterMarginWidth + syn keyword mpVardef OuterSpaceWidth OverlayDepth OverlayHeight + syn keyword mpVardef OverlayLineWidth OverlayOffset OverlayWidth + syn keyword mpVardef PageDepth PageFraction PageNumber PageOffset + syn keyword mpVardef PaperBleed PaperHeight PaperWidth PrintPaperHeight + syn keyword mpVardef PrintPaperWidth RealPageNumber RightEdgeDistance + syn keyword mpVardef RightEdgeWidth RightMarginDistance RightMarginWidth + syn keyword mpVardef SpineHeight SpineWidth StrutDepth StrutHeight + syn keyword mpVardef TextHeight TextWidth TopDistance TopHeight TopSkip + syn keyword mpVardef TopSpace VSize defaultcolormodel + syn keyword mpVariable Area BackPage CoverPage CurrentLayout Field + syn keyword mpVariable FrontPage HorPos Hsize Hstep Location Page + syn keyword mpVariable PageStateAvailable RuleDepth RuleDirection + syn keyword mpVariable RuleFactor RuleH RuleHeight RuleOffset RuleOption + syn keyword mpVariable RuleThickness RuleV RuleWidth Spine VerPos Vsize + syn keyword mpVariable Vstep + syn keyword mpConstant context_page + " mp-shap.mpiv + syn keyword mpDef drawline drawshape some_shape + syn keyword mpDef start_predefined_shape_definition + syn keyword mpDef stop_predefined_shape_definition + syn keyword mpVardef drawpredefinedline drawpredefinedshape + syn keyword mpVardef some_shape_path + syn keyword mpVariable predefined_shapes predefined_shapes_xradius + syn keyword mpVariable predefined_shapes_xxradius + syn keyword mpVariable predefined_shapes_yradius + syn keyword mpVariable predefined_shapes_yyradius + syn keyword mpConstant context_shap + " mp-step.mpiv + syn keyword mpDef initialize_step_variables midbottomboundary + syn keyword mpDef midtopboundary step_begin_cell step_begin_chart + syn keyword mpDef step_cell_ali step_cell_bot step_cell_top + syn keyword mpDef step_cells step_end_cell step_end_chart + syn keyword mpDef step_text_bot step_text_mid step_text_top + syn keyword mpDef step_texts + syn keyword mpVariable cell_distance_x cell_distance_y cell_fill_color + syn keyword mpVariable cell_line_color cell_line_width cell_offset + syn keyword mpVariable chart_align chart_category chart_vertical + syn keyword mpVariable line_distance line_height line_line_color + syn keyword mpVariable line_line_width line_offset nofcells + syn keyword mpVariable text_distance_set text_fill_color text_line_color + syn keyword mpVariable text_line_width text_offset + syn keyword mpConstant context_cell + " mp-symb.mpiv + syn keyword mpDef finishglyph prepareglyph + syn keyword mpConstant lefttriangle midbar onebar righttriangle sidebar + syn keyword mpConstant sublefttriangle subrighttriangle twobar + " mp-text.mpiv + syn keyword mpDef build_parshape + syn keyword mpVardef found_point + syn keyword mpVariable trace_parshape + syn keyword mpConstant context_text + " mp-tool.mpiv + syn keyword mpCommand dump + syn keyword mpDef addbackground b_color beginglyph break centerarrow + syn keyword mpDef clearxy condition data_mpd_file detaileddraw + syn keyword mpDef detailpaths dowithpath draw drawboundary + syn keyword mpDef drawboundingbox drawcontrollines drawcontrolpoints + syn keyword mpDef drawfill draworigin drawpath drawpathonly + syn keyword mpDef drawpathwithpoints drawpoint drawpointlabels + syn keyword mpDef drawpoints drawticks drawwholepath drawxticks + syn keyword mpDef drawyticks endglyph fill finishsavingdata g_color + syn keyword mpDef inner_boundingbox job_name leftarrow loadmodule + syn keyword mpDef midarrowhead naturalizepaths newboolean newcolor + syn keyword mpDef newnumeric newpair newpath newpicture newstring + syn keyword mpDef newtransform normalcolors normaldraw normalfill + syn keyword mpDef normalwithcolor outer_boundingbox pop_boundingbox + syn keyword mpDef popboundingbox popcurrentpicture push_boundingbox + syn keyword mpDef pushboundingbox pushcurrentpicture r_color readfile + syn keyword mpDef recolor redraw refill register_dirty_chars + syn keyword mpDef remapcolor remapcolors remappedcolor reprocess + syn keyword mpDef resetarrows resetcolormap resetdrawoptions + syn keyword mpDef resolvedcolor restroke retext rightarrow savedata + syn keyword mpDef saveoptions scale_currentpicture set_ahlength + syn keyword mpDef set_grid showgrid startplaincompatibility + syn keyword mpDef startsavingdata stopplaincompatibility + syn keyword mpDef stopsavingdata stripe_path_a stripe_path_n undashed + syn keyword mpDef undrawfill untext visualizeddraw visualizedfill + syn keyword mpDef visualizepaths withcolor withgray + syn keyword mpDef xscale_currentpicture xshifted + syn keyword mpDef xyscale_currentpicture yscale_currentpicture + syn keyword mpDef yshifted + syn keyword mpVardef acos acosh anglebetween area arrowhead + syn keyword mpVardef arrowheadonpath arrowpath asciistring asin asinh + syn keyword mpVardef atan basiccolors bbheight bbwidth bcomponent + syn keyword mpVardef blackcolor bottomboundary boundingbox c_phantom + syn keyword mpVardef ccomponent center cleanstring colorcircle + syn keyword mpVardef colordecimals colordecimalslist colorlike colorpart + syn keyword mpVardef colortype complementary complemented copylist cos + syn keyword mpVardef cosh cot cotd curved ddddecimal dddecimal ddecimal + syn keyword mpVardef decorated drawarrowpath epsed exp freedotlabel + syn keyword mpVardef freelabel gcomponent getunstringed grayed greyed + syn keyword mpVardef hsvtorgb infinite innerboundingbox interpolated inv + syn keyword mpVardef invcos inverted invsin invtan laddered leftboundary + syn keyword mpVardef leftpath leftrightpath listsize listtocurves + syn keyword mpVardef listtolines ln log mcomponent new_on_grid + syn keyword mpVardef outerboundingbox paired pen_size penpoint phantom + syn keyword mpVardef pointarrow pow punked rangepath rcomponent + syn keyword mpVardef redecorated repathed rightboundary rightpath + syn keyword mpVardef rotation roundedsquare set_inner_boundingbox + syn keyword mpVardef set_outer_boundingbox setunstringed shapedlist + syn keyword mpVardef simplified sin sinh sortlist sqr straightpath tan + syn keyword mpVardef tand tanh tensecircle thefreelabel topboundary + syn keyword mpVardef tripled undecorated unitvector unspiked unstringed + syn keyword mpVardef whitecolor ycomponent + syn keyword mpPrimaryDef along blownup bottomenlarged cornered crossed + syn keyword mpPrimaryDef enlarged enlonged leftenlarged llenlarged llmoved + syn keyword mpPrimaryDef lrenlarged lrmoved on paralleled randomized + syn keyword mpPrimaryDef randomizedcontrols randomshifted rightenlarged + syn keyword mpPrimaryDef shortened sized smoothed snapped softened squeezed + syn keyword mpPrimaryDef stretched superellipsed topenlarged ulenlarged + syn keyword mpPrimaryDef ulmoved uncolored urenlarged urmoved xsized + syn keyword mpPrimaryDef xstretched xyscaled xysized ysized ystretched zmod + syn keyword mpSecondaryDef anglestriped intersection_point numberstriped + syn keyword mpSecondaryDef peepholed + syn keyword mpTertiaryDef cutends + syn keyword mpNewInternal ahdimple ahvariant anglelength anglemethod + syn keyword mpNewInternal angleoffset charscale cmykcolormodel graycolormodel + syn keyword mpNewInternal greycolormodel maxdimensions metapostversion + syn keyword mpNewInternal nocolormodel rgbcolormodel striped_normal_inner + syn keyword mpNewInternal striped_normal_outer striped_reverse_inner + syn keyword mpNewInternal striped_reverse_outer + syn keyword mpType grayscale greyscale quadruplet triplet + syn keyword mpVariable ahfactor collapse_data color_map drawoptionsfactor + syn keyword mpVariable freedotlabelsize freelabeloffset grid grid_full + syn keyword mpVariable grid_h grid_left grid_nx grid_ny grid_w grid_x + syn keyword mpVariable grid_y intersection_found originlength + syn keyword mpVariable plain_compatibility_data pointlabelfont + syn keyword mpVariable pointlabelscale refillbackground savingdata + syn keyword mpVariable savingdatadone swappointlabels ticklength tickstep + syn keyword mpConstant CRLF DQUOTE PERCENT SPACE bcircle context_tool crlf + syn keyword mpConstant darkblue darkcyan darkgray darkgreen darkmagenta + syn keyword mpConstant darkred darkyellow downtriangle dquote freesquare + syn keyword mpConstant fulldiamond fullsquare fulltriangle lcircle + syn keyword mpConstant lefttriangle lightgray llcircle lltriangle lrcircle + syn keyword mpConstant lrtriangle mpversion nocolor noline oddly + syn keyword mpConstant originpath percent rcircle righttriangle space + syn keyword mpConstant tcircle triangle ulcircle ultriangle unitcircle + syn keyword mpConstant unitdiamond unittriangle uptriangle urcircle + syn keyword mpConstant urtriangle +endif " MetaFun macros + +" Define the default highlighting +hi def link mpTeXdelim mpPrimitive +hi def link mpBoolExp mfBoolExp +hi def link mpNumExp mfNumExp +hi def link mpPairExp mfPairExp +hi def link mpPathExp mfPathExp +hi def link mpPenExp mfPenExp +hi def link mpPicExp mfPicExp +hi def link mpStringExp mfStringExp +hi def link mpInternal mfInternal +hi def link mpCommand mfCommand +hi def link mpType mfType +hi def link mpPrimitive mfPrimitive +hi def link mpDef mfDef +hi def link mpVardef mpDef +hi def link mpPrimaryDef mpDef +hi def link mpSecondaryDef mpDef +hi def link mpTertiaryDef mpDef +hi def link mpNewInternal mpInternal +hi def link mpVariable mfVariable +hi def link mpConstant mfConstant +hi def link mpOnOff mpPrimitive +hi def link mpDash mpPrimitive +hi def link mpTeXKeyword Identifier + +let b:current_syntax = "mp" + +let &cpo = s:cpo_sav +unlet! s:cpo_sav + +" vim:sw=2 + +endif diff --git a/syntax/mplayerconf.vim b/syntax/mplayerconf.vim new file mode 100644 index 0000000..607211c --- /dev/null +++ b/syntax/mplayerconf.vim @@ -0,0 +1,132 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: mplayer(1) configuration file +" Maintainer: Dmitri Vereshchagin +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2015-01-24 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword+=- + +syn keyword mplayerconfTodo contained TODO FIXME XXX NOTE + +syn region mplayerconfComment display oneline start='#' end='$' + \ contains=mplayerconfTodo,@Spell + +syn keyword mplayerconfPreProc include + +syn keyword mplayerconfBoolean yes no true false + +syn match mplayerconfNumber '\<\d\+\>' + +syn keyword mplayerconfOption hardframedrop nomouseinput bandwidth dumpstream + \ rtsp-stream-over-tcp tv overlapsub + \ sub-bg-alpha subfont-outline unicode format + \ vo edl cookies fps zrfd af-adv nosound + \ audio-density passlogfile vobsuboutindex autoq + \ autosync benchmark colorkey nocolorkey edlout + \ enqueue fixed-vo framedrop h identify input + \ lircconf list-options loop menu menu-cfg + \ menu-root nojoystick nolirc nortc playlist + \ quiet really-quiet shuffle skin slave + \ softsleep speed sstep use-stdin aid alang + \ audio-demuxer audiofile audiofile-cache + \ cdrom-device cache cdda channels chapter + \ cookies-file demuxer dumpaudio dumpfile + \ dumpvideo dvbin dvd-device dvdangle forceidx + \ frames hr-mp3-seek idx ipv4-only-proxy + \ loadidx mc mf ni nobps noextbased + \ passwd prefer-ipv4 prefer-ipv6 rawaudio + \ rawvideo saveidx sb srate ss tskeepbroken + \ tsprog tsprobe user user-agent vid vivo + \ dumpjacosub dumpmicrodvdsub dumpmpsub dumpsami + \ dumpsrtsub dumpsub ffactor flip-hebrew font + \ forcedsubsonly fribidi-charset ifo noautosub + \ osdlevel sid slang spuaa spualign spugauss + \ sub sub-bg-color sub-demuxer sub-fuzziness + \ sub-no-text-pp subalign subcc subcp subdelay + \ subfile subfont-autoscale subfont-blur + \ subfont-encoding subfont-osd-scale + \ subfont-text-scale subfps subpos subwidth + \ utf8 vobsub vobsubid abs ao aofile aop delay + \ mixer nowaveheader aa bpp brightness contrast + \ dfbopts display double dr dxr2 fb fbmode + \ fbmodeconfig forcexv fs fsmode-dontuse fstype + \ geometry guiwid hue jpeg monitor-dotclock + \ monitor-hfreq monitor-vfreq monitoraspect + \ nograbpointer nokeepaspect noxv ontop panscan + \ rootwin saturation screenw stop-xscreensaver + \ vm vsync wid xineramascreen z zrbw zrcrop + \ zrdev zrhelp zrnorm zrquality zrvdec zrxdoff + \ ac af afm aspect flip lavdopts noaspect + \ noslices novideo oldpp pp pphelp ssf stereo + \ sws vc vfm x xvidopts xy y zoom vf vop + \ audio-delay audio-preload endpos ffourcc + \ include info noautoexpand noskip o oac of + \ ofps ovc skiplimit v vobsubout vobsuboutid + \ lameopts lavcopts nuvopts xvidencopts a52drc + \ adapter af-add af-clr af-del af-pre + \ allow-dangerous-playlist-parsing ass + \ ass-border-color ass-bottom-margin ass-color + \ ass-font-scale ass-force-style ass-hinting + \ ass-line-spacing ass-styles ass-top-margin + \ ass-use-margins ausid bluray-angle + \ bluray-device border border-pos-x border-pos-y + \ cache-min cache-seek-min capture codecpath + \ codecs-file correct-pts crash-debug + \ doubleclick-time dvd-speed edl-backward-delay + \ edl-start-pts embeddedfonts fafmttag + \ field-dominance fontconfig force-avi-aspect + \ force-key-frames frameno-file fullscreen gamma + \ gui gui-include gui-wid heartbeat-cmd + \ heartbeat-interval hr-edl-seek + \ http-header-fields idle ignore-start + \ key-fifo-size list-properties menu-chroot + \ menu-keepdir menu-startup mixer-channel + \ monitor-orientation monitorpixelaspect + \ mouse-movements msgcharset msgcolor msglevel + \ msgmodule name noar nocache noconfig + \ noconsolecontrols nocorrect-pts nodouble + \ noedl-start-pts noencodedups + \ noflip-hebrew-commas nogui noidx noodml + \ nostop-xscreensaver nosub noterm-osd + \ osd-duration osd-fractions panscanrange + \ pausing playing-msg priority profile + \ progbar-align psprobe pvr radio referrer + \ refreshrate reuse-socket rtc rtc-device + \ rtsp-destination rtsp-port + \ rtsp-stream-over-http screenh show-profile + \ softvol softvol-max sub-paths subfont + \ term-osd-esc title tvscan udp-ip udp-master + \ udp-port udp-seek-threshold udp-slave + \ unrarexec use-filedir-conf use-filename-title + \ vf-add vf-clr vf-del vf-pre volstep volume + \ zrhdec zrydoff + +syn region mplayerconfString display oneline start=+"+ end=+"+ +syn region mplayerconfString display oneline start=+'+ end=+'+ + +syn region mplayerconfProfile display oneline start='^\s*\[' end='\]' + +hi def link mplayerconfTodo Todo +hi def link mplayerconfComment Comment +hi def link mplayerconfPreProc PreProc +hi def link mplayerconfBoolean Boolean +hi def link mplayerconfNumber Number +hi def link mplayerconfOption Keyword +hi def link mplayerconfString String +hi def link mplayerconfProfile Special + +let b:current_syntax = "mplayerconf" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/mrxvtrc.vim b/syntax/mrxvtrc.vim new file mode 100644 index 0000000..327076a --- /dev/null +++ b/syntax/mrxvtrc.vim @@ -0,0 +1,286 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Description : Vim syntax file for mrxvtrc (for mrxvt-0.5.0 and up) +" Created : Wed 26 Apr 2006 01:20:53 AM CDT +" Modified : Thu 02 Feb 2012 08:37:45 PM EST +" Maintainer : GI , where a='gi1242+vim', b='gmail', c='com' + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case match + +" Errors +syn match mrxvtrcError contained '\v\S+' + +" Comments +syn match mrxvtrcComment contains=@Spell '^\s*[!#].*$' +syn match mrxvtrcComment '\v^\s*[#!]\s*\w+[.*]\w+.*:.*' + +" +" Options. +" +syn match mrxvtrcClass '\v^\s*\w+[.*]' + \ nextgroup=mrxvtrcOptions,mrxvtrcProfile,@mrxvtrcPOpts,mrxvtrcError + +" Boolean options +syn keyword mrxvtrcOptions contained nextgroup=mrxvtrcBColon,mrxvtrcError + \ highlightTabOnBell syncTabTitle hideTabbar + \ autohideTabbar bottomTabbar hideButtons + \ syncTabIcon veryBoldFont maximized + \ fullscreen reverseVideo loginShell + \ jumpScroll scrollBar scrollbarRight + \ scrollbarFloating scrollTtyOutputInhibit + \ scrollTtyKeypress transparentForce + \ transparentScrollbar transparentMenubar + \ transparentTabbar tabUsePixmap utmpInhibit + \ visualBell mapAlert meta8 + \ mouseWheelScrollPage multibyte_cursor + \ tripleclickwords showMenu xft xftNomFont + \ xftSlowOutput xftAntialias xftHinting + \ xftAutoHint xftGlobalAdvance cmdAllTabs + \ protectSecondary thai borderLess + \ overrideRedirect broadcast smartResize + \ pointerBlank cursorBlink noSysConfig + \ disableMacros linuxHomeEndKey sessionMgt + \ boldColors smoothResize useFifo veryBright +syn match mrxvtrcOptions contained nextgroup=mrxvtrcBColon,mrxvtrcError + \ '\v' +syn match mrxvtrcBColon contained skipwhite + \ nextgroup=mrxvtrcBoolVal,mrxvtrcError ':' +syn case ignore +syn keyword mrxvtrcBoolVal contained skipwhite nextgroup=mrxvtrcError + \ 0 1 yes no on off true false +syn case match + +" Color options +syn keyword mrxvtrcOptions contained nextgroup=mrxvtrcCColon,mrxvtrcError + \ ufBackground textShadow tabForeground + \ itabForeground tabBackground itabBackground + \ scrollColor troughColor highlightColor + \ cursorColor cursorColor2 pointerColor + \ borderColor tintColor +syn match mrxvtrcOptions contained nextgroup=mrxvtrcCColon,mrxvtrcError + \ '\v' +syn match mrxvtrcCColon contained skipwhite + \ nextgroup=mrxvtrcColorVal ':' +syn match mrxvtrcColorVal contained skipwhite nextgroup=mrxvtrcError + \ '\v#[0-9a-fA-F]{6}' + +" Numeric options +syn keyword mrxvtrcOptions contained nextgroup=mrxvtrcNColon,mrxvtrcError + \ maxTabWidth minVisibleTabs + \ scrollbarThickness xftmSize xftSize desktop + \ externalBorder internalBorder lineSpace + \ pointerBlankDelay cursorBlinkInterval + \ shading backgroundFade bgRefreshInterval + \ fading opacity opacityDegree xftPSize +syn match mrxvtrcNColon contained skipwhite + \ nextgroup=mrxvtrcNumVal,mrxvtrcError ':' +syn match mrxvtrcNumVal contained skipwhite nextgroup=mrxvtrcError + \ '\v[+-]?<(0[0-7]+|\d+|0x[0-9a-f]+)>' + +" String options +syn keyword mrxvtrcOptions contained nextgroup=mrxvtrcSColon,mrxvtrcError + \ tabTitle termName title clientName iconName + \ bellCommand backspaceKey deleteKey + \ printPipe cutChars answerbackString + \ smClientID geometry path boldFont xftFont + \ xftmFont xftPFont inputMethod + \ greektoggle_key menu menubarPixmap + \ scrollbarPixmap tabbarPixmap appIcon + \ multichar_encoding initProfileList +syn match mrxvtrcOptions contained nextgroup=mrxvtrcSColon,mrxvtrcError + \ '\v' +syn match mrxvtrcSColon contained skipwhite nextgroup=mrxvtrcStrVal ':' +syn match mrxvtrcStrVal contained '\v\S.*' + +" Profile options +syn cluster mrxvtrcPOpts contains=mrxvtrcPSOpts,mrxvtrcPCOpts,mrxvtrcPNOpts +syn match mrxvtrcProfile contained nextgroup=@mrxvtrcPOpts,mrxvtrcError + \ '\vprofile\d+\.' +syn keyword mrxvtrcPSOpts contained nextgroup=mrxvtrcSColon,mrxvtrcError + \ tabTitle command holdExitText holdExitTitle + \ Pixmap workingDirectory titleFormat + \ winTitleFormat +syn keyword mrxvtrcPCOpts contained nextgroup=mrxvtrcCColon,mrxvtrcError + \ background foreground +syn keyword mrxvtrcPNOpts contained nextgroup=mrxvtrcNColon,mrxvtrcError + \ holdExit saveLines + +" scrollbarStyle +syn match mrxvtrcOptions contained skipwhite + \ nextgroup=mrxvtrcSBstyle,mrxvtrcError + \ '\v' + +" +" Highlighting groups +" +hi def link mrxvtrcError Error +hi def link mrxvtrcComment Comment + +hi def link mrxvtrcClass Statement +hi def link mrxvtrcOptions mrxvtrcClass +hi def link mrxvtrcBColon mrxvtrcClass +hi def link mrxvtrcCColon mrxvtrcClass +hi def link mrxvtrcNColon mrxvtrcClass +hi def link mrxvtrcSColon mrxvtrcClass +hi def link mrxvtrcProfile mrxvtrcClass +hi def link mrxvtrcPSOpts mrxvtrcClass +hi def link mrxvtrcPCOpts mrxvtrcClass +hi def link mrxvtrcPNOpts mrxvtrcClass + +hi def link mrxvtrcBoolVal Boolean +hi def link mrxvtrcStrVal String +hi def link mrxvtrcColorVal Constant +hi def link mrxvtrcNumVal Number + +hi def link mrxvtrcSBstyle mrxvtrcStrVal +hi def link mrxvtrcSBalign mrxvtrcStrVal +hi def link mrxvtrcTSmode mrxvtrcStrVal +hi def link mrxvtrcGrkKbd mrxvtrcStrVal +hi def link mrxvtrcXftWt mrxvtrcStrVal +hi def link mrxvtrcXftSl mrxvtrcStrVal +hi def link mrxvtrcXftWd mrxvtrcStrVal +hi def link mrxvtrcXftHt mrxvtrcStrVal +hi def link mrxvtrcPedit mrxvtrcStrVal +hi def link mrxvtrcMod mrxvtrcStrVal +hi def link mrxvtrcSelSty mrxvtrcStrVal + +hi def link mrxvtrcMacro Identifier +hi def link mrxvtrcKey mrxvtrcClass +hi def link mrxvtrcTitle mrxvtrcStrVal +hi def link mrxvtrcShell Special +hi def link mrxvtrcCmd PreProc +hi def link mrxvtrcSubwin mrxvtrcStrVal + +let b:current_syntax = "mrxvtrc" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/msidl.vim b/syntax/msidl.vim new file mode 100644 index 0000000..0505374 --- /dev/null +++ b/syntax/msidl.vim @@ -0,0 +1,88 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MS IDL (Microsoft dialect of Interface Description Language) +" Maintainer: Vadim Zeitlin +" Last Change: 2012 Feb 12 by Thilo Six + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Misc basic +syn match msidlId "[a-zA-Z][a-zA-Z0-9_]*" +syn match msidlUUID "{\?[[:xdigit:]]\{8}-\([[:xdigit:]]\{4}-\)\{3}[[:xdigit:]]\{12}}\?" +syn region msidlString start=/"/ skip=/\\\(\\\\\)*"/ end=/"/ +syn match msidlLiteral "\d\+\(\.\d*\)\=" +syn match msidlLiteral "\.\d\+" +syn match msidlSpecial contained "[]\[{}:]" + +" Comments +syn keyword msidlTodo contained TODO FIXME XXX +syn region msidlComment start="/\*" end="\*/" contains=msidlTodo +syn match msidlComment "//.*" contains=msidlTodo +syn match msidlCommentError "\*/" + +" C style Preprocessor +syn region msidlIncluded contained start=+"+ skip=+\\\(\\\\\)*"+ end=+"+ +syn match msidlIncluded contained "<[^>]*>" +syn match msidlInclude "^[ \t]*#[ \t]*include\>[ \t]*["<]" contains=msidlIncluded,msidlString +syn region msidlPreCondit start="^[ \t]*#[ \t]*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=msidlComment,msidlCommentError +syn region msidlDefine start="^[ \t]*#[ \t]*\(define\>\|undef\>\)" skip="\\$" end="$" contains=msidlLiteral, msidlString + +" Attributes +syn keyword msidlAttribute contained in out propget propput propputref retval +syn keyword msidlAttribute contained aggregatable appobject binadable coclass control custom default defaultbind defaultcollelem defaultvalue defaultvtable dispinterface displaybind dual entry helpcontext helpfile helpstring helpstringdll hidden id immediatebind lcid library licensed nonbrowsable noncreatable nonextensible oleautomation optional object public readonly requestedit restricted source string uidefault usesgetlasterror vararg version +syn match msidlAttribute /uuid(.*)/he=s+4 contains=msidlUUID +syn match msidlAttribute /helpstring(.*)/he=s+10 contains=msidlString +syn region msidlAttributes start="\[" end="]" keepend contains=msidlSpecial,msidlString,msidlAttribute,msidlComment,msidlCommentError + +" Keywords +syn keyword msidlEnum enum +syn keyword msidlImport import importlib +syn keyword msidlStruct interface library coclass +syn keyword msidlTypedef typedef + +" Types +syn keyword msidlStandardType byte char double float hyper int long short void wchar_t +syn keyword msidlStandardType BOOL BSTR HRESULT VARIANT VARIANT_BOOL +syn region msidlSafeArray start="SAFEARRAY(" end=")" contains=msidlStandardType + +syn sync lines=50 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link msidlInclude Include +hi def link msidlPreProc PreProc +hi def link msidlPreCondit PreCondit +hi def link msidlDefine Macro +hi def link msidlIncluded String +hi def link msidlString String +hi def link msidlComment Comment +hi def link msidlTodo Todo +hi def link msidlSpecial SpecialChar +hi def link msidlLiteral Number +hi def link msidlUUID Number + +hi def link msidlImport Include +hi def link msidlEnum StorageClass +hi def link msidlStruct Structure +hi def link msidlTypedef Typedef +hi def link msidlAttribute StorageClass + +hi def link msidlStandardType Type +hi def link msidlSafeArray Type + + +let b:current_syntax = "msidl" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vi: set ts=8 sw=4: + +endif diff --git a/syntax/msmessages.vim b/syntax/msmessages.vim new file mode 100644 index 0000000..ed50aac --- /dev/null +++ b/syntax/msmessages.vim @@ -0,0 +1,136 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MS Message Text files (*.mc) +" Maintainer: Kevin Locke +" Last Change: 2008 April 09 +" Location: http://kevinlocke.name/programs/vim/syntax/msmessages.vim + +" See format description at +" This file is based on the rc.vim and c.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Common MS Messages keywords +syn case ignore +syn keyword msmessagesIdentifier MessageIdTypedef +syn keyword msmessagesIdentifier SeverityNames +syn keyword msmessagesIdentifier FacilityNames +syn keyword msmessagesIdentifier LanguageNames +syn keyword msmessagesIdentifier OutputBase + +syn keyword msmessagesIdentifier MessageId +syn keyword msmessagesIdentifier Severity +syn keyword msmessagesIdentifier Facility +syn keyword msmessagesIdentifier OutputBase + +syn match msmessagesIdentifier /\/ nextgroup=msmessagesIdentEq skipwhite +syn match msmessagesIdentEq transparent /=/ nextgroup=msmessagesIdentDef skipwhite contained +syn match msmessagesIdentDef display /\w\+/ contained +" Note: The Language keyword is highlighted as part of an msmessagesLangEntry + +" Set value +syn case match +syn region msmessagesSet start="(" end=")" transparent fold contains=msmessagesName keepend +syn match msmessagesName /\w\+/ nextgroup=msmessagesSetEquals skipwhite contained +syn match msmessagesSetEquals /=/ display transparent nextgroup=msmessagesNumVal skipwhite contained +syn match msmessagesNumVal display transparent "\<\d\|\.\d" contains=msmessagesNumber,msmessagesFloat,msmessagesOctalError,msmessagesOctal nextgroup=msmessagesValSep +syn match msmessagesValSep /:/ display nextgroup=msmessagesNameDef contained +syn match msmessagesNameDef /\w\+/ display contained + + +" Comments are converted to C source (by removing leading ;) +" So we highlight the comments as C +syn include @msmessagesC syntax/c.vim +unlet b:current_syntax +syn region msmessagesCComment matchgroup=msmessagesComment start=/;/ end=/$/ contains=@msmessagesC keepend + +" String and Character constants +" Highlight special characters (those which have a escape) differently +syn case ignore +syn region msmessagesLangEntry start=/\\s*=\s*\S\+\s*$/hs=e+1 end=/^\./ contains=msmessagesFormat,msmessagesLangEntryEnd,msmessagesLanguage keepend +syn match msmessagesLanguage /\" +"hex number +syn match msmessagesNumber display contained "\<0x\x\+\(u\=l\{0,2}\|ll\=u\)\>" +" Flag the first zero of an octal number as something special +syn match msmessagesOctal display contained "\<0\o\+\(u\=l\{0,2}\|ll\=u\)\>" contains=msmessagesOctalZero +syn match msmessagesOctalZero display contained "\<0" +" flag an octal number with wrong digits +syn match msmessagesOctalError display contained "\<0\o*[89]\d*" +syn match msmessagesFloat display contained "\d\+f" +"floating point number, with dot, optional exponent +syn match msmessagesFloat display contained "\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=" +"floating point number, starting with a dot, optional exponent +syn match msmessagesFloat display contained "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match msmessagesFloat display contained "\d\+e[-+]\=\d\+[fl]\=\>" +"hexadecimal floating point number, optional leading digits, with dot, with exponent +syn match msmessagesFloat display contained "0x\x*\.\x\+p[-+]\=\d\+[fl]\=\>" +"hexadecimal floating point number, with leading digits, optional dot, with exponent +syn match msmessagesFloat display contained "0x\x\+\.\=p[-+]\=\d\+[fl]\=\>" + +" Types (used in MessageIdTypedef statement) +syn case match +syn keyword msmessagesType int long short char +syn keyword msmessagesType signed unsigned +syn keyword msmessagesType size_t ssize_t sig_atomic_t +syn keyword msmessagesType int8_t int16_t int32_t int64_t +syn keyword msmessagesType uint8_t uint16_t uint32_t uint64_t +syn keyword msmessagesType int_least8_t int_least16_t int_least32_t int_least64_t +syn keyword msmessagesType uint_least8_t uint_least16_t uint_least32_t uint_least64_t +syn keyword msmessagesType int_fast8_t int_fast16_t int_fast32_t int_fast64_t +syn keyword msmessagesType uint_fast8_t uint_fast16_t uint_fast32_t uint_fast64_t +syn keyword msmessagesType intptr_t uintptr_t +syn keyword msmessagesType intmax_t uintmax_t +" Add some Windows datatypes that will be common in msmessages files +syn keyword msmessagesType BYTE CHAR SHORT SIZE_T SSIZE_T TBYTE TCHAR UCHAR USHORT +syn keyword msmessagesType DWORD DWORDLONG DWORD32 DWORD64 +syn keyword msmessagesType INT INT32 INT64 UINT UINT32 UINT64 +syn keyword msmessagesType LONG LONGLONG LONG32 LONG64 +syn keyword msmessagesType ULONG ULONGLONG ULONG32 ULONG64 + +" Sync to language entries, since they should be most common +syn sync match msmessagesLangSync grouphere msmessagesLangEntry "\ +" URL: http://www.isp.de/data/msql.vim +" Email: Subject: send syntax_vim.tgz +" Last Change: 2001 May 10 +" +" Options msql_sql_query = 1 for SQL syntax highligthing inside strings +" msql_minlines = x to sync at least x lines backwards + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'msql' +endif + +runtime! syntax/html.vim +unlet b:current_syntax + +syn cluster htmlPreproc add=msqlRegion + +syn case match + +" Internal Variables +syn keyword msqlIntVar ERRMSG contained + +" Env Variables +syn keyword msqlEnvVar SERVER_SOFTWARE SERVER_NAME SERVER_URL GATEWAY_INTERFACE contained +syn keyword msqlEnvVar SERVER_PROTOCOL SERVER_PORT REQUEST_METHOD PATH_INFO contained +syn keyword msqlEnvVar PATH_TRANSLATED SCRIPT_NAME QUERY_STRING REMOTE_HOST contained +syn keyword msqlEnvVar REMOTE_ADDR AUTH_TYPE REMOTE_USER CONTEN_TYPE contained +syn keyword msqlEnvVar CONTENT_LENGTH HTTPS HTTPS_KEYSIZE HTTPS_SECRETKEYSIZE contained +syn keyword msqlEnvVar HTTP_ACCECT HTTP_USER_AGENT HTTP_IF_MODIFIED_SINCE contained +syn keyword msqlEnvVar HTTP_FROM HTTP_REFERER contained + +" Inlclude lLite +syn include @msqlLite :p:h/lite.vim + +" Msql Region +syn region msqlRegion matchgroup=Delimiter start="D]" end=">" contains=@msqlLite,msql.* + +" sync +if exists("msql_minlines") + exec "syn sync minlines=" . msql_minlines +else + syn sync minlines=100 +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link msqlComment Comment +hi def link msqlString String +hi def link msqlNumber Number +hi def link msqlFloat Float +hi def link msqlIdentifier Identifier +hi def link msqlGlobalIdentifier Identifier +hi def link msqlIntVar Identifier +hi def link msqlEnvVar Identifier +hi def link msqlFunctions Function +hi def link msqlRepeat Repeat +hi def link msqlConditional Conditional +hi def link msqlStatement Statement +hi def link msqlType Type +hi def link msqlInclude Include +hi def link msqlDefine Define +hi def link msqlSpecialChar SpecialChar +hi def link msqlParentError Error +hi def link msqlTodo Todo +hi def link msqlOperator Operator +hi def link msqlRelation Operator + + +let b:current_syntax = "msql" + +if main_syntax == 'msql' + unlet main_syntax +endif + +" vim: ts=8 + +endif diff --git a/syntax/mupad.vim b/syntax/mupad.vim new file mode 100644 index 0000000..eab5949 --- /dev/null +++ b/syntax/mupad.vim @@ -0,0 +1,287 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: MuPAD source +" Maintainer: Dave Silvia +" Filenames: *.mu +" Date: 6/30/2004 + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Set default highlighting to Win2k +if !exists("mupad_cmdextversion") + let mupad_cmdextversion = 2 +endif + +syn case match + +syn match mupadComment "//\p*$" +syn region mupadComment start="/\*" end="\*/" + +syn region mupadString start="\"" skip=/\\"/ end="\"" + +syn match mupadOperator "(\|)\|:=\|::\|:\|;" +" boolean +syn keyword mupadOperator and or not xor +syn match mupadOperator "==>\|\<=\>" + +" Informational +syn keyword mupadSpecial FILEPATH NOTEBOOKFILE NOTEBOOKPATH +" Set-able, e.g., DIGITS:=10 +syn keyword mupadSpecial DIGITS HISTORY LEVEL +syn keyword mupadSpecial MAXLEVEL MAXDEPTH ORDER +syn keyword mupadSpecial TEXTWIDTH +" Set-able, e.g., PRETTYPRINT:=TRUE +syn keyword mupadSpecial PRETTYPRINT +" Set-able, e.g., LIBPATH:="C:\\MuPAD Pro\\mylibdir" or LIBPATH:="/usr/MuPAD Pro/mylibdir" +syn keyword mupadSpecial LIBPATH PACKAGEPATH +syn keyword mupadSpecial READPATH TESTPATH WRITEPATH +" Symbols and Constants +syn keyword mupadDefine FAIL NIL +syn keyword mupadDefine TRUE FALSE UNKNOWN +syn keyword mupadDefine complexInfinity infinity +syn keyword mupadDefine C_ CATALAN E EULER I PI Q_ R_ +syn keyword mupadDefine RD_INF RD_NINF undefined unit universe Z_ +" print() directives +syn keyword mupadDefine Unquoted NoNL KeepOrder Typeset +" domain specifics +syn keyword mupadStatement domain begin end_domain end +syn keyword mupadIdentifier inherits category axiom info doc interface +" basic programming statements +syn keyword mupadStatement proc begin end_proc +syn keyword mupadUnderlined name local option save +syn keyword mupadConditional if then elif else end_if +syn keyword mupadConditional case of do break end_case +syn keyword mupadRepeat for do next break end_for +syn keyword mupadRepeat while do next break end_while +syn keyword mupadRepeat repeat next break until end_repeat +" domain packages/libraries +syn keyword mupadType detools import linalg numeric numlib plot polylib +syn match mupadType '\' + +"syn keyword mupadFunction contains +" Functions dealing with prime numbers +syn keyword mupadFunction phi invphi mersenne nextprime numprimedivisors +syn keyword mupadFunction pollard prevprime primedivisors +" Functions operating on Lists, Matrices, Sets, ... +syn keyword mupadFunction array _index +" Evaluation +syn keyword mupadFunction float contains +" stdlib +syn keyword mupadFunction _exprseq _invert _lazy_and _lazy_or _negate +syn keyword mupadFunction _stmtseq _invert intersect minus union +syn keyword mupadFunction Ci D Ei O Re Im RootOf Si +syn keyword mupadFunction Simplify +syn keyword mupadFunction abs airyAi airyBi alias unalias anames append +syn keyword mupadFunction arcsin arccos arctan arccsc arcsec arccot +syn keyword mupadFunction arcsinh arccosh arctanh arccsch arcsech arccoth +syn keyword mupadFunction arg args array assert assign assignElements +syn keyword mupadFunction assume assuming asympt bernoulli +syn keyword mupadFunction besselI besselJ besselK besselY beta binomial bool +syn keyword mupadFunction bytes card +syn keyword mupadFunction ceil floor round trunc +syn keyword mupadFunction coeff coerce collect combine copyClosure +syn keyword mupadFunction conjugate content context contfrac +syn keyword mupadFunction debug degree degreevec delete _delete denom +syn keyword mupadFunction densematrix diff dilog dirac discont div _div +syn keyword mupadFunction divide domtype doprint erf erfc error eval evalassign +syn keyword mupadFunction evalp exp expand export unexport expose expr +syn keyword mupadFunction expr2text external extnops extop extsubsop +syn keyword mupadFunction fact fact2 factor fclose finput fname fopen fprint +syn keyword mupadFunction fread ftextinput readbitmap readdata pathname +syn keyword mupadFunction protocol read readbytes write writebytes +syn keyword mupadFunction float frac frame _frame frandom freeze unfreeze +syn keyword mupadFunction funcenv gamma gcd gcdex genident genpoly +syn keyword mupadFunction getpid getprop ground has hastype heaviside help +syn keyword mupadFunction history hold hull hypergeom icontent id +syn keyword mupadFunction ifactor igamma igcd igcdex ilcm in _in +syn keyword mupadFunction indets indexval info input int int2text +syn keyword mupadFunction interpolate interval irreducible is +syn keyword mupadFunction isprime isqrt iszero ithprime kummerU lambertW +syn keyword mupadFunction last lasterror lcm lcoeff ldegree length +syn keyword mupadFunction level lhs rhs limit linsolve lllint +syn keyword mupadFunction lmonomial ln loadmod loadproc log lterm +syn keyword mupadFunction match map mapcoeffs maprat matrix max min +syn keyword mupadFunction mod modp mods monomials multcoeffs new +syn keyword mupadFunction newDomain _next nextprime nops +syn keyword mupadFunction norm normal nterms nthcoeff nthmonomial nthterm +syn keyword mupadFunction null numer ode op operator package +syn keyword mupadFunction pade partfrac patchlevel pdivide +syn keyword mupadFunction piecewise plot plotfunc2d plotfunc3d +syn keyword mupadFunction poly poly2list polylog powermod print +syn keyword mupadFunction product protect psi quit _quit radsimp random rationalize +syn keyword mupadFunction rec rectform register reset return revert +syn keyword mupadFunction rewrite select series setuserinfo share sign signIm +syn keyword mupadFunction simplify +syn keyword mupadFunction sin cos tan csc sec cot +syn keyword mupadFunction sinh cosh tanh csch sech coth +syn keyword mupadFunction slot solve +syn keyword mupadFunction pdesolve matlinsolve matlinsolveLU toeplitzSolve +syn keyword mupadFunction vandermondeSolve fsolve odesolve odesolve2 +syn keyword mupadFunction polyroots polysysroots odesolveGeometric +syn keyword mupadFunction realroot realroots mroots lincongruence +syn keyword mupadFunction msqrts +syn keyword mupadFunction sort split sqrt strmatch strprint +syn keyword mupadFunction subs subset subsex subsop substring sum +syn keyword mupadFunction surd sysname sysorder system table taylor tbl2text +syn keyword mupadFunction tcoeff testargs testeq testtype text2expr +syn keyword mupadFunction text2int text2list text2tbl rtime time +syn keyword mupadFunction traperror type unassume unit universe +syn keyword mupadFunction unloadmod unprotect userinfo val version +syn keyword mupadFunction warning whittakerM whittakerW zeta zip + +" graphics plot:: +syn keyword mupadFunction getDefault setDefault copy modify Arc2d Arrow2d +syn keyword mupadFunction Arrow3d Bars2d Bars3d Box Boxplot Circle2d Circle3d +syn keyword mupadFunction Cone Conformal Curve2d Curve3d Cylinder Cylindrical +syn keyword mupadFunction Density Ellipse2d Function2d Function3d Hatch +syn keyword mupadFunction Histogram2d HOrbital Implicit2d Implicit3d +syn keyword mupadFunction Inequality Iteration Line2d Line3d Lsys Matrixplot +syn keyword mupadFunction MuPADCube Ode2d Ode3d Parallelogram2d Parallelogram3d +syn keyword mupadFunction Piechart2d Piechart3d Point2d Point3d Polar +syn keyword mupadFunction Polygon2d Polygon3d Raster Rectangle Sphere +syn keyword mupadFunction Ellipsoid Spherical Sum Surface SurfaceSet +syn keyword mupadFunction SurfaceSTL Tetrahedron Hexahedron Octahedron +syn keyword mupadFunction Dodecahedron Icosahedron Text2d Text3d Tube Turtle +syn keyword mupadFunction VectorField2d XRotate ZRotate Canvas CoordinateSystem2d +syn keyword mupadFunction CoordinateSystem3d Group2d Group3d Scene2d Scene3d ClippingBox +syn keyword mupadFunction Rotate2d Rotate3d Scale2d Scale3d Transform2d +syn keyword mupadFunction Transform3d Translate2d Translate3d AmbientLight +syn keyword mupadFunction Camera DistantLight PointLight SpotLight + +" graphics Attributes +" graphics Output Attributes +syn keyword mupadIdentifier OutputFile OutputOptions +" graphics Defining Attributes +syn keyword mupadIdentifier Angle AngleRange AngleBegin AngleEnd +syn keyword mupadIdentifier Area Axis AxisX AxisY AxisZ Base Top +syn keyword mupadIdentifier BaseX TopX BaseY TopY BaseZ TopZ +syn keyword mupadIdentifier BaseRadius TopRadius Cells +syn keyword mupadIdentifier Center CenterX CenterY CenterZ +syn keyword mupadIdentifier Closed ColorData CommandList Contours CoordinateType +syn keyword mupadIdentifier Data DensityData DensityFunction From To +syn keyword mupadIdentifier FromX ToX FromY ToY FromZ ToZ +syn keyword mupadIdentifier Function FunctionX FunctionY FunctionZ +syn keyword mupadIdentifier Function1 Function2 Baseline +syn keyword mupadIdentifier Generations RotationAngle IterationRules StartRule StepLength +syn keyword mupadIdentifier TurtleRules Ground Heights Moves Inequalities +syn keyword mupadIdentifier InputFile Iterations StartingPoint +syn keyword mupadIdentifier LineColorFunction FillColorFunction +syn keyword mupadIdentifier Matrix2d Matrix3d +syn keyword mupadIdentifier MeshList MeshListType MeshListNormals +syn keyword mupadIdentifier MagneticQuantumNumber MomentumQuantumNumber PrincipalQuantumNumber +syn keyword mupadIdentifier Name Normal NormalX NormalY NormalZ +syn keyword mupadIdentifier ParameterName ParameterBegin ParameterEnd ParameterRange +syn keyword mupadIdentifier Points2d Points3d Radius RadiusFunction +syn keyword mupadIdentifier Position PositionX PositionY PositionZ +syn keyword mupadIdentifier Scale ScaleX ScaleY ScaleZ Shift ShiftX ShiftY ShiftZ +syn keyword mupadIdentifier SemiAxes SemiAxisX SemiAxisY SemiAxisZ +syn keyword mupadIdentifier Tangent1 Tangent1X Tangent1Y Tangent1Z +syn keyword mupadIdentifier Tangent2 Tangent2X Tangent2Y Tangent2Z +syn keyword mupadIdentifier Text TextOrientation TextRotation +syn keyword mupadIdentifier UName URange UMin UMax VName VRange VMin VMax +syn keyword mupadIdentifier XName XRange XMin XMax YName YRange YMin YMax +syn keyword mupadIdentifier ZName ZRange ZMin ZMax ViewingBox +syn keyword mupadIdentifier ViewingBoxXMin ViewingBoxXMax ViewingBoxXRange +syn keyword mupadIdentifier ViewingBoxYMin ViewingBoxYMax ViewingBoxYRange +syn keyword mupadIdentifier ViewingBoxZMin ViewingBoxZMax ViewingBoxZRange +syn keyword mupadIdentifier Visible +" graphics Axis Attributes +syn keyword mupadIdentifier Axes AxesInFront AxesLineColor AxesLineWidth +syn keyword mupadIdentifier AxesOrigin AxesOriginX AxesOriginY AxesOriginZ +syn keyword mupadIdentifier AxesTips AxesTitleAlignment +syn keyword mupadIdentifier AxesTitleAlignmentX AxesTitleAlignmentY AxesTitleAlignmentZ +syn keyword mupadIdentifier AxesTitles XAxisTitle YAxisTitle ZAxisTitle +syn keyword mupadIdentifier AxesVisible XAxisVisible YAxisVisible ZAxisVisible +syn keyword mupadIdentifier YAxisTitleOrientation +" graphics Tick Marks Attributes +syn keyword mupadIdentifier TicksAnchor XTicksAnchor YTicksAnchor ZTicksAnchor +syn keyword mupadIdentifier TicksAt XTicksAt YTicksAt ZTicksAt +syn keyword mupadIdentifier TicksBetween XTicksBetween YTicksBetween ZTicksBetween +syn keyword mupadIdentifier TicksDistance XTicksDistance YTicksDistance ZTicksDistance +syn keyword mupadIdentifier TicksNumber XTicksNumber YTicksNumber ZTicksNumber +syn keyword mupadIdentifier TicksVisible XTicksVisible YTicksVisible ZTicksVisible +syn keyword mupadIdentifier TicksLength TicksLabelStyle +syn keyword mupadIdentifier XTicksLabelStyle YTicksLabelStyle ZTicksLabelStyle +syn keyword mupadIdentifier TicksLabelsVisible +syn keyword mupadIdentifier XTicksLabelsVisible YTicksLabelsVisible ZTicksLabelsVisible +" graphics Grid Lines Attributes +syn keyword mupadIdentifier GridInFront GridLineColor SubgridLineColor +syn keyword mupadIdentifier GridLineStyle SubgridLineStyle GridLineWidth SubgridLineWidth +syn keyword mupadIdentifier GridVisible XGridVisible YGridVisible ZGridVisible +syn keyword mupadIdentifier SubgridVisible XSubgridVisible YSubgridVisible ZSubgridVisible +" graphics Animation Attributes +syn keyword mupadIdentifier Frames TimeRange TimeBegin TimeEnd +syn keyword mupadIdentifier VisibleAfter VisibleBefore VisibleFromTo +syn keyword mupadIdentifier VisibleAfterEnd VisibleBeforeBegin +" graphics Annotation Attributes +syn keyword mupadIdentifier Footer Header FooterAlignment HeaderAlignment +syn keyword mupadIdentifier HorizontalAlignment TitleAlignment VerticalAlignment +syn keyword mupadIdentifier Legend LegendEntry LegendText +syn keyword mupadIdentifier LegendAlignment LegendPlacement LegendVisible +syn keyword mupadIdentifier Title Titles +syn keyword mupadIdentifier TitlePosition TitlePositionX TitlePositionY TitlePositionZ +" graphics Layout Attributes +syn keyword mupadIdentifier Bottom Left Height Width Layout Rows Columns +syn keyword mupadIdentifier Margin BottomMargin TopMargin LeftMargin RightMargin +syn keyword mupadIdentifier OutputUnits Spacing +" graphics Calculation Attributes +syn keyword mupadIdentifier AdaptiveMesh DiscontinuitySearch Mesh SubMesh +syn keyword mupadIdentifier UMesh USubMesh VMesh VSubMesh +syn keyword mupadIdentifier XMesh XSubMesh YMesh YSubMesh Zmesh +" graphics Camera and Lights Attributes +syn keyword mupadIdentifier CameraCoordinates CameraDirection +syn keyword mupadIdentifier CameraDirectionX CameraDirectionY CameraDirectionZ +syn keyword mupadIdentifier FocalPoint FocalPointX FocalPointY FocalPointZ +syn keyword mupadIdentifier LightColor Lighting LightIntensity OrthogonalProjection +syn keyword mupadIdentifier SpotAngle ViewingAngle +syn keyword mupadIdentifier Target TargetX TargetY TargetZ +" graphics Presentation Style and Fonts Attributes +syn keyword mupadIdentifier ArrowLength +syn keyword mupadIdentifier AxesTitleFont FooterFont HeaderFont LegendFont +syn keyword mupadIdentifier TextFont TicksLabelFont TitleFont +syn keyword mupadIdentifier BackgroundColor BackgroundColor2 BackgroundStyle +syn keyword mupadIdentifier BackgroundTransparent Billboarding BorderColor BorderWidth +syn keyword mupadIdentifier BoxCenters BoxWidths DrawMode Gap XGap YGap +syn keyword mupadIdentifier Notched NotchWidth Scaling YXRatio ZXRatio +syn keyword mupadIdentifier VerticalAsymptotesVisible VerticalAsymptotesStyle +syn keyword mupadIdentifier VerticalAsymptotesColor VerticalAsymptotesWidth +" graphics Line Style Attributes +syn keyword mupadIdentifier LineColor LineColor2 LineColorType LineStyle +syn keyword mupadIdentifier LinesVisible ULinesVisible VLinesVisible XLinesVisible +syn keyword mupadIdentifier YLinesVisible LineWidth MeshVisible +" graphics Point Style Attributes +syn keyword mupadIdentifier PointColor PointSize PointStyle PointsVisible +" graphics Surface Style Attributes +syn keyword mupadIdentifier BarStyle Shadows Color Colors FillColor FillColor2 +syn keyword mupadIdentifier FillColorTrue FillColorFalse FillColorUnknown FillColorType +syn keyword mupadIdentifier Filled FillPattern FillPatterns FillStyle +syn keyword mupadIdentifier InterpolationStyle Shading UseNormals +" graphics Arrow Style Attributes +syn keyword mupadIdentifier TipAngle TipLength TipStyle TubeDiameter +syn keyword mupadIdentifier Tubular +" graphics meta-documentation Attributes +syn keyword mupadIdentifier objectGroupsListed + + +hi def link mupadComment Comment +hi def link mupadString String +hi def link mupadOperator Operator +hi def link mupadSpecial Special +hi def link mupadStatement Statement +hi def link mupadUnderlined Underlined +hi def link mupadConditional Conditional +hi def link mupadRepeat Repeat +hi def link mupadFunction Function +hi def link mupadType Type +hi def link mupadDefine Define +hi def link mupadIdentifier Identifier + + +" TODO More comprehensive listing. + +endif diff --git a/syntax/murphi.vim b/syntax/murphi.vim new file mode 100644 index 0000000..4b3a412 --- /dev/null +++ b/syntax/murphi.vim @@ -0,0 +1,131 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Murphi model checking language +" Maintainer: Matthew Fernandez +" Last Change: 2017 Aug 27 +" Version: 2 +" Remark: Originally authored by Diego Ongaro + +if version < 600 + syntax clear +elseif exists("b:current_syntax") + finish +endif + +" Keywords are case insensitive. +" Keep these in alphabetical order. +syntax case ignore +syn keyword murphiKeyword alias +syn keyword murphiStructure array +syn keyword murphiKeyword assert +syn keyword murphiKeyword begin +syn keyword murphiType boolean +syn keyword murphiKeyword by +syn keyword murphiLabel case +syn keyword murphiKeyword clear +syn keyword murphiLabel const +syn keyword murphiRepeat do +syn keyword murphiConditional else +syn keyword murphiConditional elsif +syn keyword murphiKeyword end +syn keyword murphiKeyword endalias +syn keyword murphiRepeat endexists +syn keyword murphiRepeat endfor +syn keyword murphiRepeat endforall +syn keyword murphiKeyword endfunction +syn keyword murphiConditional endif +syn keyword murphiKeyword endprocedure +syn keyword murphiStructure endrecord +syn keyword murphiKeyword endrule +syn keyword murphiKeyword endruleset +syn keyword murphiKeyword endstartstate +syn keyword murphiConditional endswitch +syn keyword murphiRepeat endwhile +syn keyword murphiStructure enum +syn keyword murphiKeyword error +syn keyword murphiRepeat exists +syn keyword murphiBoolean false +syn keyword murphiRepeat for +syn keyword murphiRepeat forall +syn keyword murphiKeyword function +syn keyword murphiConditional if +syn keyword murphiKeyword in +syn keyword murphiKeyword interleaved +syn keyword murphiLabel invariant +syn keyword murphiFunction ismember +syn keyword murphiFunction isundefined +syn keyword murphiKeyword log +syn keyword murphiStructure of +syn keyword murphiType multiset +syn keyword murphiFunction multisetadd +syn keyword murphiFunction multisetcount +syn keyword murphiFunction multisetremove +syn keyword murphiFunction multisetremovepred +syn keyword murphiKeyword procedure +syn keyword murphiKeyword process +syn keyword murphiKeyword program +syn keyword murphiKeyword put +syn keyword murphiStructure record +syn keyword murphiKeyword return +syn keyword murphiLabel rule +syn keyword murphiLabel ruleset +syn keyword murphiType scalarset +syn keyword murphiLabel startstate +syn keyword murphiConditional switch +syn keyword murphiConditional then +syn keyword murphiRepeat to +syn keyword murphiKeyword traceuntil +syn keyword murphiBoolean true +syn keyword murphiLabel type +syn keyword murphiKeyword undefine +syn keyword murphiStructure union +syn keyword murphiLabel var +syn keyword murphiRepeat while + +syn keyword murphiTodo contained todo xxx fixme +syntax case match + +" Integers. +syn match murphiNumber "\<\d\+\>" + +" Operators and special characters. +syn match murphiOperator "[\+\-\*\/%&|=!<>:\?]\|\." +syn match murphiDelimiter "\(:[^=]\|[;,]\)" +syn match murphiSpecial "[()\[\]]" + +" Double equal sign is a common error: use one equal sign for equality testing. +syn match murphiError "==[^>]"he=e-1 +" Double && and || are errors. +syn match murphiError "&&\|||" + +" Strings. This is defined so late so that it overrides previous matches. +syn region murphiString start=+"+ end=+"+ + +" Comments. This is defined so late so that it overrides previous matches. +syn region murphiComment start="--" end="$" contains=murphiTodo +syn region murphiComment start="/\*" end="\*/" contains=murphiTodo + +" Link the rules to some groups. +hi def link murphiComment Comment +hi def link murphiString String +hi def link murphiNumber Number +hi def link murphiBoolean Boolean +hi def link murphiIdentifier Identifier +hi def link murphiFunction Function +hi def link murphiStatement Statement +hi def link murphiConditional Conditional +hi def link murphiRepeat Repeat +hi def link murphiLabel Label +hi def link murphiOperator Operator +hi def link murphiKeyword Keyword +hi def link murphiType Type +hi def link murphiStructure Structure +hi def link murphiSpecial Special +hi def link murphiDelimiter Delimiter +hi def link murphiError Error +hi def link murphiTodo Todo + +let b:current_syntax = "murphi" + +endif diff --git a/syntax/mush.vim b/syntax/mush.vim new file mode 100644 index 0000000..b69d4da --- /dev/null +++ b/syntax/mush.vim @@ -0,0 +1,219 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" MUSHcode syntax file +" Maintainer: Rick Bird +" Based on vim Syntax file by: Bek Oberin +" Last Updated: Fri Nov 04 20:28:15 2005 +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +" regular mush functions + +syntax keyword mushFunction contained @@ abs accent accname acos add after align +syntax keyword mushFunction contained allof alphamax alphamin and andflags +syntax keyword mushFunction contained andlflags andlpowers andpowers ansi aposs art +syntax keyword mushFunction contained asin atan atan2 atrlock attrcnt band baseconv +syntax keyword mushFunction contained beep before blank2tilde bnand bnot bor bound +syntax keyword mushFunction contained brackets break bxor cand cansee capstr case +syntax keyword mushFunction contained caseall cat ceil center checkpass children +syntax keyword mushFunction contained chr clone cmds cnetpost comp con config conn +syntax keyword mushFunction contained controls convsecs convtime convutcsecs cor +syntax keyword mushFunction contained cos create ctime ctu dec decrypt default +syntax keyword mushFunction contained delete die dig digest dist2d dist3d div +syntax keyword mushFunction contained division divscope doing downdiv dynhelp e +syntax keyword mushFunction contained edefault edit element elements elist elock +syntax keyword mushFunction contained emit empire empower encrypt endtag entrances +syntax keyword mushFunction contained eq escape etimefmt eval exit exp extract fdiv +syntax keyword mushFunction contained filter filterbool findable first firstof +syntax keyword mushFunction contained flags flip floor floordiv fmod fold +syntax keyword mushFunction contained folderstats followers following foreach +syntax keyword mushFunction contained fraction fullname functions get get_eval grab +syntax keyword mushFunction contained graball grep grepi gt gte hasattr hasattrp +syntax keyword mushFunction contained hasattrpval hasattrval hasdivpower hasflag +syntax keyword mushFunction contained haspower haspowergroup hastype height hidden +syntax keyword mushFunction contained home host hostname html idle idlesecs +syntax keyword mushFunction contained idle_average idle_times idle_total if ifelse +syntax keyword mushFunction contained ilev iname inc index indiv indivall insert +syntax keyword mushFunction contained inum ipaddr isdaylight isdbref isint isnum +syntax keyword mushFunction contained isword itemize items iter itext last lattr +syntax keyword mushFunction contained lcon lcstr ldelete ldivisions left lemit +syntax keyword mushFunction contained level lexits lflags link list lit ljust lmath +syntax keyword mushFunction contained ln lnum loc localize locate lock loctree log +syntax keyword mushFunction contained lparent lplayers lports lpos lsearch lsearchr +syntax keyword mushFunction contained lstats lt lte lthings lvcon lvexits lvplayers +syntax keyword mushFunction contained lvthings lwho mail maildstats mailfrom +syntax keyword mushFunction contained mailfstats mailstats mailstatus mailsubject +syntax keyword mushFunction contained mailtime map match matchall max mean median +syntax keyword mushFunction contained member merge mid min mix mod modulo modulus +syntax keyword mushFunction contained money mtime mudname mul munge mwho name nand +syntax keyword mushFunction contained nattr ncon nearby neq nexits next nor not +syntax keyword mushFunction contained nplayers nsemit nslemit nsoemit nspemit +syntax keyword mushFunction contained nsremit nszemit nthings null num nvcon +syntax keyword mushFunction contained nvexits nvplayers nvthings obj objeval objid +syntax keyword mushFunction contained objmem oemit ooref open or ord orflags +syntax keyword mushFunction contained orlflags orlpowers orpowers owner parent +syntax keyword mushFunction contained parse pcreate pemit pi pickrand playermem +syntax keyword mushFunction contained pmatch poll ports pos poss power powergroups +syntax keyword mushFunction contained powers powover program prompt pueblo quitprog +syntax keyword mushFunction contained quota r rand randword recv regedit regeditall +syntax keyword mushFunction contained regeditalli regediti regmatch regmatchi +syntax keyword mushFunction contained regrab regraball regraballi regrabi regrep +syntax keyword mushFunction contained regrepi remainder remit remove repeat replace +syntax keyword mushFunction contained rest restarts restarttime reswitch +syntax keyword mushFunction contained reswitchall reswitchalli reswitchi reverse +syntax keyword mushFunction contained revwords right rjust rloc rnum room root +syntax keyword mushFunction contained round s scan scramble search secs secure sent +syntax keyword mushFunction contained set setdiff setinter setq setr setunion sha0 +syntax keyword mushFunction contained shl shr shuffle sign signal sin sort sortby +syntax keyword mushFunction contained soundex soundlike soundslike space spellnum +syntax keyword mushFunction contained splice sql sqlescape sqrt squish ssl +syntax keyword mushFunction contained starttime stats stddev step strcat strinsert +syntax keyword mushFunction contained stripaccents stripansi strlen strmatch +syntax keyword mushFunction contained strreplace sub subj switch switchall t table +syntax keyword mushFunction contained tag tagwrap tan tel terminfo textfile +syntax keyword mushFunction contained tilde2blank time timefmt timestring tr +syntax keyword mushFunction contained trigger trim trimpenn trimtiny trunc type u +syntax keyword mushFunction contained ucstr udefault ufun uldefault ulocal updiv +syntax keyword mushFunction contained utctime v vadd val valid vcross vdim vdot +syntax keyword mushFunction contained version visible vmag vmax vmin vmul vsub +syntax keyword mushFunction contained vtattr vtcount vtcreate vtdestroy vtlcon +syntax keyword mushFunction contained vtloc vtlocate vtmaster vtname vtref vttel +syntax keyword mushFunction contained vunit wait where width wipe wordpos words +syntax keyword mushFunction contained wrap xcon xexits xget xor xplayers xthings +syntax keyword mushFunction contained xvcon xvexits xvplayers xvthings zemit zfun +syntax keyword mushFunction contained zmwho zone zwho + +" only highligh functions when they have an in-bracket immediately after +syntax match mushFunctionBrackets "\i*(" contains=mushFunction +" +" regular mush commands +syntax keyword mushAtCommandList contained @ALLHALT @ALLQUOTA @ASSERT @ATRCHOWN @ATRLOCK @ATTRIBUTE @BOOT +syntax keyword mushAtCommandList contained @BREAK @CEMIT @CHANNEL @CHAT @CHOWN @CHOWNALL @CHZONE @CHZONEALL +syntax keyword mushAtCommandList contained @CLOCK @CLONE @COBJ @COMMAND @CONFIG @CPATTR @CREATE @CRPLOG @DBCK +syntax keyword mushAtCommandList contained @DECOMPILE @DESTROY @DIG @DISABLE @DIVISION @DOING @DOLIST @DRAIN +syntax keyword mushAtCommandList contained @DUMP @EDIT @ELOCK @EMIT @EMPOWER @ENABLE @ENTRANCES @EUNLOCK @FIND +syntax keyword mushAtCommandList contained @FIRSTEXIT @FLAG @FORCE @FUNCTION @EDIT @GREP @HALT @HIDE @HOOK @KICK +syntax keyword mushAtCommandList contained @LEMIT @LEVEL @LINK @LIST @LISTMOTD @LOCK @LOG @LOGWIPE @LSET @MAIL @MALIAS +syntax keyword mushAtCommandList contained @MAP @MOTD @MVATTR @NAME @NEWPASSWORD @NOTIFY @NSCEMIT @NSEMIT @NSLEMIT +syntax keyword mushAtCommandList contained @NSOEMIT @NSPEMIT @NSPEMIT @NSREMIT @NSZEMIT @NUKE @OEMIT @OPEN @PARENT @PASSWORD +syntax keyword mushAtCommandList contained @PCREATE @PEMIT @POLL @POOR @POWERLEVEL @PROGRAM @PROMPT @PS @PURGE @QUOTA +syntax keyword mushAtCommandList contained @READCACHE @RECYCLE @REJECTMOTD @REMIT @RESTART @SCAN @SEARCH @SELECT @SET +syntax keyword mushAtCommandList contained @SHUTDOWN @SITELOCK @SNOOP @SQL @SQUOTA @STATS @SWITCH @SWEEP @SWITCH @TELEPORT +syntax keyword mushAtCommandList contained @TRIGGER @ULOCK @UNDESTROY @UNLINK @UNLOCK @UNRECYCLE @UPTIME @UUNLOCK @VERB +syntax keyword mushAtCommandList contained @VERSION @WAIT @WALL @WARNINGS @WCHECK @WHEREIS @WIPE @ZCLONE @ZEMIT +syntax match mushCommand "@\i\I*" contains=mushAtCommandList + + +syntax keyword mushCommand AHELP ANEWS ATTRIB_SET BRIEF BRIEF BUY CHANGES DESERT +syntax keyword mushCommand DISMISS DROP EMPTY ENTER EXAMINE FOLLOW GET GIVE GOTO +syntax keyword mushCommand HELP HUH_COMMAND INVENTORY INVENTORY LOOK LEAVE LOOK +syntax keyword mushCommand GOTO NEWS PAGE PAGE POSE RULES SAY SCORE SEMIPOSE +syntax keyword mushCommand SPECIALNEWS TAKE TEACH THINK UNFOLLOW USE WHISPER WHISPER +syntax keyword mushCommand WARN_ON_MISSING WHISPER WITH + +syntax match mushSpecial "\*\|!\|=\|-\|\\\|+" +syntax match mushSpecial2 contained "\*" + +syn region mushString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=mushSpecial,mushSpecial2,@Spell + + +syntax match mushIdentifier "&[^ ]\+" + +syntax match mushVariable "%r\|%t\|%cr\|%[A-Za-z0-9]\+\|%#\|##\|here" + +" numbers +syntax match mushNumber +[0-9]\++ + +" A comment line starts with a or # or " at the start of the line +" or an @@ +syntax keyword mushTodo contained TODO FIXME XXX +syntax cluster mushCommentGroup contains=mushTodo +syntax match mushComment "^\s*@@.*$" contains=mushTodo +syntax match mushComment "^#[^define|^ifdef|^else|^pragma|^ifndef|^echo|^elif|^undef|^warning].*$" contains=mushTodo +syntax match mushComment "^#$" contains=mushTodo +syntax region mushComment matchgroup=mushCommentStart start="/@@" end="@@/" contains=@mushCommentGroup,mushCommentStartError,mushCommentString,@Spell +syntax region mushCommentString contained start=+L\=\\\@" skip="\\$" end="$" end="//"me=s-1 contains=mushComment +syn match mushPreCondit display "^\s*\(%:\|#\)\s*\(else\|endif\)\>" + +syn cluster mushPreProcGroup contains=mushPreCondit,mushIncluded,mushInclude,mushDefine,mushSpecial,mushString,mushCommentSkip,mushCommentString,@mushCommentGroup,mushCommentStartError + +syn region mushIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match mushIncluded display contained "<[^>]*>" +syn match mushInclude display "^\s*\(%:\|#\)\s*include\>\s*["<]" contains=mushIncluded +syn region mushDefine start="^\s*\(%:\|#\)\s*\(define\|undef\)\>" skip="\\$" end="$" end="//"me=s-1 contains=ALLBUT,@mushPreProcGroup,@Spell +syn region mushPreProc start="^\s*\(%:\|#\)\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@mushPreProcGroup + + +syntax region mushFuncBoundaries start="\[" end="\]" contains=mushFunction,mushFlag,mushAttributes,mushNumber,mushCommand,mushVariable,mushSpecial2 + +" FLAGS +syntax keyword mushFlag PLAYER ABODE BUILDER CHOWN_OK DARK FLOATING +syntax keyword mushFlag GOING HAVEN INHERIT JUMP_OK KEY LINK_OK MONITOR +syntax keyword mushFlag NOSPOOF OPAQUE QUIET STICKY TRACE UNFINDABLE VISUAL +syntax keyword mushFlag WIZARD PARENT_OK ZONE AUDIBLE CONNECTED DESTROY_OK +syntax keyword mushFlag ENTER_OK HALTED IMMORTAL LIGHT MYOPIC PUPPET TERSE +syntax keyword mushFlag ROBOT SAFE TRANSPARENT VERBOSE CONTROL_OK COMMANDS + +syntax keyword mushAttribute aahear aclone aconnect adesc adfail adisconnect +syntax keyword mushAttribute adrop aefail aenter afail agfail ahear akill +syntax keyword mushAttribute aleave alfail alias amhear amove apay arfail +syntax keyword mushAttribute asucc atfail atport aufail ause away charges +syntax keyword mushAttribute cost desc dfail drop ealias efail enter fail +syntax keyword mushAttribute filter forwardlist gfail idesc idle infilter +syntax keyword mushAttribute inprefix kill lalias last lastsite leave lfail +syntax keyword mushAttribute listen move odesc odfail odrop oefail oenter +syntax keyword mushAttribute ofail ogfail okill oleave olfail omove opay +syntax keyword mushAttribute orfail osucc otfail otport oufail ouse oxenter +syntax keyword mushAttribute oxleave oxtport pay prefix reject rfail runout +syntax keyword mushAttribute semaphore sex startup succ tfail tport ufail +syntax keyword mushAttribute use va vb vc vd ve vf vg vh vi vj vk vl vm vn +syntax keyword mushAttribute vo vp vq vr vs vt vu vv vw vx vy vz + + + +" The default methods for highlighting. Can be overridden later +hi def link mushAttribute Constant +hi def link mushCommand Function +hi def link mushNumber Number +hi def link mushSetting PreProc +hi def link mushFunction Statement +hi def link mushVariable Identifier +hi def link mushSpecial Special +hi def link mushTodo Todo +hi def link mushFlag Special +hi def link mushIdentifier Identifier +hi def link mushDefine Macro +hi def link mushPreProc PreProc +hi def link mushPreProcGroup PreProc +hi def link mushPreCondit PreCondit +hi def link mushIncluded cString +hi def link mushInclude Include + + + +" Comments +hi def link mushCommentStart mushComment +hi def link mushComment Comment +hi def link mushCommentString mushString + + + +let b:current_syntax = "mush" + +" mush: ts=17 + +endif diff --git a/syntax/muttrc.vim b/syntax/muttrc.vim new file mode 100644 index 0000000..9a6c145 --- /dev/null +++ b/syntax/muttrc.vim @@ -0,0 +1,785 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Mutt setup files +" Original: Preben 'Peppe' Guldberg +" Maintainer: Kyle Wheeler +" Last Change: 18 August 2016 + +" This file covers mutt version 1.7.0 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Set the keyword characters +setlocal isk=@,48-57,_,- + +" handling optional variables +if !exists("use_mutt_sidebar") + let use_mutt_sidebar=0 +endif + +syn match muttrcComment "^# .*$" contains=@Spell +syn match muttrcComment "^#[^ ].*$" +syn match muttrcComment "^#$" +syn match muttrcComment "[^\\]#.*$"lc=1 + +" Escape sequences (back-tick and pipe goes here too) +syn match muttrcEscape +\\[#tnr"'Cc ]+ +syn match muttrcEscape +[`|]+ +syn match muttrcEscape +\\$+ + +" The variables takes the following arguments +"syn match muttrcString contained "=\s*[^ #"'`]\+"lc=1 contains=muttrcEscape +syn region muttrcString contained keepend start=+"+ms=e skip=+\\"+ end=+"+ contains=muttrcEscape,muttrcCommand,muttrcAction,muttrcShellString +syn region muttrcString contained keepend start=+'+ms=e skip=+\\'+ end=+'+ contains=muttrcEscape,muttrcCommand,muttrcAction +syn match muttrcStringNL contained skipwhite skipnl "\s*\\$" nextgroup=muttrcString,muttrcStringNL + +syn region muttrcShellString matchgroup=muttrcEscape keepend start=+`+ skip=+\\`+ end=+`+ contains=muttrcVarStr,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcCommand + +syn match muttrcRXChars contained /[^\\][][.*?+]\+/hs=s+1 +syn match muttrcRXChars contained /[][|()][.*?+]*/ +syn match muttrcRXChars contained /['"]^/ms=s+1 +syn match muttrcRXChars contained /$['"]/me=e-1 +syn match muttrcRXChars contained /\\/ +" Why does muttrcRXString2 work with one \ when muttrcRXString requires two? +syn region muttrcRXString contained skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcRXChars +syn region muttrcRXString contained skipwhite start=+"+ skip=+\\"+ end=+"+ contains=muttrcRXChars +syn region muttrcRXString contained skipwhite start=+[^ "'^]+ skip=+\\\s+ end=+\s+re=e-1 contains=muttrcRXChars +" For some reason, skip refuses to match backslashes here... +syn region muttrcRXString contained matchgroup=muttrcRXChars skipwhite start=+\^+ end=+[^\\]\s+re=e-1 contains=muttrcRXChars +syn region muttrcRXString contained matchgroup=muttrcRXChars skipwhite start=+\^+ end=+$\s+ contains=muttrcRXChars +syn region muttrcRXString2 contained skipwhite start=+'+ skip=+\'+ end=+'+ contains=muttrcRXChars +syn region muttrcRXString2 contained skipwhite start=+"+ skip=+\"+ end=+"+ contains=muttrcRXChars + +" these must be kept synchronized with muttrcRXString, but are intended for +" muttrcRXHooks +syn region muttrcRXHookString contained keepend skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL +syn region muttrcRXHookString contained keepend skipwhite start=+"+ skip=+\\"+ end=+"+ contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL +syn region muttrcRXHookString contained keepend skipwhite start=+[^ "'^]+ skip=+\\\s+ end=+\s+re=e-1 contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL +syn region muttrcRXHookString contained keepend skipwhite start=+\^+ end=+[^\\]\s+re=e-1 contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL +syn region muttrcRXHookString contained keepend matchgroup=muttrcRXChars skipwhite start=+\^+ end=+$\s+ contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL +syn match muttrcRXHookStringNL contained skipwhite skipnl "\s*\\$" nextgroup=muttrcRXHookString,muttrcRXHookStringNL + +" these are exclusively for args lists (e.g. -rx pat pat pat ...) +syn region muttrcRXPat contained keepend skipwhite start=+'+ skip=+\\'+ end=+'\s*+ contains=muttrcRXString nextgroup=muttrcRXPat +syn region muttrcRXPat contained keepend skipwhite start=+"+ skip=+\\"+ end=+"\s*+ contains=muttrcRXString nextgroup=muttrcRXPat +syn match muttrcRXPat contained /[^-'"#!]\S\+/ skipwhite contains=muttrcRXChars nextgroup=muttrcRXPat +syn match muttrcRXDef contained "-rx\s\+" skipwhite nextgroup=muttrcRXPat + +syn match muttrcSpecial +\(['"]\)!\1+ + +syn match muttrcSetStrAssignment contained skipwhite /=\s*\%(\\\?\$\)\?[0-9A-Za-z_-]\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable +syn region muttrcSetStrAssignment contained skipwhite keepend start=+=\s*"+hs=s+1 end=+"+ skip=+\\"+ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcString +syn region muttrcSetStrAssignment contained skipwhite keepend start=+=\s*'+hs=s+1 end=+'+ skip=+\\'+ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcString +syn match muttrcSetBoolAssignment contained skipwhite /=\s*\\\?\$\w\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable +syn match muttrcSetBoolAssignment contained skipwhite /=\s*\%(yes\|no\)/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetBoolAssignment contained skipwhite /=\s*"\%(yes\|no\)"/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetBoolAssignment contained skipwhite /=\s*'\%(yes\|no\)'/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetQuadAssignment contained skipwhite /=\s*\\\?\$\w\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable +syn match muttrcSetQuadAssignment contained skipwhite /=\s*\%(ask-\)\?\%(yes\|no\)/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetQuadAssignment contained skipwhite /=\s*"\%(ask-\)\?\%(yes\|no\)"/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetQuadAssignment contained skipwhite /=\s*'\%(ask-\)\?\%(yes\|no\)'/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetNumAssignment contained skipwhite /=\s*\\\?\$\w\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable +syn match muttrcSetNumAssignment contained skipwhite /=\s*\d\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetNumAssignment contained skipwhite /=\s*"\d\+"/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn match muttrcSetNumAssignment contained skipwhite /=\s*'\d\+'/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +" Now catch some email addresses and headers (purified version from mail.vim) +syn match muttrcEmail "[a-zA-Z0-9._-]\+@[a-zA-Z0-9./-]\+" +syn match muttrcHeader "\<\c\%(From\|To\|C[Cc]\|B[Cc][Cc]\|Reply-To\|Subject\|Return-Path\|Received\|Date\|Replied\|Attach\)\>:\=" + +syn match muttrcKeySpecial contained +\%(\\[Cc'"]\|\^\|\\[01]\d\{2}\)+ +syn match muttrcKey contained "\S\+" contains=muttrcKeySpecial,muttrcKeyName +syn region muttrcKey contained start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=muttrcKeySpecial,muttrcKeyName +syn region muttrcKey contained start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=muttrcKeySpecial,muttrcKeyName +syn match muttrcKeyName contained "\" +syn match muttrcKeyName contained "\\[trne]" +syn match muttrcKeyName contained "\c<\%(BackSpace\|BackTab\|Delete\|Down\|End\|Enter\|Esc\|Home\|Insert\|Left\|PageDown\|PageUp\|Return\|Right\|Space\|Tab\|Up\)>" +syn match muttrcKeyName contained "" + +syn keyword muttrcVarBool skipwhite contained + \ allow_8bit allow_ansi arrow_cursor ascii_chars askbcc askcc attach_split + \ auto_tag autoedit beep beep_new bounce_delivered braille_friendly + \ check_mbox_size check_new collapse_unread confirmappend confirmcreate + \ crypt_autoencrypt crypt_autopgp crypt_autosign crypt_autosmime + \ crypt_confirmhook crypt_opportunistic_encrypt crypt_replyencrypt + \ crypt_replysign crypt_replysignencrypted crypt_timestamp crypt_use_gpgme + \ crypt_use_pka delete_untag digest_collapse duplicate_threads edit_hdrs + \ edit_headers encode_from envelope_from fast_reply fcc_clear followup_to + \ force_name forw_decode forw_decrypt forw_quote forward_decode forward_decrypt + \ forward_quote hdrs header help hidden_host hide_limited hide_missing + \ hide_thread_subject hide_top_limited hide_top_missing honor_disposition + \ idn_decode idn_encode ignore_linear_white_space ignore_list_reply_to + \ imap_check_subscribed imap_list_subscribed imap_passive imap_peek + \ imap_servernoise implicit_autoview include_onlyfirst keep_flagged + \ mail_check_recent mail_check_stats mailcap_sanitize maildir_check_cur + \ maildir_header_cache_verify maildir_trash mark_old markers menu_move_off + \ menu_scroll message_cache_clean meta_key metoo mh_purge mime_forward_decode + \ narrow_tree pager_stop pgp_auto_decode pgp_auto_traditional pgp_autoencrypt + \ pgp_autoinline pgp_autosign pgp_check_exit pgp_create_traditional + \ pgp_ignore_subkeys pgp_long_ids pgp_replyencrypt pgp_replyinline pgp_replysign + \ pgp_replysignencrypted pgp_retainable_sigs pgp_show_unusable pgp_strict_enc + \ pgp_use_gpg_agent pipe_decode pipe_split pop_auth_try_all pop_last + \ postpone_encrypt postpone_encrypt_as print_decode print_split prompt_after + \ read_only reflow_space_quotes reflow_text reflow_wrap reply_self resolve + \ resume_draft_files resume_edited_draft_files reverse_alias reverse_name + \ reverse_realname rfc2047_parameters save_address save_empty save_name score + \ sidebar_folder_indent sidebar_new_mail_only sidebar_next_new_wrap + \ sidebar_short_path sidebar_sort sidebar_visible sig_dashes sig_on_top + \ smart_wrap smime_ask_cert_label smime_decrypt_use_default_key smime_is_default + \ sort_re ssl_force_tls ssl_use_sslv2 ssl_use_sslv3 ssl_use_tlsv1 + \ ssl_usesystemcerts ssl_verify_dates ssl_verify_host status_on_top strict_mime + \ strict_threads suspend text_flowed thorough_search thread_received tilde + \ ts_enabled uncollapse_jump use_8bitmime use_domain use_envelope_from use_from + \ use_idn use_ipv6 user_agent wait_key weed wrap_search write_bcc + \ nextgroup=muttrcSetBoolAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn keyword muttrcVarBool skipwhite contained + \ noallow_8bit noallow_ansi noarrow_cursor noascii_chars noaskbcc noaskcc noattach_split + \ noauto_tag noautoedit nobeep nobeep_new nobounce_delivered nobraille_friendly + \ nocheck_mbox_size nocheck_new nocollapse_unread noconfirmappend noconfirmcreate + \ nocrypt_autoencrypt nocrypt_autopgp nocrypt_autosign nocrypt_autosmime + \ nocrypt_confirmhook nocrypt_opportunistic_encrypt nocrypt_replyencrypt + \ nocrypt_replysign nocrypt_replysignencrypted nocrypt_timestamp nocrypt_use_gpgme + \ nocrypt_use_pka nodelete_untag nodigest_collapse noduplicate_threads noedit_hdrs + \ noedit_headers noencode_from noenvelope_from nofast_reply nofcc_clear nofollowup_to + \ noforce_name noforw_decode noforw_decrypt noforw_quote noforward_decode noforward_decrypt + \ noforward_quote nohdrs noheader nohelp nohidden_host nohide_limited nohide_missing + \ nohide_thread_subject nohide_top_limited nohide_top_missing nohonor_disposition + \ noidn_decode noidn_encode noignore_linear_white_space noignore_list_reply_to + \ noimap_check_subscribed noimap_list_subscribed noimap_passive noimap_peek + \ noimap_servernoise noimplicit_autoview noinclude_onlyfirst nokeep_flagged + \ nomail_check_recent nomail_check_stats nomailcap_sanitize nomaildir_check_cur + \ nomaildir_header_cache_verify nomaildir_trash nomark_old nomarkers nomenu_move_off + \ nomenu_scroll nomessage_cache_clean nometa_key nometoo nomh_purge nomime_forward_decode + \ nonarrow_tree nopager_stop nopgp_auto_decode nopgp_auto_traditional nopgp_autoencrypt + \ nopgp_autoinline nopgp_autosign nopgp_check_exit nopgp_create_traditional + \ nopgp_ignore_subkeys nopgp_long_ids nopgp_replyencrypt nopgp_replyinline nopgp_replysign + \ nopgp_replysignencrypted nopgp_retainable_sigs nopgp_show_unusable nopgp_strict_enc + \ nopgp_use_gpg_agent nopipe_decode nopipe_split nopop_auth_try_all nopop_last + \ nopostpone_encrypt nopostpone_encrypt_as noprint_decode noprint_split noprompt_after + \ noread_only noreflow_space_quotes noreflow_text noreflow_wrap noreply_self noresolve + \ noresume_draft_files noresume_edited_draft_files noreverse_alias noreverse_name + \ noreverse_realname norfc2047_parameters nosave_address nosave_empty nosave_name noscore + \ nosidebar_folder_indent nosidebar_new_mail_only nosidebar_next_new_wrap + \ nosidebar_short_path nosidebar_sort nosidebar_visible nosig_dashes nosig_on_top + \ nosmart_wrap nosmime_ask_cert_label nosmime_decrypt_use_default_key nosmime_is_default + \ nosort_re nossl_force_tls nossl_use_sslv2 nossl_use_sslv3 nossl_use_tlsv1 + \ nossl_usesystemcerts nossl_verify_dates nossl_verify_host nostatus_on_top nostrict_mime + \ nostrict_threads nosuspend notext_flowed nothorough_search nothread_received notilde + \ nots_enabled nouncollapse_jump nouse_8bitmime nouse_domain nouse_envelope_from nouse_from + \ nouse_idn nouse_ipv6 nouser_agent nowait_key noweed nowrap_search nowrite_bcc + \ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn keyword muttrcVarBool skipwhite contained + \ invallow_8bit invallow_ansi invarrow_cursor invascii_chars invaskbcc invaskcc invattach_split + \ invauto_tag invautoedit invbeep invbeep_new invbounce_delivered invbraille_friendly + \ invcheck_mbox_size invcheck_new invcollapse_unread invconfirmappend invconfirmcreate + \ invcrypt_autoencrypt invcrypt_autopgp invcrypt_autosign invcrypt_autosmime + \ invcrypt_confirmhook invcrypt_opportunistic_encrypt invcrypt_replyencrypt + \ invcrypt_replysign invcrypt_replysignencrypted invcrypt_timestamp invcrypt_use_gpgme + \ invcrypt_use_pka invdelete_untag invdigest_collapse invduplicate_threads invedit_hdrs + \ invedit_headers invencode_from invenvelope_from invfast_reply invfcc_clear invfollowup_to + \ invforce_name invforw_decode invforw_decrypt invforw_quote invforward_decode invforward_decrypt + \ invforward_quote invhdrs invheader invhelp invhidden_host invhide_limited invhide_missing + \ invhide_thread_subject invhide_top_limited invhide_top_missing invhonor_disposition + \ invidn_decode invidn_encode invignore_linear_white_space invignore_list_reply_to + \ invimap_check_subscribed invimap_list_subscribed invimap_passive invimap_peek + \ invimap_servernoise invimplicit_autoview invinclude_onlyfirst invkeep_flagged + \ invmail_check_recent invmail_check_stats invmailcap_sanitize invmaildir_check_cur + \ invmaildir_header_cache_verify invmaildir_trash invmark_old invmarkers invmenu_move_off + \ invmenu_scroll invmessage_cache_clean invmeta_key invmetoo invmh_purge invmime_forward_decode + \ invnarrow_tree invpager_stop invpgp_auto_decode invpgp_auto_traditional invpgp_autoencrypt + \ invpgp_autoinline invpgp_autosign invpgp_check_exit invpgp_create_traditional + \ invpgp_ignore_subkeys invpgp_long_ids invpgp_replyencrypt invpgp_replyinline invpgp_replysign + \ invpgp_replysignencrypted invpgp_retainable_sigs invpgp_show_unusable invpgp_strict_enc + \ invpgp_use_gpg_agent invpipe_decode invpipe_split invpop_auth_try_all invpop_last + \ invpostpone_encrypt invpostpone_encrypt_as invprint_decode invprint_split invprompt_after + \ invread_only invreflow_space_quotes invreflow_text invreflow_wrap invreply_self invresolve + \ invresume_draft_files invresume_edited_draft_files invreverse_alias invreverse_name + \ invreverse_realname invrfc2047_parameters invsave_address invsave_empty invsave_name invscore + \ invsidebar_folder_indent invsidebar_new_mail_only invsidebar_next_new_wrap + \ invsidebar_short_path invsidebar_sort invsidebar_visible invsig_dashes invsig_on_top + \ invsmart_wrap invsmime_ask_cert_label invsmime_decrypt_use_default_key invsmime_is_default + \ invsort_re invssl_force_tls invssl_use_sslv2 invssl_use_sslv3 invssl_use_tlsv1 + \ invssl_usesystemcerts invssl_verify_dates invssl_verify_host invstatus_on_top invstrict_mime + \ invstrict_threads invsuspend invtext_flowed invthorough_search invthread_received invtilde + \ invts_enabled invuncollapse_jump invuse_8bitmime invuse_domain invuse_envelope_from invuse_from + \ invuse_idn invuse_ipv6 invuser_agent invwait_key invweed invwrap_search invwrite_bcc + \ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn keyword muttrcVarQuad skipwhite contained + \ abort_nosubject abort_unmodified bounce copy crypt_verify_sig delete + \ fcc_attach forward_edit honor_followup_to include mime_forward + \ mime_forward_rest mime_fwd move pgp_mime_auto pgp_verify_sig pop_delete + \ pop_reconnect postpone print quit recall reply_to ssl_starttls + \ nextgroup=muttrcSetQuadAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn keyword muttrcVarQuad skipwhite contained + \ noabort_nosubject noabort_unmodified nobounce nocopy nocrypt_verify_sig nodelete + \ nofcc_attach noforward_edit nohonor_followup_to noinclude nomime_forward + \ nomime_forward_rest nomime_fwd nomove nopgp_mime_auto nopgp_verify_sig nopop_delete + \ nopop_reconnect nopostpone noprint noquit norecall noreply_to nossl_starttls + \ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn keyword muttrcVarQuad skipwhite contained + \ invabort_nosubject invabort_unmodified invbounce invcopy invcrypt_verify_sig invdelete + \ invfcc_attach invforward_edit invhonor_followup_to invinclude invmime_forward + \ invmime_forward_rest invmime_fwd invmove invpgp_mime_auto invpgp_verify_sig invpop_delete + \ invpop_reconnect invpostpone invprint invquit invrecall invreply_to invssl_starttls + \ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn keyword muttrcVarNum skipwhite contained + \ connect_timeout history imap_keepalive imap_pipeline_depth mail_check + \ mail_check_stats_interval menu_context net_inc pager_context pager_index_lines + \ pgp_timeout pop_checkinterval read_inc save_history score_threshold_delete + \ score_threshold_flag score_threshold_read search_context sendmail_wait + \ sidebar_width sleep_time smime_timeout ssl_min_dh_prime_bits time_inc timeout + \ wrap wrap_headers wrapmargin write_inc + \ nextgroup=muttrcSetNumAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn match muttrcFormatErrors contained /%./ + +syn match muttrcStrftimeEscapes contained /%[AaBbCcDdeFGgHhIjklMmnpRrSsTtUuVvWwXxYyZz+%]/ +syn match muttrcStrftimeEscapes contained /%E[cCxXyY]/ +syn match muttrcStrftimeEscapes contained /%O[BdeHImMSuUVwWy]/ + +syn region muttrcIndexFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcIndexFormatEscapes,muttrcIndexFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcIndexFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcIndexFormatEscapes,muttrcIndexFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcQueryFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcQueryFormatEscapes,muttrcQueryFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcAliasFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcAliasFormatEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcAliasFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcAliasFormatEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcAttachFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcAttachFormatEscapes,muttrcAttachFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcAttachFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcAttachFormatEscapes,muttrcAttachFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcComposeFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcComposeFormatEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcComposeFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcComposeFormatEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcFolderFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcFolderFormatEscapes,muttrcFolderFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcFolderFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcFolderFormatEscapes,muttrcFolderFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcMixFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcMixFormatEscapes,muttrcMixFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcMixFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcMixFormatEscapes,muttrcMixFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcPGPFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPGPFormatEscapes,muttrcPGPFormatConditionals,muttrcFormatErrors,muttrcPGPTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcPGPFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPGPFormatEscapes,muttrcPGPFormatConditionals,muttrcFormatErrors,muttrcPGPTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcPGPCmdFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPGPCmdFormatEscapes,muttrcPGPCmdFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcPGPCmdFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPGPCmdFormatEscapes,muttrcPGPCmdFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcStatusFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcStatusFormatEscapes,muttrcStatusFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcStatusFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcStatusFormatEscapes,muttrcStatusFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcPGPGetKeysFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPGPGetKeysFormatEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcPGPGetKeysFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPGPGetKeysFormatEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcSmimeFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcSmimeFormatEscapes,muttrcSmimeFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcSmimeFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcSmimeFormatEscapes,muttrcSmimeFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcStrftimeFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcStrftimeEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn region muttrcStrftimeFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcStrftimeEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +" The following info was pulled from hdr_format_str in hdrline.c +syn match muttrcIndexFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[aAbBcCdDeEfFHilLmMnNOPsStTuvXyYZ%]/ +syn match muttrcIndexFormatEscapes contained /%[>|*]./ +syn match muttrcIndexFormatConditionals contained /%?[EFHlLMNOXyY]?/ nextgroup=muttrcFormatConditionals2 +" The following info was pulled from alias_format_str in addrbook.c +syn match muttrcAliasFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[afnrt%]/ +" The following info was pulled from query_format_str in query.c +syn match muttrcQueryFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[acent%]/ +syn match muttrcQueryFormatConditionals contained /%?[e]?/ nextgroup=muttrcFormatConditionals2 +" The following info was pulled from mutt_attach_fmt in recvattach.c +syn match muttrcAttachFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[CcDdefImMnQstTuX%]/ +syn match muttrcAttachFormatEscapes contained /%[>|*]./ +syn match muttrcAttachFormatConditionals contained /%?[CcdDefInmMQstTuX]?/ nextgroup=muttrcFormatConditionals2 +syn match muttrcFormatConditionals2 contained /[^?]*?/ +" The following info was pulled from compose_format_str in compose.c +syn match muttrcComposeFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[ahlv%]/ +syn match muttrcComposeFormatEscapes contained /%[>|*]./ +" The following info was pulled from folder_format_str in browser.c +syn match muttrcFolderFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[CDdfFglNstu%]/ +syn match muttrcFolderFormatEscapes contained /%[>|*]./ +syn match muttrcFolderFormatConditionals contained /%?[N]?/ +" The following info was pulled from mix_entry_fmt in remailer.c +syn match muttrcMixFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[ncsa%]/ +syn match muttrcMixFormatConditionals contained /%?[ncsa]?/ +" The following info was pulled from crypt_entry_fmt in crypt-gpgme.c +" and pgp_entry_fmt in pgpkey.c (note that crypt_entry_fmt supports +" 'p', but pgp_entry_fmt does not). +syn match muttrcPGPFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[nkualfctp%]/ +syn match muttrcPGPFormatConditionals contained /%?[nkualfct]?/ +" The following info was pulled from _mutt_fmt_pgp_command in +" pgpinvoke.c +syn match muttrcPGPCmdFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[pfsar%]/ +syn match muttrcPGPCmdFormatConditionals contained /%?[pfsar]?/ nextgroup=muttrcFormatConditionals2 +" The following info was pulled from status_format_str in status.c +syn match muttrcStatusFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[bdfFhlLmMnopPrsStuvV%]/ +syn match muttrcStatusFormatEscapes contained /%[>|*]./ +syn match muttrcStatusFormatConditionals contained /%?[bdFlLmMnoptuV]?/ nextgroup=muttrcFormatConditionals2 +" This matches the documentation, but directly contradicts the code +" (according to the code, this should be identical to the +" muttrcPGPCmdFormatEscapes +syn match muttrcPGPGetKeysFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[r%]/ +" The following info was pulled from _mutt_fmt_smime_command in +" smime.c +syn match muttrcSmimeFormatEscapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?[Cciskaf%]/ +syn match muttrcSmimeFormatConditionals contained /%?[Cciskaf]?/ nextgroup=muttrcFormatConditionals2 + +syn region muttrcTimeEscapes contained start=+%{+ end=+}+ contains=muttrcStrftimeEscapes +syn region muttrcTimeEscapes contained start=+%\[+ end=+\]+ contains=muttrcStrftimeEscapes +syn region muttrcTimeEscapes contained start=+%(+ end=+)+ contains=muttrcStrftimeEscapes +syn region muttrcTimeEscapes contained start=+%<+ end=+>+ contains=muttrcStrftimeEscapes +syn region muttrcPGPTimeEscapes contained start=+%\[+ end=+\]+ contains=muttrcStrftimeEscapes + +syn keyword muttrcVarStr contained skipwhite attribution index_format message_format pager_format nextgroup=muttrcVarEqualsIdxFmt +syn match muttrcVarEqualsIdxFmt contained skipwhite "=" nextgroup=muttrcIndexFormatStr +syn keyword muttrcVarStr contained skipwhite alias_format nextgroup=muttrcVarEqualsAliasFmt +syn match muttrcVarEqualsAliasFmt contained skipwhite "=" nextgroup=muttrcAliasFormatStr +syn keyword muttrcVarStr contained skipwhite attach_format nextgroup=muttrcVarEqualsAttachFmt +syn match muttrcVarEqualsAttachFmt contained skipwhite "=" nextgroup=muttrcAttachFormatStr +syn keyword muttrcVarStr contained skipwhite compose_format nextgroup=muttrcVarEqualsComposeFmt +syn match muttrcVarEqualsComposeFmt contained skipwhite "=" nextgroup=muttrcComposeFormatStr +syn keyword muttrcVarStr contained skipwhite folder_format nextgroup=muttrcVarEqualsFolderFmt +syn match muttrcVarEqualsFolderFmt contained skipwhite "=" nextgroup=muttrcFolderFormatStr +syn keyword muttrcVarStr contained skipwhite mix_entry_format nextgroup=muttrcVarEqualsMixFmt +syn match muttrcVarEqualsMixFmt contained skipwhite "=" nextgroup=muttrcMixFormatStr +syn keyword muttrcVarStr contained skipwhite pgp_entry_format nextgroup=muttrcVarEqualsPGPFmt +syn match muttrcVarEqualsPGPFmt contained skipwhite "=" nextgroup=muttrcPGPFormatStr +syn keyword muttrcVarStr contained skipwhite query_format nextgroup=muttrcVarEqualsQueryFmt +syn match muttrcVarEqualsQueryFmt contained skipwhite "=" nextgroup=muttrcQueryFormatStr +syn keyword muttrcVarStr contained skipwhite pgp_decode_command pgp_verify_command pgp_decrypt_command pgp_clearsign_command pgp_sign_command pgp_encrypt_sign_command pgp_encrypt_only_command pgp_import_command pgp_export_command pgp_verify_key_command pgp_list_secring_command pgp_list_pubring_command nextgroup=muttrcVarEqualsPGPCmdFmt +syn match muttrcVarEqualsPGPCmdFmt contained skipwhite "=" nextgroup=muttrcPGPCmdFormatStr +syn keyword muttrcVarStr contained skipwhite ts_icon_format ts_status_format status_format nextgroup=muttrcVarEqualsStatusFmt +syn match muttrcVarEqualsStatusFmt contained skipwhite "=" nextgroup=muttrcStatusFormatStr +syn keyword muttrcVarStr contained skipwhite pgp_getkeys_command nextgroup=muttrcVarEqualsPGPGetKeysFmt +syn match muttrcVarEqualsPGPGetKeysFmt contained skipwhite "=" nextgroup=muttrcPGPGetKeysFormatStr +syn keyword muttrcVarStr contained skipwhite smime_decrypt_command smime_verify_command smime_verify_opaque_command smime_sign_command smime_sign_opaque_command smime_encrypt_command smime_pk7out_command smime_get_cert_command smime_get_signer_cert_command smime_import_cert_command smime_get_cert_email_command nextgroup=muttrcVarEqualsSmimeFmt +syn match muttrcVarEqualsSmimeFmt contained skipwhite "=" nextgroup=muttrcSmimeFormatStr +syn keyword muttrcVarStr contained skipwhite date_format nextgroup=muttrcVarEqualsStrftimeFmt +syn match muttrcVarEqualsStrftimeFmt contained skipwhite "=" nextgroup=muttrcStrftimeFormatStr + +syn match muttrcVPrefix contained /[?&]/ nextgroup=muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn match muttrcVarStr contained skipwhite 'my_[a-zA-Z0-9_]\+' nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn keyword muttrcVarStr contained skipwhite + \ alias_file assumed_charset attach_charset attach_sep certificate_file charset + \ config_charset content_type default_hook display_filter dotlock_program + \ dsn_notify dsn_return editor entropy_file envelope_from_address escape folder + \ forw_format forward_format from gecos_mask hdr_format header_cache + \ header_cache_compress header_cache_pagesize history_file hostname + \ imap_authenticators imap_delim_chars imap_headers imap_idle imap_login + \ imap_pass imap_user indent_str indent_string ispell locale mailcap_path mask + \ mbox mbox_type message_cachedir mh_seq_flagged mh_seq_replied mh_seq_unseen + \ mixmaster msg_format pager pgp_decryption_okay pgp_good_sign + \ pgp_mime_signature_description pgp_mime_signature_filename pgp_sign_as + \ pgp_sort_keys pipe_sep pop_authenticators pop_host pop_pass pop_user + \ post_indent_str post_indent_string postpone_encrypt_as postponed preconnect + \ print_cmd print_command query_command quote_regexp realname record + \ reply_regexp send_charset sendmail shell sidebar_delim sidebar_delim_chars + \ sidebar_divider_char sidebar_format sidebar_indent_string sidebar_sort_method + \ signature simple_search smileys smime_ca_location smime_certificates + \ smime_default_key smime_encrypt_with smime_keys smime_sign_as + \ smime_sign_digest_alg smtp_authenticators smtp_pass smtp_url sort sort_alias + \ sort_aux sort_browser spam_separator spoolfile ssl_ca_certificates_file + \ ssl_ciphers ssl_client_cert status_chars tmpdir to_chars trash ts_icon_format + \ ts_status_format tunnel visual + \ nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +" Present in 1.4.2.1 (pgp_create_traditional was a bool then) +syn keyword muttrcVarBool contained skipwhite imap_force_ssl noimap_force_ssl invimap_force_ssl nextgroup=muttrcSetBoolAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +"syn keyword muttrcVarQuad contained pgp_create_traditional nopgp_create_traditional invpgp_create_traditional +syn keyword muttrcVarStr contained skipwhite alternates nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +syn keyword muttrcMenu contained alias attach browser compose editor index pager postpone pgp mix query generic +syn match muttrcMenuList "\S\+" contained contains=muttrcMenu +syn match muttrcMenuCommas /,/ contained + +syn keyword muttrcHooks contained skipwhite account-hook charset-hook iconv-hook message-hook folder-hook mbox-hook save-hook fcc-hook fcc-save-hook send-hook send2-hook reply-hook crypt-hook + +syn keyword muttrcCommand skipwhite + \ alternative_order auto_view exec hdr_order iconv-hook ignore mailboxes + \ mailto_allow mime_lookup my_hdr pgp-hook push score sidebar_whitelist source + \ unalternative_order unalternative_order unauto_view ungroup unhdr_order + \ unignore unmailboxes unmailto_allow unmime_lookup unmono unmy_hdr unscore +syn keyword muttrcCommand skipwhite charset-hook nextgroup=muttrcRXString +syn keyword muttrcCommand skipwhite unhook nextgroup=muttrcHooks + +syn keyword muttrcCommand skipwhite spam nextgroup=muttrcSpamPattern +syn region muttrcSpamPattern contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPattern nextgroup=muttrcString,muttrcStringNL +syn region muttrcSpamPattern contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPattern nextgroup=muttrcString,muttrcStringNL + +syn keyword muttrcCommand skipwhite nospam nextgroup=muttrcNoSpamPattern +syn region muttrcNoSpamPattern contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPattern +syn region muttrcNoSpamPattern contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPattern + +syn match muttrcAttachmentsMimeType contained "[*a-z0-9_-]\+/[*a-z0-9._-]\+\s*" skipwhite nextgroup=muttrcAttachmentsMimeType +syn match muttrcAttachmentsFlag contained "[+-]\%([AI]\|inline\|attachment\)\s\+" skipwhite nextgroup=muttrcAttachmentsMimeType +syn match muttrcAttachmentsLine "^\s*\%(un\)\?attachments\s\+" skipwhite nextgroup=muttrcAttachmentsFlag + +syn match muttrcUnHighlightSpace contained "\%(\s\+\|\\$\)" + +syn keyword muttrcAsterisk contained * +syn keyword muttrcListsKeyword lists skipwhite nextgroup=muttrcGroupDef,muttrcComment +syn keyword muttrcListsKeyword unlists skipwhite nextgroup=muttrcAsterisk,muttrcComment + +syn keyword muttrcSubscribeKeyword subscribe nextgroup=muttrcGroupDef,muttrcComment +syn keyword muttrcSubscribeKeyword unsubscribe nextgroup=muttrcAsterisk,muttrcComment + +syn keyword muttrcAlternateKeyword contained alternates unalternates +syn region muttrcAlternatesLine keepend start=+^\s*\%(un\)\?alternates\s+ skip=+\\$+ end=+$+ contains=muttrcAlternateKeyword,muttrcGroupDef,muttrcRXPat,muttrcUnHighlightSpace,muttrcComment + +" muttrcVariable includes a prefix because partial strings are considered +" valid. +syn match muttrcVariable contained "\\\@]\+" contains=muttrcEmail +syn match muttrcFunction contained "\<\%(attach\|bounce\|copy\|delete\|display\|flag\|forward\|parent\|pipe\|postpone\|print\|purge\|recall\|resend\|save\|send\|tag\|undelete\)-message\>" +syn match muttrcFunction contained "\<\%(delete\|next\|previous\|read\|tag\|break\|undelete\)-thread\>" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\<\%(backward\|capitalize\|downcase\|forward\|kill\|upcase\)-word\>" +syn match muttrcFunction contained "\<\%(delete\|filter\|first\|last\|next\|pipe\|previous\|print\|save\|select\|tag\|undelete\)-entry\>" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\" +syn match muttrcFunction contained "\<\%(backspace\|backward-char\|bol\|bottom\|bottom-page\|buffy-cycle\|clear-flag\|complete\%(-query\)\?\|copy-file\|create-alias\|detach-file\|eol\|exit\|extract-keys\|\%(imap-\)\?fetch-mail\|forget-passphrase\|forward-char\|group-reply\|help\|ispell\|jump\|limit\|list-reply\|mail\|mail-key\|mark-as-new\|middle-page\|new-mime\|noop\|pgp-menu\|query\|query-append\|quit\|quote-char\|read-subthread\|redraw-screen\|refresh\|rename-file\|reply\|select-new\|set-flag\|shell-escape\|skip-quoted\|sort\|subscribe\|sync-mailbox\|top\|top-page\|transpose-chars\|unsubscribe\|untag-pattern\|verify-key\|what-key\|write-fcc\)\>" +syn keyword muttrcFunction contained imap-logout-all +if use_mutt_sidebar == 1 + syn match muttrcFunction contained "\]\{-}>" contains=muttrcBadAction,muttrcFunction,muttrcKeyName + +syn keyword muttrcCommand set skipwhite nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn keyword muttrcCommand unset skipwhite nextgroup=muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn keyword muttrcCommand reset skipwhite nextgroup=muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr +syn keyword muttrcCommand toggle skipwhite nextgroup=muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr + +" First, functions that take regular expressions: +syn match muttrcRXHookNot contained /!\s*/ skipwhite nextgroup=muttrcRXHookString,muttrcRXHookStringNL +syn match muttrcRXHooks /\<\%(account\|folder\)-hook\>/ skipwhite nextgroup=muttrcRXHookNot,muttrcRXHookString,muttrcRXHookStringNL + +" Now, functions that take patterns +syn match muttrcPatHookNot contained /!\s*/ skipwhite nextgroup=muttrcPattern +syn match muttrcPatHooks /\<\%(mbox\|crypt\)-hook\>/ skipwhite nextgroup=muttrcPatHookNot,muttrcPattern +syn match muttrcPatHooks /\<\%(message\|reply\|send\|send2\|save\|\|fcc\%(-save\)\?\)-hook\>/ skipwhite nextgroup=muttrcPatHookNot,muttrcOptPattern + +syn match muttrcBindFunction contained /\S\+\>/ skipwhite contains=muttrcFunction +syn match muttrcBindFunctionNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcBindFunction,muttrcBindFunctionNL +syn match muttrcBindKey contained /\S\+/ skipwhite contains=muttrcKey nextgroup=muttrcBindFunction,muttrcBindFunctionNL +syn match muttrcBindKeyNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcBindKey,muttrcBindKeyNL +syn match muttrcBindMenuList contained /\S\+/ skipwhite contains=muttrcMenu,muttrcMenuCommas nextgroup=muttrcBindKey,muttrcBindKeyNL +syn match muttrcBindMenuListNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcBindMenuList,muttrcBindMenuListNL +syn keyword muttrcCommand skipwhite bind nextgroup=muttrcBindMenuList,muttrcBindMenuListNL + +syn region muttrcMacroDescr contained keepend skipwhite start=+\s*\S+ms=e skip=+\\ + end=+ \|$+me=s +syn region muttrcMacroDescr contained keepend skipwhite start=+'+ms=e skip=+\\'+ end=+'+me=s +syn region muttrcMacroDescr contained keepend skipwhite start=+"+ms=e skip=+\\"+ end=+"+me=s +syn match muttrcMacroDescrNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcMacroDescr,muttrcMacroDescrNL +syn region muttrcMacroBody contained skipwhite start="\S" skip='\\ \|\\$' end=' \|$' contains=muttrcEscape,muttrcSet,muttrcUnset,muttrcReset,muttrcToggle,muttrcCommand,muttrcAction nextgroup=muttrcMacroDescr,muttrcMacroDescrNL +syn region muttrcMacroBody matchgroup=Type contained skipwhite start=+'+ms=e skip=+\\'+ end=+'\|\%(\%(\\\\\)\@]\+>/ contains=muttrcEmail nextgroup=muttrcAliasComma +syn match muttrcAliasEncEmailNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasEncEmail,muttrcAliasEncEmailNL +syn match muttrcAliasNameNoParens contained /[^<(@]\+\s\+/ nextgroup=muttrcAliasEncEmail,muttrcAliasEncEmailNL +syn region muttrcAliasName contained matchgroup=Type start=/(/ end=/)/ skipwhite +syn match muttrcAliasNameNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasName,muttrcAliasNameNL +syn match muttrcAliasENNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasEmail,muttrcAliasEncEmail,muttrcAliasNameNoParens,muttrcAliasENNL +syn match muttrcAliasKey contained /\s*[^- \t]\S\+/ skipwhite nextgroup=muttrcAliasEmail,muttrcAliasEncEmail,muttrcAliasNameNoParens,muttrcAliasENNL +syn match muttrcAliasNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasGroupDef,muttrcAliasKey,muttrcAliasNL +syn keyword muttrcCommand skipwhite alias nextgroup=muttrcAliasGroupDef,muttrcAliasKey,muttrcAliasNL + +syn match muttrcUnAliasKey contained "\s*\w\+\s*" skipwhite nextgroup=muttrcUnAliasKey,muttrcUnAliasNL +syn match muttrcUnAliasNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcUnAliasKey,muttrcUnAliasNL +syn keyword muttrcCommand skipwhite unalias nextgroup=muttrcUnAliasKey,muttrcUnAliasNL + +syn match muttrcSimplePat contained "!\?\^\?[~][ADEFgGklNOpPQRSTuUvV=$]" +syn match muttrcSimplePat contained "!\?\^\?[~][mnXz]\s*\%([<>-][0-9]\+[kM]\?\|[0-9]\+[kM]\?[-]\%([0-9]\+[kM]\?\)\?\)" +syn match muttrcSimplePat contained "!\?\^\?[~][dr]\s*\%(\%(-\?[0-9]\{1,2}\%(/[0-9]\{1,2}\%(/[0-9]\{2}\%([0-9]\{2}\)\?\)\?\)\?\%([+*-][0-9]\+[ymwd]\)*\)\|\%(\%([0-9]\{1,2}\%(/[0-9]\{1,2}\%(/[0-9]\{2}\%([0-9]\{2}\)\?\)\?\)\?\%([+*-][0-9]\+[ymwd]\)*\)-\%([0-9]\{1,2}\%(/[0-9]\{1,2}\%(/[0-9]\{2}\%([0-9]\{2}\)\?\)\?\)\?\%([+*-][0-9]\+[ymwd]\)\?\)\?\)\|\%([<>=][0-9]\+[ymwd]\)\|\%(`[^`]\+`\)\|\%(\$[a-zA-Z0-9_-]\+\)\)" contains=muttrcShellString,muttrcVariable +syn match muttrcSimplePat contained "!\?\^\?[~][bBcCefhHiLstxy]\s*" nextgroup=muttrcSimplePatRXContainer +syn match muttrcSimplePat contained "!\?\^\?[%][bBcCefhHiLstxy]\s*" nextgroup=muttrcSimplePatString +syn match muttrcSimplePat contained "!\?\^\?[=][bcCefhHiLstxy]\s*" nextgroup=muttrcSimplePatString +syn region muttrcSimplePat contained keepend start=+!\?\^\?[~](+ end=+)+ contains=muttrcSimplePat +"syn match muttrcSimplePat contained /'[^~=%][^']*/ contains=muttrcRXString +syn region muttrcSimplePatString contained keepend start=+"+ end=+"+ skip=+\\"+ +syn region muttrcSimplePatString contained keepend start=+'+ end=+'+ skip=+\\'+ +syn region muttrcSimplePatString contained keepend start=+[^ "']+ skip=+\\ + end=+\s+re=e-1 +syn region muttrcSimplePatRXContainer contained keepend start=+"+ end=+"+ skip=+\\"+ contains=muttrcRXString +syn region muttrcSimplePatRXContainer contained keepend start=+'+ end=+'+ skip=+\\'+ contains=muttrcRXString +syn region muttrcSimplePatRXContainer contained keepend start=+[^ "']+ skip=+\\ + end=+\s+re=e-1 contains=muttrcRXString +syn match muttrcSimplePatMetas contained /[(|)]/ + +syn match muttrcOptSimplePat contained skipwhite /[~=%!(^].*/ contains=muttrcSimplePat,muttrcSimplePatMetas +syn match muttrcOptSimplePat contained skipwhite /[^~=%!(^].*/ contains=muttrcRXString +syn region muttrcOptPattern contained matchgroup=Type keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcOptSimplePat,muttrcUnHighlightSpace nextgroup=muttrcString,muttrcStringNL +syn region muttrcOptPattern contained matchgroup=Type keepend skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcOptSimplePat,muttrcUnHighlightSpace nextgroup=muttrcString,muttrcStringNL +syn region muttrcOptPattern contained keepend skipwhite start=+[~](+ end=+)+ skip=+\\)+ contains=muttrcSimplePat nextgroup=muttrcString,muttrcStringNL +syn match muttrcOptPattern contained skipwhite /[~][A-Za-z]/ contains=muttrcSimplePat nextgroup=muttrcString,muttrcStringNL +syn match muttrcOptPattern contained skipwhite /[.]/ nextgroup=muttrcString,muttrcStringNL +" Keep muttrcPattern and muttrcOptPattern synchronized +syn region muttrcPattern contained matchgroup=Type keepend skipwhite start=+"+ skip=+\\"+ end=+"+ contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas +syn region muttrcPattern contained matchgroup=Type keepend skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas +syn region muttrcPattern contained keepend skipwhite start=+[~](+ end=+)+ skip=+\\)+ contains=muttrcSimplePat +syn match muttrcPattern contained skipwhite /[~][A-Za-z]/ contains=muttrcSimplePat +syn match muttrcPattern contained skipwhite /[.]/ +syn region muttrcPatternInner contained keepend start=+"[~=%!(^]+ms=s+1 skip=+\\"+ end=+"+me=e-1 contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas +syn region muttrcPatternInner contained keepend start=+'[~=%!(^]+ms=s+1 skip=+\\'+ end=+'+me=e-1 contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas + +" Colour definitions takes object, foreground and background arguments (regexps excluded). +syn match muttrcColorMatchCount contained "[0-9]\+" +syn match muttrcColorMatchCountNL contained skipwhite skipnl "\s*\\$" nextgroup=muttrcColorMatchCount,muttrcColorMatchCountNL +syn region muttrcColorRXPat contained start=+\s*'+ skip=+\\'+ end=+'\s*+ keepend skipwhite contains=muttrcRXString2 nextgroup=muttrcColorMatchCount,muttrcColorMatchCountNL +syn region muttrcColorRXPat contained start=+\s*"+ skip=+\\"+ end=+"\s*+ keepend skipwhite contains=muttrcRXString2 nextgroup=muttrcColorMatchCount,muttrcColorMatchCountNL +syn keyword muttrcColorField skipwhite contained + \ attachment body bold error hdrdefault header index indicator markers message + \ normal prompt quoted search sidebar-divider sidebar-flagged sidebar-highlight + \ sidebar-indicator sidebar-new sidebar-spoolfile signature status tilde tree + \ underline +syn match muttrcColorField contained "\" +if use_mutt_sidebar == 1 + syn keyword muttrcColorField contained sidebar_new +endif +syn keyword muttrcColor contained black blue cyan default green magenta red white yellow +syn keyword muttrcColor contained brightblack brightblue brightcyan brightdefault brightgreen brightmagenta brightred brightwhite brightyellow +syn match muttrcColor contained "\<\%(bright\)\=color\d\{1,3}\>" +" Now for the structure of the color line +syn match muttrcColorRXNL contained skipnl "\s*\\$" nextgroup=muttrcColorRXPat,muttrcColorRXNL +syn match muttrcColorBG contained /\s*[$]\?\w\+/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcColorRXPat,muttrcColorRXNL +syn match muttrcColorBGNL contained skipnl "\s*\\$" nextgroup=muttrcColorBG,muttrcColorBGNL +syn match muttrcColorFG contained /\s*[$]\?\w\+/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcColorBG,muttrcColorBGNL +syn match muttrcColorFGNL contained skipnl "\s*\\$" nextgroup=muttrcColorFG,muttrcColorFGNL +syn match muttrcColorContext contained /\s*[$]\?\w\+/ contains=muttrcColorField,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcColorFG,muttrcColorFGNL +syn match muttrcColorNL contained skipnl "\s*\\$" nextgroup=muttrcColorContext,muttrcColorNL +syn match muttrcColorKeyword contained /^\s*color\s\+/ nextgroup=muttrcColorContext,muttrcColorNL +syn region muttrcColorLine keepend start=/^\s*color\s\+\%(index\|header\)\@!/ skip=+\\$+ end=+$+ contains=muttrcColorKeyword,muttrcComment,muttrcUnHighlightSpace +" Now for the structure of the color index line +syn match muttrcPatternNL contained skipnl "\s*\\$" nextgroup=muttrcPattern,muttrcPatternNL +syn match muttrcColorBGI contained /\s*[$]\?\w\+\s*/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcPattern,muttrcPatternNL +syn match muttrcColorBGNLI contained skipnl "\s*\\$" nextgroup=muttrcColorBGI,muttrcColorBGNLI +syn match muttrcColorFGI contained /\s*[$]\?\w\+/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcColorBGI,muttrcColorBGNLI +syn match muttrcColorFGNLI contained skipnl "\s*\\$" nextgroup=muttrcColorFGI,muttrcColorFGNLI +syn match muttrcColorContextI contained /\s*\/ contains=muttrcUnHighlightSpace nextgroup=muttrcColorFGI,muttrcColorFGNLI +syn match muttrcColorNLI contained skipnl "\s*\\$" nextgroup=muttrcColorContextI,muttrcColorNLI +syn match muttrcColorKeywordI contained skipwhite /\/ nextgroup=muttrcColorContextI,muttrcColorNLI +syn region muttrcColorLine keepend skipwhite start=/\/ skip=+\\$+ end=+$+ contains=muttrcColorKeywordI,muttrcComment,muttrcUnHighlightSpace +" Now for the structure of the color header line +syn match muttrcRXPatternNL contained skipnl "\s*\\$" nextgroup=muttrcRXString,muttrcRXPatternNL +syn match muttrcColorBGH contained /\s*[$]\?\w\+\s*/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcRXString,muttrcRXPatternNL +syn match muttrcColorBGNLH contained skipnl "\s*\\$" nextgroup=muttrcColorBGH,muttrcColorBGNLH +syn match muttrcColorFGH contained /\s*[$]\?\w\+/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcColorBGH,muttrcColorBGNLH +syn match muttrcColorFGNLH contained skipnl "\s*\\$" nextgroup=muttrcColorFGH,muttrcColorFGNLH +syn match muttrcColorContextH contained /\s*\/ contains=muttrcUnHighlightSpace nextgroup=muttrcColorFGH,muttrcColorFGNLH +syn match muttrcColorNLH contained skipnl "\s*\\$" nextgroup=muttrcColorContextH,muttrcColorNLH +syn match muttrcColorKeywordH contained skipwhite /\/ nextgroup=muttrcColorContextH,muttrcColorNLH +syn region muttrcColorLine keepend skipwhite start=/\/ skip=+\\$+ end=+$+ contains=muttrcColorKeywordH,muttrcComment,muttrcUnHighlightSpace +" And now color's brother: +syn region muttrcUnColorPatterns contained skipwhite start=+\s*'+ end=+'+ skip=+\\'+ contains=muttrcPattern nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL +syn region muttrcUnColorPatterns contained skipwhite start=+\s*"+ end=+"+ skip=+\\"+ contains=muttrcPattern nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL +syn match muttrcUnColorPatterns contained skipwhite /\s*[^'"\s]\S\*/ contains=muttrcPattern nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL +syn match muttrcUnColorPatNL contained skipwhite skipnl /\s*\\$/ nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL +syn match muttrcUnColorAll contained skipwhite /[*]/ +syn match muttrcUnColorAPNL contained skipwhite skipnl /\s*\\$/ nextgroup=muttrcUnColorPatterns,muttrcUnColorAll,muttrcUnColorAPNL +syn match muttrcUnColorIndex contained skipwhite /\s*index\s\+/ nextgroup=muttrcUnColorPatterns,muttrcUnColorAll,muttrcUnColorAPNL +syn match muttrcUnColorIndexNL contained skipwhite skipnl /\s*\\$/ nextgroup=muttrcUnColorIndex,muttrcUnColorIndexNL +syn match muttrcUnColorKeyword contained skipwhite /^\s*uncolor\s\+/ nextgroup=muttrcUnColorIndex,muttrcUnColorIndexNL +syn region muttrcUnColorLine keepend start=+^\s*uncolor\s+ skip=+\\$+ end=+$+ contains=muttrcUnColorKeyword,muttrcComment,muttrcUnHighlightSpace + +" Mono are almost like color (ojects inherited from color) +syn keyword muttrcMonoAttrib contained bold none normal reverse standout underline +syn keyword muttrcMono contained mono skipwhite nextgroup=muttrcColorField +syn match muttrcMonoLine "^\s*mono\s\+\S\+" skipwhite nextgroup=muttrcMonoAttrib contains=muttrcMono + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link muttrcComment Comment +hi def link muttrcEscape SpecialChar +hi def link muttrcRXChars SpecialChar +hi def link muttrcString String +hi def link muttrcRXString String +hi def link muttrcRXString2 String +hi def link muttrcSpecial Special +hi def link muttrcHooks Type +hi def link muttrcGroupFlag Type +hi def link muttrcGroupDef Macro +hi def link muttrcAddrDef muttrcGroupFlag +hi def link muttrcRXDef muttrcGroupFlag +hi def link muttrcRXPat String +hi def link muttrcAliasGroupName Macro +hi def link muttrcAliasKey Identifier +hi def link muttrcUnAliasKey Identifier +hi def link muttrcAliasEncEmail Identifier +hi def link muttrcAliasParens Type +hi def link muttrcSetNumAssignment Number +hi def link muttrcSetBoolAssignment Boolean +hi def link muttrcSetQuadAssignment Boolean +hi def link muttrcSetStrAssignment String +hi def link muttrcEmail Special +hi def link muttrcVariableInner Special +hi def link muttrcEscapedVariable String +hi def link muttrcHeader Type +hi def link muttrcKeySpecial SpecialChar +hi def link muttrcKey Type +hi def link muttrcKeyName SpecialChar +hi def link muttrcVarBool Identifier +hi def link muttrcVarQuad Identifier +hi def link muttrcVarNum Identifier +hi def link muttrcVarStr Identifier +hi def link muttrcMenu Identifier +hi def link muttrcCommand Keyword +hi def link muttrcMacroDescr String +hi def link muttrcAction Macro +hi def link muttrcBadAction Error +hi def link muttrcBindFunction Error +hi def link muttrcBindMenuList Error +hi def link muttrcFunction Macro +hi def link muttrcGroupKeyword muttrcCommand +hi def link muttrcGroupLine Error +hi def link muttrcSubscribeKeyword muttrcCommand +hi def link muttrcSubscribeLine Error +hi def link muttrcListsKeyword muttrcCommand +hi def link muttrcListsLine Error +hi def link muttrcAlternateKeyword muttrcCommand +hi def link muttrcAlternatesLine Error +hi def link muttrcAttachmentsLine muttrcCommand +hi def link muttrcAttachmentsFlag Type +hi def link muttrcAttachmentsMimeType String +hi def link muttrcColorLine Error +hi def link muttrcColorContext Error +hi def link muttrcColorContextI Identifier +hi def link muttrcColorContextH Identifier +hi def link muttrcColorKeyword muttrcCommand +hi def link muttrcColorKeywordI muttrcColorKeyword +hi def link muttrcColorKeywordH muttrcColorKeyword +hi def link muttrcColorField Identifier +hi def link muttrcColor Type +hi def link muttrcColorFG Error +hi def link muttrcColorFGI Error +hi def link muttrcColorFGH Error +hi def link muttrcColorBG Error +hi def link muttrcColorBGI Error +hi def link muttrcColorBGH Error +hi def link muttrcMonoAttrib muttrcColor +hi def link muttrcMono muttrcCommand +hi def link muttrcSimplePat Identifier +hi def link muttrcSimplePatString Macro +hi def link muttrcSimplePatMetas Special +hi def link muttrcPattern Error +hi def link muttrcUnColorLine Error +hi def link muttrcUnColorKeyword muttrcCommand +hi def link muttrcUnColorIndex Identifier +hi def link muttrcShellString muttrcEscape +hi def link muttrcRXHooks muttrcCommand +hi def link muttrcRXHookNot Type +hi def link muttrcPatHooks muttrcCommand +hi def link muttrcPatHookNot Type +hi def link muttrcFormatConditionals2 Type +hi def link muttrcIndexFormatStr muttrcString +hi def link muttrcIndexFormatEscapes muttrcEscape +hi def link muttrcIndexFormatConditionals muttrcFormatConditionals2 +hi def link muttrcAliasFormatStr muttrcString +hi def link muttrcAliasFormatEscapes muttrcEscape +hi def link muttrcAttachFormatStr muttrcString +hi def link muttrcAttachFormatEscapes muttrcEscape +hi def link muttrcAttachFormatConditionals muttrcFormatConditionals2 +hi def link muttrcComposeFormatStr muttrcString +hi def link muttrcComposeFormatEscapes muttrcEscape +hi def link muttrcFolderFormatStr muttrcString +hi def link muttrcFolderFormatEscapes muttrcEscape +hi def link muttrcFolderFormatConditionals muttrcFormatConditionals2 +hi def link muttrcMixFormatStr muttrcString +hi def link muttrcMixFormatEscapes muttrcEscape +hi def link muttrcMixFormatConditionals muttrcFormatConditionals2 +hi def link muttrcPGPFormatStr muttrcString +hi def link muttrcPGPFormatEscapes muttrcEscape +hi def link muttrcPGPFormatConditionals muttrcFormatConditionals2 +hi def link muttrcPGPCmdFormatStr muttrcString +hi def link muttrcPGPCmdFormatEscapes muttrcEscape +hi def link muttrcPGPCmdFormatConditionals muttrcFormatConditionals2 +hi def link muttrcStatusFormatStr muttrcString +hi def link muttrcStatusFormatEscapes muttrcEscape +hi def link muttrcStatusFormatConditionals muttrcFormatConditionals2 +hi def link muttrcPGPGetKeysFormatStr muttrcString +hi def link muttrcPGPGetKeysFormatEscapes muttrcEscape +hi def link muttrcSmimeFormatStr muttrcString +hi def link muttrcSmimeFormatEscapes muttrcEscape +hi def link muttrcSmimeFormatConditionals muttrcFormatConditionals2 +hi def link muttrcTimeEscapes muttrcEscape +hi def link muttrcPGPTimeEscapes muttrcEscape +hi def link muttrcStrftimeEscapes Type +hi def link muttrcStrftimeFormatStr muttrcString +hi def link muttrcFormatErrors Error + +hi def link muttrcBindFunctionNL SpecialChar +hi def link muttrcBindKeyNL SpecialChar +hi def link muttrcBindMenuListNL SpecialChar +hi def link muttrcMacroDescrNL SpecialChar +hi def link muttrcMacroBodyNL SpecialChar +hi def link muttrcMacroKeyNL SpecialChar +hi def link muttrcMacroMenuListNL SpecialChar +hi def link muttrcColorMatchCountNL SpecialChar +hi def link muttrcColorNL SpecialChar +hi def link muttrcColorRXNL SpecialChar +hi def link muttrcColorBGNL SpecialChar +hi def link muttrcColorFGNL SpecialChar +hi def link muttrcAliasNameNL SpecialChar +hi def link muttrcAliasENNL SpecialChar +hi def link muttrcAliasNL SpecialChar +hi def link muttrcUnAliasNL SpecialChar +hi def link muttrcAliasGroupDefNL SpecialChar +hi def link muttrcAliasEncEmailNL SpecialChar +hi def link muttrcPatternNL SpecialChar +hi def link muttrcUnColorPatNL SpecialChar +hi def link muttrcUnColorAPNL SpecialChar +hi def link muttrcUnColorIndexNL SpecialChar +hi def link muttrcStringNL SpecialChar + + +let b:current_syntax = "muttrc" + +let &cpo = s:cpo_save +unlet s:cpo_save +"EOF vim: ts=8 noet tw=100 sw=8 sts=0 ft=vim + +endif diff --git a/syntax/mysql.vim b/syntax/mysql.vim new file mode 100644 index 0000000..1fe1934 --- /dev/null +++ b/syntax/mysql.vim @@ -0,0 +1,292 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: mysql +" Maintainer: Kenneth J. Pronovici +" Last Change: $LastChangedDate: 2016-04-11 10:31:04 -0500 (Mon, 11 Apr 2016) $ +" Filenames: *.mysql +" URL: ftp://cedar-solutions.com/software/mysql.vim +" Note: The definitions below are taken from the mysql user manual as of April 2002, for version 3.23 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Always ignore case +syn case ignore + +" General keywords which don't fall into other categories +syn keyword mysqlKeyword action add after aggregate all alter as asc auto_increment avg_row_length +syn keyword mysqlKeyword both by +syn keyword mysqlKeyword cascade change character check checksum column columns comment constraint create cross +syn keyword mysqlKeyword current_date current_time current_timestamp +syn keyword mysqlKeyword data database databases day day_hour day_minute day_second +syn keyword mysqlKeyword default delayed delay_key_write delete desc describe distinct distinctrow drop +syn keyword mysqlKeyword enclosed escape escaped explain +syn keyword mysqlKeyword fields file first flush for foreign from full function +syn keyword mysqlKeyword global grant grants group +syn keyword mysqlKeyword having heap high_priority hosts hour hour_minute hour_second +syn keyword mysqlKeyword identified ignore index infile inner insert insert_id into isam +syn keyword mysqlKeyword join +syn keyword mysqlKeyword key keys kill last_insert_id leading left limit lines load local lock logs long +syn keyword mysqlKeyword low_priority +syn keyword mysqlKeyword match max_rows middleint min_rows minute minute_second modify month myisam +syn keyword mysqlKeyword natural no +syn keyword mysqlKeyword on optimize option optionally order outer outfile +syn keyword mysqlKeyword pack_keys partial password primary privileges procedure process processlist +syn keyword mysqlKeyword read references reload rename replace restrict returns revoke right row rows +syn keyword mysqlKeyword second select show shutdown soname sql_big_result sql_big_selects sql_big_tables sql_log_off +syn keyword mysqlKeyword sql_log_update sql_low_priority_updates sql_select_limit sql_small_result sql_warnings starting +syn keyword mysqlKeyword status straight_join string +syn keyword mysqlKeyword table tables temporary terminated to trailing type +syn keyword mysqlKeyword unique unlock unsigned update usage use using +syn keyword mysqlKeyword values varbinary variables varying +syn keyword mysqlKeyword where with write +syn keyword mysqlKeyword year_month +syn keyword mysqlKeyword zerofill + +" Special values +syn keyword mysqlSpecial false null true + +" Strings (single- and double-quote) +syn region mysqlString start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn region mysqlString start=+'+ skip=+\\\\\|\\'+ end=+'+ + +" Numbers and hexidecimal values +syn match mysqlNumber "-\=\<[0-9]*\>" +syn match mysqlNumber "-\=\<[0-9]*\.[0-9]*\>" +syn match mysqlNumber "-\=\<[0-9][0-9]*e[+-]\=[0-9]*\>" +syn match mysqlNumber "-\=\<[0-9]*\.[0-9]*e[+-]\=[0-9]*\>" +syn match mysqlNumber "\<0x[abcdefABCDEF0-9]*\>" + +" User variables +syn match mysqlVariable "@\a*[A-Za-z0-9]*\([._]*[A-Za-z0-9]\)*" + +" Escaped column names +syn match mysqlEscaped "`[^`]*`" + +" Comments (c-style, mysql-style and modified sql-style) +syn region mysqlComment start="/\*" end="\*/" +syn match mysqlComment "#.*" +syn match mysqlComment "--\_s.*" +syn sync ccomment mysqlComment + +" Column types +" +" This gets a bit ugly. There are two different problems we have to +" deal with. +" +" The first problem is that some keywords like 'float' can be used +" both with and without specifiers, i.e. 'float', 'float(1)' and +" 'float(@var)' are all valid. We have to account for this and we +" also have to make sure that garbage like floatn or float_(1) is not +" highlighted. +" +" The second problem is that some of these keywords are included in +" function names. For instance, year() is part of the name of the +" dayofyear() function, and the dec keyword (no parenthesis) is part of +" the name of the decode() function. + +syn keyword mysqlType tinyint smallint mediumint int integer bigint +syn keyword mysqlType date datetime time bit bool +syn keyword mysqlType tinytext mediumtext longtext text +syn keyword mysqlType tinyblob mediumblob longblob blob +syn region mysqlType start="float\W" end="."me=s-1 +syn region mysqlType start="float$" end="."me=s-1 +syn region mysqlType start="float(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="double\W" end="."me=s-1 +syn region mysqlType start="double$" end="."me=s-1 +syn region mysqlType start="double(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="double precision\W" end="."me=s-1 +syn region mysqlType start="double precision$" end="."me=s-1 +syn region mysqlType start="double precision(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="real\W" end="."me=s-1 +syn region mysqlType start="real$" end="."me=s-1 +syn region mysqlType start="real(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="numeric(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="dec\W" end="."me=s-1 +syn region mysqlType start="dec$" end="."me=s-1 +syn region mysqlType start="dec(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="decimal\W" end="."me=s-1 +syn region mysqlType start="decimal$" end="."me=s-1 +syn region mysqlType start="decimal(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="\Wtimestamp\W" end="."me=s-1 +syn region mysqlType start="\Wtimestamp$" end="."me=s-1 +syn region mysqlType start="\Wtimestamp(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="^timestamp\W" end="."me=s-1 +syn region mysqlType start="^timestamp$" end="."me=s-1 +syn region mysqlType start="^timestamp(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="\Wyear(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="^year(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="char(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="varchar(" end=")" contains=mysqlNumber,mysqlVariable +syn region mysqlType start="enum(" end=")" contains=mysqlString,mysqlVariable +syn region mysqlType start="\Wset(" end=")" contains=mysqlString,mysqlVariable +syn region mysqlType start="^set(" end=")" contains=mysqlString,mysqlVariable + +" Logical, string and numeric operators +syn keyword mysqlOperator between not and or is in like regexp rlike binary exists +syn region mysqlOperator start="isnull(" end=")" contains=ALL +syn region mysqlOperator start="coalesce(" end=")" contains=ALL +syn region mysqlOperator start="interval(" end=")" contains=ALL + +" Control flow functions +syn keyword mysqlFlow case when then else end +syn region mysqlFlow start="ifnull(" end=")" contains=ALL +syn region mysqlFlow start="nullif(" end=")" contains=ALL +syn region mysqlFlow start="if(" end=")" contains=ALL + +" General Functions +" +" I'm leery of just defining keywords for functions, since according to the MySQL manual: +" +" Function names do not clash with table or column names. For example, ABS is a +" valid column name. The only restriction is that for a function call, no spaces +" are allowed between the function name and the `(' that follows it. +" +" This means that if I want to highlight function names properly, I have to use a +" region to define them, not just a keyword. This will probably cause the syntax file +" to load more slowly, but at least it will be 'correct'. + +syn region mysqlFunction start="abs(" end=")" contains=ALL +syn region mysqlFunction start="acos(" end=")" contains=ALL +syn region mysqlFunction start="adddate(" end=")" contains=ALL +syn region mysqlFunction start="ascii(" end=")" contains=ALL +syn region mysqlFunction start="asin(" end=")" contains=ALL +syn region mysqlFunction start="atan(" end=")" contains=ALL +syn region mysqlFunction start="atan2(" end=")" contains=ALL +syn region mysqlFunction start="avg(" end=")" contains=ALL +syn region mysqlFunction start="benchmark(" end=")" contains=ALL +syn region mysqlFunction start="bin(" end=")" contains=ALL +syn region mysqlFunction start="bit_and(" end=")" contains=ALL +syn region mysqlFunction start="bit_count(" end=")" contains=ALL +syn region mysqlFunction start="bit_or(" end=")" contains=ALL +syn region mysqlFunction start="ceiling(" end=")" contains=ALL +syn region mysqlFunction start="character_length(" end=")" contains=ALL +syn region mysqlFunction start="char_length(" end=")" contains=ALL +syn region mysqlFunction start="concat(" end=")" contains=ALL +syn region mysqlFunction start="concat_ws(" end=")" contains=ALL +syn region mysqlFunction start="connection_id(" end=")" contains=ALL +syn region mysqlFunction start="conv(" end=")" contains=ALL +syn region mysqlFunction start="cos(" end=")" contains=ALL +syn region mysqlFunction start="cot(" end=")" contains=ALL +syn region mysqlFunction start="count(" end=")" contains=ALL +syn region mysqlFunction start="curdate(" end=")" contains=ALL +syn region mysqlFunction start="curtime(" end=")" contains=ALL +syn region mysqlFunction start="date_add(" end=")" contains=ALL +syn region mysqlFunction start="date_format(" end=")" contains=ALL +syn region mysqlFunction start="date_sub(" end=")" contains=ALL +syn region mysqlFunction start="dayname(" end=")" contains=ALL +syn region mysqlFunction start="dayofmonth(" end=")" contains=ALL +syn region mysqlFunction start="dayofweek(" end=")" contains=ALL +syn region mysqlFunction start="dayofyear(" end=")" contains=ALL +syn region mysqlFunction start="decode(" end=")" contains=ALL +syn region mysqlFunction start="degrees(" end=")" contains=ALL +syn region mysqlFunction start="elt(" end=")" contains=ALL +syn region mysqlFunction start="encode(" end=")" contains=ALL +syn region mysqlFunction start="encrypt(" end=")" contains=ALL +syn region mysqlFunction start="exp(" end=")" contains=ALL +syn region mysqlFunction start="export_set(" end=")" contains=ALL +syn region mysqlFunction start="extract(" end=")" contains=ALL +syn region mysqlFunction start="field(" end=")" contains=ALL +syn region mysqlFunction start="find_in_set(" end=")" contains=ALL +syn region mysqlFunction start="floor(" end=")" contains=ALL +syn region mysqlFunction start="format(" end=")" contains=ALL +syn region mysqlFunction start="from_days(" end=")" contains=ALL +syn region mysqlFunction start="from_unixtime(" end=")" contains=ALL +syn region mysqlFunction start="get_lock(" end=")" contains=ALL +syn region mysqlFunction start="greatest(" end=")" contains=ALL +syn region mysqlFunction start="group_unique_users(" end=")" contains=ALL +syn region mysqlFunction start="hex(" end=")" contains=ALL +syn region mysqlFunction start="inet_aton(" end=")" contains=ALL +syn region mysqlFunction start="inet_ntoa(" end=")" contains=ALL +syn region mysqlFunction start="instr(" end=")" contains=ALL +syn region mysqlFunction start="lcase(" end=")" contains=ALL +syn region mysqlFunction start="least(" end=")" contains=ALL +syn region mysqlFunction start="length(" end=")" contains=ALL +syn region mysqlFunction start="load_file(" end=")" contains=ALL +syn region mysqlFunction start="locate(" end=")" contains=ALL +syn region mysqlFunction start="log(" end=")" contains=ALL +syn region mysqlFunction start="log10(" end=")" contains=ALL +syn region mysqlFunction start="lower(" end=")" contains=ALL +syn region mysqlFunction start="lpad(" end=")" contains=ALL +syn region mysqlFunction start="ltrim(" end=")" contains=ALL +syn region mysqlFunction start="make_set(" end=")" contains=ALL +syn region mysqlFunction start="master_pos_wait(" end=")" contains=ALL +syn region mysqlFunction start="max(" end=")" contains=ALL +syn region mysqlFunction start="md5(" end=")" contains=ALL +syn region mysqlFunction start="mid(" end=")" contains=ALL +syn region mysqlFunction start="min(" end=")" contains=ALL +syn region mysqlFunction start="mod(" end=")" contains=ALL +syn region mysqlFunction start="monthname(" end=")" contains=ALL +syn region mysqlFunction start="now(" end=")" contains=ALL +syn region mysqlFunction start="oct(" end=")" contains=ALL +syn region mysqlFunction start="octet_length(" end=")" contains=ALL +syn region mysqlFunction start="ord(" end=")" contains=ALL +syn region mysqlFunction start="period_add(" end=")" contains=ALL +syn region mysqlFunction start="period_diff(" end=")" contains=ALL +syn region mysqlFunction start="pi(" end=")" contains=ALL +syn region mysqlFunction start="position(" end=")" contains=ALL +syn region mysqlFunction start="pow(" end=")" contains=ALL +syn region mysqlFunction start="power(" end=")" contains=ALL +syn region mysqlFunction start="quarter(" end=")" contains=ALL +syn region mysqlFunction start="radians(" end=")" contains=ALL +syn region mysqlFunction start="rand(" end=")" contains=ALL +syn region mysqlFunction start="release_lock(" end=")" contains=ALL +syn region mysqlFunction start="repeat(" end=")" contains=ALL +syn region mysqlFunction start="reverse(" end=")" contains=ALL +syn region mysqlFunction start="round(" end=")" contains=ALL +syn region mysqlFunction start="rpad(" end=")" contains=ALL +syn region mysqlFunction start="rtrim(" end=")" contains=ALL +syn region mysqlFunction start="sec_to_time(" end=")" contains=ALL +syn region mysqlFunction start="session_user(" end=")" contains=ALL +syn region mysqlFunction start="sign(" end=")" contains=ALL +syn region mysqlFunction start="sin(" end=")" contains=ALL +syn region mysqlFunction start="soundex(" end=")" contains=ALL +syn region mysqlFunction start="space(" end=")" contains=ALL +syn region mysqlFunction start="sqrt(" end=")" contains=ALL +syn region mysqlFunction start="std(" end=")" contains=ALL +syn region mysqlFunction start="stddev(" end=")" contains=ALL +syn region mysqlFunction start="strcmp(" end=")" contains=ALL +syn region mysqlFunction start="subdate(" end=")" contains=ALL +syn region mysqlFunction start="substring(" end=")" contains=ALL +syn region mysqlFunction start="substring_index(" end=")" contains=ALL +syn region mysqlFunction start="subtime(" end=")" contains=ALL +syn region mysqlFunction start="sum(" end=")" contains=ALL +syn region mysqlFunction start="sysdate(" end=")" contains=ALL +syn region mysqlFunction start="system_user(" end=")" contains=ALL +syn region mysqlFunction start="tan(" end=")" contains=ALL +syn region mysqlFunction start="time_format(" end=")" contains=ALL +syn region mysqlFunction start="time_to_sec(" end=")" contains=ALL +syn region mysqlFunction start="to_days(" end=")" contains=ALL +syn region mysqlFunction start="trim(" end=")" contains=ALL +syn region mysqlFunction start="ucase(" end=")" contains=ALL +syn region mysqlFunction start="unique_users(" end=")" contains=ALL +syn region mysqlFunction start="unix_timestamp(" end=")" contains=ALL +syn region mysqlFunction start="upper(" end=")" contains=ALL +syn region mysqlFunction start="user(" end=")" contains=ALL +syn region mysqlFunction start="version(" end=")" contains=ALL +syn region mysqlFunction start="week(" end=")" contains=ALL +syn region mysqlFunction start="weekday(" end=")" contains=ALL +syn region mysqlFunction start="yearweek(" end=")" contains=ALL + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link mysqlKeyword Statement +hi def link mysqlSpecial Special +hi def link mysqlString String +hi def link mysqlNumber Number +hi def link mysqlVariable Identifier +hi def link mysqlComment Comment +hi def link mysqlType Type +hi def link mysqlOperator Statement +hi def link mysqlFlow Statement +hi def link mysqlFunction Function + + +let b:current_syntax = "mysql" + + +endif diff --git a/syntax/n1ql.vim b/syntax/n1ql.vim new file mode 100644 index 0000000..b17034a --- /dev/null +++ b/syntax/n1ql.vim @@ -0,0 +1,438 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: N1QL / Couchbase Server +" Maintainer: Eugene Ciurana +" Version: 1.0 +" Source: https://github.com/pr3d4t0r/n1ql-vim-syntax +" +" License: Vim is Charityware. n1ql.vim syntax is Charityware. +" (c) Copyright 2017 by Eugene Ciurana / pr3d4t0r. Licensed +" under the standard VIM LICENSE - Vim command :help uganda.txt +" for details. +" +" Questions, comments: +" https://ciurana.eu/pgp, https://keybase.io/pr3d4t0r +" +" vim: set fileencoding=utf-8: + + +if exists("b:current_syntax") + finish +endif + + +syn case ignore + +syn keyword n1qlSpecial DATASTORES +syn keyword n1qlSpecial DUAL +syn keyword n1qlSpecial FALSE +syn keyword n1qlSpecial INDEXES +syn keyword n1qlSpecial KEYSPACES +syn keyword n1qlSpecial MISSING +syn keyword n1qlSpecial NAMESPACES +syn keyword n1qlSpecial NULL +syn keyword n1qlSpecial TRUE + + +" +" *** keywords *** +" +syn keyword n1qlKeyword ALL +syn keyword n1qlKeyword ANY +syn keyword n1qlKeyword ASC +syn keyword n1qlKeyword BEGIN +syn keyword n1qlKeyword BETWEEN +syn keyword n1qlKeyword BREAK +syn keyword n1qlKeyword BUCKET +syn keyword n1qlKeyword CALL +syn keyword n1qlKeyword CASE +syn keyword n1qlKeyword CAST +syn keyword n1qlKeyword CLUSTER +syn keyword n1qlKeyword COLLATE +syn keyword n1qlKeyword COLLECTION +syn keyword n1qlKeyword CONNECT +syn keyword n1qlKeyword CONTINUE +syn keyword n1qlKeyword CORRELATE +syn keyword n1qlKeyword COVER +syn keyword n1qlKeyword DATABASE +syn keyword n1qlKeyword DATASET +syn keyword n1qlKeyword DATASTORE +syn keyword n1qlKeyword DECLARE +syn keyword n1qlKeyword DECREMENT +syn keyword n1qlKeyword DERIVED +syn keyword n1qlKeyword DESC +syn keyword n1qlKeyword DESCRIBE +syn keyword n1qlKeyword DO +syn keyword n1qlKeyword EACH +syn keyword n1qlKeyword ELEMENT +syn keyword n1qlKeyword ELSE +syn keyword n1qlKeyword END +syn keyword n1qlKeyword EVERY +syn keyword n1qlKeyword EXCLUDE +syn keyword n1qlKeyword EXISTS +syn keyword n1qlKeyword FETCH +syn keyword n1qlKeyword FIRST +syn keyword n1qlKeyword FLATTEN +syn keyword n1qlKeyword FOR +syn keyword n1qlKeyword FORCE +syn keyword n1qlKeyword FROM +syn keyword n1qlKeyword FUNCTION +syn keyword n1qlKeyword GROUP +syn keyword n1qlKeyword GSI +syn keyword n1qlKeyword HAVING +syn keyword n1qlKeyword IF +syn keyword n1qlKeyword IGNORE +syn keyword n1qlKeyword INCLUDE +syn keyword n1qlKeyword INCREMENT +syn keyword n1qlKeyword INDEX +syn keyword n1qlKeyword INITIAL +syn keyword n1qlKeyword INLINE +syn keyword n1qlKeyword INNER +syn keyword n1qlKeyword INTO +syn keyword n1qlKeyword KEY +syn keyword n1qlKeyword KEYS +syn keyword n1qlKeyword KEYSPACE +syn keyword n1qlKeyword KNOWN +syn keyword n1qlKeyword LAST +syn keyword n1qlKeyword LET +syn keyword n1qlKeyword LETTING +syn keyword n1qlKeyword LIMIT +syn keyword n1qlKeyword LOOP +syn keyword n1qlKeyword LSM +syn keyword n1qlKeyword MAP +syn keyword n1qlKeyword MAPPING +syn keyword n1qlKeyword MATCHED +syn keyword n1qlKeyword MATERIALIZED +syn keyword n1qlKeyword MERGE +syn keyword n1qlKeyword NAMESPACE +syn keyword n1qlKeyword NEST +syn keyword n1qlKeyword OPTION +syn keyword n1qlKeyword ORDER +syn keyword n1qlKeyword OUTER +syn keyword n1qlKeyword OVER +syn keyword n1qlKeyword PARSE +syn keyword n1qlKeyword PARTITION +syn keyword n1qlKeyword PASSWORD +syn keyword n1qlKeyword PATH +syn keyword n1qlKeyword POOL +syn keyword n1qlKeyword PRIMARY +syn keyword n1qlKeyword PRIVATE +syn keyword n1qlKeyword PRIVILEGE +syn keyword n1qlKeyword PROCEDURE +syn keyword n1qlKeyword PUBLIC +syn keyword n1qlKeyword REALM +syn keyword n1qlKeyword REDUCE +syn keyword n1qlKeyword RETURN +syn keyword n1qlKeyword RETURNING +syn keyword n1qlKeyword ROLE +syn keyword n1qlKeyword SATISFIES +syn keyword n1qlKeyword SCHEMA +syn keyword n1qlKeyword SELF +syn keyword n1qlKeyword SEMI +syn keyword n1qlKeyword SHOW +syn keyword n1qlKeyword START +syn keyword n1qlKeyword STATISTICS +syn keyword n1qlKeyword SYSTEM +syn keyword n1qlKeyword THEN +syn keyword n1qlKeyword TRANSACTION +syn keyword n1qlKeyword TRIGGER +syn keyword n1qlKeyword UNDER +syn keyword n1qlKeyword UNKNOWN +syn keyword n1qlKeyword UNSET +syn keyword n1qlKeyword USE +syn keyword n1qlKeyword USER +syn keyword n1qlKeyword USING +syn keyword n1qlKeyword VALIDATE +syn keyword n1qlKeyword VALUE +syn keyword n1qlKeyword VALUED +syn keyword n1qlKeyword VALUES +syn keyword n1qlKeyword VIEW +syn keyword n1qlKeyword WHEN +syn keyword n1qlKeyword WHERE +syn keyword n1qlKeyword WHILE +syn keyword n1qlKeyword WITHIN +syn keyword n1qlKeyword WORK + + +" +" *** functions *** +" +syn keyword n1qlOperator ABS +syn keyword n1qlOperator ACOS +syn keyword n1qlOperator ARRAY_AGG +syn keyword n1qlOperator ARRAY_APPEND +syn keyword n1qlOperator ARRAY_AVG +syn keyword n1qlOperator ARRAY_CONCAT +syn keyword n1qlOperator ARRAY_CONTAINS +syn keyword n1qlOperator ARRAY_COUNT +syn keyword n1qlOperator ARRAY_DISTINCT +syn keyword n1qlOperator ARRAY_FLATTEN +syn keyword n1qlOperator ARRAY_IFNULL +syn keyword n1qlOperator ARRAY_INSERT +syn keyword n1qlOperator ARRAY_INTERSECT +syn keyword n1qlOperator ARRAY_LENGTH +syn keyword n1qlOperator ARRAY_MAX +syn keyword n1qlOperator ARRAY_MIN +syn keyword n1qlOperator ARRAY_POSITION +syn keyword n1qlOperator ARRAY_PREPEND +syn keyword n1qlOperator ARRAY_PUT +syn keyword n1qlOperator ARRAY_RANGE +syn keyword n1qlOperator ARRAY_REMOVE +syn keyword n1qlOperator ARRAY_REPEAT +syn keyword n1qlOperator ARRAY_REPLACE +syn keyword n1qlOperator ARRAY_REVERSE +syn keyword n1qlOperator ARRAY_SORT +syn keyword n1qlOperator ARRAY_START +syn keyword n1qlOperator ARRAY_SUM +syn keyword n1qlOperator ARRAY_SYMDIFF +syn keyword n1qlOperator ARRAY_UNION +syn keyword n1qlOperator ASIN +syn keyword n1qlOperator ATAN +syn keyword n1qlOperator ATAN2 +syn keyword n1qlOperator AVG +syn keyword n1qlOperator BASE64 +syn keyword n1qlOperator BASE64_DECODE +syn keyword n1qlOperator BASE64_ENCODE +syn keyword n1qlOperator CEIL +syn keyword n1qlOperator CLOCK_LOCAL +syn keyword n1qlOperator CLOCK_STR +syn keyword n1qlOperator CLOCK_TZ +syn keyword n1qlOperator CLOCK_UTC +syn keyword n1qlOperator CLOCL_MILLIS +syn keyword n1qlOperator CONTAINS +syn keyword n1qlOperator COS +syn keyword n1qlOperator COUNT +syn keyword n1qlOperator DATE_ADD_MILLIS +syn keyword n1qlOperator DATE_ADD_STR +syn keyword n1qlOperator DATE_DIFF_MILLIS +syn keyword n1qlOperator DATE_DIFF_STR +syn keyword n1qlOperator DATE_FORMAT_STR +syn keyword n1qlOperator DATE_PART_MILLIS +syn keyword n1qlOperator DATE_PART_STR +syn keyword n1qlOperator DATE_RANGE_MILLIS +syn keyword n1qlOperator DATE_RANGE_STR +syn keyword n1qlOperator DATE_TRUC_STR +syn keyword n1qlOperator DATE_TRUNC_MILLIS +syn keyword n1qlOperator DECODE_JSON +syn keyword n1qlOperator DEGREES +syn keyword n1qlOperator DURATION_TO_STR +syn keyword n1qlOperator E +syn keyword n1qlOperator ENCODED_SIZE +syn keyword n1qlOperator ENCODE_JSON +syn keyword n1qlOperator EXP +syn keyword n1qlOperator FLOOR +syn keyword n1qlOperator GREATEST +syn keyword n1qlOperator IFINF +syn keyword n1qlOperator IFMISSING +syn keyword n1qlOperator IFMISSINGORNULL +syn keyword n1qlOperator IFNAN +syn keyword n1qlOperator IFNANORINF +syn keyword n1qlOperator IFNULL +syn keyword n1qlOperator INITCAP +syn keyword n1qlOperator ISARRAY +syn keyword n1qlOperator ISATOM +syn keyword n1qlOperator ISBOOLEAN +syn keyword n1qlOperator ISNUMBER +syn keyword n1qlOperator ISOBJECT +syn keyword n1qlOperator ISSTRING +syn keyword n1qlOperator LEAST +syn keyword n1qlOperator LENGTH +syn keyword n1qlOperator LN +syn keyword n1qlOperator LOG +syn keyword n1qlOperator LOWER +syn keyword n1qlOperator LTRIM +syn keyword n1qlOperator MAX +syn keyword n1qlOperator META +syn keyword n1qlOperator MILLIS +syn keyword n1qlOperator MILLIS_TO_LOCAL +syn keyword n1qlOperator MILLIS_TO_STR +syn keyword n1qlOperator MILLIS_TO_TZ +syn keyword n1qlOperator MILLIS_TO_UTC +syn keyword n1qlOperator MILLIS_TO_ZONE_NAME +syn keyword n1qlOperator MIN +syn keyword n1qlOperator MISSINGIF +syn keyword n1qlOperator NANIF +syn keyword n1qlOperator NEGINFIF +syn keyword n1qlOperator NOW_LOCAL +syn keyword n1qlOperator NOW_MILLIS +syn keyword n1qlOperator NOW_STR +syn keyword n1qlOperator NOW_TZ +syn keyword n1qlOperator NOW_UTC +syn keyword n1qlOperator NULLIF +syn keyword n1qlOperator OBJECT_ADD +syn keyword n1qlOperator OBJECT_CONCAT +syn keyword n1qlOperator OBJECT_INNER_PAIRS +syn keyword n1qlOperator OBJECT_INNER_VALUES +syn keyword n1qlOperator OBJECT_LENGTH +syn keyword n1qlOperator OBJECT_NAMES +syn keyword n1qlOperator OBJECT_PAIRS +syn keyword n1qlOperator OBJECT_PUT +syn keyword n1qlOperator OBJECT_REMOVE +syn keyword n1qlOperator OBJECT_RENAME +syn keyword n1qlOperator OBJECT_REPLACE +syn keyword n1qlOperator OBJECT_UNWRAP +syn keyword n1qlOperator OBJECT_VALUES +syn keyword n1qlOperator PI +syn keyword n1qlOperator POLY_LENGTH +syn keyword n1qlOperator POSINIF +syn keyword n1qlOperator POSITION +syn keyword n1qlOperator POWER +syn keyword n1qlOperator RADIANS +syn keyword n1qlOperator RANDOM +syn keyword n1qlOperator REGEXP_CONTAINS +syn keyword n1qlOperator REGEXP_LIKE +syn keyword n1qlOperator REGEXP_POSITION +syn keyword n1qlOperator REGEXP_REPLACE +syn keyword n1qlOperator REPEAT +syn keyword n1qlOperator REPLACE +syn keyword n1qlOperator REVERSE +syn keyword n1qlOperator ROUND +syn keyword n1qlOperator RTRIM +syn keyword n1qlOperator SIGN +syn keyword n1qlOperator SIN +syn keyword n1qlOperator SPLIT +syn keyword n1qlOperator SQRT +syn keyword n1qlOperator STR_TO_DURATION +syn keyword n1qlOperator STR_TO_MILLIS +syn keyword n1qlOperator STR_TO_TZ +syn keyword n1qlOperator STR_TO_UTC +syn keyword n1qlOperator STR_TO_ZONE_NAME +syn keyword n1qlOperator SUBSTR +syn keyword n1qlOperator SUFFIXES +syn keyword n1qlOperator SUM +syn keyword n1qlOperator TAN +syn keyword n1qlOperator TITLE +syn keyword n1qlOperator TOARRAY +syn keyword n1qlOperator TOATOM +syn keyword n1qlOperator TOBOOLEAN +syn keyword n1qlOperator TOKENS +syn keyword n1qlOperator TONUMBER +syn keyword n1qlOperator TOOBJECT +syn keyword n1qlOperator TOSTRING +syn keyword n1qlOperator TRIM +syn keyword n1qlOperator TRUNC +syn keyword n1qlOperator TYPE +syn keyword n1qlOperator UPPER +syn keyword n1qlOperator UUID +syn keyword n1qlOperator WEEKDAY_MILLIS +syn keyword n1qlOperator WEEKDAY_STR + + +" +" *** operators *** +" +syn keyword n1qlOperator AND +syn keyword n1qlOperator AS +syn keyword n1qlOperator BY +syn keyword n1qlOperator DISTINCT +syn keyword n1qlOperator EXCEPT +syn keyword n1qlOperator ILIKE +syn keyword n1qlOperator IN +syn keyword n1qlOperator INTERSECT +syn keyword n1qlOperator IS +syn keyword n1qlOperator JOIN +syn keyword n1qlOperator LEFT +syn keyword n1qlOperator LIKE +syn keyword n1qlOperator MINUS +syn keyword n1qlOperator NEST +syn keyword n1qlOperator NESTING +syn keyword n1qlOperator NOT +syn keyword n1qlOperator OFFSET +syn keyword n1qlOperator ON +syn keyword n1qlOperator OR +syn keyword n1qlOperator OUT +syn keyword n1qlOperator RIGHT +syn keyword n1qlOperator SOME +syn keyword n1qlOperator TO +syn keyword n1qlOperator UNION +syn keyword n1qlOperator UNIQUE +syn keyword n1qlOperator UNNEST +syn keyword n1qlOperator VIA +syn keyword n1qlOperator WITH +syn keyword n1qlOperator XOR + + +" +" *** statements *** +" +syn keyword n1qlStatement ALTER +syn keyword n1qlStatement ANALYZE +syn keyword n1qlStatement BUILD +syn keyword n1qlStatement COMMIT +syn keyword n1qlStatement CREATE +syn keyword n1qlStatement DELETE +syn keyword n1qlStatement DROP +syn keyword n1qlStatement EXECUTE +syn keyword n1qlStatement EXPLAIN +syn keyword n1qlStatement GRANT +syn keyword n1qlStatement INFER +syn keyword n1qlStatement INSERT +syn keyword n1qlStatement MERGE +syn keyword n1qlStatement PREPARE +syn keyword n1qlStatement RENAME +syn keyword n1qlStatement REVOKE +syn keyword n1qlStatement ROLLBACK +syn keyword n1qlStatement SELECT +syn keyword n1qlStatement SET +syn keyword n1qlStatement TRUNCATE +syn keyword n1qlStatement UPDATE +syn keyword n1qlStatement UPSERT + + +" +" *** types *** +" +syn keyword n1qlType ARRAY +syn keyword n1qlType BINARY +syn keyword n1qlType BOOLEAN +syn keyword n1qlType NUMBER +syn keyword n1qlType OBJECT +syn keyword n1qlType RAW +syn keyword n1qlType STRING + + +" +" *** strings and characters *** +" +syn region n1qlString start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn region n1qlString start=+'+ skip=+\\\\\|\\'+ end=+'+ +syn region n1qlBucketSpec start=+`+ skip=+\\\\\|\\'+ end=+`+ + + +" +" *** numbers *** +" +syn match n1qlNumber "-\=\<\d*\.\=[0-9_]\>" + + +" +" *** comments *** +" +syn region n1qlComment start="/\*" end="\*/" contains=n1qlTODO +syn match n1qlComment "--.*$" contains=n1qlTODO +syn sync ccomment n1qlComment + + +" +" *** TODO *** +" +syn keyword n1qlTODO contained TODO FIXME XXX DEBUG NOTE + + +" +" *** enable *** +" +hi def link n1qlBucketSpec Underlined +hi def link n1qlComment Comment +hi def link n1qlKeyword Macro +hi def link n1qlOperator Function +hi def link n1qlSpecial Special +hi def link n1qlStatement Statement +hi def link n1qlString String +hi def link n1qlTODO Todo +hi def link n1qlType Type + +let b:current_syntax = "n1ql" + +endif diff --git a/syntax/named.vim b/syntax/named.vim new file mode 100644 index 0000000..2d34fca --- /dev/null +++ b/syntax/named.vim @@ -0,0 +1,233 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: BIND configuration file +" Maintainer: Nick Hibma +" Last change: 2007-01-30 +" Filenames: named.conf, rndc.conf +" Location: http://www.van-laarhoven.org/vim/syntax/named.vim +" +" Previously maintained by glory hump and updated by Marcin +" Dalecki. +" +" This file could do with a lot of improvements, so comments are welcome. +" Please submit the named.conf (segment) with any comments. +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +setlocal iskeyword=.,-,48-58,A-Z,a-z,_ + +syn sync match namedSync grouphere NONE "^(zone|controls|acl|key)" + +let s:save_cpo = &cpo +set cpo-=C + +" BIND configuration file + +syn match namedComment "//.*" +syn match namedComment "#.*" +syn region namedComment start="/\*" end="\*/" +syn region namedString start=/"/ end=/"/ contained +" --- omitted trailing semicolon +syn match namedError /[^;{#]$/ + +" --- top-level keywords + +syn keyword namedInclude include nextgroup=namedString skipwhite +syn keyword namedKeyword acl key nextgroup=namedIntIdent skipwhite +syn keyword namedKeyword server nextgroup=namedIdentifier skipwhite +syn keyword namedKeyword controls nextgroup=namedSection skipwhite +syn keyword namedKeyword trusted-keys nextgroup=namedIntSection skipwhite +syn keyword namedKeyword logging nextgroup=namedLogSection skipwhite +syn keyword namedKeyword options nextgroup=namedOptSection skipwhite +syn keyword namedKeyword zone nextgroup=namedZoneString skipwhite + +" --- Identifier: name of following { ... } Section +syn match namedIdentifier contained /\k\+/ nextgroup=namedSection skipwhite +" --- IntIdent: name of following IntSection +syn match namedIntIdent contained /"\=\k\+"\=/ nextgroup=namedIntSection skipwhite + +" --- Section: { ... } clause +syn region namedSection contained start=+{+ end=+};+ contains=namedSection,namedIntKeyword + +" --- IntSection: section that does not contain other sections +syn region namedIntSection contained start=+{+ end=+}+ contains=namedIntKeyword,namedError + +" --- IntKeyword: keywords contained within `{ ... }' sections only +" + these keywords are contained within `key' and `acl' sections +syn keyword namedIntKeyword contained key algorithm +syn keyword namedIntKeyword contained secret nextgroup=namedString skipwhite + +" + these keywords are contained within `server' section only +syn keyword namedIntKeyword contained bogus support-ixfr nextgroup=namedBool,namedNotBool skipwhite +syn keyword namedIntKeyword contained transfers nextgroup=namedNumber,namedNotNumber skipwhite +syn keyword namedIntKeyword contained transfer-format +syn keyword namedIntKeyword contained keys nextgroup=namedIntSection skipwhite + +" + these keywords are contained within `controls' section only +syn keyword namedIntKeyword contained inet nextgroup=namedIPaddr,namedIPerror skipwhite +syn keyword namedIntKeyword contained unix nextgroup=namedString skipwhite +syn keyword namedIntKeyword contained port perm owner group nextgroup=namedNumber,namedNotNumber skipwhite +syn keyword namedIntKeyword contained allow nextgroup=namedIntSection skipwhite + +" + these keywords are contained within `update-policy' section only +syn keyword namedIntKeyword contained grant nextgroup=namedString skipwhite +syn keyword namedIntKeyword contained name self subdomain wildcard nextgroup=namedString skipwhite +syn keyword namedIntKeyword TXT A PTR NS SOA A6 CNAME MX ANY skipwhite + +" --- options +syn region namedOptSection contained start=+{+ end=+};+ contains=namedOption,namedCNOption,namedComment,namedParenError + +syn keyword namedOption contained version directory +\ nextgroup=namedString skipwhite +syn keyword namedOption contained named-xfer dump-file pid-file +\ nextgroup=namedString skipwhite +syn keyword namedOption contained mem-statistics-file statistics-file +\ nextgroup=namedString skipwhite +syn keyword namedOption contained auth-nxdomain deallocate-on-exit +\ nextgroup=namedBool,namedNotBool skipwhite +syn keyword namedOption contained dialup fake-iquery fetch-glue +\ nextgroup=namedBool,namedNotBool skipwhite +syn keyword namedOption contained has-old-clients host-statistics +\ nextgroup=namedBool,namedNotBool skipwhite +syn keyword namedOption contained maintain-ixfr-base multiple-cnames +\ nextgroup=namedBool,namedNotBool skipwhite +syn keyword namedOption contained notify recursion rfc2308-type1 +\ nextgroup=namedBool,namedNotBool skipwhite +syn keyword namedOption contained use-id-pool treat-cr-as-space +\ nextgroup=namedBool,namedNotBool skipwhite +syn keyword namedOption contained also-notify forwarders +\ nextgroup=namedIPlist skipwhite +syn keyword namedOption contained forward check-names +syn keyword namedOption contained allow-query allow-transfer allow-recursion +\ nextgroup=namedAML skipwhite +syn keyword namedOption contained blackhole listen-on +\ nextgroup=namedIntSection skipwhite +syn keyword namedOption contained lame-ttl max-transfer-time-in +\ nextgroup=namedNumber,namedNotNumber skipwhite +syn keyword namedOption contained max-ncache-ttl min-roots +\ nextgroup=namedNumber,namedNotNumber skipwhite +syn keyword namedOption contained serial-queries transfers-in +\ nextgroup=namedNumber,namedNotNumber skipwhite +syn keyword namedOption contained transfers-out transfers-per-ns +syn keyword namedOption contained transfer-format +syn keyword namedOption contained transfer-source +\ nextgroup=namedIPaddr,namedIPerror skipwhite +syn keyword namedOption contained max-ixfr-log-size +\ nextgroup=namedNumber,namedNotNumber skipwhite +syn keyword namedOption contained coresize datasize files stacksize +syn keyword namedOption contained cleaning-interval interface-interval statistics-interval heartbeat-interval +\ nextgroup=namedNumber,namedNotNumber skipwhite +syn keyword namedOption contained topology sortlist rrset-order +\ nextgroup=namedIntSection skipwhite + +syn match namedOption contained /\/ nextgroup=namedSpareDot +syn match namedDomain contained /"\."/ms=s+1,me=e-1 +syn match namedSpareDot contained /\./ + +" --- syntax errors +syn match namedIllegalDom contained /"\S*[^-A-Za-z0-9.[:space:]]\S*"/ms=s+1,me=e-1 +syn match namedIPerror contained /\<\S*[^0-9.[:space:];]\S*/ +syn match namedEParenError contained +{+ +syn match namedParenError +}\([^;]\|$\)+ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link namedComment Comment +hi def link namedInclude Include +hi def link namedKeyword Keyword +hi def link namedIntKeyword Keyword +hi def link namedIdentifier Identifier +hi def link namedIntIdent Identifier + +hi def link namedString String +hi def link namedBool Type +hi def link namedNotBool Error +hi def link namedNumber Number +hi def link namedNotNumber Error + +hi def link namedOption namedKeyword +hi def link namedLogOption namedKeyword +hi def link namedCNOption namedKeyword +hi def link namedQSKeywords Type +hi def link namedCNKeywords Type +hi def link namedLogCategory Type +hi def link namedIPaddr Number +hi def link namedDomain Identifier +hi def link namedZoneOpt namedKeyword +hi def link namedZoneType Type +hi def link namedParenError Error +hi def link namedEParenError Error +hi def link namedIllegalDom Error +hi def link namedIPerror Error +hi def link namedSpareDot Error +hi def link namedError Error + + +let &cpo = s:save_cpo +unlet s:save_cpo + +let b:current_syntax = "named" + +" vim: ts=17 + +endif diff --git a/syntax/nanorc.vim b/syntax/nanorc.vim new file mode 100644 index 0000000..727c5b5 --- /dev/null +++ b/syntax/nanorc.vim @@ -0,0 +1,247 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: nanorc(5) - GNU nano configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword nanorcTodo contained TODO FIXME XXX NOTE + +syn region nanorcComment display oneline start='^\s*#' end='$' + \ contains=nanorcTodo,@Spell + +syn match nanorcBegin display '^' + \ nextgroup=nanorcKeyword,nanorcComment + \ skipwhite + +syn keyword nanorcKeyword contained set unset + \ nextgroup=nanorcBoolOption, + \ nanorcStringOption,nanorcNumberOption + \ skipwhite + +syn keyword nanorcKeyword contained syntax + \ nextgroup=nanorcSynGroupName skipwhite + +syn keyword nanorcKeyword contained color + \ nextgroup=@nanorcFGColor skipwhite + +syn keyword nanorcBoolOption contained autoindent backup const cut + \ historylog morespace mouse multibuffer + \ noconvert nofollow nohelp nowrap preserve + \ rebinddelete regexp smarthome smooth suspend + \ tempfile view + +syn keyword nanorcStringOption contained backupdir brackets operatingdir + \ punct quotestr speller whitespace + \ nextgroup=nanorcString skipwhite + +syn keyword nanorcNumberOption contained fill tabsize + \ nextgroup=nanorcNumber skipwhite + +syn region nanorcSynGroupName contained display oneline start=+"+ + \ end=+"\ze\%([[:blank:]]\|$\)+ + \ nextgroup=nanorcRegexes skipwhite + +syn match nanorcString contained display '".*"' + +syn region nanorcRegexes contained display oneline start=+"+ + \ end=+"\ze\%([[:blank:]]\|$\)+ + \ nextgroup=nanorcRegexes skipwhite + +syn match nanorcNumber contained display '[+-]\=\<\d\+\>' + +syn cluster nanorcFGColor contains=nanorcFGWhite,nanorcFGBlack, + \ nanorcFGRed,nanorcFGBlue,nanorcFGGreen, + \ nanorcFGYellow,nanorcFGMagenta,nanorcFGCyan, + \ nanorcFGBWhite,nanorcFGBBlack,nanorcFGBRed, + \ nanorcFGBBlue,nanorcFGBGreen,nanorcFGBYellow, + \ nanorcFGBMagenta,nanorcFGBCyan + +syn keyword nanorcFGWhite contained white + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBlack contained black + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGRed contained red + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBlue contained blue + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGGreen contained green + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGYellow contained yellow + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGMagenta contained magenta + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGCyan contained cyan + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBWhite contained brightwhite + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBBlack contained brightblack + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBRed contained brightred + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBBlue contained brightblue + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBGreen contained brightgreen + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBYellow contained brightyellow + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBMagenta contained brightmagenta + \ nextgroup=@nanorcFGSpec skipwhite + +syn keyword nanorcFGBCyan contained brightcyan + \ nextgroup=@nanorcFGSpec skipwhite + +syn cluster nanorcBGColor contains=nanorcBGWhite,nanorcBGBlack, + \ nanorcBGRed,nanorcBGBlue,nanorcBGGreen, + \ nanorcBGYellow,nanorcBGMagenta,nanorcBGCyan, + \ nanorcBGBWhite,nanorcBGBBlack,nanorcBGBRed, + \ nanorcBGBBlue,nanorcBGBGreen,nanorcBGBYellow, + \ nanorcBGBMagenta,nanorcBGBCyan + +syn keyword nanorcBGWhite contained white + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBlack contained black + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGRed contained red + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBlue contained blue + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGGreen contained green + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGYellow contained yellow + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGMagenta contained magenta + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGCyan contained cyan + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBWhite contained brightwhite + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBBlack contained brightblack + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBRed contained brightred + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBBlue contained brightblue + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBGreen contained brightgreen + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBYellow contained brightyellow + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBMagenta contained brightmagenta + \ nextgroup=@nanorcBGSpec skipwhite + +syn keyword nanorcBGBCyan contained brightcyan + \ nextgroup=@nanorcBGSpec skipwhite + +syn match nanorcBGColorSep contained ',' nextgroup=@nanorcBGColor + +syn cluster nanorcFGSpec contains=nanorcBGColorSep,nanorcRegexes, + \ nanorcStartRegion + +syn cluster nanorcBGSpec contains=nanorcRegexes,nanorcStartRegion + +syn keyword nanorcStartRegion contained start nextgroup=nanorcStartRegionEq + +syn match nanorcStartRegionEq contained '=' nextgroup=nanorcRegion + +syn region nanorcRegion contained display oneline start=+"+ + \ end=+"\ze\%([[:blank:]]\|$\)+ + \ nextgroup=nanorcEndRegion skipwhite + +syn keyword nanorcEndRegion contained end nextgroup=nanorcStartRegionEq + +syn match nanorcEndRegionEq contained '=' nextgroup=nanorcRegex + +syn region nanorcRegex contained display oneline start=+"+ + \ end=+"\ze\%([[:blank:]]\|$\)+ + +hi def link nanorcTodo Todo +hi def link nanorcComment Comment +hi def link nanorcKeyword Keyword +hi def link nanorcBoolOption Identifier +hi def link nanorcStringOption Identifier +hi def link nanorcNumberOption Identifier +hi def link nanorcSynGroupName String +hi def link nanorcString String +hi def link nanorcRegexes nanorcString +hi def link nanorcNumber Number +hi def nanorcFGWhite ctermfg=Gray guifg=Gray +hi def nanorcFGBlack ctermfg=Black guifg=Black +hi def nanorcFGRed ctermfg=DarkRed guifg=DarkRed +hi def nanorcFGBlue ctermfg=DarkBlue guifg=DarkBlue +hi def nanorcFGGreen ctermfg=DarkGreen guifg=DarkGreen +hi def nanorcFGYellow ctermfg=Brown guifg=Brown +hi def nanorcFGMagenta ctermfg=DarkMagenta guifg=DarkMagenta +hi def nanorcFGCyan ctermfg=DarkCyan guifg=DarkCyan +hi def nanorcFGBWhite ctermfg=White guifg=White +hi def nanorcFGBBlack ctermfg=DarkGray guifg=DarkGray +hi def nanorcFGBRed ctermfg=Red guifg=Red +hi def nanorcFGBBlue ctermfg=Blue guifg=Blue +hi def nanorcFGBGreen ctermfg=Green guifg=Green +hi def nanorcFGBYellow ctermfg=Yellow guifg=Yellow +hi def nanorcFGBMagenta ctermfg=Magenta guifg=Magenta +hi def nanorcFGBCyan ctermfg=Cyan guifg=Cyan +hi def link nanorcBGColorSep Normal +hi def nanorcBGWhite ctermbg=Gray guibg=Gray +hi def nanorcBGBlack ctermbg=Black guibg=Black +hi def nanorcBGRed ctermbg=DarkRed guibg=DarkRed +hi def nanorcBGBlue ctermbg=DarkBlue guibg=DarkBlue +hi def nanorcBGGreen ctermbg=DarkGreen guibg=DarkGreen +hi def nanorcBGYellow ctermbg=Brown guibg=Brown +hi def nanorcBGMagenta ctermbg=DarkMagenta guibg=DarkMagenta +hi def nanorcBGCyan ctermbg=DarkCyan guibg=DarkCyan +hi def nanorcBGBWhite ctermbg=White guibg=White +hi def nanorcBGBBlack ctermbg=DarkGray guibg=DarkGray +hi def nanorcBGBRed ctermbg=Red guibg=Red +hi def nanorcBGBBlue ctermbg=Blue guibg=Blue +hi def nanorcBGBGreen ctermbg=Green guibg=Green +hi def nanorcBGBYellow ctermbg=Yellow guibg=Yellow +hi def nanorcBGBMagenta ctermbg=Magenta guibg=Magenta +hi def nanorcBGBCyan ctermbg=Cyan guibg=Cyan +hi def link nanorcStartRegion Type +hi def link nanorcStartRegionEq Operator +hi def link nanorcRegion nanorcString +hi def link nanorcEndRegion Type +hi def link nanorcEndRegionEq Operator +hi def link nanorcRegex nanoRegexes + +let b:current_syntax = "nanorc" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/nasm.vim b/syntax/nasm.vim new file mode 100644 index 0000000..bbac542 --- /dev/null +++ b/syntax/nasm.vim @@ -0,0 +1,530 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: NASM - The Netwide Assembler (v0.98) +" Maintainer: Andrii Sokolov +" Original Author: Manuel M.H. Stol +" Former Maintainer: Manuel M.H. Stol +" Contributors: Leonard König (C string highlighting) +" Last Change: 2017 Jan 23 +" NASM Home: http://www.nasm.us/ + + + +" Setup Syntax: +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +" Assembler syntax is case insensetive +syn case ignore + + + +" Vim search and movement commands on identifers +" Comments at start of a line inside which to skip search for indentifiers +setlocal comments=:; +" Identifier Keyword characters (defines \k) +setlocal iskeyword=@,48-57,#,$,.,?,@-@,_,~ + + +" Comments: +syn region nasmComment start=";" keepend end="$" contains=@nasmGrpInComments +syn region nasmSpecialComment start=";\*\*\*" keepend end="$" +syn keyword nasmInCommentTodo contained TODO FIXME XXX[XXXXX] +syn cluster nasmGrpInComments contains=nasmInCommentTodo +syn cluster nasmGrpComments contains=@nasmGrpInComments,nasmComment,nasmSpecialComment + + + +" Label Identifiers: +" in NASM: 'Everything is a Label' +" Definition Label = label defined by %[i]define or %[i]assign +" Identifier Label = label defined as first non-keyword on a line or %[i]macro +syn match nasmLabelError "$\=\(\d\+\K\|[#.@]\|\$\$\k\)\k*\>" +syn match nasmLabel "\<\(\h\|[?@]\)\k*\>" +syn match nasmLabel "[\$\~]\(\h\|[?@]\)\k*\>"lc=1 +" Labels starting with one or two '.' are special +syn match nasmLocalLabel "\<\.\(\w\|[#$?@~]\)\k*\>" +syn match nasmLocalLabel "\<\$\.\(\w\|[#$?@~]\)\k*\>"ms=s+1 +if !exists("nasm_no_warn") + syn match nasmLabelWarn "\<\~\=\$\=[_.][_.\~]*\>" +endif +if exists("nasm_loose_syntax") + syn match nasmSpecialLabel "\<\.\.@\k\+\>" + syn match nasmSpecialLabel "\<\$\.\.@\k\+\>"ms=s+1 + if !exists("nasm_no_warn") + syn match nasmLabelWarn "\<\$\=\.\.@\(\d\|[#$\.~]\)\k*\>" + endif + " disallow use of nasm internal label format + syn match nasmLabelError "\<\$\=\.\.@\d\+\.\k*\>" +else + syn match nasmSpecialLabel "\<\.\.@\(\h\|[?@]\)\k*\>" + syn match nasmSpecialLabel "\<\$\.\.@\(\h\|[?@]\)\k*\>"ms=s+1 +endif +" Labels can be dereferenced with '$' to destinguish them from reserved words +syn match nasmLabelError "\<\$\K\k*\s*:" +syn match nasmLabelError "^\s*\$\K\k*\>" +syn match nasmLabelError "\<\~\s*\(\k*\s*:\|\$\=\.\k*\)" + + + +" Constants: +syn match nasmStringError +["'`]+ +" NASM is case sensitive here: eg. u-prefix allows for 4-digit, U-prefix for +" 8-digit Unicode characters +syn case match +" one-char escape-sequences +syn match nasmCStringEscape display contained "\\[’"‘\\\?abtnvfre]" +" hex and octal numbers +syn match nasmCStringEscape display contained "\\\(x\x\{2}\|\o\{1,3}\)" +" Unicode characters +syn match nasmCStringEscape display contained "\\\(u\x\{4}\|U\x\{8}\)" +" ISO C99 format strings (copied from cFormat in runtime/syntax/c.vim) +syn match nasmCStringFormat display "%\(\d\+\$\)\=[-+' #0*]*\(\d*\|\*\|\*\d\+\$\)\(\.\(\d*\|\*\|\*\d\+\$\)\)\=\([hlLjzt]\|ll\|hh\)\=\([aAbdiuoxXDOUfFeEgGcCsSpn]\|\[\^\=.[^]]*\]\)" contained +syn match nasmCStringFormat display "%%" contained +syn match nasmString +\("[^"]\{-}"\|'[^']\{-}'\)+ +" Highlight C escape- and format-sequences within ``-strings +syn match nasmCString +\(`[^`]\{-}`\)+ contains=nasmCStringEscape,nasmCStringFormat extend +syn case ignore +syn match nasmBinNumber "\<[0-1]\+b\>" +syn match nasmBinNumber "\<\~[0-1]\+b\>"lc=1 +syn match nasmOctNumber "\<\o\+q\>" +syn match nasmOctNumber "\<\~\o\+q\>"lc=1 +syn match nasmDecNumber "\<\d\+\>" +syn match nasmDecNumber "\<\~\d\+\>"lc=1 +syn match nasmHexNumber "\<\(\d\x*h\|0x\x\+\|\$\d\x*\)\>" +syn match nasmHexNumber "\<\~\(\d\x*h\|0x\x\+\|\$\d\x*\)\>"lc=1 +syn match nasmFltNumber "\<\d\+\.\d*\(e[+-]\=\d\+\)\=\>" +syn keyword nasmFltNumber Inf Infinity Indefinite NaN SNaN QNaN +syn match nasmNumberError "\<\~\s*\d\+\.\d*\(e[+-]\=\d\+\)\=\>" + + +" Netwide Assembler Storage Directives: +" Storage types +syn keyword nasmTypeError DF EXTRN FWORD RESF TBYTE +syn keyword nasmType FAR NEAR SHORT +syn keyword nasmType BYTE WORD DWORD QWORD DQWORD HWORD DHWORD TWORD +syn keyword nasmType CDECL FASTCALL NONE PASCAL STDCALL +syn keyword nasmStorage DB DW DD DQ DDQ DT +syn keyword nasmStorage RESB RESW RESD RESQ RESDQ REST +syn keyword nasmStorage EXTERN GLOBAL COMMON +" Structured storage types +syn match nasmTypeError "\<\(AT\|I\=\(END\)\=\(STRUCT\=\|UNION\)\|I\=END\)\>" +syn match nasmStructureLabel contained "\<\(AT\|I\=\(END\)\=\(STRUCT\=\|UNION\)\|I\=END\)\>" +" structures cannot be nested (yet) -> use: 'keepend' and 're=' +syn cluster nasmGrpCntnStruc contains=ALLBUT,@nasmGrpInComments,nasmMacroDef,@nasmGrpInMacros,@nasmGrpInPreCondits,nasmStructureDef,@nasmGrpInStrucs +syn region nasmStructureDef transparent matchgroup=nasmStructure keepend start="^\s*STRUCT\>"hs=e-5 end="^\s*ENDSTRUCT\>"re=e-9 contains=@nasmGrpCntnStruc +syn region nasmStructureDef transparent matchgroup=nasmStructure keepend start="^\s*STRUC\>"hs=e-4 end="^\s*ENDSTRUC\>"re=e-8 contains=@nasmGrpCntnStruc +syn region nasmStructureDef transparent matchgroup=nasmStructure keepend start="\" end="\" contains=@nasmGrpCntnStruc,nasmInStructure +" union types are not part of nasm (yet) +"syn region nasmStructureDef transparent matchgroup=nasmStructure keepend start="^\s*UNION\>"hs=e-4 end="^\s*ENDUNION\>"re=e-8 contains=@nasmGrpCntnStruc +"syn region nasmStructureDef transparent matchgroup=nasmStructure keepend start="\" end="\" contains=@nasmGrpCntnStruc,nasmInStructure +syn match nasmInStructure contained "^\s*AT\>"hs=e-1 +syn cluster nasmGrpInStrucs contains=nasmStructure,nasmInStructure,nasmStructureLabel + + + +" PreProcessor Instructions: +" NAsm PreProcs start with %, but % is not a character +syn match nasmPreProcError "%{\=\(%\=\k\+\|%%\+\k*\|[+-]\=\d\+\)}\=" +if exists("nasm_loose_syntax") + syn cluster nasmGrpNxtCtx contains=nasmStructureLabel,nasmLabel,nasmLocalLabel,nasmSpecialLabel,nasmLabelError,nasmPreProcError +else + syn cluster nasmGrpNxtCtx contains=nasmStructureLabel,nasmLabel,nasmLabelError,nasmPreProcError +endif + +" Multi-line macro +syn cluster nasmGrpCntnMacro contains=ALLBUT,@nasmGrpInComments,nasmStructureDef,@nasmGrpInStrucs,nasmMacroDef,@nasmGrpPreCondits,nasmMemReference,nasmInMacPreCondit,nasmInMacStrucDef +syn region nasmMacroDef matchgroup=nasmMacro keepend start="^\s*%macro\>"hs=e-5 start="^\s*%imacro\>"hs=e-6 end="^\s*%endmacro\>"re=e-9 contains=@nasmGrpCntnMacro,nasmInMacStrucDef +if exists("nasm_loose_syntax") + syn match nasmInMacLabel contained "%\(%\k\+\>\|{%\k\+}\)" + syn match nasmInMacLabel contained "%\($\+\(\w\|[#\.?@~]\)\k*\>\|{$\+\(\w\|[#\.?@~]\)\k*}\)" + syn match nasmInMacPreProc contained "^\s*%\(push\|repl\)\>"hs=e-4 skipwhite nextgroup=nasmStructureLabel,nasmLabel,nasmInMacParam,nasmLocalLabel,nasmSpecialLabel,nasmLabelError,nasmPreProcError + if !exists("nasm_no_warn") + syn match nasmInMacLblWarn contained "%\(%[$\.]\k*\>\|{%[$\.]\k*}\)" + syn match nasmInMacLblWarn contained "%\($\+\(\d\|[#\.@~]\)\k*\|{\$\+\(\d\|[#\.@~]\)\k*}\)" + hi link nasmInMacCatLabel nasmInMacLblWarn + else + hi link nasmInMacCatLabel nasmInMacLabel + endif +else + syn match nasmInMacLabel contained "%\(%\(\w\|[#?@~]\)\k*\>\|{%\(\w\|[#?@~]\)\k*}\)" + syn match nasmInMacLabel contained "%\($\+\(\h\|[?@]\)\k*\>\|{$\+\(\h\|[?@]\)\k*}\)" + hi link nasmInMacCatLabel nasmLabelError +endif +syn match nasmInMacCatLabel contained "\d\K\k*"lc=1 +syn match nasmInMacLabel contained "\d}\k\+"lc=2 +if !exists("nasm_no_warn") + syn match nasmInMacLblWarn contained "%\(\($\+\|%\)[_~][._~]*\>\|{\($\+\|%\)[_~][._~]*}\)" +endif +syn match nasmInMacPreProc contained "^\s*%pop\>"hs=e-3 +syn match nasmInMacPreProc contained "^\s*%\(push\|repl\)\>"hs=e-4 skipwhite nextgroup=@nasmGrpNxtCtx +" structures cannot be nested (yet) -> use: 'keepend' and 're=' +syn region nasmInMacStrucDef contained transparent matchgroup=nasmStructure keepend start="^\s*STRUCT\>"hs=e-5 end="^\s*ENDSTRUCT\>"re=e-9 contains=@nasmGrpCntnMacro +syn region nasmInMacStrucDef contained transparent matchgroup=nasmStructure keepend start="^\s*STRUC\>"hs=e-4 end="^\s*ENDSTRUC\>"re=e-8 contains=@nasmGrpCntnMacro +syn region nasmInMacStrucDef contained transparent matchgroup=nasmStructure keepend start="\" end="\" contains=@nasmGrpCntnMacro,nasmInStructure +" union types are not part of nasm (yet) +"syn region nasmInMacStrucDef contained transparent matchgroup=nasmStructure keepend start="^\s*UNION\>"hs=e-4 end="^\s*ENDUNION\>"re=e-8 contains=@nasmGrpCntnMacro +"syn region nasmInMacStrucDef contained transparent matchgroup=nasmStructure keepend start="\" end="\" contains=@nasmGrpCntnMacro,nasmInStructure +syn region nasmInMacPreConDef contained transparent matchgroup=nasmInMacPreCondit start="^\s*%ifnidni\>"hs=e-7 start="^\s*%if\(idni\|n\(ctx\|def\|idn\|num\|str\)\)\>"hs=e-6 start="^\s*%if\(ctx\|def\|idn\|nid\|num\|str\)\>"hs=e-5 start="^\s*%ifid\>"hs=e-4 start="^\s*%if\>"hs=e-2 end="%endif\>" contains=@nasmGrpCntnMacro,nasmInMacPreCondit,nasmInPreCondit +" Todo: allow STRUC/ISTRUC to be used inside preprocessor conditional block +syn match nasmInMacPreCondit contained transparent "ctx\s"lc=3 skipwhite nextgroup=@nasmGrpNxtCtx +syn match nasmInMacPreCondit contained "^\s*%elifctx\>"hs=e-7 skipwhite nextgroup=@nasmGrpNxtCtx +syn match nasmInMacPreCondit contained "^\s*%elifnctx\>"hs=e-8 skipwhite nextgroup=@nasmGrpNxtCtx +syn match nasmInMacParamNum contained "\<\d\+\.list\>"me=e-5 +syn match nasmInMacParamNum contained "\<\d\+\.nolist\>"me=e-7 +syn match nasmInMacDirective contained "\.\(no\)\=list\>" +syn match nasmInMacMacro contained transparent "macro\s"lc=5 skipwhite nextgroup=nasmStructureLabel +syn match nasmInMacMacro contained "^\s*%rotate\>"hs=e-6 +syn match nasmInMacParam contained "%\([+-]\=\d\+\|{[+-]\=\d\+}\)" +" nasm conditional macro operands/arguments +" Todo: check feasebility; add too nasmGrpInMacros, etc. +"syn match nasmInMacCond contained "\<\(N\=\([ABGL]E\=\|[CEOSZ]\)\|P[EO]\=\)\>" +syn cluster nasmGrpInMacros contains=nasmMacro,nasmInMacMacro,nasmInMacParam,nasmInMacParamNum,nasmInMacDirective,nasmInMacLabel,nasmInMacLblWarn,nasmInMacMemRef,nasmInMacPreConDef,nasmInMacPreCondit,nasmInMacPreProc,nasmInMacStrucDef + +" Context pre-procs that are better used inside a macro +if exists("nasm_ctx_outside_macro") + syn region nasmPreConditDef transparent matchgroup=nasmCtxPreCondit start="^\s*%ifnctx\>"hs=e-6 start="^\s*%ifctx\>"hs=e-5 end="%endif\>" contains=@nasmGrpCntnPreCon + syn match nasmCtxPreProc "^\s*%pop\>"hs=e-3 + if exists("nasm_loose_syntax") + syn match nasmCtxLocLabel "%$\+\(\w\|[#.?@~]\)\k*\>" + else + syn match nasmCtxLocLabel "%$\+\(\h\|[?@]\)\k*\>" + endif + syn match nasmCtxPreProc "^\s*%\(push\|repl\)\>"hs=e-4 skipwhite nextgroup=@nasmGrpNxtCtx + syn match nasmCtxPreCondit contained transparent "ctx\s"lc=3 skipwhite nextgroup=@nasmGrpNxtCtx + syn match nasmCtxPreCondit contained "^\s*%elifctx\>"hs=e-7 skipwhite nextgroup=@nasmGrpNxtCtx + syn match nasmCtxPreCondit contained "^\s*%elifnctx\>"hs=e-8 skipwhite nextgroup=@nasmGrpNxtCtx + if exists("nasm_no_warn") + hi link nasmCtxPreCondit nasmPreCondit + hi link nasmCtxPreProc nasmPreProc + hi link nasmCtxLocLabel nasmLocalLabel + else + hi link nasmCtxPreCondit nasmPreProcWarn + hi link nasmCtxPreProc nasmPreProcWarn + hi link nasmCtxLocLabel nasmLabelWarn + endif +endif + +" Conditional assembly +syn cluster nasmGrpCntnPreCon contains=ALLBUT,@nasmGrpInComments,@nasmGrpInMacros,@nasmGrpInStrucs +syn region nasmPreConditDef transparent matchgroup=nasmPreCondit start="^\s*%ifnidni\>"hs=e-7 start="^\s*%if\(idni\|n\(def\|idn\|num\|str\)\)\>"hs=e-6 start="^\s*%if\(def\|idn\|nid\|num\|str\)\>"hs=e-5 start="^\s*%ifid\>"hs=e-4 start="^\s*%if\>"hs=e-2 end="%endif\>" contains=@nasmGrpCntnPreCon +syn match nasmInPreCondit contained "^\s*%el\(if\|se\)\>"hs=e-4 +syn match nasmInPreCondit contained "^\s*%elifid\>"hs=e-6 +syn match nasmInPreCondit contained "^\s*%elif\(def\|idn\|nid\|num\|str\)\>"hs=e-7 +syn match nasmInPreCondit contained "^\s*%elif\(n\(def\|idn\|num\|str\)\|idni\)\>"hs=e-8 +syn match nasmInPreCondit contained "^\s*%elifnidni\>"hs=e-9 +syn cluster nasmGrpInPreCondits contains=nasmPreCondit,nasmInPreCondit,nasmCtxPreCondit +syn cluster nasmGrpPreCondits contains=nasmPreConditDef,@nasmGrpInPreCondits,nasmCtxPreProc,nasmCtxLocLabel + +" Other pre-processor statements +syn match nasmPreProc "^\s*%\(rep\|use\)\>"hs=e-3 +syn match nasmPreProc "^\s*%line\>"hs=e-4 +syn match nasmPreProc "^\s*%\(clear\|error\|fatal\)\>"hs=e-5 +syn match nasmPreProc "^\s*%\(endrep\|strlen\|substr\)\>"hs=e-6 +syn match nasmPreProc "^\s*%\(exitrep\|warning\)\>"hs=e-7 +syn match nasmDefine "^\s*%undef\>"hs=e-5 +syn match nasmDefine "^\s*%\(assign\|define\)\>"hs=e-6 +syn match nasmDefine "^\s*%i\(assign\|define\)\>"hs=e-7 +syn match nasmDefine "^\s*%unmacro\>"hs=e-7 +syn match nasmInclude "^\s*%include\>"hs=e-7 +" Todo: Treat the line tail after %fatal, %error, %warning as text + +" Multiple pre-processor instructions on single line detection (obsolete) +"syn match nasmPreProcError +^\s*\([^\t "%';][^"%';]*\|[^\t "';][^"%';]\+\)%\a\+\>+ +syn cluster nasmGrpPreProcs contains=nasmMacroDef,@nasmGrpInMacros,@nasmGrpPreCondits,nasmPreProc,nasmDefine,nasmInclude,nasmPreProcWarn,nasmPreProcError + + + +" Register Identifiers: +" Register operands: +syn match nasmGen08Register "\<[A-D][HL]\>" +syn match nasmGen16Register "\<\([A-D]X\|[DS]I\|[BS]P\)\>" +syn match nasmGen32Register "\" +syn match nasmGen64Register "\" +syn match nasmSegRegister "\<[C-GS]S\>" +syn match nasmSpcRegister "\" +syn match nasmFpuRegister "\" +syn match nasmMmxRegister "\" +syn match nasmSseRegister "\" +syn match nasmCtrlRegister "\" +syn match nasmDebugRegister "\" +syn match nasmTestRegister "\" +syn match nasmRegisterError "\<\(CR[15-9]\|DR[4-58-9]\|TR[0-28-9]\)\>" +syn match nasmRegisterError "\" +syn match nasmRegisterError "\\)" +syn match nasmRegisterError "\" +" Memory reference operand (address): +syn match nasmMemRefError "[[\]]" +syn cluster nasmGrpCntnMemRef contains=ALLBUT,@nasmGrpComments,@nasmGrpPreProcs,@nasmGrpInStrucs,nasmMemReference,nasmMemRefError +syn match nasmInMacMemRef contained "\[[^;[\]]\{-}\]" contains=@nasmGrpCntnMemRef,nasmPreProcError,nasmInMacLabel,nasmInMacLblWarn,nasmInMacParam +syn match nasmMemReference "\[[^;[\]]\{-}\]" contains=@nasmGrpCntnMemRef,nasmPreProcError,nasmCtxLocLabel + + + +" Netwide Assembler Directives: +" Compilation constants +syn keyword nasmConstant __BITS__ __DATE__ __FILE__ __FORMAT__ __LINE__ +syn keyword nasmConstant __NASM_MAJOR__ __NASM_MINOR__ __NASM_VERSION__ +syn keyword nasmConstant __TIME__ +" Instruction modifiers +syn match nasmInstructnError "\" +syn match nasmInstrModifier "\(^\|:\)\s*[C-GS]S\>"ms=e-1 +syn keyword nasmInstrModifier A16 A32 O16 O32 +syn match nasmInstrModifier "\"lc=5,ms=e-1 +" the 'to' keyword is not allowed for fpu-pop instructions (yet) +"syn match nasmInstrModifier "\"lc=6,ms=e-1 +" NAsm directives +syn keyword nasmRepeat TIMES +syn keyword nasmDirective ALIGN[B] INCBIN EQU NOSPLIT SPLIT +syn keyword nasmDirective ABSOLUTE BITS SECTION SEGMENT +syn keyword nasmDirective ENDSECTION ENDSEGMENT +syn keyword nasmDirective __SECT__ +" Macro created standard directives: (requires %include) +syn case match +syn keyword nasmStdDirective ENDPROC EPILOGUE LOCALS PROC PROLOGUE USES +syn keyword nasmStdDirective ENDIF ELSE ELIF ELSIF IF +"syn keyword nasmStdDirective BREAK CASE DEFAULT ENDSWITCH SWITCH +"syn keyword nasmStdDirective CASE OF ENDCASE +syn keyword nasmStdDirective DO ENDFOR ENDWHILE FOR REPEAT UNTIL WHILE EXIT +syn case ignore +" Format specific directives: (all formats) +" (excluded: extension directives to section, global, common and extern) +syn keyword nasmFmtDirective ORG +syn keyword nasmFmtDirective EXPORT IMPORT GROUP UPPERCASE SEG WRT +syn keyword nasmFmtDirective LIBRARY +syn case match +syn keyword nasmFmtDirective _GLOBAL_OFFSET_TABLE_ __GLOBAL_OFFSET_TABLE_ +syn keyword nasmFmtDirective ..start ..got ..gotoff ..gotpc ..plt ..sym +syn case ignore + + + +" Standard Instructions: +syn match nasmInstructnError "\<\(F\=CMOV\|SET\)N\=\a\{0,2}\>" +syn keyword nasmInstructnError CMPS MOVS LCS LODS STOS XLAT +syn match nasmStdInstruction "\" +syn match nasmInstructnError "\\s*[^:]"he=e-1 +syn match nasmStdInstruction "\<\(CMOV\|J\|SET\)\(N\=\([ABGL]E\=\|[CEOSZ]\)\|P[EO]\=\)\>" +syn match nasmStdInstruction "\" +syn keyword nasmStdInstruction AAA AAD AAM AAS ADC ADD AND +syn keyword nasmStdInstruction BOUND BSF BSR BSWAP BT[C] BTR BTS +syn keyword nasmStdInstruction CALL CBW CDQ CLC CLD CMC CMP CMPSB CMPSD CMPSW CMPSQ +syn keyword nasmStdInstruction CMPXCHG CMPXCHG8B CPUID CWD[E] CQO +syn keyword nasmStdInstruction DAA DAS DEC DIV ENTER +syn keyword nasmStdInstruction IDIV IMUL INC INT[O] IRET[D] IRETW IRETQ +syn keyword nasmStdInstruction JCXZ JECXZ JMP +syn keyword nasmStdInstruction LAHF LDS LEA LEAVE LES LFS LGS LODSB LODSD LODSQ +syn keyword nasmStdInstruction LODSW LOOP[E] LOOPNE LOOPNZ LOOPZ LSS +syn keyword nasmStdInstruction MOVSB MOVSD MOVSW MOVSX MOVSQ MOVZX MUL NEG NOP NOT +syn keyword nasmStdInstruction OR POPA[D] POPAW POPF[D] POPFW POPFQ +syn keyword nasmStdInstruction PUSH[AD] PUSHAW PUSHF[D] PUSHFW PUSHFQ +syn keyword nasmStdInstruction RCL RCR RETF RET[N] ROL ROR +syn keyword nasmStdInstruction SAHF SAL SAR SBB SCASB SCASD SCASW +syn keyword nasmStdInstruction SHL[D] SHR[D] STC STD STOSB STOSD STOSW STOSQ SUB +syn keyword nasmStdInstruction TEST XADD XCHG XLATB XOR +syn keyword nasmStdInstruction LFENCE MFENCE SFENCE + + +" System Instructions: (usually privileged) +" Verification of pointer parameters +syn keyword nasmSysInstruction ARPL LAR LSL VERR VERW +" Addressing descriptor tables +syn keyword nasmSysInstruction LLDT SLDT LGDT SGDT +" Multitasking +syn keyword nasmSysInstruction LTR STR +" Coprocessing and Multiprocessing (requires fpu and multiple cpu's resp.) +syn keyword nasmSysInstruction CLTS LOCK WAIT +" Input and Output +syn keyword nasmInstructnError INS OUTS +syn keyword nasmSysInstruction IN INSB INSW INSD OUT OUTSB OUTSB OUTSW OUTSD +" Interrupt control +syn keyword nasmSysInstruction CLI STI LIDT SIDT +" System control +syn match nasmSysInstruction "\"me=s+3 +syn keyword nasmSysInstruction HLT INVD LMSW +syn keyword nasmSseInstruction PREFETCHT0 PREFETCHT1 PREFETCHT2 PREFETCHNTA +syn keyword nasmSseInstruction RSM SFENCE SMSW SYSENTER SYSEXIT UD2 WBINVD +" TLB (Translation Lookahead Buffer) testing +syn match nasmSysInstruction "\"me=s+3 +syn keyword nasmSysInstruction INVLPG + +" Debugging Instructions: (privileged) +syn match nasmDbgInstruction "\"me=s+3 +syn keyword nasmDbgInstruction INT1 INT3 RDMSR RDTSC RDPMC WRMSR + + +" Floating Point Instructions: (requires FPU) +syn match nasmFpuInstruction "\" +syn keyword nasmFpuInstruction F2XM1 FABS FADD[P] FBLD FBSTP +syn keyword nasmFpuInstruction FCHS FCLEX FCOM[IP] FCOMP[P] FCOS +syn keyword nasmFpuInstruction FDECSTP FDISI FDIV[P] FDIVR[P] FENI FFREE +syn keyword nasmFpuInstruction FIADD FICOM[P] FIDIV[R] FILD +syn keyword nasmFpuInstruction FIMUL FINCSTP FINIT FIST[P] FISUB[R] +syn keyword nasmFpuInstruction FLD[1] FLDCW FLDENV FLDL2E FLDL2T FLDLG2 +syn keyword nasmFpuInstruction FLDLN2 FLDPI FLDZ FMUL[P] +syn keyword nasmFpuInstruction FNCLEX FNDISI FNENI FNINIT FNOP FNSAVE +syn keyword nasmFpuInstruction FNSTCW FNSTENV FNSTSW FNSTSW +syn keyword nasmFpuInstruction FPATAN FPREM[1] FPTAN FRNDINT FRSTOR +syn keyword nasmFpuInstruction FSAVE FSCALE FSETPM FSIN FSINCOS FSQRT +syn keyword nasmFpuInstruction FSTCW FSTENV FST[P] FSTSW FSUB[P] FSUBR[P] +syn keyword nasmFpuInstruction FTST FUCOM[IP] FUCOMP[P] +syn keyword nasmFpuInstruction FXAM FXCH FXTRACT FYL2X FYL2XP1 + + +" Multi Media Xtension Packed Instructions: (requires MMX unit) +" Standard MMX instructions: (requires MMX1 unit) +syn match nasmInstructnError "\" +syn match nasmInstructnError "\" +syn keyword nasmMmxInstruction EMMS MOVD MOVQ +syn keyword nasmMmxInstruction PACKSSDW PACKSSWB PACKUSWB PADDB PADDD PADDW +syn keyword nasmMmxInstruction PADDSB PADDSW PADDUSB PADDUSW PAND[N] +syn keyword nasmMmxInstruction PCMPEQB PCMPEQD PCMPEQW PCMPGTB PCMPGTD PCMPGTW +syn keyword nasmMmxInstruction PMACHRIW PMADDWD PMULHW PMULLW POR +syn keyword nasmMmxInstruction PSLLD PSLLQ PSLLW PSRAD PSRAW PSRLD PSRLQ PSRLW +syn keyword nasmMmxInstruction PSUBB PSUBD PSUBW PSUBSB PSUBSW PSUBUSB PSUBUSW +syn keyword nasmMmxInstruction PUNPCKHBW PUNPCKHDQ PUNPCKHWD +syn keyword nasmMmxInstruction PUNPCKLBW PUNPCKLDQ PUNPCKLWD PXOR +" Extended MMX instructions: (requires MMX2/SSE unit) +syn keyword nasmMmxInstruction MASKMOVQ MOVNTQ +syn keyword nasmMmxInstruction PAVGB PAVGW PEXTRW PINSRW PMAXSW PMAXUB +syn keyword nasmMmxInstruction PMINSW PMINUB PMOVMSKB PMULHUW PSADBW PSHUFW + + +" Streaming SIMD Extension Packed Instructions: (requires SSE unit) +syn match nasmInstructnError "\" +syn match nasmSseInstruction "\" +syn keyword nasmSseInstruction ADDPS ADDSS ANDNPS ANDPS +syn keyword nasmSseInstruction COMISS CVTPI2PS CVTPS2PI +syn keyword nasmSseInstruction CVTSI2SS CVTSS2SI CVTTPS2PI CVTTSS2SI +syn keyword nasmSseInstruction DIVPS DIVSS FXRSTOR FXSAVE LDMXCSR +syn keyword nasmSseInstruction MAXPS MAXSS MINPS MINSS MOVAPS MOVHLPS MOVHPS +syn keyword nasmSseInstruction MOVLHPS MOVLPS MOVMSKPS MOVNTPS MOVSS MOVUPS +syn keyword nasmSseInstruction MULPS MULSS +syn keyword nasmSseInstruction ORPS RCPPS RCPSS RSQRTPS RSQRTSS +syn keyword nasmSseInstruction SHUFPS SQRTPS SQRTSS STMXCSR SUBPS SUBSS +syn keyword nasmSseInstruction UCOMISS UNPCKHPS UNPCKLPS XORPS + + +" Three Dimensional Now Packed Instructions: (requires 3DNow! unit) +syn keyword nasmNowInstruction FEMMS PAVGUSB PF2ID PFACC PFADD PFCMPEQ PFCMPGE +syn keyword nasmNowInstruction PFCMPGT PFMAX PFMIN PFMUL PFRCP PFRCPIT1 +syn keyword nasmNowInstruction PFRCPIT2 PFRSQIT1 PFRSQRT PFSUB[R] PI2FD +syn keyword nasmNowInstruction PMULHRWA PREFETCH[W] + + +" Vendor Specific Instructions: +" Cyrix instructions (requires Cyrix processor) +syn keyword nasmCrxInstruction PADDSIW PAVEB PDISTIB PMAGW PMULHRW[C] PMULHRIW +syn keyword nasmCrxInstruction PMVGEZB PMVLZB PMVNZB PMVZB PSUBSIW +syn keyword nasmCrxInstruction RDSHR RSDC RSLDT SMINT SMINTOLD SVDC SVLDT SVTS +syn keyword nasmCrxInstruction WRSHR +" AMD instructions (requires AMD processor) +syn keyword nasmAmdInstruction SYSCALL SYSRET + + +" Undocumented Instructions: +syn match nasmUndInstruction "\"me=s+3 +syn keyword nasmUndInstruction CMPXCHG486 IBTS ICEBP INT01 INT03 LOADALL +syn keyword nasmUndInstruction LOADALL286 LOADALL386 SALC SMI UD1 UMOV XBTS + + + +" Synchronize Syntax: +syn sync clear +syn sync minlines=50 "for multiple region nesting +syn sync match nasmSync grouphere nasmMacroDef "^\s*%i\=macro\>"me=s-1 +syn sync match nasmSync grouphere NONE "^\s*%endmacro\>" + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" Sub Links: +hi def link nasmInMacDirective nasmDirective +hi def link nasmInMacLabel nasmLocalLabel +hi def link nasmInMacLblWarn nasmLabelWarn +hi def link nasmInMacMacro nasmMacro +hi def link nasmInMacParam nasmMacro +hi def link nasmInMacParamNum nasmDecNumber +hi def link nasmInMacPreCondit nasmPreCondit +hi def link nasmInMacPreProc nasmPreProc +hi def link nasmInPreCondit nasmPreCondit +hi def link nasmInStructure nasmStructure +hi def link nasmStructureLabel nasmStructure + +" Comment Group: +hi def link nasmComment Comment +hi def link nasmSpecialComment SpecialComment +hi def link nasmInCommentTodo Todo + +" Constant Group: +hi def link nasmString String +hi def link nasmCString String +hi def link nasmStringError Error +hi def link nasmCStringEscape SpecialChar +hi def link nasmCStringFormat SpecialChar +hi def link nasmBinNumber Number +hi def link nasmOctNumber Number +hi def link nasmDecNumber Number +hi def link nasmHexNumber Number +hi def link nasmFltNumber Float +hi def link nasmNumberError Error + +" Identifier Group: +hi def link nasmLabel Identifier +hi def link nasmLocalLabel Identifier +hi def link nasmSpecialLabel Special +hi def link nasmLabelError Error +hi def link nasmLabelWarn Todo + +" PreProc Group: +hi def link nasmPreProc PreProc +hi def link nasmDefine Define +hi def link nasmInclude Include +hi def link nasmMacro Macro +hi def link nasmPreCondit PreCondit +hi def link nasmPreProcError Error +hi def link nasmPreProcWarn Todo + +" Type Group: +hi def link nasmType Type +hi def link nasmStorage StorageClass +hi def link nasmStructure Structure +hi def link nasmTypeError Error + +" Directive Group: +hi def link nasmConstant Constant +hi def link nasmInstrModifier Operator +hi def link nasmRepeat Repeat +hi def link nasmDirective Keyword +hi def link nasmStdDirective Operator +hi def link nasmFmtDirective Keyword + +" Register Group: +hi def link nasmCtrlRegister Special +hi def link nasmDebugRegister Debug +hi def link nasmTestRegister Special +hi def link nasmRegisterError Error +hi def link nasmMemRefError Error + +" Instruction Group: +hi def link nasmStdInstruction Statement +hi def link nasmSysInstruction Statement +hi def link nasmDbgInstruction Debug +hi def link nasmFpuInstruction Statement +hi def link nasmMmxInstruction Statement +hi def link nasmSseInstruction Statement +hi def link nasmNowInstruction Statement +hi def link nasmAmdInstruction Special +hi def link nasmCrxInstruction Special +hi def link nasmUndInstruction Todo +hi def link nasmInstructnError Error + + +let b:current_syntax = "nasm" + +" vim:ts=8 sw=4 + +endif diff --git a/syntax/nastran.vim b/syntax/nastran.vim new file mode 100644 index 0000000..91ee2c3 --- /dev/null +++ b/syntax/nastran.vim @@ -0,0 +1,185 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: NASTRAN input/DMAP +" Maintainer: Tom Kowalski +" Last change: April 27, 2001 +" Thanks to the authors and maintainers of fortran.vim. +" Since DMAP shares some traits with fortran, this syntax file +" is based on the fortran.vim syntax file. +"---------------------------------------------------------------------- +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +" DMAP is not case dependent +syn case ignore +" +"--------------------DMAP SYNTAX--------------------------------------- +" +" -------Executive Modules and Statements +" +syn keyword nastranDmapexecmod call dbview delete end equiv equivx exit +syn keyword nastranDmapexecmod file message purge purgex return subdmap +syn keyword nastranDmapType type +syn keyword nastranDmapLabel go to goto +syn keyword nastranDmapRepeat if else elseif endif then +syn keyword nastranDmapRepeat do while +syn region nastranDmapString start=+"+ end=+"+ oneline +syn region nastranDmapString start=+'+ end=+'+ oneline +" If you don't like initial tabs in dmap (or at all) +"syn match nastranDmapIniTab "^\t.*$" +"syn match nastranDmapTab "\t" + +" Any integer +syn match nastranDmapNumber "-\=\<[0-9]\+\>" +" floating point number, with dot, optional exponent +syn match nastranDmapFloat "\<[0-9]\+\.[0-9]*\([edED][-+]\=[0-9]\+\)\=\>" +" floating point number, starting with a dot, optional exponent +syn match nastranDmapFloat "\.[0-9]\+\([edED][-+]\=[0-9]\+\)\=\>" +" floating point number, without dot, with exponent +syn match nastranDmapFloat "\<[0-9]\+[edED][-+]\=[0-9]\+\>" + +syn match nastranDmapLogical "\(true\|false\)" + +syn match nastranDmapPreCondit "^#define\>" +syn match nastranDmapPreCondit "^#include\>" +" +" -------Comments may be contained in another line. +" +syn match nastranDmapComment "^[\$].*$" +syn match nastranDmapComment "\$.*$" +syn match nastranDmapComment "^[\$].*$" contained +syn match nastranDmapComment "\$.*$" contained +" Treat all past 72nd column as a comment. Do not work with tabs! +" Breaks down when 72-73rd column is in another match (eg number or keyword) +syn match nastranDmapComment "^.\{-72}.*$"lc=72 contained + +" +" -------Utility Modules +" +syn keyword nastranDmapUtilmod append copy dbc dbdict dbdir dmin drms1 +syn keyword nastranDmapUtilmod dtiin eltprt ifp ifp1 inputt2 inputt4 lamx +syn keyword nastranDmapUtilmod matgen matgpr matmod matpch matprn matprt +syn keyword nastranDmapUtilmod modtrl mtrxin ofp output2 output4 param +syn keyword nastranDmapUtilmod paraml paramr prtparam pvt scalar +syn keyword nastranDmapUtilmod seqp setval tabedit tabprt tabpt vec vecplot +syn keyword nastranDmapUtilmod xsort +" +" -------Matrix Modules +" +syn keyword nastranDmapMatmod add add5 cead dcmp decomp diagonal fbs merge +syn keyword nastranDmapMatmod mpyad norm read reigl smpyad solve solvit +syn keyword nastranDmapMatmod trnsp umerge umerge1 upartn dmiin partn +syn region nastranDmapMatmod start=+^ *[Dd][Mm][Ii]+ end=+[\/]+ +" +" -------Implicit Functions +" +syn keyword nastranDmapImplicit abs acos acosh andl asin asinh atan atan2 +syn keyword nastranDmapImplicit atanh atanh2 char clen clock cmplx concat1 +syn keyword nastranDmapImplicit concat2 concat3 conjg cos cosh dble diagoff +syn keyword nastranDmapImplicit diagon dim dlablank dlxblank dprod eqvl exp +syn keyword nastranDmapImplicit getdiag getsys ichar imag impl index indexstr +syn keyword nastranDmapImplicit int itol leq lge lgt lle llt lne log log10 +syn keyword nastranDmapImplicit logx ltoi mcgetsys mcputsys max min mod neqvl +syn keyword nastranDmapImplicit nint noop normal notl numeq numge numgt numle +syn keyword nastranDmapImplicit numlt numne orl pi precison putdiag putsys +syn keyword nastranDmapImplicit rand rdiagon real rtimtogo setcore sign sin +syn keyword nastranDmapImplicit sinh sngl sprod sqrt substrin tan tanh +syn keyword nastranDmapImplicit timetogo wlen xorl +" +" +"--------------------INPUT FILE SYNTAX--------------------------------------- +" +" +" -------Nastran Statement +" +syn keyword nastranNastranCard nastran +" +" -------The File Management Section (FMS) +" +syn region nastranFMSCard start=+^ *[Aa][Cc][Qq][Uu][Ii]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Aa][Ss][Ss][Ii][Gg]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Cc][oO][Nn][Nn][Ee]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Cc][Ll][Ee]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Dd][Ii][Cc]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Dd][Ii][Rr]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Ff][Ii][Xx]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Ll][Oo][Aa]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Ll][Oo][Cc]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Ss][Ee][Tt]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Uu][Nn][Ll]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Bb][Uu][Pp][Dd]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Dd][Ee][Ff][Ii][Nn]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Ee][Nn][Dd][Jj][Oo]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Ee][Xx][Pp][Aa][Nn]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Ii][Nn][Cc][Ll][Uu]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Ii][Nn][Ii][Tt]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Pp][Rr][Oo][Jj]+ end=+$+ oneline +syn region nastranFMSCard start=+^ *[Rr][Ee][Ss][Tt]+ end=+$+ oneline +syn match nastranDmapUtilmod "^ *[Rr][Ee][Ss][Tt][Aa].*,.*," contains=nastranDmapComment +" +" -------Executive Control Section +" +syn region nastranECSCard start=+^ *[Aa][Ll][Tt][Ee][Rr]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Aa][Pp][Pp]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Cc][Oo][Mm][Pp][Ii]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Dd][Ii][Aa][Gg] + end=+$+ oneline +syn region nastranECSCard start=+^ *[Ee][Cc][Hh][Oo]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Ee][Nn][Dd][Aa][Ll]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Ii][Dd]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Ii][Nn][Cc][Ll][Uu]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Ll][Ii][Nn][Kk]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Mm][Aa][Ll][Tt][Ee]+ end=+$+ oneline +syn region nastranECSCard start=+^ *[Ss][Oo][Ll] + end=+$+ oneline +syn region nastranECSCard start=+^ *[Tt][Ii][Mm][Ee]+ end=+$+ oneline +" +" -------Delimiters +" +syn match nastranDelimiter "[Cc][Ee][Nn][Dd]" contained +syn match nastranDelimiter "[Bb][Ee][Gg][Ii][Nn]" contained +syn match nastranDelimiter " *[Bb][Uu][Ll][Kk]" contained +syn match nastranDelimiter "[Ee][Nn][Dd] *[dD][Aa][Tt][Aa]" contained +" +" -------Case Control section +" +syn region nastranCC start=+^ *[Cc][Ee][Nn][Dd]+ end=+^ *[Bb][Ee][Gg][Ii][Nn]+ contains=nastranDelimiter,nastranBulkData,nastranDmapComment + +" +" -------Bulk Data section +" +syn region nastranBulkData start=+ *[Bb][Uu][Ll][Kk] *$+ end=+^ [Ee][Nn][Dd] *[Dd]+ contains=nastranDelimiter,nastranDmapComment +" +" -------The following cards may appear in multiple sections of the file +" +syn keyword nastranUtilCard ECHOON ECHOOFF INCLUDE PARAM + + +" The default methods for highlighting. Can be overridden later +hi def link nastranDmapexecmod Statement +hi def link nastranDmapType Type +hi def link nastranDmapPreCondit Error +hi def link nastranDmapUtilmod PreProc +hi def link nastranDmapMatmod nastranDmapUtilmod +hi def link nastranDmapString String +hi def link nastranDmapNumber Constant +hi def link nastranDmapFloat nastranDmapNumber +hi def link nastranDmapInitTab nastranDmapNumber +hi def link nastranDmapTab nastranDmapNumber +hi def link nastranDmapLogical nastranDmapExecmod +hi def link nastranDmapImplicit Identifier +hi def link nastranDmapComment Comment +hi def link nastranDmapRepeat nastranDmapexecmod +hi def link nastranNastranCard nastranDmapPreCondit +hi def link nastranECSCard nastranDmapUtilmod +hi def link nastranFMSCard nastranNastranCard +hi def link nastranCC nastranDmapexecmod +hi def link nastranDelimiter Special +hi def link nastranBulkData nastranDmapType +hi def link nastranUtilCard nastranDmapexecmod + +let b:current_syntax = "nastran" + +"EOF vim: ts=8 noet tw=120 sw=8 sts=0 + +endif diff --git a/syntax/natural.vim b/syntax/natural.vim new file mode 100644 index 0000000..ca2bba6 --- /dev/null +++ b/syntax/natural.vim @@ -0,0 +1,205 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" +" Language: NATURAL +" Version: 2.1.0.5 +" Maintainer: Marko von Oppen +" Last Changed: 2012-02-05 18:50:43 +" Support: http://www.von-oppen.com/ + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +setlocal iskeyword+=-,*,#,+,_,/ + +let s:cpo_save = &cpo +set cpo&vim + +" NATURAL is case insensitive +syntax case ignore + +" preprocessor +syn keyword naturalInclude include nextgroup=naturalObjName skipwhite + +" define data +syn keyword naturalKeyword define data end-define +syn keyword naturalKeyword independent global parameter local redefine view +syn keyword naturalKeyword const[ant] init initial + +" loops +syn keyword naturalLoop read end-read end-work find end-find histogram end-histogram +syn keyword naturalLoop end-all sort end-sort sorted descending ascending +syn keyword naturalRepeat repeat end-repeat while until for step end-for +syn keyword naturalKeyword in file with field starting from ending at thru by isn where +syn keyword naturalError on error end-error +syn keyword naturalKeyword accept reject end-enddata number unique retain as release +syn keyword naturalKeyword start end-start break end-break physical page top sequence +syn keyword naturalKeyword end-toppage end-endpage end-endfile before processing +syn keyword naturalKeyword end-before + +" conditionals +syn keyword naturalConditional if then else end-if end-norec +syn keyword naturalConditional decide end-decide value when condition none any + +" assignment / calculation +syn keyword naturalKeyword reset assign move left right justified compress to into edited +syn keyword naturalKeyword add subtract multiply divide compute name +syn keyword naturalKeyword all giving remainder rounded leaving space numeric +syn keyword naturalKeyword examine full replace giving separate delimiter modified +syn keyword naturalKeyword suspend identical suppress + +" program flow +syn keyword naturalFlow callnat fetch return enter escape bottom top stack formatted +syn keyword naturalFlow command call +syn keyword naturalflow end-subroutine routine + +" file operations +syn keyword naturalKeyword update store get delete end transaction work once close + +" other keywords +syn keyword naturalKeyword first every of no record[s] found ignore immediate +syn keyword naturalKeyword set settime key control stop terminate + +" in-/output +syn keyword naturalKeyword write display input reinput notitle nohdr map newpage +syn keyword naturalKeyword alarm text help eject index window base size +syn keyword naturalKeyword format printer skip lines + +" functions +syn keyword naturalKeyword abs atn cos exp frac int log sgn sin sqrt tan val old +syn keyword naturalKeyword pos + +" report mode keywords +syn keyword naturalRMKeyword same loop obtain indexed do doend + +" Subroutine name +syn keyword naturalFlow perform subroutine nextgroup=naturalFunction skipwhite +syn match naturalFunction "\<[a-z][-_a-z0-9]*\>" + +syn keyword naturalFlow using nextgroup=naturalKeyword,naturalObjName skipwhite +syn match naturalObjName "\<[a-z][-_a-z0-9]\{,7}\>" + +" Labels +syn match naturalLabel "\<[+#a-z][-_#a-z0-9]*\." +syn match naturalRef "\<[+#a-z][-_#a-z0-9]*\>\.\<[+#a-z][*]\=[-_#a-z0-9]*\>" + +" mark keyword special handling +syn keyword naturalKeyword mark nextgroup=naturalMark skipwhite +syn match naturalMark "\<\*[a-z][-_#.a-z0-9]*\>" + +" System variables +syn match naturalSysVar "\<\*[a-z][-a-z0-9]*\>" + +"integer number, or floating point number without a dot. +syn match naturalNumber "\<-\=\d\+\>" +"floating point number, with dot +syn match naturalNumber "\<-\=\d\+\.\d\+\>" +"floating point number, starting with a dot +syn match naturalNumber "\.\d\+" + +" Formats in write statement +syn match naturalFormat "\<\d\+[TX]\>" + +" String and Character contstants +syn match naturalString "H'\x\+'" +syn region naturalString start=+"+ end=+"+ +syn region naturalString start=+'+ end=+'+ + +" Type definition +syn match naturalAttribute "\<[-a-z][a-z]=[-a-z0-9_\.,]\+\>" +syn match naturalType contained "\<[ABINP]\d\+\(,\d\+\)\=\>" +syn match naturalType contained "\<[CL]\>" + +" "TODO" / other comments +syn keyword naturalTodo contained todo test +syn match naturalCommentMark contained "[a-z][^ \t/:|]*\(\s[^ \t/:'"|]\+\)*:\s"he=e-1 + +" comments +syn region naturalComment start="/\*" end="$" contains=naturalTodo,naturalLineRef,naturalCommentMark +syn region naturalComment start="^\*[ *]" end="$" contains=naturalTodo,naturalLineRef,naturalCommentMark +syn region naturalComment start="^\d\{4} \*[\ \*]"lc=5 end="$" contains=naturalTodo,naturalLineRef,naturalCommentMark +syn match naturalComment "^\*$" +syn match naturalComment "^\d\{4} \*$"lc=5 +" /* is legal syntax in parentheses e.g. "#ident(label./*)" +syn region naturalPComment contained start="/\*\s*[^),]" end="$" contains=naturalTodo,naturalLineRef,naturalCommentMark + +" operators +syn keyword naturalOperator and or not eq ne gt lt ge le mask scan modified + +" constants +syn keyword naturalBoolean true false +syn match naturalLineNo "^\d\{4}" + +" identifiers +syn match naturalIdent "\<[+#a-z][-_#a-z0-9]*\>[^\.']"me=e-1 +syn match naturalIdent "\<[+#a-z][-_#a-z0-9]*$" +syn match naturalLegalIdent "[+#a-z][-_#a-z0-9]*/[-_#a-z0-9]*" + +" parentheses +syn region naturalPar matchgroup=naturalParGui start="(" end=")" contains=naturalLabel,naturalRef,naturalOperator,@naturalConstant,naturalType,naturalSysVar,naturalPar,naturalLineNo,naturalPComment +syn match naturalLineRef "(\d\{4})" + +" build syntax groups +syntax cluster naturalConstant contains=naturalString,naturalNumber,naturalAttribute,naturalBoolean + +" folding +if v:version >= 600 + set foldignore=* +endif + + +" The default methods for highlighting. Can be overridden later + +" Constants +hi def link naturalFormat Constant +hi def link naturalAttribute Constant +hi def link naturalNumber Number +hi def link naturalString String +hi def link naturalBoolean Boolean + +" All kinds of keywords +hi def link naturalConditional Conditional +hi def link naturalRepeat Repeat +hi def link naturalLoop Repeat +hi def link naturalFlow Keyword +hi def link naturalError Keyword +hi def link naturalKeyword Keyword +hi def link naturalOperator Operator +hi def link naturalParGui Operator + +" Labels +hi def link naturalLabel Label +hi def link naturalRefLabel Label + +" Comments +hi def link naturalPComment Comment +hi def link naturalComment Comment +hi def link naturalTodo Todo +hi def link naturalCommentMark PreProc + +hi def link naturalInclude Include +hi def link naturalSysVar Identifier +hi def link naturalLineNo LineNr +hi def link naturalLineRef Error +hi def link naturalSpecial Special +hi def link naturalComKey Todo + +" illegal things +hi def link naturalRMKeyword Error +hi def link naturalLegalIdent Error + +hi def link naturalType Type +hi def link naturalFunction Function +hi def link naturalObjName PreProc + + +let b:current_syntax = "natural" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim:set ts=8 sw=8 noet ft=vim list: + +endif diff --git a/syntax/ncf.vim b/syntax/ncf.vim new file mode 100644 index 0000000..56d6fd4 --- /dev/null +++ b/syntax/ncf.vim @@ -0,0 +1,251 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Novell "NCF" Batch File +" Maintainer: Jonathan J. Miner +" Last Change: Tue, 04 Sep 2001 16:20:33 CDT +" $Id: ncf.vim,v 1.1 2004/06/13 16:31:58 vimboss Exp $ + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +syn keyword ncfCommands mount load unload +syn keyword ncfBoolean on off +syn keyword ncfCommands set nextgroup=ncfSetCommands +syn keyword ncfTimeTypes Reference Primary Secondary Single +syn match ncfLoad "\(unl\|l\)oad .*"lc=4 contains=ALLBUT,Error +syn match ncfMount "mount .*"lc=5 contains=ALLBUT,Error + +syn match ncfComment "^\ *rem.*$" +syn match ncfComment "^\ *;.*$" +syn match ncfComment "^\ *#.*$" + +syn match ncfSearchPath "search \(add\|del\) " nextgroup=ncfPath +syn match ncfPath "\<[^: ]\+:\([A-Za-z0-9._]\|\\\)*\>" +syn match ncfServerName "^file server name .*$" +syn match ncfIPXNet "^ipx internal net" + +" String +syn region ncfString start=+"+ end=+"+ +syn match ncfContString "= \(\(\.\{0,1}\(OU=\|O=\)\{0,1}[A-Z_]\+\)\+;\{0,1}\)\+"lc=2 + +syn match ncfHexNumber "\<\d\(\d\+\|[A-F]\+\)*\>" +syn match ncfNumber "\<\d\+\.\{0,1}\d*\>" +syn match ncfIPAddr "\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}" +syn match ncfTime "\(+|=\)\{0,1}\d\{1,2}:\d\{1,2}:\d\{1,2}" +syn match ncfDSTTime "([^ ]\+ [^ ]\+ \(FIRST\|LAST\)\s*\d\{1,2}:\d\{1,2}:\d\{1,2} \(AM\|PM\))" +syn match ncfTimeZone "[A-Z]\{3}\d[A-Z]\{3}" + +syn match ncfLogins "^\([Dd]is\|[Ee]n\)able login[s]*" +syn match ncfScript "[^ ]*\.ncf" + +" SET Commands that take a Number following +syn match ncfSetCommandsNum "\(Alert Message Nodes\)\s*=" +syn match ncfSetCommandsNum "\(Auto Restart After Abend\)\s*=" +syn match ncfSetCommandsNum "\(Auto Restart After Abend Delay Time\)\s*=" +syn match ncfSetCommandsNum "\(Compression Daily Check Starting Hour\)\s*=" +syn match ncfSetCommandsNum "\(Compression Daily Check Stop Hour\)\s*=" +syn match ncfSetCommandsNum "\(Concurrent Remirror Requests\)\s*=" +syn match ncfSetCommandsNum "\(Convert Compressed to Uncompressed Option\)\s*=" +syn match ncfSetCommandsNum "\(Days Untouched Before Compression\)\s*=" +syn match ncfSetCommandsNum "\(Decompress Free Space Warning Interval\)\s*=" +syn match ncfSetCommandsNum "\(Decompress Percent Disk Space Free to Allow Commit\)\s*=" +syn match ncfSetCommandsNum "\(Deleted Files Compression Option\)\s*=" +syn match ncfSetCommandsNum "\(Directory Cache Allocation Wait Time\)\s*=" +syn match ncfSetCommandsNum "\(Enable IPX Checksums\)\s*=" +syn match ncfSetCommandsNum "\(Garbage Collection Interval\)\s*=" +syn match ncfSetCommandsNum "\(IPX NetBIOS Replication Option\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Concurrent Compressions\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Concurrent Directory Cache Writes\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Concurrent Disk Cache Writes\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Directory Cache Buffers\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Extended Attributes per File or Path\)\s*=" +syn match ncfSetCommandsNum "\(Maximum File Locks\)\s*=" +syn match ncfSetCommandsNum "\(Maximum File Locks Per Connection\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Interrupt Events\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Number of Directory Handles\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Number of Internal Directory Handles\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Outstanding NCP Searches\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Packet Receive Buffers\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Physical Receive Packet Size\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Record Locks\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Record Locks Per Connection\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Service Processes\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Subdirectory Tree Depth\)\s*=" +syn match ncfSetCommandsNum "\(Maximum Transactions\)\s*=" +syn match ncfSetCommandsNum "\(Minimum Compression Percentage Gain\)\s*=" +syn match ncfSetCommandsNum "\(Minimum Directory Cache Buffers\)\s*=" +syn match ncfSetCommandsNum "\(Minimum File Cache Buffers\)\s*=" +syn match ncfSetCommandsNum "\(Minimum File Cache Report Threshold\)\s*=" +syn match ncfSetCommandsNum "\(Minimum Free Memory for Garbage Collection\)\s*=" +syn match ncfSetCommandsNum "\(Minimum Packet Receive Buffers\)\s*=" +syn match ncfSetCommandsNum "\(Minimum Service Processes\)\s*=" +syn match ncfSetCommandsNum "\(NCP Packet Signature Option\)\s*=" +syn match ncfSetCommandsNum "\(NDS Backlink Interval\)\s*=" +syn match ncfSetCommandsNum "\(NDS Client NCP Retries\)\s*=" +syn match ncfSetCommandsNum "\(NDS External Reference Life Span\)\s*=" +syn match ncfSetCommandsNum "\(NDS Inactivity Synchronization Interval\)\s*=" +syn match ncfSetCommandsNum "\(NDS Janitor Interval\)\s*=" +syn match ncfSetCommandsNum "\(New Service Process Wait Time\)\s*=" +syn match ncfSetCommandsNum "\(Number of Frees for Garbage Collection\)\s*=" +syn match ncfSetCommandsNum "\(Number of Watchdog Packets\)\s*=" +syn match ncfSetCommandsNum "\(Pseudo Preemption Count\)\s*=" +syn match ncfSetCommandsNum "\(Read Ahead LRU Sitting Time Threshold\)\s*=" +syn match ncfSetCommandsNum "\(Remirror Block Size\)\s*=" +syn match ncfSetCommandsNum "\(Reserved Buffers Below 16 Meg\)\s*=" +syn match ncfSetCommandsNum "\(Server Log File Overflow Size\)\s*=" +syn match ncfSetCommandsNum "\(Server Log File State\)\s*=" +syn match ncfSetCommandsNum "\(SMP Polling Count\)\s*=" +syn match ncfSetCommandsNum "\(SMP Stack Size\)\s*=" +syn match ncfSetCommandsNum "\(TIMESYNC Polling Count\)\s*=" +syn match ncfSetCommandsNum "\(TIMESYNC Polling Interval\)\s*=" +syn match ncfSetCommandsNum "\(TIMESYNC Synchronization Radius\)\s*=" +syn match ncfSetCommandsNum "\(TIMESYNC Write Value\)\s*=" +syn match ncfSetCommandsNum "\(Volume Log File Overflow Size\)\s*=" +syn match ncfSetCommandsNum "\(Volume Log File State\)\s*=" +syn match ncfSetCommandsNum "\(Volume Low Warning Reset Threshold\)\s*=" +syn match ncfSetCommandsNum "\(Volume Low Warning Threshold\)\s*=" +syn match ncfSetCommandsNum "\(Volume TTS Log File Overflow Size\)\s*=" +syn match ncfSetCommandsNum "\(Volume TTS Log File State\)\s*=" +syn match ncfSetCommandsNum "\(Worker Thread Execute In a Row Count\)\s*=" + +" SET Commands that take a Boolean (ON/OFF) + +syn match ncfSetCommandsBool "\(Alloc Memory Check Flag\)\s*=" +syn match ncfSetCommandsBool "\(Allow Audit Passwords\)\s*=" +syn match ncfSetCommandsBool "\(Allow Change to Client Rights\)\s*=" +syn match ncfSetCommandsBool "\(Allow Deletion of Active Directories\)\s*=" +syn match ncfSetCommandsBool "\(Allow Invalid Pointers\)\s*=" +syn match ncfSetCommandsBool "\(Allow LIP\)\s*=" +syn match ncfSetCommandsBool "\(Allow Unencrypted Passwords\)\s*=" +syn match ncfSetCommandsBool "\(Allow Unowned Files To Be Extended\)\s*=" +syn match ncfSetCommandsBool "\(Auto Register Memory Above 16 Megabytes\)\s*=" +syn match ncfSetCommandsBool "\(Auto TTS Backout Flag\)\s*=" +syn match ncfSetCommandsBool "\(Automatically Repair Bad Volumes\)\s*=" +syn match ncfSetCommandsBool "\(Check Equivalent to Me\)\s*=" +syn match ncfSetCommandsBool "\(Command Line Prompt Default Choice\)\s*=" +syn match ncfSetCommandsBool "\(Console Display Watchdog Logouts\)\s*=" +syn match ncfSetCommandsBool "\(Daylight Savings Time Status\)\s*=" +syn match ncfSetCommandsBool "\(Developer Option\)\s*=" +syn match ncfSetCommandsBool "\(Display Incomplete IPX Packet Alerts\)\s*=" +syn match ncfSetCommandsBool "\(Display Lost Interrupt Alerts\)\s*=" +syn match ncfSetCommandsBool "\(Display NCP Bad Component Warnings\)\s*=" +syn match ncfSetCommandsBool "\(Display NCP Bad Length Warnings\)\s*=" +syn match ncfSetCommandsBool "\(Display Old API Names\)\s*=" +syn match ncfSetCommandsBool "\(Display Relinquish Control Alerts\)\s*=" +syn match ncfSetCommandsBool "\(Display Spurious Interrupt Alerts\)\s*=" +syn match ncfSetCommandsBool "\(Enable Deadlock Detection\)\s*=" +syn match ncfSetCommandsBool "\(Enable Disk Read After Write Verify\)\s*=" +syn match ncfSetCommandsBool "\(Enable File Compression\)\s*=" +syn match ncfSetCommandsBool "\(Enable IO Handicap Attribute\)\s*=" +syn match ncfSetCommandsBool "\(Enable SECURE.NCF\)\s*=" +syn match ncfSetCommandsBool "\(Fast Volume Mounts\)\s*=" +syn match ncfSetCommandsBool "\(Global Pseudo Preemption\)\s*=" +syn match ncfSetCommandsBool "\(Halt System on Invalid Parameters\)\s*=" +syn match ncfSetCommandsBool "\(Ignore Disk Geometry\)\s*=" +syn match ncfSetCommandsBool "\(Immediate Purge of Deleted Files\)\s*=" +syn match ncfSetCommandsBool "\(NCP File Commit\)\s*=" +syn match ncfSetCommandsBool "\(NDS Trace File Length to Zero\)\s*=" +syn match ncfSetCommandsBool "\(NDS Trace to File\)\s*=" +syn match ncfSetCommandsBool "\(NDS Trace to Screen\)\s*=" +syn match ncfSetCommandsBool "\(New Time With Daylight Savings Time Status\)\s*=" +syn match ncfSetCommandsBool "\(Read Ahead Enabled\)\s*=" +syn match ncfSetCommandsBool "\(Read Fault Emulation\)\s*=" +syn match ncfSetCommandsBool "\(Read Fault Notification\)\s*=" +syn match ncfSetCommandsBool "\(Reject NCP Packets with Bad Components\)\s*=" +syn match ncfSetCommandsBool "\(Reject NCP Packets with Bad Lengths\)\s*=" +syn match ncfSetCommandsBool "\(Replace Console Prompt with Server Name\)\s*=" +syn match ncfSetCommandsBool "\(Reply to Get Nearest Server\)\s*=" +syn match ncfSetCommandsBool "\(SMP Developer Option\)\s*=" +syn match ncfSetCommandsBool "\(SMP Flush Processor Cache\)\s*=" +syn match ncfSetCommandsBool "\(SMP Intrusive Abend Mode\)\s*=" +syn match ncfSetCommandsBool "\(SMP Memory Protection\)\s*=" +syn match ncfSetCommandsBool "\(Sound Bell for Alerts\)\s*=" +syn match ncfSetCommandsBool "\(TIMESYNC Configured Sources\)\s*=" +syn match ncfSetCommandsBool "\(TIMESYNC Directory Tree Mode\)\s*=" +syn match ncfSetCommandsBool "\(TIMESYNC Hardware Clock\)\s*=" +syn match ncfSetCommandsBool "\(TIMESYNC RESET\)\s*=" +syn match ncfSetCommandsBool "\(TIMESYNC Restart Flag\)\s*=" +syn match ncfSetCommandsBool "\(TIMESYNC Service Advertising\)\s*=" +syn match ncfSetCommandsBool "\(TIMESYNC Write Parameters\)\s*=" +syn match ncfSetCommandsBool "\(TTS Abort Dump Flag\)\s*=" +syn match ncfSetCommandsBool "\(Upgrade Low Priority Threads\)\s*=" +syn match ncfSetCommandsBool "\(Volume Low Warn All Users\)\s*=" +syn match ncfSetCommandsBool "\(Write Fault Emulation\)\s*=" +syn match ncfSetCommandsBool "\(Write Fault Notification\)\s*=" + +" Set Commands that take a "string" -- NOT QUOTED + +syn match ncfSetCommandsStr "\(Default Time Server Type\)\s*=" +syn match ncfSetCommandsStr "\(SMP NetWare Kernel Mode\)\s*=" +syn match ncfSetCommandsStr "\(Time Zone\)\s*=" +syn match ncfSetCommandsStr "\(TIMESYNC ADD Time Source\)\s*=" +syn match ncfSetCommandsStr "\(TIMESYNC REMOVE Time Source\)\s*=" +syn match ncfSetCommandsStr "\(TIMESYNC Time Source\)\s*=" +syn match ncfSetCommandsStr "\(TIMESYNC Type\)\s*=" + +" SET Commands that take a "Time" + +syn match ncfSetCommandsTime "\(Command Line Prompt Time Out\)\s*=" +syn match ncfSetCommandsTime "\(Delay Before First Watchdog Packet\)\s*=" +syn match ncfSetCommandsTime "\(Delay Between Watchdog Packets\)\s*=" +syn match ncfSetCommandsTime "\(Directory Cache Buffer NonReferenced Delay\)\s*=" +syn match ncfSetCommandsTime "\(Dirty Directory Cache Delay Time\)\s*=" +syn match ncfSetCommandsTime "\(Dirty Disk Cache Delay Time\)\s*=" +syn match ncfSetCommandsTime "\(File Delete Wait Time\)\s*=" +syn match ncfSetCommandsTime "\(Minimum File Delete Wait Time\)\s*=" +syn match ncfSetCommandsTime "\(Mirrored Devices Are Out of Sync Message Frequency\)\s*=" +syn match ncfSetCommandsTime "\(New Packet Receive Buffer Wait Time\)\s*=" +syn match ncfSetCommandsTime "\(TTS Backout File Truncation Wait Time\)\s*=" +syn match ncfSetCommandsTime "\(TTS UnWritten Cache Wait Time\)\s*=" +syn match ncfSetCommandsTime "\(Turbo FAT Re-Use Wait Time\)\s*=" +syn match ncfSetCommandsTime "\(Daylight Savings Time Offset\)\s*=" + +syn match ncfSetCommandsTimeDate "\(End of Daylight Savings Time\)\s*=" +syn match ncfSetCommandsTimeDate "\(Start of Daylight Savings Time\)\s*=" + +syn match ncfSetCommandsBindCon "\(Bindery Context\)\s*=" nextgroup=ncfContString + +syn cluster ncfSetCommands contains=ncfSetCommandsNum,ncfSetCommandsBool,ncfSetCommandsStr,ncfSetCommandsTime,ncfSetCommandsTimeDate,ncfSetCommandsBindCon + + +if exists("ncf_highlight_unknowns") + syn match Error "[^ \t]*" contains=ALL +endif + + +" The default methods for highlighting. Can be overridden later +hi def link ncfCommands Statement +hi def link ncfSetCommands ncfCommands +hi def link ncfLogins ncfCommands +hi def link ncfString String +hi def link ncfContString ncfString +hi def link ncfComment Comment +hi def link ncfImplicit Type +hi def link ncfBoolean Boolean +hi def link ncfScript Identifier +hi def link ncfNumber Number +hi def link ncfIPAddr ncfNumber +hi def link ncfHexNumber ncfNumber +hi def link ncfTime ncfNumber +hi def link ncfDSTTime ncfNumber +hi def link ncfPath Constant +hi def link ncfServerName Special +hi def link ncfIPXNet ncfServerName +hi def link ncfTimeTypes Constant +hi def link ncfSetCommandsNum ncfSetCommands +hi def link ncfSetCommandsBool ncfSetCommands +hi def link ncfSetCommandsStr ncfSetCommands +hi def link ncfSetCommandsTime ncfSetCommands +hi def link ncfSetCommandsTimeDate ncfSetCommands +hi def link ncfSetCommandsBindCon ncfSetCommands + + + +let b:current_syntax = "ncf" + +endif diff --git a/syntax/netrc.vim b/syntax/netrc.vim new file mode 100644 index 0000000..ebfe883 --- /dev/null +++ b/syntax/netrc.vim @@ -0,0 +1,56 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: netrc(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2010-01-03 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword netrcKeyword machine nextgroup=netrcMachine skipwhite skipnl +syn keyword netrcKeyword account + \ login + \ nextgroup=netrcLogin,netrcSpecial skipwhite skipnl +syn keyword netrcKeyword password nextgroup=netrcPassword skipwhite skipnl +syn keyword netrcKeyword default +syn keyword netrcKeyword macdef + \ nextgroup=netrcInit,netrcMacroName skipwhite skipnl +syn region netrcMacro contained start='.' end='^$' + +syn match netrcMachine contained display '\S\+' +syn match netrcMachine contained display '"[^\\"]*\(\\.[^\\"]*\)*"' +syn match netrcLogin contained display '\S\+' +syn match netrcLogin contained display '"[^\\"]*\(\\.[^\\"]*\)*"' +syn match netrcPassword contained display '\S\+' +syn match netrcPassword contained display '"[^\\"]*\(\\.[^\\"]*\)*"' +syn match netrcMacroName contained display '\S\+' + \ nextgroup=netrcMacro skipwhite skipnl +syn match netrcMacroName contained display '"[^\\"]*\(\\.[^\\"]*\)*"' + \ nextgroup=netrcMacro skipwhite skipnl + +syn keyword netrcSpecial contained anonymous +syn match netrcInit contained '\" contained skipwhite + +" ----------------------------- +" Special filetype highlighting {{{1 +" ----------------------------- +if exists("g:netrw_special_syntax") && netrw_special_syntax + syn match netrwBak "\(\S\+ \)*\S\+\.bak\>" contains=netrwTreeBar,@NoSpell + syn match netrwCompress "\(\S\+ \)*\S\+\.\%(gz\|bz2\|Z\|zip\)\>" contains=netrwTreeBar,@NoSpell + if has("unix") + syn match netrwCoreDump "\" contains=netrwTreeBar,@NoSpell + endif + syn match netrwLex "\(\S\+ \)*\S\+\.\%(l\|lex\)\>" contains=netrwTreeBar,@NoSpell + syn match netrwYacc "\(\S\+ \)*\S\+\.y\>" contains=netrwTreeBar,@NoSpell + syn match netrwData "\(\S\+ \)*\S\+\.dat\>" contains=netrwTreeBar,@NoSpell + syn match netrwDoc "\(\S\+ \)*\S\+\.\%(doc\|txt\|pdf\|ps\)" contains=netrwTreeBar,@NoSpell + syn match netrwHdr "\(\S\+ \)*\S\+\.\%(h\|hpp\)\>" contains=netrwTreeBar,@NoSpell + syn match netrwLib "\(\S\+ \)*\S*\.\%(a\|so\|lib\|dll\)\>" contains=netrwTreeBar,@NoSpell + syn match netrwMakeFile "\<[mM]akefile\>\|\(\S\+ \)*\S\+\.mak\>" contains=netrwTreeBar,@NoSpell + syn match netrwObj "\(\S\+ \)*\S*\.\%(o\|obj\)\>" contains=netrwTreeBar,@NoSpell + syn match netrwTags "\<\(ANmenu\|ANtags\)\>" contains=netrwTreeBar,@NoSpell + syn match netrwTags "\" contains=netrwTreeBar,@NoSpell + syn match netrwTilde "\(\S\+ \)*\S\+\~\*\=\>" contains=netrwTreeBar,@NoSpell + syn match netrwTmp "\\|\(\S\+ \)*\S*tmp\>" contains=netrwTreeBar,@NoSpell +endif + +" --------------------------------------------------------------------- +" Highlighting Links: {{{1 +if !exists("did_drchip_netrwlist_syntax") + let did_drchip_netrwlist_syntax= 1 + hi default link netrwClassify Function + hi default link netrwCmdSep Delimiter + hi default link netrwComment Comment + hi default link netrwDir Directory + hi default link netrwHelpCmd Function + hi default link netrwQHTopic Number + hi default link netrwHidePat Statement + hi default link netrwHideSep netrwComment + hi default link netrwList Statement + hi default link netrwVersion Identifier + hi default link netrwSymLink Question + hi default link netrwExe PreProc + hi default link netrwDateSep Delimiter + + hi default link netrwTreeBar Special + hi default link netrwTimeSep netrwDateSep + hi default link netrwComma netrwComment + hi default link netrwHide netrwComment + hi default link netrwMarkFile TabLineSel + hi default link netrwLink Special + + " special syntax highlighting (see :he g:netrw_special_syntax) + hi default link netrwBak NonText + hi default link netrwCompress Folded + hi default link netrwCoreDump WarningMsg + hi default link netrwData DiffChange + hi default link netrwHdr netrwPlain + hi default link netrwLex netrwPlain + hi default link netrwLib DiffChange + hi default link netrwMakefile DiffChange + hi default link netrwObj Folded + hi default link netrwTilde Folded + hi default link netrwTmp Folded + hi default link netrwTags Folded + hi default link netrwYacc netrwPlain +endif + +" Current Syntax: {{{1 +let b:current_syntax = "netrwlist" +" --------------------------------------------------------------------- +" vim: ts=8 fdm=marker + +endif diff --git a/syntax/ninja.vim b/syntax/ninja.vim new file mode 100644 index 0000000..e551840 --- /dev/null +++ b/syntax/ninja.vim @@ -0,0 +1,87 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" ninja build file syntax. +" Language: ninja build file as described at +" http://martine.github.com/ninja/manual.html +" Version: 1.4 +" Last Change: 2014/05/13 +" Maintainer: Nicolas Weber +" Version 1.4 of this script is in the upstream vim repository and will be +" included in the next vim release. If you change this, please send your change +" upstream. + +" ninja lexer and parser are at +" https://github.com/martine/ninja/blob/master/src/lexer.in.cc +" https://github.com/martine/ninja/blob/master/src/manifest_parser.cc + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case match + +syn match ninjaComment /#.*/ contains=@Spell + +" Toplevel statements are the ones listed here and +" toplevel variable assignments (ident '=' value). +" lexer.in.cc, ReadToken() and manifest_parser.cc, Parse() +syn match ninjaKeyword "^build\>" +syn match ninjaKeyword "^rule\>" +syn match ninjaKeyword "^pool\>" +syn match ninjaKeyword "^default\>" +syn match ninjaKeyword "^include\>" +syn match ninjaKeyword "^subninja\>" + +" Both 'build' and 'rule' begin a variable scope that ends +" on the first line without indent. 'rule' allows only a +" limited set of magic variables, 'build' allows general +" let assignments. +" manifest_parser.cc, ParseRule() +syn region ninjaRule start="^rule" end="^\ze\S" contains=ALL transparent +syn keyword ninjaRuleCommand contained command deps depfile description generator + \ pool restat rspfile rspfile_content + +syn region ninjaPool start="^pool" end="^\ze\S" contains=ALL transparent +syn keyword ninjaPoolCommand contained depth + +" Strings are parsed as follows: +" lexer.in.cc, ReadEvalString() +" simple_varname = [a-zA-Z0-9_-]+; +" varname = [a-zA-Z0-9_.-]+; +" $$ -> $ +" $\n -> line continuation +" '$ ' -> escaped space +" $simple_varname -> variable +" ${varname} -> variable + +syn match ninjaDollar "\$\$" +syn match ninjaWrapLineOperator "\$$" +syn match ninjaSimpleVar "\$[a-zA-Z0-9_-]\+" +syn match ninjaVar "\${[a-zA-Z0-9_.-]\+}" + +" operators are: +" variable assignment = +" rule definition : +" implicit dependency | +" order-only dependency || +syn match ninjaOperator "\(=\|:\||\|||\)\ze\s" + +hi def link ninjaComment Comment +hi def link ninjaKeyword Keyword +hi def link ninjaRuleCommand Statement +hi def link ninjaPoolCommand Statement +hi def link ninjaDollar ninjaOperator +hi def link ninjaWrapLineOperator ninjaOperator +hi def link ninjaOperator Operator +hi def link ninjaSimpleVar ninjaVar +hi def link ninjaVar Identifier + +let b:current_syntax = "ninja" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/nosyntax.vim b/syntax/nosyntax.vim new file mode 100644 index 0000000..74ef70a --- /dev/null +++ b/syntax/nosyntax.vim @@ -0,0 +1,34 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax support file +" Maintainer: Bram Moolenaar +" Last Change: 2006 Apr 16 + +" This file is used for ":syntax off". +" It removes the autocommands and stops highlighting for all buffers. + +if !has("syntax") + finish +endif + +" Remove all autocommands for the Syntax event. This also avoids that +" "syntax=foo" in a modeline triggers the SynSet() function of synload.vim. +au! Syntax + +" remove all syntax autocommands and remove the syntax for each buffer +augroup syntaxset + au! + au BufEnter * syn clear + au BufEnter * if exists("b:current_syntax") | unlet b:current_syntax | endif + doautoall syntaxset BufEnter * + au! +augroup END + +if exists("syntax_on") + unlet syntax_on +endif +if exists("syntax_manual") + unlet syntax_manual +endif + +endif diff --git a/syntax/nqc.vim b/syntax/nqc.vim new file mode 100644 index 0000000..785d909 --- /dev/null +++ b/syntax/nqc.vim @@ -0,0 +1,369 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: NQC - Not Quite C, for LEGO mindstorms +" NQC homepage: http://www.enteract.com/~dbaum/nqc/ +" Maintainer: Stefan Scherer +" Last Change: 2001 May 10 +" URL: http://www.enotes.de/twiki/pub/Home/LegoMindstorms/nqc.vim +" Filenames: .nqc + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Statements +syn keyword nqcStatement break return continue start stop abs sign +syn keyword nqcStatement sub task +syn keyword nqcLabel case default +syn keyword nqcConditional if else switch +syn keyword nqcRepeat while for do until repeat + +" Scout and RCX2 +syn keyword nqcEvents acquire catch monitor + +" types and classes +syn keyword nqcType int true false void +syn keyword nqcStorageClass asm const inline + + + +" Sensors -------------------------------------------- +" Input Sensors +syn keyword nqcConstant SENSOR_1 SENSOR_2 SENSOR_3 + +" Types for SetSensorType() +syn keyword nqcConstant SENSOR_TYPE_TOUCH SENSOR_TYPE_TEMPERATURE +syn keyword nqcConstant SENSOR_TYPE_LIGHT SENSOR_TYPE_ROTATION +syn keyword nqcConstant SENSOR_LIGHT SENSOR_TOUCH + +" Modes for SetSensorMode() +syn keyword nqcConstant SENSOR_MODE_RAW SENSOR_MODE_BOOL +syn keyword nqcConstant SENSOR_MODE_EDGE SENSOR_MODE_PULSE +syn keyword nqcConstant SENSOR_MODE_PERCENT SENSOR_MODE_CELSIUS +syn keyword nqcConstant SENSOR_MODE_FAHRENHEIT SENSOR_MODE_ROTATION + +" Sensor configurations for SetSensor() +syn keyword nqcConstant SENSOR_TOUCH SENSOR_LIGHT SENSOR_ROTATION +syn keyword nqcConstant SENSOR_CELSIUS SENSOR_FAHRENHEIT SENSOR_PULSE +syn keyword nqcConstant SENSOR_EDGE + +" Functions - All +syn keyword nqcFunction ClearSensor +syn keyword nqcFunction SensorValue SensorType + +" Functions - RCX +syn keyword nqcFunction SetSensor SetSensorType +syn keyword nqcFunction SensorValueBool + +" Functions - RCX, CyberMaster +syn keyword nqcFunction SetSensorMode SensorMode + +" Functions - RCX, Scout +syn keyword nqcFunction SensorValueRaw + +" Functions - Scout +syn keyword nqcFunction SetSensorLowerLimit SetSensorUpperLimit +syn keyword nqcFunction SetSensorHysteresis CalibrateSensor + + +" Outputs -------------------------------------------- +" Outputs for On(), Off(), etc. +syn keyword nqcConstant OUT_A OUT_B OUT_C + +" Modes for SetOutput() +syn keyword nqcConstant OUT_ON OUT_OFF OUT_FLOAT + +" Directions for SetDirection() +syn keyword nqcConstant OUT_FWD OUT_REV OUT_TOGGLE + +" Output power for SetPower() +syn keyword nqcConstant OUT_LOW OUT_HALF OUT_FULL + +" Functions - All +syn keyword nqcFunction SetOutput SetDirection SetPower OutputStatus +syn keyword nqcFunction On Off Float Fwd Rev Toggle +syn keyword nqcFunction OnFwd OnRev OnFor + +" Functions - RXC2, Scout +syn keyword nqcFunction SetGlobalOutput SetGlobalDirection SetMaxPower +syn keyword nqcFunction GlobalOutputStatus + + +" Sound ---------------------------------------------- +" Sounds for PlaySound() +syn keyword nqcConstant SOUND_CLICK SOUND_DOUBLE_BEEP SOUND_DOWN +syn keyword nqcConstant SOUND_UP SOUND_LOW_BEEP SOUND_FAST_UP + +" Functions - All +syn keyword nqcFunction PlaySound PlayTone + +" Functions - RCX2, Scout +syn keyword nqcFunction MuteSound UnmuteSound ClearSound +syn keyword nqcFunction SelectSounds + + +" LCD ------------------------------------------------ +" Modes for SelectDisplay() +syn keyword nqcConstant DISPLAY_WATCH DISPLAY_SENSOR_1 DISPLAY_SENSOR_2 +syn keyword nqcConstant DISPLAY_SENSOR_3 DISPLAY_OUT_A DISPLAY_OUT_B +syn keyword nqcConstant DISPLAY_OUT_C +" RCX2 +syn keyword nqcConstant DISPLAY_USER + +" Functions - RCX +syn keyword nqcFunction SelectDisplay +" Functions - RCX2 +syn keyword nqcFunction SetUserDisplay + + +" Communication -------------------------------------- +" Messages - RCX, Scout ------------------------------ +" Tx power level for SetTxPower() +syn keyword nqcConstant TX_POWER_LO TX_POWER_HI + +" Functions - RCX, Scout +syn keyword nqcFunction Message ClearMessage SendMessage SetTxPower + +" Serial - RCX2 -------------------------------------- +" for SetSerialComm() +syn keyword nqcConstant SERIAL_COMM_DEFAULT SERIAL_COMM_4800 +syn keyword nqcConstant SERIAL_COMM_DUTY25 SERIAL_COMM_76KHZ + +" for SetSerialPacket() +syn keyword nqcConstant SERIAL_PACKET_DEFAULT SERIAL_PACKET_PREAMBLE +syn keyword nqcConstant SERIAL_PACKET_NEGATED SERIAL_PACKET_CHECKSUM +syn keyword nqcConstant SERIAL_PACKET_RCX + +" Functions - RCX2 +syn keyword nqcFunction SetSerialComm SetSerialPacket SetSerialData +syn keyword nqcFunction SerialData SendSerial + +" VLL - Scout ---------------------------------------- +" Functions - Scout +syn keyword nqcFunction SendVLL + + +" Timers --------------------------------------------- +" Functions - All +syn keyword nqcFunction ClearTimer Timer + +" Functions - RCX2 +syn keyword nqcFunction SetTimer FastTimer + + +" Counters ------------------------------------------- +" Functions - RCX2, Scout +syn keyword nqcFunction ClearCounter IncCounter DecCounter Counter + + +" Access Control ------------------------------------- +syn keyword nqcConstant ACQUIRE_OUT_A ACQUIRE_OUT_B ACQUIRE_OUT_C +syn keyword nqcConstant ACQUIRE_SOUND +" RCX2 only +syn keyword nqcConstant ACQUIRE_USER_1 ACQUIRE_USER_2 ACQUIRE_USER_3 +syn keyword nqcConstant ACQUIRE_USER_4 + +" Functions - RCX2, Scout +syn keyword nqcFunction SetPriority + + +" Events --------------------------------------------- +" RCX2 Events +syn keyword nqcConstant EVENT_TYPE_PRESSED EVENT_TYPE_RELEASED +syn keyword nqcConstant EVENT_TYPE_PULSE EVENT_TYPE_EDGE +syn keyword nqcConstant EVENT_TYPE_FAST_CHANGE EVENT_TYPE_LOW +syn keyword nqcConstant EVENT_TYPE_NORMAL EVENT_TYPE_HIGH +syn keyword nqcConstant EVENT_TYPE_CLICK EVENT_TYPE_DOUBLECLICK +syn keyword nqcConstant EVENT_TYPE_MESSAGE + +" Scout Events +syn keyword nqcConstant EVENT_1_PRESSED EVENT_1_RELEASED +syn keyword nqcConstant EVENT_2_PRESSED EVENT_2_RELEASED +syn keyword nqcConstant EVENT_LIGHT_HIGH EVENT_LIGHT_NORMAL +syn keyword nqcConstant EVENT_LIGHT_LOW EVENT_LIGHT_CLICK +syn keyword nqcConstant EVENT_LIGHT_DOUBLECLICK EVENT_COUNTER_0 +syn keyword nqcConstant EVENT_COUNTER_1 EVENT_TIMER_0 EVENT_TIMER_1 +syn keyword nqcConstant EVENT_TIMER_2 EVENT_MESSAGE + +" Functions - RCX2, Scout +syn keyword nqcFunction ActiveEvents Event + +" Functions - RCX2 +syn keyword nqcFunction CurrentEvents +syn keyword nqcFunction SetEvent ClearEvent ClearAllEvents EventState +syn keyword nqcFunction CalibrateEvent SetUpperLimit UpperLimit +syn keyword nqcFunction SetLowerLimit LowerLimit SetHysteresis +syn keyword nqcFunction Hysteresis +syn keyword nqcFunction SetClickTime ClickTime SetClickCounter +syn keyword nqcFunction ClickCounter + +" Functions - Scout +syn keyword nqcFunction SetSensorClickTime SetCounterLimit +syn keyword nqcFunction SetTimerLimit + + +" Data Logging --------------------------------------- +" Functions - RCX +syn keyword nqcFunction CreateDatalog AddToDatalog +syn keyword nqcFunction UploadDatalog + + +" General Features ----------------------------------- +" Functions - All +syn keyword nqcFunction Wait StopAllTasks Random +syn keyword nqcFunction SetSleepTime SleepNow + +" Functions - RCX +syn keyword nqcFunction Program Watch SetWatch + +" Functions - RCX2 +syn keyword nqcFunction SetRandomSeed SelectProgram +syn keyword nqcFunction BatteryLevel FirmwareVersion + +" Functions - Scout +" Parameters for SetLight() +syn keyword nqcConstant LIGHT_ON LIGHT_OFF +syn keyword nqcFunction SetScoutRules ScoutRules SetScoutMode +syn keyword nqcFunction SetEventFeedback EventFeedback SetLight + +" additional CyberMaster defines +syn keyword nqcConstant OUT_L OUT_R OUT_X +syn keyword nqcConstant SENSOR_L SENSOR_M SENSOR_R +" Functions - CyberMaster +syn keyword nqcFunction Drive OnWait OnWaitDifferent +syn keyword nqcFunction ClearTachoCounter TachoCount TachoSpeed +syn keyword nqcFunction ExternalMotorRunning AGC + + + +" nqcCommentGroup allows adding matches for special things in comments +syn keyword nqcTodo contained TODO FIXME XXX +syn cluster nqcCommentGroup contains=nqcTodo + +"when wanted, highlight trailing white space +if exists("nqc_space_errors") + if !exists("nqc_no_trail_space_error") + syn match nqcSpaceError display excludenl "\s\+$" + endif + if !exists("nqc_no_tab_space_error") + syn match nqcSpaceError display " \+\t"me=e-1 + endif +endif + +"catch errors caused by wrong parenthesis and brackets +syn cluster nqcParenGroup contains=nqcParenError,nqcIncluded,nqcCommentSkip,@nqcCommentGroup,nqcCommentStartError,nqcCommentSkip,nqcCppOut,nqcCppOut2,nqcCppSkip,nqcNumber,nqcFloat,nqcNumbers +if exists("nqc_no_bracket_error") + syn region nqcParen transparent start='(' end=')' contains=ALLBUT,@nqcParenGroup,nqcCppParen + " nqcCppParen: same as nqcParen but ends at end-of-line; used in nqcDefine + syn region nqcCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@nqcParenGroup,nqcParen + syn match nqcParenError display ")" + syn match nqcErrInParen display contained "[{}]" +else + syn region nqcParen transparent start='(' end=')' contains=ALLBUT,@nqcParenGroup,nqcCppParen,nqcErrInBracket,nqcCppBracket + " nqcCppParen: same as nqcParen but ends at end-of-line; used in nqcDefine + syn region nqcCppParen transparent start='(' skip='\\$' excludenl end=')' end='$' contained contains=ALLBUT,@nqcParenGroup,nqcErrInBracket,nqcParen,nqcBracket + syn match nqcParenError display "[\])]" + syn match nqcErrInParen display contained "[\]{}]" + syn region nqcBracket transparent start='\[' end=']' contains=ALLBUT,@nqcParenGroup,nqcErrInParen,nqcCppParen,nqcCppBracket + " nqcCppBracket: same as nqcParen but ends at end-of-line; used in nqcDefine + syn region nqcCppBracket transparent start='\[' skip='\\$' excludenl end=']' end='$' contained contains=ALLBUT,@nqcParenGroup,nqcErrInParen,nqcParen,nqcBracket + syn match nqcErrInBracket display contained "[);{}]" +endif + +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match nqcNumbers display transparent "\<\d\|\.\d" contains=nqcNumber,nqcFloat +" Same, but without octal error (for comments) +syn match nqcNumber display contained "\d\+\(u\=l\{0,2}\|ll\=u\)\>" +"hex number +syn match nqcNumber display contained "0x\x\+\(u\=l\{0,2}\|ll\=u\)\>" +" Flag the first zero of an octal number as something special +syn match nqcFloat display contained "\d\+f" +"floating point number, with dot, optional exponent +syn match nqcFloat display contained "\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=" +"floating point number, starting with a dot, optional exponent +syn match nqcFloat display contained "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match nqcFloat display contained "\d\+e[-+]\=\d\+[fl]\=\>" +" flag an octal number with wrong digits +syn case match + +syn region nqcCommentL start="//" skip="\\$" end="$" keepend contains=@nqcCommentGroup,nqcSpaceError +syn region nqcComment matchgroup=nqcCommentStart start="/\*" matchgroup=NONE end="\*/" contains=@nqcCommentGroup,nqcCommentStartError,nqcSpaceError + +" keep a // comment separately, it terminates a preproc. conditional +syntax match nqcCommentError display "\*/" +syntax match nqcCommentStartError display "/\*" contained + + + + + +syn region nqcPreCondit start="^\s*#\s*\(if\|ifdef\|ifndef\|elif\)\>" skip="\\$" end="$" end="//"me=s-1 contains=nqcComment,nqcCharacter,nqcCppParen,nqcParenError,nqcNumbers,nqcCommentError,nqcSpaceError +syn match nqcPreCondit display "^\s*#\s*\(else\|endif\)\>" +if !exists("nqc_no_if0") + syn region nqcCppOut start="^\s*#\s*if\s\+0\>" end=".\|$" contains=nqcCppOut2 + syn region nqcCppOut2 contained start="0" end="^\s*#\s*\(endif\>\|else\>\|elif\>\)" contains=nqcSpaceError,nqcCppSkip + syn region nqcCppSkip contained start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*#\s*endif\>" contains=nqcSpaceError,nqcCppSkip +endif +syn region nqcIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match nqcInclude display "^\s*#\s*include\>\s*["]" contains=nqcIncluded +"syn match nqcLineSkip "\\$" +syn cluster nqcPreProcGroup contains=nqcPreCondit,nqcIncluded,nqcInclude,nqcDefine,nqcErrInParen,nqcErrInBracket,nqcCppOut,nqcCppOut2,nqcCppSkip,nqcNumber,nqcFloat,nqcNumbers,nqcCommentSkip,@nqcCommentGroup,nqcCommentStartError,nqcParen,nqcBracket +syn region nqcDefine start="^\s*#\s*\(define\|undef\)\>" skip="\\$" end="$" contains=ALLBUT,@nqcPreProcGroup +syn region nqcPreProc start="^\s*#\s*\(pragma\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@nqcPreProcGroup + +if !exists("nqc_minlines") + if !exists("nqc_no_if0") + let nqc_minlines = 50 " #if 0 constructs can be long + else + let nqc_minlines = 15 " mostly for () constructs + endif +endif +exec "syn sync ccomment nqcComment minlines=" . nqc_minlines + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link nqcLabel Label +hi def link nqcConditional Conditional +hi def link nqcRepeat Repeat +hi def link nqcCharacter Character +hi def link nqcNumber Number +hi def link nqcFloat Float +hi def link nqcFunction Function +hi def link nqcParenError nqcError +hi def link nqcErrInParen nqcError +hi def link nqcErrInBracket nqcError +hi def link nqcCommentL nqcComment +hi def link nqcCommentStart nqcComment +hi def link nqcCommentError nqcError +hi def link nqcCommentStartError nqcError +hi def link nqcSpaceError nqcError +hi def link nqcStorageClass StorageClass +hi def link nqcInclude Include +hi def link nqcPreProc PreProc +hi def link nqcDefine Macro +hi def link nqcIncluded String +hi def link nqcError Error +hi def link nqcStatement Statement +hi def link nqcEvents Statement +hi def link nqcPreCondit PreCondit +hi def link nqcType Type +hi def link nqcConstant Constant +hi def link nqcCommentSkip nqcComment +hi def link nqcComment Comment +hi def link nqcTodo Todo +hi def link nqcCppSkip nqcCppOut +hi def link nqcCppOut2 nqcCppOut +hi def link nqcCppOut Comment + + +let b:current_syntax = "nqc" + +" vim: ts=8 + +endif diff --git a/syntax/nroff.vim b/syntax/nroff.vim new file mode 100644 index 0000000..e4facd2 --- /dev/null +++ b/syntax/nroff.vim @@ -0,0 +1,253 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" VIM syntax file +" Language: nroff/groff +" Maintainer: Pedro Alejandro López-Valencia +" URL: http://vorbote.wordpress.com/ +" Last Change: 2012 Feb 2 +" +" {{{1 Acknowledgements +" +" ACKNOWLEDGEMENTS: +" +" My thanks to Jérôme Plût , who was the +" creator and maintainer of this syntax file for several years. +" May I be as good at it as he has been. +" +" {{{1 Todo +" +" TODO: +" +" * Write syntax highlighting files for the preprocessors, +" and integrate with nroff.vim. +" +" +" {{{1 Start syntax highlighting. +" +" quit when a syntax file was already loaded +" +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" +" {{{1 plugin settings... +" +" {{{2 enable spacing error highlighting +" +if exists("nroff_space_errors") + syn match nroffError /\s\+$/ + syn match nroffSpaceError /[.,:;!?]\s\{2,}/ +endif +" +" +" {{{1 Special file settings +" +" {{{2 ms exdented paragraphs are not in the default paragraphs list. +" +setlocal paragraphs+=XP +" +" {{{2 Activate navigation to preporcessor sections. +" +if exists("b:preprocs_as_sections") + setlocal sections=EQTSPS[\ G1GS +endif + +" {{{1 Escape sequences +" ------------------------------------------------------------ + +syn match nroffEscChar /\\[CN]/ nextgroup=nroffEscCharArg +syn match nroffEscape /\\[*fgmnYV]/ nextgroup=nroffEscRegPar,nroffEscRegArg +syn match nroffEscape /\\s[+-]\=/ nextgroup=nroffSize +syn match nroffEscape /\\[$AbDhlLRvxXZ]/ nextgroup=nroffEscPar,nroffEscArg + +syn match nroffEscRegArg /./ contained +syn match nroffEscRegArg2 /../ contained +syn match nroffEscRegPar /(/ contained nextgroup=nroffEscRegArg2 +syn match nroffEscArg /./ contained +syn match nroffEscArg2 /../ contained +syn match nroffEscPar /(/ contained nextgroup=nroffEscArg2 +syn match nroffSize /\((\d\)\=\d/ contained + +syn region nroffEscCharArg start=/'/ end=/'/ contained +syn region nroffEscArg start=/'/ end=/'/ contained contains=nroffEscape,@nroffSpecial + +if exists("b:nroff_is_groff") + syn region nroffEscRegArg matchgroup=nroffEscape start=/\[/ end=/\]/ contained oneline + syn region nroffSize matchgroup=nroffEscape start=/\[/ end=/\]/ contained +endif + +syn match nroffEscape /\\[adprtu{}]/ +syn match nroffEscape /\\$/ +syn match nroffEscape /\\\$[@*]/ + +" {{{1 Strings and special characters +" ------------------------------------------------------------ + +syn match nroffSpecialChar /\\[\\eE?!-]/ +syn match nroffSpace "\\[&%~|^0)/,]" +syn match nroffSpecialChar /\\(../ + +if exists("b:nroff_is_groff") + syn match nroffSpecialChar /\\\[[^]]*]/ + syn region nroffPreserve matchgroup=nroffSpecialChar start=/\\?/ end=/\\?/ oneline +endif + +syn region nroffPreserve matchgroup=nroffSpecialChar start=/\\!/ end=/$/ oneline + +syn cluster nroffSpecial contains=nroffSpecialChar,nroffSpace + + +syn region nroffString start=/"/ end=/"/ skip=/\\$/ contains=nroffEscape,@nroffSpecial contained +syn region nroffString start=/'/ end=/'/ skip=/\\$/ contains=nroffEscape,@nroffSpecial contained + + +" {{{1 Numbers and units +" ------------------------------------------------------------ +syn match nroffNumBlock /[0-9.]\a\=/ contained contains=nroffNumber +syn match nroffNumber /\d\+\(\.\d*\)\=/ contained nextgroup=nroffUnit,nroffBadChar +syn match nroffNumber /\.\d\+)/ contained nextgroup=nroffUnit,nroffBadChar +syn match nroffBadChar /./ contained +syn match nroffUnit /[icpPszmnvMu]/ contained + + +" {{{1 Requests +" ------------------------------------------------------------ + +" Requests begin with . or ' at the beginning of a line, or +" after .if or .ie. + +syn match nroffReqLeader /^[.']/ nextgroup=nroffReqName skipwhite +syn match nroffReqLeader /[.']/ contained nextgroup=nroffReqName skipwhite + +if exists("b:nroff_is_groff") +" +" GNU troff allows long request names +" + syn match nroffReqName /[^\t \\\[?]\+/ contained nextgroup=nroffReqArg +else + syn match nroffReqName /[^\t \\\[?]\{1,2}/ contained nextgroup=nroffReqArg +endif + +syn region nroffReqArg start=/\S/ skip=/\\$/ end=/$/ contained contains=nroffEscape,@nroffSpecial,nroffString,nroffError,nroffSpaceError,nroffNumBlock,nroffComment + +" {{{2 Conditional: .if .ie .el +syn match nroffReqName /\(if\|ie\)/ contained nextgroup=nroffCond skipwhite +syn match nroffReqName /el/ contained nextgroup=nroffReqLeader skipwhite +syn match nroffCond /\S\+/ contained nextgroup=nroffReqLeader skipwhite + +" {{{2 String definition: .ds .as +syn match nroffReqname /[da]s/ contained nextgroup=nroffDefIdent skipwhite +syn match nroffDefIdent /\S\+/ contained nextgroup=nroffDefinition skipwhite +syn region nroffDefinition matchgroup=nroffSpecialChar start=/"/ matchgroup=NONE end=/\\"/me=e-2 skip=/\\$/ start=/\S/ end=/$/ contained contains=nroffDefSpecial +syn match nroffDefSpecial /\\$/ contained +syn match nroffDefSpecial /\\\((.\)\=./ contained + +if exists("b:nroff_is_groff") + syn match nroffDefSpecial /\\\[[^]]*]/ contained +endif + +" {{{2 Macro definition: .de .am, also diversion: .di +syn match nroffReqName /\(d[ei]\|am\)/ contained nextgroup=nroffIdent skipwhite +syn match nroffIdent /[^[?( \t]\+/ contained +if exists("b:nroff_is_groff") + syn match nroffReqName /als/ contained nextgroup=nroffIdent skipwhite +endif + +" {{{2 Register definition: .rn .rr +syn match nroffReqName /[rn]r/ contained nextgroup=nroffIdent skipwhite +if exists("b:nroff_is_groff") + syn match nroffReqName /\(rnn\|aln\)/ contained nextgroup=nroffIdent skipwhite +endif + + +" {{{1 eqn/tbl/pic +" ------------------------------------------------------------ +" +" XXX: write proper syntax highlight for eqn / tbl / pic ? +" + +syn region nroffEquation start=/^\.\s*EQ\>/ end=/^\.\s*EN\>/ +syn region nroffTable start=/^\.\s*TS\>/ end=/^\.\s*TE\>/ +syn region nroffPicture start=/^\.\s*PS\>/ end=/^\.\s*PE\>/ +syn region nroffRefer start=/^\.\s*\[\>/ end=/^\.\s*\]\>/ +syn region nroffGrap start=/^\.\s*G1\>/ end=/^\.\s*G2\>/ +syn region nroffGremlin start=/^\.\s*GS\>/ end=/^\.\s*GE|GF\>/ + +" {{{1 Comments +" ------------------------------------------------------------ + +syn region nroffIgnore start=/^[.']\s*ig/ end=/^['.]\s*\./ +syn match nroffComment /\(^[.']\s*\)\=\\".*/ contains=nroffTodo +syn match nroffComment /^'''.*/ contains=nroffTodo + +if exists("b:nroff_is_groff") + syn match nroffComment "\\#.*$" contains=nroffTodo +endif + +syn keyword nroffTodo TODO XXX FIXME contained + +" {{{1 Hilighting +" ------------------------------------------------------------ +" + +" +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +" + +hi def link nroffEscChar nroffSpecialChar +hi def link nroffEscCharAr nroffSpecialChar +hi def link nroffSpecialChar SpecialChar +hi def link nroffSpace Delimiter + +hi def link nroffEscRegArg2 nroffEscRegArg +hi def link nroffEscRegArg nroffIdent + +hi def link nroffEscArg2 nroffEscArg +hi def link nroffEscPar nroffEscape + +hi def link nroffEscRegPar nroffEscape +hi def link nroffEscArg nroffEscape +hi def link nroffSize nroffEscape +hi def link nroffEscape Preproc + +hi def link nroffIgnore Comment +hi def link nroffComment Comment +hi def link nroffTodo Todo + +hi def link nroffReqLeader nroffRequest +hi def link nroffReqName nroffRequest +hi def link nroffRequest Statement +hi def link nroffCond PreCondit +hi def link nroffDefIdent nroffIdent +hi def link nroffIdent Identifier + +hi def link nroffEquation PreProc +hi def link nroffTable PreProc +hi def link nroffPicture PreProc +hi def link nroffRefer PreProc +hi def link nroffGrap PreProc +hi def link nroffGremlin PreProc + +hi def link nroffNumber Number +hi def link nroffBadChar nroffError +hi def link nroffSpaceError nroffError +hi def link nroffError Error + +hi def link nroffPreserve String +hi def link nroffString String +hi def link nroffDefinition String +hi def link nroffDefSpecial Special + + +let b:current_syntax = "nroff" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim600: set fdm=marker fdl=2: + +endif diff --git a/syntax/nsis.vim b/syntax/nsis.vim new file mode 100644 index 0000000..363723b --- /dev/null +++ b/syntax/nsis.vim @@ -0,0 +1,260 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: NSIS script, for version of NSIS 1.91 and later +" Maintainer: Alex Jakushev +" Last Change: 2004 May 12 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + + +"COMMENTS +syn keyword nsisTodo todo attention note fixme readme +syn region nsisComment start=";" end="$" contains=nsisTodo +syn region nsisComment start="#" end="$" contains=nsisTodo + +"LABELS +syn match nsisLocalLabel "\a\S\{-}:" +syn match nsisGlobalLabel "\.\S\{-1,}:" + +"PREPROCESSOR +syn match nsisPreprocSubst "${.\{-}}" +syn match nsisDefine "!define\>" +syn match nsisDefine "!undef\>" +syn match nsisPreCondit "!ifdef\>" +syn match nsisPreCondit "!ifndef\>" +syn match nsisPreCondit "!endif\>" +syn match nsisPreCondit "!else\>" +syn match nsisMacro "!macro\>" +syn match nsisMacro "!macroend\>" +syn match nsisMacro "!insertmacro\>" + +"COMPILER UTILITY +syn match nsisInclude "!include\>" +syn match nsisSystem "!cd\>" +syn match nsisSystem "!system\>" +syn match nsisSystem "!packhdr\>" + +"VARIABLES +syn match nsisUserVar "$\d" +syn match nsisUserVar "$R\d" +syn match nsisSysVar "$INSTDIR" +syn match nsisSysVar "$OUTDIR" +syn match nsisSysVar "$CMDLINE" +syn match nsisSysVar "$PROGRAMFILES" +syn match nsisSysVar "$DESKTOP" +syn match nsisSysVar "$EXEDIR" +syn match nsisSysVar "$WINDIR" +syn match nsisSysVar "$SYSDIR" +syn match nsisSysVar "$TEMP" +syn match nsisSysVar "$STARTMENU" +syn match nsisSysVar "$SMPROGRAMS" +syn match nsisSysVar "$SMSTARTUP" +syn match nsisSysVar "$QUICKLAUNCH" +syn match nsisSysVar "$HWNDPARENT" +syn match nsisSysVar "$\\r" +syn match nsisSysVar "$\\n" +syn match nsisSysVar "$\$" + +"STRINGS +syn region nsisString start=/"/ skip=/'\|`/ end=/"/ contains=nsisPreprocSubst,nsisUserVar,nsisSysVar,nsisRegistry +syn region nsisString start=/'/ skip=/"\|`/ end=/'/ contains=nsisPreprocSubst,nsisUserVar,nsisSysVar,nsisRegistry +syn region nsisString start=/`/ skip=/"\|'/ end=/`/ contains=nsisPreprocSubst,nsisUserVar,nsisSysVar,nsisRegistry + +"CONSTANTS +syn keyword nsisBoolean true false on off + +syn keyword nsisAttribOptions hide show nevershow auto force try ifnewer normal silent silentlog +syn keyword nsisAttribOptions smooth colored SET CUR END RO none listonly textonly both current all +syn keyword nsisAttribOptions zlib bzip2 lzma + +syn match nsisAttribOptions '\/NOCUSTOM' +syn match nsisAttribOptions '\/CUSTOMSTRING' +syn match nsisAttribOptions '\/COMPONENTSONLYONCUSTOM' +syn match nsisAttribOptions '\/windows' +syn match nsisAttribOptions '\/r' +syn match nsisAttribOptions '\/oname' +syn match nsisAttribOptions '\/REBOOTOK' +syn match nsisAttribOptions '\/SILENT' +syn match nsisAttribOptions '\/FILESONLY' +syn match nsisAttribOptions '\/SHORT' + +syn keyword nsisExecShell SW_SHOWNORMAL SW_SHOWMAXIMIZED SW_SHOWMINIMIZED + +syn keyword nsisRegistry HKCR HKLM HKCU HKU HKCC HKDD HKPD +syn keyword nsisRegistry HKEY_CLASSES_ROOT HKEY_LOCAL_MACHINE HKEY_CURRENT_USER HKEY_USERS +syn keyword nsisRegistry HKEY_CURRENT_CONFIG HKEY_DYN_DATA HKEY_PERFORMANCE_DATA + +syn keyword nsisFileAttrib NORMAL ARCHIVE HIDDEN OFFLINE READONLY SYSTEM TEMPORARY +syn keyword nsisFileAttrib FILE_ATTRIBUTE_NORMAL FILE_ATTRIBUTE_ARCHIVE FILE_ATTRIBUTE_HIDDEN +syn keyword nsisFileAttrib FILE_ATTRIBUTE_OFFLINE FILE_ATTRIBUTE_READONLY FILE_ATTRIBUTE_SYSTEM +syn keyword nsisFileAttrib FILE_ATTRIBUTE_TEMPORARY + +syn keyword nsisMessageBox MB_OK MB_OKCANCEL MB_ABORTRETRYIGNORE MB_RETRYCANCEL MB_YESNO MB_YESNOCANCEL +syn keyword nsisMessageBox MB_ICONEXCLAMATION MB_ICONINFORMATION MB_ICONQUESTION MB_ICONSTOP +syn keyword nsisMessageBox MB_TOPMOST MB_SETFOREGROUND MB_RIGHT +syn keyword nsisMessageBox MB_DEFBUTTON1 MB_DEFBUTTON2 MB_DEFBUTTON3 MB_DEFBUTTON4 +syn keyword nsisMessageBox IDABORT IDCANCEL IDIGNORE IDNO IDOK IDRETRY IDYES + +syn match nsisNumber "\<[^0]\d*\>" +syn match nsisNumber "\<0x\x\+\>" +syn match nsisNumber "\<0\o*\>" + + +"INSTALLER ATTRIBUTES - General installer configuration +syn keyword nsisAttribute OutFile Name Caption SubCaption BrandingText Icon +syn keyword nsisAttribute WindowIcon BGGradient SilentInstall SilentUnInstall +syn keyword nsisAttribute CRCCheck MiscButtonText InstallButtonText FileErrorText + +"INSTALLER ATTRIBUTES - Install directory configuration +syn keyword nsisAttribute InstallDir InstallDirRegKey + +"INSTALLER ATTRIBUTES - License page configuration +syn keyword nsisAttribute LicenseText LicenseData + +"INSTALLER ATTRIBUTES - Component page configuration +syn keyword nsisAttribute ComponentText InstType EnabledBitmap DisabledBitmap SpaceTexts + +"INSTALLER ATTRIBUTES - Directory page configuration +syn keyword nsisAttribute DirShow DirText AllowRootDirInstall + +"INSTALLER ATTRIBUTES - Install page configuration +syn keyword nsisAttribute InstallColors InstProgressFlags AutoCloseWindow +syn keyword nsisAttribute ShowInstDetails DetailsButtonText CompletedText + +"INSTALLER ATTRIBUTES - Uninstall configuration +syn keyword nsisAttribute UninstallText UninstallIcon UninstallCaption +syn keyword nsisAttribute UninstallSubCaption ShowUninstDetails UninstallButtonText + +"COMPILER ATTRIBUTES +syn keyword nsisCompiler SetOverwrite SetCompress SetCompressor SetDatablockOptimize SetDateSave + + +"FUNCTIONS - general purpose +syn keyword nsisInstruction SetOutPath File Exec ExecWait ExecShell +syn keyword nsisInstruction Rename Delete RMDir + +"FUNCTIONS - registry & ini +syn keyword nsisInstruction WriteRegStr WriteRegExpandStr WriteRegDWORD WriteRegBin +syn keyword nsisInstruction WriteINIStr ReadRegStr ReadRegDWORD ReadINIStr ReadEnvStr +syn keyword nsisInstruction ExpandEnvStrings DeleteRegValue DeleteRegKey EnumRegKey +syn keyword nsisInstruction EnumRegValue DeleteINISec DeleteINIStr + +"FUNCTIONS - general purpose, advanced +syn keyword nsisInstruction CreateDirectory CopyFiles SetFileAttributes CreateShortCut +syn keyword nsisInstruction GetFullPathName SearchPath GetTempFileName CallInstDLL +syn keyword nsisInstruction RegDLL UnRegDLL GetDLLVersion GetDLLVersionLocal +syn keyword nsisInstruction GetFileTime GetFileTimeLocal + +"FUNCTIONS - Branching, flow control, error checking, user interaction, etc instructions +syn keyword nsisInstruction Goto Call Return IfErrors ClearErrors SetErrors FindWindow +syn keyword nsisInstruction SendMessage IsWindow IfFileExists MessageBox StrCmp +syn keyword nsisInstruction IntCmp IntCmpU Abort Quit GetFunctionAddress GetLabelAddress +syn keyword nsisInstruction GetCurrentAddress + +"FUNCTIONS - File and directory i/o instructions +syn keyword nsisInstruction FindFirst FindNext FindClose FileOpen FileClose FileRead +syn keyword nsisInstruction FileWrite FileReadByte FileWriteByte FileSeek + +"FUNCTIONS - Misc instructions +syn keyword nsisInstruction SetDetailsView SetDetailsPrint SetAutoClose DetailPrint +syn keyword nsisInstruction Sleep BringToFront HideWindow SetShellVarContext + +"FUNCTIONS - String manipulation support +syn keyword nsisInstruction StrCpy StrLen + +"FUNCTIONS - Stack support +syn keyword nsisInstruction Push Pop Exch + +"FUNCTIONS - Integer manipulation support +syn keyword nsisInstruction IntOp IntFmt + +"FUNCTIONS - Rebooting support +syn keyword nsisInstruction Reboot IfRebootFlag SetRebootFlag + +"FUNCTIONS - Uninstaller instructions +syn keyword nsisInstruction WriteUninstaller + +"FUNCTIONS - Install logging instructions +syn keyword nsisInstruction LogSet LogText + +"FUNCTIONS - Section management instructions +syn keyword nsisInstruction SectionSetFlags SectionGetFlags SectionSetText +syn keyword nsisInstruction SectionGetText + + +"SPECIAL FUNCTIONS - install +syn match nsisCallback "\.onInit" +syn match nsisCallback "\.onUserAbort" +syn match nsisCallback "\.onInstSuccess" +syn match nsisCallback "\.onInstFailed" +syn match nsisCallback "\.onVerifyInstDir" +syn match nsisCallback "\.onNextPage" +syn match nsisCallback "\.onPrevPage" +syn match nsisCallback "\.onSelChange" + +"SPECIAL FUNCTIONS - uninstall +syn match nsisCallback "un\.onInit" +syn match nsisCallback "un\.onUserAbort" +syn match nsisCallback "un\.onInstSuccess" +syn match nsisCallback "un\.onInstFailed" +syn match nsisCallback "un\.onVerifyInstDir" +syn match nsisCallback "un\.onNextPage" + + +"STATEMENTS - sections +syn keyword nsisStatement Section SectionIn SectionEnd SectionDivider +syn keyword nsisStatement AddSize + +"STATEMENTS - functions +syn keyword nsisStatement Function FunctionEnd + +"STATEMENTS - pages +syn keyword nsisStatement Page UninstPage PageEx PageExEnc PageCallbacks + + +"ERROR +syn keyword nsisError UninstallExeName + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link nsisInstruction Function +hi def link nsisComment Comment +hi def link nsisLocalLabel Label +hi def link nsisGlobalLabel Label +hi def link nsisStatement Statement +hi def link nsisString String +hi def link nsisBoolean Boolean +hi def link nsisAttribOptions Constant +hi def link nsisExecShell Constant +hi def link nsisFileAttrib Constant +hi def link nsisMessageBox Constant +hi def link nsisRegistry Identifier +hi def link nsisNumber Number +hi def link nsisError Error +hi def link nsisUserVar Identifier +hi def link nsisSysVar Identifier +hi def link nsisAttribute Type +hi def link nsisCompiler Type +hi def link nsisTodo Todo +hi def link nsisCallback Operator +" preprocessor commands +hi def link nsisPreprocSubst PreProc +hi def link nsisDefine Define +hi def link nsisMacro Macro +hi def link nsisPreCondit PreCondit +hi def link nsisInclude Include +hi def link nsisSystem PreProc + + +let b:current_syntax = "nsis" + + +endif diff --git a/syntax/obj.vim b/syntax/obj.vim new file mode 100644 index 0000000..d04227b --- /dev/null +++ b/syntax/obj.vim @@ -0,0 +1,87 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: 3D wavefront's obj file +" Maintainer: Vincent Berthoux +" File Types: .obj (used in 3D) +" Last Change: 2010 May 18 +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match objError "^\a\+" + +syn match objKeywords "^cstype\s" +syn match objKeywords "^ctech\s" +syn match objKeywords "^stech\s" +syn match objKeywords "^deg\s" +syn match objKeywords "^curv\(2\?\)\s" +syn match objKeywords "^parm\s" +syn match objKeywords "^surf\s" +syn match objKeywords "^end\s" +syn match objKeywords "^bzp\s" +syn match objKeywords "^bsp\s" +syn match objKeywords "^res\s" +syn match objKeywords "^cdc\s" +syn match objKeywords "^con\s" + +syn match objKeywords "^shadow_obj\s" +syn match objKeywords "^trace_obj\s" +syn match objKeywords "^usemap\s" +syn match objKeywords "^lod\s" +syn match objKeywords "^maplib\s" +syn match objKeywords "^d_interp\s" +syn match objKeywords "^c_interp\s" +syn match objKeywords "^bevel\s" +syn match objKeywords "^mg\s" +syn match objKeywords "^s\s" +syn match objKeywords "^con\s" +syn match objKeywords "^trim\s" +syn match objKeywords "^hole\s" +syn match objKeywords "^scrv\s" +syn match objKeywords "^sp\s" +syn match objKeywords "^step\s" +syn match objKeywords "^bmat\s" +syn match objKeywords "^csh\s" +syn match objKeywords "^call\s" + +syn match objComment "^#.*" +syn match objVertex "^v\s" +syn match objFace "^f\s" +syn match objVertice "^vt\s" +syn match objNormale "^vn\s" +syn match objGroup "^g\s.*" +syn match objMaterial "^usemtl\s.*" +syn match objInclude "^mtllib\s.*" + +syn match objFloat "-\?\d\+\.\d\+\(e\(+\|-\)\d\+\)\?" +syn match objInt "\d\+" +syn match objIndex "\d\+\/\d*\/\d*" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link objError Error +hi def link objComment Comment +hi def link objInclude PreProc +hi def link objFloat Float +hi def link objInt Number +hi def link objGroup Structure +hi def link objIndex Constant +hi def link objMaterial Label + +hi def link objVertex Keyword +hi def link objNormale Keyword +hi def link objVertice Keyword +hi def link objFace Keyword +hi def link objKeywords Keyword + + + +let b:current_syntax = "obj" + +" vim: ts=8 + +endif diff --git a/syntax/objc.vim b/syntax/objc.vim new file mode 100644 index 0000000..07d8050 --- /dev/null +++ b/syntax/objc.vim @@ -0,0 +1,537 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Objective-C +" Maintainer: Kazunobu Kuriyama +" Last Change: 2015 Dec 14 + +""" Preparation for loading ObjC stuff +if exists("b:current_syntax") + finish +endif +if &filetype != 'objcpp' + syn clear + runtime! syntax/c.vim +endif +let s:cpo_save = &cpo +set cpo&vim + +""" ObjC proper stuff follows... + +syn keyword objcPreProcMacro __OBJC__ __OBJC2__ __clang__ + +" Defined Types +syn keyword objcPrincipalType id Class SEL IMP BOOL instancetype +syn keyword objcUsefulTerm nil Nil NO YES + +" Preprocessor Directives +syn region objcImported display contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match objcImported display contained "\(<\h[-a-zA-Z0-9_/]*\.h>\|<[a-z0-9]\+>\)" +syn match objcImport display "^\s*\(%:\|#\)\s*import\>\s*["<]" contains=objcImported + +" ObjC Compiler Directives +syn match objcObjDef display /@interface\>\|@implementation\>\|@end\>\|@class\>/ +syn match objcProtocol display /@protocol\>\|@optional\>\|@required\>/ +syn match objcProperty display /@property\>\|@synthesize\>\|@dynamic\>/ +syn match objcIvarScope display /@private\>\|@protected\>\|@public\>\|@package\>/ +syn match objcInternalRep display /@selector\>\|@encode\>/ +syn match objcException display /@try\>\|@throw\>\|@catch\|@finally\>/ +syn match objcThread display /@synchronized\>/ +syn match objcPool display /@autoreleasepool\>/ +syn match objcModuleImport display /@import\>/ + +" ObjC Constant Strings +syn match objcSpecial display contained "%@" +syn region objcString start=+\(@"\|"\)+ skip=+\\\\\|\\"+ end=+"+ contains=cFormat,cSpecial,objcSpecial + +" ObjC Hidden Arguments +syn keyword objcHiddenArgument self _cmd super + +" ObjC Type Qualifiers for Blocks +syn keyword objcBlocksQualifier __block +" ObjC Type Qualifiers for Object Lifetime +syn keyword objcObjectLifetimeQualifier __strong __weak __unsafe_unretained __autoreleasing +" ObjC Type Qualifiers for Toll-Free Bridge +syn keyword objcTollFreeBridgeQualifier __bridge __bridge_retained __bridge_transfer + +" ObjC Type Qualifiers for Remote Messaging +syn match objcRemoteMessagingQualifier display contained /\((\s*oneway\s\+\|(\s*in\s\+\|(\s*out\s\+\|(\s*inout\s\+\|(\s*bycopy\s\+\(in\(out\)\?\|out\)\?\|(\s*byref\s\+\(in\(out\)\?\|out\)\?\)/hs=s+1 + +" ObjC Storage Classes +syn keyword objcStorageClass _Nullable _Nonnull _Null_unspecified +syn keyword objcStorageClass __nullable __nonnull __null_unspecified +syn keyword objcStorageClass nullable nonnull null_unspecified + +" ObjC type specifier +syn keyword objcTypeSpecifier __kindof __covariant + +" ObjC Type Infomation Parameters +syn keyword objcTypeInfoParams ObjectType KeyType + +" shorthand +syn cluster objcTypeQualifier contains=objcBlocksQualifier,objcObjectLifetimeQualifier,objcTollFreeBridgeQualifier,objcRemoteMessagingQualifier + +" ObjC Fast Enumeration +syn match objcFastEnumKeyword display /\sin\(\s\|$\)/ + +" ObjC Literal Syntax +syn match objcLiteralSyntaxNumber display /@\(YES\>\|NO\>\|\d\|-\|+\)/ contains=cNumber,cFloat,cOctal +syn match objcLiteralSyntaxSpecialChar display /@'/ contains=cSpecialCharacter +syn match objcLiteralSyntaxChar display /@'[^\\]'/ +syn match objcLiteralSyntaxOp display /@\((\|\[\|{\)/me=e-1,he=e-1 + +" ObjC Declared Property Attributes +syn match objDeclPropAccessorNameAssign display /\s*=\s*/ contained +syn region objcDeclPropAccessorName display start=/\(getter\|setter\)/ end=/\h\w*/ contains=objDeclPropAccessorNameAssign +syn keyword objcDeclPropAccessorType readonly readwrite contained +syn keyword objcDeclPropAssignSemantics assign retain copy contained +syn keyword objcDeclPropAtomicity nonatomic contained +syn keyword objcDeclPropARC strong weak contained +syn match objcDeclPropNullable /\((\|\s\)nullable\(,\|)\)/ms=s+1,hs=s+1,me=e-1,he=e-1 contained +syn match objcDeclPropNonnull /\((\|\s\)nonnull\(,\|)\)/ms=s+1,hs=s+1,me=e-1,he=e-1 contained +syn match objcDeclPropNullUnspecified /\((\|\s\)null_unspecified\(,\|)\)/ms=s+1,hs=s+1,me=e-1,he=e-1 contained +syn keyword objcDeclProcNullResettable null_resettable contained +syn region objcDeclProp display transparent keepend start=/@property\s*(/ end=/)/ contains=objcProperty,objcDeclPropAccessorName,objcDeclPropAccessorType,objcDeclPropAssignSemantics,objcDeclPropAtomicity,objcDeclPropARC,objcDeclPropNullable,objcDeclPropNonnull,objcDeclPropNullUnspecified,objcDeclProcNullResettable + +" To distinguish colons in methods and dictionaries from those in C's labels. +syn match objcColon display /^\s*\h\w*\s*\:\(\s\|.\)/me=e-1,he=e-1 + +" To distinguish a protocol list from system header files +syn match objcProtocolList display /<\h\w*\(\s*,\s*\h\w*\)*>/ contains=objcPrincipalType,cType,Type,objcType,objcTypeInfoParams + +" Type info for collection classes +syn match objcTypeInfo display /<\h\w*\s*<\(\h\w*\s*\**\|\h\w*\)>>/ contains=objcPrincipalType,cType,Type,objcType,objcTypeInfoParams + +" shorthand +syn cluster objcCEntities contains=cType,cStructure,cStorageClass,cString,cCharacter,cSpecialCharacter,cNumbers,cConstant,cOperator,cComment,cCommentL,cStatement,cLabel,cConditional,cRepeat +syn cluster objcObjCEntities contains=objcHiddenArgument,objcPrincipalType,objcString,objcUsefulTerm,objcProtocol,objcInternalRep,objcException,objcThread,objcPool,objcModuleImport,@objcTypeQualifier,objcLiteralSyntaxNumber,objcLiteralSyntaxOp,objcLiteralSyntaxChar,objcLiteralSyntaxSpecialChar,objcProtocolList,objcColon,objcFastEnumKeyword,objcType,objcClass,objcMacro,objcEnum,objcEnumValue,objcExceptionValue,objcNotificationValue,objcConstVar,objcPreProcMacro,objcTypeInfo + +" Objective-C Message Expressions +syn region objcMethodCall start=/\[/ end=/\]/ contains=objcMethodCall,objcBlocks,@objcObjCEntities,@objcCEntities + +" To distinguish class method and instance method +syn match objcInstanceMethod display /^s*-\s*/ +syn match objcClassMethod display /^s*+\s*/ + +" ObjC Blocks +syn region objcBlocks start=/\(\^\s*([^)]\+)\s*{\|\^\s*{\)/ end=/}/ contains=objcBlocks,objcMethodCall,@objcObjCEntities,@objcCEntities + +syn cluster cParenGroup add=objcMethodCall +syn cluster cPreProcGroup add=objcMethodCall + +""" Foundation Framework +syn match objcClass /Protocol\s*\*/me=s+8,he=s+8 + +""""""""""""""""" +" NSObjCRuntime.h +syn keyword objcType NSInteger NSUInteger NSComparator +syn keyword objcEnum NSComparisonResult +syn keyword objcEnumValue NSOrderedAscending NSOrderedSame NSOrderedDescending +syn keyword objcEnum NSEnumerationOptions +syn keyword objcEnumValue NSEnumerationConcurrent NSEnumerationReverse +syn keyword objcEnum NSSortOptions +syn keyword objcEnumValue NSSortConcurrent NSSortStable +syn keyword objcEnumValue NSNotFound +syn keyword objcMacro NSIntegerMax NSIntegerMin NSUIntegerMax +syn keyword objcMacro NS_INLINE NS_BLOCKS_AVAILABLE NS_NONATOMIC_IOSONLY NS_FORMAT_FUNCTION NS_FORMAT_ARGUMENT NS_RETURNS_RETAINED NS_RETURNS_NOT_RETAINED NS_RETURNS_INNER_POINTER NS_AUTOMATED_REFCOUNT_UNAVAILABLE NS_AUTOMATED_REFCOUNT_WEAK_UNAVAILABLE NS_REQUIRES_PROPERTY_DEFINITIONS NS_REPLACES_RECEIVER NS_RELEASES_ARGUMENT NS_VALID_UNTIL_END_OF_SCOPE NS_ROOT_CLASS NS_REQUIRES_SUPER NS_PROTOCOL_REQUIRES_EXPLICIT_IMPLEMENTATION NS_DESIGNATED_INITIALIZER NS_REQUIRES_NIL_TERMINATION +syn keyword objcEnum NSQualityOfService +syn keyword objcEnumValue NSQualityOfServiceUserInteractive NSQualityOfServiceUserInitiated NSQualityOfServiceUtility NSQualityOfServiceBackground NSQualityOfServiceDefault +" NSRange.h +syn keyword objcType NSRange NSRangePointer +" NSGeometry.h +syn keyword objcType NSPoint NSPointPointer NSPointArray NSSize NSSizePointer NSSizeArray NSRect NSRectPointer NSRectArray NSEdgeInsets +syn keyword objcEnum NSRectEdge +syn keyword objcEnumValue NSMinXEdge NSMinYEdge NSMaxXEdge NSMaxYEdge +syn keyword objcEnumValue NSRectEdgeMinX NSRectEdgeMinY NSRectEdgeMaxX NSRectEdgeMaxY +syn keyword objcConstVar NSZeroPoint NSZeroSize NSZeroRect NSEdgeInsetsZero +syn keyword cType CGFloat CGPoint CGSize CGRect +syn keyword objcEnum NSAlignmentOptions +syn keyword objcEnumValue NSAlignMinXInward NSAlignMinYInward NSAlignMaxXInward NSAlignMaxYInward NSAlignWidthInward NSAlignHeightInward NSAlignMinXOutward NSAlignMinYOutward NSAlignMaxXOutward NSAlignMaxYOutward NSAlignWidthOutward NSAlignHeightOutward NSAlignMinXNearest NSAlignMinYNearest NSAlignMaxXNearest NSAlignMaxYNearest NSAlignWidthNearest NSAlignHeightNearest NSAlignRectFlipped NSAlignAllEdgesInward NSAlignAllEdgesOutward NSAlignAllEdgesNearest +" NSDecimal.h +syn keyword objcType NSDecimal +syn keyword objcEnum NSRoundingMode +syn keyword objcEnumValue NSRoundPlain NSRoundDown NSRoundUp NSRoundBankers +syn keyword objcEnum NSCalculationError +syn keyword objcEnumValue NSCalculationNoError NSCalculationLossOfPrecision NSCalculationUnderflow NSCalculationOverflow NSCalculationDivideByZero +syn keyword objcConstVar NSDecimalMaxSize NSDecimalNoScale +" NSDate.h +syn match objcClass /NSDate\s*\*/me=s+6,he=s+6 +syn keyword objcType NSTimeInterval +syn keyword objcNotificationValue NSSystemClockDidChangeNotification +syn keyword objcMacro NSTimeIntervalSince1970 +" NSZone.h +syn match objcType /NSZone\s*\*/me=s+6,he=s+6 +syn keyword objcEnumValue NSScannedOption NSCollectorDisabledOption +" NSError.h +syn match objcClass /NSError\s*\*/me=s+7,he=s+7 +syn keyword objcConstVar NSCocoaErrorDomain NSPOSIXErrorDomain NSOSStatusErrorDomain NSMachErrorDomain NSUnderlyingErrorKey NSLocalizedDescriptionKey NSLocalizedFailureReasonErrorKey NSLocalizedRecoverySuggestionErrorKey NSLocalizedRecoveryOptionsErrorKey NSRecoveryAttempterErrorKey NSHelpAnchorErrorKey NSStringEncodingErrorKey NSURLErrorKey NSFilePathErrorKey +" NSException.h +syn match objcClass /NSException\s*\*/me=s+11,he=s+11 +syn match objcClass /NSAssertionHandler\s*\*/me=s+18,he=s+18 +syn keyword objcType NSUncaughtExceptionHandler +syn keyword objcConstVar NSGenericException NSRangeException NSInvalidArgumentException NSInternalInconsistencyException NSMallocException NSObjectInaccessibleException NSObjectNotAvailableException NSDestinationInvalidException NSPortTimeoutException NSInvalidSendPortException NSInvalidReceivePortException NSPortSendException NSPortReceiveException NSOldStyleException +" NSNotification.h +syn match objcClass /NSNotification\s*\*/me=s+14,he=s+14 +syn match objcClass /NSNotificationCenter\s*\*/me=s+20,he=s+20 +" NSDistributedNotificationCenter.h +syn match objcClass /NSDistributedNotificationCenter\s*\*/me=s+31,he=s+31 +syn keyword objcConstVar NSLocalNotificationCenterType +syn keyword objcEnum NSNotificationSuspensionBehavior +syn keyword objcEnumValue NSNotificationSuspensionBehaviorDrop NSNotificationSuspensionBehaviorCoalesce NSNotificationSuspensionBehaviorHold NSNotificationSuspensionBehaviorHold NSNotificationSuspensionBehaviorDeliverImmediately +syn keyword objcEnumValue NSNotificationDeliverImmediately NSNotificationPostToAllSessions +syn keyword objcEnum NSDistributedNotificationOptions +syn keyword objcEnumValue NSDistributedNotificationDeliverImmediately NSDistributedNotificationPostToAllSessions +" NSNotificationQueue.h +syn match objcClass /NSNotificationQueue\s*\*/me=s+19,he=s+19 +syn keyword objcEnum NSPostingStyle +syn keyword objcEnumValue NSPostWhenIdle NSPostASAP NSPostNow +syn keyword objcEnum NSNotificationCoalescing +syn keyword objcEnumValue NSNotificationNoCoalescing NSNotificationCoalescingOnName NSNotificationCoalescingOnSender +" NSEnumerator.h +syn match objcClass /NSEnumerator\s*\*/me=s+12,he=s+12 +syn match objcClass /NSEnumerator<.*>\s*\*/me=s+12,he=s+12 contains=objcTypeInfoParams +syn keyword objcType NSFastEnumerationState +" NSIndexSet.h +syn match objcClass /NSIndexSet\s*\*/me=s+10,he=s+10 +syn match objcClass /NSMutableIndexSet\s*\*/me=s+17,he=s+17 +" NSCharecterSet.h +syn match objcClass /NSCharacterSet\s*\*/me=s+14,he=s+14 +syn match objcClass /NSMutableCharacterSet\s*\*/me=s+21,he=s+21 +syn keyword objcConstVar NSOpenStepUnicodeReservedBase +" NSURL.h +syn match objcClass /NSURL\s*\*/me=s+5,he=s+5 +syn keyword objcEnum NSURLBookmarkCreationOptions +syn keyword objcEnumValue NSURLBookmarkCreationPreferFileIDResolution NSURLBookmarkCreationMinimalBookmark NSURLBookmarkCreationSuitableForBookmarkFile NSURLBookmarkCreationWithSecurityScope NSURLBookmarkCreationSecurityScopeAllowOnlyReadAccess +syn keyword objcEnum NSURLBookmarkResolutionOptions +syn keyword objcEnumValue NSURLBookmarkResolutionWithoutUI NSURLBookmarkResolutionWithoutMounting NSURLBookmarkResolutionWithSecurityScope +syn keyword objcType NSURLBookmarkFileCreationOptions +syn keyword objcConstVar NSURLFileScheme NSURLKeysOfUnsetValuesKey +syn keyword objcConstVar NSURLNameKey NSURLLocalizedNameKey NSURLIsRegularFileKey NSURLIsDirectoryKey NSURLIsSymbolicLinkKey NSURLIsVolumeKey NSURLIsPackageKey NSURLIsApplicationKey NSURLApplicationIsScriptableKey NSURLIsSystemImmutableKey NSURLIsUserImmutableKey NSURLIsHiddenKey NSURLHasHiddenExtensionKey NSURLCreationDateKey NSURLContentAccessDateKey NSURLContentModificationDateKey NSURLAttributeModificationDateKey NSURLLinkCountKey NSURLParentDirectoryURLKey NSURLVolumeURLKey NSURLTypeIdentifierKey NSURLLocalizedTypeDescriptionKey NSURLLabelNumberKey NSURLLabelColorKey NSURLLocalizedLabelKey NSURLEffectiveIconKey NSURLCustomIconKey NSURLFileResourceIdentifierKey NSURLVolumeIdentifierKey NSURLPreferredIOBlockSizeKey NSURLIsReadableKey NSURLIsWritableKey NSURLIsExecutableKey NSURLFileSecurityKey NSURLIsExcludedFromBackupKey NSURLTagNamesKey NSURLPathKey NSURLIsMountTriggerKey NSURLGenerationIdentifierKey NSURLDocumentIdentifierKey NSURLAddedToDirectoryDateKey NSURLQuarantinePropertiesKey NSURLFileResourceTypeKey +syn keyword objcConstVar NSURLFileResourceTypeNamedPipe NSURLFileResourceTypeCharacterSpecial NSURLFileResourceTypeDirectory NSURLFileResourceTypeBlockSpecial NSURLFileResourceTypeRegular NSURLFileResourceTypeSymbolicLink NSURLFileResourceTypeSocket NSURLFileResourceTypeUnknown NSURLThumbnailDictionaryKey NSURLThumbnailKey NSThumbnail1024x1024SizeKey +syn keyword objcConstVar NSURLFileSizeKey NSURLFileAllocatedSizeKey NSURLTotalFileSizeKey NSURLTotalFileAllocatedSizeKey NSURLIsAliasFileKey NSURLFileProtectionKey NSURLFileProtectionNone NSURLFileProtectionComplete NSURLFileProtectionCompleteUnlessOpen NSURLFileProtectionCompleteUntilFirstUserAuthentication +syn keyword objcConstVar NSURLVolumeLocalizedFormatDescriptionKey NSURLVolumeTotalCapacityKey NSURLVolumeAvailableCapacityKey NSURLVolumeResourceCountKey NSURLVolumeSupportsPersistentIDsKey NSURLVolumeSupportsSymbolicLinksKey NSURLVolumeSupportsHardLinksKey NSURLVolumeSupportsJournalingKey NSURLVolumeIsJournalingKey NSURLVolumeSupportsSparseFilesKey NSURLVolumeSupportsZeroRunsKey NSURLVolumeSupportsCaseSensitiveNamesKey NSURLVolumeSupportsCasePreservedNamesKey NSURLVolumeSupportsRootDirectoryDatesKey NSURLVolumeSupportsVolumeSizesKey NSURLVolumeSupportsRenamingKey NSURLVolumeSupportsAdvisoryFileLockingKey NSURLVolumeSupportsExtendedSecurityKey NSURLVolumeIsBrowsableKey NSURLVolumeMaximumFileSizeKey NSURLVolumeIsEjectableKey NSURLVolumeIsRemovableKey NSURLVolumeIsInternalKey NSURLVolumeIsAutomountedKey NSURLVolumeIsLocalKey NSURLVolumeIsReadOnlyKey NSURLVolumeCreationDateKey NSURLVolumeURLForRemountingKey NSURLVolumeUUIDStringKey NSURLVolumeNameKey NSURLVolumeLocalizedNameKey +syn keyword objcConstVar NSURLIsUbiquitousItemKey NSURLUbiquitousItemHasUnresolvedConflictsKey NSURLUbiquitousItemIsDownloadedKey NSURLUbiquitousItemIsDownloadingKey NSURLUbiquitousItemIsUploadedKey NSURLUbiquitousItemIsUploadingKey NSURLUbiquitousItemPercentDownloadedKey NSURLUbiquitousItemPercentUploadedKey NSURLUbiquitousItemDownloadingStatusKey NSURLUbiquitousItemDownloadingErrorKey NSURLUbiquitousItemUploadingErrorKey NSURLUbiquitousItemDownloadRequestedKey NSURLUbiquitousItemContainerDisplayNameKey NSURLUbiquitousItemDownloadingStatusNotDownloaded NSURLUbiquitousItemDownloadingStatusDownloaded NSURLUbiquitousItemDownloadingStatusCurrent +"""""""""""" +" NSString.h +syn match objcClass /NSString\s*\*/me=s+8,he=s+8 +syn match objcClass /NSMutableString\s*\*/me=s+15,he=s+15 +syn keyword objcType unichar +syn keyword objcExceptionValue NSParseErrorException NSCharacterConversionException +syn keyword objcMacro NSMaximumStringLength +syn keyword objcEnum NSStringCompareOptions +syn keyword objcEnumValue NSCaseInsensitiveSearch NSLiteralSearch NSBackwardsSearch NSAnchoredSearch NSNumericSearch NSDiacriticInsensitiveSearch NSWidthInsensitiveSearch NSForcedOrderingSearch NSRegularExpressionSearch +syn keyword objcEnum NSStringEncoding +syn keyword objcEnumValue NSProprietaryStringEncoding +syn keyword objcEnumValue NSASCIIStringEncoding NSNEXTSTEPStringEncoding NSJapaneseEUCStringEncoding NSUTF8StringEncoding NSISOLatin1StringEncoding NSSymbolStringEncoding NSNonLossyASCIIStringEncoding NSShiftJISStringEncoding NSISOLatin2StringEncoding NSUnicodeStringEncoding NSWindowsCP1251StringEncoding NSWindowsCP1252StringEncoding NSWindowsCP1253StringEncoding NSWindowsCP1254StringEncoding NSWindowsCP1250StringEncoding NSISO2022JPStringEncoding NSMacOSRomanStringEncoding NSUTF16StringEncoding NSUTF16BigEndianStringEncoding NSUTF16LittleEndianStringEncoding NSUTF32StringEncoding NSUTF32BigEndianStringEncoding NSUTF32LittleEndianStringEncoding +syn keyword objcEnum NSStringEncodingConversionOptions +syn keyword objcEnumValue NSStringEncodingConversionAllowLossy NSStringEncodingConversionExternalRepresentation +syn keyword objcEnum NSStringEnumerationOptions +syn keyword objcEnumValue NSStringEnumerationByLines NSStringEnumerationByParagraphs NSStringEnumerationByComposedCharacterSequences NSStringEnumerationByWords NSStringEnumerationBySentences NSStringEnumerationReverse NSStringEnumerationSubstringNotRequired NSStringEnumerationLocalized +syn keyword objcConstVar NSStringTransformLatinToKatakana NSStringTransformLatinToHiragana NSStringTransformLatinToHangul NSStringTransformLatinToArabic NSStringTransformLatinToHebrew NSStringTransformLatinToThai NSStringTransformLatinToCyrillic NSStringTransformLatinToGreek NSStringTransformToLatin NSStringTransformMandarinToLatin NSStringTransformHiraganaToKatakana NSStringTransformFullwidthToHalfwidth NSStringTransformToXMLHex NSStringTransformToUnicodeName NSStringTransformStripCombiningMarks NSStringTransformStripDiacritics +syn keyword objcConstVar NSStringEncodingDetectionSuggestedEncodingsKey NSStringEncodingDetectionDisallowedEncodingsKey NSStringEncodingDetectionUseOnlySuggestedEncodingsKey NSStringEncodingDetectionAllowLossyKey NSStringEncodingDetectionFromWindowsKey NSStringEncodingDetectionLossySubstitutionKey NSStringEncodingDetectionLikelyLanguageKey +" NSAttributedString.h +syn match objcClass /NSAttributedString\s*\*/me=s+18,he=s+18 +syn match objcClass /NSMutableAttributedString\s*\*/me=s+25,he=s+25 +syn keyword objcEnum NSAttributedStringEnumerationOptions +syn keyword objcEnumValue NSAttributedStringEnumerationReverse NSAttributedStringEnumerationLongestEffectiveRangeNotRequired +" NSValue.h +syn match objcClass /NSValue\s*\*/me=s+7,he=s+7 +syn match objcClass /NSNumber\s*\*/me=s+8,he=s+8 +" NSDecimalNumber.h +syn match objcClass /NSDecimalNumber\s*\*/me=s+15,he=s+15 +syn match objcClass /NSDecimalNumberHandler\s*\*/me=s+22,he=s+22 +syn keyword objcExceptionValue NSDecimalNumberExactnessException NSDecimalNumberOverflowException NSDecimalNumberUnderflowException NSDecimalNumberDivideByZeroException +" NSData.h +syn match objcClass /NSData\s*\*/me=s+6,he=s+6 +syn match objcClass /NSMutableData\s*\*/me=s+13,he=s+13 +syn keyword objcEnum NSDataReadingOptions +syn keyword objcEnumValue NSDataReadingMappedIfSafe NSDataReadingUncached NSDataReadingMappedAlways NSDataReadingMapped NSMappedRead NSUncachedRead +syn keyword objcEnum NSDataWritingOptions +syn keyword objcEnumValue NSDataWritingAtomic NSDataWritingWithoutOverwriting NSDataWritingFileProtectionNone NSDataWritingFileProtectionComplete NSDataWritingFileProtectionCompleteUnlessOpen NSDataWritingFileProtectionCompleteUntilFirstUserAuthentication NSDataWritingFileProtectionMask NSAtomicWrite +syn keyword objcEnum NSDataSearchOptions +syn keyword objcEnumValue NSDataSearchBackwards NSDataSearchAnchored +syn keyword objcEnum NSDataBase64EncodingOptions NSDataBase64DecodingOptions +syn keyword objcEnumValue NSDataBase64Encoding64CharacterLineLength NSDataBase64Encoding76CharacterLineLength NSDataBase64EncodingEndLineWithCarriageReturn NSDataBase64EncodingEndLineWithLineFeed NSDataBase64DecodingIgnoreUnknownCharacters +" NSArray.h +syn match objcClass /NSArray\s*\*/me=s+7,he=s+7 +syn match objcClass /NSArray<.*>\s*\*/me=s+7,he=s+7 contains=objcTypeInfoParams +syn match objcClass /NSMutableArray\s*\*/me=s+14,he=s+14 +syn match objcClass /NSMutableArray<.*>\s*\*/me=s+14,he=s+14 contains=objcTypeInfoParams +syn keyword objcEnum NSBinarySearchingOptions +syn keyword objcEnumValue NSBinarySearchingFirstEqual NSBinarySearchingLastEqual NSBinarySearchingInsertionIndex +" NSDictionary.h +syn match objcClass /NSDictionary\s*\*/me=s+12,he=s+12 +syn match objcClass /NSDictionary<.*>\s*\*/me=s+12,he=s+12 contains=objcTypeInfoParams +syn match objcClass /NSMutableDictionary\s*\*/me=s+19,he=s+19 +syn match objcClass /NSMutableDictionary<.*>\s*\*/me=s+19,he=s+19 contains=objcTypeInfoParams +" NSSet.h +syn match objcClass /NSSet\s*\*/me=s+5,me=s+5 +syn match objcClass /NSSet<.*>\s*\*/me=s+5,me=s+5 contains=objcTypeInfoParams +syn match objcClass /NSMutableSet\s*\*/me=s+12,me=s+12 +syn match objcClass /NSMutableSet<.*>\s*\*/me=s+12,me=s+12 contains=objcTypeInfoParams +syn match objcClass /NSCountedSet\s*\*/me=s+12,me=s+12 +syn match objcClass /NSCountedSet<.*>\s*\*/me=s+12,me=s+12 contains=objcTypeInfoParams +" NSOrderedSet.h +syn match objcClass /NSOrderedSet\s*\*/me=s+12,me=s+12 +syn match objcClass /NSOrderedSet<.*>\s*\*/me=s+12,me=s+12 contains=objcTypeInfoParams +syn match objcClass /NSMutableOrderedSet\s*\*/me=s+19,me=s+19 +syn match objcClass /NSMutableOrderedSet<.*>\s*\*/me=s+19,me=s+19 +""""""""""""""""""" +" NSPathUtilities.h +syn keyword objcEnum NSSearchPathDirectory +syn keyword objcEnumValue NSApplicationDirectory NSDemoApplicationDirectory NSDeveloperApplicationDirectory NSAdminApplicationDirectory NSLibraryDirectory NSDeveloperDirectory NSUserDirectory NSDocumentationDirectory NSDocumentDirectory NSCoreServiceDirectory NSAutosavedInformationDirectory NSDesktopDirectory NSCachesDirectory NSApplicationSupportDirectory NSDownloadsDirectory NSInputMethodsDirectory NSMoviesDirectory NSMusicDirectory NSPicturesDirectory NSPrinterDescriptionDirectory NSSharedPublicDirectory NSPreferencePanesDirectory NSApplicationScriptsDirectory NSItemReplacementDirectory NSAllApplicationsDirectory NSAllLibrariesDirectory NSTrashDirectory +syn keyword objcEnum NSSearchPathDomainMask +syn keyword objcEnumValue NSUserDomainMask NSLocalDomainMask NSNetworkDomainMask NSSystemDomainMask NSAllDomainsMask +" NSFileManger.h +syn match objcClass /NSFileManager\s*\*/me=s+13,he=s+13 +syn match objcClass /NSDirectoryEnumerator\s*\*/me=s+21,he=s+21 contains=objcTypeInfoParams +syn match objcClass /NSDirectoryEnumerator<.*>\s*\*/me=s+21,he=s+21 +syn keyword objcEnum NSVolumeEnumerationOptions +syn keyword objcEnumValue NSVolumeEnumerationSkipHiddenVolumes NSVolumeEnumerationProduceFileReferenceURLs +syn keyword objcEnum NSURLRelationship +syn keyword objcEnumValue NSURLRelationshipContains NSURLRelationshipSame NSURLRelationshipOther +syn keyword objcEnum NSFileManagerUnmountOptions +syn keyword objcEnumValue NSFileManagerUnmountAllPartitionsAndEjectDisk NSFileManagerUnmountWithoutUI +syn keyword objcConstVar NSFileManagerUnmountDissentingProcessIdentifierErrorKey +syn keyword objcEnum NSDirectoryEnumerationOptions +syn keyword objcEnumValue NSDirectoryEnumerationSkipsSubdirectoryDescendants NSDirectoryEnumerationSkipsPackageDescendants NSDirectoryEnumerationSkipsHiddenFiles +syn keyword objcEnum NSFileManagerItemReplacementOptions +syn keyword objcEnumValue NSFileManagerItemReplacementUsingNewMetadataOnly NSFileManagerItemReplacementWithoutDeletingBackupItem +syn keyword objcNotificationValue NSUbiquityIdentityDidChangeNotification +syn keyword objcConstVar NSFileType NSFileTypeDirectory NSFileTypeRegular NSFileTypeSymbolicLink NSFileTypeSocket NSFileTypeCharacterSpecial NSFileTypeBlockSpecial NSFileTypeUnknown NSFileSize NSFileModificationDate NSFileReferenceCount NSFileDeviceIdentifier NSFileOwnerAccountName NSFileGroupOwnerAccountName NSFilePosixPermissions NSFileSystemNumber NSFileSystemFileNumber NSFileExtensionHidden NSFileHFSCreatorCode NSFileHFSTypeCode NSFileImmutable NSFileAppendOnly NSFileCreationDate NSFileOwnerAccountID NSFileGroupOwnerAccountID NSFileBusy NSFileProtectionKey NSFileProtectionNone NSFileProtectionComplete NSFileProtectionCompleteUnlessOpen NSFileProtectionCompleteUntilFirstUserAuthentication NSFileSystemSize NSFileSystemFreeSize NSFileSystemNodes NSFileSystemFreeNodes +" NSFileHandle.h +syn match objcClass /NSFileHandle\s*\*/me=s+12,he=s+12 +syn keyword objcExceptionValue NSFileHandleOperationException +syn keyword objcNotificationValue NSFileHandleReadCompletionNotification NSFileHandleReadToEndOfFileCompletionNotification NSFileHandleConnectionAcceptedNotification NSFileHandleDataAvailableNotification NSFileHandleNotificationDataItem NSFileHandleNotificationFileHandleItem NSFileHandleNotificationMonitorModes +syn match objcClass /NSPipe\s*\*/me=s+6,he=s+6 +"""""""""""" +" NSLocale.h +syn match objcClass /NSLocale\s*\*/me=s+8,he=s+8 +syn keyword objcEnum NSLocaleLanguageDirection +syn keyword objcEnumValue NSLocaleLanguageDirectionUnknown NSLocaleLanguageDirectionLeftToRight NSLocaleLanguageDirectionRightToLeft NSLocaleLanguageDirectionTopToBottom NSLocaleLanguageDirectionBottomToTop +syn keyword objcNotificationValue NSCurrentLocaleDidChangeNotification +syn keyword objcConstVar NSLocaleIdentifier NSLocaleLanguageCode NSLocaleCountryCode NSLocaleScriptCode NSLocaleVariantCode NSLocaleExemplarCharacterSet NSLocaleCalendar NSLocaleCollationIdentifier NSLocaleUsesMetricSystem NSLocaleMeasurementSystem NSLocaleDecimalSeparator NSLocaleGroupingSeparator NSLocaleCurrencySymbol NSLocaleCurrencyCode NSLocaleCollatorIdentifier NSLocaleQuotationBeginDelimiterKey NSLocaleQuotationEndDelimiterKey NSLocaleAlternateQuotationBeginDelimiterKey NSLocaleAlternateQuotationEndDelimiterKey NSGregorianCalendar NSBuddhistCalendar NSChineseCalendar NSHebrewCalendar NSIslamicCalendar NSIslamicCivilCalendar NSJapaneseCalendar NSRepublicOfChinaCalendar NSPersianCalendar NSIndianCalendar NSISO8601Calendar +" NSFormatter.h +syn match objcClass /NSFormatter\s*\*/me=s+11,he=s+11 +syn keyword objcEnum NSFormattingContext NSFormattingUnitStyle +syn keyword objcEnumValue NSFormattingContextUnknown NSFormattingContextDynamic NSFormattingContextStandalone NSFormattingContextListItem NSFormattingContextBeginningOfSentence NSFormattingContextMiddleOfSentence NSFormattingUnitStyleShort NSFormattingUnitStyleMedium NSFormattingUnitStyleLong +" NSNumberFormatter.h +syn match objcClass /NSNumberFormatter\s*\*/me=s+17,he=s+17 +syn keyword objcEnum NSNumberFormatterStyle +syn keyword objcEnumValue NSNumberFormatterNoStyle NSNumberFormatterDecimalStyle NSNumberFormatterCurrencyStyle NSNumberFormatterPercentStyle NSNumberFormatterScientificStyle NSNumberFormatterSpellOutStyle NSNumberFormatterOrdinalStyle NSNumberFormatterCurrencyISOCodeStyle NSNumberFormatterCurrencyPluralStyle NSNumberFormatterCurrencyAccountingStyle +syn keyword objcEnum NSNumberFormatterBehavior +syn keyword objcEnumValue NSNumberFormatterBehaviorDefault NSNumberFormatterBehavior10_0 NSNumberFormatterBehavior10_4 +syn keyword objcEnum NSNumberFormatterPadPosition +syn keyword objcEnumValue NSNumberFormatterPadBeforePrefix NSNumberFormatterPadAfterPrefix NSNumberFormatterPadBeforeSuffix NSNumberFormatterPadAfterSuffix +syn keyword objcEnum NSNumberFormatterRoundingMode +syn keyword objcEnumValue NSNumberFormatterRoundCeiling NSNumberFormatterRoundFloor NSNumberFormatterRoundDown NSNumberFormatterRoundUp NSNumberFormatterRoundHalfEven NSNumberFormatterRoundHalfDown NSNumberFormatterRoundHalfUp +" NSDateFormatter.h +syn match objcClass /NSDateFormatter\s*\*/me=s+15,he=s+15 +syn keyword objcEnum NSDateFormatterStyle +syn keyword objcEnumValue NSDateFormatterNoStyle NSDateFormatterShortStyle NSDateFormatterMediumStyle NSDateFormatterLongStyle NSDateFormatterFullStyle +syn keyword objcEnum NSDateFormatterBehavior +syn keyword objcEnumValue NSDateFormatterBehaviorDefault NSDateFormatterBehavior10_0 NSDateFormatterBehavior10_4 +" NSCalendar.h +syn match objcClass /NSCalendar\s*\*/me=s+10,he=s+10 +syn keyword objcConstVar NSCalendarIdentifierGregorian NSCalendarIdentifierBuddhist NSCalendarIdentifierChinese NSCalendarIdentifierCoptic NSCalendarIdentifierEthiopicAmeteMihret NSCalendarIdentifierEthiopicAmeteAlem NSCalendarIdentifierHebrew NSCalendarIdentifierISO8601 NSCalendarIdentifierIndian NSCalendarIdentifierIslamic NSCalendarIdentifierIslamicCivil NSCalendarIdentifierJapanese NSCalendarIdentifierPersian NSCalendarIdentifierRepublicOfChina NSCalendarIdentifierIslamicTabular NSCalendarIdentifierIslamicUmmAlQura +syn keyword objcEnum NSCalendarUnit +syn keyword objcEnumValue NSCalendarUnitEra NSCalendarUnitYear NSCalendarUnitMonth NSCalendarUnitDay NSCalendarUnitHour NSCalendarUnitMinute NSCalendarUnitSecond NSCalendarUnitWeekday NSCalendarUnitWeekdayOrdinal NSCalendarUnitQuarter NSCalendarUnitWeekOfMonth NSCalendarUnitWeekOfYear NSCalendarUnitYearForWeekOfYear NSCalendarUnitNanosecond NSCalendarUnitCalendar NSCalendarUnitTimeZone +syn keyword objcEnumValue NSEraCalendarUnit NSYearCalendarUnit NSMonthCalendarUnit NSDayCalendarUnit NSHourCalendarUnit NSMinuteCalendarUnit NSSecondCalendarUnit NSWeekCalendarUnit NSWeekdayCalendarUnit NSWeekdayOrdinalCalendarUnit NSQuarterCalendarUnit NSWeekOfMonthCalendarUnit NSWeekOfYearCalendarUnit NSYearForWeekOfYearCalendarUnit NSCalendarCalendarUnit NSTimeZoneCalendarUnit +syn keyword objcEnumValue NSWrapCalendarComponents NSUndefinedDateComponent NSDateComponentUndefined +syn match objcClass /NSDateComponents\s*\*/me=s+16,he=s+16 +syn keyword objcEnum NSCalendarOptions +syn keyword objcEnumValue NSCalendarWrapComponents NSCalendarMatchStrictly NSCalendarSearchBackwards NSCalendarMatchPreviousTimePreservingSmallerUnits NSCalendarMatchNextTimePreservingSmallerUnits NSCalendarMatchNextTime NSCalendarMatchFirst NSCalendarMatchLast +syn keyword objcConstVar NSCalendarDayChangedNotification +" NSTimeZone.h +syn match objcClass /NSTimeZone\s*\*/me=s+10,he=s+10 +syn keyword objcEnum NSTimeZoneNameStyle +syn keyword objcEnumValue NSTimeZoneNameStyleStandard NSTimeZoneNameStyleShortStandard NSTimeZoneNameStyleDaylightSaving NSTimeZoneNameStyleShortDaylightSaving NSTimeZoneNameStyleGeneric NSTimeZoneNameStyleShortGeneric +syn keyword objcNotificationValue NSSystemTimeZoneDidChangeNotification +""""""""""" +" NSCoder.h +syn match objcClass /NSCoder\s*\*/me=s+7,he=s+7 +" NSArchiver.h +syn match objcClass /NSArchiver\s*\*/me=s+10,he=s+10 +syn match objcClass /NSUnarchiver\s*\*/me=s+12,he=s+12 +syn keyword objcExceptionValue NSInconsistentArchiveException +" NSKeyedArchiver.h +syn match objcClass /NSKeyedArchiver\s*\*/me=s+15,he=s+15 +syn match objcClass /NSKeyedUnarchiver\s*\*/me=s+17,he=s+17 +syn keyword objcExceptionValue NSInvalidArchiveOperationException NSInvalidUnarchiveOperationException +syn keyword objcConstVar NSKeyedArchiveRootObjectKey +"""""""""""""""""" +" NSPropertyList.h +syn keyword objcEnum NSPropertyListMutabilityOptions +syn keyword objcEnumValue NSPropertyListImmutable NSPropertyListMutableContainers NSPropertyListMutableContainersAndLeaves +syn keyword objcEnum NSPropertyListFormat +syn keyword objcEnumValue NSPropertyListOpenStepFormat NSPropertyListXMLFormat_v1_0 NSPropertyListBinaryFormat_v1_0 +syn keyword objcType NSPropertyListReadOptions NSPropertyListWriteOptions +" NSUserDefaults.h +syn match objcClass /NSUserDefaults\s*\*/me=s+14,he=s+14 +syn keyword objcConstVar NSGlobalDomain NSArgumentDomain NSRegistrationDomain +syn keyword objcNotificationValue NSUserDefaultsDidChangeNotification +" NSBundle.h +syn match objcClass /NSBundle\s*\*/me=s+8,he=s+8 +syn keyword objcEnumValue NSBundleExecutableArchitectureI386 NSBundleExecutableArchitecturePPC NSBundleExecutableArchitectureX86_64 NSBundleExecutableArchitecturePPC64 +syn keyword objcNotificationValue NSBundleDidLoadNotification NSLoadedClasses NSBundleResourceRequestLowDiskSpaceNotification +syn keyword objcConstVar NSBundleResourceRequestLoadingPriorityUrgent +""""""""""""""""" +" NSProcessInfo.h +syn match objcClass /NSProcessInfo\s*\*/me=s+13,he=s+13 +syn keyword objcEnumValue NSWindowsNTOperatingSystem NSWindows95OperatingSystem NSSolarisOperatingSystem NSHPUXOperatingSystem NSMACHOperatingSystem NSSunOSOperatingSystem NSOSF1OperatingSystem +syn keyword objcType NSOperatingSystemVersion +syn keyword objcEnum NSActivityOptions NSProcessInfoThermalState +syn keyword objcEnumValue NSActivityIdleDisplaySleepDisabled NSActivityIdleSystemSleepDisabled NSActivitySuddenTerminationDisabled NSActivityAutomaticTerminationDisabled NSActivityUserInitiated NSActivityUserInitiatedAllowingIdleSystemSleep NSActivityBackground NSActivityLatencyCritical NSProcessInfoThermalStateNominal NSProcessInfoThermalStateFair NSProcessInfoThermalStateSerious NSProcessInfoThermalStateCritical +syn keyword objcNotificationValue NSProcessInfoThermalStateDidChangeNotification NSProcessInfoPowerStateDidChangeNotification +" NSTask.h +syn match objcClass /NSTask\s*\*/me=s+6,he=s+6 +syn keyword objcEnum NSTaskTerminationReason +syn keyword objcEnumValue NSTaskTerminationReasonExit NSTaskTerminationReasonUncaughtSignal +syn keyword objcNotificationValue NSTaskDidTerminateNotification +" NSThread.h +syn match objcClass /NSThread\s*\*/me=s+8,he=s+8 +syn keyword objcNotificationValue NSWillBecomeMultiThreadedNotification NSDidBecomeSingleThreadedNotification NSThreadWillExitNotification +" NSLock.h +syn match objcClass /NSLock\s*\*/me=s+6,he=s+6 +syn match objcClass /NSConditionLock\s*\*/me=s+15,he=s+15 +syn match objcClass /NSRecursiveLock\s*\*/me=s+15,he=s+15 +" NSDictributedLock +syn match objcClass /NSDistributedLock\s*\*/me=s+17,he=s+17 +" NSOperation.h +"""""""""""""""" +syn match objcClass /NSOperation\s*\*/me=s+11,he=s+11 +syn keyword objcEnum NSOperationQueuePriority +syn keyword objcEnumValue NSOperationQueuePriorityVeryLow NSOperationQueuePriorityLow NSOperationQueuePriorityNormal NSOperationQueuePriorityHigh NSOperationQueuePriorityVeryHigh +syn match objcClass /NSBlockOperation\s*\*/me=s+16,he=s+16 +syn match objcClass /NSInvocationOperation\s*\*/me=s+21,he=s+21 +syn keyword objcExceptionValue NSInvocationOperationVoidResultException NSInvocationOperationCancelledException +syn match objcClass /NSOperationQueue\s*\*/me=s+16,he=s+16 +syn keyword objcEnumValue NSOperationQueueDefaultMaxConcurrentOperationCount +" NSConnection.h +syn match objcClass /NSConnection\s*\*/me=s+12,he=s+12 +syn keyword objcConstVar NSConnectionReplyMode +syn keyword objcNotificationValue NSConnectionDidDieNotification NSConnectionDidInitializeNotification +syn keyword objcExceptionValue NSFailedAuthenticationException +" NSPort.h +syn match objcClass /NSPort\s*\*/me=s+6,he=s+6 +syn keyword objcType NSSocketNativeHandle +syn keyword objcNotificationValue NSPortDidBecomeInvalidNotification +syn match objcClass /NSMachPort\s*\*/me=s+10,he=s+10 +syn keyword objcEnum NSMachPortOptions +syn keyword objcEnumValue NSMachPortDeallocateNone NSMachPortDeallocateSendRight NSMachPortDeallocateReceiveRight +syn match objcClass /NSMessagePort\s*\*/me=s+13,he=s+13 +syn match objcClass /NSSocketPort\s*\*/me=s+12,he=s+12 +" NSPortMessage.h +syn match objcClass /NSPortMessage\s*\*/me=s+13,he=s+13 +" NSDistantObject.h +syn match objcClass /NSDistantObject\s*\*/me=s+15,he=s+15 +" NSPortNameServer.h +syn match objcClass /NSPortNameServer\s*\*/me=s+16,he=s+16 +syn match objcClass /NSMessagePortNameServer\s*\*/me=s+23,he=s+23 +syn match objcClass /NSSocketPortNameServer\s*\*/me=s+22,he=s+22 +" NSHost.h +syn match objcClass /NSHost\s*\*/me=s+6,he=s+6 +" NSInvocation.h +syn match objcClass /NSInvocation\s*\*/me=s+12,he=s+12 +" NSMethodSignature.h +syn match objcClass /NSMethodSignature\s*\*/me=s+17,he=s+17 +""""" +" NSScanner.h +syn match objcClass /NSScanner\s*\*/me=s+9,he=s+9 +" NSTimer.h +syn match objcClass /NSTimer\s*\*/me=s+7,he=s+7 +" NSAutoreleasePool.h +syn match objcClass /NSAutoreleasePool\s*\*/me=s+17,he=s+17 +" NSRunLoop.h +syn match objcClass /NSRunLoop\s*\*/me=s+9,he=s+9 +syn keyword objcConstVar NSDefaultRunLoopMode NSRunLoopCommonModes +" NSNull.h +syn match objcClass /NSNull\s*\*/me=s+6,he=s+6 +" NSProxy.h +syn match objcClass /NSProxy\s*\*/me=s+7,he=s+7 +" NSObject.h +syn match objcClass /NSObject\s*\*/me=s+8,he=s+8 + + +" NSCache.h +syn match objcClass /NSCache\s*\*/me=s+7,he=s+7 +syn match objcClass /NSCache<.*>\s*\*/me=s+7,he=s+7 contains=objcTypeInfoParams +" NSHashTable.h +syn match objcClass /NSHashTable\s*\*/me=s+11,he=s+11 +syn match objcClass /NSHashTable<.*>\s*\*/me=s+11,he=s+11 contains=objcTypeInfoParams +syn keyword objcConstVar NSHashTableStrongMemory NSHashTableZeroingWeakMemory NSHashTableCopyIn NSHashTableObjectPointerPersonality NSHashTableWeakMemory +syn keyword objcType NSHashTableOptions NSHashEnumerator NSHashTableCallBacks +syn keyword objcConstVar NSIntegerHashCallBacks NSNonOwnedPointerHashCallBacks NSNonRetainedObjectHashCallBacks NSObjectHashCallBacks NSOwnedObjectIdentityHashCallBacks NSOwnedPointerHashCallBacks NSPointerToStructHashCallBacks NSOwnedObjectIdentityHashCallBacks NSOwnedObjectIdentityHashCallBacks NSIntHashCallBacks +" NSMapTable.h +syn match objcClass /NSMapTable\s*\*/me=s+10,he=s+10 +syn match objcClass /NSMapTable<.*>\s*\*/me=s+10,he=s+10 contains=objcTypeInfoParams +syn keyword objcConstVar NSPointerToStructHashCallBacks NSPointerToStructHashCallBacks NSPointerToStructHashCallBacks NSPointerToStructHashCallBacks NSPointerToStructHashCallBacks +syn keyword objcConstVar NSMapTableStrongMemory NSMapTableZeroingWeakMemory NSMapTableCopyIn NSMapTableObjectPointerPersonality NSMapTableWeakMemory +syn keyword objcType NSMapTableOptions NSMapEnumerator NSMapTableKeyCallBacks NSMapTableValueCallBacks +syn keyword objcMacro NSNotAnIntMapKey NSNotAnIntegerMapKey NSNotAPointerMapKey +syn keyword objcConstVar NSIntegerMapKeyCallBacks NSNonOwnedPointerMapKeyCallBacks NSNonOwnedPointerOrNullMapKeyCallBacks NSNonRetainedObjectMapKeyCallBacks NSObjectMapKeyCallBacks NSOwnedPointerMapKeyCallBacks NSIntMapKeyCallBacks NSIntegerMapValueCallBacks NSNonOwnedPointerMapValueCallBacks NSObjectMapValueCallBacks NSNonRetainedObjectMapValueCallBacks NSOwnedPointerMapValueCallBacks NSIntMapValueCallBacks + +" NSPointerFunctions.h +syn match objcClass /NSPointerFunctions\s*\*/me=s+18,he=s+18 +syn keyword objcEnum NSPointerFunctionsOptions +syn keyword objcEnumValue NSPointerFunctionsStrongMemory NSPointerFunctionsZeroingWeakMemory NSPointerFunctionsOpaqueMemory NSPointerFunctionsMallocMemory NSPointerFunctionsMachVirtualMemory NSPointerFunctionsWeakMemory NSPointerFunctionsObjectPersonality NSPointerFunctionsOpaquePersonality NSPointerFunctionsObjectPointerPersonality NSPointerFunctionsCStringPersonality NSPointerFunctionsStructPersonality NSPointerFunctionsIntegerPersonality NSPointerFunctionsCopyIn + + +""" Default Highlighting +hi def link objcPreProcMacro cConstant +hi def link objcPrincipalType cType +hi def link objcUsefulTerm cConstant +hi def link objcImport cInclude +hi def link objcImported cString +hi def link objcObjDef cOperator +hi def link objcProtocol cOperator +hi def link objcProperty cOperator +hi def link objcIvarScope cOperator +hi def link objcInternalRep cOperator +hi def link objcException cOperator +hi def link objcThread cOperator +hi def link objcPool cOperator +hi def link objcModuleImport cOperator +hi def link objcSpecial cSpecial +hi def link objcString cString +hi def link objcHiddenArgument cStatement +hi def link objcBlocksQualifier cStorageClass +hi def link objcObjectLifetimeQualifier cStorageClass +hi def link objcTollFreeBridgeQualifier cStorageClass +hi def link objcRemoteMessagingQualifier cStorageClass +hi def link objcStorageClass cStorageClass +hi def link objcFastEnumKeyword cStatement +hi def link objcLiteralSyntaxNumber cNumber +hi def link objcLiteralSyntaxChar cCharacter +hi def link objcLiteralSyntaxSpecialChar cCharacter +hi def link objcLiteralSyntaxOp cOperator +hi def link objcDeclPropAccessorName cConstant +hi def link objcDeclPropAccessorType cConstant +hi def link objcDeclPropAssignSemantics cConstant +hi def link objcDeclPropAtomicity cConstant +hi def link objcDeclPropARC cConstant +hi def link objcDeclPropNullable cConstant +hi def link objcDeclPropNonnull cConstant +hi def link objcDeclPropNullUnspecified cConstant +hi def link objcDeclProcNullResettable cConstant +hi def link objcInstanceMethod Function +hi def link objcClassMethod Function +hi def link objcType cType +hi def link objcClass cType +hi def link objcTypeSpecifier cType +hi def link objcMacro cConstant +hi def link objcEnum cType +hi def link objcEnumValue cConstant +hi def link objcExceptionValue cConstant +hi def link objcNotificationValue cConstant +hi def link objcConstVar cConstant +hi def link objcTypeInfoParams Identifier + +""" Final step +let b:current_syntax = "objc" +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 sw=2 sts=2 + +endif diff --git a/syntax/objcpp.vim b/syntax/objcpp.vim new file mode 100644 index 0000000..99a9555 --- /dev/null +++ b/syntax/objcpp.vim @@ -0,0 +1,24 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Objective C++ +" Maintainer: Kazunobu Kuriyama +" Ex-Maintainer: Anthony Hodsdon +" Last Change: 2007 Oct 29 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read in C++ and ObjC syntax files +runtime! syntax/cpp.vim +unlet b:current_syntax +runtime! syntax/objc.vim + +syn keyword objCppNonStructure class template namespace transparent contained +syn keyword objCppNonStatement new delete friend using transparent contained + +let b:current_syntax = "objcpp" + +endif diff --git a/syntax/ocaml.vim b/syntax/ocaml.vim index a337f54..c5469cc 100644 --- a/syntax/ocaml.vim +++ b/syntax/ocaml.vim @@ -1,3 +1,325 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: OCaml +" Filenames: *.ml *.mli *.mll *.mly +" Maintainers: Markus Mottl +" Karl-Heinz Sylla +" Issac Trotts +" URL: http://www.ocaml.info/vim/syntax/ocaml.vim +" Last Change: 2012 May 12 - Added Dominique Pellé's spell checking patch (MM) +" 2012 Feb 01 - Improved module path highlighting (MM) +" 2010 Oct 11 - Added highlighting of lnot (MM, thanks to Erick Matsen) + +" A minor patch was applied to the official version so that object/end +" can be distinguished from begin/end, which is used for indentation, +" and folding. (David Baelde) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") && b:current_syntax == "ocaml" + finish +endif + +" OCaml is case sensitive. +syn case match + +" Access to the method of an object +syn match ocamlMethod "#" + +" Script headers highlighted like comments +syn match ocamlComment "^#!.*" contains=@Spell + +" Scripting directives +syn match ocamlScript "^#\<\(quit\|labels\|warnings\|directory\|cd\|load\|use\|install_printer\|remove_printer\|require\|thread\|trace\|untrace\|untrace_all\|print_depth\|print_length\|camlp4o\)\>" + +" lowercase identifier - the standard way to match +syn match ocamlLCIdentifier /\<\(\l\|_\)\(\w\|'\)*\>/ + +syn match ocamlKeyChar "|" + +" Errors +syn match ocamlBraceErr "}" +syn match ocamlBrackErr "\]" +syn match ocamlParenErr ")" +syn match ocamlArrErr "|]" + +syn match ocamlCommentErr "\*)" + +syn match ocamlCountErr "\" +syn match ocamlCountErr "\" + +if !exists("ocaml_revised") + syn match ocamlDoErr "\" +endif + +syn match ocamlDoneErr "\" +syn match ocamlThenErr "\" + +" Error-highlighting of "end" without synchronization: +" as keyword or as error (default) +if exists("ocaml_noend_error") + syn match ocamlKeyword "\" +else + syn match ocamlEndErr "\" +endif + +" Some convenient clusters +syn cluster ocamlAllErrs contains=ocamlBraceErr,ocamlBrackErr,ocamlParenErr,ocamlCommentErr,ocamlCountErr,ocamlDoErr,ocamlDoneErr,ocamlEndErr,ocamlThenErr + +syn cluster ocamlAENoParen contains=ocamlBraceErr,ocamlBrackErr,ocamlCommentErr,ocamlCountErr,ocamlDoErr,ocamlDoneErr,ocamlEndErr,ocamlThenErr + +syn cluster ocamlContained contains=ocamlTodo,ocamlPreDef,ocamlModParam,ocamlModParam1,ocamlPreMPRestr,ocamlMPRestr,ocamlMPRestr1,ocamlMPRestr2,ocamlMPRestr3,ocamlModRHS,ocamlFuncWith,ocamlFuncStruct,ocamlModTypeRestr,ocamlModTRWith,ocamlWith,ocamlWithRest,ocamlModType,ocamlFullMod,ocamlVal + + +" Enclosing delimiters +syn region ocamlEncl transparent matchgroup=ocamlKeyword start="(" matchgroup=ocamlKeyword end=")" contains=ALLBUT,@ocamlContained,ocamlParenErr +syn region ocamlEncl transparent matchgroup=ocamlKeyword start="{" matchgroup=ocamlKeyword end="}" contains=ALLBUT,@ocamlContained,ocamlBraceErr +syn region ocamlEncl transparent matchgroup=ocamlKeyword start="\[" matchgroup=ocamlKeyword end="\]" contains=ALLBUT,@ocamlContained,ocamlBrackErr +syn region ocamlEncl transparent matchgroup=ocamlKeyword start="\[|" matchgroup=ocamlKeyword end="|\]" contains=ALLBUT,@ocamlContained,ocamlArrErr + + +" Comments +syn region ocamlComment start="(\*" end="\*)" contains=@Spell,ocamlComment,ocamlTodo +syn keyword ocamlTodo contained TODO FIXME XXX NOTE + + +" Objects +syn region ocamlEnd matchgroup=ocamlObject start="\" matchgroup=ocamlObject end="\" contains=ALLBUT,@ocamlContained,ocamlEndErr + + +" Blocks +if !exists("ocaml_revised") + syn region ocamlEnd matchgroup=ocamlKeyword start="\" matchgroup=ocamlKeyword end="\" contains=ALLBUT,@ocamlContained,ocamlEndErr +endif + + +" "for" +syn region ocamlNone matchgroup=ocamlKeyword start="\" matchgroup=ocamlKeyword end="\<\(to\|downto\)\>" contains=ALLBUT,@ocamlContained,ocamlCountErr + + +" "do" +if !exists("ocaml_revised") + syn region ocamlDo matchgroup=ocamlKeyword start="\" matchgroup=ocamlKeyword end="\" contains=ALLBUT,@ocamlContained,ocamlDoneErr +endif + +" "if" +syn region ocamlNone matchgroup=ocamlKeyword start="\" matchgroup=ocamlKeyword end="\" contains=ALLBUT,@ocamlContained,ocamlThenErr + + +"" Modules + +" "sig" +syn region ocamlSig matchgroup=ocamlModule start="\" matchgroup=ocamlModule end="\" contains=ALLBUT,@ocamlContained,ocamlEndErr,ocamlModule +syn region ocamlModSpec matchgroup=ocamlKeyword start="\" matchgroup=ocamlModule end="\<\u\(\w\|'\)*\>" contained contains=@ocamlAllErrs,ocamlComment skipwhite skipempty nextgroup=ocamlModTRWith,ocamlMPRestr + +" "open" +syn region ocamlNone matchgroup=ocamlKeyword start="\" matchgroup=ocamlModule end="\<\u\(\w\|'\)*\( *\. *\u\(\w\|'\)*\)*\>" contains=@ocamlAllErrs,ocamlComment + +" "include" +syn match ocamlKeyword "\" skipwhite skipempty nextgroup=ocamlModParam,ocamlFullMod + +" "module" - somewhat complicated stuff ;-) +syn region ocamlModule matchgroup=ocamlKeyword start="\" matchgroup=ocamlModule end="\<\u\(\w\|'\)*\>" contains=@ocamlAllErrs,ocamlComment skipwhite skipempty nextgroup=ocamlPreDef +syn region ocamlPreDef start="."me=e-1 matchgroup=ocamlKeyword end="\l\|=\|)"me=e-1 contained contains=@ocamlAllErrs,ocamlComment,ocamlModParam,ocamlModTypeRestr,ocamlModTRWith nextgroup=ocamlModPreRHS +syn region ocamlModParam start="([^*]" end=")" contained contains=@ocamlAENoParen,ocamlModParam1,ocamlVal +syn match ocamlModParam1 "\<\u\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=ocamlPreMPRestr + +syn region ocamlPreMPRestr start="."me=e-1 end=")"me=e-1 contained contains=@ocamlAllErrs,ocamlComment,ocamlMPRestr,ocamlModTypeRestr + +syn region ocamlMPRestr start=":" end="."me=e-1 contained contains=@ocamlComment skipwhite skipempty nextgroup=ocamlMPRestr1,ocamlMPRestr2,ocamlMPRestr3 +syn region ocamlMPRestr1 matchgroup=ocamlModule start="\ssig\s\=" matchgroup=ocamlModule end="\" contained contains=ALLBUT,@ocamlContained,ocamlEndErr,ocamlModule +syn region ocamlMPRestr2 start="\sfunctor\(\s\|(\)\="me=e-1 matchgroup=ocamlKeyword end="->" contained contains=@ocamlAllErrs,ocamlComment,ocamlModParam skipwhite skipempty nextgroup=ocamlFuncWith,ocamlMPRestr2 +syn match ocamlMPRestr3 "\w\(\w\|'\)*\( *\. *\w\(\w\|'\)*\)*" contained +syn match ocamlModPreRHS "=" contained skipwhite skipempty nextgroup=ocamlModParam,ocamlFullMod +syn keyword ocamlKeyword val +syn region ocamlVal matchgroup=ocamlKeyword start="\" matchgroup=ocamlLCIdentifier end="\<\l\(\w\|'\)*\>" contains=@ocamlAllErrs,ocamlComment,ocamlFullMod skipwhite skipempty nextgroup=ocamlMPRestr +syn region ocamlModRHS start="." end=". *\w\|([^*]"me=e-2 contained contains=ocamlComment skipwhite skipempty nextgroup=ocamlModParam,ocamlFullMod +syn match ocamlFullMod "\<\u\(\w\|'\)*\( *\. *\u\(\w\|'\)*\)*" contained skipwhite skipempty nextgroup=ocamlFuncWith + +syn region ocamlFuncWith start="([^*]"me=e-1 end=")" contained contains=ocamlComment,ocamlWith,ocamlFuncStruct skipwhite skipempty nextgroup=ocamlFuncWith +syn region ocamlFuncStruct matchgroup=ocamlModule start="[^a-zA-Z]struct\>"hs=s+1 matchgroup=ocamlModule end="\" contains=ALLBUT,@ocamlContained,ocamlEndErr + +syn match ocamlModTypeRestr "\<\w\(\w\|'\)*\( *\. *\w\(\w\|'\)*\)*\>" contained +syn region ocamlModTRWith start=":\s*("hs=s+1 end=")" contained contains=@ocamlAENoParen,ocamlWith +syn match ocamlWith "\<\(\u\(\w\|'\)* *\. *\)*\w\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=ocamlWithRest +syn region ocamlWithRest start="[^)]" end=")"me=e-1 contained contains=ALLBUT,@ocamlContained + +" "struct" +syn region ocamlStruct matchgroup=ocamlModule start="\<\(module\s\+\)\=struct\>" matchgroup=ocamlModule end="\" contains=ALLBUT,@ocamlContained,ocamlEndErr + +" "module type" +syn region ocamlKeyword start="\\s*\\(\s*\\)\=" matchgroup=ocamlModule end="\<\w\(\w\|'\)*\>" contains=ocamlComment skipwhite skipempty nextgroup=ocamlMTDef +syn match ocamlMTDef "=\s*\w\(\w\|'\)*\>"hs=s+1,me=s+1 skipwhite skipempty nextgroup=ocamlFullMod + +syn keyword ocamlKeyword and as assert class +syn keyword ocamlKeyword constraint else +syn keyword ocamlKeyword exception external fun + +syn keyword ocamlKeyword in inherit initializer +syn keyword ocamlKeyword land lazy let match +syn keyword ocamlKeyword method mutable new of +syn keyword ocamlKeyword parser private raise rec +syn keyword ocamlKeyword try type +syn keyword ocamlKeyword virtual when while with + +if exists("ocaml_revised") + syn keyword ocamlKeyword do value + syn keyword ocamlBoolean True False +else + syn keyword ocamlKeyword function + syn keyword ocamlBoolean true false + syn match ocamlKeyChar "!" +endif + +syn keyword ocamlType array bool char exn float format format4 +syn keyword ocamlType int int32 int64 lazy_t list nativeint option +syn keyword ocamlType string unit + +syn keyword ocamlOperator asr lnot lor lsl lsr lxor mod not + +syn match ocamlConstructor "(\s*)" +syn match ocamlConstructor "\[\s*\]" +syn match ocamlConstructor "\[|\s*>|]" +syn match ocamlConstructor "\[<\s*>\]" +syn match ocamlConstructor "\u\(\w\|'\)*\>" + +" Polymorphic variants +syn match ocamlConstructor "`\w\(\w\|'\)*\>" + +" Module prefix +syn match ocamlModPath "\u\(\w\|'\)* *\."he=e-1 + +syn match ocamlCharacter "'\\\d\d\d'\|'\\[\'ntbr]'\|'.'" +syn match ocamlCharacter "'\\x\x\x'" +syn match ocamlCharErr "'\\\d\d'\|'\\\d'" +syn match ocamlCharErr "'\\[^\'ntbr]'" +syn region ocamlString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@Spell + +syn match ocamlFunDef "->" +syn match ocamlRefAssign ":=" +syn match ocamlTopStop ";;" +syn match ocamlOperator "\^" +syn match ocamlOperator "::" + +syn match ocamlOperator "&&" +syn match ocamlOperator "<" +syn match ocamlOperator ">" +syn match ocamlAnyVar "\<_\>" +syn match ocamlKeyChar "|[^\]]"me=e-1 +syn match ocamlKeyChar ";" +syn match ocamlKeyChar "\~" +syn match ocamlKeyChar "?" +syn match ocamlKeyChar "\*" +syn match ocamlKeyChar "=" + +if exists("ocaml_revised") + syn match ocamlErr "<-" +else + syn match ocamlOperator "<-" +endif + +syn match ocamlNumber "\<-\=\d\(_\|\d\)*[l|L|n]\?\>" +syn match ocamlNumber "\<-\=0[x|X]\(\x\|_\)\+[l|L|n]\?\>" +syn match ocamlNumber "\<-\=0[o|O]\(\o\|_\)\+[l|L|n]\?\>" +syn match ocamlNumber "\<-\=0[b|B]\([01]\|_\)\+[l|L|n]\?\>" +syn match ocamlFloat "\<-\=\d\(_\|\d\)*\.\?\(_\|\d\)*\([eE][-+]\=\d\(_\|\d\)*\)\=\>" + +" Labels +syn match ocamlLabel "\~\(\l\|_\)\(\w\|'\)*"lc=1 +syn match ocamlLabel "?\(\l\|_\)\(\w\|'\)*"lc=1 +syn region ocamlLabel transparent matchgroup=ocamlLabel start="?(\(\l\|_\)\(\w\|'\)*"lc=2 end=")"me=e-1 contains=ALLBUT,@ocamlContained,ocamlParenErr + + +" Synchronization +syn sync minlines=50 +syn sync maxlines=500 + +if !exists("ocaml_revised") + syn sync match ocamlDoSync grouphere ocamlDo "\" + syn sync match ocamlDoSync groupthere ocamlDo "\" +endif + +if exists("ocaml_revised") + syn sync match ocamlEndSync grouphere ocamlEnd "\<\(object\)\>" +else + syn sync match ocamlEndSync grouphere ocamlEnd "\<\(begin\|object\)\>" +endif + +syn sync match ocamlEndSync groupthere ocamlEnd "\" +syn sync match ocamlStructSync grouphere ocamlStruct "\" +syn sync match ocamlStructSync groupthere ocamlStruct "\" +syn sync match ocamlSigSync grouphere ocamlSig "\" +syn sync match ocamlSigSync groupthere ocamlSig "\" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link ocamlBraceErr Error +hi def link ocamlBrackErr Error +hi def link ocamlParenErr Error +hi def link ocamlArrErr Error + +hi def link ocamlCommentErr Error + +hi def link ocamlCountErr Error +hi def link ocamlDoErr Error +hi def link ocamlDoneErr Error +hi def link ocamlEndErr Error +hi def link ocamlThenErr Error + +hi def link ocamlCharErr Error + +hi def link ocamlErr Error + +hi def link ocamlComment Comment + +hi def link ocamlModPath Include +hi def link ocamlObject Include +hi def link ocamlModule Include +hi def link ocamlModParam1 Include +hi def link ocamlModType Include +hi def link ocamlMPRestr3 Include +hi def link ocamlFullMod Include +hi def link ocamlModTypeRestr Include +hi def link ocamlWith Include +hi def link ocamlMTDef Include + +hi def link ocamlScript Include + +hi def link ocamlConstructor Constant + +hi def link ocamlVal Keyword +hi def link ocamlModPreRHS Keyword +hi def link ocamlMPRestr2 Keyword +hi def link ocamlKeyword Keyword +hi def link ocamlMethod Include +hi def link ocamlFunDef Keyword +hi def link ocamlRefAssign Keyword +hi def link ocamlKeyChar Keyword +hi def link ocamlAnyVar Keyword +hi def link ocamlTopStop Keyword +hi def link ocamlOperator Keyword + +hi def link ocamlBoolean Boolean +hi def link ocamlCharacter Character +hi def link ocamlNumber Number +hi def link ocamlFloat Float +hi def link ocamlString String + +hi def link ocamlLabel Identifier + +hi def link ocamlType Type + +hi def link ocamlTodo Todo + +hi def link ocamlEncl Keyword + + +let b:current_syntax = "ocaml" + +" vim: ts=8 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'ocaml') == -1 " Vim syntax file diff --git a/syntax/occam.vim b/syntax/occam.vim new file mode 100644 index 0000000..3d06b2b --- /dev/null +++ b/syntax/occam.vim @@ -0,0 +1,120 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: occam +" Copyright: Fred Barnes , Mario Schweigler +" Maintainer: Mario Schweigler +" Last Change: 24 May 2003 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +"{{{ Settings +" Set shift width for indent +setlocal shiftwidth=2 +" Set the tab key size to two spaces +setlocal softtabstop=2 +" Let tab keys always be expanded to spaces +setlocal expandtab + +" Dots are valid in occam identifiers +setlocal iskeyword+=. +"}}} + +syn case match + +syn keyword occamType BYTE BOOL INT INT16 INT32 INT64 REAL32 REAL64 ANY +syn keyword occamType CHAN DATA OF TYPE TIMER INITIAL VAL PORT MOBILE PLACED +syn keyword occamType PROCESSOR PACKED RECORD PROTOCOL SHARED ROUND TRUNC + +syn keyword occamStructure SEQ PAR IF ALT PRI FORKING PLACE AT + +syn keyword occamKeyword PROC IS TRUE FALSE SIZE RECURSIVE REC +syn keyword occamKeyword RETYPES RESHAPES STEP FROM FOR RESCHEDULE STOP SKIP FORK +syn keyword occamKeyword FUNCTION VALOF RESULT ELSE CLONE CLAIM +syn keyword occamBoolean TRUE FALSE +syn keyword occamRepeat WHILE +syn keyword occamConditional CASE +syn keyword occamConstant MOSTNEG MOSTPOS + +syn match occamBrackets /\[\|\]/ +syn match occamParantheses /(\|)/ + +syn keyword occamOperator AFTER TIMES MINUS PLUS INITIAL REM AND OR XOR NOT +syn keyword occamOperator BITAND BITOR BITNOT BYTESIN OFFSETOF + +syn match occamOperator /::\|:=\|?\|!/ +syn match occamOperator /<\|>\|+\|-\|\*\|\/\|\\\|=\|\~/ +syn match occamOperator /@\|\$\$\|%\|&&\|<&\|&>\|<\]\|\[>\|\^/ + +syn match occamSpecialChar /\M**\|*'\|*"\|*#\(\[0-9A-F\]\+\)/ contained +syn match occamChar /\M\L\='\[^*\]'/ +syn match occamChar /L'[^']*'/ contains=occamSpecialChar + +syn case ignore +syn match occamTodo /\:\=/ contained +syn match occamNote /\:\=/ contained +syn case match +syn keyword occamNote NOT contained + +syn match occamComment /--.*/ contains=occamCommentTitle,occamTodo,occamNote +syn match occamCommentTitle /--\s*\u\a*\(\s\+\u\a*\)*:/hs=s+2 contained contains=occamTodo,occamNote +syn match occamCommentTitle /--\s*KROC-LIBRARY\(\.so\|\.a\)\=\s*$/hs=s+2 contained +syn match occamCommentTitle /--\s*\(KROC-OPTIONS:\|RUN-PARAMETERS:\)/hs=s+2 contained + +syn match occamIdentifier /\<[A-Z.][A-Z.0-9]*\>/ +syn match occamFunction /\<[A-Za-z.][A-Za-z0-9.]*\>/ contained + +syn match occamPPIdentifier /##.\{-}\>/ + +syn region occamString start=/"/ skip=/\M*"/ end=/"/ contains=occamSpecialChar +syn region occamCharString start=/'/ end=/'/ contains=occamSpecialChar + +syn match occamNumber /\<\d\+\(\.\d\+\(E\(+\|-\)\d\+\)\=\)\=/ +syn match occamNumber /-\d\+\(\.\d\+\(E\(+\|-\)\d\+\)\=\)\=/ +syn match occamNumber /#\(\d\|[A-F]\)\+/ +syn match occamNumber /-#\(\d\|[A-F]\)\+/ + +syn keyword occamCDString SHARED EXTERNAL DEFINED NOALIAS NOUSAGE NOT contained +syn keyword occamCDString FILE LINE PROCESS.PRIORITY OCCAM2.5 contained +syn keyword occamCDString USER.DEFINED.OPERATORS INITIAL.DECL MOBILES contained +syn keyword occamCDString BLOCKING.SYSCALLS VERSION NEED.QUAD.ALIGNMENT contained +syn keyword occamCDString TARGET.CANONICAL TARGET.CPU TARGET.OS TARGET.VENDOR contained +syn keyword occamCDString TRUE FALSE AND OR contained +syn match occamCDString /<\|>\|=\|(\|)/ contained + +syn region occamCDirective start=/#\(USE\|INCLUDE\|PRAGMA\|DEFINE\|UNDEFINE\|UNDEF\|IF\|ELIF\|ELSE\|ENDIF\|WARNING\|ERROR\|RELAX\)\>/ end=/$/ contains=occamString,occamComment,occamCDString + + +hi def link occamType Type +hi def link occamKeyword Keyword +hi def link occamComment Comment +hi def link occamCommentTitle PreProc +hi def link occamTodo Todo +hi def link occamNote Todo +hi def link occamString String +hi def link occamCharString String +hi def link occamNumber Number +hi def link occamCDirective PreProc +hi def link occamCDString String +hi def link occamPPIdentifier PreProc +hi def link occamBoolean Boolean +hi def link occamSpecialChar SpecialChar +hi def link occamChar Character +hi def link occamStructure Structure +hi def link occamIdentifier Identifier +hi def link occamConstant Constant +hi def link occamOperator Operator +hi def link occamFunction Ignore +hi def link occamRepeat Repeat +hi def link occamConditional Conditional +hi def link occamBrackets Type +hi def link occamParantheses Delimiter + + +let b:current_syntax = "occam" + + +endif diff --git a/syntax/omnimark.vim b/syntax/omnimark.vim new file mode 100644 index 0000000..0ffddc3 --- /dev/null +++ b/syntax/omnimark.vim @@ -0,0 +1,110 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Omnimark +" Maintainer: Paul Terray +" Last Change: 11 Oct 2000 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=@,48-57,_,128-167,224-235,- + +syn keyword omnimarkKeywords ACTIVATE AGAIN +syn keyword omnimarkKeywords CATCH CLEAR CLOSE COPY COPY-CLEAR CROSS-TRANSLATE +syn keyword omnimarkKeywords DEACTIVATE DECLARE DECREMENT DEFINE DISCARD DIVIDE DO DOCUMENT-END DOCUMENT-START DONE DTD-START +syn keyword omnimarkKeywords ELEMENT ELSE ESCAPE EXIT +syn keyword omnimarkKeywords FAIL FIND FIND-END FIND-START FORMAT +syn keyword omnimarkKeywords GROUP +syn keyword omnimarkKeywords HALT HALT-EVERYTHING +syn keyword omnimarkKeywords IGNORE IMPLIED INCLUDE INCLUDE-END INCLUDE-START INCREMENT INPUT +syn keyword omnimarkKeywords JOIN +syn keyword omnimarkKeywords LINE-END LINE-START LOG LOOKAHEAD +syn keyword omnimarkKeywords MACRO +syn keyword omnimarkKeywords MACRO-END MARKED-SECTION MARKUP-COMMENT MARKUP-ERROR MARKUP-PARSER MASK MATCH MINUS MODULO +syn keyword omnimarkKeywords NEW NEWLINE NEXT +syn keyword omnimarkKeywords OPEN OUTPUT OUTPUT-TO OVER +syn keyword omnimarkKeywords PROCESS PROCESS-END PROCESS-START PROCESSING-INSTRUCTION PROLOG-END PROLOG-IN-ERROR PUT +syn keyword omnimarkKeywords REMOVE REOPEN REPEAT RESET RETHROW RETURN +syn keyword omnimarkKeywords WHEN WHITE-SPACE +syn keyword omnimarkKeywords SAVE SAVE-CLEAR SCAN SELECT SET SGML SGML-COMMENT SGML-DECLARATION-END SGML-DTD SGML-DTDS SGML-ERROR SGML-IN SGML-OUT SGML-PARSE SGML-PARSER SHIFT SUBMIT SUCCEED SUPPRESS +syn keyword omnimarkKeywords SYSTEM-CALL +syn keyword omnimarkKeywords TEST-SYSTEM THROW TO TRANSLATE +syn keyword omnimarkKeywords UC UL UNLESS UP-TRANSLATE +syn keyword omnimarkKeywords XML-PARSE + +syn keyword omnimarkCommands ACTIVE AFTER ANCESTOR AND ANOTHER ARG AS ATTACHED ATTRIBUTE ATTRIBUTES +syn keyword omnimarkCommands BASE BEFORE BINARY BINARY-INPUT BINARY-MODE BINARY-OUTPUT BREAK-WIDTH BUFFER BY +syn keyword omnimarkCommands CASE CHILDREN CLOSED COMPILED-DATE COMPLEMENT CONREF CONTENT CONTEXT-TRANSLATE COUNTER CREATED CREATING CREATOR CURRENT +syn keyword omnimarkCommands DATA-ATTRIBUTE DATA-ATTRIBUTES DATA-CONTENT DATA-LETTERS DATE DECLARED-CONREF DECLARED-CURRENT DECLARED-DEFAULTED DECLARED-FIXED DECLARED-IMPLIED DECLARED-REQUIRED +syn keyword omnimarkCommands DEFAULT-ENTITY DEFAULTED DEFAULTING DELIMITER DIFFERENCE DIRECTORY DOCTYPE DOCUMENT DOCUMENT-ELEMENT DOMAIN-FREE DOWN-TRANSLATE DTD DTD-END DTDS +syn keyword omnimarkCommands ELEMENTS ELSEWHERE EMPTY ENTITIES ENTITY EPILOG-START EQUAL EXCEPT EXISTS EXTERNAL EXTERNAL-DATA-ENTITY EXTERNAL-ENTITY EXTERNAL-FUNCTION EXTERNAL-OUTPUT-FUNCTION +syn keyword omnimarkCommands EXTERNAL-TEXT-ENTITY +syn keyword omnimarkCommands FALSE FILE FUNCTION FUNCTION-LIBRARY +syn keyword omnimarkCommands GENERAL GLOBAL GREATER-EQUAL GREATER-THAN GROUPS +syn keyword omnimarkCommands HAS HASNT HERALDED-NAMES +syn keyword omnimarkCommands ID ID-CHECKING IDREF IDREFS IN IN-LIBRARY INCLUSION INITIAL INITIAL-SIZE INSERTION-BREAK INSTANCE INTERNAL INVALID-DATA IS ISNT ITEM +syn keyword omnimarkCommands KEY KEYED +syn keyword omnimarkCommands LAST LASTMOST LC LENGTH LESS-EQUAL LESS-THAN LETTERS LIBRARY LITERAL LOCAL +syn keyword omnimarkCommands MATCHES MIXED MODIFIABLE +syn keyword omnimarkCommands NAME NAME-LETTERS NAMECASE NAMED NAMES NDATA-ENTITY NEGATE NESTED-REFERENTS NMTOKEN NMTOKENS NO NO-DEFAULT-IO NON-CDATA NON-IMPLIED NON-SDATA NOT NOTATION NUMBER-OF NUMBERS +syn keyword omnimarkCommands NUTOKEN NUTOKENS +syn keyword omnimarkCommands OCCURRENCE OF OPAQUE OPTIONAL OR +syn keyword omnimarkCommands PARAMETER PARENT PAST PATTERN PLUS PREPARENT PREVIOUS PROPER PUBLIC +syn keyword omnimarkCommands READ-ONLY READABLE REFERENT REFERENTS REFERENTS-ALLOWED REFERENTS-DISPLAYED REFERENTS-NOT-ALLOWED REMAINDER REPEATED REPLACEMENT-BREAK REVERSED +syn keyword omnimarkCommands SILENT-REFERENT SIZE SKIP SOURCE SPECIFIED STATUS STREAM SUBDOC-ENTITY SUBDOCUMENT SUBDOCUMENTS SUBELEMENT SWITCH SYMBOL SYSTEM +syn keyword omnimarkCommands TEXT-MODE THIS TIMES TOKEN TRUE +syn keyword omnimarkCommands UNANCHORED UNATTACHED UNION USEMAP USING +syn keyword omnimarkCommands VALUE VALUED VARIABLE +syn keyword omnimarkCommands WITH WRITABLE +syn keyword omnimarkCommands XML XML-DTD XML-DTDS +syn keyword omnimarkCommands YES +syn keyword omnimarkCommands #ADDITIONAL-INFO #APPINFO #CAPACITY #CHARSET #CLASS #COMMAND-LINE-NAMES #CONSOLE #CURRENT-INPUT #CURRENT-OUTPUT #DATA #DOCTYPE #DOCUMENT #DTD #EMPTY #ERROR #ERROR-CODE +syn keyword omnimarkCommands #FILE-NAME #FIRST #GROUP #IMPLIED #ITEM #LANGUAGE-VERSION #LAST #LIBPATH #LIBRARY #LIBVALUE #LINE-NUMBER #MAIN-INPUT #MAIN-OUTPUT #MARKUP-ERROR-COUNT #MARKUP-ERROR-TOTAL +syn keyword omnimarkCommands #MARKUP-PARSER #MARKUP-WARNING-COUNT #MARKUP-WARNING-TOTAL #MESSAGE #NONE #OUTPUT #PLATFORM-INFO #PROCESS-INPUT #PROCESS-OUTPUT #RECOVERY-INFO #SGML #SGML-ERROR-COUNT +syn keyword omnimarkCommands #SGML-ERROR-TOTAL #SGML-WARNING-COUNT #SGML-WARNING-TOTAL #SUPPRESS #SYNTAX #! + +syn keyword omnimarkPatterns ANY ANY-TEXT +syn keyword omnimarkPatterns BLANK +syn keyword omnimarkPatterns CDATA CDATA-ENTITY CONTENT-END CONTENT-START +syn keyword omnimarkPatterns DIGIT +syn keyword omnimarkPatterns LETTER +syn keyword omnimarkPatterns NUMBER +syn keyword omnimarkPatterns PCDATA +syn keyword omnimarkPatterns RCDATA +syn keyword omnimarkPatterns SDATA SDATA-ENTITY SPACE +syn keyword omnimarkPatterns TEXT +syn keyword omnimarkPatterns VALUE-END VALUE-START +syn keyword omnimarkPatterns WORD-END WORD-START + +syn region omnimarkComment start=";" end="$" + +" strings +syn region omnimarkString matchgroup=Normal start=+'+ end=+'+ skip=+%'+ contains=omnimarkEscape +syn region omnimarkString matchgroup=Normal start=+"+ end=+"+ skip=+%"+ contains=omnimarkEscape +syn match omnimarkEscape contained +%.+ +syn match omnimarkEscape contained +%[0-9][0-9]#+ + +"syn sync maxlines=100 +syn sync minlines=2000 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link omnimarkCommands Statement +hi def link omnimarkKeywords Identifier +hi def link omnimarkString String +hi def link omnimarkPatterns Macro +" hi def link omnimarkNumber Number +hi def link omnimarkComment Comment +hi def link omnimarkEscape Special + + +let b:current_syntax = "omnimark" + +" vim: ts=8 + + +endif diff --git a/syntax/openroad.vim b/syntax/openroad.vim new file mode 100644 index 0000000..fcf54b4 --- /dev/null +++ b/syntax/openroad.vim @@ -0,0 +1,256 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: CA-OpenROAD +" Maintainer: Luis Moreno +" Last change: 2001 Jun 12 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syntax case ignore + +" Keywords +" +syntax keyword openroadKeyword ABORT ALL ALTER AND ANY AS ASC AT AVG BEGIN +syntax keyword openroadKeyword BETWEEN BY BYREF CALL CALLFRAME CALLPROC CASE +syntax keyword openroadKeyword CLEAR CLOSE COMMIT CONNECT CONTINUE COPY COUNT +syntax keyword openroadKeyword CREATE CURRENT DBEVENT DECLARE DEFAULT DELETE +syntax keyword openroadKeyword DELETEROW DESC DIRECT DISCONNECT DISTINCT DO +syntax keyword openroadKeyword DROP ELSE ELSEIF END ENDCASE ENDDECLARE ENDFOR +syntax keyword openroadKeyword ENDIF ENDLOOP ENDWHILE ESCAPE EXECUTE EXISTS +syntax keyword openroadKeyword EXIT FETCH FIELD FOR FROM GOTOFRAME GRANT GROUP +syntax keyword openroadKeyword HAVING IF IMMEDIATE IN INDEX INITIALISE +syntax keyword openroadKeyword INITIALIZE INQUIRE_INGRES INQUIRE_SQL INSERT +syntax keyword openroadKeyword INSERTROW INSTALLATION INTEGRITY INTO KEY LIKE +syntax keyword openroadKeyword LINK MAX MESSAGE METHOD MIN MODE MODIFY NEXT +syntax keyword openroadKeyword NOECHO NOT NULL OF ON OPEN OPENFRAME OR ORDER +syntax keyword openroadKeyword PERMIT PROCEDURE PROMPT QUALIFICATION RAISE +syntax keyword openroadKeyword REGISTER RELOCATE REMOVE REPEAT REPEATED RESUME +syntax keyword openroadKeyword RETURN RETURNING REVOKE ROLE ROLLBACK RULE SAVE +syntax keyword openroadKeyword SAVEPOINT SELECT SET SLEEP SOME SUM SYSTEM TABLE +syntax keyword openroadKeyword THEN TO TRANSACTION UNION UNIQUE UNTIL UPDATE +syntax keyword openroadKeyword VALUES VIEW WHERE WHILE WITH WORK + +syntax keyword openroadTodo contained TODO + +" Catch errors caused by wrong parenthesis +" +syntax cluster openroadParenGroup contains=openroadParenError,openroadTodo +syntax region openroadParen transparent start='(' end=')' contains=ALLBUT,@openroadParenGroup +syntax match openroadParenError ")" +highlight link openroadParenError cError + +" Numbers +" +syntax match openroadNumber "\<[0-9]\+\>" + +" String +" +syntax region openroadString start=+'+ end=+'+ + +" Operators, Data Types and Functions +" +syntax match openroadOperator /[\+\-\*\/=\<\>;\(\)]/ + +syntax keyword openroadType ARRAY BYTE CHAR DATE DECIMAL FLOAT FLOAT4 +syntax keyword openroadType FLOAT8 INT1 INT2 INT4 INTEGER INTEGER1 +syntax keyword openroadType INTEGER2 INTEGER4 MONEY OBJECT_KEY +syntax keyword openroadType SECURITY_LABEL SMALLINT TABLE_KEY VARCHAR + +syntax keyword openroadFunc IFNULL + +" System Classes +" +syntax keyword openroadClass ACTIVEFIELD ANALOGFIELD APPFLAG APPSOURCE +syntax keyword openroadClass ARRAYOBJECT ATTRIBUTEOBJECT BARFIELD +syntax keyword openroadClass BITMAPOBJECT BOXTRIM BREAKSPEC BUTTONFIELD +syntax keyword openroadClass CELLATTRIBUTE CHOICEBITMAP CHOICEDETAIL +syntax keyword openroadClass CHOICEFIELD CHOICEITEM CHOICELIST CLASS +syntax keyword openroadClass CLASSSOURCE COLUMNCROSS COLUMNFIELD +syntax keyword openroadClass COMPOSITEFIELD COMPSOURCE CONTROLBUTTON +syntax keyword openroadClass CROSSTABLE CURSORBITMAP CURSOROBJECT DATASTREAM +syntax keyword openroadClass DATEOBJECT DBEVENTOBJECT DBSESSIONOBJECT +syntax keyword openroadClass DISPLAYFORM DYNEXPR ELLIPSESHAPE ENTRYFIELD +syntax keyword openroadClass ENUMFIELD EVENT EXTOBJECT EXTOBJFIELD +syntax keyword openroadClass FIELDOBJECT FLEXIBLEFORM FLOATOBJECT FORMFIELD +syntax keyword openroadClass FRAMEEXEC FRAMEFORM FRAMESOURCE FREETRIM +syntax keyword openroadClass GHOSTEXEC GHOSTSOURCE IMAGEFIELD IMAGETRIM +syntax keyword openroadClass INTEGEROBJECT LISTFIELD LISTVIEWCOLATTR +syntax keyword openroadClass LISTVIEWFIELD LONGBYTEOBJECT LONGVCHAROBJECT +syntax keyword openroadClass MATRIXFIELD MENUBAR MENUBUTTON MENUFIELD +syntax keyword openroadClass MENUGROUP MENUITEM MENULIST MENUSEPARATOR +syntax keyword openroadClass MENUSTACK MENUTOGGLE METHODEXEC METHODOBJECT +syntax keyword openroadClass MONEYOBJECT OBJECT OPTIONFIELD OPTIONMENU +syntax keyword openroadClass PALETTEFIELD POPUPBUTTON PROC4GLSOURCE PROCEXEC +syntax keyword openroadClass PROCHANDLE QUERYCOL QUERYOBJECT QUERYPARM +syntax keyword openroadClass QUERYTABLE RADIOFIELD RECTANGLESHAPE ROWCROSS +syntax keyword openroadClass SCALARFIELD SCOPE SCROLLBARFIELD SEGMENTSHAPE +syntax keyword openroadClass SESSIONOBJECT SHAPEFIELD SLIDERFIELD SQLSELECT +syntax keyword openroadClass STACKFIELD STRINGOBJECT SUBFORM TABBAR +syntax keyword openroadClass TABFIELD TABFOLDER TABLEFIELD TABPAGE +syntax keyword openroadClass TOGGLEFIELD TREE TREENODE TREEVIEWFIELD +syntax keyword openroadClass USERCLASSOBJECT USEROBJECT VIEWPORTFIELD + +" System Events +" +syntax keyword openroadEvent CHILDCLICK CHILDCLICKPOINT CHILDCOLLAPSED +syntax keyword openroadEvent CHILDDETAILS CHILDDOUBLECLICK CHILDDRAGBOX +syntax keyword openroadEvent CHILDDRAGSEGMENT CHILDENTRY CHILDEXIT +syntax keyword openroadEvent CHILDEXPANDED CHILDHEADERCLICK CHILDMOVED +syntax keyword openroadEvent CHILDPROPERTIES CHILDRESIZED CHILDSCROLL +syntax keyword openroadEvent CHILDSELECT CHILDSELECTIONCHANGED CHILDSETVALUE +syntax keyword openroadEvent CHILDUNSELECT CHILDVALIDATE CLICK CLICKPOINT +syntax keyword openroadEvent COLLAPSED DBEVENT DETAILS DOUBLECLICK DRAGBOX +syntax keyword openroadEvent DRAGSEGMENT ENTRY EXIT EXPANDED EXTCLASSEVENT +syntax keyword openroadEvent FRAMEACTIVATE FRAMEDEACTIVATE HEADERCLICK +syntax keyword openroadEvent INSERTROW LABELCHANGED MOVED PAGEACTIVATED +syntax keyword openroadEvent PAGECHANGED PAGEDEACTIVATED PROPERTIES RESIZED +syntax keyword openroadEvent SCROLL SELECT SELECTIONCHANGED SETVALUE +syntax keyword openroadEvent TERMINATE UNSELECT USEREVENT VALIDATE +syntax keyword openroadEvent WINDOWCLOSE WINDOWICON WINDOWMOVED WINDOWRESIZED +syntax keyword openroadEvent WINDOWVISIBLE + +" System Constants +" +syntax keyword openroadConst BF_BMP BF_GIF BF_SUNRASTER BF_TIFF +syntax keyword openroadConst BF_WINDOWCURSOR BF_WINDOWICON BF_XBM +syntax keyword openroadConst CC_BACKGROUND CC_BLACK CC_BLUE CC_BROWN CC_CYAN +syntax keyword openroadConst CC_DEFAULT_1 CC_DEFAULT_10 CC_DEFAULT_11 +syntax keyword openroadConst CC_DEFAULT_12 CC_DEFAULT_13 CC_DEFAULT_14 +syntax keyword openroadConst CC_DEFAULT_15 CC_DEFAULT_16 CC_DEFAULT_17 +syntax keyword openroadConst CC_DEFAULT_18 CC_DEFAULT_19 CC_DEFAULT_2 +syntax keyword openroadConst CC_DEFAULT_20 CC_DEFAULT_21 CC_DEFAULT_22 +syntax keyword openroadConst CC_DEFAULT_23 CC_DEFAULT_24 CC_DEFAULT_25 +syntax keyword openroadConst CC_DEFAULT_26 CC_DEFAULT_27 CC_DEFAULT_28 +syntax keyword openroadConst CC_DEFAULT_29 CC_DEFAULT_3 CC_DEFAULT_30 +syntax keyword openroadConst CC_DEFAULT_4 CC_DEFAULT_5 CC_DEFAULT_6 +syntax keyword openroadConst CC_DEFAULT_7 CC_DEFAULT_8 CC_DEFAULT_9 +syntax keyword openroadConst CC_FOREGROUND CC_GRAY CC_GREEN CC_LIGHT_BLUE +syntax keyword openroadConst CC_LIGHT_BROWN CC_LIGHT_CYAN CC_LIGHT_GRAY +syntax keyword openroadConst CC_LIGHT_GREEN CC_LIGHT_ORANGE CC_LIGHT_PINK +syntax keyword openroadConst CC_LIGHT_PURPLE CC_LIGHT_RED CC_LIGHT_YELLOW +syntax keyword openroadConst CC_MAGENTA CC_ORANGE CC_PALE_BLUE CC_PALE_BROWN +syntax keyword openroadConst CC_PALE_CYAN CC_PALE_GRAY CC_PALE_GREEN +syntax keyword openroadConst CC_PALE_ORANGE CC_PALE_PINK CC_PALE_PURPLE +syntax keyword openroadConst CC_PALE_RED CC_PALE_YELLOW CC_PINK CC_PURPLE +syntax keyword openroadConst CC_RED CC_SYS_ACTIVEBORDER CC_SYS_ACTIVECAPTION +syntax keyword openroadConst CC_SYS_APPWORKSPACE CC_SYS_BACKGROUND +syntax keyword openroadConst CC_SYS_BTNFACE CC_SYS_BTNSHADOW CC_SYS_BTNTEXT +syntax keyword openroadConst CC_SYS_CAPTIONTEXT CC_SYS_GRAYTEXT +syntax keyword openroadConst CC_SYS_HIGHLIGHT CC_SYS_HIGHLIGHTTEXT +syntax keyword openroadConst CC_SYS_INACTIVEBORDER CC_SYS_INACTIVECAPTION +syntax keyword openroadConst CC_SYS_INACTIVECAPTIONTEXT CC_SYS_MENU +syntax keyword openroadConst CC_SYS_MENUTEXT CC_SYS_SCROLLBAR CC_SYS_SHADOW +syntax keyword openroadConst CC_SYS_WINDOW CC_SYS_WINDOWFRAME +syntax keyword openroadConst CC_SYS_WINDOWTEXT CC_WHITE CC_YELLOW +syntax keyword openroadConst CL_INVALIDVALUE CP_BOTH CP_COLUMNS CP_NONE +syntax keyword openroadConst CP_ROWS CS_CLOSED CS_CURRENT CS_NOCURRENT +syntax keyword openroadConst CS_NO_MORE_ROWS CS_OPEN CS_OPEN_CACHED DC_BW +syntax keyword openroadConst DC_COLOR DP_AUTOSIZE_FIELD DP_CLIP_IMAGE +syntax keyword openroadConst DP_SCALE_IMAGE_H DP_SCALE_IMAGE_HW +syntax keyword openroadConst DP_SCALE_IMAGE_W DS_CONNECTED DS_DISABLED +syntax keyword openroadConst DS_DISCONNECTED DS_INGRES_DBMS DS_NO_DBMS +syntax keyword openroadConst DS_ORACLE_DBMS DS_SQLSERVER_DBMS DV_NULL +syntax keyword openroadConst DV_STRING DV_SYSTEM EH_NEXT_HANDLER EH_RESUME +syntax keyword openroadConst EH_RETRY EP_INTERACTIVE EP_NONE EP_OUTPUT +syntax keyword openroadConst ER_FAIL ER_NAMEEXISTS ER_OK ER_OUTOFRANGE +syntax keyword openroadConst ER_ROWNOTFOUND ER_USER1 ER_USER10 ER_USER2 +syntax keyword openroadConst ER_USER3 ER_USER4 ER_USER5 ER_USER6 ER_USER7 +syntax keyword openroadConst ER_USER8 ER_USER9 FALSE FA_BOTTOMCENTER +syntax keyword openroadConst FA_BOTTOMLEFT FA_BOTTOMRIGHT FA_CENTER +syntax keyword openroadConst FA_CENTERLEFT FA_CENTERRIGHT FA_DEFAULT FA_NONE +syntax keyword openroadConst FA_TOPCENTER FA_TOPLEFT FA_TOPRIGHT +syntax keyword openroadConst FB_CHANGEABLE FB_CLICKPOINT FB_DIMMED FB_DRAGBOX +syntax keyword openroadConst FB_DRAGSEGMENT FB_FLEXIBLE FB_INVISIBLE +syntax keyword openroadConst FB_LANDABLE FB_MARKABLE FB_RESIZEABLE +syntax keyword openroadConst FB_VIEWABLE FB_VISIBLE FC_LOWER FC_NONE FC_UPPER +syntax keyword openroadConst FM_QUERY FM_READ FM_UPDATE FM_USER1 FM_USER2 +syntax keyword openroadConst FM_USER3 FO_DEFAULT FO_HORIZONTAL FO_VERTICAL +syntax keyword openroadConst FP_BITMAP FP_CLEAR FP_CROSSHATCH FP_DARKSHADE +syntax keyword openroadConst FP_DEFAULT FP_HORIZONTAL FP_LIGHTSHADE FP_SHADE +syntax keyword openroadConst FP_SOLID FP_VERTICAL FT_NOTSETVALUE FT_SETVALUE +syntax keyword openroadConst FT_TABTO FT_TAKEFOCUS GF_BOTTOM GF_DEFAULT +syntax keyword openroadConst GF_LEFT GF_RIGHT GF_TOP HC_DOUBLEQUOTE +syntax keyword openroadConst HC_FORMFEED HC_NEWLINE HC_QUOTE HC_SPACE HC_TAB +syntax keyword openroadConst HV_CONTENTS HV_CONTEXT HV_HELPONHELP HV_KEY +syntax keyword openroadConst HV_QUIT LS_3D LS_DASH LS_DASHDOT LS_DASHDOTDOT +syntax keyword openroadConst LS_DEFAULT LS_DOT LS_SOLID LW_DEFAULT +syntax keyword openroadConst LW_EXTRATHIN LW_MAXIMUM LW_MIDDLE LW_MINIMUM +syntax keyword openroadConst LW_NOLINE LW_THICK LW_THIN LW_VERYTHICK +syntax keyword openroadConst LW_VERYTHIN MB_DISABLED MB_ENABLED MB_INVISIBLE +syntax keyword openroadConst MB_MOVEABLE MT_ERROR MT_INFO MT_NONE MT_WARNING +syntax keyword openroadConst OP_APPEND OP_NONE OS3D OS_DEFAULT OS_SHADOW +syntax keyword openroadConst OS_SOLID PU_CANCEL PU_OK QS_ACTIVE QS_INACTIVE +syntax keyword openroadConst QS_SETCOL QY_ARRAY QY_CACHE QY_CURSOR QY_DIRECT +syntax keyword openroadConst RC_CHILDSELECTED RC_DOWN RC_END RC_FIELDFREED +syntax keyword openroadConst RC_FIELDORPHANED RC_GROUPSELECT RC_HOME RC_LEFT +syntax keyword openroadConst RC_MODECHANGED RC_MOUSECLICK RC_MOUSEDRAG +syntax keyword openroadConst RC_NEXT RC_NOTAPPLICABLE RC_PAGEDOWN RC_PAGEUP +syntax keyword openroadConst RC_PARENTSELECTED RC_PREVIOUS RC_PROGRAM +syntax keyword openroadConst RC_RESUME RC_RETURN RC_RIGHT RC_ROWDELETED +syntax keyword openroadConst RC_ROWINSERTED RC_ROWSALLDELETED RC_SELECT +syntax keyword openroadConst RC_TFSCROLL RC_TOGGLESELECT RC_UP RS_CHANGED +syntax keyword openroadConst RS_DELETED RS_NEW RS_UNCHANGED RS_UNDEFINED +syntax keyword openroadConst SK_CLOSE SK_COPY SK_CUT SK_DELETE SK_DETAILS +syntax keyword openroadConst SK_DUPLICATE SK_FIND SK_GO SK_HELP SK_NEXT +syntax keyword openroadConst SK_NONE SK_PASTE SK_PROPS SK_QUIT SK_REDO +syntax keyword openroadConst SK_SAVE SK_TFDELETEALLROWS SK_TFDELETEROW +syntax keyword openroadConst SK_TFFIND SK_TFINSERTROW SK_UNDO SP_APPSTARTING +syntax keyword openroadConst SP_ARROW SP_CROSS SP_IBEAM SP_ICON SP_NO +syntax keyword openroadConst SP_SIZE SP_SIZENESW SP_SIZENS SP_SIZENWSE +syntax keyword openroadConst SP_SIZEWE SP_UPARROW SP_WAIT SY_NT SY_OS2 +syntax keyword openroadConst SY_UNIX SY_VMS SY_WIN95 TF_COURIER TF_HELVETICA +syntax keyword openroadConst TF_LUCIDA TF_MENUDEFAULT TF_NEWCENTURY TF_SYSTEM +syntax keyword openroadConst TF_TIMESROMAN TRUE UE_DATAERROR UE_EXITED +syntax keyword openroadConst UE_NOTACTIVE UE_PURGED UE_RESUMED UE_UNKNOWN +syntax keyword openroadConst WI_MOTIF WI_MSWIN32 WI_MSWINDOWS WI_NONE WI_PM +syntax keyword openroadConst WP_FLOATING WP_INTERACTIVE WP_PARENTCENTERED +syntax keyword openroadConst WP_PARENTRELATIVE WP_SCREENCENTERED +syntax keyword openroadConst WP_SCREENRELATIVE WV_ICON WV_INVISIBLE +syntax keyword openroadConst WV_UNREALIZED WV_VISIBLE + +" System Variables +" +syntax keyword openroadVar CurFrame CurProcedure CurMethod CurObject + +" Identifiers +" +syntax match openroadIdent /[a-zA-Z_][a-zA-Z_]*![a-zA-Z_][a-zA-Z_]*/ + +" Comments +" +if exists("openroad_comment_strings") + syntax match openroadCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region openroadCommentString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end="$" + syntax region openroadComment start="/\*" end="\*/" contains=openroadCommentString,openroadCharacter,openroadNumber + syntax match openroadComment "//.*" contains=openroadComment2String,openroadCharacter,openroadNumber +else + syn region openroadComment start="/\*" end="\*/" + syn match openroadComment "//.*" +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +" + +hi def link openroadKeyword Statement +hi def link openroadNumber Number +hi def link openroadString String +hi def link openroadComment Comment +hi def link openroadOperator Operator +hi def link openroadType Type +hi def link openroadFunc Special +hi def link openroadClass Type +hi def link openroadEvent Statement +hi def link openroadConst Constant +hi def link openroadVar Identifier +hi def link openroadIdent Identifier +hi def link openroadTodo Todo + + +let b:current_syntax = "openroad" + +endif diff --git a/syntax/opl.vim b/syntax/opl.vim new file mode 100644 index 0000000..75f54c1 --- /dev/null +++ b/syntax/opl.vim @@ -0,0 +1,93 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: OPL +" Maintainer: Czo +" Last Change: 2012 Feb 03 by Thilo Six +" $Id: opl.vim,v 1.1 2004/06/13 17:34:11 vimboss Exp $ + +" Open Psion Language... (EPOC16/EPOC32) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" case is not significant +syn case ignore + +" A bunch of useful OPL keywords +syn keyword OPLStatement proc endp abs acos addr adjustalloc alert alloc app +syn keyword OPLStatement append appendsprite asc asin at atan back beep +syn keyword OPLStatement begintrans bookmark break busy byref cache +syn keyword OPLStatement cachehdr cacherec cachetidy call cancel caption +syn keyword OPLStatement changesprite chr$ clearflags close closesprite cls +syn keyword OPLStatement cmd$ committrans compact compress const continue +syn keyword OPLStatement copy cos count create createsprite cursor +syn keyword OPLStatement datetosecs datim$ day dayname$ days daystodate +syn keyword OPLStatement dbuttons dcheckbox dchoice ddate declare dedit +syn keyword OPLStatement deditmulti defaultwin deg delete dfile dfloat +syn keyword OPLStatement dialog diaminit diampos dinit dir$ dlong do dow +syn keyword OPLStatement dposition drawsprite dtext dtime dxinput edit else +syn keyword OPLStatement elseif enda endif endv endwh entersend entersend0 +syn keyword OPLStatement eof erase err err$ errx$ escape eval exist exp ext +syn keyword OPLStatement external find findfield findlib first fix$ flags +syn keyword OPLStatement flt font freealloc gat gborder gbox gbutton +syn keyword OPLStatement gcircle gclock gclose gcls gcolor gcopy gcreate +syn keyword OPLStatement gcreatebit gdrawobject gellipse gen$ get get$ +syn keyword OPLStatement getcmd$ getdoc$ getevent getevent32 geteventa32 +syn keyword OPLStatement geteventc getlibh gfill gfont ggmode ggrey gheight +syn keyword OPLStatement gidentity ginfo ginfo32 ginvert giprint glineby +syn keyword OPLStatement glineto gloadbit gloadfont global gmove gorder +syn keyword OPLStatement goriginx goriginy goto gotomark gpatt gpeekline +syn keyword OPLStatement gpoly gprint gprintb gprintclip grank gsavebit +syn keyword OPLStatement gscroll gsetpenwidth gsetwin gstyle gtmode gtwidth +syn keyword OPLStatement gunloadfont gupdate guse gvisible gwidth gx +syn keyword OPLStatement gxborder gxprint gy hex$ hour iabs icon if include +syn keyword OPLStatement input insert int intf intrans key key$ keya keyc +syn keyword OPLStatement killmark kmod last lclose left$ len lenalloc +syn keyword OPLStatement linklib ln loadlib loadm loc local lock log lopen +syn keyword OPLStatement lower$ lprint max mcard mcasc mean menu mid$ min +syn keyword OPLStatement minit minute mkdir modify month month$ mpopup +syn keyword OPLStatement newobj newobjh next notes num$ odbinfo off onerr +syn keyword OPLStatement open openr opx os parse$ path pause peek pi +syn keyword OPLStatement pointerfilter poke pos position possprite print +syn keyword OPLStatement put rad raise randomize realloc recsize rename +syn keyword OPLStatement rept$ return right$ rmdir rnd rollback sci$ screen +syn keyword OPLStatement screeninfo second secstodate send setdoc setflags +syn keyword OPLStatement setname setpath sin space sqr statuswin +syn keyword OPLStatement statwininfo std stop style sum tan testevent trap +syn keyword OPLStatement type uadd unloadlib unloadm until update upper$ +syn keyword OPLStatement use usr usr$ usub val var vector week while year +" syn keyword OPLStatement rem + + +syn match OPLNumber "\<\d\+\>" +syn match OPLNumber "\<\d\+\.\d*\>" +syn match OPLNumber "\.\d\+\>" + +syn region OPLString start=+"+ end=+"+ +syn region OPLComment start="REM[\t ]" end="$" +syn match OPLMathsOperator "-\|=\|[:<>+\*^/\\]" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link OPLStatement Statement +hi def link OPLNumber Number +hi def link OPLString String +hi def link OPLComment Comment +hi def link OPLMathsOperator Conditional +" hi def link OPLError Error + + +let b:current_syntax = "opl" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 + +endif diff --git a/syntax/ora.vim b/syntax/ora.vim new file mode 100644 index 0000000..5dcfa50 --- /dev/null +++ b/syntax/ora.vim @@ -0,0 +1,468 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Oracle config files (.ora) (Oracle 8i, ver. 8.1.5) +" Maintainer: Sandor Kopanyi +" Url: <-> +" Last Change: 2003 May 11 + +" * the keywords are listed by file (sqlnet.ora, listener.ora, etc.) +" * the parathesis-checking is made at the beginning for all keywords +" * possible values are listed also +" * there are some overlappings (e.g. METHOD is mentioned both for +" sqlnet-ora and tnsnames.ora; since will not cause(?) problems +" is easier to follow separately each file's keywords) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'ora' +endif + +syn case ignore + +"comments +syn match oraComment "\#.*" + +" catch errors caused by wrong parenthesis +syn region oraParen transparent start="(" end=")" contains=@oraAll,oraParen +syn match oraParenError ")" + +" strings +syn region oraString start=+"+ end=+"+ + +"common .ora staff + +"common protocol parameters +syn keyword oraKeywordGroup ADDRESS ADDRESS_LIST +syn keyword oraKeywordGroup DESCRIPTION_LIST DESCRIPTION +"all protocols +syn keyword oraKeyword PROTOCOL +syn keyword oraValue ipc tcp nmp +"Bequeath +syn keyword oraKeyword PROGRAM ARGV0 ARGS +"IPC +syn keyword oraKeyword KEY +"Named Pipes +syn keyword oraKeyword SERVER PIPE +"LU6.2 +syn keyword oraKeyword LU_NAME LLU LOCAL_LU LLU_NAME LOCAL_LU_NAME +syn keyword oraKeyword MODE MDN +syn keyword oraKeyword PLU PARTNER_LU_NAME PLU_LA PARTNER_LU_LOCAL_ALIAS +syn keyword oraKeyword TP_NAME TPN +"SPX +syn keyword oraKeyword SERVICE +"TCP/IP and TCP/IP with SSL +syn keyword oraKeyword HOST PORT + +"misc. keywords I've met but didn't find in manual (maybe they are deprecated?) +syn keyword oraKeywordGroup COMMUNITY_LIST +syn keyword oraKeyword COMMUNITY NAME DEFAULT_ZONE +syn keyword oraValue tcpcom + +"common values +syn keyword oraValue yes no on off true false null all none ok +"word 'world' is used a lot... +syn keyword oraModifier world + +"misc. common keywords +syn keyword oraKeyword TRACE_DIRECTORY TRACE_LEVEL TRACE_FILE + + +"sqlnet.ora +syn keyword oraKeywordPref NAMES NAMESCTL +syn keyword oraKeywordPref OSS SOURCE SQLNET TNSPING +syn keyword oraKeyword AUTOMATIC_IPC BEQUEATH_DETACH DAEMON TRACE_MASK +syn keyword oraKeyword DISABLE_OOB +syn keyword oraKeyword LOG_DIRECTORY_CLIENT LOG_DIRECTORY_SERVER +syn keyword oraKeyword LOG_FILE_CLIENT LOG_FILE_SERVER +syn keyword oraKeyword DCE PREFIX DEFAULT_DOMAIN DIRECTORY_PATH +syn keyword oraKeyword INITIAL_RETRY_TIMEOUT MAX_OPEN_CONNECTIONS +syn keyword oraKeyword MESSAGE_POOL_START_SIZE NIS META_MAP +syn keyword oraKeyword PASSWORD PREFERRED_SERVERS REQUEST_RETRIES +syn keyword oraKeyword INTERNAL_ENCRYPT_PASSWORD INTERNAL_USE +syn keyword oraKeyword NO_INITIAL_SERVER NOCONFIRM +syn keyword oraKeyword SERVER_PASSWORD TRACE_UNIQUE MY_WALLET +syn keyword oraKeyword LOCATION DIRECTORY METHOD METHOD_DATA +syn keyword oraKeyword SQLNET_ADDRESS +syn keyword oraKeyword AUTHENTICATION_SERVICES +syn keyword oraKeyword AUTHENTICATION_KERBEROS5_SERVICE +syn keyword oraKeyword AUTHENTICATION_GSSAPI_SERVICE +syn keyword oraKeyword CLIENT_REGISTRATION +syn keyword oraKeyword CRYPTO_CHECKSUM_CLIENT CRYPTO_CHECKSUM_SERVER +syn keyword oraKeyword CRYPTO_CHECKSUM_TYPES_CLIENT CRYPTO_CHECKSUM_TYPES_SERVER +syn keyword oraKeyword CRYPTO_SEED +syn keyword oraKeyword ENCRYPTION_CLIENT ENCRYPTION_SERVER +syn keyword oraKeyword ENCRYPTION_TYPES_CLIENT ENCRYPTION_TYPES_SERVER +syn keyword oraKeyword EXPIRE_TIME +syn keyword oraKeyword IDENTIX_FINGERPRINT_DATABASE IDENTIX_FINGERPRINT_DATABASE_USER +syn keyword oraKeyword IDENTIX_FINGERPRINT_DATABASE_PASSWORD IDENTIX_FINGERPRINT_METHOD +syn keyword oraKeyword KERBEROS5_CC_NAME KERBEROS5_CLOCKSKEW KERBEROS5_CONF +syn keyword oraKeyword KERBEROS5_KEYTAB KERBEROS5_REALMS +syn keyword oraKeyword RADIUS_ALTERNATE RADIUS_ALTERNATE_PORT RADIUS_ALTERNATE_RETRIES +syn keyword oraKeyword RADIUS_AUTHENTICATION_TIMEOUT RADIUS_AUTHENTICATION +syn keyword oraKeyword RADIUS_AUTHENTICATION_INTERFACE RADIUS_AUTHENTICATION_PORT +syn keyword oraKeyword RADIUS_AUTHENTICATION_RETRIES RADIUS_AUTHENTICATION_TIMEOUT +syn keyword oraKeyword RADIUS_CHALLENGE_RESPONSE RADIUS_SECRET RADIUS_SEND_ACCOUNTING +syn keyword oraKeyword SSL_CLIENT_AUTHENTICATION SSL_CIPHER_SUITES SSL_VERSION +syn keyword oraKeyword TRACE_DIRECTORY_CLIENT TRACE_DIRECTORY_SERVER +syn keyword oraKeyword TRACE_FILE_CLIENT TRACE_FILE_SERVER +syn keyword oraKeyword TRACE_LEVEL_CLIENT TRACE_LEVEL_SERVER +syn keyword oraKeyword TRACE_UNIQUE_CLIENT +syn keyword oraKeyword USE_CMAN USE_DEDICATED_SERVER +syn keyword oraValue user admin support +syn keyword oraValue accept accepted reject rejected requested required +syn keyword oraValue md5 rc4_40 rc4_56 rc4_128 des des_40 +syn keyword oraValue tnsnames onames hostname dce nis novell +syn keyword oraValue file oracle +syn keyword oraValue oss +syn keyword oraValue beq nds nts kerberos5 securid cybersafe identix dcegssapi radius +syn keyword oraValue undetermined + +"tnsnames.ora +syn keyword oraKeywordGroup CONNECT_DATA FAILOVER_MODE +syn keyword oraKeyword FAILOVER LOAD_BALANCE SOURCE_ROUTE TYPE_OF_SERVICE +syn keyword oraKeyword BACKUP TYPE METHOD GLOBAL_NAME HS +syn keyword oraKeyword INSTANCE_NAME RDB_DATABASE SDU SERVER +syn keyword oraKeyword SERVICE_NAME SERVICE_NAMES SID +syn keyword oraKeyword HANDLER_NAME EXTPROC_CONNECTION_DATA +syn keyword oraValue session select basic preconnect dedicated shared + +"listener.ora +syn keyword oraKeywordGroup SID_LIST SID_DESC PRESPAWN_LIST PRESPAWN_DESC +syn match oraKeywordGroup "SID_LIST_\w*" +syn keyword oraKeyword PROTOCOL_STACK PRESENTATION SESSION +syn keyword oraKeyword GLOBAL_DBNAME ORACLE_HOME PROGRAM SID_NAME +syn keyword oraKeyword PRESPAWN_MAX POOL_SIZE TIMEOUT +syn match oraKeyword "CONNECT_TIMEOUT_\w*" +syn match oraKeyword "LOG_DIRECTORY_\w*" +syn match oraKeyword "LOG_FILE_\w*" +syn match oraKeyword "PASSWORDS_\w*" +syn match oraKeyword "STARTUP_WAIT_TIME_\w*" +syn match oraKeyword "STARTUP_WAITTIME_\w*" +syn match oraKeyword "TRACE_DIRECTORY_\w*" +syn match oraKeyword "TRACE_FILE_\w*" +syn match oraKeyword "TRACE_LEVEL_\w*" +syn match oraKeyword "USE_PLUG_AND_PLAY_\w*" +syn keyword oraValue ttc giop ns raw + +"names.ora +syn keyword oraKeywordGroup ADDRESSES ADMIN_REGION +syn keyword oraKeywordGroup DEFAULT_FORWARDERS FORWARDER_LIST FORWARDER +syn keyword oraKeywordGroup DOMAIN_HINTS HINT_DESC HINT_LIST +syn keyword oraKeywordGroup DOMAINS DOMAIN_LIST DOMAIN +syn keyword oraKeywordPref NAMES +syn keyword oraKeyword EXPIRE REFRESH REGION RETRY USERID VERSION +syn keyword oraKeyword AUTHORITY_REQUIRED CONNECT_TIMEOUT +syn keyword oraKeyword AUTO_REFRESH_EXPIRE AUTO_REFRESH_RETRY +syn keyword oraKeyword CACHE_CHECKPOINT_FILE CACHE_CHECKPOINT_INTERVAL +syn keyword oraKeyword CONFIG_CHECKPOINT_FILE DEFAULT_FORWARDERS_ONLY +syn keyword oraKeyword HINT FORWARDING_AVAILABLE FORWARDING_DESIRED +syn keyword oraKeyword KEEP_DB_OPEN +syn keyword oraKeyword LOG_DIRECTORY LOG_FILE LOG_STATS_INTERVAL LOG_UNIQUE +syn keyword oraKeyword MAX_OPEN_CONNECTIONS MAX_REFORWARDS +syn keyword oraKeyword MESSAGE_POOL_START_SIZE +syn keyword oraKeyword NO_MODIFY_REQUESTS NO_REGION_DATABASE +syn keyword oraKeyword PASSWORD REGION_CHECKPOINT_FILE +syn keyword oraKeyword RESET_STATS_INTERVAL SAVE_CONFIG_ON_STOP +syn keyword oraKeyword SERVER_NAME TRACE_FUNC TRACE_UNIQUE + +"cman.ora +syn keyword oraKeywordGroup CMAN CMAN_ADMIN CMAN_PROFILE PARAMETER_LIST +syn keyword oraKeywordGroup CMAN_RULES RULES_LIST RULE +syn keyword oraKeyword ANSWER_TIMEOUT AUTHENTICATION_LEVEL LOG_LEVEL +syn keyword oraKeyword MAX_FREELIST_BUFFERS MAXIMUM_CONNECT_DATA MAXIMUM_RELAYS +syn keyword oraKeyword RELAY_STATISTICS SHOW_TNS_INFO TRACING +syn keyword oraKeyword USE_ASYNC_CALL SRC DST SRV ACT + +"protocol.ora +syn match oraKeyword "\w*\.EXCLUDED_NODES" +syn match oraKeyword "\w*\.INVITED_NODES" +syn match oraKeyword "\w*\.VALIDNODE_CHECKING" +syn keyword oraKeyword TCP NODELAY + + + + +"--------------------------------------- +"init.ora + +"common values +syn keyword oraValue nested_loops merge hash unlimited + +"init params +syn keyword oraKeyword O7_DICTIONARY_ACCESSIBILITY ALWAYS_ANTI_JOIN ALWAYS_SEMI_JOIN +syn keyword oraKeyword AQ_TM_PROCESSES ARCH_IO_SLAVES AUDIT_FILE_DEST AUDIT_TRAIL +syn keyword oraKeyword BACKGROUND_CORE_DUMP BACKGROUND_DUMP_DEST +syn keyword oraKeyword BACKUP_TAPE_IO_SLAVES BITMAP_MERGE_AREA_SIZE +syn keyword oraKeyword BLANK_TRIMMING BUFFER_POOL_KEEP BUFFER_POOL_RECYCLE +syn keyword oraKeyword COMMIT_POINT_STRENGTH COMPATIBLE CONTROL_FILE_RECORD_KEEP_TIME +syn keyword oraKeyword CONTROL_FILES CORE_DUMP_DEST CPU_COUNT +syn keyword oraKeyword CREATE_BITMAP_AREA_SIZE CURSOR_SPACE_FOR_TIME +syn keyword oraKeyword DB_BLOCK_BUFFERS DB_BLOCK_CHECKING DB_BLOCK_CHECKSUM +syn keyword oraKeyword DB_BLOCK_LRU_LATCHES DB_BLOCK_MAX_DIRTY_TARGET +syn keyword oraKeyword DB_BLOCK_SIZE DB_DOMAIN +syn keyword oraKeyword DB_FILE_DIRECT_IO_COUNT DB_FILE_MULTIBLOCK_READ_COUNT +syn keyword oraKeyword DB_FILE_NAME_CONVERT DB_FILE_SIMULTANEOUS_WRITES +syn keyword oraKeyword DB_FILES DB_NAME DB_WRITER_PROCESSES +syn keyword oraKeyword DBLINK_ENCRYPT_LOGIN DBWR_IO_SLAVES +syn keyword oraKeyword DELAYED_LOGGING_BLOCK_CLEANOUTS DISCRETE_TRANSACTIONS_ENABLED +syn keyword oraKeyword DISK_ASYNCH_IO DISTRIBUTED_TRANSACTIONS +syn keyword oraKeyword DML_LOCKS ENQUEUE_RESOURCES ENT_DOMAIN_NAME EVENT +syn keyword oraKeyword FAST_START_IO_TARGET FAST_START_PARALLEL_ROLLBACK +syn keyword oraKeyword FIXED_DATE FREEZE_DB_FOR_FAST_INSTANCE_RECOVERY +syn keyword oraKeyword GC_DEFER_TIME GC_FILES_TO_LOCKS GC_RELEASABLE_LOCKS GC_ROLLBACK_LOCKS +syn keyword oraKeyword GLOBAL_NAMES HASH_AREA_SIZE +syn keyword oraKeyword HASH_JOIN_ENABLED HASH_MULTIBLOCK_IO_COUNT +syn keyword oraKeyword HI_SHARED_MEMORY_ADDRESS HS_AUTOREGISTER +syn keyword oraKeyword IFILE +syn keyword oraKeyword INSTANCE_GROUPS INSTANCE_NAME INSTANCE_NUMBER +syn keyword oraKeyword JAVA_POOL_SIZE JOB_QUEUE_INTERVAL JOB_QUEUE_PROCESSES LARGE_POOL_SIZE +syn keyword oraKeyword LICENSE_MAX_SESSIONS LICENSE_MAX_USERS LICENSE_SESSIONS_WARNING +syn keyword oraKeyword LM_LOCKS LM_PROCS LM_RESS +syn keyword oraKeyword LOCAL_LISTENER LOCK_NAME_SPACE LOCK_SGA LOCK_SGA_AREAS +syn keyword oraKeyword LOG_ARCHIVE_BUFFER_SIZE LOG_ARCHIVE_BUFFERS LOG_ARCHIVE_DEST +syn match oraKeyword "LOG_ARCHIVE_DEST_\(1\|2\|3\|4\|5\)" +syn match oraKeyword "LOG_ARCHIVE_DEST_STATE_\(1\|2\|3\|4\|5\)" +syn keyword oraKeyword LOG_ARCHIVE_DUPLEX_DEST LOG_ARCHIVE_FORMAT LOG_ARCHIVE_MAX_PROCESSES +syn keyword oraKeyword LOG_ARCHIVE_MIN_SUCCEED_DEST LOG_ARCHIVE_START +syn keyword oraKeyword LOG_BUFFER LOG_CHECKPOINT_INTERVAL LOG_CHECKPOINT_TIMEOUT +syn keyword oraKeyword LOG_CHECKPOINTS_TO_ALERT LOG_FILE_NAME_CONVERT +syn keyword oraKeyword MAX_COMMIT_PROPAGATION_DELAY MAX_DUMP_FILE_SIZE +syn keyword oraKeyword MAX_ENABLED_ROLES MAX_ROLLBACK_SEGMENTS +syn keyword oraKeyword MTS_DISPATCHERS MTS_MAX_DISPATCHERS MTS_MAX_SERVERS MTS_SERVERS +syn keyword oraKeyword NLS_CALENDAR NLS_COMP NLS_CURRENCY NLS_DATE_FORMAT +syn keyword oraKeyword NLS_DATE_LANGUAGE NLS_DUAL_CURRENCY NLS_ISO_CURRENCY NLS_LANGUAGE +syn keyword oraKeyword NLS_NUMERIC_CHARACTERS NLS_SORT NLS_TERRITORY +syn keyword oraKeyword OBJECT_CACHE_MAX_SIZE_PERCENT OBJECT_CACHE_OPTIMAL_SIZE +syn keyword oraKeyword OPEN_CURSORS OPEN_LINKS OPEN_LINKS_PER_INSTANCE +syn keyword oraKeyword OPS_ADMINISTRATION_GROUP +syn keyword oraKeyword OPTIMIZER_FEATURES_ENABLE OPTIMIZER_INDEX_CACHING +syn keyword oraKeyword OPTIMIZER_INDEX_COST_ADJ OPTIMIZER_MAX_PERMUTATIONS +syn keyword oraKeyword OPTIMIZER_MODE OPTIMIZER_PERCENT_PARALLEL +syn keyword oraKeyword OPTIMIZER_SEARCH_LIMIT +syn keyword oraKeyword ORACLE_TRACE_COLLECTION_NAME ORACLE_TRACE_COLLECTION_PATH +syn keyword oraKeyword ORACLE_TRACE_COLLECTION_SIZE ORACLE_TRACE_ENABLE +syn keyword oraKeyword ORACLE_TRACE_FACILITY_NAME ORACLE_TRACE_FACILITY_PATH +syn keyword oraKeyword OS_AUTHENT_PREFIX OS_ROLES +syn keyword oraKeyword PARALLEL_ADAPTIVE_MULTI_USER PARALLEL_AUTOMATIC_TUNING +syn keyword oraKeyword PARALLEL_BROADCAST_ENABLED PARALLEL_EXECUTION_MESSAGE_SIZE +syn keyword oraKeyword PARALLEL_INSTANCE_GROUP PARALLEL_MAX_SERVERS +syn keyword oraKeyword PARALLEL_MIN_PERCENT PARALLEL_MIN_SERVERS +syn keyword oraKeyword PARALLEL_SERVER PARALLEL_SERVER_INSTANCES PARALLEL_THREADS_PER_CPU +syn keyword oraKeyword PARTITION_VIEW_ENABLED PLSQL_V2_COMPATIBILITY +syn keyword oraKeyword PRE_PAGE_SGA PROCESSES +syn keyword oraKeyword QUERY_REWRITE_ENABLED QUERY_REWRITE_INTEGRITY +syn keyword oraKeyword RDBMS_SERVER_DN READ_ONLY_OPEN_DELAYED RECOVERY_PARALLELISM +syn keyword oraKeyword REMOTE_DEPENDENCIES_MODE REMOTE_LOGIN_PASSWORDFILE +syn keyword oraKeyword REMOTE_OS_AUTHENT REMOTE_OS_ROLES +syn keyword oraKeyword REPLICATION_DEPENDENCY_TRACKING +syn keyword oraKeyword RESOURCE_LIMIT RESOURCE_MANAGER_PLAN +syn keyword oraKeyword ROLLBACK_SEGMENTS ROW_LOCKING SERIAL _REUSE SERVICE_NAMES +syn keyword oraKeyword SESSION_CACHED_CURSORS SESSION_MAX_OPEN_FILES SESSIONS +syn keyword oraKeyword SHADOW_CORE_DUMP +syn keyword oraKeyword SHARED_MEMORY_ADDRESS SHARED_POOL_RESERVED_SIZE SHARED_POOL_SIZE +syn keyword oraKeyword SORT_AREA_RETAINED_SIZE SORT_AREA_SIZE SORT_MULTIBLOCK_READ_COUNT +syn keyword oraKeyword SQL92_SECURITY SQL_TRACE STANDBY_ARCHIVE_DEST +syn keyword oraKeyword STAR_TRANSFORMATION_ENABLED TAPE_ASYNCH_IO THREAD +syn keyword oraKeyword TIMED_OS_STATISTICS TIMED_STATISTICS +syn keyword oraKeyword TRANSACTION_AUDITING TRANSACTIONS TRANSACTIONS_PER_ROLLBACK_SEGMENT +syn keyword oraKeyword USE_INDIRECT_DATA_BUFFERS USER_DUMP_DEST +syn keyword oraKeyword UTL_FILE_DIR +syn keyword oraKeywordObs ALLOW_PARTIAL_SN_RESULTS B_TREE_BITMAP_PLANS +syn keyword oraKeywordObs BACKUP_DISK_IO_SLAVES CACHE_SIZE_THRESHOLD +syn keyword oraKeywordObs CCF_IO_SIZE CLEANUP_ROLLBACK_ENTRIES +syn keyword oraKeywordObs CLOSE_CACHED_OPEN_CURSORS COMPATIBLE_NO_RECOVERY +syn keyword oraKeywordObs COMPLEX_VIEW_MERGING +syn keyword oraKeywordObs DB_BLOCK_CHECKPOINT_BATCH DB_BLOCK_LRU_EXTENDED_STATISTICS +syn keyword oraKeywordObs DB_BLOCK_LRU_STATISTICS +syn keyword oraKeywordObs DISTRIBUTED_LOCK_TIMEOUT DISTRIBUTED_RECOVERY_CONNECTION_HOLD_TIME +syn keyword oraKeywordObs FAST_FULL_SCAN_ENABLED GC_LATCHES GC_LCK_PROCS +syn keyword oraKeywordObs LARGE_POOL_MIN_ALLOC LGWR_IO_SLAVES +syn keyword oraKeywordObs LOG_BLOCK_CHECKSUM LOG_FILES +syn keyword oraKeywordObs LOG_SIMULTANEOUS_COPIES LOG_SMALL_ENTRY_MAX_SIZE +syn keyword oraKeywordObs MAX_TRANSACTION_BRANCHES +syn keyword oraKeywordObs MTS_LISTENER_ADDRESS MTS_MULTIPLE_LISTENERS +syn keyword oraKeywordObs MTS_RATE_LOG_SIZE MTS_RATE_SCALE MTS_SERVICE +syn keyword oraKeywordObs OGMS_HOME OPS_ADMIN_GROUP +syn keyword oraKeywordObs PARALLEL_DEFAULT_MAX_INSTANCES PARALLEL_MIN_MESSAGE_POOL +syn keyword oraKeywordObs PARALLEL_SERVER_IDLE_TIME PARALLEL_TRANSACTION_RESOURCE_TIMEOUT +syn keyword oraKeywordObs PUSH_JOIN_PREDICATE REDUCE_ALARM ROW_CACHE_CURSORS +syn keyword oraKeywordObs SEQUENCE_CACHE_ENTRIES SEQUENCE_CACHE_HASH_BUCKETS +syn keyword oraKeywordObs SHARED_POOL_RESERVED_MIN_ALLOC +syn keyword oraKeywordObs SORT_DIRECT_WRITES SORT_READ_FAC SORT_SPACEMAP_SIZE +syn keyword oraKeywordObs SORT_WRITE_BUFFER_SIZE SORT_WRITE_BUFFERS +syn keyword oraKeywordObs SPIN_COUNT TEMPORARY_TABLE_LOCKS USE_ISM +syn keyword oraValue db os full partial mandatory optional reopen enable defer +syn keyword oraValue always default intent disable dml plsql temp_disable +syn match oravalue "Arabic Hijrah" +syn match oravalue "English Hijrah" +syn match oravalue "Gregorian" +syn match oravalue "Japanese Imperial" +syn match oravalue "Persian" +syn match oravalue "ROC Official" +syn match oravalue "Thai Buddha" +syn match oravalue "8.0.0" +syn match oravalue "8.0.3" +syn match oravalue "8.0.4" +syn match oravalue "8.1.3" +syn match oraModifier "archived log" +syn match oraModifier "backup corruption" +syn match oraModifier "backup datafile" +syn match oraModifier "backup piece " +syn match oraModifier "backup redo log" +syn match oraModifier "backup set" +syn match oraModifier "copy corruption" +syn match oraModifier "datafile copy" +syn match oraModifier "deleted object" +syn match oraModifier "loghistory" +syn match oraModifier "offline range" + +"undocumented init params +"up to 7.2 (inclusive) +syn keyword oraKeywordUndObs _latch_spin_count _trace_instance_termination +syn keyword oraKeywordUndObs _wakeup_timeout _lgwr_async_write +"7.3 +syn keyword oraKeywordUndObs _standby_lock_space_name _enable_dba_locking +"8.0.5 +syn keyword oraKeywordUnd _NUMA_instance_mapping _NUMA_pool_size +syn keyword oraKeywordUnd _advanced_dss_features _affinity_on _all_shared_dblinks +syn keyword oraKeywordUnd _allocate_creation_order _allow_resetlogs_corruption +syn keyword oraKeywordUnd _always_star_transformation _bump_highwater_mark_count +syn keyword oraKeywordUnd _column_elimination_off _controlfile_enqueue_timeout +syn keyword oraKeywordUnd _corrupt_blocks_on_stuck_recovery _corrupted_rollback_segments +syn keyword oraKeywordUnd _cr_deadtime _cursor_db_buffers_pinned +syn keyword oraKeywordUnd _db_block_cache_clone _db_block_cache_map _db_block_cache_protect +syn keyword oraKeywordUnd _db_block_hash_buckets _db_block_hi_priority_batch_size +syn keyword oraKeywordUnd _db_block_max_cr_dba _db_block_max_scan_cnt +syn keyword oraKeywordUnd _db_block_med_priority_batch_size _db_block_no_idle_writes +syn keyword oraKeywordUnd _db_block_write_batch _db_handles _db_handles_cached +syn keyword oraKeywordUnd _db_large_dirty_queue _db_no_mount_lock +syn keyword oraKeywordUnd _db_writer_histogram_statistics _db_writer_scan_depth +syn keyword oraKeywordUnd _db_writer_scan_depth_decrement _db_writer_scan_depth_increment +syn keyword oraKeywordUnd _disable_incremental_checkpoints +syn keyword oraKeywordUnd _disable_latch_free_SCN_writes_via_32cas +syn keyword oraKeywordUnd _disable_latch_free_SCN_writes_via_64cas +syn keyword oraKeywordUnd _disable_logging _disable_ntlog_events +syn keyword oraKeywordUnd _dss_cache_flush _dynamic_stats_threshold +syn keyword oraKeywordUnd _enable_cscn_caching _enable_default_affinity +syn keyword oraKeywordUnd _enqueue_debug_multi_instance _enqueue_hash +syn keyword oraKeywordUnd _enqueue_hash_chain_latches _enqueue_locks +syn keyword oraKeywordUnd _fifth_spare_parameter _first_spare_parameter _fourth_spare_parameter +syn keyword oraKeywordUnd _gc_class_locks _groupby_nopushdown_cut_ratio +syn keyword oraKeywordUnd _idl_conventional_index_maintenance _ignore_failed_escalates +syn keyword oraKeywordUnd _init_sql_file +syn keyword oraKeywordUnd _io_slaves_disabled _ioslave_batch_count _ioslave_issue_count +syn keyword oraKeywordUnd _kgl_bucket_count _kgl_latch_count _kgl_multi_instance_invalidation +syn keyword oraKeywordUnd _kgl_multi_instance_lock _kgl_multi_instance_pin +syn keyword oraKeywordUnd _latch_miss_stat_sid _latch_recovery_alignment _latch_wait_posting +syn keyword oraKeywordUnd _lm_ast_option _lm_direct_sends _lm_dlmd_procs _lm_domains _lm_groups +syn keyword oraKeywordUnd _lm_non_fault_tolerant _lm_send_buffers _lm_statistics _lm_xids +syn keyword oraKeywordUnd _log_blocks_during_backup _log_buffers_debug _log_checkpoint_recovery_check +syn keyword oraKeywordUnd _log_debug_multi_instance _log_entry_prebuild_threshold _log_io_size +syn keyword oraKeywordUnd _log_space_errors +syn keyword oraKeywordUnd _max_exponential_sleep _max_sleep_holding_latch +syn keyword oraKeywordUnd _messages _minimum_giga_scn _mts_load_constants _nested_loop_fudge +syn keyword oraKeywordUnd _no_objects _no_or_expansion +syn keyword oraKeywordUnd _number_cached_attributes _offline_rollback_segments _open_files_limit +syn keyword oraKeywordUnd _optimizer_undo_changes +syn keyword oraKeywordUnd _oracle_trace_events _oracle_trace_facility_version +syn keyword oraKeywordUnd _ordered_nested_loop _parallel_server_sleep_time +syn keyword oraKeywordUnd _passwordfile_enqueue_timeout _pdml_slaves_diff_part +syn keyword oraKeywordUnd _plsql_dump_buffer_events _predicate_elimination_enabled +syn keyword oraKeywordUnd _project_view_columns +syn keyword oraKeywordUnd _px_broadcast_fudge_factor _px_broadcast_trace _px_dop_limit_degree +syn keyword oraKeywordUnd _px_dop_limit_threshold _px_kxfr_granule_allocation _px_kxib_tracing +syn keyword oraKeywordUnd _release_insert_threshold _reuse_index_loop +syn keyword oraKeywordUnd _rollback_segment_count _rollback_segment_initial +syn keyword oraKeywordUnd _row_cache_buffer_size _row_cache_instance_locks +syn keyword oraKeywordUnd _save_escalates _scn_scheme +syn keyword oraKeywordUnd _second_spare_parameter _session_idle_bit_latches +syn keyword oraKeywordUnd _shared_session_sort_fetch_buffer _single_process +syn keyword oraKeywordUnd _small_table_threshold _sql_connect_capability_override +syn keyword oraKeywordUnd _sql_connect_capability_table +syn keyword oraKeywordUnd _test_param_1 _test_param_2 _test_param_3 +syn keyword oraKeywordUnd _third_spare_parameter _tq_dump_period +syn keyword oraKeywordUnd _trace_archive_dest _trace_archive_start _trace_block_size +syn keyword oraKeywordUnd _trace_buffers_per_process _trace_enabled _trace_events +syn keyword oraKeywordUnd _trace_file_size _trace_files_public _trace_flushing _trace_write_batch_size +syn keyword oraKeywordUnd _upconvert_from_ast _use_vector_post _wait_for_sync _walk_insert_threshold +"dunno which version; may be 8.1.x, may be obsoleted +syn keyword oraKeywordUndObs _arch_io_slaves _average_dirties_half_life _b_tree_bitmap_plans +syn keyword oraKeywordUndObs _backup_disk_io_slaves _backup_io_pool_size +syn keyword oraKeywordUndObs _cleanup_rollback_entries _close_cached_open_cursors +syn keyword oraKeywordUndObs _compatible_no_recovery _complex_view_merging +syn keyword oraKeywordUndObs _cpu_to_io _cr_server +syn keyword oraKeywordUndObs _db_aging_cool_count _db_aging_freeze_cr _db_aging_hot_criteria +syn keyword oraKeywordUndObs _db_aging_stay_count _db_aging_touch_time +syn keyword oraKeywordUndObs _db_percent_hot_default _db_percent_hot_keep _db_percent_hot_recycle +syn keyword oraKeywordUndObs _db_writer_chunk_writes _db_writer_max_writes +syn keyword oraKeywordUndObs _dbwr_async_io _dbwr_tracing +syn keyword oraKeywordUndObs _defer_multiple_waiters _discrete_transaction_enabled +syn keyword oraKeywordUndObs _distributed_lock_timeout _distributed_recovery _distribited_recovery_ +syn keyword oraKeywordUndObs _domain_index_batch_size _domain_index_dml_batch_size +syn keyword oraKeywordUndObs _enable_NUMA_optimization _enable_block_level_transaction_recovery +syn keyword oraKeywordUndObs _enable_list_io _enable_multiple_sampling +syn keyword oraKeywordUndObs _fairness_treshold _fast_full_scan_enabled _foreground_locks +syn keyword oraKeywordUndObs _full_pwise_join_enabled _gc_latches _gc_lck_procs +syn keyword oraKeywordUndObs _high_server_treshold _index_prefetch_factor _kcl_debug +syn keyword oraKeywordUndObs _kkfi_trace _large_pool_min_alloc _lazy_freelist_close _left_nested_loops_random +syn keyword oraKeywordUndObs _lgwr_async_io _lgwr_io_slaves _lock_sga_areas +syn keyword oraKeywordUndObs _log_archive_buffer_size _log_archive_buffers _log_simultaneous_copies +syn keyword oraKeywordUndObs _low_server_treshold _max_transaction_branches +syn keyword oraKeywordUndObs _mts_rate_log_size _mts_rate_scale +syn keyword oraKeywordUndObs _mview_cost_rewrite _mview_rewrite_2 +syn keyword oraKeywordUndObs _ncmb_readahead_enabled _ncmb_readahead_tracing +syn keyword oraKeywordUndObs _ogms_home +syn keyword oraKeywordUndObs _parallel_adaptive_max_users _parallel_default_max_instances +syn keyword oraKeywordUndObs _parallel_execution_message_align _parallel_fake_class_pct +syn keyword oraKeywordUndObs _parallel_load_bal_unit _parallel_load_balancing +syn keyword oraKeywordUndObs _parallel_min_message_pool _parallel_recovery_stopat +syn keyword oraKeywordUndObs _parallel_server_idle_time _parallelism_cost_fudge_factor +syn keyword oraKeywordUndObs _partial_pwise_join_enabled _pdml_separate_gim _push_join_predicate +syn keyword oraKeywordUndObs _px_granule_size _px_index_sampling _px_load_publish_interval +syn keyword oraKeywordUndObs _px_max_granules_per_slave _px_min_granules_per_slave _px_no_stealing +syn keyword oraKeywordUndObs _row_cache_cursors _serial_direct_read _shared_pool_reserved_min_alloc +syn keyword oraKeywordUndObs _sort_space_for_write_buffers _spin_count _system_trig_enabled +syn keyword oraKeywordUndObs _trace_buffer_flushes _trace_cr_buffer_creates _trace_multi_block_reads +syn keyword oraKeywordUndObs _transaction_recovery_servers _use_ism _yield_check_interval + + +syn cluster oraAll add=oraKeyword,oraKeywordGroup,oraKeywordPref,oraKeywordObs,oraKeywordUnd,oraKeywordUndObs +syn cluster oraAll add=oraValue,oraModifier,oraString,oraSpecial,oraComment + +"============================================================================== +" highlighting + +" Only when an item doesn't have highlighting yet + +hi def link oraKeyword Statement "usual keywords +hi def link oraKeywordGroup Type "keywords which group other keywords +hi def link oraKeywordPref oraKeywordGroup "keywords which act as prefixes +hi def link oraKeywordObs Todo "obsolete keywords +hi def link oraKeywordUnd PreProc "undocumented keywords +hi def link oraKeywordUndObs oraKeywordObs "undocumented obsolete keywords +hi def link oraValue Identifier "values, like true or false +hi def link oraModifier oraValue "modifies values +hi def link oraString String "strings + +hi def link oraSpecial Special "special characters +hi def link oraError Error "errors +hi def link oraParenError oraError "errors caused by mismatching parantheses + +hi def link oraComment Comment "comments + + + +let b:current_syntax = "ora" + +if main_syntax == 'ora' + unlet main_syntax +endif + +" vim: ts=8 + +endif diff --git a/syntax/pamconf.vim b/syntax/pamconf.vim new file mode 100644 index 0000000..11f4b28 --- /dev/null +++ b/syntax/pamconf.vim @@ -0,0 +1,124 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: pam(8) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2011-08-03 + + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match pamconfService '^[[:graph:]]\+' + \ nextgroup=pamconfType, + \ pamconfServiceLineCont skipwhite + +syn keyword pamconfTodo contained TODO FIXME XXX NOTE + +syn region pamconfComment display oneline start='#' end='$' + \ contains=pamconfTodo,@Spell + +syn match pamconfServiceLineCont contained '\\$' + \ nextgroup=pamconfType, + \ pamconfServiceLineCont skipwhite skipnl + +syn keyword pamconfType account auth password session + \ nextgroup=pamconfControl, + \ pamconfTypeLineCont skipwhite + +syn match pamconfTypeLineCont contained '\\$' + \ nextgroup=pamconfControl, + \ pamconfTypeLineCont skipwhite skipnl + +syn keyword pamconfControl contained requisite required sufficient + \ optional include substack + \ nextgroup=pamconfMPath, + \ pamconfControlLineContH skipwhite + +syn match pamconfControlBegin '\[' nextgroup=pamconfControlValues, + \ pamconfControlLineCont skipwhite + +syn match pamconfControlLineCont contained '\\$' + \ nextgroup=pamconfControlValues, + \ pamconfControlLineCont skipwhite skipnl + +syn keyword pamconfControlValues contained success open_err symbol_err + \ service_err system_err buf_err + \ perm_denied auth_err cred_insufficient + \ authinfo_unavail user_unknown maxtries + \ new_authtok_reqd acct_expired session_err + \ cred_unavail cred_expired cred_err + \ no_module_data conv_err authtok_err + \ authtok_recover_err authtok_lock_busy + \ authtok_disable_aging try_again ignore + \ abort authtok_expired module_unknown + \ bad_item and default + \ nextgroup=pamconfControlValueEq + +syn match pamconfControlValueEq contained '=' + \ nextgroup=pamconfControlActionN, + \ pamconfControlAction + +syn match pamconfControlActionN contained '\d\+\>' + \ nextgroup=pamconfControlValues, + \ pamconfControlLineCont,pamconfControlEnd + \ skipwhite +syn keyword pamconfControlAction contained ignore bad die ok done reset + \ nextgroup=pamconfControlValues, + \ pamconfControlLineCont,pamconfControlEnd + \ skipwhite + +syn match pamconfControlEnd contained '\]' + \ nextgroup=pamconfMPath, + \ pamconfControlLineContH skipwhite + +syn match pamconfControlLineContH contained '\\$' + \ nextgroup=pamconfMPath, + \ pamconfControlLineContH skipwhite skipnl + +syn match pamconfMPath contained '\S\+' + \ nextgroup=pamconfMPathLineCont, + \ pamconfArgs skipwhite + +syn match pamconfArgs contained '\S\+' + \ nextgroup=pamconfArgsLineCont, + \ pamconfArgs skipwhite + +syn match pamconfMPathLineCont contained '\\$' + \ nextgroup=pamconfMPathLineCont, + \ pamconfArgs skipwhite skipnl + +syn match pamconfArgsLineCont contained '\\$' + \ nextgroup=pamconfArgsLineCont, + \ pamconfArgs skipwhite skipnl + +hi def link pamconfTodo Todo +hi def link pamconfComment Comment +hi def link pamconfService Statement +hi def link pamconfServiceLineCont Special +hi def link pamconfType Type +hi def link pamconfTypeLineCont pamconfServiceLineCont +hi def link pamconfControl Macro +hi def link pamconfControlBegin Delimiter +hi def link pamconfControlLineContH pamconfServiceLineCont +hi def link pamconfControlLineCont pamconfServiceLineCont +hi def link pamconfControlValues Identifier +hi def link pamconfControlValueEq Operator +hi def link pamconfControlActionN Number +hi def link pamconfControlAction Identifier +hi def link pamconfControlEnd Delimiter +hi def link pamconfMPath String +hi def link pamconfMPathLineCont pamconfServiceLineCont +hi def link pamconfArgs Normal +hi def link pamconfArgsLineCont pamconfServiceLineCont + +let b:current_syntax = "pamconf" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/papp.vim b/syntax/papp.vim new file mode 100644 index 0000000..02a5743 --- /dev/null +++ b/syntax/papp.vim @@ -0,0 +1,80 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file for the "papp" file format (_p_erl _app_lication) +" +" Language: papp +" Maintainer: Marc Lehmann +" Last Change: 2009 Nov 11 +" Filenames: *.papp *.pxml *.pxsl +" URL: http://papp.plan9.de/ + +" You can set the "papp_include_html" variable so that html will be +" rendered as such inside phtml sections (in case you actually put html +" there - papp does not require that). Also, rendering html tends to keep +" the clutter high on the screen - mixing three languages is difficult +" enough(!). PS: it is also slow. + +" pod is, btw, allowed everywhere, which is actually wrong :( + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" source is basically xml, with included html (this is common) and perl bits +runtime! syntax/xml.vim +unlet b:current_syntax + +if exists("papp_include_html") + syn include @PAppHtml syntax/html.vim + unlet b:current_syntax + syntax spell default " added by Bram +endif + +syn include @PAppPerl syntax/perl.vim + +syn cluster xmlFoldCluster add=papp_perl,papp_xperl,papp_phtml,papp_pxml,papp_perlPOD + +" preprocessor commands +syn region papp_prep matchgroup=papp_prep start="^#\s*\(if\|elsif\)" end="$" keepend contains=@perlExpr contained +syn match papp_prep /^#\s*\(else\|endif\|??\).*$/ contained +" translation entries +syn region papp_gettext start=/__"/ end=/"/ contained contains=@papp_perlInterpDQ +syn cluster PAppHtml add=papp_gettext,papp_prep + +" add special, paired xperl, perl and phtml tags +syn region papp_perl matchgroup=xmlTag start="" end="" contains=papp_CDATAp,@PAppPerl keepend +syn region papp_xperl matchgroup=xmlTag start="" end="" contains=papp_CDATAp,@PAppPerl keepend +syn region papp_phtml matchgroup=xmlTag start="" end="" contains=papp_CDATAh,papp_ph_perl,papp_ph_html,papp_ph_hint,@PAppHtml keepend +syn region papp_pxml matchgroup=xmlTag start="" end="" contains=papp_CDATAx,papp_ph_perl,papp_ph_xml,papp_ph_xint keepend +syn region papp_perlPOD start="^=[a-z]" end="^=cut" contains=@Pod,perlTodo keepend + +" cdata sections +syn region papp_CDATAp matchgroup=xmlCdataDecl start="" contains=@PAppPerl contained keepend +syn region papp_CDATAh matchgroup=xmlCdataDecl start="" contains=papp_ph_perl,papp_ph_html,papp_ph_hint,@PAppHtml contained keepend +syn region papp_CDATAx matchgroup=xmlCdataDecl start="" contains=papp_ph_perl,papp_ph_xml,papp_ph_xint contained keepend + +syn region papp_ph_perl matchgroup=Delimiter start="<[:?]" end="[:?]>"me=e-2 nextgroup=papp_ph_html contains=@PAppPerl contained keepend +syn region papp_ph_html matchgroup=Delimiter start=":>" end="<[:?]"me=e-2 nextgroup=papp_ph_perl contains=@PAppHtml contained keepend +syn region papp_ph_hint matchgroup=Delimiter start="?>" end="<[:?]"me=e-2 nextgroup=papp_ph_perl contains=@perlInterpDQ,@PAppHtml contained keepend +syn region papp_ph_xml matchgroup=Delimiter start=":>" end="<[:?]"me=e-2 nextgroup=papp_ph_perl contains= contained keepend +syn region papp_ph_xint matchgroup=Delimiter start="?>" end="<[:?]"me=e-2 nextgroup=papp_ph_perl contains=@perlInterpDQ contained keepend + +" synchronization is horrors! +syn sync clear +syn sync match pappSync grouphere papp_CDATAh "" +syn sync match pappSync grouphere papp_CDATAh "^# *\(if\|elsif\|else\|endif\)" +syn sync match pappSync grouphere papp_CDATAh "" +syn sync match pappSync grouphere NONE "" + +syn sync maxlines=300 +syn sync minlines=5 + +" The default highlighting. + +hi def link papp_prep preCondit +hi def link papp_gettext String + +let b:current_syntax = "papp" + +endif diff --git a/syntax/pascal.vim b/syntax/pascal.vim new file mode 100644 index 0000000..d902fcc --- /dev/null +++ b/syntax/pascal.vim @@ -0,0 +1,364 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Pascal +" Version: 2.8 +" Last Change: 2004/10/17 17:47:30 +" Maintainer: Xavier Crégut +" Previous Maintainer: Mario Eusebio + +" Contributors: Tim Chase , +" Stas Grabois , +" Mazen NEIFER , +" Klaus Hast , +" Austin Ziegler , +" Markus Koenig + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +syn case ignore +syn sync lines=250 + +syn keyword pascalBoolean true false +syn keyword pascalConditional if else then +syn keyword pascalConstant nil maxint +syn keyword pascalLabel case goto label +syn keyword pascalOperator and div downto in mod not of or packed with +syn keyword pascalRepeat do for do repeat while to until +syn keyword pascalStatement procedure function +syn keyword pascalStatement program begin end const var type +syn keyword pascalStruct record +syn keyword pascalType array boolean char integer file pointer real set +syn keyword pascalType string text variant + + + " 20011222az: Added new items. +syn keyword pascalTodo contained TODO FIXME XXX DEBUG NOTE + + " 20010723az: When wanted, highlight the trailing whitespace -- this is + " based on c_space_errors; to enable, use "pascal_space_errors". +if exists("pascal_space_errors") + if !exists("pascal_no_trail_space_error") + syn match pascalSpaceError "\s\+$" + endif + if !exists("pascal_no_tab_space_error") + syn match pascalSpaceError " \+\t"me=e-1 + endif +endif + + + +" String +if !exists("pascal_one_line_string") + syn region pascalString matchgroup=pascalString start=+'+ end=+'+ contains=pascalStringEscape + if exists("pascal_gpc") + syn region pascalString matchgroup=pascalString start=+"+ end=+"+ contains=pascalStringEscapeGPC + else + syn region pascalStringError matchgroup=pascalStringError start=+"+ end=+"+ contains=pascalStringEscape + endif +else + "wrong strings + syn region pascalStringError matchgroup=pascalStringError start=+'+ end=+'+ end=+$+ contains=pascalStringEscape + if exists("pascal_gpc") + syn region pascalStringError matchgroup=pascalStringError start=+"+ end=+"+ end=+$+ contains=pascalStringEscapeGPC + else + syn region pascalStringError matchgroup=pascalStringError start=+"+ end=+"+ end=+$+ contains=pascalStringEscape + endif + + "right strings + syn region pascalString matchgroup=pascalString start=+'+ end=+'+ oneline contains=pascalStringEscape + " To see the start and end of strings: + " syn region pascalString matchgroup=pascalStringError start=+'+ end=+'+ oneline contains=pascalStringEscape + if exists("pascal_gpc") + syn region pascalString matchgroup=pascalString start=+"+ end=+"+ oneline contains=pascalStringEscapeGPC + else + syn region pascalStringError matchgroup=pascalStringError start=+"+ end=+"+ oneline contains=pascalStringEscape + endif +end +syn match pascalStringEscape contained "''" +syn match pascalStringEscapeGPC contained '""' + + +" syn match pascalIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>" + + +if exists("pascal_symbol_operator") + syn match pascalSymbolOperator "[+\-/*=]" + syn match pascalSymbolOperator "[<>]=\=" + syn match pascalSymbolOperator "<>" + syn match pascalSymbolOperator ":=" + syn match pascalSymbolOperator "[()]" + syn match pascalSymbolOperator "\.\." + syn match pascalSymbolOperator "[\^.]" + syn match pascalMatrixDelimiter "[][]" + "if you prefer you can highlight the range + "syn match pascalMatrixDelimiter "[\d\+\.\.\d\+]" +endif + +syn match pascalNumber "-\=\<\d\+\>" +syn match pascalFloat "-\=\<\d\+\.\d\+\>" +syn match pascalFloat "-\=\<\d\+\.\d\+[eE]-\=\d\+\>" +syn match pascalHexNumber "\$[0-9a-fA-F]\+\>" + +if exists("pascal_no_tabs") + syn match pascalShowTab "\t" +endif + +syn region pascalComment start="(\*\|{" end="\*)\|}" contains=pascalTodo,pascalSpaceError + + +if !exists("pascal_no_functions") + " array functions + syn keyword pascalFunction pack unpack + + " memory function + syn keyword pascalFunction Dispose New + + " math functions + syn keyword pascalFunction Abs Arctan Cos Exp Ln Sin Sqr Sqrt + + " file functions + syn keyword pascalFunction Eof Eoln Write Writeln + syn keyword pascalPredefined Input Output + + if exists("pascal_traditional") + " These functions do not seem to be defined in Turbo Pascal + syn keyword pascalFunction Get Page Put + endif + + " ordinal functions + syn keyword pascalFunction Odd Pred Succ + + " transfert functions + syn keyword pascalFunction Chr Ord Round Trunc +endif + + +if !exists("pascal_traditional") + + syn keyword pascalStatement constructor destructor implementation inherited + syn keyword pascalStatement interface unit uses + syn keyword pascalModifier absolute assembler external far forward inline + syn keyword pascalModifier interrupt near virtual + syn keyword pascalAcces private public + syn keyword pascalStruct object + syn keyword pascalOperator shl shr xor + + syn region pascalPreProc start="(\*\$" end="\*)" contains=pascalTodo + syn region pascalPreProc start="{\$" end="}" + + syn region pascalAsm matchgroup=pascalAsmKey start="\" end="\" contains=pascalComment,pascalPreProc + + syn keyword pascalType ShortInt LongInt Byte Word + syn keyword pascalType ByteBool WordBool LongBool + syn keyword pascalType Cardinal LongWord + syn keyword pascalType Single Double Extended Comp + syn keyword pascalType PChar + + + if !exists ("pascal_fpc") + syn keyword pascalPredefined Result + endif + + if exists("pascal_fpc") + syn region pascalComment start="//" end="$" contains=pascalTodo,pascalSpaceError + syn keyword pascalStatement fail otherwise operator + syn keyword pascalDirective popstack + syn keyword pascalPredefined self + syn keyword pascalType ShortString AnsiString WideString + endif + + if exists("pascal_gpc") + syn keyword pascalType SmallInt + syn keyword pascalType AnsiChar + syn keyword pascalType PAnsiChar + endif + + if exists("pascal_delphi") + syn region pascalComment start="//" end="$" contains=pascalTodo,pascalSpaceError + syn keyword pascalType SmallInt Int64 + syn keyword pascalType Real48 Currency + syn keyword pascalType AnsiChar WideChar + syn keyword pascalType ShortString AnsiString WideString + syn keyword pascalType PAnsiChar PWideChar + syn match pascalFloat "-\=\<\d\+\.\d\+[dD]-\=\d\+\>" + syn match pascalStringEscape contained "#[12][0-9]\=[0-9]\=" + syn keyword pascalStruct class dispinterface + syn keyword pascalException try except raise at on finally + syn keyword pascalStatement out + syn keyword pascalStatement library package + syn keyword pascalStatement initialization finalization uses exports + syn keyword pascalStatement property out resourcestring threadvar + syn keyword pascalModifier contains + syn keyword pascalModifier overridden reintroduce abstract + syn keyword pascalModifier override export dynamic name message + syn keyword pascalModifier dispid index stored default nodefault readonly + syn keyword pascalModifier writeonly implements overload requires resident + syn keyword pascalAcces protected published automated + syn keyword pascalDirective register pascal cvar cdecl stdcall safecall + syn keyword pascalOperator as is + endif + + if exists("pascal_no_functions") + "syn keyword pascalModifier read write + "may confuse with Read and Write functions. Not easy to handle. + else + " control flow functions + syn keyword pascalFunction Break Continue Exit Halt RunError + + " ordinal functions + syn keyword pascalFunction Dec Inc High Low + + " math functions + syn keyword pascalFunction Frac Int Pi + + " string functions + syn keyword pascalFunction Concat Copy Delete Insert Length Pos Str Val + + " memory function + syn keyword pascalFunction FreeMem GetMem MaxAvail MemAvail + + " pointer and address functions + syn keyword pascalFunction Addr Assigned CSeg DSeg Ofs Ptr Seg SPtr SSeg + + " misc functions + syn keyword pascalFunction Exclude FillChar Hi Include Lo Move ParamCount + syn keyword pascalFunction ParamStr Random Randomize SizeOf Swap TypeOf + syn keyword pascalFunction UpCase + + " predefined variables + syn keyword pascalPredefined ErrorAddr ExitCode ExitProc FileMode FreeList + syn keyword pascalPredefined FreeZero HeapEnd HeapError HeapOrg HeapPtr + syn keyword pascalPredefined InOutRes OvrCodeList OvrDebugPtr OvrDosHandle + syn keyword pascalPredefined OvrEmsHandle OvrHeapEnd OvrHeapOrg OvrHeapPtr + syn keyword pascalPredefined OvrHeapSize OvrLoadList PrefixSeg RandSeed + syn keyword pascalPredefined SaveInt00 SaveInt02 SaveInt1B SaveInt21 + syn keyword pascalPredefined SaveInt23 SaveInt24 SaveInt34 SaveInt35 + syn keyword pascalPredefined SaveInt36 SaveInt37 SaveInt38 SaveInt39 + syn keyword pascalPredefined SaveInt3A SaveInt3B SaveInt3C SaveInt3D + syn keyword pascalPredefined SaveInt3E SaveInt3F SaveInt75 SegA000 SegB000 + syn keyword pascalPredefined SegB800 SelectorInc StackLimit Test8087 + + " file functions + syn keyword pascalFunction Append Assign BlockRead BlockWrite ChDir Close + syn keyword pascalFunction Erase FilePos FileSize Flush GetDir IOResult + syn keyword pascalFunction MkDir Read Readln Rename Reset Rewrite RmDir + syn keyword pascalFunction Seek SeekEof SeekEoln SetTextBuf Truncate + + " crt unit + syn keyword pascalFunction AssignCrt ClrEol ClrScr Delay DelLine GotoXY + syn keyword pascalFunction HighVideo InsLine KeyPressed LowVideo NormVideo + syn keyword pascalFunction NoSound ReadKey Sound TextBackground TextColor + syn keyword pascalFunction TextMode WhereX WhereY Window + syn keyword pascalPredefined CheckBreak CheckEOF CheckSnow DirectVideo + syn keyword pascalPredefined LastMode TextAttr WindMin WindMax + syn keyword pascalFunction BigCursor CursorOff CursorOn + syn keyword pascalConstant Black Blue Green Cyan Red Magenta Brown + syn keyword pascalConstant LightGray DarkGray LightBlue LightGreen + syn keyword pascalConstant LightCyan LightRed LightMagenta Yellow White + syn keyword pascalConstant Blink ScreenWidth ScreenHeight bw40 + syn keyword pascalConstant co40 bw80 co80 mono + syn keyword pascalPredefined TextChar + + " DOS unit + syn keyword pascalFunction AddDisk DiskFree DiskSize DosExitCode DosVersion + syn keyword pascalFunction EnvCount EnvStr Exec Expand FindClose FindFirst + syn keyword pascalFunction FindNext FSearch FSplit GetCBreak GetDate + syn keyword pascalFunction GetEnv GetFAttr GetFTime GetIntVec GetTime + syn keyword pascalFunction GetVerify Intr Keep MSDos PackTime SetCBreak + syn keyword pascalFunction SetDate SetFAttr SetFTime SetIntVec SetTime + syn keyword pascalFunction SetVerify SwapVectors UnPackTime + syn keyword pascalConstant FCarry FParity FAuxiliary FZero FSign FOverflow + syn keyword pascalConstant Hidden Sysfile VolumeId Directory Archive + syn keyword pascalConstant AnyFile fmClosed fmInput fmOutput fmInout + syn keyword pascalConstant TextRecNameLength TextRecBufSize + syn keyword pascalType ComStr PathStr DirStr NameStr ExtStr SearchRec + syn keyword pascalType FileRec TextBuf TextRec Registers DateTime + syn keyword pascalPredefined DosError + + "Graph Unit + syn keyword pascalFunction Arc Bar Bar3D Circle ClearDevice ClearViewPort + syn keyword pascalFunction CloseGraph DetectGraph DrawPoly Ellipse + syn keyword pascalFunction FillEllipse FillPoly FloodFill GetArcCoords + syn keyword pascalFunction GetAspectRatio GetBkColor GetColor + syn keyword pascalFunction GetDefaultPalette GetDriverName GetFillPattern + syn keyword pascalFunction GetFillSettings GetGraphMode GetImage + syn keyword pascalFunction GetLineSettings GetMaxColor GetMaxMode GetMaxX + syn keyword pascalFunction GetMaxY GetModeName GetModeRange GetPalette + syn keyword pascalFunction GetPaletteSize GetPixel GetTextSettings + syn keyword pascalFunction GetViewSettings GetX GetY GraphDefaults + syn keyword pascalFunction GraphErrorMsg GraphResult ImageSize InitGraph + syn keyword pascalFunction InstallUserDriver InstallUserFont Line LineRel + syn keyword pascalFunction LineTo MoveRel MoveTo OutText OutTextXY + syn keyword pascalFunction PieSlice PutImage PutPixel Rectangle + syn keyword pascalFunction RegisterBGIDriver RegisterBGIFont + syn keyword pascalFunction RestoreCRTMode Sector SetActivePage + syn keyword pascalFunction SetAllPallette SetAspectRatio SetBkColor + syn keyword pascalFunction SetColor SetFillPattern SetFillStyle + syn keyword pascalFunction SetGraphBufSize SetGraphMode SetLineStyle + syn keyword pascalFunction SetPalette SetRGBPalette SetTextJustify + syn keyword pascalFunction SetTextStyle SetUserCharSize SetViewPort + syn keyword pascalFunction SetVisualPage SetWriteMode TextHeight TextWidth + syn keyword pascalType ArcCoordsType FillPatternType FillSettingsType + syn keyword pascalType LineSettingsType PaletteType PointType + syn keyword pascalType TextSettingsType ViewPortType + + " string functions + syn keyword pascalFunction StrAlloc StrBufSize StrCat StrComp StrCopy + syn keyword pascalFunction StrDispose StrECopy StrEnd StrFmt StrIComp + syn keyword pascalFunction StrLCat StrLComp StrLCopy StrLen StrLFmt + syn keyword pascalFunction StrLIComp StrLower StrMove StrNew StrPas + syn keyword pascalFunction StrPCopy StrPLCopy StrPos StrRScan StrScan + syn keyword pascalFunction StrUpper + endif + +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link pascalAcces pascalStatement +hi def link pascalBoolean Boolean +hi def link pascalComment Comment +hi def link pascalConditional Conditional +hi def link pascalConstant Constant +hi def link pascalDelimiter Identifier +hi def link pascalDirective pascalStatement +hi def link pascalException Exception +hi def link pascalFloat Float +hi def link pascalFunction Function +hi def link pascalLabel Label +hi def link pascalMatrixDelimiter Identifier +hi def link pascalModifier Type +hi def link pascalNumber Number +hi def link pascalOperator Operator +hi def link pascalPredefined pascalStatement +hi def link pascalPreProc PreProc +hi def link pascalRepeat Repeat +hi def link pascalSpaceError Error +hi def link pascalStatement Statement +hi def link pascalString String +hi def link pascalStringEscape Special +hi def link pascalStringEscapeGPC Special +hi def link pascalStringError Error +hi def link pascalStruct pascalStatement +hi def link pascalSymbolOperator pascalOperator +hi def link pascalTodo Todo +hi def link pascalType Type +hi def link pascalUnclassified pascalStatement +" hi def link pascalAsm Assembler +hi def link pascalError Error +hi def link pascalAsmKey pascalStatement +hi def link pascalShowTab Error + + + +let b:current_syntax = "pascal" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/passwd.vim b/syntax/passwd.vim new file mode 100644 index 0000000..cee1eec --- /dev/null +++ b/syntax/passwd.vim @@ -0,0 +1,75 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: passwd(5) password file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-10-03 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match passwdBegin display '^' nextgroup=passwdAccount + +syn match passwdAccount contained display '[^:]\+' + \ nextgroup=passwdPasswordColon + +syn match passwdPasswordColon contained display ':' + \ nextgroup=passwdPassword,passwdShadow + +syn match passwdPassword contained display '[^:]\+' + \ nextgroup=passwdUIDColon + +syn match passwdShadow contained display '[x*!]' + \ nextgroup=passwdUIDColon + +syn match passwdUIDColon contained display ':' nextgroup=passwdUID + +syn match passwdUID contained display '\d\{0,10}' + \ nextgroup=passwdGIDColon + +syn match passwdGIDColon contained display ':' nextgroup=passwdGID + +syn match passwdGID contained display '\d\{0,10}' + \ nextgroup=passwdGecosColon + +syn match passwdGecosColon contained display ':' nextgroup=passwdGecos + +syn match passwdGecos contained display '[^:]*' + \ nextgroup=passwdDirColon + +syn match passwdDirColon contained display ':' nextgroup=passwdDir + +syn match passwdDir contained display '/[^:]*' + \ nextgroup=passwdShellColon + +syn match passwdShellColon contained display ':' + \ nextgroup=passwdShell + +syn match passwdShell contained display '.*' + +hi def link passwdColon Normal +hi def link passwdAccount Identifier +hi def link passwdPasswordColon passwdColon +hi def link passwdPassword Number +hi def link passwdShadow Special +hi def link passwdUIDColon passwdColon +hi def link passwdUID Number +hi def link passwdGIDColon passwdColon +hi def link passwdGID Number +hi def link passwdGecosColon passwdColon +hi def link passwdGecos Comment +hi def link passwdDirColon passwdColon +hi def link passwdDir Type +hi def link passwdShellColon passwdColon +hi def link passwdShell Operator + +let b:current_syntax = "passwd" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/pcap.vim b/syntax/pcap.vim new file mode 100644 index 0000000..9ec36b0 --- /dev/null +++ b/syntax/pcap.vim @@ -0,0 +1,52 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Config file: printcap +" Maintainer: Lennart Schultz (defunct) +" Modified by Bram +" Last Change: 2003 May 11 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +"define keywords +setlocal isk=@,46-57,_,-,#,=,192-255 + +"first all the bad guys +syn match pcapBad '^.\+$' "define any line as bad +syn match pcapBadword '\k\+' contained "define any sequence of keywords as bad +syn match pcapBadword ':' contained "define any single : as bad +syn match pcapBadword '\\' contained "define any single \ as bad +"then the good boys +" Boolean keywords +syn match pcapKeyword contained ':\(fo\|hl\|ic\|rs\|rw\|sb\|sc\|sf\|sh\)' +" Numeric Keywords +syn match pcapKeyword contained ':\(br\|du\|fc\|fs\|mx\|pc\|pl\|pw\|px\|py\|xc\|xs\)#\d\+' +" String Keywords +syn match pcapKeyword contained ':\(af\|cf\|df\|ff\|gf\|if\|lf\|lo\|lp\|nd\|nf\|of\|rf\|rg\|rm\|rp\|sd\|st\|tf\|tr\|vf\)=\k*' +" allow continuation +syn match pcapEnd ':\\$' contained +" +syn match pcapDefineLast '^\s.\+$' contains=pcapBadword,pcapKeyword +syn match pcapDefine '^\s.\+$' contains=pcapBadword,pcapKeyword,pcapEnd +syn match pcapHeader '^\k[^|]\+\(|\k[^|]\+\)*:\\$' +syn match pcapComment "#.*$" + +syn sync minlines=50 + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link pcapBad WarningMsg +hi def link pcapBadword WarningMsg +hi def link pcapComment Comment + + +let b:current_syntax = "pcap" + +" vim: ts=8 + +endif diff --git a/syntax/pccts.vim b/syntax/pccts.vim new file mode 100644 index 0000000..89f253c --- /dev/null +++ b/syntax/pccts.vim @@ -0,0 +1,93 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PCCTS +" Maintainer: Scott Bigham +" Last Change: 10 Aug 1999 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read the C++ syntax to start with +syn include @cppTopLevel syntax/cpp.vim + +syn region pcctsAction matchgroup=pcctsDelim start="<<" end=">>?\=" contains=@cppTopLevel,pcctsRuleRef + +syn region pcctsArgBlock matchgroup=pcctsDelim start="\(>\s*\)\=\[" end="\]" contains=@cppTopLevel,pcctsRuleRef + +syn region pcctsString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=pcctsSpecialChar +syn match pcctsSpecialChar "\\\\\|\\\"" contained + +syn region pcctsComment start="/\*" end="\*/" contains=cTodo +syn match pcctsComment "//.*$" contains=cTodo + +syn region pcctsDirective start="^\s*#header\s\+<<" end=">>" contains=pcctsAction keepend +syn match pcctsDirective "^\s*#parser\>.*$" contains=pcctsString,pcctsComment +syn match pcctsDirective "^\s*#tokdefs\>.*$" contains=pcctsString,pcctsComment +syn match pcctsDirective "^\s*#token\>.*$" contains=pcctsString,pcctsAction,pcctsTokenName,pcctsComment +syn region pcctsDirective start="^\s*#tokclass\s\+[A-Z]\i*\s\+{" end="}" contains=pcctsString,pcctsTokenName +syn match pcctsDirective "^\s*#lexclass\>.*$" contains=pcctsTokenName +syn region pcctsDirective start="^\s*#errclass\s\+[^{]\+\s\+{" end="}" contains=pcctsString,pcctsTokenName +syn match pcctsDirective "^\s*#pred\>.*$" contains=pcctsTokenName,pcctsAction + +syn cluster pcctsInRule contains=pcctsString,pcctsRuleName,pcctsTokenName,pcctsAction,pcctsArgBlock,pcctsSubRule,pcctsLabel,pcctsComment + +syn region pcctsRule start="\<[a-z][A-Za-z0-9_]*\>\(\s*\[[^]]*\]\)\=\(\s*>\s*\[[^]]*\]\)\=\s*:" end=";" contains=@pcctsInRule + +syn region pcctsSubRule matchgroup=pcctsDelim start="(" end=")\(+\|\*\|?\(\s*=>\)\=\)\=" contains=@pcctsInRule contained +syn region pcctsSubRule matchgroup=pcctsDelim start="{" end="}" contains=@pcctsInRule contained + +syn match pcctsRuleName "\<[a-z]\i*\>" contained +syn match pcctsTokenName "\<[A-Z]\i*\>" contained + +syn match pcctsLabel "\<\I\i*:\I\i*" contained contains=pcctsLabelHack,pcctsRuleName,pcctsTokenName +syn match pcctsLabel "\<\I\i*:\"\([^\\]\|\\.\)*\"" contained contains=pcctsLabelHack,pcctsString +syn match pcctsLabelHack "\<\I\i*:" contained + +syn match pcctsRuleRef "\$\I\i*\>" contained +syn match pcctsRuleRef "\$\d\+\(\.\d\+\)\>" contained + +syn keyword pcctsClass class nextgroup=pcctsClassName skipwhite +syn match pcctsClassName "\<\I\i*\>" contained nextgroup=pcctsClassBlock skipwhite skipnl +syn region pcctsClassBlock start="{" end="}" contained contains=pcctsRule,pcctsComment,pcctsDirective,pcctsAction,pcctsException,pcctsExceptionHandler + +syn keyword pcctsException exception nextgroup=pcctsExceptionRuleRef skipwhite +syn match pcctsExceptionRuleRef "\[\I\i*\]" contained contains=pcctsExceptionID +syn match pcctsExceptionID "\I\i*" contained +syn keyword pcctsExceptionHandler catch default +syn keyword pcctsExceptionHandler NoViableAlt NoSemViableAlt +syn keyword pcctsExceptionHandler MismatchedToken + +syn sync clear +syn sync match pcctsSyncAction grouphere pcctsAction "<<" +syn sync match pcctsSyncAction "<<\([^>]\|>[^>]\)*>>" +syn sync match pcctsSyncRule grouphere pcctsRule "\<[a-z][A-Za-z0-9_]*\>\s*\[[^]]*\]\s*:" +syn sync match pcctsSyncRule grouphere pcctsRule "\<[a-z][A-Za-z0-9_]*\>\(\s*\[[^]]*\]\)\=\s*>\s*\[[^]]*\]\s*:" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link pcctsDelim Special +hi def link pcctsTokenName Identifier +hi def link pcctsRuleName Statement +hi def link pcctsLabelHack Label +hi def link pcctsDirective PreProc +hi def link pcctsString String +hi def link pcctsComment Comment +hi def link pcctsClass Statement +hi def link pcctsClassName Identifier +hi def link pcctsException Statement +hi def link pcctsExceptionHandler Keyword +hi def link pcctsExceptionRuleRef pcctsDelim +hi def link pcctsExceptionID Identifier +hi def link pcctsRuleRef Identifier +hi def link pcctsSpecialChar SpecialChar + + +let b:current_syntax = "pccts" + +" vim: ts=8 + +endif diff --git a/syntax/pdf.vim b/syntax/pdf.vim new file mode 100644 index 0000000..a6af459 --- /dev/null +++ b/syntax/pdf.vim @@ -0,0 +1,77 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PDF +" Maintainer: Tim Pope +" Last Change: 2007 Dec 16 + +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'pdf' +endif + +syn include @pdfXML syntax/xml.vim + +syn case match + +syn cluster pdfObjects contains=pdfBoolean,pdfConstant,pdfNumber,pdfFloat,pdfName,pdfHexString,pdfString,pdfArray,pdfHash,pdfReference,pdfComment +syn keyword pdfBoolean true false contained +syn keyword pdfConstant null contained +syn match pdfNumber "[+-]\=\<\d\+\>" +syn match pdfFloat "[+-]\=\<\%(\d\+\.\|\d*\.\d\+\)\>" contained + +syn match pdfNameError "#\X\|#\x\X\|#00" contained containedin=pdfName +syn match pdfSpecialChar "#\x\x" contained containedin=pdfName +syn match pdfName "/[^[:space:]\[\](){}<>/]*" contained +syn match pdfHexError "[^[:space:][:xdigit:]<>]" contained +"syn match pdfHexString "<\s*\x[^<>]*\x\s*>" contained contains=pdfHexError +"syn match pdfHexString "<\s*\x\=\s*>" contained +syn region pdfHexString matchgroup=pdfDelimiter start="<<\@!" end=">" contained contains=pdfHexError +syn match pdfStringError "\\." contained containedin=pdfString +syn match pdfSpecialChar "\\\%(\o\{1,3\}\|[nrtbf()\\]\)" contained containedin=pdfString +syn region pdfString matchgroup=pdfDelimiter start="\\\@>" contains=@pdfObjects contained +syn match pdfReference "\<\d\+\s\+\d\+\s\+R\>" +"syn keyword pdfOperator R contained containedin=pdfReference + +syn region pdfObject matchgroup=pdfType start="\" end="\" contains=@pdfObjects +syn region pdfObject matchgroup=pdfType start="\ +" Homepage: http://github.com/vim-perl/vim-perl/tree/master +" Bugs/requests: http://github.com/vim-perl/vim-perl/issues +" Last Change: 2017-09-12 +" Contributors: Andy Lester +" Hinrik Örn Sigurðsson +" Lukas Mai +" Nick Hibma +" Sonia Heimann +" Rob Hoelz +" and many others. +" +" Please download the most recent version first, before mailing +" any comments. +" +" The following parameters are available for tuning the +" perl syntax highlighting, with defaults given: +" +" let perl_include_pod = 1 +" unlet perl_no_scope_in_variables +" unlet perl_no_extended_vars +" unlet perl_string_as_statement +" unlet perl_no_sync_on_sub +" unlet perl_no_sync_on_global_var +" let perl_sync_dist = 100 +" unlet perl_fold +" unlet perl_fold_blocks +" unlet perl_nofold_packages +" unlet perl_nofold_subs +" unlet perl_fold_anonymous_subs +" unlet perl_no_subprototype_error + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" POD starts with ^= and ends with ^=cut + +if !exists("perl_include_pod") || perl_include_pod == 1 + " Include a while extra syntax file + syn include @Pod syntax/pod.vim + unlet b:current_syntax + if exists("perl_fold") + syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Pod,@Spell,perlTodo keepend fold extend + syn region perlPOD start="^=cut" end="^=cut" contains=perlTodo keepend fold extend + else + syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Pod,@Spell,perlTodo keepend + syn region perlPOD start="^=cut" end="^=cut" contains=perlTodo keepend + endif +else + " Use only the bare minimum of rules + if exists("perl_fold") + syn region perlPOD start="^=[a-z]" end="^=cut" fold + else + syn region perlPOD start="^=[a-z]" end="^=cut" + endif +endif + + +syn cluster perlTop contains=TOP + +syn region perlBraces start="{" end="}" transparent extend + +" All keywords +" +syn match perlConditional "\<\%(if\|elsif\|unless\|given\|when\|default\)\>" +syn match perlConditional "\\)\|\>\)" contains=perlElseIfError skipwhite skipnl skipempty +syn match perlRepeat "\<\%(while\|for\%(each\)\=\|do\|until\|continue\)\>" +syn match perlOperator "\<\%(defined\|undef\|eq\|ne\|[gl][et]\|cmp\|not\|and\|or\|xor\|not\|bless\|ref\|do\)\>" +" for some reason, adding this as the nextgroup for perlControl fixes BEGIN +" folding issues... +syn match perlFakeGroup "" contained +syn match perlControl "\<\%(BEGIN\|CHECK\|INIT\|END\|UNITCHECK\)\>\_s*" nextgroup=perlFakeGroup + +syn match perlStatementStorage "\<\%(my\|our\|local\|state\)\>" +syn match perlStatementControl "\<\%(return\|last\|next\|redo\|goto\|break\)\>" +syn match perlStatementScalar "\<\%(chom\=p\|chr\|crypt\|r\=index\|lc\%(first\)\=\|length\|ord\|pack\|sprintf\|substr\|fc\|uc\%(first\)\=\)\>" +syn match perlStatementRegexp "\<\%(pos\|quotemeta\|split\|study\)\>" +syn match perlStatementNumeric "\<\%(abs\|atan2\|cos\|exp\|hex\|int\|log\|oct\|rand\|sin\|sqrt\|srand\)\>" +syn match perlStatementList "\<\%(splice\|unshift\|shift\|push\|pop\|join\|reverse\|grep\|map\|sort\|unpack\)\>" +syn match perlStatementHash "\<\%(delete\|each\|exists\|keys\|values\)\>" +syn match perlStatementIOfunc "\<\%(syscall\|dbmopen\|dbmclose\)\>" +syn match perlStatementFiledesc "\<\%(binmode\|close\%(dir\)\=\|eof\|fileno\|getc\|lstat\|printf\=\|read\%(dir\|line\|pipe\)\|rewinddir\|say\|select\|stat\|tell\%(dir\)\=\|write\)\>" nextgroup=perlFiledescStatementNocomma skipwhite +syn match perlStatementFiledesc "\<\%(fcntl\|flock\|ioctl\|open\%(dir\)\=\|read\|seek\%(dir\)\=\|sys\%(open\|read\|seek\|write\)\|truncate\)\>" nextgroup=perlFiledescStatementComma skipwhite +syn match perlStatementVector "\" +syn match perlStatementFiles "\<\%(ch\%(dir\|mod\|own\|root\)\|glob\|link\|mkdir\|readlink\|rename\|rmdir\|symlink\|umask\|unlink\|utime\)\>" +syn match perlStatementFiles "-[rwxoRWXOezsfdlpSbctugkTBMAC]\>" +syn match perlStatementFlow "\<\%(caller\|die\|dump\|eval\|exit\|wantarray\|evalbytes\)\>" +syn match perlStatementInclude "\<\%(require\|import\|unimport\)\>" +syn match perlStatementInclude "\<\%(use\|no\)\s\+\%(\%(attributes\|attrs\|autodie\|autouse\|parent\|base\|big\%(int\|num\|rat\)\|blib\|bytes\|charnames\|constant\|diagnostics\|encoding\%(::warnings\)\=\|feature\|fields\|filetest\|if\|integer\|less\|lib\|locale\|mro\|open\|ops\|overload\|overloading\|re\|sigtrap\|sort\|strict\|subs\|threads\%(::shared\)\=\|utf8\|vars\|version\|vmsish\|warnings\%(::register\)\=\)\>\)\=" +syn match perlStatementProc "\<\%(alarm\|exec\|fork\|get\%(pgrp\|ppid\|priority\)\|kill\|pipe\|set\%(pgrp\|priority\)\|sleep\|system\|times\|wait\%(pid\)\=\)\>" +syn match perlStatementSocket "\<\%(accept\|bind\|connect\|get\%(peername\|sock\%(name\|opt\)\)\|listen\|recv\|send\|setsockopt\|shutdown\|socket\%(pair\)\=\)\>" +syn match perlStatementIPC "\<\%(msg\%(ctl\|get\|rcv\|snd\)\|sem\%(ctl\|get\|op\)\|shm\%(ctl\|get\|read\|write\)\)\>" +syn match perlStatementNetwork "\<\%(\%(end\|[gs]et\)\%(host\|net\|proto\|serv\)ent\|get\%(\%(host\|net\)by\%(addr\|name\)\|protoby\%(name\|number\)\|servby\%(name\|port\)\)\)\>" +syn match perlStatementPword "\<\%(get\%(pw\%(uid\|nam\)\|gr\%(gid\|nam\)\|login\)\)\|\%(end\|[gs]et\)\%(pw\|gr\)ent\>" +syn match perlStatementTime "\<\%(gmtime\|localtime\|time\)\>" + +syn match perlStatementMisc "\<\%(warn\|format\|formline\|reset\|scalar\|prototype\|lock\|tied\=\|untie\)\>" + +syn keyword perlTodo TODO TODO: TBD TBD: FIXME FIXME: XXX XXX: NOTE NOTE: contained + +syn region perlStatementIndirObjWrap matchgroup=perlStatementIndirObj start="\%(\<\%(map\|grep\|sort\|printf\=\|say\|system\|exec\)\>\s*\)\@<={" end="}" transparent extend + +syn match perlLabel "^\s*\h\w*\s*::\@!\%(\ is *not* considered as part of the +" variable - there again, too complicated and too slow. + +" Special variables first ($^A, ...) and ($|, $', ...) +syn match perlVarPlain "$^[ACDEFHILMNOPRSTVWX]\=" +syn match perlVarPlain "$[\\\"\[\]'&`+*.,;=%~!?@#$<>(-]" +syn match perlVarPlain "@[-+]" +syn match perlVarPlain "$\%(0\|[1-9]\d*\)" +" Same as above, but avoids confusion in $::foo (equivalent to $main::foo) +syn match perlVarPlain "$::\@!" +" These variables are not recognized within matches. +syn match perlVarNotInMatches "$[|)]" +" This variable is not recognized within matches delimited by m//. +syn match perlVarSlash "$/" + +" And plain identifiers +syn match perlPackageRef "[$@#%*&]\%(\%(::\|'\)\=\I\i*\%(\%(::\|'\)\I\i*\)*\)\=\%(::\|'\)\I"ms=s+1,me=e-1 contained + +" To not highlight packages in variables as a scope reference - i.e. in +" $pack::var, pack:: is a scope, just set "perl_no_scope_in_variables" +" If you don't want complex things like @{${"foo"}} to be processed, +" just set the variable "perl_no_extended_vars"... + +if !exists("perl_no_scope_in_variables") + syn match perlVarPlain "\%([@$]\|\$#\)\$*\%(\I\i*\)\=\%(\%(::\|'\)\I\i*\)*\%(::\|\i\@<=\)" contains=perlPackageRef nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref + syn match perlVarPlain2 "%\$*\%(\I\i*\)\=\%(\%(::\|'\)\I\i*\)*\%(::\|\i\@<=\)" contains=perlPackageRef nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref + syn match perlFunctionName "&\$*\%(\I\i*\)\=\%(\%(::\|'\)\I\i*\)*\%(::\|\i\@<=\)" contains=perlPackageRef nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref +else + syn match perlVarPlain "\%([@$]\|\$#\)\$*\%(\I\i*\)\=\%(\%(::\|'\)\I\i*\)*\%(::\|\i\@<=\)" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref + syn match perlVarPlain2 "%\$*\%(\I\i*\)\=\%(\%(::\|'\)\I\i*\)*\%(::\|\i\@<=\)" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref + syn match perlFunctionName "&\$*\%(\I\i*\)\=\%(\%(::\|'\)\I\i*\)*\%(::\|\i\@<=\)" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref +endif + +syn match perlVarPlain2 "%[-+]" + +if !exists("perl_no_extended_vars") + syn cluster perlExpr contains=perlStatementIndirObjWrap,perlStatementScalar,perlStatementRegexp,perlStatementNumeric,perlStatementList,perlStatementHash,perlStatementFiles,perlStatementTime,perlStatementMisc,perlVarPlain,perlVarPlain2,perlVarNotInMatches,perlVarSlash,perlVarBlock,perlVarBlock2,perlShellCommand,perlFloat,perlNumber,perlStringUnexpanded,perlString,perlQQ,perlArrow,perlBraces + syn region perlArrow matchgroup=perlArrow start="->\s*(" end=")" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref contained + syn region perlArrow matchgroup=perlArrow start="->\s*\[" end="\]" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref contained + syn region perlArrow matchgroup=perlArrow start="->\s*{" end="}" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref contained + syn match perlArrow "->\s*{\s*\I\i*\s*}" contains=perlVarSimpleMemberName nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref contained + syn region perlArrow matchgroup=perlArrow start="->\s*\$*\I\i*\s*(" end=")" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref contained + syn region perlVarBlock matchgroup=perlVarPlain start="\%($#\|[$@]\)\$*{" skip="\\}" end=+}\|\%(\%(<<\%('\|"\)\?\)\@=\)+ contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref extend + syn region perlVarBlock2 matchgroup=perlVarPlain start="[%&*]\$*{" skip="\\}" end=+}\|\%(\%(<<\%('\|"\)\?\)\@=\)+ contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref extend + syn match perlVarPlain2 "[%&*]\$*{\I\i*}" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref extend + syn match perlVarPlain "\%(\$#\|[@$]\)\$*{\I\i*}" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref extend + syn region perlVarMember matchgroup=perlVarPlain start="\%(->\)\={" skip="\\}" end="}" contained contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref extend + syn match perlVarSimpleMember "\%(->\)\={\s*\I\i*\s*}" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref contains=perlVarSimpleMemberName contained extend + syn match perlVarSimpleMemberName "\I\i*" contained + syn region perlVarMember matchgroup=perlVarPlain start="\%(->\)\=\[" skip="\\]" end="]" contained contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod,perlPostDeref extend + syn match perlPackageConst "__PACKAGE__" nextgroup=perlMethod,perlPostDeref + syn match perlMethod "->\$*\I\i*" contained nextgroup=perlVarSimpleMember,perlVarMember,perlMethod,perlPostDeref + syn match perlPostDeref "->\%($#\|[$@%&*]\)\*" contained nextgroup=perlVarSimpleMember,perlVarMember,perlMethod,perlPostDeref + syn region perlPostDeref start="->\%($#\|[$@%&*]\)\[" skip="\\]" end="]" contained contains=@perlExpr nextgroup=perlVarSimpleMember,perlVarMember,perlMethod,perlPostDeref + syn region perlPostDeref matchgroup=perlPostDeref start="->\%($#\|[$@%&*]\){" skip="\\}" end="}" contained contains=@perlExpr nextgroup=perlVarSimpleMember,perlVarMember,perlMethod,perlPostDeref +endif + +" File Descriptors +syn match perlFiledescRead "<\h\w*>" + +syn match perlFiledescStatementComma "(\=\s*\<\u\w*\>\s*,"me=e-1 transparent contained contains=perlFiledescStatement +syn match perlFiledescStatementNocomma "(\=\s*\<\u\w*\>\s*[^, \t]"me=e-1 transparent contained contains=perlFiledescStatement + +syn match perlFiledescStatement "\<\u\w*\>" contained + +" Special characters in strings and matches +syn match perlSpecialString "\\\%(\o\{1,3}\|x\%({\x\+}\|\x\{1,2}\)\|c.\|[^cx]\)" contained extend +syn match perlSpecialStringU2 "\\." extend contained contains=NONE +syn match perlSpecialStringU "\\\\" contained +syn match perlSpecialMatch "\\[1-9]" contained extend +syn match perlSpecialMatch "\\g\%(\d\+\|{\%(-\=\d\+\|\h\w*\)}\)" contained +syn match perlSpecialMatch "\\k\%(<\h\w*>\|'\h\w*'\)" contained +syn match perlSpecialMatch "{\d\+\%(,\%(\d\+\)\=\)\=}" contained +syn match perlSpecialMatch "\[[]-]\=[^\[\]]*[]-]\=\]" contained extend +syn match perlSpecialMatch "[+*()?.]" contained +syn match perlSpecialMatch "(?[#:=!]" contained +syn match perlSpecialMatch "(?[impsx]*\%(-[imsx]\+\)\=)" contained +syn match perlSpecialMatch "(?\%([-+]\=\d\+\|R\))" contained +syn match perlSpecialMatch "(?\%(&\|P[>=]\)\h\w*)" contained +syn match perlSpecialMatch "(\*\%(\%(PRUNE\|SKIP\|THEN\)\%(:[^)]*\)\=\|\%(MARK\|\):[^)]*\|COMMIT\|F\%(AIL\)\=\|ACCEPT\))" contained + +" Possible errors +" +" Highlight lines with only whitespace (only in blank delimited here documents) as errors +syn match perlNotEmptyLine "^\s\+$" contained +" Highlight "} else if (...) {", it should be "} else { if (...) { " or "} elsif (...) {" +syn match perlElseIfError "else\_s*if" containedin=perlConditional +syn keyword perlElseIfError elseif containedin=perlConditional + +" Variable interpolation +" +" These items are interpolated inside "" strings and similar constructs. +syn cluster perlInterpDQ contains=perlSpecialString,perlVarPlain,perlVarNotInMatches,perlVarSlash,perlVarBlock +" These items are interpolated inside '' strings and similar constructs. +syn cluster perlInterpSQ contains=perlSpecialStringU,perlSpecialStringU2 +" These items are interpolated inside m// matches and s/// substitutions. +syn cluster perlInterpSlash contains=perlSpecialString,perlSpecialMatch,perlVarPlain,perlVarBlock +" These items are interpolated inside m## matches and s### substitutions. +syn cluster perlInterpMatch contains=@perlInterpSlash,perlVarSlash + +" Shell commands +syn region perlShellCommand matchgroup=perlMatchStartEnd start="`" end="`" contains=@perlInterpDQ keepend + +" Constants +" +" Numbers +syn match perlNumber "\<\%(0\%(x\x[[:xdigit:]_]*\|b[01][01_]*\|\o[0-7_]*\|\)\|[1-9][[:digit:]_]*\)\>" +syn match perlFloat "\<\d[[:digit:]_]*[eE][\-+]\=\d\+" +syn match perlFloat "\<\d[[:digit:]_]*\.[[:digit:]_]*\%([eE][\-+]\=\d\+\)\=" +syn match perlFloat "\.[[:digit:]][[:digit:]_]*\%([eE][\-+]\=\d\+\)\=" + +syn match perlString "\<\%(v\d\+\%(\.\d\+\)*\|\d\+\%(\.\d\+\)\{2,}\)\>" contains=perlVStringV +syn match perlVStringV "\+ extend contained contains=perlAnglesSQ,@perlInterpSQ keepend + +syn region perlParensDQ start=+(+ end=+)+ extend contained contains=perlParensDQ,@perlInterpDQ keepend +syn region perlBracketsDQ start=+\[+ end=+\]+ extend contained contains=perlBracketsDQ,@perlInterpDQ keepend +syn region perlBracesDQ start=+{+ end=+}+ extend contained contains=perlBracesDQ,@perlInterpDQ keepend +syn region perlAnglesDQ start=+<+ end=+>+ extend contained contains=perlAnglesDQ,@perlInterpDQ keepend + + +" Simple version of searches and matches +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@\s*\z([^[:space:]'([{<#]\)+ end=+\z1[msixpodualgcn]*+ contains=@perlInterpMatch keepend extend +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@\)\@\)\@\)\@\)\@\)\@[msixpodualgcn]*+ contains=@perlInterpMatch,perlAnglesDQ keepend extend +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@\)\@\s*\z([^[:space:]'([{<#]\)+ end=+\z1+me=e-1 contains=@perlInterpMatch nextgroup=perlSubstitutionGQQ keepend extend +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@\)\@\)\@\)\@\)\@+ contains=@perlInterpMatch,perlAnglesDQ nextgroup=perlSubstitutionGQQ skipwhite skipempty skipnl keepend extend +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@\)\@[msixpodualgcern]*+ contained contains=@perlInterpDQ,perlAnglesDQ keepend extend +syn region perlSubstitutionSQ matchgroup=perlMatchStartEnd start=+'+ end=+'[msixpodualgcern]*+ contained contains=@perlInterpSQ keepend extend + +" Translations +" perlMatch is the first part, perlTranslation* is the second, translator part. +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@\s*\z([^[:space:]([{<#]\)+ end=+\z1+me=e-1 contains=@perlInterpSQ nextgroup=perlTranslationGQ +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@\)\@\)\@\)\@+ contains=@perlInterpSQ,perlAnglesSQ nextgroup=perlTranslationGQ skipwhite skipempty skipnl +syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@[cdsr]*+ contains=perlAnglesSQ contained + + +" Strings and q, qq, qw and qr expressions + +syn region perlStringUnexpanded matchgroup=perlStringStartEnd start="'" end="'" contains=@perlInterpSQ keepend extend +syn region perlString matchgroup=perlStringStartEnd start=+"+ end=+"+ contains=@perlInterpDQ keepend extend +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpSQ keepend extend +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\)\@\)\@\)\@\)\@+ contains=@perlInterpSQ,perlAnglesSQ keepend extend + +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpDQ keepend extend +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\)\@\)\@\)\@\)\@+ contains=@perlInterpDQ,perlAnglesDQ keepend extend + +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\)\@\)\@\)\@\)\@\)\@+ contains=@perlInterpSQ,perlAnglesSQ keepend extend + +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\s*\z([^[:space:]#([{<'/]\)+ end=+\z1[imosxdual]*+ contains=@perlInterpMatch keepend extend +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\)\@\)\@\)\@ and qr[] which allows for comments and extra whitespace in the pattern +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\)\@[imosxdual]*+ contains=@perlInterpMatch,perlAnglesDQ,perlComment keepend extend +syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@\zs\_[^)]\+" contained + syn match perlSubPrototype +(\_[^)]*)\_s*+ nextgroup=perlSubAttributes,perlComment contained contains=perlSubPrototypeError +endif + +syn match perlSubName +\%(\h\|::\|'\w\)\%(\w\|::\|'\w\)*\_s*\|+ contained nextgroup=perlSubPrototype,perlSignature,perlSubAttributes,perlComment + +syn match perlFunction +\\_s*+ nextgroup=perlSubName + +" The => operator forces a bareword to the left of it to be interpreted as +" a string +syn match perlString "\I\@\)\@=" + +" All other # are comments, except ^#! +syn match perlComment "#.*" contains=perlTodo,@Spell extend +syn match perlSharpBang "^#!.*" + +" Formats +syn region perlFormat matchgroup=perlStatementIOFunc start="^\s*\~]\+\%(\.\.\.\)\=" contained +syn match perlFormatField "[@^]#[#.]*" contained +syn match perlFormatField "@\*" contained +syn match perlFormatField "@[^A-Za-z_|<>~#*]"me=e-1 contained +syn match perlFormatField "@$" contained + +" __END__ and __DATA__ clauses +if exists("perl_fold") + syntax region perlDATA start="^__DATA__$" skip="." end="." contains=@perlDATA fold + syntax region perlDATA start="^__END__$" skip="." end="." contains=perlPOD,@perlDATA fold +else + syntax region perlDATA start="^__DATA__$" skip="." end="." contains=@perlDATA + syntax region perlDATA start="^__END__$" skip="." end="." contains=perlPOD,@perlDATA +endif + +" +" Folding + +if exists("perl_fold") + " Note: this bit must come before the actual highlighting of the "package" + " keyword, otherwise this will screw up Pod lines that match /^package/ + if !exists("perl_nofold_packages") + syn region perlPackageFold start="^package \S\+;\s*\%(#.*\)\=$" end="^1;\=\s*\%(#.*\)\=$" end="\n\+package"me=s-1 transparent fold keepend + endif + if !exists("perl_nofold_subs") + if get(g:, "perl_fold_anonymous_subs", 0) + syn region perlSubFold start="\[^{]*{" end="}" transparent fold keepend extend + syn region perlSubFold start="\<\%(BEGIN\|END\|CHECK\|INIT\)\>\s*{" end="}" transparent fold keepend + else + syn region perlSubFold start="^\z(\s*\)\.*[^};]$" end="^\z1}\s*\%(#.*\)\=$" transparent fold keepend + syn region perlSubFold start="^\z(\s*\)\<\%(BEGIN\|END\|CHECK\|INIT\|UNITCHECK\)\>.*[^};]$" end="^\z1}\s*$" transparent fold keepend + endif + endif + + if exists("perl_fold_blocks") + syn region perlBlockFold start="^\z(\s*\)\%(if\|elsif\|unless\|for\|while\|until\|given\)\s*(.*)\%(\s*{\)\=\s*\%(#.*\)\=$" start="^\z(\s*\)for\%(each\)\=\s*\%(\%(my\|our\)\=\s*\S\+\s*\)\=(.*)\%(\s*{\)\=\s*\%(#.*\)\=$" end="^\z1}\s*;\=\%(#.*\)\=$" transparent fold keepend + syn region perlBlockFold start="^\z(\s*\)\%(do\|else\)\%(\s*{\)\=\s*\%(#.*\)\=$" end="^\z1}\s*while" end="^\z1}\s*;\=\%(#.*\)\=$" transparent fold keepend + endif + + setlocal foldmethod=syntax + syn sync fromstart +else + " fromstart above seems to set minlines even if perl_fold is not set. + syn sync minlines=0 +endif + +" NOTE: If you're linking new highlight groups to perlString, please also put +" them into b:match_skip in ftplugin/perl.vim. + +" The default highlighting. +hi def link perlSharpBang PreProc +hi def link perlControl PreProc +hi def link perlInclude Include +hi def link perlSpecial Special +hi def link perlString String +hi def link perlCharacter Character +hi def link perlNumber Number +hi def link perlFloat Float +hi def link perlType Type +hi def link perlIdentifier Identifier +hi def link perlLabel Label +hi def link perlStatement Statement +hi def link perlConditional Conditional +hi def link perlRepeat Repeat +hi def link perlOperator Operator +hi def link perlFunction Keyword +hi def link perlSubName Function +hi def link perlSubPrototype Type +hi def link perlSignature Type +hi def link perlSubAttributes PreProc +hi def link perlSubAttributesCont perlSubAttributes +hi def link perlComment Comment +hi def link perlTodo Todo +if exists("perl_string_as_statement") + hi def link perlStringStartEnd perlStatement +else + hi def link perlStringStartEnd perlString +endif +hi def link perlVStringV perlStringStartEnd +hi def link perlList perlStatement +hi def link perlMisc perlStatement +hi def link perlVarPlain perlIdentifier +hi def link perlVarPlain2 perlIdentifier +hi def link perlArrow perlIdentifier +hi def link perlFiledescRead perlIdentifier +hi def link perlFiledescStatement perlIdentifier +hi def link perlVarSimpleMember perlIdentifier +hi def link perlVarSimpleMemberName perlString +hi def link perlVarNotInMatches perlIdentifier +hi def link perlVarSlash perlIdentifier +hi def link perlQQ perlString +hi def link perlHereDoc perlString +hi def link perlStringUnexpanded perlString +hi def link perlSubstitutionSQ perlString +hi def link perlSubstitutionGQQ perlString +hi def link perlTranslationGQ perlString +hi def link perlMatch perlString +hi def link perlMatchStartEnd perlStatement +hi def link perlFormatName perlIdentifier +hi def link perlFormatField perlString +hi def link perlPackageDecl perlType +hi def link perlStorageClass perlType +hi def link perlPackageRef perlType +hi def link perlStatementPackage perlStatement +hi def link perlStatementStorage perlStatement +hi def link perlStatementControl perlStatement +hi def link perlStatementScalar perlStatement +hi def link perlStatementRegexp perlStatement +hi def link perlStatementNumeric perlStatement +hi def link perlStatementList perlStatement +hi def link perlStatementHash perlStatement +hi def link perlStatementIOfunc perlStatement +hi def link perlStatementFiledesc perlStatement +hi def link perlStatementVector perlStatement +hi def link perlStatementFiles perlStatement +hi def link perlStatementFlow perlStatement +hi def link perlStatementInclude perlStatement +hi def link perlStatementProc perlStatement +hi def link perlStatementSocket perlStatement +hi def link perlStatementIPC perlStatement +hi def link perlStatementNetwork perlStatement +hi def link perlStatementPword perlStatement +hi def link perlStatementTime perlStatement +hi def link perlStatementMisc perlStatement +hi def link perlStatementIndirObj perlStatement +hi def link perlFunctionName perlIdentifier +hi def link perlMethod perlIdentifier +hi def link perlPostDeref perlIdentifier +hi def link perlFunctionPRef perlType +if !get(g:, 'perl_include_pod', 1) + hi def link perlPOD perlComment +endif +hi def link perlShellCommand perlString +hi def link perlSpecialAscii perlSpecial +hi def link perlSpecialDollar perlSpecial +hi def link perlSpecialString perlSpecial +hi def link perlSpecialStringU perlSpecial +hi def link perlSpecialMatch perlSpecial +hi def link perlDATA perlComment + +" NOTE: Due to a bug in Vim (or more likely, a misunderstanding on my part), +" I had to remove the transparent property from the following regions +" in order to get them to highlight correctly. Feel free to remove +" these and reinstate the transparent property if you know how. +hi def link perlParensSQ perlString +hi def link perlBracketsSQ perlString +hi def link perlBracesSQ perlString +hi def link perlAnglesSQ perlString + +hi def link perlParensDQ perlString +hi def link perlBracketsDQ perlString +hi def link perlBracesDQ perlString +hi def link perlAnglesDQ perlString + +hi def link perlSpecialStringU2 perlString + +" Possible errors +hi def link perlNotEmptyLine Error +hi def link perlElseIfError Error +hi def link perlSubPrototypeError Error +hi def link perlSubError Error + +" Syncing to speed up processing +" +if !exists("perl_no_sync_on_sub") + syn sync match perlSync grouphere NONE "^\s*\" + syn sync match perlSync grouphere NONE "^}" +endif + +if !exists("perl_no_sync_on_global_var") + syn sync match perlSync grouphere NONE "^$\I[[:alnum:]_:]+\s*=\s*{" + syn sync match perlSync grouphere NONE "^[@%]\I[[:alnum:]_:]+\s*=\s*(" +endif + +if exists("perl_sync_dist") + execute "syn sync maxlines=" . perl_sync_dist +else + syn sync maxlines=100 +endif + +syn sync match perlSyncPOD grouphere perlPOD "^=pod" +syn sync match perlSyncPOD grouphere perlPOD "^=head" +syn sync match perlSyncPOD grouphere perlPOD "^=item" +syn sync match perlSyncPOD grouphere NONE "^=cut" + +let b:current_syntax = "perl" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" XXX Change to sts=4:sw=4 +" vim:ts=8:sts=2:sw=2:expandtab:ft=vim + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Vim syntax file diff --git a/syntax/perl6.vim b/syntax/perl6.vim new file mode 100644 index 0000000..c68cb2f --- /dev/null +++ b/syntax/perl6.vim @@ -0,0 +1,2246 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Perl 6 +" Maintainer: vim-perl +" Homepage: http://github.com/vim-perl/vim-perl/tree/master +" Bugs/requests: http://github.com/vim-perl/vim-perl/issues +" Last Change: 2013-07-21 + +" Contributors: Luke Palmer +" Moritz Lenz +" Hinrik Örn Sigurðsson +" +" This is a big undertaking. Perl 6 is the sort of language that only Perl +" can parse. But I'll do my best to get vim to. +" +" You can associate the extension ".pl" with the filetype "perl6" by setting +" autocmd BufNewFile,BufRead *.pl setf perl6 +" in your ~/.vimrc. But that will infringe on Perl 5, so you might want to +" put a modeline near the beginning or end of your Perl 6 files instead: +" # vim: filetype=perl6 + +" TODO: +" * Deal with s:Perl5// +" * m:s// is a match, not a substitution +" * Make these highlight as strings, not operators: +" <==> <=:=> <===> <=~> <« »> «>» «<» +" * Allow more keywords to match as function calls(leave() is export(), etc) +" * Optimization: use nextgroup instead of lookaround (:help syn-nextgroup) +" * Fix s''' substitutions being matched as package names +" * Match s/// and m/// better, so things like "$s/" won't match +" * Add more support for folding (:help syn-fold) +" * Add more syntax syncing hooks (:help syn-sync) +" * Q//: +" :to, :heredoc +" interpolate \q:s{$scalar} (though the spec isn't very clear on it) +" +" Impossible TODO?: +" * Unspace +" * Unicode bracketing characters for quoting (there are so many) +" * Various tricks depending on context. I.e. we can't know when Perl +" expects «*» to be a string or a hyperoperator. The latter is presumably +" more common, so that's what we assume. +" * Selective highlighting of Pod formatting codes with the :allow option +" * Arbitrary number, order, and negation of adverbs to Q//, q//, qq//. +" Currently only the first adverb is considered significant. Anything +" more would require an exponential amount of regexes, making this +" already slow syntax file even slower. +" +" If you want to have Pir code inside Q:PIR// strings highlighted, do: +" let perl6_embedded_pir=1 +" +" The above requires pir.vim, which you can find in Parrot's repository: +" https://svn.parrot.org/parrot/trunk/editor/ +" +" Some less than crucial things have been made optional to speed things up. +" Look at the comments near the if/else branches in this file to see exactly +" which features are affected. "perl6_extended_all" enables everything. +" +" The defaults are: +" +" unlet perl6_extended_comments +" unlet perl6_extended_q +" unlet perl6_extended_all + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +" identifiers +syn match p6Normal display "\K\%(\k\|[-']\K\@=\)*" + +" This is used in the for loops below +" Don't use the "syn keyword" construct because that always has higher +" priority than matches/regions, so the words can't be autoquoted with +" the "=>" and "p5=>" operators. All the lookaround stuff is to make sure +" we don't match them as part of some other identifier. +let s:before_keyword = " display \"\\%(\\k\\|\\K\\@<=[-']\\)\\@.;\\]" +syn match p6Operator display "\%(:\@\)" +" "i" requires a digit to the left, and no keyword char to the right +syn match p6Operator display "\d\@<=i\k\@!" +" index overloading +syn match p6Operator display "\%(&\.(\@=\|@\.\[\@=\|%\.{\@=\)" + +" all infix operators except nonassocative ones +let s:infix_a = [ + \ "div % mod +& +< +> \\~& ?& \\~< \\~> +| +\\^ \\~| \\~\\^ ?| ?\\^ xx x", + \ "\\~ && & also <== ==> <<== ==>> == != < <= > >= \\~\\~ eq ne lt le gt", + \ "ge =:= === eqv before after \\^\\^ min max \\^ff ff\\^ \\^ff\\^", + \ "\\^fff fff\\^ \\^fff\\^ fff ff ::= := \\.= => , : p5=> Z minmax", + \ "\\.\\.\\. and andthen or orelse xor \\^ += -= /= \\*= \\~= //= ||=", + \ "+ - \\*\\* \\* // / \\~ || |", +\ ] +" nonassociative infix operators +let s:infix_n = "but does <=> leg cmp \\.\\. \\.\\.\\^\\^ \\^\\.\\. \\^\\.\\.\\^" + +let s:infix_a_long = join(s:infix_a, " ") +let s:infix_a_words = split(s:infix_a_long) +let s:infix_a_pattern = join(s:infix_a_words, "\\|") + +let s:infix_n_words = split(s:infix_n) +let s:infix_n_pattern = join(s:infix_n_words, "\\|") + +let s:both = [s:infix_a_pattern, s:infix_n_pattern] +let s:infix = join(s:both, "\\|") + +let s:infix_assoc = "!\\?\\%(" . s:infix_a_pattern . "\\)" +let s:infix = "!\\?\\%(" . s:infix . "\\)" + +unlet s:infix_a s:infix_a_long s:infix_a_words s:infix_a_pattern +unlet s:infix_n s:infix_n_pattern s:both + +" [+] reduce +exec "syn match p6ReduceOp display \"\\k\\@" + +" does is a type constraint sometimes +syn match p6TypeConstraint display "does\%(\s*\%(\k\|[-']\K\@=\)\)\@=" + +" int is a type sometimes +syn match p6Type display "\\%(\s*(\|\s\+\d\)\@!" + +" these Routine names are also Properties, if preceded by "is" +syn match p6Property display "\%(is\s\+\)\@<=\%(signature\|context\|also\|shape\)" + +" The sigil in ::*Package +syn match p6PackageTwigil display "\%(::\)\@<=\*" + +" $ +syn region p6MatchVarSigil + \ matchgroup=p6Variable + \ start="\$\%(<<\@!\)\@=" + \ end=">\@<=" + \ contains=p6MatchVar + +syn region p6MatchVar + \ matchgroup=p6Twigil + \ start="<" + \ end=">" + \ contained + +" Contextualizers +syn match p6Context display "\<\%(item\|list\|slice\|hash\)\>" +syn match p6Context display "\%(\$\|@\|%\|&\|@@\)(\@=" + +" the "$" placeholder in "$var1, $, var2 = @list" +syn match p6Placeholder display "\%(,\s*\)\@<=\$\%(\K\|\%([.^*?=!~]\|:\@]*>\|«[^»]*»\|{[^}]*}\)\)*\)\.\?\%(([^)]*)\|\[[^\]]*]\|<[^>]*>\|«[^»]*»\|{[^}]*}\)\)\)" + \ start="\ze\z(\$\%(\%(\%(\%([.^*?=!~]\|:\@]*>\|«[^»]*»\|{[^}]*}\)\)*\)\.\?\%(([^)]*)\|\[[^\]]*]\|<[^>]*>\|«[^»]*»\|{[^}]*}\)\)\)" + \ end="\z1\zs" + \ contained + \ contains=TOP + \ keepend + +syn region p6InterpArray + \ matchgroup=p6Context + \ start="@\ze()\@!" + \ start="@@\ze()\@!" + \ skip="([^)]*)" + \ end=")\zs" + \ contained + \ contains=TOP + +syn region p6InterpHash + \ start="\ze\z(%\$*\%(\%(\%(!\|/\|¢\)\|\%(\%(\%([.^*?=!~]\|:\@]*>\|«[^»]*»\|{[^}]*}\)\)*\)\.\?\%(([^)]*)\|\[[^\]]*]\|<[^>]*>\|«[^»]*»\|{[^}]*}\)\)\)" + \ end="\z1\zs" + \ contained + \ contains=TOP + \ keepend + +syn region p6InterpHash + \ matchgroup=p6Context + \ start="%\ze()\@!" + \ skip="([^)]*)" + \ end=")\zs" + \ contained + \ contains=TOP + +syn region p6InterpFunction + \ start="\ze\z(&\%(\%(!\|/\|¢\)\|\%(\%(\%([.^*?=!~]\|:\@]*>\|«[^»]*»\|{[^}]*}\)\)*\)\.\?\%(([^)]*)\|\[[^\]]*]\|<[^>]*>\|«[^»]*»\|{[^}]*}\)\)\)" + \ end="\z1\zs" + \ contained + \ contains=TOP + \ keepend + +syn region p6InterpFunction + \ matchgroup=p6Context + \ start="&\ze()\@!" + \ skip="([^)]*)" + \ end=")\zs" + \ contained + \ contains=TOP + +syn region p6InterpClosure + \ start="\\\@" contained +syn match p6EscCloseFrench display "\\»" contained +syn match p6EscBackTick display "\\`" contained +syn match p6EscForwardSlash display "\\/" contained +syn match p6EscVerticalBar display "\\|" contained +syn match p6EscExclamation display "\\!" contained +syn match p6EscComma display "\\," contained +syn match p6EscDollar display "\\\$" contained +syn match p6EscCloseCurly display "\\}" contained +syn match p6EscCloseBracket display "\\\]" contained + +" misc escapes +syn match p6EscOctOld display "\\\d\{1,3}" contained +syn match p6EscNull display "\\0\d\@!" contained +syn match p6EscCodePoint display "\%(\\c\)\@<=\%(\d\|\S\|\[\)\@=" contained nextgroup=p6CodePoint +syn match p6EscHex display "\%(\\x\)\@<=\%(\x\|\[\)\@=" contained nextgroup=p6HexSequence +syn match p6EscOct display "\%(\\o\)\@<=\%(\o\|\[\)\@=" contained nextgroup=p6OctSequence +syn match p6EscQQ display "\\qq" contained nextgroup=p6QQSequence +syn match p6EscOpenCurly display "\\{" contained +syn match p6EscHash display "\\#" contained +syn match p6EscBackSlash display "\\\\" contained + +syn region p6QQSequence + \ matchgroup=p6Escape + \ start="\[" + \ skip="\[[^\]]*]" + \ end="]" + \ contained + \ transparent + \ contains=@p6Interp_qq + +syn match p6CodePoint display "\%(\d\+\|\S\)" contained +syn region p6CodePoint + \ matchgroup=p6Escape + \ start="\[" + \ end="]" + \ contained + +syn match p6HexSequence display "\x\+" contained +syn region p6HexSequence + \ matchgroup=p6Escape + \ start="\[" + \ end="]" + \ contained + +syn match p6OctSequence display "\o\+" contained +syn region p6OctSequence + \ matchgroup=p6Escape + \ start="\[" + \ end="]" + \ contained + +" matches :key, :!key, :$var, :key, etc +" Since we don't know in advance how the adverb ends, we use a trick. +" Consume nothing with the start pattern (\ze at the beginning), +" while capturing the whole adverb into \z1 and then putting it before +" the match start (\zs) of the end pattern. +syn region p6Adverb + \ start="\ze\z(:!\?\K\%(\k\|[-']\K\@=\)*\%(([^)]*)\|\[[^\]]*]\|<[^>]*>\|«[^»]*»\|{[^}]*}\)\?\)" + \ start="\ze\z(:!\?[@$%]\$*\%(::\|\%(\$\@<=\d\+\|!\|/\|¢\)\|\%(\%([.^*?=!~]\|:\@ +" FIXME: not sure how to distinguish this from the "less than" operator +" in all cases. For now, it matches if any of the following is true: +" +" * There is whitespace missing on either side of the "<", since +" people tend to put spaces around "less than" +" * It comes after "enum", "for", "any", "all", or "none" +" * It's the first or last thing on a line (ignoring whitespace) +" * It's preceded by "= " +" +" It never matches when: +" +" * Preceded by [<+~=] (e.g. <>, =<$foo>) +" * Followed by [-=] (e.g. <--, <=, <==) +syn region p6StringAngle + \ matchgroup=p6Quote + \ start="\%(\<\%(enum\|for\|any\|all\|none\)\>\s*(\?\s*\)\@<=<\%(<\|=>\|[-=]\{1,2}>\@!\)\@!" + \ start="\%(\s\|[<+~=]\)\@\|[-=]\{1,2}>\@!\)\@!" + \ start="[<+~=]\@\|[-=]\{1,2}>\@!\)\@!" + \ start="\%(^\s*\)\@<=<\%(<\|=>\|[-=]\{1,2}>\@!\)\@!" + \ start="[<+~=]\@\|[-=]\{1,2}>\@!\)\@!" + \ skip="\\\@" + \ end=">" + \ contains=p6InnerAnglesOne,p6EscBackSlash,p6EscCloseAngle + +syn region p6InnerAnglesOne + \ matchgroup=p6StringAngle + \ start="<" + \ skip="\\\@" + \ end=">" + \ transparent + \ contained + \ contains=p6InnerAnglesOne + +" <> +syn region p6StringAngles + \ matchgroup=p6Quote + \ start="<<=\@!" + \ skip="\\\@" + \ end=">>" + \ contains=p6InnerAnglesTwo,@p6Interp_qq,p6Comment,p6EscHash,p6EscCloseAngle,p6Adverb,p6StringSQ,p6StringDQ + +syn region p6InnerAnglesTwo + \ matchgroup=p6StringAngles + \ start="<<" + \ skip="\\\@" + \ end=">>" + \ transparent + \ contained + \ contains=p6InnerAnglesTwo + +" «words» +syn region p6StringFrench + \ matchgroup=p6Quote + \ start="«" + \ skip="\\\@" nextgroup=p6QPairs skipwhite skipempty +syn match p6QPairs contained transparent skipwhite skipempty nextgroup=p6StringQ,p6StringQ_PIR "\%(\_s*:!\?\K\%(\k\|[-']\K\@=\)*\%(([^)]*)\|\[[^\]]*]\|<[^>]*>\|«[^»]*»\|{[^}]*}\)\?\)*" + +if exists("perl6_embedded_pir") + syn include @p6PIR syntax/pir.vim +endif + +" hardcoded set of delimiters +let s:delims = [ + \ ["\\\"", "\\\"", "p6EscDoubleQuote", "\\\\\\@", "p6EscCloseAngle", "\\%(\\\\\\@\\|<[^>]*>\\)"], + \ ["«", "»", "p6EscCloseFrench", "\\%(\\\\\\@>", "p6EscCloseAngle", "\\%(\\\\\\@>\\|<<\\%([^>]\\|>>\\@!\\)*>>\\)"]) + call add(s:delims, ["\\s\\@<=<<<", ">>>", "p6EscCloseAngle", "\\%(\\\\\\@>>\\|<<<\\%([^>]\\|>\\%(>>\\)\\@!\\)*>>>\\)"]) +endif + +if !exists("perl6_extended_q") && !exists("perl6_extended_all") + " simple version, no special highlighting within the string + for [start_delim, end_delim, end_group, skip] in s:delims + exec "syn region p6StringQ matchgroup=p6Quote start=\"".start_delim."\" skip=\"".skip."\" end=\"".end_delim."\" contains=".end_group." contained" + endfor + + if exists("perl6_embedded_pir") + " highlight embedded PIR code + for [start_delim, end_delim, end_group, skip] in s:delims + exec "syn region p6StringQ_PIR matchgroup=p6Quote start=\"\\%(Q\\s*:PIR\\s*\\)\\@<=".start_delim."\" skip=\"".skip."\" end=\"".end_delim."\" contains=@p6PIR,".end_group." contained" + endfor + endif +else + let s:before = "syn region p6StringQ matchgroup=p6Quote start=\"\\%(" + let s:after = "\\%(\\_s*:!\\?\\K\\%(\\k\\|[-']\\K\\@=\\)*\\%(([^)]*)\\|\\[[^\\]]*]\\|<[^>]*>\\|«[^»]*»\\|{[^}]*}\\)\\?\\)*\\_s*\\)\\@<=" + + let s:adverbs = [ + \ ["s", "scalar"], + \ ["a", "array"], + \ ["h", "hash"], + \ ["f", "function"], + \ ["c", "closure"], + \ ["b", "backslash"], + \ ["w", "words"], + \ ["ww", "quotewords"], + \ ["x", "exec"], + \ ] + + " these can't be conjoined with q and qq (e.g. as qqq and qqqq) + let s:q_adverbs = [ + \ ["q", "single"], + \ ["qq", "double"], + \ ] + + for [start_delim, end_delim, end_group, skip] in s:delims + " Q, q, and qq with any number of (ignored) adverbs + exec s:before ."Q". s:after .start_delim."\" end=\"". end_delim ."\""." contained" + exec s:before ."q". s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_q"." contained" + exec s:before ."qq". s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_qq"." contained" + + for [short, long] in s:adverbs + " Qs, qs, qqs, Qa, qa, qqa, etc, with ignored adverbs + exec s:before ."Q".short. s:after .start_delim ."\" end=\"". end_delim ."\" contains=@p6Interp_".long." contained" + exec s:before ."q".short. s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_q,@p6Interp_".long." contained" + exec s:before ."qq".short. s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_qq,@p6Interp_".long." contained" + + " Q, q, and qq, with one significant adverb + exec s:before ."Q\\s*:\\%(".short."\\|".long."\\)". s:after .start_delim ."\" end=\"". end_delim ."\" contains=@p6Interp_".long." contained" + for [q_short, q_long] in s:q_adverbs + exec s:before ."Q\\s*:\\%(".q_short."\\|".q_long."\\)". s:after .start_delim ."\" end=\"". end_delim ."\" contains=@p6Interp_".q_long." contained" + endfor + exec s:before ."q\\s*:\\%(".short."\\|".long."\\)". s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_q,@p6Interp_".long." contained" + exec s:before ."qq\\s*:\\%(".short."\\|".long."\\)". s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_qq,@p6Interp_".long." contained" + + for [short2, long2] in s:adverbs + " Qs, qs, qqs, Qa, qa, qqa, etc, with one significant adverb + exec s:before ."Q".short."\\s*:\\%(".short2."\\|".long2."\\)". s:after .start_delim ."\" end=\"". end_delim ."\" contains=@p6Interp_".long.",@p6Interp_".long2." contained" + for [q_short2, q_long2] in s:q_adverbs + exec s:before ."Q".short."\\s*:\\%(".q_short2."\\|".q_long2."\\)". s:after .start_delim ."\" end=\"". end_delim ."\" contains=@p6Interp_".long.",@p6Interp_".q_long2." contained" + endfor + exec s:before ."q".short."\\s*:\\%(".short2."\\|".long2."\\)". s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_q,@p6Interp_".long.",@p6Interp_".long2." contained" + exec s:before ."qq".short."\\s*:\\%(".short2."\\|".long2."\\)". s:after .start_delim ."\" skip=\"". skip ."\" end=\"". end_delim ."\" contains=". end_group .",@p6Interp_qq,@p6Interp_".long.",@p6Interp_".long2." contained" + endfor + endfor + endfor + unlet s:before s:after s:adverbs s:q_adverbs +endif +unlet s:delims + +" Match these so something else above can't. E.g. the "q" in "role q { }" +" should not be considered a string +syn match p6Normal display "\%(\<\%(role\|grammar\|slang\)\s\+\)\@<=\K\%(\k\|[-']\K\@=\)*" + +" :key +syn match p6Operator display ":\@ and p5=> autoquoting +syn match p6StringP5Auto display "\K\%(\k\|[-']\K\@=\)*\ze\s\+p5=>" +syn match p6StringAuto display "\K\%(\k\|[-']\K\@=\)*\ze\%(p5\)\@" +syn match p6StringAuto display "\K\%(\k\|[-']\K\@=\)*\ze\s\+=>" +syn match p6StringAuto display "\K\%(\k\|[-']\K\@=\)*p5\ze=>" + +" Hyperoperators. Needs to come after the quoting operators (<>, «», etc) +exec "syn match p6HyperOp display \"»" .s:infix."»\\?\"" +exec "syn match p6HyperOp display \"«\\?".s:infix."«\"" +exec "syn match p6HyperOp display \"»" .s:infix."«\"" +exec "syn match p6HyperOp display \"«" .s:infix. "»\"" + +exec "syn match p6HyperOp display \">>" .s:infix."\\%(>>\\)\\?\"" +exec "syn match p6HyperOp display \"\\%(<<\\)\\?".s:infix."<<\"" +exec "syn match p6HyperOp display \">>" .s:infix."<<\"" +exec "syn match p6HyperOp display \"<<" .s:infix.">>\"" +unlet s:infix + +" Regexes and grammars + +syn match p6RegexName display "\%(\<\%(regex\|rule\|token\)\s\+\)\@<=\K\%(\k\|[-']\K\@=\)*" nextgroup=p6RegexBlockCrap skipwhite skipempty +syn match p6RegexBlockCrap "[^{]*" nextgroup=p6RegexBlock skipwhite skipempty transparent contained + +syn region p6RegexBlock + \ matchgroup=p6Normal + \ start="{" + \ end="}" + \ contained + \ contains=@p6Regexen,@p6Variables + +" Perl 6 regex bits + +syn cluster p6Regexen + \ add=p6RxMeta + \ add=p6RxEscape + \ add=p6EscHex + \ add=p6EscOct + \ add=p6EscNull + \ add=p6RxAnchor + \ add=p6RxCapture + \ add=p6RxGroup + \ add=p6RxAlternation + \ add=p6RxAdverb + \ add=p6RxAdverbArg + \ add=p6RxStorage + \ add=p6RxAssertion + \ add=p6RxQuoteWords + \ add=p6RxClosure + \ add=p6RxStringSQ + \ add=p6RxStringDQ + \ add=p6Comment + +syn match p6RxMeta display contained ".\%(\k\|\s\)\@" + \ contained + \ contains=@p6Regexen,@p6Variables,p6RxCharClass,p6RxAssertCall +syn region p6RxAssertCall + \ matchgroup=p6Normal + \ start="\%(::\|\%(\K\%(\k\|[-']\K\@=\)*\)\)\@<=(\@=" + \ end=")\@<=" + \ contained + \ contains=TOP +syn region p6RxCharClass + \ matchgroup=p6StringSpecial2 + \ start="\%(<[-!+?]\?\)\@<=\[" + \ skip="\\]" + \ end="]" + \ contained + \ contains=p6RxRange,p6RxEscape,p6EscHex,p6EscOct,p6EscNull +syn region p6RxQuoteWords + \ matchgroup=p6StringSpecial2 + \ start="< " + \ end=">" + \ contained +syn region p6RxAdverb + \ start="\ze\z(:!\?\K\%(\k\|[-']\K\@=\)*\)" + \ end="\z1\zs" + \ contained + \ contains=TOP + \ keepend +syn region p6RxAdverbArg + \ start="\%(:!\?\K\%(\k\|[-']\K\@=\)*\)\@<=(" + \ skip="([^)]*)" + \ end=")" + \ contained + \ contains=TOP +syn region p6RxStorage + \ matchgroup=p6Operator + \ start="\%(^\s*\)\@<=:\%(my\>\|temp\>\)\@=" + \ end="$" + \ contains=TOP + \ contained + +" Perl 5 regex bits + +syn cluster p6RegexP5Base + \ add=p6RxP5Escape + \ add=p6RxP5Oct + \ add=p6RxP5Hex + \ add=p6RxP5EscMeta + \ add=p6RxP5CodePoint + \ add=p6RxP5Prop + +" normal regex stuff +syn cluster p6RegexP5 + \ add=@p6RegexP5Base + \ add=p6RxP5Quantifier + \ add=p6RxP5Meta + \ add=p6RxP5QuoteMeta + \ add=p6RxP5ParenMod + \ add=p6RxP5Verb + \ add=p6RxP5Count + \ add=p6RxP5Named + \ add=p6RxP5ReadRef + \ add=p6RxP5WriteRef + \ add=p6RxP5CharClass + \ add=p6RxP5Anchor + +" inside character classes +syn cluster p6RegexP5Class + \ add=@p6RegexP5Base + \ add=p6RxP5Posix + \ add=p6RxP5Range + +syn match p6RxP5Escape display contained "\\\S" +syn match p6RxP5CodePoint display contained "\\c\S\@=" nextgroup=p6RxP5CPId +syn match p6RxP5CPId display contained "\S" +syn match p6RxP5Oct display contained "\\\%(\o\{1,3}\)\@=" nextgroup=p6RxP5OctSeq +syn match p6RxP5OctSeq display contained "\o\{1,3}" +syn match p6RxP5Anchor display contained "[\^$]" +syn match p6RxP5Hex display contained "\\x\%({\x\+}\|\x\{1,2}\)\@=" nextgroup=p6RxP5HexSeq +syn match p6RxP5HexSeq display contained "\x\{1,2}" +syn region p6RxP5HexSeq + \ matchgroup=p6RxP5Escape + \ start="{" + \ end="}" + \ contained +syn region p6RxP5Named + \ matchgroup=p6RxP5Escape + \ start="\%(\\N\)\@<={" + \ end="}" + \ contained +syn match p6RxP5Quantifier display contained "\%([+*]\|(\@" + \ contained +syn match p6RxP5WriteRef display contained "\\g\%(\d\|{\)\@=" nextgroup=p6RxP5WriteRefId +syn match p6RxP5WriteRefId display contained "\d\+" +syn region p6RxP5WriteRefId + \ matchgroup=p6RxP5Escape + \ start="{" + \ end="}" + \ contained +syn match p6RxP5Prop display contained "\\[pP]\%(\a\|{\)\@=" nextgroup=p6RxP5PropId +syn match p6RxP5PropId display contained "\a" +syn region p6RxP5PropId + \ matchgroup=p6RxP5Escape + \ start="{" + \ end="}" + \ contained +syn match p6RxP5Meta display contained "[(|).]" +syn match p6RxP5ParenMod display contained "(\@<=?\@=" nextgroup=p6RxP5Mod,p6RxP5ModName,p6RxP5Code +syn match p6RxP5Mod display contained "?\%(<\?=\|<\?!\|[#:|]\)" +syn match p6RxP5Mod display contained "?-\?[impsx]\+" +syn match p6RxP5Mod display contained "?\%([-+]\?\d\+\|R\)" +syn match p6RxP5Mod display contained "?(DEFINE)" +syn match p6RxP5Mod display contained "?\%(&\|P[>=]\)" nextgroup=p6RxP5ModDef +syn match p6RxP5ModDef display contained "\h\w*" +syn region p6RxP5ModName + \ matchgroup=p6StringSpecial + \ start="?'" + \ end="'" + \ contained +syn region p6RxP5ModName + \ matchgroup=p6StringSpecial + \ start="?P\?<" + \ end=">" + \ contained +syn region p6RxP5Code + \ matchgroup=p6StringSpecial + \ start="??\?{" + \ end="})\@=" + \ contained + \ contains=TOP +syn match p6RxP5EscMeta display contained "\\[?*.{}()[\]|\^$]" +syn match p6RxP5Count display contained "\%({\d\+\%(,\%(\d\+\)\?\)\?}\)\@=" nextgroup=p6RxP5CountId +syn region p6RxP5CountId + \ matchgroup=p6RxP5Escape + \ start="{" + \ end="}" + \ contained +syn match p6RxP5Verb display contained "(\@<=\*\%(\%(PRUNE\|SKIP\|THEN\)\%(:[^)]*\)\?\|\%(MARK\|\):[^)]*\|COMMIT\|F\%(AIL\)\?\|ACCEPT\)" +syn region p6RxP5QuoteMeta + \ matchgroup=p6RxP5Escape + \ start="\\Q" + \ end="\\E" + \ contained + \ contains=@p6Variables,p6EscBackSlash +syn region p6RxP5CharClass + \ matchgroup=p6StringSpecial + \ start="\[\^\?" + \ skip="\\]" + \ end="]" + \ contained + \ contains=@p6RegexP5Class +syn region p6RxP5Posix + \ matchgroup=p6RxP5Escape + \ start="\[:" + \ end=":]" + \ contained +syn match p6RxP5Range display contained "-" + +" 'string' inside a regex +syn region p6RxStringSQ + \ matchgroup=p6Quote + \ start="'" + \ skip="\\\@, mm, rx +syn region p6Match + \ matchgroup=p6Quote + \ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@\@!>\@!" + \ skip="\\>" + \ end=">" + \ contains=@p6Regexen,@p6Variables + +" m«foo», mm«foo», rx«foo» +syn region p6Match + \ matchgroup=p6Quote + \ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@ +syn region p6Match + \ matchgroup=p6Quote + \ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@\@!" + \ skip="\\>" + \ end=">" + \ contains=@p6Regexen,@p6Variables + +" s«foo» +syn region p6Match + \ matchgroup=p6Quote + \ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@ +syn region p6Match + \ matchgroup=p6Quote + \ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@\@!" + \ skip="\\>" + \ end=">" + \ contains=@p6RegexP5,p6Variables + +" m:P5«» +syn region p6Match + \ matchgroup=p6Quote + \ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@]*>" + \ end=">" + \ matchgroup=p6Error + \ start="^#<" + \ contains=p6Attention,p6Comment +syn region p6Comment + \ matchgroup=p6Comment + \ start="^\@]\|>>\@!\)*>>" + \ end=">>" + \ matchgroup=p6Error + \ start="^#<<" + \ contains=p6Attention,p6Comment + syn region p6Comment + \ matchgroup=p6Comment + \ start="^\@]\|>\%(>>\)\@!\)*>>>" + \ end=">>>" + \ matchgroup=p6Error + \ start="^#<<<" + \ contains=p6Attention,p6Comment + + syn region p6Comment + \ matchgroup=p6Comment + \ start="^\@" + \ end="^\ze\%(\s*$\|=\K\)" + \ contains=p6PodAbbrCodeType + \ keepend + +syn region p6PodAbbrCodeType + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=p6PodName,p6PodAbbrCode + +syn region p6PodAbbrCode + \ start="^" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + +" Abbreviated blocks (everything is a comment) +syn region p6PodAbbrRegion + \ matchgroup=p6PodPrefix + \ start="^=\zecomment\>" + \ end="^\ze\%(\s*$\|=\K\)" + \ contains=p6PodAbbrCommentType + \ keepend + +syn region p6PodAbbrCommentType + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=p6PodComment,p6PodAbbrNoCode + +" Abbreviated blocks (implicit code allowed) +syn region p6PodAbbrRegion + \ matchgroup=p6PodPrefix + \ start="^=\ze\%(pod\|item\|nested\|\u\+\)\>" + \ end="^\ze\%(\s*$\|=\K\)" + \ contains=p6PodAbbrType + \ keepend + +syn region p6PodAbbrType + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=p6PodName,p6PodAbbr + +syn region p6PodAbbr + \ start="^" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=@p6PodFormat,p6PodImplicitCode + +" Abbreviated block to end-of-file +syn region p6PodAbbrRegion + \ matchgroup=p6PodPrefix + \ start="^=\zeEND\>" + \ end="\%$" + \ contains=p6PodAbbrEOFType + \ keepend + +syn region p6PodAbbrEOFType + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="\%$" + \ contained + \ contains=p6PodName,p6PodAbbrEOF + +syn region p6PodAbbrEOF + \ start="^" + \ end="\%$" + \ contained + \ contains=@p6PodNestedBlocks,@p6PodFormat,p6PodImplicitCode + +" Directives +syn region p6PodDirectRegion + \ matchgroup=p6PodPrefix + \ start="^=\%(config\|use\)\>" + \ end="^\ze\%([^=]\|=\K\|\s*$\)" + \ contains=p6PodDirectArgRegion + \ keepend + +syn region p6PodDirectArgRegion + \ matchgroup=p6PodType + \ start="\S\+" + \ end="^\ze\%([^=]\|=\K\|\s*$\)" + \ contained + \ contains=p6PodDirectConfigRegion + +syn region p6PodDirectConfigRegion + \ start="" + \ end="^\ze\%([^=]\|=\K\|\s*$\)" + \ contained + \ contains=@p6PodConfig + +" =encoding is a special directive +syn region p6PodDirectRegion + \ matchgroup=p6PodPrefix + \ start="^=encoding\>" + \ end="^\ze\%([^=]\|=\K\|\s*$\)" + \ contains=p6PodEncodingArgRegion + \ keepend + +syn region p6PodEncodingArgRegion + \ matchgroup=p6PodName + \ start="\S\+" + \ end="^\ze\%([^=]\|=\K\|\s*$\)" + \ contained + +" Paragraph blocks (implicit code forbidden) +syn region p6PodParaRegion + \ matchgroup=p6PodPrefix + \ start="^=for\>" + \ end="^\ze\%(\s*$\|=\K\)" + \ contains=p6PodParaNoCodeTypeRegion + \ keepend + \ extend + +syn region p6PodParaNoCodeTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=p6PodParaNoCode,p6PodParaConfigRegion + +syn region p6PodParaConfigRegion + \ start="" + \ end="^\ze\%([^=]\|=\k\@\ze\s*code\>" + \ end="^\ze\%(\s*$\|=\K\)" + \ contains=p6PodParaCodeTypeRegion + \ keepend + \ extend + +syn region p6PodParaCodeTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=p6PodParaCode,p6PodParaConfigRegion + +syn region p6PodParaCode + \ start="^[^=]" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + +" Paragraph blocks (implicit code allowed) +syn region p6PodParaRegion + \ matchgroup=p6PodPrefix + \ start="^=for\>\ze\s*\%(pod\|item\|nested\|\u\+\)\>" + \ end="^\ze\%(\s*$\|=\K\)" + \ contains=p6PodParaTypeRegion + \ keepend + \ extend + +syn region p6PodParaTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=p6PodPara,p6PodParaConfigRegion + +syn region p6PodPara + \ start="^[^=]" + \ end="^\ze\%(\s*$\|=\K\)" + \ contained + \ contains=@p6PodFormat,p6PodImplicitCode + +" Paragraph block to end-of-file +syn region p6PodParaRegion + \ matchgroup=p6PodPrefix + \ start="^=for\>\ze\s\+END\>" + \ end="\%$" + \ contains=p6PodParaEOFTypeRegion + \ keepend + \ extend + +syn region p6PodParaEOFTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="\%$" + \ contained + \ contains=p6PodParaEOF,p6PodParaConfigRegion + +syn region p6PodParaEOF + \ start="^[^=]" + \ end="\%$" + \ contained + \ contains=@p6PodNestedBlocks,@p6PodFormat,p6PodImplicitCode + +" Delimited blocks (implicit code forbidden) +syn region p6PodDelimRegion + \ matchgroup=p6PodPrefix + \ start="^=begin\>" + \ end="^=end\>" + \ contains=p6PodDelimNoCodeTypeRegion + \ keepend + \ extend + +syn region p6PodDelimNoCodeTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze=end\>" + \ contained + \ contains=p6PodDelimNoCode,p6PodDelimConfigRegion + +syn region p6PodDelimConfigRegion + \ start="" + \ end="^\ze\%([^=]\|=\K\|\s*$\)" + \ contained + \ contains=@p6PodConfig + +syn region p6PodDelimNoCode + \ start="^" + \ end="^\ze=end\>" + \ contained + \ contains=@p6PodNestedBlocks,@p6PodFormat + +" Delimited blocks (everything is code) +syn region p6PodDelimRegion + \ matchgroup=p6PodPrefix + \ start="^=begin\>\ze\s*code\>" + \ end="^=end\>" + \ contains=p6PodDelimCodeTypeRegion + \ keepend + \ extend + +syn region p6PodDelimCodeTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze=end\>" + \ contained + \ contains=p6PodDelimCode,p6PodDelimConfigRegion + +syn region p6PodDelimCode + \ start="^" + \ end="^\ze=end\>" + \ contained + \ contains=@p6PodNestedBlocks + +" Delimited blocks (implicit code allowed) +syn region p6PodDelimRegion + \ matchgroup=p6PodPrefix + \ start="^=begin\>\ze\s*\%(pod\|item\|nested\|\u\+\)\>" + \ end="^=end\>" + \ contains=p6PodDelimTypeRegion + \ keepend + \ extend + +syn region p6PodDelimTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="^\ze=end\>" + \ contained + \ contains=p6PodDelim,p6PodDelimConfigRegion + +syn region p6PodDelim + \ start="^" + \ end="^\ze=end\>" + \ contained + \ contains=@p6PodNestedBlocks,@p6PodFormat,p6PodImplicitCode + +" Delimited block to end-of-file +syn region p6PodDelimRegion + \ matchgroup=p6PodPrefix + \ start="^=begin\>\ze\s\+END\>" + \ end="\%$" + \ contains=p6PodDelimEOFTypeRegion + \ extend + +syn region p6PodDelimEOFTypeRegion + \ matchgroup=p6PodType + \ start="\K\k*" + \ end="\%$" + \ contained + \ contains=p6PodDelimEOF,p6PodDelimConfigRegion + +syn region p6PodDelimEOF + \ start="^" + \ end="\%$" + \ contained + \ contains=@p6PodNestedBlocks,@p6PodFormat,p6PodImplicitCode + +syn cluster p6PodConfig + \ add=p6PodConfigOperator + \ add=p6PodExtraConfig + \ add=p6StringAuto + \ add=p6PodAutoQuote + \ add=p6StringSQ + +syn region p6PodParens + \ start="(" + \ end=")" + \ contained + \ contains=p6Number,p6StringSQ + +syn match p6PodAutoQuote display contained "=>" +syn match p6PodConfigOperator display contained ":!\?" nextgroup=p6PodConfigOption +syn match p6PodConfigOption display contained "[^[:space:](<]\+" nextgroup=p6PodParens,p6StringAngle +syn match p6PodExtraConfig display contained "^=" +syn match p6PodVerticalBar display contained "|" +syn match p6PodColon display contained ":" +syn match p6PodSemicolon display contained ";" +syn match p6PodComma display contained "," +syn match p6PodImplicitCode display contained "^\s.*" + +syn region p6PodDelimEndRegion + \ matchgroup=p6PodType + \ start="\%(^=end\>\)\@<=" + \ end="\K\k*" + +" These may appear inside delimited blocks +syn cluster p6PodNestedBlocks + \ add=p6PodAbbrRegion + \ add=p6PodDirectRegion + \ add=p6PodParaRegion + \ add=p6PodDelimRegion + \ add=p6PodDelimEndRegion + +" Pod formatting codes + +syn cluster p6PodFormat + \ add=p6PodFormatOne + \ add=p6PodFormatTwo + \ add=p6PodFormatThree + \ add=p6PodFormatFrench + +" Balanced angles found inside formatting codes. Ensures proper nesting. + +syn region p6PodFormatAnglesOne + \ matchgroup=p6PodFormat + \ start="<" + \ skip="<[^>]*>" + \ end=">" + \ transparent + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatAnglesOne + +syn region p6PodFormatAnglesTwo + \ matchgroup=p6PodFormat + \ start="<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ transparent + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatAnglesOne,p6PodFormatAnglesTwo + +syn region p6PodFormatAnglesThree + \ matchgroup=p6PodFormat + \ start="<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ transparent + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatAnglesOne,p6PodFormatAnglesTwo,p6PodFormatAnglesThree + +syn region p6PodFormatAnglesFrench + \ matchgroup=p6PodFormat + \ start="«" + \ skip="«[^»]*»" + \ end="»" + \ transparent + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatAnglesOne,p6PodFormatAnglesTwo,p6PodFormatAnglesThree + +" All formatting codes + +syn region p6PodFormatOne + \ matchgroup=p6PodFormatCode + \ start="\u<" + \ skip="<[^>]*>" + \ end=">" + \ contained + \ contains=p6PodFormatAnglesOne,p6PodFormatFrench,p6PodFormatOne + +syn region p6PodFormatTwo + \ matchgroup=p6PodFormatCode + \ start="\u<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ contained + \ contains=p6PodFormatAnglesTwo,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo + +syn region p6PodFormatThree + \ matchgroup=p6PodFormatCode + \ start="\u<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ contained + \ contains=p6PodFormatAnglesThree,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree + +syn region p6PodFormatFrench + \ matchgroup=p6PodFormatCode + \ start="\u«" + \ skip="«[^»]*»" + \ end="»" + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree + +" C<> and V<> don't allow nested formatting formatting codes + +syn region p6PodFormatOne + \ matchgroup=p6PodFormatCode + \ start="[CV]<" + \ skip="<[^>]*>" + \ end=">" + \ contained + \ contains=p6PodFormatAnglesOne + +syn region p6PodFormatTwo + \ matchgroup=p6PodFormatCode + \ start="[CV]<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ contained + \ contains=p6PodFormatAnglesTwo + +syn region p6PodFormatThree + \ matchgroup=p6PodFormatCode + \ start="[CV]<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ contained + \ contains=p6PodFormatAnglesThree + +syn region p6PodFormatFrench + \ matchgroup=p6PodFormatCode + \ start="[CV]«" + \ skip="«[^»]*»" + \ end="»" + \ contained + \ contains=p6PodFormatAnglesFrench + +" L<> can have a "|" separator + +syn region p6PodFormatOne + \ matchgroup=p6PodFormatCode + \ start="L<" + \ skip="<[^>]*>" + \ end=">" + \ contained + \ contains=p6PodFormatAnglesOne,p6PodFormatFrench,p6PodFormatOne,p6PodVerticalBar + +syn region p6PodFormatTwo + \ matchgroup=p6PodFormatCode + \ start="L<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ contained + \ contains=p6PodFormatAnglesTwo,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodVerticalBar + +syn region p6PodFormatThree + \ matchgroup=p6PodFormatCode + \ start="L<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ contained + \ contains=p6PodFormatAnglesThree,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodVerticalBar + +syn region p6PodFormatFrench + \ matchgroup=p6PodFormatCode + \ start="L«" + \ skip="«[^»]*»" + \ end="»" + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodVerticalBar + +" E<> can have a ";" separator + +syn region p6PodFormatOne + \ matchgroup=p6PodFormatCode + \ start="E<" + \ skip="<[^>]*>" + \ end=">" + \ contained + \ contains=p6PodFormatAnglesOne,p6PodFormatFrench,p6PodFormatOne,p6PodSemiColon + +syn region p6PodFormatTwo + \ matchgroup=p6PodFormatCode + \ start="E<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ contained + \ contains=p6PodFormatAnglesTwo,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodSemiColon + +syn region p6PodFormatThree + \ matchgroup=p6PodFormatCode + \ start="E<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ contained + \ contains=p6PodFormatAnglesThree,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodSemiColon + +syn region p6PodFormatFrench + \ matchgroup=p6PodFormatCode + \ start="E«" + \ skip="«[^»]*»" + \ end="»" + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodSemiColon + +" M<> can have a ":" separator + +syn region p6PodFormatOne + \ matchgroup=p6PodFormatCode + \ start="M<" + \ skip="<[^>]*>" + \ end=">" + \ contained + \ contains=p6PodFormatAnglesOne,p6PodFormatFrench,p6PodFormatOne,p6PodColon + +syn region p6PodFormatTwo + \ matchgroup=p6PodFormatCode + \ start="M<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ contained + \ contains=p6PodFormatAnglesTwo,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodColon + +syn region p6PodFormatThree + \ matchgroup=p6PodFormatCode + \ start="M<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ contained + \ contains=p6PodFormatAnglesThree,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodColon + +syn region p6PodFormatFrench + \ matchgroup=p6PodFormatCode + \ start="M«" + \ skip="«[^»]*»" + \ end="»" + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodColon + +" D<> can have "|" and ";" separators + +syn region p6PodFormatOne + \ matchgroup=p6PodFormatCode + \ start="D<" + \ skip="<[^>]*>" + \ end=">" + \ contained + \ contains=p6PodFormatAnglesOne,p6PodFormatFrench,p6PodFormatOne,p6PodVerticalBar,p6PodSemiColon + +syn region p6PodFormatTwo + \ matchgroup=p6PodFormatCode + \ start="D<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ contained + \ contains=p6PodFormatAngleTwo,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodVerticalBar,p6PodSemiColon + +syn region p6PodFormatThree + \ matchgroup=p6PodFormatCode + \ start="D<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ contained + \ contains=p6PodFormatAnglesThree,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodVerticalBar,p6PodSemiColon + +syn region p6PodFormatFrench + \ matchgroup=p6PodFormatCode + \ start="D«" + \ skip="«[^»]*»" + \ end="»" + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodVerticalBar,p6PodSemiColon + +" X<> can have "|", "," and ";" separators + +syn region p6PodFormatOne + \ matchgroup=p6PodFormatCode + \ start="X<" + \ skip="<[^>]*>" + \ end=">" + \ contained + \ contains=p6PodFormatAnglesOne,p6PodFormatFrench,p6PodFormatOne,p6PodVerticalBar,p6PodSemiColon,p6PodComma + +syn region p6PodFormatTwo + \ matchgroup=p6PodFormatCode + \ start="X<<" + \ skip="<<[^>]*>>" + \ end=">>" + \ contained + \ contains=p6PodFormatAnglesTwo,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodVerticalBar,p6PodSemiColon,p6PodComma + +syn region p6PodFormatThree + \ matchgroup=p6PodFormatCode + \ start="X<<<" + \ skip="<<<[^>]*>>>" + \ end=">>>" + \ contained + \ contains=p6PodFormatAnglesThree,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodVerticalBar,p6PodSemiColon,p6PodComma + +syn region p6PodFormatFrench + \ matchgroup=p6PodFormatCode + \ start="X«" + \ skip="«[^»]*»" + \ end="»" + \ contained + \ contains=p6PodFormatAnglesFrench,p6PodFormatFrench,p6PodFormatOne,p6PodFormatTwo,p6PodFormatThree,p6PodVerticalBar,p6PodSemiColon,p6PodComma + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link p6EscOctOld p6Error +hi def link p6PackageTwigil p6Twigil +hi def link p6StringAngle p6String +hi def link p6StringFrench p6String +hi def link p6StringAngles p6String +hi def link p6StringSQ p6String +hi def link p6StringDQ p6String +hi def link p6StringQ p6String +hi def link p6RxStringSQ p6String +hi def link p6RxStringDQ p6String +hi def link p6Substitution p6String +hi def link p6Transliteration p6String +hi def link p6StringAuto p6String +hi def link p6StringP5Auto p6String +hi def link p6Key p6String +hi def link p6Match p6String +hi def link p6RegexBlock p6String +hi def link p6RxP5CharClass p6String +hi def link p6RxP5QuoteMeta p6String +hi def link p6RxCharClass p6String +hi def link p6RxQuoteWords p6String +hi def link p6ReduceOp p6Operator +hi def link p6ReverseCrossOp p6Operator +hi def link p6HyperOp p6Operator +hi def link p6QuoteQ p6Operator +hi def link p6RxRange p6StringSpecial +hi def link p6RxAnchor p6StringSpecial +hi def link p6RxP5Anchor p6StringSpecial +hi def link p6CodePoint p6StringSpecial +hi def link p6RxMeta p6StringSpecial +hi def link p6RxP5Range p6StringSpecial +hi def link p6RxP5CPId p6StringSpecial +hi def link p6RxP5Posix p6StringSpecial +hi def link p6RxP5Mod p6StringSpecial +hi def link p6RxP5HexSeq p6StringSpecial +hi def link p6RxP5OctSeq p6StringSpecial +hi def link p6RxP5WriteRefId p6StringSpecial +hi def link p6HexSequence p6StringSpecial +hi def link p6OctSequence p6StringSpecial +hi def link p6RxP5Named p6StringSpecial +hi def link p6RxP5PropId p6StringSpecial +hi def link p6RxP5Quantifier p6StringSpecial +hi def link p6RxP5CountId p6StringSpecial +hi def link p6RxP5Verb p6StringSpecial +hi def link p6Escape p6StringSpecial2 +hi def link p6EscNull p6StringSpecial2 +hi def link p6EscHash p6StringSpecial2 +hi def link p6EscQQ p6StringSpecial2 +hi def link p6EscQuote p6StringSpecial2 +hi def link p6EscDoubleQuote p6StringSpecial2 +hi def link p6EscBackTick p6StringSpecial2 +hi def link p6EscForwardSlash p6StringSpecial2 +hi def link p6EscVerticalBar p6StringSpecial2 +hi def link p6EscExclamation p6StringSpecial2 +hi def link p6EscDollar p6StringSpecial2 +hi def link p6EscOpenCurly p6StringSpecial2 +hi def link p6EscCloseCurly p6StringSpecial2 +hi def link p6EscCloseBracket p6StringSpecial2 +hi def link p6EscCloseAngle p6StringSpecial2 +hi def link p6EscCloseFrench p6StringSpecial2 +hi def link p6EscBackSlash p6StringSpecial2 +hi def link p6RxEscape p6StringSpecial2 +hi def link p6RxCapture p6StringSpecial2 +hi def link p6RxAlternation p6StringSpecial2 +hi def link p6RxP5 p6StringSpecial2 +hi def link p6RxP5ReadRef p6StringSpecial2 +hi def link p6RxP5Oct p6StringSpecial2 +hi def link p6RxP5Hex p6StringSpecial2 +hi def link p6RxP5EscMeta p6StringSpecial2 +hi def link p6RxP5Meta p6StringSpecial2 +hi def link p6RxP5Escape p6StringSpecial2 +hi def link p6RxP5CodePoint p6StringSpecial2 +hi def link p6RxP5WriteRef p6StringSpecial2 +hi def link p6RxP5Prop p6StringSpecial2 + +hi def link p6Property Tag +hi def link p6Attention Todo +hi def link p6Type Type +hi def link p6Error Error +hi def link p6BlockLabel Label +hi def link p6Float Float +hi def link p6Normal Normal +hi def link p6Package Normal +hi def link p6PackageScope Normal +hi def link p6Number Number +hi def link p6VersionNum Number +hi def link p6String String +hi def link p6Repeat Repeat +hi def link p6Keyword Keyword +hi def link p6Pragma Keyword +hi def link p6Module Keyword +hi def link p6DeclareRoutine Keyword +hi def link p6VarStorage Special +hi def link p6FlowControl Special +hi def link p6NumberBase Special +hi def link p6Twigil Special +hi def link p6StringSpecial2 Special +hi def link p6VersionDot Special +hi def link p6Comment Comment +hi def link p6Include Include +hi def link p6Shebang PreProc +hi def link p6ClosureTrait PreProc +hi def link p6Routine Function +hi def link p6Operator Operator +hi def link p6Version Operator +hi def link p6Context Operator +hi def link p6Quote Delimiter +hi def link p6TypeConstraint PreCondit +hi def link p6Exception Exception +hi def link p6Placeholder Identifier +hi def link p6Variable Identifier +hi def link p6VarSlash Identifier +hi def link p6VarNum Identifier +hi def link p6VarExclam Identifier +hi def link p6VarMatch Identifier +hi def link p6VarName Identifier +hi def link p6MatchVar Identifier +hi def link p6RxP5ReadRefId Identifier +hi def link p6RxP5ModDef Identifier +hi def link p6RxP5ModName Identifier +hi def link p6Conditional Conditional +hi def link p6StringSpecial SpecialChar + +hi def link p6PodAbbr p6Pod +hi def link p6PodAbbrEOF p6Pod +hi def link p6PodAbbrNoCode p6Pod +hi def link p6PodAbbrCode p6PodCode +hi def link p6PodPara p6Pod +hi def link p6PodParaEOF p6Pod +hi def link p6PodParaNoCode p6Pod +hi def link p6PodParaCode p6PodCode +hi def link p6PodDelim p6Pod +hi def link p6PodDelimEOF p6Pod +hi def link p6PodDelimNoCode p6Pod +hi def link p6PodDelimCode p6PodCode +hi def link p6PodImplicitCode p6PodCode +hi def link p6PodExtraConfig p6PodPrefix +hi def link p6PodVerticalBar p6PodFormatCode +hi def link p6PodColon p6PodFormatCode +hi def link p6PodSemicolon p6PodFormatCode +hi def link p6PodComma p6PodFormatCode +hi def link p6PodFormatOne p6PodFormat +hi def link p6PodFormatTwo p6PodFormat +hi def link p6PodFormatThree p6PodFormat +hi def link p6PodFormatFrench p6PodFormat + +hi def link p6PodType Type +hi def link p6PodConfigOption String +hi def link p6PodCode PreProc +hi def link p6Pod Comment +hi def link p6PodComment Comment +hi def link p6PodAutoQuote Operator +hi def link p6PodConfigOperator Operator +hi def link p6PodPrefix Statement +hi def link p6PodName Identifier +hi def link p6PodFormatCode SpecialChar +hi def link p6PodFormat SpecialComment + + +" Syncing to speed up processing +"syn sync match p6SyncPod groupthere p6PodAbbrRegion "^=\K\k*\>" +"syn sync match p6SyncPod groupthere p6PodDirectRegion "^=\%(config\|use\|encoding\)\>" +"syn sync match p6SyncPod groupthere p6PodParaRegion "^=for\>" +"syn sync match p6SyncPod groupthere p6PodDelimRegion "^=begin\>" +"syn sync match p6SyncPod groupthere p6PodDelimEndRegion "^=end\>" + +" Let's just sync whole file, the other methods aren't reliable (or I don't +" know how to use them reliably) +syn sync fromstart + +setlocal foldmethod=syntax + +let b:current_syntax = "perl6" + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim:ts=8:sts=4:sw=4:expandtab:ft=vim + +endif diff --git a/syntax/pf.vim b/syntax/pf.vim new file mode 100644 index 0000000..01f6ceb --- /dev/null +++ b/syntax/pf.vim @@ -0,0 +1,110 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" pf syntax file +" Language: OpenBSD packet filter configuration (pf.conf) +" Original Author: Camiel Dobbelaar +" Maintainer: Lauri Tirkkonen +" Last Change: 2016 Jul 06 + +if exists("b:current_syntax") + finish +endif + +setlocal foldmethod=syntax +syn iskeyword @,48-57,_,-,+ +syn sync fromstart + +syn cluster pfNotLS contains=pfTodo,pfVarAssign +syn keyword pfCmd anchor antispoof block include match pass queue +syn keyword pfCmd queue set table +syn match pfCmd /^\s*load\sanchor\>/ +syn keyword pfTodo TODO XXX contained +syn keyword pfWildAddr all any +syn match pfComment /#.*$/ contains=pfTodo +syn match pfCont /\\$/ +syn match pfErrClose /}/ +syn match pfIPv4 /\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}/ +syn match pfIPv6 /[a-fA-F0-9:]*::[a-fA-F0-9:.]*/ +syn match pfIPv6 /[a-fA-F0-9:]\+:[a-fA-F0-9:]\+:[a-fA-F0-9:.]\+/ +syn match pfNetmask /\/\d\+/ +syn match pfNum /[a-zA-Z0-9_:.]\@/ +syn match pfVar /$[a-zA-Z][a-zA-Z0-9_]*/ +syn match pfVarAssign /^\s*[a-zA-Z][a-zA-Z0-9_]*\s*=/me=e-1 +syn region pfFold1 start=/^#\{1}>/ end=/^#\{1,3}>/me=s-1 transparent fold +syn region pfFold2 start=/^#\{2}>/ end=/^#\{2,3}>/me=s-1 transparent fold +syn region pfFold3 start=/^#\{3}>/ end=/^#\{3}>/me=s-1 transparent fold +syn region pfList start=/{/ end=/}/ transparent contains=ALLBUT,pfErrClose,@pfNotLS +syn region pfString start=/"/ skip=/\\"/ end=/"/ contains=pfIPv4,pfIPv6,pfNetmask,pfTable,pfVar +syn region pfString start=/'/ skip=/\\'/ end=/'/ contains=pfIPv4,pfIPv6,pfNetmask,pfTable,pfVar + +syn keyword pfService 802-11-iapp Microsoft-SQL-Monitor +syn keyword pfService Microsoft-SQL-Server NeXTStep NextStep +syn keyword pfService afpovertcp afs3-bos afs3-callback afs3-errors +syn keyword pfService afs3-fileserver afs3-kaserver afs3-prserver +syn keyword pfService afs3-rmtsys afs3-update afs3-vlserver +syn keyword pfService afs3-volser amt-redir-tcp amt-redir-tls +syn keyword pfService amt-soap-http amt-soap-https asf-rmcp at-echo +syn keyword pfService at-nbp at-rtmp at-zis auth authentication +syn keyword pfService bfd-control bfd-echo bftp bgp bgpd biff bootpc +syn keyword pfService bootps canna cddb cddbp chargen chat cmd +syn keyword pfService cmip-agent cmip-man comsat conference +syn keyword pfService conserver courier csnet-ns cso-ns cvspserver +syn keyword pfService daap datametrics daytime dhcpd-sync +syn keyword pfService dhcpv6-client dhcpv6-server discard domain +syn keyword pfService echo efs eklogin ekshell ekshell2 epmap eppc +syn keyword pfService exec finger ftp ftp-data git gopher hostname +syn keyword pfService hostnames hprop http https hunt hylafax iapp +syn keyword pfService icb ident imap imap2 imap3 imaps ingreslock +syn keyword pfService ipp iprop ipsec-msft ipsec-nat-t ipx irc +syn keyword pfService isakmp iscsi isisd iso-tsap kauth kdc kerberos +syn keyword pfService kerberos-adm kerberos-iv kerberos-sec +syn keyword pfService kerberos_master kf kip klogin kpasswd kpop +syn keyword pfService krb524 krb_prop krbupdate krcmd kreg kshell kx +syn keyword pfService l2tp ldap ldaps ldp link login mail mdns +syn keyword pfService mdnsresponder microsoft-ds ms-sql-m ms-sql-s +syn keyword pfService msa msp mtp mysql name nameserver netbios-dgm +syn keyword pfService netbios-ns netbios-ssn netnews netplan netrjs +syn keyword pfService netstat netwall newdate nextstep nfs nfsd +syn keyword pfService nicname nnsp nntp ntalk ntp null openwebnet +syn keyword pfService ospf6d ospfapi ospfd photuris pop2 pop3 pop3pw +syn keyword pfService pop3s poppassd portmap postgresql postoffice +syn keyword pfService pptp presence printer prospero prospero-np +syn keyword pfService puppet pwdgen qotd quote radacct radius +syn keyword pfService radius-acct rdp readnews remotefs resource rfb +syn keyword pfService rfe rfs rfs_server ripd ripng rje rkinit rlp +syn keyword pfService routed router rpc rpcbind rsync rtelnet rtsp +syn keyword pfService sa-msg-port sane-port sftp shell sieve silc +syn keyword pfService sink sip smtp smtps smux snmp snmp-trap +syn keyword pfService snmptrap snpp socks source spamd spamd-cfg +syn keyword pfService spamd-sync spooler spop3 ssdp ssh submission +syn keyword pfService sunrpc supdup supfiledbg supfilesrv support +syn keyword pfService svn svrloc swat syslog syslog-tls systat +syn keyword pfService tacacs tacas+ talk tap tcpmux telnet tempo +syn keyword pfService tftp time timed timeserver timserver tsap +syn keyword pfService ttylink ttytst ub-dns-control ulistserv untp +syn keyword pfService usenet users uucp uucp-path uucpd vnc vxlan +syn keyword pfService wais webster who whod whois www x400 x400-snd +syn keyword pfService xcept xdmcp xmpp-bosh xmpp-client xmpp-server +syn keyword pfService z3950 zabbix-agent zabbix-trapper zebra +syn keyword pfService zebrasrv + +hi def link pfCmd Statement +hi def link pfComment Comment +hi def link pfCont Statement +hi def link pfErrClose Error +hi def link pfIPv4 Type +hi def link pfIPv6 Type +hi def link pfNetmask Constant +hi def link pfNum Constant +hi def link pfService Constant +hi def link pfString String +hi def link pfTable Identifier +hi def link pfTodo Todo +hi def link pfVar Identifier +hi def link pfVarAssign Identifier +hi def link pfWildAddr Type + +let b:current_syntax = "pf" + +endif diff --git a/syntax/pfmain.vim b/syntax/pfmain.vim new file mode 100644 index 0000000..3bd18dc --- /dev/null +++ b/syntax/pfmain.vim @@ -0,0 +1,1839 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Postfix main.cf configuration +" Maintainer: KELEMEN Peter +" Last Updates: Anton Shestakov, Hong Xu +" Last Change: 2015 Feb 10 +" Version: 0.40 +" URL: http://cern.ch/fuji/vim/syntax/pfmain.vim +" Comment: Based on Postfix 2.12/3.0 postconf.5.html. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=@,48-57,_,- + +syntax case match +syntax sync minlines=1 + +syntax keyword pfmainConf 2bounce_notice_recipient +syntax keyword pfmainConf access_map_defer_code +syntax keyword pfmainConf access_map_reject_code +syntax keyword pfmainConf address_verify_cache_cleanup_interval +syntax keyword pfmainConf address_verify_default_transport +syntax keyword pfmainConf address_verify_local_transport +syntax keyword pfmainConf address_verify_map +syntax keyword pfmainConf address_verify_negative_cache +syntax keyword pfmainConf address_verify_negative_expire_time +syntax keyword pfmainConf address_verify_negative_refresh_time +syntax keyword pfmainConf address_verify_poll_count +syntax keyword pfmainConf address_verify_poll_delay +syntax keyword pfmainConf address_verify_positive_expire_time +syntax keyword pfmainConf address_verify_positive_refresh_time +syntax keyword pfmainConf address_verify_relay_transport +syntax keyword pfmainConf address_verify_relayhost +syntax keyword pfmainConf address_verify_sender +syntax keyword pfmainConf address_verify_sender_dependent_default_transport_maps +syntax keyword pfmainConf address_verify_sender_dependent_relayhost_maps +syntax keyword pfmainConf address_verify_sender_ttl +syntax keyword pfmainConf address_verify_service_name +syntax keyword pfmainConf address_verify_transport_maps +syntax keyword pfmainConf address_verify_virtual_transport +syntax keyword pfmainConf alias_database +syntax keyword pfmainConf alias_maps +syntax keyword pfmainConf allow_mail_to_commands +syntax keyword pfmainConf allow_mail_to_files +syntax keyword pfmainConf allow_min_user +syntax keyword pfmainConf allow_percent_hack +syntax keyword pfmainConf allow_untrusted_routing +syntax keyword pfmainConf alternate_config_directories +syntax keyword pfmainConf always_add_missing_headers +syntax keyword pfmainConf always_bcc +syntax keyword pfmainConf anvil_rate_time_unit +syntax keyword pfmainConf anvil_status_update_time +syntax keyword pfmainConf append_at_myorigin +syntax keyword pfmainConf append_dot_mydomain +syntax keyword pfmainConf application_event_drain_time +syntax keyword pfmainConf authorized_flush_users +syntax keyword pfmainConf authorized_mailq_users +syntax keyword pfmainConf authorized_submit_users +syntax keyword pfmainConf authorized_verp_clients +syntax keyword pfmainConf backwards_bounce_logfile_compatibility +syntax keyword pfmainConf berkeley_db_create_buffer_size +syntax keyword pfmainConf berkeley_db_read_buffer_size +syntax keyword pfmainConf best_mx_transport +syntax keyword pfmainConf biff +syntax keyword pfmainConf body_checks +syntax keyword pfmainConf body_checks_size_limit +syntax keyword pfmainConf bounce_notice_recipient +syntax keyword pfmainConf bounce_queue_lifetime +syntax keyword pfmainConf bounce_service_name +syntax keyword pfmainConf bounce_size_limit +syntax keyword pfmainConf bounce_template_file +syntax keyword pfmainConf broken_sasl_auth_clients +syntax keyword pfmainConf canonical_classes +syntax keyword pfmainConf canonical_maps +syntax keyword pfmainConf cleanup_service_name +syntax keyword pfmainConf command_directory +syntax keyword pfmainConf command_execution_directory +syntax keyword pfmainConf command_expansion_filter +syntax keyword pfmainConf command_time_limit +syntax keyword pfmainConf compatibility_level +syntax keyword pfmainConf config_directory +syntax keyword pfmainConf confirm_delay_cleared +syntax keyword pfmainConf connection_cache_protocol_timeout +syntax keyword pfmainConf connection_cache_service_name +syntax keyword pfmainConf connection_cache_status_update_time +syntax keyword pfmainConf connection_cache_ttl_limit +syntax keyword pfmainConf content_filter +syntax keyword pfmainConf cyrus_sasl_config_path +syntax keyword pfmainConf daemon_directory +syntax keyword pfmainConf daemon_table_open_error_is_fatal +syntax keyword pfmainConf daemon_timeout +syntax keyword pfmainConf data_directory +syntax keyword pfmainConf debug_peer_level +syntax keyword pfmainConf debug_peer_list +syntax keyword pfmainConf debugger_command +syntax keyword pfmainConf default_database_type +syntax keyword pfmainConf default_delivery_slot_cost +syntax keyword pfmainConf default_delivery_slot_discount +syntax keyword pfmainConf default_delivery_slot_loan +syntax keyword pfmainConf default_delivery_status_filter +syntax keyword pfmainConf default_destination_concurrency_failed_cohort_limit +syntax keyword pfmainConf default_destination_concurrency_limit +syntax keyword pfmainConf default_destination_concurrency_negative_feedback +syntax keyword pfmainConf default_destination_concurrency_positive_feedback +syntax keyword pfmainConf default_destination_rate_delay +syntax keyword pfmainConf default_destination_recipient_limit +syntax keyword pfmainConf default_extra_recipient_limit +syntax keyword pfmainConf default_filter_nexthop +syntax keyword pfmainConf default_minimum_delivery_slots +syntax keyword pfmainConf default_privs +syntax keyword pfmainConf default_process_limit +syntax keyword pfmainConf default_rbl_reply +syntax keyword pfmainConf default_recipient_limit +syntax keyword pfmainConf default_recipient_refill_delay +syntax keyword pfmainConf default_recipient_refill_limit +syntax keyword pfmainConf default_transport +syntax keyword pfmainConf default_verp_delimiters +syntax keyword pfmainConf defer_code +syntax keyword pfmainConf defer_service_name +syntax keyword pfmainConf defer_transports +syntax keyword pfmainConf delay_logging_resolution_limit +syntax keyword pfmainConf delay_notice_recipient +syntax keyword pfmainConf delay_warning_time +syntax keyword pfmainConf deliver_lock_attempts +syntax keyword pfmainConf deliver_lock_delay +syntax keyword pfmainConf destination_concurrency_feedback_debug +syntax keyword pfmainConf detect_8bit_encoding_header +syntax keyword pfmainConf disable_dns_lookups +syntax keyword pfmainConf disable_mime_input_processing +syntax keyword pfmainConf disable_mime_output_conversion +syntax keyword pfmainConf disable_verp_bounces +syntax keyword pfmainConf disable_vrfy_command +syntax keyword pfmainConf dnsblog_reply_delay +syntax keyword pfmainConf dnsblog_service_name +syntax keyword pfmainConf dont_remove +syntax keyword pfmainConf double_bounce_sender +syntax keyword pfmainConf duplicate_filter_limit +syntax keyword pfmainConf empty_address_default_transport_maps_lookup_key +syntax keyword pfmainConf empty_address_recipient +syntax keyword pfmainConf empty_address_relayhost_maps_lookup_key +syntax keyword pfmainConf enable_errors_to +syntax keyword pfmainConf enable_long_queue_ids +syntax keyword pfmainConf enable_original_recipient +syntax keyword pfmainConf error_notice_recipient +syntax keyword pfmainConf error_service_name +syntax keyword pfmainConf execution_directory_expansion_filter +syntax keyword pfmainConf expand_owner_alias +syntax keyword pfmainConf export_environment +syntax keyword pfmainConf extract_recipient_limit +syntax keyword pfmainConf fallback_relay +syntax keyword pfmainConf fallback_transport +syntax keyword pfmainConf fallback_transport_maps +syntax keyword pfmainConf fast_flush_domains +syntax keyword pfmainConf fast_flush_purge_time +syntax keyword pfmainConf fast_flush_refresh_time +syntax keyword pfmainConf fault_injection_code +syntax keyword pfmainConf flush_service_name +syntax keyword pfmainConf fork_attempts +syntax keyword pfmainConf fork_delay +syntax keyword pfmainConf forward_expansion_filter +syntax keyword pfmainConf forward_path +syntax keyword pfmainConf frozen_delivered_to +syntax keyword pfmainConf hash_queue_depth +syntax keyword pfmainConf hash_queue_names +syntax keyword pfmainConf header_address_token_limit +syntax keyword pfmainConf header_checks +syntax keyword pfmainConf header_size_limit +syntax keyword pfmainConf helpful_warnings +syntax keyword pfmainConf home_mailbox +syntax keyword pfmainConf hopcount_limit +syntax keyword pfmainConf html_directory +syntax keyword pfmainConf ignore_mx_lookup_error +syntax keyword pfmainConf import_environment +syntax keyword pfmainConf in_flow_delay +syntax keyword pfmainConf inet_interfaces +syntax keyword pfmainConf inet_protocols +syntax keyword pfmainConf initial_destination_concurrency +syntax keyword pfmainConf internal_mail_filter_classes +syntax keyword pfmainConf invalid_hostname_reject_code +syntax keyword pfmainConf ipc_idle +syntax keyword pfmainConf ipc_timeout +syntax keyword pfmainConf ipc_ttl +syntax keyword pfmainConf line_length_limit +syntax keyword pfmainConf lmdb_map_size +syntax keyword pfmainConf lmtp_address_preference +syntax keyword pfmainConf lmtp_address_verify_target +syntax keyword pfmainConf lmtp_assume_final +syntax keyword pfmainConf lmtp_bind_address +syntax keyword pfmainConf lmtp_bind_address6 +syntax keyword pfmainConf lmtp_body_checks +syntax keyword pfmainConf lmtp_cache_connection +syntax keyword pfmainConf lmtp_cname_overrides_servername +syntax keyword pfmainConf lmtp_connect_timeout +syntax keyword pfmainConf lmtp_connection_cache_destinations +syntax keyword pfmainConf lmtp_connection_cache_on_demand +syntax keyword pfmainConf lmtp_connection_cache_time_limit +syntax keyword pfmainConf lmtp_connection_reuse_count_limit +syntax keyword pfmainConf lmtp_connection_reuse_time_limit +syntax keyword pfmainConf lmtp_data_done_timeout +syntax keyword pfmainConf lmtp_data_init_timeout +syntax keyword pfmainConf lmtp_data_xfer_timeout +syntax keyword pfmainConf lmtp_defer_if_no_mx_address_found +syntax keyword pfmainConf lmtp_delivery_status_filter +syntax keyword pfmainConf lmtp_destination_concurrency_limit +syntax keyword pfmainConf lmtp_destination_recipient_limit +syntax keyword pfmainConf lmtp_discard_lhlo_keyword_address_maps +syntax keyword pfmainConf lmtp_discard_lhlo_keywords +syntax keyword pfmainConf lmtp_dns_reply_filter +syntax keyword pfmainConf lmtp_dns_resolver_options +syntax keyword pfmainConf lmtp_dns_support_level +syntax keyword pfmainConf lmtp_enforce_tls +syntax keyword pfmainConf lmtp_generic_maps +syntax keyword pfmainConf lmtp_header_checks +syntax keyword pfmainConf lmtp_host_lookup +syntax keyword pfmainConf lmtp_lhlo_name +syntax keyword pfmainConf lmtp_lhlo_timeout +syntax keyword pfmainConf lmtp_line_length_limit +syntax keyword pfmainConf lmtp_mail_timeout +syntax keyword pfmainConf lmtp_mime_header_checks +syntax keyword pfmainConf lmtp_mx_address_limit +syntax keyword pfmainConf lmtp_mx_session_limit +syntax keyword pfmainConf lmtp_nested_header_checks +syntax keyword pfmainConf lmtp_per_record_deadline +syntax keyword pfmainConf lmtp_pix_workaround_delay_time +syntax keyword pfmainConf lmtp_pix_workaround_maps +syntax keyword pfmainConf lmtp_pix_workaround_threshold_time +syntax keyword pfmainConf lmtp_pix_workarounds +syntax keyword pfmainConf lmtp_quit_timeout +syntax keyword pfmainConf lmtp_quote_rfc821_envelope +syntax keyword pfmainConf lmtp_randomize_addresses +syntax keyword pfmainConf lmtp_rcpt_timeout +syntax keyword pfmainConf lmtp_reply_filter +syntax keyword pfmainConf lmtp_rset_timeout +syntax keyword pfmainConf lmtp_sasl_auth_cache_name +syntax keyword pfmainConf lmtp_sasl_auth_cache_time +syntax keyword pfmainConf lmtp_sasl_auth_enable +syntax keyword pfmainConf lmtp_sasl_auth_soft_bounce +syntax keyword pfmainConf lmtp_sasl_mechanism_filter +syntax keyword pfmainConf lmtp_sasl_password_maps +syntax keyword pfmainConf lmtp_sasl_path +syntax keyword pfmainConf lmtp_sasl_security_options +syntax keyword pfmainConf lmtp_sasl_tls_security_options +syntax keyword pfmainConf lmtp_sasl_tls_verified_security_options +syntax keyword pfmainConf lmtp_sasl_type +syntax keyword pfmainConf lmtp_send_dummy_mail_auth +syntax keyword pfmainConf lmtp_send_xforward_command +syntax keyword pfmainConf lmtp_sender_dependent_authentication +syntax keyword pfmainConf lmtp_skip_5xx_greeting +syntax keyword pfmainConf lmtp_skip_quit_response +syntax keyword pfmainConf lmtp_starttls_timeout +syntax keyword pfmainConf lmtp_tcp_port +syntax keyword pfmainConf lmtp_tls_CAfile +syntax keyword pfmainConf lmtp_tls_CApath +syntax keyword pfmainConf lmtp_tls_block_early_mail_reply +syntax keyword pfmainConf lmtp_tls_cert_file +syntax keyword pfmainConf lmtp_tls_ciphers +syntax keyword pfmainConf lmtp_tls_dcert_file +syntax keyword pfmainConf lmtp_tls_dkey_file +syntax keyword pfmainConf lmtp_tls_eccert_file +syntax keyword pfmainConf lmtp_tls_eckey_file +syntax keyword pfmainConf lmtp_tls_enforce_peername +syntax keyword pfmainConf lmtp_tls_exclude_ciphers +syntax keyword pfmainConf lmtp_tls_fingerprint_cert_match +syntax keyword pfmainConf lmtp_tls_fingerprint_digest +syntax keyword pfmainConf lmtp_tls_force_insecure_host_tlsa_lookup +syntax keyword pfmainConf lmtp_tls_key_file +syntax keyword pfmainConf lmtp_tls_loglevel +syntax keyword pfmainConf lmtp_tls_mandatory_ciphers +syntax keyword pfmainConf lmtp_tls_mandatory_exclude_ciphers +syntax keyword pfmainConf lmtp_tls_mandatory_protocols +syntax keyword pfmainConf lmtp_tls_note_starttls_offer +syntax keyword pfmainConf lmtp_tls_per_site +syntax keyword pfmainConf lmtp_tls_policy_maps +syntax keyword pfmainConf lmtp_tls_protocols +syntax keyword pfmainConf lmtp_tls_scert_verifydepth +syntax keyword pfmainConf lmtp_tls_secure_cert_match +syntax keyword pfmainConf lmtp_tls_security_level +syntax keyword pfmainConf lmtp_tls_session_cache_database +syntax keyword pfmainConf lmtp_tls_session_cache_timeout +syntax keyword pfmainConf lmtp_tls_trust_anchor_file +syntax keyword pfmainConf lmtp_tls_verify_cert_match +syntax keyword pfmainConf lmtp_use_tls +syntax keyword pfmainConf lmtp_xforward_timeout +syntax keyword pfmainConf local_command_shell +syntax keyword pfmainConf local_delivery_status_filter +syntax keyword pfmainConf local_destination_concurrency_limit +syntax keyword pfmainConf local_destination_recipient_limit +syntax keyword pfmainConf local_header_rewrite_clients +syntax keyword pfmainConf local_recipient_maps +syntax keyword pfmainConf local_transport +syntax keyword pfmainConf luser_relay +syntax keyword pfmainConf mail_name +syntax keyword pfmainConf mail_owner +syntax keyword pfmainConf mail_release_date +syntax keyword pfmainConf mail_spool_directory +syntax keyword pfmainConf mail_version +syntax keyword pfmainConf mailbox_command +syntax keyword pfmainConf mailbox_command_maps +syntax keyword pfmainConf mailbox_delivery_lock +syntax keyword pfmainConf mailbox_size_limit +syntax keyword pfmainConf mailbox_transport +syntax keyword pfmainConf mailbox_transport_maps +syntax keyword pfmainConf mailq_path +syntax keyword pfmainConf manpage_directory +syntax keyword pfmainConf maps_rbl_domains +syntax keyword pfmainConf maps_rbl_reject_code +syntax keyword pfmainConf masquerade_classes +syntax keyword pfmainConf masquerade_domains +syntax keyword pfmainConf masquerade_exceptions +syntax keyword pfmainConf master_service_disable +syntax keyword pfmainConf max_idle +syntax keyword pfmainConf max_use +syntax keyword pfmainConf maximal_backoff_time +syntax keyword pfmainConf maximal_queue_lifetime +syntax keyword pfmainConf message_drop_headers +syntax keyword pfmainConf message_reject_characters +syntax keyword pfmainConf message_size_limit +syntax keyword pfmainConf message_strip_characters +syntax keyword pfmainConf meta_directory +syntax keyword pfmainConf milter_command_timeout +syntax keyword pfmainConf milter_connect_macros +syntax keyword pfmainConf milter_connect_timeout +syntax keyword pfmainConf milter_content_timeout +syntax keyword pfmainConf milter_data_macros +syntax keyword pfmainConf milter_default_action +syntax keyword pfmainConf milter_end_of_data_macros +syntax keyword pfmainConf milter_end_of_header_macros +syntax keyword pfmainConf milter_header_checks +syntax keyword pfmainConf milter_helo_macros +syntax keyword pfmainConf milter_macro_daemon_name +syntax keyword pfmainConf milter_macro_v +syntax keyword pfmainConf milter_mail_macros +syntax keyword pfmainConf milter_protocol +syntax keyword pfmainConf milter_rcpt_macros +syntax keyword pfmainConf milter_unknown_command_macros +syntax keyword pfmainConf mime_boundary_length_limit +syntax keyword pfmainConf mime_header_checks +syntax keyword pfmainConf mime_nesting_limit +syntax keyword pfmainConf minimal_backoff_time +syntax keyword pfmainConf multi_instance_directories +syntax keyword pfmainConf multi_instance_enable +syntax keyword pfmainConf multi_instance_group +syntax keyword pfmainConf multi_instance_name +syntax keyword pfmainConf multi_instance_wrapper +syntax keyword pfmainConf multi_recipient_bounce_reject_code +syntax keyword pfmainConf mydestination +syntax keyword pfmainConf mydomain +syntax keyword pfmainConf myhostname +syntax keyword pfmainConf mynetworks +syntax keyword pfmainConf mynetworks_style +syntax keyword pfmainConf myorigin +syntax keyword pfmainConf nested_header_checks +syntax keyword pfmainConf newaliases_path +syntax keyword pfmainConf non_fqdn_reject_code +syntax keyword pfmainConf non_smtpd_milters +syntax keyword pfmainConf notify_classes +syntax keyword pfmainConf nullmx_reject_code +syntax keyword pfmainConf owner_request_special +syntax keyword pfmainConf parent_domain_matches_subdomains +syntax keyword pfmainConf permit_mx_backup_networks +syntax keyword pfmainConf pickup_service_name +syntax keyword pfmainConf pipe_delivery_status_filter +syntax keyword pfmainConf plaintext_reject_code +syntax keyword pfmainConf postmulti_control_commands +syntax keyword pfmainConf postmulti_start_commands +syntax keyword pfmainConf postmulti_stop_commands +syntax keyword pfmainConf postscreen_access_list +syntax keyword pfmainConf postscreen_bare_newline_action +syntax keyword pfmainConf postscreen_bare_newline_enable +syntax keyword pfmainConf postscreen_bare_newline_ttl +syntax keyword pfmainConf postscreen_blacklist_action +syntax keyword pfmainConf postscreen_cache_cleanup_interval +syntax keyword pfmainConf postscreen_cache_map +syntax keyword pfmainConf postscreen_cache_retention_time +syntax keyword pfmainConf postscreen_client_connection_count_limit +syntax keyword pfmainConf postscreen_command_count_limit +syntax keyword pfmainConf postscreen_command_filter +syntax keyword pfmainConf postscreen_command_time_limit +syntax keyword pfmainConf postscreen_disable_vrfy_command +syntax keyword pfmainConf postscreen_discard_ehlo_keyword_address_maps +syntax keyword pfmainConf postscreen_discard_ehlo_keywords +syntax keyword pfmainConf postscreen_dnsbl_action +syntax keyword pfmainConf postscreen_dnsbl_reply_map +syntax keyword pfmainConf postscreen_dnsbl_sites +syntax keyword pfmainConf postscreen_dnsbl_threshold +syntax keyword pfmainConf postscreen_dnsbl_timeout +syntax keyword pfmainConf postscreen_dnsbl_ttl +syntax keyword pfmainConf postscreen_dnsbl_whitelist_threshold +syntax keyword pfmainConf postscreen_enforce_tls +syntax keyword pfmainConf postscreen_expansion_filter +syntax keyword pfmainConf postscreen_forbidden_commands +syntax keyword pfmainConf postscreen_greet_action +syntax keyword pfmainConf postscreen_greet_banner +syntax keyword pfmainConf postscreen_greet_ttl +syntax keyword pfmainConf postscreen_greet_wait +syntax keyword pfmainConf postscreen_helo_required +syntax keyword pfmainConf postscreen_non_smtp_command_action +syntax keyword pfmainConf postscreen_non_smtp_command_enable +syntax keyword pfmainConf postscreen_non_smtp_command_ttl +syntax keyword pfmainConf postscreen_pipelining_action +syntax keyword pfmainConf postscreen_pipelining_enable +syntax keyword pfmainConf postscreen_pipelining_ttl +syntax keyword pfmainConf postscreen_post_queue_limit +syntax keyword pfmainConf postscreen_pre_queue_limit +syntax keyword pfmainConf postscreen_reject_footer +syntax keyword pfmainConf postscreen_tls_security_level +syntax keyword pfmainConf postscreen_upstream_proxy_protocol +syntax keyword pfmainConf postscreen_upstream_proxy_timeout +syntax keyword pfmainConf postscreen_use_tls +syntax keyword pfmainConf postscreen_watchdog_timeout +syntax keyword pfmainConf postscreen_whitelist_interfaces +syntax keyword pfmainConf prepend_delivered_header +syntax keyword pfmainConf process_id +syntax keyword pfmainConf process_id_directory +syntax keyword pfmainConf process_name +syntax keyword pfmainConf propagate_unmatched_extensions +syntax keyword pfmainConf proxy_interfaces +syntax keyword pfmainConf proxy_read_maps +syntax keyword pfmainConf proxy_write_maps +syntax keyword pfmainConf proxymap_service_name +syntax keyword pfmainConf proxywrite_service_name +syntax keyword pfmainConf qmgr_clog_warn_time +syntax keyword pfmainConf qmgr_daemon_timeout +syntax keyword pfmainConf qmgr_fudge_factor +syntax keyword pfmainConf qmgr_ipc_timeout +syntax keyword pfmainConf qmgr_message_active_limit +syntax keyword pfmainConf qmgr_message_recipient_limit +syntax keyword pfmainConf qmgr_message_recipient_minimum +syntax keyword pfmainConf qmqpd_authorized_clients +syntax keyword pfmainConf qmqpd_client_port_logging +syntax keyword pfmainConf qmqpd_error_delay +syntax keyword pfmainConf qmqpd_timeout +syntax keyword pfmainConf queue_directory +syntax keyword pfmainConf queue_file_attribute_count_limit +syntax keyword pfmainConf queue_minfree +syntax keyword pfmainConf queue_run_delay +syntax keyword pfmainConf queue_service_name +syntax keyword pfmainConf rbl_reply_maps +syntax keyword pfmainConf readme_directory +syntax keyword pfmainConf receive_override_options +syntax keyword pfmainConf recipient_bcc_maps +syntax keyword pfmainConf recipient_canonical_classes +syntax keyword pfmainConf recipient_canonical_maps +syntax keyword pfmainConf recipient_delimiter +syntax keyword pfmainConf reject_code +syntax keyword pfmainConf reject_tempfail_action +syntax keyword pfmainConf relay_clientcerts +syntax keyword pfmainConf relay_destination_concurrency_limit +syntax keyword pfmainConf relay_destination_recipient_limit +syntax keyword pfmainConf relay_domains +syntax keyword pfmainConf relay_domains_reject_code +syntax keyword pfmainConf relay_recipient_maps +syntax keyword pfmainConf relay_transport +syntax keyword pfmainConf relayhost +syntax keyword pfmainConf relocated_maps +syntax keyword pfmainConf remote_header_rewrite_domain +syntax keyword pfmainConf require_home_directory +syntax keyword pfmainConf reset_owner_alias +syntax keyword pfmainConf resolve_dequoted_address +syntax keyword pfmainConf resolve_null_domain +syntax keyword pfmainConf resolve_numeric_domain +syntax keyword pfmainConf rewrite_service_name +syntax keyword pfmainConf sample_directory +syntax keyword pfmainConf send_cyrus_sasl_authzid +syntax keyword pfmainConf sender_based_routing +syntax keyword pfmainConf sender_bcc_maps +syntax keyword pfmainConf sender_canonical_classes +syntax keyword pfmainConf sender_canonical_maps +syntax keyword pfmainConf sender_dependent_default_transport_maps +syntax keyword pfmainConf sender_dependent_relayhost_maps +syntax keyword pfmainConf sendmail_fix_line_endings +syntax keyword pfmainConf sendmail_path +syntax keyword pfmainConf service_throttle_time +syntax keyword pfmainConf setgid_group +syntax keyword pfmainConf shlib_directory +syntax keyword pfmainConf show_user_unknown_table_name +syntax keyword pfmainConf showq_service_name +syntax keyword pfmainConf smtp_address_preference +syntax keyword pfmainConf smtp_address_verify_target +syntax keyword pfmainConf smtp_always_send_ehlo +syntax keyword pfmainConf smtp_bind_address +syntax keyword pfmainConf smtp_bind_address6 +syntax keyword pfmainConf smtp_body_checks +syntax keyword pfmainConf smtp_cname_overrides_servername +syntax keyword pfmainConf smtp_connect_timeout +syntax keyword pfmainConf smtp_connection_cache_destinations +syntax keyword pfmainConf smtp_connection_cache_on_demand +syntax keyword pfmainConf smtp_connection_cache_time_limit +syntax keyword pfmainConf smtp_connection_reuse_count_limit +syntax keyword pfmainConf smtp_connection_reuse_time_limit +syntax keyword pfmainConf smtp_data_done_timeout +syntax keyword pfmainConf smtp_data_init_timeout +syntax keyword pfmainConf smtp_data_xfer_timeout +syntax keyword pfmainConf smtp_defer_if_no_mx_address_found +syntax keyword pfmainConf smtp_delivery_status_filter +syntax keyword pfmainConf smtp_destination_concurrency_limit +syntax keyword pfmainConf smtp_destination_recipient_limit +syntax keyword pfmainConf smtp_discard_ehlo_keyword_address_maps +syntax keyword pfmainConf smtp_discard_ehlo_keywords +syntax keyword pfmainConf smtp_dns_reply_filter +syntax keyword pfmainConf smtp_dns_resolver_options +syntax keyword pfmainConf smtp_dns_support_level +syntax keyword pfmainConf smtp_enforce_tls +syntax keyword pfmainConf smtp_fallback_relay +syntax keyword pfmainConf smtp_generic_maps +syntax keyword pfmainConf smtp_header_checks +syntax keyword pfmainConf smtp_helo_name +syntax keyword pfmainConf smtp_helo_timeout +syntax keyword pfmainConf smtp_host_lookup +syntax keyword pfmainConf smtp_line_length_limit +syntax keyword pfmainConf smtp_mail_timeout +syntax keyword pfmainConf smtp_mime_header_checks +syntax keyword pfmainConf smtp_mx_address_limit +syntax keyword pfmainConf smtp_mx_session_limit +syntax keyword pfmainConf smtp_nested_header_checks +syntax keyword pfmainConf smtp_never_send_ehlo +syntax keyword pfmainConf smtp_per_record_deadline +syntax keyword pfmainConf smtp_pix_workaround_delay_time +syntax keyword pfmainConf smtp_pix_workaround_maps +syntax keyword pfmainConf smtp_pix_workaround_threshold_time +syntax keyword pfmainConf smtp_pix_workarounds +syntax keyword pfmainConf smtp_quit_timeout +syntax keyword pfmainConf smtp_quote_rfc821_envelope +syntax keyword pfmainConf smtp_randomize_addresses +syntax keyword pfmainConf smtp_rcpt_timeout +syntax keyword pfmainConf smtp_reply_filter +syntax keyword pfmainConf smtp_rset_timeout +syntax keyword pfmainConf smtp_sasl_auth_cache_name +syntax keyword pfmainConf smtp_sasl_auth_cache_time +syntax keyword pfmainConf smtp_sasl_auth_enable +syntax keyword pfmainConf smtp_sasl_auth_soft_bounce +syntax keyword pfmainConf smtp_sasl_mechanism_filter +syntax keyword pfmainConf smtp_sasl_password_maps +syntax keyword pfmainConf smtp_sasl_path +syntax keyword pfmainConf smtp_sasl_security_options +syntax keyword pfmainConf smtp_sasl_tls_security_options +syntax keyword pfmainConf smtp_sasl_tls_verified_security_options +syntax keyword pfmainConf smtp_sasl_type +syntax keyword pfmainConf smtp_send_dummy_mail_auth +syntax keyword pfmainConf smtp_send_xforward_command +syntax keyword pfmainConf smtp_sender_dependent_authentication +syntax keyword pfmainConf smtp_skip_4xx_greeting +syntax keyword pfmainConf smtp_skip_5xx_greeting +syntax keyword pfmainConf smtp_skip_quit_response +syntax keyword pfmainConf smtp_starttls_timeout +syntax keyword pfmainConf smtp_tls_CAfile +syntax keyword pfmainConf smtp_tls_CApath +syntax keyword pfmainConf smtp_tls_block_early_mail_reply +syntax keyword pfmainConf smtp_tls_cert_file +syntax keyword pfmainConf smtp_tls_cipherlist +syntax keyword pfmainConf smtp_tls_ciphers +syntax keyword pfmainConf smtp_tls_dcert_file +syntax keyword pfmainConf smtp_tls_dkey_file +syntax keyword pfmainConf smtp_tls_eccert_file +syntax keyword pfmainConf smtp_tls_eckey_file +syntax keyword pfmainConf smtp_tls_enforce_peername +syntax keyword pfmainConf smtp_tls_exclude_ciphers +syntax keyword pfmainConf smtp_tls_fingerprint_cert_match +syntax keyword pfmainConf smtp_tls_fingerprint_digest +syntax keyword pfmainConf smtp_tls_force_insecure_host_tlsa_lookup +syntax keyword pfmainConf smtp_tls_key_file +syntax keyword pfmainConf smtp_tls_loglevel +syntax keyword pfmainConf smtp_tls_mandatory_ciphers +syntax keyword pfmainConf smtp_tls_mandatory_exclude_ciphers +syntax keyword pfmainConf smtp_tls_mandatory_protocols +syntax keyword pfmainConf smtp_tls_note_starttls_offer +syntax keyword pfmainConf smtp_tls_per_site +syntax keyword pfmainConf smtp_tls_policy_maps +syntax keyword pfmainConf smtp_tls_protocols +syntax keyword pfmainConf smtp_tls_scert_verifydepth +syntax keyword pfmainConf smtp_tls_secure_cert_match +syntax keyword pfmainConf smtp_tls_security_level +syntax keyword pfmainConf smtp_tls_session_cache_database +syntax keyword pfmainConf smtp_tls_session_cache_timeout +syntax keyword pfmainConf smtp_tls_trust_anchor_file +syntax keyword pfmainConf smtp_tls_verify_cert_match +syntax keyword pfmainConf smtp_tls_wrappermode +syntax keyword pfmainConf smtp_use_tls +syntax keyword pfmainConf smtp_xforward_timeout +syntax keyword pfmainConf smtpd_authorized_verp_clients +syntax keyword pfmainConf smtpd_authorized_xclient_hosts +syntax keyword pfmainConf smtpd_authorized_xforward_hosts +syntax keyword pfmainConf smtpd_banner +syntax keyword pfmainConf smtpd_client_connection_count_limit +syntax keyword pfmainConf smtpd_client_connection_rate_limit +syntax keyword pfmainConf smtpd_client_event_limit_exceptions +syntax keyword pfmainConf smtpd_client_message_rate_limit +syntax keyword pfmainConf smtpd_client_new_tls_session_rate_limit +syntax keyword pfmainConf smtpd_client_port_logging +syntax keyword pfmainConf smtpd_client_recipient_rate_limit +syntax keyword pfmainConf smtpd_client_restrictions +syntax keyword pfmainConf smtpd_command_filter +syntax keyword pfmainConf smtpd_data_restrictions +syntax keyword pfmainConf smtpd_delay_open_until_valid_rcpt +syntax keyword pfmainConf smtpd_delay_reject +syntax keyword pfmainConf smtpd_discard_ehlo_keyword_address_maps +syntax keyword pfmainConf smtpd_discard_ehlo_keywords +syntax keyword pfmainConf smtpd_dns_reply_filter +syntax keyword pfmainConf smtpd_end_of_data_restrictions +syntax keyword pfmainConf smtpd_enforce_tls +syntax keyword pfmainConf smtpd_error_sleep_time +syntax keyword pfmainConf smtpd_etrn_restrictions +syntax keyword pfmainConf smtpd_expansion_filter +syntax keyword pfmainConf smtpd_forbidden_commands +syntax keyword pfmainConf smtpd_hard_error_limit +syntax keyword pfmainConf smtpd_helo_required +syntax keyword pfmainConf smtpd_helo_restrictions +syntax keyword pfmainConf smtpd_history_flush_threshold +syntax keyword pfmainConf smtpd_junk_command_limit +syntax keyword pfmainConf smtpd_log_access_permit_actions +syntax keyword pfmainConf smtpd_milters +syntax keyword pfmainConf smtpd_noop_commands +syntax keyword pfmainConf smtpd_null_access_lookup_key +syntax keyword pfmainConf smtpd_peername_lookup +syntax keyword pfmainConf smtpd_per_record_deadline +syntax keyword pfmainConf smtpd_policy_service_default_action +syntax keyword pfmainConf smtpd_policy_service_max_idle +syntax keyword pfmainConf smtpd_policy_service_max_ttl +syntax keyword pfmainConf smtpd_policy_service_request_limit +syntax keyword pfmainConf smtpd_policy_service_retry_delay +syntax keyword pfmainConf smtpd_policy_service_timeout +syntax keyword pfmainConf smtpd_policy_service_try_limit +syntax keyword pfmainConf smtpd_proxy_ehlo +syntax keyword pfmainConf smtpd_proxy_filter +syntax keyword pfmainConf smtpd_proxy_options +syntax keyword pfmainConf smtpd_proxy_timeout +syntax keyword pfmainConf smtpd_recipient_limit +syntax keyword pfmainConf smtpd_recipient_overshoot_limit +syntax keyword pfmainConf smtpd_recipient_restrictions +syntax keyword pfmainConf smtpd_reject_footer +syntax keyword pfmainConf smtpd_reject_unlisted_recipient +syntax keyword pfmainConf smtpd_reject_unlisted_sender +syntax keyword pfmainConf smtpd_relay_restrictions +syntax keyword pfmainConf smtpd_restriction_classes +syntax keyword pfmainConf smtpd_sasl_application_name +syntax keyword pfmainConf smtpd_sasl_auth_enable +syntax keyword pfmainConf smtpd_sasl_authenticated_header +syntax keyword pfmainConf smtpd_sasl_exceptions_networks +syntax keyword pfmainConf smtpd_sasl_local_domain +syntax keyword pfmainConf smtpd_sasl_path +syntax keyword pfmainConf smtpd_sasl_security_options +syntax keyword pfmainConf smtpd_sasl_service +syntax keyword pfmainConf smtpd_sasl_tls_security_options +syntax keyword pfmainConf smtpd_sasl_type +syntax keyword pfmainConf smtpd_sender_login_maps +syntax keyword pfmainConf smtpd_sender_restrictions +syntax keyword pfmainConf smtpd_service_name +syntax keyword pfmainConf smtpd_soft_error_limit +syntax keyword pfmainConf smtpd_starttls_timeout +syntax keyword pfmainConf smtpd_timeout +syntax keyword pfmainConf smtpd_tls_CAfile +syntax keyword pfmainConf smtpd_tls_CApath +syntax keyword pfmainConf smtpd_tls_always_issue_session_ids +syntax keyword pfmainConf smtpd_tls_ask_ccert +syntax keyword pfmainConf smtpd_tls_auth_only +syntax keyword pfmainConf smtpd_tls_ccert_verifydepth +syntax keyword pfmainConf smtpd_tls_cert_file +syntax keyword pfmainConf smtpd_tls_cipherlist +syntax keyword pfmainConf smtpd_tls_ciphers +syntax keyword pfmainConf smtpd_tls_dcert_file +syntax keyword pfmainConf smtpd_tls_dh1024_param_file +syntax keyword pfmainConf smtpd_tls_dh512_param_file +syntax keyword pfmainConf smtpd_tls_dkey_file +syntax keyword pfmainConf smtpd_tls_eccert_file +syntax keyword pfmainConf smtpd_tls_eckey_file +syntax keyword pfmainConf smtpd_tls_eecdh_grade +syntax keyword pfmainConf smtpd_tls_exclude_ciphers +syntax keyword pfmainConf smtpd_tls_fingerprint_digest +syntax keyword pfmainConf smtpd_tls_key_file +syntax keyword pfmainConf smtpd_tls_loglevel +syntax keyword pfmainConf smtpd_tls_mandatory_ciphers +syntax keyword pfmainConf smtpd_tls_mandatory_exclude_ciphers +syntax keyword pfmainConf smtpd_tls_mandatory_protocols +syntax keyword pfmainConf smtpd_tls_protocols +syntax keyword pfmainConf smtpd_tls_received_header +syntax keyword pfmainConf smtpd_tls_req_ccert +syntax keyword pfmainConf smtpd_tls_security_level +syntax keyword pfmainConf smtpd_tls_session_cache_database +syntax keyword pfmainConf smtpd_tls_session_cache_timeout +syntax keyword pfmainConf smtpd_tls_wrappermode +syntax keyword pfmainConf smtpd_upstream_proxy_protocol +syntax keyword pfmainConf smtpd_upstream_proxy_timeout +syntax keyword pfmainConf smtpd_use_tls +syntax keyword pfmainConf smtputf8_autodetect_classes +syntax keyword pfmainConf smtputf8_enable +syntax keyword pfmainConf soft_bounce +syntax keyword pfmainConf stale_lock_time +syntax keyword pfmainConf stress +syntax keyword pfmainConf strict_7bit_headers +syntax keyword pfmainConf strict_8bitmime +syntax keyword pfmainConf strict_8bitmime_body +syntax keyword pfmainConf strict_mailbox_ownership +syntax keyword pfmainConf strict_mime_encoding_domain +syntax keyword pfmainConf strict_rfc821_envelopes +syntax keyword pfmainConf strict_smtputf8 +syntax keyword pfmainConf sun_mailtool_compatibility +syntax keyword pfmainConf swap_bangpath +syntax keyword pfmainConf syslog_facility +syntax keyword pfmainConf syslog_name +syntax keyword pfmainConf tcp_windowsize +syntax keyword pfmainConf tls_append_default_CA +syntax keyword pfmainConf tls_daemon_random_bytes +syntax keyword pfmainConf tls_dane_digest_agility +syntax keyword pfmainConf tls_dane_digests +syntax keyword pfmainConf tls_dane_trust_anchor_digest_enable +syntax keyword pfmainConf tls_disable_workarounds +syntax keyword pfmainConf tls_eecdh_strong_curve +syntax keyword pfmainConf tls_eecdh_ultra_curve +syntax keyword pfmainConf tls_export_cipherlist +syntax keyword pfmainConf tls_high_cipherlist +syntax keyword pfmainConf tls_legacy_public_key_fingerprints +syntax keyword pfmainConf tls_low_cipherlist +syntax keyword pfmainConf tls_medium_cipherlist +syntax keyword pfmainConf tls_null_cipherlist +syntax keyword pfmainConf tls_preempt_cipherlist +syntax keyword pfmainConf tls_random_bytes +syntax keyword pfmainConf tls_random_exchange_name +syntax keyword pfmainConf tls_random_prng_update_period +syntax keyword pfmainConf tls_random_reseed_period +syntax keyword pfmainConf tls_random_source +syntax keyword pfmainConf tls_session_ticket_cipher +syntax keyword pfmainConf tls_ssl_options +syntax keyword pfmainConf tls_wildcard_matches_multiple_labels +syntax keyword pfmainConf tlsmgr_service_name +syntax keyword pfmainConf tlsproxy_enforce_tls +syntax keyword pfmainConf tlsproxy_service_name +syntax keyword pfmainConf tlsproxy_tls_CAfile +syntax keyword pfmainConf tlsproxy_tls_CApath +syntax keyword pfmainConf tlsproxy_tls_always_issue_session_ids +syntax keyword pfmainConf tlsproxy_tls_ask_ccert +syntax keyword pfmainConf tlsproxy_tls_ccert_verifydepth +syntax keyword pfmainConf tlsproxy_tls_cert_file +syntax keyword pfmainConf tlsproxy_tls_ciphers +syntax keyword pfmainConf tlsproxy_tls_dcert_file +syntax keyword pfmainConf tlsproxy_tls_dh1024_param_file +syntax keyword pfmainConf tlsproxy_tls_dh512_param_file +syntax keyword pfmainConf tlsproxy_tls_dkey_file +syntax keyword pfmainConf tlsproxy_tls_eccert_file +syntax keyword pfmainConf tlsproxy_tls_eckey_file +syntax keyword pfmainConf tlsproxy_tls_eecdh_grade +syntax keyword pfmainConf tlsproxy_tls_exclude_ciphers +syntax keyword pfmainConf tlsproxy_tls_fingerprint_digest +syntax keyword pfmainConf tlsproxy_tls_key_file +syntax keyword pfmainConf tlsproxy_tls_loglevel +syntax keyword pfmainConf tlsproxy_tls_mandatory_ciphers +syntax keyword pfmainConf tlsproxy_tls_mandatory_exclude_ciphers +syntax keyword pfmainConf tlsproxy_tls_mandatory_protocols +syntax keyword pfmainConf tlsproxy_tls_protocols +syntax keyword pfmainConf tlsproxy_tls_req_ccert +syntax keyword pfmainConf tlsproxy_tls_security_level +syntax keyword pfmainConf tlsproxy_tls_session_cache_timeout +syntax keyword pfmainConf tlsproxy_use_tls +syntax keyword pfmainConf tlsproxy_watchdog_timeout +syntax keyword pfmainConf trace_service_name +syntax keyword pfmainConf transport_delivery_slot_cost +syntax keyword pfmainConf transport_delivery_slot_discount +syntax keyword pfmainConf transport_delivery_slot_loan +syntax keyword pfmainConf transport_destination_concurrency_failed_cohort_limit +syntax keyword pfmainConf transport_destination_concurrency_limit +syntax keyword pfmainConf transport_destination_concurrency_negative_feedback +syntax keyword pfmainConf transport_destination_concurrency_positive_feedback +syntax keyword pfmainConf transport_destination_rate_delay +syntax keyword pfmainConf transport_destination_recipient_limit +syntax keyword pfmainConf transport_extra_recipient_limit +syntax keyword pfmainConf transport_initial_destination_concurrency +syntax keyword pfmainConf transport_maps +syntax keyword pfmainConf transport_minimum_delivery_slots +syntax keyword pfmainConf transport_recipient_limit +syntax keyword pfmainConf transport_recipient_refill_delay +syntax keyword pfmainConf transport_recipient_refill_limit +syntax keyword pfmainConf transport_retry_time +syntax keyword pfmainConf transport_time_limit +syntax keyword pfmainConf trigger_timeout +syntax keyword pfmainConf undisclosed_recipients_header +syntax keyword pfmainConf unknown_address_reject_code +syntax keyword pfmainConf unknown_address_tempfail_action +syntax keyword pfmainConf unknown_client_reject_code +syntax keyword pfmainConf unknown_helo_hostname_tempfail_action +syntax keyword pfmainConf unknown_hostname_reject_code +syntax keyword pfmainConf unknown_local_recipient_reject_code +syntax keyword pfmainConf unknown_relay_recipient_reject_code +syntax keyword pfmainConf unknown_virtual_alias_reject_code +syntax keyword pfmainConf unknown_virtual_mailbox_reject_code +syntax keyword pfmainConf unverified_recipient_defer_code +syntax keyword pfmainConf unverified_recipient_reject_code +syntax keyword pfmainConf unverified_recipient_reject_reason +syntax keyword pfmainConf unverified_recipient_tempfail_action +syntax keyword pfmainConf unverified_sender_defer_code +syntax keyword pfmainConf unverified_sender_reject_code +syntax keyword pfmainConf unverified_sender_reject_reason +syntax keyword pfmainConf unverified_sender_tempfail_action +syntax keyword pfmainConf verp_delimiter_filter +syntax keyword pfmainConf virtual_alias_address_length_limit +syntax keyword pfmainConf virtual_alias_domains +syntax keyword pfmainConf virtual_alias_expansion_limit +syntax keyword pfmainConf virtual_alias_maps +syntax keyword pfmainConf virtual_alias_recursion_limit +syntax keyword pfmainConf virtual_delivery_status_filter +syntax keyword pfmainConf virtual_destination_concurrency_limit +syntax keyword pfmainConf virtual_destination_recipient_limit +syntax keyword pfmainConf virtual_gid_maps +syntax keyword pfmainConf virtual_mailbox_base +syntax keyword pfmainConf virtual_mailbox_domains +syntax keyword pfmainConf virtual_mailbox_limit +syntax keyword pfmainConf virtual_mailbox_lock +syntax keyword pfmainConf virtual_mailbox_maps +syntax keyword pfmainConf virtual_maps +syntax keyword pfmainConf virtual_minimum_uid +syntax keyword pfmainConf virtual_transport +syntax keyword pfmainConf virtual_uid_maps +syntax match pfmainRef "$\<2bounce_notice_recipient\>" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" +syntax match pfmainRef "$\" + +syntax keyword pfmainWord accept +syntax keyword pfmainWord all +syntax keyword pfmainWord always +syntax keyword pfmainWord check_address_map +syntax keyword pfmainWord check_ccert_access +syntax keyword pfmainWord check_client_a_access +syntax keyword pfmainWord check_client_access +syntax keyword pfmainWord check_client_mx_access +syntax keyword pfmainWord check_client_ns_access +syntax keyword pfmainWord check_etrn_access +syntax keyword pfmainWord check_helo_a_access +syntax keyword pfmainWord check_helo_access +syntax keyword pfmainWord check_helo_mx_access +syntax keyword pfmainWord check_helo_ns_access +syntax keyword pfmainWord check_policy_service +syntax keyword pfmainWord check_recipient_a_access +syntax keyword pfmainWord check_recipient_access +syntax keyword pfmainWord check_recipient_maps +syntax keyword pfmainWord check_recipient_mx_access +syntax keyword pfmainWord check_recipient_ns_access +syntax keyword pfmainWord check_relay_domains +syntax keyword pfmainWord check_reverse_client_hostname_a_access +syntax keyword pfmainWord check_reverse_client_hostname_access +syntax keyword pfmainWord check_reverse_client_hostname_mx_access +syntax keyword pfmainWord check_reverse_client_hostname_ns_access +syntax keyword pfmainWord check_sasl_access +syntax keyword pfmainWord check_sender_a_access +syntax keyword pfmainWord check_sender_access +syntax keyword pfmainWord check_sender_mx_access +syntax keyword pfmainWord check_sender_ns_access +syntax keyword pfmainWord class +syntax keyword pfmainWord client_address +syntax keyword pfmainWord client_port +syntax keyword pfmainWord dane +syntax keyword pfmainWord dane-only +syntax keyword pfmainWord defer +syntax keyword pfmainWord defer_if_permit +syntax keyword pfmainWord defer_if_reject +syntax keyword pfmainWord defer_unauth_destination +syntax keyword pfmainWord disabled +syntax keyword pfmainWord dns +syntax keyword pfmainWord dnssec +syntax keyword pfmainWord drop +syntax keyword pfmainWord dunno +syntax keyword pfmainWord enabled +syntax keyword pfmainWord encrypt +syntax keyword pfmainWord enforce +syntax keyword pfmainWord envelope_recipient +syntax keyword pfmainWord envelope_sender +syntax keyword pfmainWord export +syntax keyword pfmainWord fingerprint +syntax keyword pfmainWord header_recipient +syntax keyword pfmainWord header_sender +syntax keyword pfmainWord high +syntax keyword pfmainWord host +syntax keyword pfmainWord ignore +syntax keyword pfmainWord ipv4 +syntax keyword pfmainWord ipv6 +syntax keyword pfmainWord localtime +syntax keyword pfmainWord low +syntax keyword pfmainWord may +syntax keyword pfmainWord maybe +syntax keyword pfmainWord medium +syntax keyword pfmainWord native +syntax keyword pfmainWord never +syntax keyword pfmainWord no_address_mappings +syntax keyword pfmainWord no_header_body_checks +syntax keyword pfmainWord no_header_reply +syntax keyword pfmainWord no_milters +syntax keyword pfmainWord no_unknown_recipient_checks +syntax keyword pfmainWord none +syntax keyword pfmainWord null +syntax keyword pfmainWord off +syntax keyword pfmainWord on +syntax keyword pfmainWord permit +syntax keyword pfmainWord permit_auth_destination +syntax keyword pfmainWord permit_dnswl_client +syntax keyword pfmainWord permit_inet_interfaces +syntax keyword pfmainWord permit_mx_backup +syntax keyword pfmainWord permit_mynetworks +syntax keyword pfmainWord permit_naked_ip_address +syntax keyword pfmainWord permit_rhswl_client +syntax keyword pfmainWord permit_sasl_authenticated +syntax keyword pfmainWord permit_tls_all_clientcerts +syntax keyword pfmainWord permit_tls_clientcerts +syntax keyword pfmainWord quarantine +syntax keyword pfmainWord reject +syntax keyword pfmainWord reject_authenticated_sender_login_mismatch +syntax keyword pfmainWord reject_invalid_helo_hostname +syntax keyword pfmainWord reject_invalid_hostname +syntax keyword pfmainWord reject_known_sender_login_mismatch +syntax keyword pfmainWord reject_maps_rbl +syntax keyword pfmainWord reject_multi_recipient_bounce +syntax keyword pfmainWord reject_non_fqdn_helo_hostname +syntax keyword pfmainWord reject_non_fqdn_hostname +syntax keyword pfmainWord reject_non_fqdn_recipient +syntax keyword pfmainWord reject_non_fqdn_sender +syntax keyword pfmainWord reject_plaintext_session +syntax keyword pfmainWord reject_rbl +syntax keyword pfmainWord reject_rbl_client +syntax keyword pfmainWord reject_rhsbl_client +syntax keyword pfmainWord reject_rhsbl_helo +syntax keyword pfmainWord reject_rhsbl_recipient +syntax keyword pfmainWord reject_rhsbl_reverse_client +syntax keyword pfmainWord reject_rhsbl_sender +syntax keyword pfmainWord reject_sender_login_mismatch +syntax keyword pfmainWord reject_unauth_destination +syntax keyword pfmainWord reject_unauth_pipelining +syntax keyword pfmainWord reject_unauthenticated_sender_login_mismatch +syntax keyword pfmainWord reject_unknown_address +syntax keyword pfmainWord reject_unknown_client +syntax keyword pfmainWord reject_unknown_client_hostname +syntax keyword pfmainWord reject_unknown_forward_client_hostname +syntax keyword pfmainWord reject_unknown_helo_hostname +syntax keyword pfmainWord reject_unknown_hostname +syntax keyword pfmainWord reject_unknown_recipient_domain +syntax keyword pfmainWord reject_unknown_reverse_client_hostname +syntax keyword pfmainWord reject_unknown_sender_domain +syntax keyword pfmainWord reject_unlisted_recipient +syntax keyword pfmainWord reject_unlisted_sender +syntax keyword pfmainWord reject_unverified_recipient +syntax keyword pfmainWord reject_unverified_sender +syntax keyword pfmainWord secure +syntax keyword pfmainWord server_name +syntax keyword pfmainWord sleep +syntax keyword pfmainWord smtpd_access_maps +syntax keyword pfmainWord speed_adjust +syntax keyword pfmainWord strong +syntax keyword pfmainWord subnet +syntax keyword pfmainWord tempfail +syntax keyword pfmainWord ultra +syntax keyword pfmainWord warn_if_reject +syntax keyword pfmainWord CRYPTOPRO_TLSEXT_BUG +syntax keyword pfmainWord DONT_INSERT_EMPTY_FRAGMENTS +syntax keyword pfmainWord LEGACY_SERVER_CONNECT +syntax keyword pfmainWord MICROSOFT_BIG_SSLV3_BUFFER +syntax keyword pfmainWord MICROSOFT_SESS_ID_BUG +syntax keyword pfmainWord MSIE_SSLV2_RSA_PADDING +syntax keyword pfmainWord NETSCAPE_CHALLENGE_BUG +syntax keyword pfmainWord NETSCAPE_REUSE_CIPHER_CHANGE_BUG +syntax keyword pfmainWord SSLEAY_080_CLIENT_DH_BUG +syntax keyword pfmainWord SSLREF2_REUSE_CERT_TYPE_BUG +syntax keyword pfmainWord TLS_BLOCK_PADDING_BUG +syntax keyword pfmainWord TLS_D5_BUG +syntax keyword pfmainWord TLS_ROLLBACK_BUG + +syntax keyword pfmainDict btree cidr environ hash nis pcre proxy regexp sdbm static tcp unix +syntax keyword pfmainQueueDir incoming active deferred corrupt hold +syntax keyword pfmainTransport smtp lmtp unix local relay uucp virtual +syntax keyword pfmainLock fcntl flock dotlock +syntax keyword pfmainAnswer yes no + +syntax match pfmainComment "#.*$" +syntax match pfmainNumber "\<\d\+\>" +syntax match pfmainTime "\<\d\+[hmsd]\>" +syntax match pfmainIP "\<\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}\>" +syntax match pfmainVariable "\$\w\+" contains=pfmainRef + +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" + +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" + +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" + +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" + +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" + +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\<2bounce\>" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" + +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" +syntax match pfmainSpecial "\" + + +hi def link pfmainConf Statement +hi def link pfmainRef PreProc +hi def link pfmainWord identifier + +hi def link pfmainDict Type +hi def link pfmainQueueDir Constant +hi def link pfmainTransport Constant +hi def link pfmainLock Constant +hi def link pfmainAnswer Constant + +hi def link pfmainComment Comment +hi def link pfmainNumber Number +hi def link pfmainTime Number +hi def link pfmainIP Number +hi def link pfmainVariable Error +hi def link pfmainSpecial Special + + +let b:current_syntax = "pfmain" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/php.vim b/syntax/php.vim index c8e6f3c..1c7d2be 100644 --- a/syntax/php.vim +++ b/syntax/php.vim @@ -1,3 +1,672 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: php PHP 3/4/5/7 +" Maintainer: Jason Woofenden +" Last Change: Jul 14, 2017 +" URL: https://jasonwoof.com/gitweb/?p=vim-syntax.git;a=blob;f=php.vim;hb=HEAD +" Former Maintainers: Peter Hodge +" Debian VIM Maintainers +" +" Note: If you are using a colour terminal with dark background, you will +" probably find the 'elflord' colorscheme is much better for PHP's syntax +" than the default colourscheme, because elflord's colours will better +" highlight the break-points (Statements) in your code. +" +" Options: +" Set to anything to enable: +" php_sql_query SQL syntax highlighting inside strings +" php_htmlInStrings HTML syntax highlighting inside strings +" php_baselib highlighting baselib functions +" php_asp_tags highlighting ASP-style short tags +" php_parent_error_close highlighting parent error ] or ) +" php_parent_error_open skipping an php end tag, if there exists +" an open ( or [ without a closing one +" php_oldStyle use old colorstyle +" php_noShortTags don't sync as php +" Set to a specific value: +" php_folding = 1 fold classes and functions +" php_folding = 2 fold all { } regions +" php_sync_method = x where x is an integer: +" -1 sync by search ( default ) +" >0 sync at least x lines backwards +" 0 sync from start +" Set to 0 to _disable_: (Added by Peter Hodge On June 9, 2006) +" php_special_functions = 0 highlight functions with abnormal behaviour +" php_alt_comparisons = 0 comparison operators in an alternate colour +" php_alt_assignByReference = 0 '= &' in an alternate colour +" +" +" Note: +" Setting php_folding=1 will match a closing } by comparing the indent +" before the class or function keyword with the indent of a matching }. +" Setting php_folding=2 will match all of pairs of {,} ( see known +" bugs ii ) + +" Known Bugs: +" - setting php_parent_error_close on and php_parent_error_open off +" has these two leaks: +" i) A closing ) or ] inside a string match to the last open ( or [ +" before the string, when the the closing ) or ] is on the same line +" where the string started. In this case a following ) or ] after +" the string would be highlighted as an error, what is incorrect. +" ii) Same problem if you are setting php_folding = 2 with a closing +" } inside an string on the first line of this string. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'php' +endif + +runtime! syntax/html.vim +unlet b:current_syntax + +" accept old options +if !exists("php_sync_method") + if exists("php_minlines") + let php_sync_method=php_minlines + else + let php_sync_method=-1 + endif +endif + +if exists("php_parentError") && !exists("php_parent_error_open") && !exists("php_parent_error_close") + let php_parent_error_close=1 + let php_parent_error_open=1 +endif + +syn cluster htmlPreproc add=phpRegion,phpRegionAsp,phpRegionSc + +syn include @sqlTop syntax/sql.vim +syn sync clear +unlet b:current_syntax +syn cluster sqlTop remove=sqlString,sqlComment +if exists( "php_sql_query") + syn cluster phpAddStrings contains=@sqlTop +endif + +if exists( "php_htmlInStrings") + syn cluster phpAddStrings add=@htmlTop +endif + +" make sure we can use \ at the begining of the line to do a continuation +let s:cpo_save = &cpo +set cpo&vim + +syn case match + +" Env Variables +syn keyword phpEnvVar GATEWAY_INTERFACE SERVER_NAME SERVER_SOFTWARE SERVER_PROTOCOL REQUEST_METHOD QUERY_STRING DOCUMENT_ROOT HTTP_ACCEPT HTTP_ACCEPT_CHARSET HTTP_ENCODING HTTP_ACCEPT_LANGUAGE HTTP_CONNECTION HTTP_HOST HTTP_REFERER HTTP_USER_AGENT REMOTE_ADDR REMOTE_PORT SCRIPT_FILENAME SERVER_ADMIN SERVER_PORT SERVER_SIGNATURE PATH_TRANSLATED SCRIPT_NAME REQUEST_URI contained + +" Internal Variables +syn keyword phpIntVar GLOBALS PHP_ERRMSG PHP_SELF HTTP_GET_VARS HTTP_POST_VARS HTTP_COOKIE_VARS HTTP_POST_FILES HTTP_ENV_VARS HTTP_SERVER_VARS HTTP_SESSION_VARS HTTP_RAW_POST_DATA HTTP_STATE_VARS _GET _POST _COOKIE _FILES _SERVER _ENV _SERVER _REQUEST _SESSION contained + +" Constants +syn keyword phpCoreConstant PHP_VERSION PHP_OS DEFAULT_INCLUDE_PATH PEAR_INSTALL_DIR PEAR_EXTENSION_DIR PHP_EXTENSION_DIR PHP_BINDIR PHP_LIBDIR PHP_DATADIR PHP_SYSCONFDIR PHP_LOCALSTATEDIR PHP_CONFIG_FILE_PATH PHP_OUTPUT_HANDLER_START PHP_OUTPUT_HANDLER_CONT PHP_OUTPUT_HANDLER_END contained + +" Predefined constants +" Generated by: curl -q http://php.net/manual/en/errorfunc.constants.php | grep -oP 'E_\w+' | sort -u +syn keyword phpCoreConstant E_ALL E_COMPILE_ERROR E_COMPILE_WARNING E_CORE_ERROR E_CORE_WARNING E_DEPRECATED E_ERROR E_NOTICE E_PARSE E_RECOVERABLE_ERROR E_STRICT E_USER_DEPRECATED E_USER_ERROR E_USER_NOTICE E_USER_WARNING E_WARNING contained + +syn case ignore + +syn keyword phpConstant __LINE__ __FILE__ __FUNCTION__ __METHOD__ __CLASS__ __DIR__ __NAMESPACE__ __TRAIT__ contained + + +" Function and Methods ripped from php_manual_de.tar.gz Jan 2003 +syn keyword phpFunctions apache_child_terminate apache_get_modules apache_get_version apache_getenv apache_lookup_uri apache_note apache_request_headers apache_response_headers apache_setenv ascii2ebcdic ebcdic2ascii getallheaders virtual contained +syn keyword phpFunctions array_change_key_case array_chunk array_column array_combine array_count_values array_diff_assoc array_diff_key array_diff_uassoc array_diff_ukey array_diff array_fill_keys array_fill array_filter array_flip array_intersect_assoc array_intersect_key array_intersect_uassoc array_intersect_ukey array_intersect array_key_exists array_keys array_map array_merge_recursive array_merge array_multisort array_pad array_pop array_product array_push array_rand array_reduce array_replace_recursive array_replace array_reverse array_search array_shift array_slice array_splice array_sum array_udiff_assoc array_udiff_uassoc array_udiff array_uintersect_assoc array_uintersect_uassoc array_uintersect array_unique array_unshift array_values array_walk_recursive array_walk arsort asort count current each end in_array key_exists key krsort ksort natcasesort natsort next pos prev range reset rsort shuffle sizeof sort uasort uksort usort contained +syn keyword phpFunctions aspell_check aspell_new aspell_suggest contained +syn keyword phpFunctions bcadd bccomp bcdiv bcmod bcmul bcpow bcpowmod bcscale bcsqrt bcsub contained +syn keyword phpFunctions bzclose bzcompress bzdecompress bzerrno bzerror bzerrstr bzflush bzopen bzread bzwrite contained +syn keyword phpFunctions cal_days_in_month cal_from_jd cal_info cal_to_jd easter_date easter_days frenchtojd gregoriantojd jddayofweek jdmonthname jdtofrench jdtogregorian jdtojewish jdtojulian jdtounix jewishtojd juliantojd unixtojd contained +syn keyword phpFunctions ccvs_add ccvs_auth ccvs_command ccvs_count ccvs_delete ccvs_done ccvs_init ccvs_lookup ccvs_new ccvs_report ccvs_return ccvs_reverse ccvs_sale ccvs_status ccvs_textvalue ccvs_void contained +syn keyword phpFunctions call_user_method_array call_user_method class_exists get_class_methods get_class_vars get_class get_declared_classes get_object_vars get_parent_class is_a is_subclass_of method_exists contained +syn keyword phpFunctions com VARIANT com_addref com_get com_invoke com_isenum com_load_typelib com_load com_propget com_propput com_propset com_release com_set contained +syn keyword phpFunctions cpdf_add_annotation cpdf_add_outline cpdf_arc cpdf_begin_text cpdf_circle cpdf_clip cpdf_close cpdf_closepath_fill_stroke cpdf_closepath_stroke cpdf_closepath cpdf_continue_text cpdf_curveto cpdf_end_text cpdf_fill_stroke cpdf_fill cpdf_finalize_page cpdf_finalize cpdf_global_set_document_limits cpdf_import_jpeg cpdf_lineto cpdf_moveto cpdf_newpath cpdf_open cpdf_output_buffer cpdf_page_init cpdf_place_inline_image cpdf_rect cpdf_restore cpdf_rlineto cpdf_rmoveto cpdf_rotate_text cpdf_rotate cpdf_save_to_file cpdf_save cpdf_scale cpdf_set_action_url cpdf_set_char_spacing cpdf_set_creator cpdf_set_current_page cpdf_set_font_directories cpdf_set_font_map_file cpdf_set_font cpdf_set_horiz_scaling cpdf_set_keywords cpdf_set_leading cpdf_set_page_animation cpdf_set_subject cpdf_set_text_matrix cpdf_set_text_pos cpdf_set_text_rendering cpdf_set_text_rise cpdf_set_title cpdf_set_viewer_preferences cpdf_set_word_spacing cpdf_setdash cpdf_setflat cpdf_setgray_fill cpdf_setgray_stroke cpdf_setgray cpdf_setlinecap cpdf_setlinejoin cpdf_setlinewidth cpdf_setmiterlimit cpdf_setrgbcolor_fill cpdf_setrgbcolor_stroke cpdf_setrgbcolor cpdf_show_xy cpdf_show cpdf_stringwidth cpdf_stroke cpdf_text cpdf_translate contained +syn keyword phpFunctions crack_check crack_closedict crack_getlastmessage crack_opendict contained +syn keyword phpFunctions ctype_alnum ctype_alpha ctype_cntrl ctype_digit ctype_graph ctype_lower ctype_print ctype_punct ctype_space ctype_upper ctype_xdigit contained +syn keyword phpFunctions curl_close curl_errno curl_error curl_exec curl_getinfo curl_init curl_multi_add_handle curl_multi_close curl_multi_exec curl_multi_getcontent curl_multi_info_read curl_multi_init curl_multi_remove_handle curl_multi_select curl_setopt curl_version contained +syn keyword phpFunctions cybercash_base64_decode cybercash_base64_encode cybercash_decr cybercash_encr contained +syn keyword phpFunctions cyrus_authenticate cyrus_bind cyrus_close cyrus_connect cyrus_query cyrus_unbind contained +syn keyword phpFunctions checkdate date getdate gettimeofday gmdate gmmktime gmstrftime localtime microtime mktime strftime strtotime time contained +syn keyword phpFunctions dba_close dba_delete dba_exists dba_fetch dba_firstkey dba_handlers dba_insert dba_key_split dba_list dba_nextkey dba_open dba_optimize dba_popen dba_replace dba_sync contained +syn keyword phpFunctions dbase_add_record dbase_close dbase_create dbase_delete_record dbase_get_header_info dbase_get_record_with_names dbase_get_record dbase_numfields dbase_numrecords dbase_open dbase_pack dbase_replace_record contained +syn keyword phpFunctions dblist dbmclose dbmdelete dbmexists dbmfetch dbmfirstkey dbminsert dbmnextkey dbmopen dbmreplace contained +syn keyword phpFunctions dbplus_add dbplus_aql dbplus_chdir dbplus_close dbplus_curr dbplus_errcode dbplus_errno dbplus_find dbplus_first dbplus_flush dbplus_freealllocks dbplus_freelock dbplus_freerlocks dbplus_getlock dbplus_getunique dbplus_info dbplus_last dbplus_lockrel dbplus_next dbplus_open dbplus_prev dbplus_rchperm dbplus_rcreate dbplus_rcrtexact dbplus_rcrtlike dbplus_resolve dbplus_restorepos dbplus_rkeys dbplus_ropen dbplus_rquery dbplus_rrename dbplus_rsecindex dbplus_runlink dbplus_rzap dbplus_savepos dbplus_setindex dbplus_setindexbynumber dbplus_sql dbplus_tcl dbplus_tremove dbplus_undo dbplus_undoprepare dbplus_unlockrel dbplus_unselect dbplus_update dbplus_xlockrel dbplus_xunlockrel contained +syn keyword phpFunctions dbx_close dbx_compare dbx_connect dbx_error dbx_escape_string dbx_fetch_row dbx_query dbx_sort contained +syn keyword phpFunctions dio_close dio_fcntl dio_open dio_read dio_seek dio_stat dio_tcsetattr dio_truncate dio_write contained +syn keyword phpFunctions chdir chroot dir closedir getcwd opendir readdir rewinddir scandir contained +syn keyword phpFunctions domxml_new_doc domxml_open_file domxml_open_mem domxml_version domxml_xmltree domxml_xslt_stylesheet_doc domxml_xslt_stylesheet_file domxml_xslt_stylesheet xpath_eval_expression xpath_eval xpath_new_context xptr_eval xptr_new_context contained +syn keyword phpMethods name specified value create_attribute create_cdata_section create_comment create_element_ns create_element create_entity_reference create_processing_instruction create_text_node doctype document_element dump_file dump_mem get_element_by_id get_elements_by_tagname html_dump_mem xinclude entities internal_subset name notations public_id system_id get_attribute_node get_attribute get_elements_by_tagname has_attribute remove_attribute set_attribute tagname add_namespace append_child append_sibling attributes child_nodes clone_node dump_node first_child get_content has_attributes has_child_nodes insert_before is_blank_node last_child next_sibling node_name node_type node_value owner_document parent_node prefix previous_sibling remove_child replace_child replace_node set_content set_name set_namespace unlink_node data target process result_dump_file result_dump_mem contained +syn keyword phpFunctions dotnet_load contained +syn keyword phpFunctions debug_backtrace debug_print_backtrace error_log error_reporting restore_error_handler set_error_handler trigger_error user_error contained +syn keyword phpFunctions escapeshellarg escapeshellcmd exec passthru proc_close proc_get_status proc_nice proc_open proc_terminate shell_exec system contained +syn keyword phpFunctions fam_cancel_monitor fam_close fam_monitor_collection fam_monitor_directory fam_monitor_file fam_next_event fam_open fam_pending fam_resume_monitor fam_suspend_monitor contained +syn keyword phpFunctions fbsql_affected_rows fbsql_autocommit fbsql_change_user fbsql_close fbsql_commit fbsql_connect fbsql_create_blob fbsql_create_clob fbsql_create_db fbsql_data_seek fbsql_database_password fbsql_database fbsql_db_query fbsql_db_status fbsql_drop_db fbsql_errno fbsql_error fbsql_fetch_array fbsql_fetch_assoc fbsql_fetch_field fbsql_fetch_lengths fbsql_fetch_object fbsql_fetch_row fbsql_field_flags fbsql_field_len fbsql_field_name fbsql_field_seek fbsql_field_table fbsql_field_type fbsql_free_result fbsql_get_autostart_info fbsql_hostname fbsql_insert_id fbsql_list_dbs fbsql_list_fields fbsql_list_tables fbsql_next_result fbsql_num_fields fbsql_num_rows fbsql_password fbsql_pconnect fbsql_query fbsql_read_blob fbsql_read_clob fbsql_result fbsql_rollback fbsql_select_db fbsql_set_lob_mode fbsql_set_transaction fbsql_start_db fbsql_stop_db fbsql_tablename fbsql_username fbsql_warnings contained +syn keyword phpFunctions fdf_add_doc_javascript fdf_add_template fdf_close fdf_create fdf_enum_values fdf_errno fdf_error fdf_get_ap fdf_get_attachment fdf_get_encoding fdf_get_file fdf_get_flags fdf_get_opt fdf_get_status fdf_get_value fdf_get_version fdf_header fdf_next_field_name fdf_open_string fdf_open fdf_remove_item fdf_save_string fdf_save fdf_set_ap fdf_set_encoding fdf_set_file fdf_set_flags fdf_set_javascript_action fdf_set_opt fdf_set_status fdf_set_submit_form_action fdf_set_target_frame fdf_set_value fdf_set_version contained +syn keyword phpFunctions filepro_fieldcount filepro_fieldname filepro_fieldtype filepro_fieldwidth filepro_retrieve filepro_rowcount filepro contained +syn keyword phpFunctions basename chgrp chmod chown clearstatcache copy delete dirname disk_free_space disk_total_space diskfreespace fclose feof fflush fgetc fgetcsv fgets fgetss file_exists file_get_contents file_put_contents file fileatime filectime filegroup fileinode filemtime fileowner fileperms filesize filetype flock fnmatch fopen fpassthru fputs fread fscanf fseek fstat ftell ftruncate fwrite glob is_dir is_executable is_file is_link is_readable is_uploaded_file is_writable is_writeable link linkinfo lstat mkdir move_uploaded_file parse_ini_file pathinfo pclose popen readfile readlink realpath rename rewind rmdir set_file_buffer stat symlink tempnam tmpfile touch umask unlink contained +syn keyword phpFunctions fribidi_log2vis contained +syn keyword phpFunctions ftp_alloc ftp_cdup ftp_chdir ftp_chmod ftp_close ftp_connect ftp_delete ftp_exec ftp_fget ftp_fput ftp_get_option ftp_get ftp_login ftp_mdtm ftp_mkdir ftp_nb_continue ftp_nb_fget ftp_nb_fput ftp_nb_get ftp_nb_put ftp_nlist ftp_pasv ftp_put ftp_pwd ftp_quit ftp_raw ftp_rawlist ftp_rename ftp_rmdir ftp_set_option ftp_site ftp_size ftp_ssl_connect ftp_systype contained +syn keyword phpFunctions call_user_func_array call_user_func create_function func_get_arg func_get_args func_num_args function_exists get_defined_functions register_shutdown_function register_tick_function unregister_tick_function contained +syn keyword phpFunctions bind_textdomain_codeset bindtextdomain dcgettext dcngettext dgettext dngettext gettext ngettext textdomain contained +syn keyword phpFunctions gmp_abs gmp_add gmp_and gmp_clrbit gmp_cmp gmp_com gmp_div_q gmp_div_qr gmp_div_r gmp_div gmp_divexact gmp_fact gmp_gcd gmp_gcdext gmp_hamdist gmp_init gmp_intval gmp_invert gmp_jacobi gmp_legendre gmp_mod gmp_mul gmp_neg gmp_or gmp_perfect_square gmp_popcount gmp_pow gmp_powm gmp_prob_prime gmp_random gmp_scan0 gmp_scan1 gmp_setbit gmp_sign gmp_sqrt gmp_sqrtrem gmp_sqrtrm gmp_strval gmp_sub gmp_xor contained +syn keyword phpFunctions header headers_list headers_sent setcookie contained +syn keyword phpFunctions hw_api_attribute hwapi_hgcsp hw_api_content hw_api_object contained +syn keyword phpMethods key langdepvalue value values checkin checkout children mimetype read content copy dbstat dcstat dstanchors dstofsrcanchors count reason find ftstat hwstat identify info insert insertanchor insertcollection insertdocument link lock move assign attreditable count insert remove title value object objectbyanchor parents description type remove replace setcommitedversion srcanchors srcsofdst unlock user userlist contained +syn keyword phpFunctions hw_Array2Objrec hw_changeobject hw_Children hw_ChildrenObj hw_Close hw_Connect hw_connection_info hw_cp hw_Deleteobject hw_DocByAnchor hw_DocByAnchorObj hw_Document_Attributes hw_Document_BodyTag hw_Document_Content hw_Document_SetContent hw_Document_Size hw_dummy hw_EditText hw_Error hw_ErrorMsg hw_Free_Document hw_GetAnchors hw_GetAnchorsObj hw_GetAndLock hw_GetChildColl hw_GetChildCollObj hw_GetChildDocColl hw_GetChildDocCollObj hw_GetObject hw_GetObjectByQuery hw_GetObjectByQueryColl hw_GetObjectByQueryCollObj hw_GetObjectByQueryObj hw_GetParents hw_GetParentsObj hw_getrellink hw_GetRemote hw_getremotechildren hw_GetSrcByDestObj hw_GetText hw_getusername hw_Identify hw_InCollections hw_Info hw_InsColl hw_InsDoc hw_insertanchors hw_InsertDocument hw_InsertObject hw_mapid hw_Modifyobject hw_mv hw_New_Document hw_objrec2array hw_Output_Document hw_pConnect hw_PipeDocument hw_Root hw_setlinkroot hw_stat hw_Unlock hw_Who contained +syn keyword phpFunctions ibase_add_user ibase_affected_rows ibase_blob_add ibase_blob_cancel ibase_blob_close ibase_blob_create ibase_blob_echo ibase_blob_get ibase_blob_import ibase_blob_info ibase_blob_open ibase_close ibase_commit_ret ibase_commit ibase_connect ibase_delete_user ibase_drop_db ibase_errcode ibase_errmsg ibase_execute ibase_fetch_assoc ibase_fetch_object ibase_fetch_row ibase_field_info ibase_free_event_handler ibase_free_query ibase_free_result ibase_gen_id ibase_modify_user ibase_name_result ibase_num_fields ibase_num_params ibase_param_info ibase_pconnect ibase_prepare ibase_query ibase_rollback_ret ibase_rollback ibase_set_event_handler ibase_timefmt ibase_trans ibase_wait_event contained +syn keyword phpFunctions iconv_get_encoding iconv_mime_decode_headers iconv_mime_decode iconv_mime_encode iconv_set_encoding iconv_strlen iconv_strpos iconv_strrpos iconv_substr iconv ob_iconv_handler contained +syn keyword phpFunctions ifx_affected_rows ifx_blobinfile_mode ifx_byteasvarchar ifx_close ifx_connect ifx_copy_blob ifx_create_blob ifx_create_char ifx_do ifx_error ifx_errormsg ifx_fetch_row ifx_fieldproperties ifx_fieldtypes ifx_free_blob ifx_free_char ifx_free_result ifx_get_blob ifx_get_char ifx_getsqlca ifx_htmltbl_result ifx_nullformat ifx_num_fields ifx_num_rows ifx_pconnect ifx_prepare ifx_query ifx_textasvarchar ifx_update_blob ifx_update_char ifxus_close_slob ifxus_create_slob ifxus_free_slob ifxus_open_slob ifxus_read_slob ifxus_seek_slob ifxus_tell_slob ifxus_write_slob contained +syn keyword phpFunctions exif_imagetype exif_read_data exif_thumbnail gd_info getimagesize image_type_to_mime_type image2wbmp imagealphablending imageantialias imagearc imagechar imagecharup imagecolorallocate imagecolorallocatealpha imagecolorat imagecolorclosest imagecolorclosestalpha imagecolorclosesthwb imagecolordeallocate imagecolorexact imagecolorexactalpha imagecolormatch imagecolorresolve imagecolorresolvealpha imagecolorset imagecolorsforindex imagecolorstotal imagecolortransparent imagecopy imagecopymerge imagecopymergegray imagecopyresampled imagecopyresized imagecreate imagecreatefromgd2 imagecreatefromgd2part imagecreatefromgd imagecreatefromgif imagecreatefromjpeg imagecreatefrompng imagecreatefromstring imagecreatefromwbmp imagecreatefromxbm imagecreatefromxpm imagecreatetruecolor imagedashedline imagedestroy imageellipse imagefill imagefilledarc imagefilledellipse imagefilledpolygon imagefilledrectangle imagefilltoborder imagefontheight imagefontwidth imageftbbox imagefttext imagegammacorrect imagegd2 imagegd imagegif imageinterlace imageistruecolor imagejpeg imageline imageloadfont imagepalettecopy imagepng imagepolygon imagepsbbox imagepscopyfont imagepsencodefont imagepsextendfont imagepsfreefont imagepsloadfont imagepsslantfont imagepstext imagerectangle imagerotate imagesavealpha imagesetbrush imagesetpixel imagesetstyle imagesetthickness imagesettile imagestring imagestringup imagesx imagesy imagetruecolortopalette imagettfbbox imagettftext imagetypes imagewbmp iptcembed iptcparse jpeg2wbmp png2wbmp read_exif_data contained +syn keyword phpFunctions imap_8bit imap_alerts imap_append imap_base64 imap_binary imap_body imap_bodystruct imap_check imap_clearflag_full imap_close imap_createmailbox imap_delete imap_deletemailbox imap_errors imap_expunge imap_fetch_overview imap_fetchbody imap_fetchheader imap_fetchstructure imap_get_quota imap_get_quotaroot imap_getacl imap_getmailboxes imap_getsubscribed imap_header imap_headerinfo imap_headers imap_last_error imap_list imap_listmailbox imap_listscan imap_listsubscribed imap_lsub imap_mail_compose imap_mail_copy imap_mail_move imap_mail imap_mailboxmsginfo imap_mime_header_decode imap_msgno imap_num_msg imap_num_recent imap_open imap_ping imap_qprint imap_renamemailbox imap_reopen imap_rfc822_parse_adrlist imap_rfc822_parse_headers imap_rfc822_write_address imap_scanmailbox imap_search imap_set_quota imap_setacl imap_setflag_full imap_sort imap_status imap_subscribe imap_thread imap_timeout imap_uid imap_undelete imap_unsubscribe imap_utf7_decode imap_utf7_encode imap_utf8 contained +syn keyword phpFunctions assert_options assert dl extension_loaded get_cfg_var get_current_user get_defined_constants get_extension_funcs get_include_path get_included_files get_loaded_extensions get_magic_quotes_gpc get_magic_quotes_runtime get_required_files getenv getlastmod getmygid getmyinode getmypid getmyuid getopt getrusage ini_alter ini_get_all ini_get ini_restore ini_set main memory_get_usage php_ini_scanned_files php_logo_guid php_sapi_name php_uname phpcredits phpinfo phpversion putenv restore_include_path set_include_path set_magic_quotes_runtime set_time_limit version_compare zend_logo_guid zend_version contained +syn keyword phpFunctions ingres_autocommit ingres_close ingres_commit ingres_connect ingres_fetch_array ingres_fetch_object ingres_fetch_row ingres_field_length ingres_field_name ingres_field_nullable ingres_field_precision ingres_field_scale ingres_field_type ingres_num_fields ingres_num_rows ingres_pconnect ingres_query ingres_rollback contained +syn keyword phpFunctions ircg_channel_mode ircg_disconnect ircg_fetch_error_msg ircg_get_username ircg_html_encode ircg_ignore_add ircg_ignore_del ircg_is_conn_alive ircg_join ircg_kick ircg_lookup_format_messages ircg_msg ircg_nick ircg_nickname_escape ircg_nickname_unescape ircg_notice ircg_part ircg_pconnect ircg_register_format_messages ircg_set_current ircg_set_file ircg_set_on_die ircg_topic ircg_whois contained +syn keyword phpFunctions java_last_exception_clear java_last_exception_get contained +syn keyword phpFunctions json_decode json_encode json_last_error contained +syn keyword phpFunctions ldap_8859_to_t61 ldap_add ldap_bind ldap_close ldap_compare ldap_connect ldap_count_entries ldap_delete ldap_dn2ufn ldap_err2str ldap_errno ldap_error ldap_explode_dn ldap_first_attribute ldap_first_entry ldap_first_reference ldap_free_result ldap_get_attributes ldap_get_dn ldap_get_entries ldap_get_option ldap_get_values_len ldap_get_values ldap_list ldap_mod_add ldap_mod_del ldap_mod_replace ldap_modify ldap_next_attribute ldap_next_entry ldap_next_reference ldap_parse_reference ldap_parse_result ldap_read ldap_rename ldap_search ldap_set_option ldap_set_rebind_proc ldap_sort ldap_start_tls ldap_t61_to_8859 ldap_unbind contained +syn keyword phpFunctions lzf_compress lzf_decompress lzf_optimized_for contained +syn keyword phpFunctions ezmlm_hash mail contained +syn keyword phpFunctions mailparse_determine_best_xfer_encoding mailparse_msg_create mailparse_msg_extract_part_file mailparse_msg_extract_part mailparse_msg_free mailparse_msg_get_part_data mailparse_msg_get_part mailparse_msg_get_structure mailparse_msg_parse_file mailparse_msg_parse mailparse_rfc822_parse_addresses mailparse_stream_encode mailparse_uudecode_all contained +syn keyword phpFunctions abs acos acosh asin asinh atan2 atan atanh base_convert bindec ceil cos cosh decbin dechex decoct deg2rad exp expm1 floor fmod getrandmax hexdec hypot is_finite is_infinite is_nan lcg_value log10 log1p log max min mt_getrandmax mt_rand mt_srand octdec pi pow rad2deg rand round sin sinh sqrt srand tan tanh contained +syn keyword phpFunctions mb_convert_case mb_convert_encoding mb_convert_kana mb_convert_variables mb_decode_mimeheader mb_decode_numericentity mb_detect_encoding mb_detect_order mb_encode_mimeheader mb_encode_numericentity mb_ereg_match mb_ereg_replace mb_ereg_search_getpos mb_ereg_search_getregs mb_ereg_search_init mb_ereg_search_pos mb_ereg_search_regs mb_ereg_search_setpos mb_ereg_search mb_ereg mb_eregi_replace mb_eregi mb_get_info mb_http_input mb_http_output mb_internal_encoding mb_language mb_output_handler mb_parse_str mb_preferred_mime_name mb_regex_encoding mb_regex_set_options mb_send_mail mb_split mb_strcut mb_strimwidth mb_strlen mb_strpos mb_strrpos mb_strtolower mb_strtoupper mb_strwidth mb_substitute_character mb_substr_count mb_substr contained +syn keyword phpFunctions mcal_append_event mcal_close mcal_create_calendar mcal_date_compare mcal_date_valid mcal_day_of_week mcal_day_of_year mcal_days_in_month mcal_delete_calendar mcal_delete_event mcal_event_add_attribute mcal_event_init mcal_event_set_alarm mcal_event_set_category mcal_event_set_class mcal_event_set_description mcal_event_set_end mcal_event_set_recur_daily mcal_event_set_recur_monthly_mday mcal_event_set_recur_monthly_wday mcal_event_set_recur_none mcal_event_set_recur_weekly mcal_event_set_recur_yearly mcal_event_set_start mcal_event_set_title mcal_expunge mcal_fetch_current_stream_event mcal_fetch_event mcal_is_leap_year mcal_list_alarms mcal_list_events mcal_next_recurrence mcal_open mcal_popen mcal_rename_calendar mcal_reopen mcal_snooze mcal_store_event mcal_time_valid mcal_week_of_year contained +syn keyword phpFunctions mcrypt_cbc mcrypt_cfb mcrypt_create_iv mcrypt_decrypt mcrypt_ecb mcrypt_enc_get_algorithms_name mcrypt_enc_get_block_size mcrypt_enc_get_iv_size mcrypt_enc_get_key_size mcrypt_enc_get_modes_name mcrypt_enc_get_supported_key_sizes mcrypt_enc_is_block_algorithm_mode mcrypt_enc_is_block_algorithm mcrypt_enc_is_block_mode mcrypt_enc_self_test mcrypt_encrypt mcrypt_generic_deinit mcrypt_generic_end mcrypt_generic_init mcrypt_generic mcrypt_get_block_size mcrypt_get_cipher_name mcrypt_get_iv_size mcrypt_get_key_size mcrypt_list_algorithms mcrypt_list_modes mcrypt_module_close mcrypt_module_get_algo_block_size mcrypt_module_get_algo_key_size mcrypt_module_get_supported_key_sizes mcrypt_module_is_block_algorithm_mode mcrypt_module_is_block_algorithm mcrypt_module_is_block_mode mcrypt_module_open mcrypt_module_self_test mcrypt_ofb mdecrypt_generic contained +syn keyword phpFunctions mcve_adduser mcve_adduserarg mcve_bt mcve_checkstatus mcve_chkpwd mcve_chngpwd mcve_completeauthorizations mcve_connect mcve_connectionerror mcve_deleteresponse mcve_deletetrans mcve_deleteusersetup mcve_deluser mcve_destroyconn mcve_destroyengine mcve_disableuser mcve_edituser mcve_enableuser mcve_force mcve_getcell mcve_getcellbynum mcve_getcommadelimited mcve_getheader mcve_getuserarg mcve_getuserparam mcve_gft mcve_gl mcve_gut mcve_initconn mcve_initengine mcve_initusersetup mcve_iscommadelimited mcve_liststats mcve_listusers mcve_maxconntimeout mcve_monitor mcve_numcolumns mcve_numrows mcve_override mcve_parsecommadelimited mcve_ping mcve_preauth mcve_preauthcompletion mcve_qc mcve_responseparam mcve_return mcve_returncode mcve_returnstatus mcve_sale mcve_setblocking mcve_setdropfile mcve_setip mcve_setssl_files mcve_setssl mcve_settimeout mcve_settle mcve_text_avs mcve_text_code mcve_text_cv mcve_transactionauth mcve_transactionavs mcve_transactionbatch mcve_transactioncv mcve_transactionid mcve_transactionitem mcve_transactionssent mcve_transactiontext mcve_transinqueue mcve_transnew mcve_transparam mcve_transsend mcve_ub mcve_uwait mcve_verifyconnection mcve_verifysslcert mcve_void contained +syn keyword phpFunctions mhash_count mhash_get_block_size mhash_get_hash_name mhash_keygen_s2k mhash contained +syn keyword phpFunctions mime_content_type contained +syn keyword phpFunctions ming_setcubicthreshold ming_setscale ming_useswfversion SWFAction SWFBitmap swfbutton_keypress SWFbutton SWFDisplayItem SWFFill SWFFont SWFGradient SWFMorph SWFMovie SWFShape SWFSprite SWFText SWFTextField contained +syn keyword phpMethods getHeight getWidth addAction addShape setAction setdown setHit setOver setUp addColor move moveTo multColor remove Rotate rotateTo scale scaleTo setDepth setName setRatio skewX skewXTo skewY skewYTo moveTo rotateTo scaleTo skewXTo skewYTo getwidth addEntry getshape1 getshape2 add nextframe output remove save setbackground setdimension setframes setrate streammp3 addFill drawCurve drawCurveTo drawLine drawLineTo movePen movePenTo setLeftFill setLine setRightFill add nextframe remove setframes addString getWidth moveTo setColor setFont setHeight setSpacing addstring align setbounds setcolor setFont setHeight setindentation setLeftMargin setLineSpacing setMargins setname setrightMargin contained +syn keyword phpFunctions connection_aborted connection_status connection_timeout constant define defined die eval exit get_browser highlight_file highlight_string ignore_user_abort pack show_source sleep uniqid unpack usleep contained +syn keyword phpFunctions udm_add_search_limit udm_alloc_agent udm_api_version udm_cat_list udm_cat_path udm_check_charset udm_check_stored udm_clear_search_limits udm_close_stored udm_crc32 udm_errno udm_error udm_find udm_free_agent udm_free_ispell_data udm_free_res udm_get_doc_count udm_get_res_field udm_get_res_param udm_load_ispell_data udm_open_stored udm_set_agent_param contained +syn keyword phpFunctions msession_connect msession_count msession_create msession_destroy msession_disconnect msession_find msession_get_array msession_get msession_getdata msession_inc msession_list msession_listvar msession_lock msession_plugin msession_randstr msession_set_array msession_set msession_setdata msession_timeout msession_uniq msession_unlock contained +syn keyword phpFunctions msql_affected_rows msql_close msql_connect msql_create_db msql_createdb msql_data_seek msql_dbname msql_drop_db msql_dropdb msql_error msql_fetch_array msql_fetch_field msql_fetch_object msql_fetch_row msql_field_seek msql_fieldflags msql_fieldlen msql_fieldname msql_fieldtable msql_fieldtype msql_free_result msql_freeresult msql_list_dbs msql_list_fields msql_list_tables msql_listdbs msql_listfields msql_listtables msql_num_fields msql_num_rows msql_numfields msql_numrows msql_pconnect msql_query msql_regcase msql_result msql_select_db msql_selectdb msql_tablename msql contained +syn keyword phpFunctions mssql_bind mssql_close mssql_connect mssql_data_seek mssql_execute mssql_fetch_array mssql_fetch_assoc mssql_fetch_batch mssql_fetch_field mssql_fetch_object mssql_fetch_row mssql_field_length mssql_field_name mssql_field_seek mssql_field_type mssql_free_result mssql_free_statement mssql_get_last_message mssql_guid_string mssql_init mssql_min_error_severity mssql_min_message_severity mssql_next_result mssql_num_fields mssql_num_rows mssql_pconnect mssql_query mssql_result mssql_rows_affected mssql_select_db contained +syn keyword phpFunctions muscat_close muscat_get muscat_give muscat_setup_net muscat_setup contained +syn keyword phpFunctions mysql_affected_rows mysql_change_user mysql_client_encoding mysql_close mysql_connect mysql_create_db mysql_data_seek mysql_db_name mysql_db_query mysql_drop_db mysql_errno mysql_error mysql_escape_string mysql_fetch_array mysql_fetch_assoc mysql_fetch_field mysql_fetch_lengths mysql_fetch_object mysql_fetch_row mysql_field_flags mysql_field_len mysql_field_name mysql_field_seek mysql_field_table mysql_field_type mysql_free_result mysql_get_client_info mysql_get_host_info mysql_get_proto_info mysql_get_server_info mysql_info mysql_insert_id mysql_list_dbs mysql_list_fields mysql_list_processes mysql_list_tables mysql_num_fields mysql_num_rows mysql_pconnect mysql_ping mysql_query mysql_real_escape_string mysql_result mysql_select_db mysql_stat mysql_tablename mysql_thread_id mysql_unbuffered_query contained +syn keyword phpFunctions mysqli_affected_rows mysqli_autocommit mysqli_bind_param mysqli_bind_result mysqli_change_user mysqli_character_set_name mysqli_close mysqli_commit mysqli_connect mysqli_data_seek mysqli_debug mysqli_disable_reads_from_master mysqli_disable_rpl_parse mysqli_dump_debug_info mysqli_enable_reads_from_master mysqli_enable_rpl_parse mysqli_errno mysqli_error mysqli_execute mysqli_fetch_array mysqli_fetch_assoc mysqli_fetch_field_direct mysqli_fetch_field mysqli_fetch_fields mysqli_fetch_lengths mysqli_fetch_object mysqli_fetch_row mysqli_fetch mysqli_field_count mysqli_field_seek mysqli_field_tell mysqli_free_result mysqli_get_client_info mysqli_get_host_info mysqli_get_proto_info mysqli_get_server_info mysqli_get_server_version mysqli_info mysqli_init mysqli_insert_id mysqli_kill mysqli_master_query mysqli_num_fields mysqli_num_rows mysqli_options mysqli_param_count mysqli_ping mysqli_prepare_result mysqli_prepare mysqli_profiler mysqli_query mysqli_read_query_result mysqli_real_connect mysqli_real_escape_string mysqli_real_query mysqli_reload mysqli_rollback mysqli_rpl_parse_enabled mysqli_rpl_probe mysqli_rpl_query_type mysqli_select_db mysqli_send_long_data mysqli_send_query mysqli_slave_query mysqli_ssl_set mysqli_stat mysqli_stmt_affected_rows mysqli_stmt_close mysqli_stmt_errno mysqli_stmt_error mysqli_stmt_store_result mysqli_store_result mysqli_thread_id mysqli_thread_safe mysqli_use_result mysqli_warning_count contained +syn keyword phpFunctions ncurses_addch ncurses_addchnstr ncurses_addchstr ncurses_addnstr ncurses_addstr ncurses_assume_default_colors ncurses_attroff ncurses_attron ncurses_attrset ncurses_baudrate ncurses_beep ncurses_bkgd ncurses_bkgdset ncurses_border ncurses_bottom_panel ncurses_can_change_color ncurses_cbreak ncurses_clear ncurses_clrtobot ncurses_clrtoeol ncurses_color_content ncurses_color_set ncurses_curs_set ncurses_def_prog_mode ncurses_def_shell_mode ncurses_define_key ncurses_del_panel ncurses_delay_output ncurses_delch ncurses_deleteln ncurses_delwin ncurses_doupdate ncurses_echo ncurses_echochar ncurses_end ncurses_erase ncurses_erasechar ncurses_filter ncurses_flash ncurses_flushinp ncurses_getch ncurses_getmaxyx ncurses_getmouse ncurses_getyx ncurses_halfdelay ncurses_has_colors ncurses_has_ic ncurses_has_il ncurses_has_key ncurses_hide_panel ncurses_hline ncurses_inch ncurses_init_color ncurses_init_pair ncurses_init ncurses_insch ncurses_insdelln ncurses_insertln ncurses_insstr ncurses_instr ncurses_isendwin ncurses_keyok ncurses_keypad ncurses_killchar ncurses_longname ncurses_meta ncurses_mouse_trafo ncurses_mouseinterval ncurses_mousemask ncurses_move_panel ncurses_move ncurses_mvaddch ncurses_mvaddchnstr ncurses_mvaddchstr ncurses_mvaddnstr ncurses_mvaddstr ncurses_mvcur ncurses_mvdelch ncurses_mvgetch ncurses_mvhline ncurses_mvinch ncurses_mvvline ncurses_mvwaddstr ncurses_napms ncurses_new_panel ncurses_newpad ncurses_newwin ncurses_nl ncurses_nocbreak ncurses_noecho ncurses_nonl ncurses_noqiflush ncurses_noraw ncurses_pair_content ncurses_panel_above ncurses_panel_below ncurses_panel_window ncurses_pnoutrefresh ncurses_prefresh ncurses_putp ncurses_qiflush ncurses_raw ncurses_refresh ncurses_replace_panel ncurses_reset_prog_mode ncurses_reset_shell_mode ncurses_resetty ncurses_savetty ncurses_scr_dump ncurses_scr_init ncurses_scr_restore ncurses_scr_set ncurses_scrl ncurses_show_panel ncurses_slk_attr ncurses_slk_attroff ncurses_slk_attron ncurses_slk_attrset ncurses_slk_clear ncurses_slk_color ncurses_slk_init ncurses_slk_noutrefresh ncurses_slk_refresh ncurses_slk_restore ncurses_slk_set ncurses_slk_touch ncurses_standend ncurses_standout ncurses_start_color ncurses_termattrs ncurses_termname ncurses_timeout ncurses_top_panel ncurses_typeahead ncurses_ungetch ncurses_ungetmouse ncurses_update_panels ncurses_use_default_colors ncurses_use_env ncurses_use_extended_names ncurses_vidattr ncurses_vline ncurses_waddch ncurses_waddstr ncurses_wattroff ncurses_wattron ncurses_wattrset ncurses_wborder ncurses_wclear ncurses_wcolor_set ncurses_werase ncurses_wgetch ncurses_whline ncurses_wmouse_trafo ncurses_wmove ncurses_wnoutrefresh ncurses_wrefresh ncurses_wstandend ncurses_wstandout ncurses_wvline contained +syn keyword phpFunctions checkdnsrr closelog debugger_off debugger_on define_syslog_variables dns_check_record dns_get_mx dns_get_record fsockopen gethostbyaddr gethostbyname gethostbynamel getmxrr getprotobyname getprotobynumber getservbyname getservbyport ip2long long2ip openlog pfsockopen socket_get_status socket_set_blocking socket_set_timeout syslog contained +syn keyword phpFunctions yp_all yp_cat yp_err_string yp_errno yp_first yp_get_default_domain yp_master yp_match yp_next yp_order contained +syn keyword phpFunctions notes_body notes_copy_db notes_create_db notes_create_note notes_drop_db notes_find_note notes_header_info notes_list_msgs notes_mark_read notes_mark_unread notes_nav_create notes_search notes_unread notes_version contained +syn keyword phpFunctions nsapi_request_headers nsapi_response_headers nsapi_virtual contained +syn keyword phpFunctions aggregate_info aggregate_methods_by_list aggregate_methods_by_regexp aggregate_methods aggregate_properties_by_list aggregate_properties_by_regexp aggregate_properties aggregate aggregation_info deaggregate contained +syn keyword phpFunctions ocibindbyname ocicancel ocicloselob ocicollappend ocicollassign ocicollassignelem ocicollgetelem ocicollmax ocicollsize ocicolltrim ocicolumnisnull ocicolumnname ocicolumnprecision ocicolumnscale ocicolumnsize ocicolumntype ocicolumntyperaw ocicommit ocidefinebyname ocierror ociexecute ocifetch ocifetchinto ocifetchstatement ocifreecollection ocifreecursor ocifreedesc ocifreestatement ociinternaldebug ociloadlob ocilogoff ocilogon ocinewcollection ocinewcursor ocinewdescriptor ocinlogon ocinumcols ociparse ociplogon ociresult ocirollback ocirowcount ocisavelob ocisavelobfile ociserverversion ocisetprefetch ocistatementtype ociwritelobtofile ociwritetemporarylob contained +syn keyword phpFunctions odbc_autocommit odbc_binmode odbc_close_all odbc_close odbc_columnprivileges odbc_columns odbc_commit odbc_connect odbc_cursor odbc_data_source odbc_do odbc_error odbc_errormsg odbc_exec odbc_execute odbc_fetch_array odbc_fetch_into odbc_fetch_object odbc_fetch_row odbc_field_len odbc_field_name odbc_field_num odbc_field_precision odbc_field_scale odbc_field_type odbc_foreignkeys odbc_free_result odbc_gettypeinfo odbc_longreadlen odbc_next_result odbc_num_fields odbc_num_rows odbc_pconnect odbc_prepare odbc_primarykeys odbc_procedurecolumns odbc_procedures odbc_result_all odbc_result odbc_rollback odbc_setoption odbc_specialcolumns odbc_statistics odbc_tableprivileges odbc_tables contained +syn keyword phpFunctions openssl_cipher_iv_length openssl_csr_export_to_file openssl_csr_export openssl_csr_get_public_key openssl_csr_get_subject openssl_csr_new openssl_csr_sign openssl_decrypt openssl_dh_compute_key openssl_digest openssl_encrypt openssl_error_string openssl_free_key openssl_get_cert_locations openssl_get_cipher_methods openssl_get_md_methods openssl_get_privatekey openssl_get_publickey openssl_open openssl_pbkdf2 openssl_pkcs12_export_to_file openssl_pkcs12_export openssl_pkcs12_read openssl_pkcs7_decrypt openssl_pkcs7_encrypt openssl_pkcs7_sign openssl_pkcs7_verify openssl_pkey_export_to_file openssl_pkey_export openssl_pkey_free openssl_pkey_get_details openssl_pkey_get_private openssl_pkey_get_public openssl_pkey_new openssl_private_decrypt openssl_private_encrypt openssl_public_decrypt openssl_public_encrypt openssl_random_pseudo_bytes openssl_seal openssl_sign openssl_spki_export_challenge openssl_spki_export openssl_spki_new openssl_spki_verify openssl_verify openssl_x509_check_private_key openssl_x509_checkpurpose openssl_x509_export_to_file openssl_x509_export openssl_x509_fingerprint openssl_x509_free openssl_x509_parse openssl_x509_read contained +syn keyword phpFunctions ora_bind ora_close ora_columnname ora_columnsize ora_columntype ora_commit ora_commitoff ora_commiton ora_do ora_error ora_errorcode ora_exec ora_fetch_into ora_fetch ora_getcolumn ora_logoff ora_logon ora_numcols ora_numrows ora_open ora_parse ora_plogon ora_rollback contained +syn keyword phpFunctions flush ob_clean ob_end_clean ob_end_flush ob_flush ob_get_clean ob_get_contents ob_get_flush ob_get_length ob_get_level ob_get_status ob_gzhandler ob_implicit_flush ob_list_handlers ob_start output_add_rewrite_var output_reset_rewrite_vars contained +syn keyword phpFunctions overload contained +syn keyword phpFunctions ovrimos_close ovrimos_commit ovrimos_connect ovrimos_cursor ovrimos_exec ovrimos_execute ovrimos_fetch_into ovrimos_fetch_row ovrimos_field_len ovrimos_field_name ovrimos_field_num ovrimos_field_type ovrimos_free_result ovrimos_longreadlen ovrimos_num_fields ovrimos_num_rows ovrimos_prepare ovrimos_result_all ovrimos_result ovrimos_rollback contained +syn keyword phpFunctions pcntl_exec pcntl_fork pcntl_signal pcntl_waitpid pcntl_wexitstatus pcntl_wifexited pcntl_wifsignaled pcntl_wifstopped pcntl_wstopsig pcntl_wtermsig contained +syn keyword phpFunctions preg_grep preg_match_all preg_match preg_quote preg_replace_callback preg_replace preg_split contained +syn keyword phpFunctions pdf_add_annotation pdf_add_bookmark pdf_add_launchlink pdf_add_locallink pdf_add_note pdf_add_outline pdf_add_pdflink pdf_add_thumbnail pdf_add_weblink pdf_arc pdf_arcn pdf_attach_file pdf_begin_page pdf_begin_pattern pdf_begin_template pdf_circle pdf_clip pdf_close_image pdf_close_pdi_page pdf_close_pdi pdf_close pdf_closepath_fill_stroke pdf_closepath_stroke pdf_closepath pdf_concat pdf_continue_text pdf_curveto pdf_delete pdf_end_page pdf_end_pattern pdf_end_template pdf_endpath pdf_fill_stroke pdf_fill pdf_findfont pdf_get_buffer pdf_get_font pdf_get_fontname pdf_get_fontsize pdf_get_image_height pdf_get_image_width pdf_get_majorversion pdf_get_minorversion pdf_get_parameter pdf_get_pdi_parameter pdf_get_pdi_value pdf_get_value pdf_initgraphics pdf_lineto pdf_makespotcolor pdf_moveto pdf_new pdf_open_CCITT pdf_open_file pdf_open_gif pdf_open_image_file pdf_open_image pdf_open_jpeg pdf_open_memory_image pdf_open_pdi_page pdf_open_pdi pdf_open_png pdf_open_tiff pdf_open pdf_place_image pdf_place_pdi_page pdf_rect pdf_restore pdf_rotate pdf_save pdf_scale pdf_set_border_color pdf_set_border_dash pdf_set_border_style pdf_set_char_spacing pdf_set_duration pdf_set_font pdf_set_horiz_scaling pdf_set_info_author pdf_set_info_creator pdf_set_info_keywords pdf_set_info_subject pdf_set_info_title pdf_set_info pdf_set_leading pdf_set_parameter pdf_set_text_matrix pdf_set_text_pos pdf_set_text_rendering pdf_set_text_rise pdf_set_value pdf_set_word_spacing pdf_setcolor pdf_setdash pdf_setflat pdf_setfont pdf_setgray_fill pdf_setgray_stroke pdf_setgray pdf_setlinecap pdf_setlinejoin pdf_setlinewidth pdf_setmatrix pdf_setmiterlimit pdf_setpolydash pdf_setrgbcolor_fill pdf_setrgbcolor_stroke pdf_setrgbcolor pdf_show_boxed pdf_show_xy pdf_show pdf_skew pdf_stringwidth pdf_stroke pdf_translate contained +syn keyword phpFunctions pfpro_cleanup pfpro_init pfpro_process_raw pfpro_process pfpro_version contained +syn keyword phpFunctions pg_affected_rows pg_cancel_query pg_client_encoding pg_close pg_connect pg_connection_busy pg_connection_reset pg_connection_status pg_convert pg_copy_from pg_copy_to pg_dbname pg_delete pg_end_copy pg_escape_bytea pg_escape_string pg_fetch_all pg_fetch_array pg_fetch_assoc pg_fetch_object pg_fetch_result pg_fetch_row pg_field_is_null pg_field_name pg_field_num pg_field_prtlen pg_field_size pg_field_type pg_free_result pg_get_notify pg_get_pid pg_get_result pg_host pg_insert pg_last_error pg_last_notice pg_last_oid pg_lo_close pg_lo_create pg_lo_export pg_lo_import pg_lo_open pg_lo_read_all pg_lo_read pg_lo_seek pg_lo_tell pg_lo_unlink pg_lo_write pg_meta_data pg_num_fields pg_num_rows pg_options pg_pconnect pg_ping pg_port pg_put_line pg_query pg_result_error pg_result_seek pg_result_status pg_select pg_send_query pg_set_client_encoding pg_trace pg_tty pg_unescape_bytea pg_untrace pg_update contained +syn keyword phpFunctions posix_ctermid posix_get_last_error posix_getcwd posix_getegid posix_geteuid posix_getgid posix_getgrgid posix_getgrnam posix_getgroups posix_getlogin posix_getpgid posix_getpgrp posix_getpid posix_getppid posix_getpwnam posix_getpwuid posix_getrlimit posix_getsid posix_getuid posix_isatty posix_kill posix_mkfifo posix_setegid posix_seteuid posix_setgid posix_setpgid posix_setsid posix_setuid posix_strerror posix_times posix_ttyname posix_uname contained +syn keyword phpFunctions printer_abort printer_close printer_create_brush printer_create_dc printer_create_font printer_create_pen printer_delete_brush printer_delete_dc printer_delete_font printer_delete_pen printer_draw_bmp printer_draw_chord printer_draw_elipse printer_draw_line printer_draw_pie printer_draw_rectangle printer_draw_roundrect printer_draw_text printer_end_doc printer_end_page printer_get_option printer_list printer_logical_fontheight printer_open printer_select_brush printer_select_font printer_select_pen printer_set_option printer_start_doc printer_start_page printer_write contained +syn keyword phpFunctions pspell_add_to_personal pspell_add_to_session pspell_check pspell_clear_session pspell_config_create pspell_config_ignore pspell_config_mode pspell_config_personal pspell_config_repl pspell_config_runtogether pspell_config_save_repl pspell_new_config pspell_new_personal pspell_new pspell_save_wordlist pspell_store_replacement pspell_suggest contained +syn keyword phpFunctions qdom_error qdom_tree contained +syn keyword phpFunctions readline_add_history readline_clear_history readline_completion_function readline_info readline_list_history readline_read_history readline_write_history readline contained +syn keyword phpFunctions recode_file recode_string recode contained +syn keyword phpFunctions ereg_replace ereg eregi_replace eregi split spliti sql_regcase contained +syn keyword phpFunctions ftok msg_get_queue msg_receive msg_remove_queue msg_send msg_set_queue msg_stat_queue sem_acquire sem_get sem_release sem_remove shm_attach shm_detach shm_get_var shm_put_var shm_remove_var shm_remove contained +syn keyword phpFunctions sesam_affected_rows sesam_commit sesam_connect sesam_diagnostic sesam_disconnect sesam_errormsg sesam_execimm sesam_fetch_array sesam_fetch_result sesam_fetch_row sesam_field_array sesam_field_name sesam_free_result sesam_num_fields sesam_query sesam_rollback sesam_seek_row sesam_settransaction contained +syn keyword phpFunctions session_cache_expire session_cache_limiter session_decode session_destroy session_encode session_get_cookie_params session_id session_is_registered session_module_name session_name session_regenerate_id session_register session_save_path session_set_cookie_params session_set_save_handler session_start session_unregister session_unset session_write_close contained +syn keyword phpFunctions shmop_close shmop_delete shmop_open shmop_read shmop_size shmop_write contained +syn keyword phpFunctions snmp_get_quick_print snmp_set_quick_print snmpget snmprealwalk snmpset snmpwalk snmpwalkoid contained +syn keyword phpFunctions socket_accept socket_bind socket_clear_error socket_close socket_connect socket_create_listen socket_create_pair socket_create socket_get_option socket_getpeername socket_getsockname socket_iovec_add socket_iovec_alloc socket_iovec_delete socket_iovec_fetch socket_iovec_free socket_iovec_set socket_last_error socket_listen socket_read socket_readv socket_recv socket_recvfrom socket_recvmsg socket_select socket_send socket_sendmsg socket_sendto socket_set_block socket_set_nonblock socket_set_option socket_shutdown socket_strerror socket_write socket_writev contained +syn keyword phpFunctions sqlite_array_query sqlite_busy_timeout sqlite_changes sqlite_close sqlite_column sqlite_create_aggregate sqlite_create_function sqlite_current sqlite_error_string sqlite_escape_string sqlite_fetch_array sqlite_fetch_single sqlite_fetch_string sqlite_field_name sqlite_has_more sqlite_last_error sqlite_last_insert_rowid sqlite_libencoding sqlite_libversion sqlite_next sqlite_num_fields sqlite_num_rows sqlite_open sqlite_popen sqlite_query sqlite_rewind sqlite_seek sqlite_udf_decode_binary sqlite_udf_encode_binary sqlite_unbuffered_query contained +syn keyword phpFunctions stream_context_create stream_context_get_options stream_context_set_option stream_context_set_params stream_copy_to_stream stream_filter_append stream_filter_prepend stream_filter_register stream_get_contents stream_get_filters stream_get_line stream_get_meta_data stream_get_transports stream_get_wrappers stream_register_wrapper stream_select stream_set_blocking stream_set_timeout stream_set_write_buffer stream_socket_accept stream_socket_client stream_socket_get_name stream_socket_recvfrom stream_socket_sendto stream_socket_server stream_wrapper_register contained +syn keyword phpFunctions addcslashes addslashes bin2hex chop chr chunk_split convert_cyr_string count_chars crc32 crypt explode fprintf get_html_translation_table hebrev hebrevc html_entity_decode htmlentities htmlspecialchars implode join levenshtein localeconv ltrim md5_file md5 metaphone money_format nl_langinfo nl2br number_format ord parse_str print printf quoted_printable_decode quotemeta rtrim setlocale sha1_file sha1 similar_text soundex sprintf sscanf str_ireplace str_pad str_repeat str_replace str_rot13 str_shuffle str_split str_word_count strcasecmp strchr strcmp strcoll strcspn strip_tags stripcslashes stripos stripslashes stristr strlen strnatcasecmp strnatcmp strncasecmp strncmp strpos strrchr strrev strripos strrpos strspn strstr strtok strtolower strtoupper strtr substr_compare substr_count substr_replace substr trim ucfirst ucwords vprintf vsprintf wordwrap contained +syn keyword phpFunctions swf_actiongeturl swf_actiongotoframe swf_actiongotolabel swf_actionnextframe swf_actionplay swf_actionprevframe swf_actionsettarget swf_actionstop swf_actiontogglequality swf_actionwaitforframe swf_addbuttonrecord swf_addcolor swf_closefile swf_definebitmap swf_definefont swf_defineline swf_definepoly swf_definerect swf_definetext swf_endbutton swf_enddoaction swf_endshape swf_endsymbol swf_fontsize swf_fontslant swf_fonttracking swf_getbitmapinfo swf_getfontinfo swf_getframe swf_labelframe swf_lookat swf_modifyobject swf_mulcolor swf_nextid swf_oncondition swf_openfile swf_ortho2 swf_ortho swf_perspective swf_placeobject swf_polarview swf_popmatrix swf_posround swf_pushmatrix swf_removeobject swf_rotate swf_scale swf_setfont swf_setframe swf_shapearc swf_shapecurveto3 swf_shapecurveto swf_shapefillbitmapclip swf_shapefillbitmaptile swf_shapefilloff swf_shapefillsolid swf_shapelinesolid swf_shapelineto swf_shapemoveto swf_showframe swf_startbutton swf_startdoaction swf_startshape swf_startsymbol swf_textwidth swf_translate swf_viewport contained +syn keyword phpFunctions sybase_affected_rows sybase_close sybase_connect sybase_data_seek sybase_deadlock_retry_count sybase_fetch_array sybase_fetch_assoc sybase_fetch_field sybase_fetch_object sybase_fetch_row sybase_field_seek sybase_free_result sybase_get_last_message sybase_min_client_severity sybase_min_error_severity sybase_min_message_severity sybase_min_server_severity sybase_num_fields sybase_num_rows sybase_pconnect sybase_query sybase_result sybase_select_db sybase_set_message_handler sybase_unbuffered_query contained +syn keyword phpFunctions tidy_access_count tidy_clean_repair tidy_config_count tidy_diagnose tidy_error_count tidy_get_body tidy_get_config tidy_get_error_buffer tidy_get_head tidy_get_html_ver tidy_get_html tidy_get_output tidy_get_release tidy_get_root tidy_get_status tidy_getopt tidy_is_xhtml tidy_load_config tidy_parse_file tidy_parse_string tidy_repair_file tidy_repair_string tidy_reset_config tidy_save_config tidy_set_encoding tidy_setopt tidy_warning_count contained +syn keyword phpMethods attributes children get_attr get_nodes has_children has_siblings is_asp is_comment is_html is_jsp is_jste is_text is_xhtml is_xml next prev tidy_node contained +syn keyword phpFunctions token_get_all token_name contained +syn keyword phpFunctions base64_decode base64_encode get_meta_tags http_build_query parse_url rawurldecode rawurlencode urldecode urlencode contained +syn keyword phpFunctions doubleval empty floatval get_defined_vars get_resource_type gettype import_request_variables intval is_array is_bool is_callable is_double is_float is_int is_integer is_long is_null is_numeric is_object is_real is_resource is_scalar is_string isset print_r serialize settype strval unserialize unset var_dump var_export contained +syn keyword phpFunctions vpopmail_add_alias_domain_ex vpopmail_add_alias_domain vpopmail_add_domain_ex vpopmail_add_domain vpopmail_add_user vpopmail_alias_add vpopmail_alias_del_domain vpopmail_alias_del vpopmail_alias_get_all vpopmail_alias_get vpopmail_auth_user vpopmail_del_domain_ex vpopmail_del_domain vpopmail_del_user vpopmail_error vpopmail_passwd vpopmail_set_user_quota contained +syn keyword phpFunctions w32api_deftype w32api_init_dtype w32api_invoke_function w32api_register_function w32api_set_call_method contained +syn keyword phpFunctions wddx_add_vars wddx_deserialize wddx_packet_end wddx_packet_start wddx_serialize_value wddx_serialize_vars contained +syn keyword phpFunctions utf8_decode utf8_encode xml_error_string xml_get_current_byte_index xml_get_current_column_number xml_get_current_line_number xml_get_error_code xml_parse_into_struct xml_parse xml_parser_create_ns xml_parser_create xml_parser_free xml_parser_get_option xml_parser_set_option xml_set_character_data_handler xml_set_default_handler xml_set_element_handler xml_set_end_namespace_decl_handler xml_set_external_entity_ref_handler xml_set_notation_decl_handler xml_set_object xml_set_processing_instruction_handler xml_set_start_namespace_decl_handler xml_set_unparsed_entity_decl_handler contained +syn keyword phpFunctions xmlrpc_decode_request xmlrpc_decode xmlrpc_encode_request xmlrpc_encode xmlrpc_get_type xmlrpc_parse_method_descriptions xmlrpc_server_add_introspection_data xmlrpc_server_call_method xmlrpc_server_create xmlrpc_server_destroy xmlrpc_server_register_introspection_callback xmlrpc_server_register_method xmlrpc_set_type contained +syn keyword phpFunctions xslt_create xslt_errno xslt_error xslt_free xslt_output_process xslt_set_base xslt_set_encoding xslt_set_error_handler xslt_set_log xslt_set_sax_handler xslt_set_sax_handlers xslt_set_scheme_handler xslt_set_scheme_handlers contained +syn keyword phpFunctions yaz_addinfo yaz_ccl_conf yaz_ccl_parse yaz_close yaz_connect yaz_database yaz_element yaz_errno yaz_error yaz_es_result yaz_get_option yaz_hits yaz_itemorder yaz_present yaz_range yaz_record yaz_scan_result yaz_scan yaz_schema yaz_search yaz_set_option yaz_sort yaz_syntax yaz_wait contained +syn keyword phpFunctions zip_close zip_entry_close zip_entry_compressedsize zip_entry_compressionmethod zip_entry_filesize zip_entry_name zip_entry_open zip_entry_read zip_open zip_read contained +syn keyword phpFunctions gzclose gzcompress gzdeflate gzencode gzeof gzfile gzgetc gzgets gzgetss gzinflate gzopen gzpassthru gzputs gzread gzrewind gzseek gztell gzuncompress gzwrite readgzfile zlib_get_coding_type contained + +if exists( "php_baselib" ) + syn keyword phpMethods query next_record num_rows affected_rows nf f p np num_fields haltmsg seek link_id query_id metadata table_names nextid connect halt free register unregister is_registered delete url purl self_url pself_url hidden_session add_query padd_query reimport_get_vars reimport_post_vars reimport_cookie_vars set_container set_tokenname release_token put_headers get_id get_id put_id freeze thaw gc reimport_any_vars start url purl login_if is_authenticated auth_preauth auth_loginform auth_validatelogin auth_refreshlogin auth_registerform auth_doregister start check have_perm permsum perm_invalid contained + syn keyword phpFunctions page_open page_close sess_load sess_save contained +endif + +" Conditional +syn keyword phpConditional declare else enddeclare endswitch elseif endif if switch contained + +" Repeat +syn keyword phpRepeat as do endfor endforeach endwhile for foreach while contained + +" Repeat +syn keyword phpLabel case default switch contained + +" Statement +syn keyword phpStatement return break continue exit goto yield contained + +" Keyword +syn keyword phpKeyword var const contained + +" Type +syn keyword phpType bool boolean int integer real double float string array object NULL callable iterable contained + +" Structure +syn keyword phpStructure namespace extends implements instanceof parent self contained + +" Operator +syn match phpOperator "[-=+%^&|*!.~?:]" contained display +syn match phpOperator "[-+*/%^&|.]=" contained display +syn match phpOperator "/[^*/]"me=e-1 contained display +syn match phpOperator "\$" contained display +syn match phpOperator "&&\|\" contained display +syn match phpOperator "||\|\" contained display +syn match phpRelation "[!=<>]=" contained display +syn match phpRelation "[<>]" contained display +syn match phpMemberSelector "->" contained display +syn match phpVarSelector "\$" contained display + +" Identifier +syn match phpIdentifier "$\h\w*" contained contains=phpEnvVar,phpIntVar,phpVarSelector display +syn match phpIdentifierSimply "${\h\w*}" contains=phpOperator,phpParent contained display +syn region phpIdentifierComplex matchgroup=phpParent start="{\$"rs=e-1 end="}" contains=phpIdentifier,phpMemberSelector,phpVarSelector,phpIdentifierComplexP contained extend +syn region phpIdentifierComplexP matchgroup=phpParent start="\[" end="]" contains=@phpClInside contained + +" Interpolated indentifiers (inside strings) + syn match phpBrackets "[][}{]" contained display + " errors + syn match phpInterpSimpleError "\[[^]]*\]" contained display " fallback (if nothing else matches) + syn match phpInterpSimpleError "->[^a-zA-Z_]" contained display + " make sure these stay above the correct DollarCurlies so they don't take priority + syn match phpInterpBogusDollarCurley "${[^}]*}" contained display " fallback (if nothing else matches) + syn match phpinterpSimpleBracketsInner "\w\+" contained + syn match phpInterpSimpleBrackets "\[\h\w*]" contained contains=phpBrackets,phpInterpSimpleBracketsInner + syn match phpInterpSimpleBrackets "\[\d\+]" contained contains=phpBrackets,phpInterpSimpleBracketsInner + syn match phpInterpSimpleBrackets "\[0[xX]\x\+]" contained contains=phpBrackets,phpInterpSimpleBracketsInner + syn match phpInterpSimple "\$\h\w*\(\[[^]]*\]\|->\h\w*\)\?" contained contains=phpInterpSimpleBrackets,phpIdentifier,phpInterpSimpleError,phpMethods,phpMemberSelector display + syn match phpInterpVarname "\h\w*" contained + syn match phpInterpMethodName "\h\w*" contained " default color + syn match phpInterpSimpleCurly "\${\h\w*}" contains=phpInterpVarname contained extend + syn region phpInterpDollarCurley1Helper matchgroup=phpParent start="{" end="\[" contains=phpInterpVarname contained + syn region phpInterpDollarCurly1 matchgroup=phpParent start="\${\h\w*\["rs=s+1 end="]}" contains=phpInterpDollarCurley1Helper,@phpClConst contained extend + + syn match phpInterpDollarCurley2Helper "{\h\w*->" contains=phpBrackets,phpInterpVarname,phpMemberSelector contained + + syn region phpInterpDollarCurly2 matchgroup=phpParent start="\${\h\w*->"rs=s+1 end="}" contains=phpInterpDollarCurley2Helper,phpInterpMethodName contained + + syn match phpInterpBogusDollarCurley "${\h\w*->}" contained display + syn match phpInterpBogusDollarCurley "${\h\w*\[]}" contained display + + syn region phpInterpComplex matchgroup=phpParent start="{\$"rs=e-1 end="}" contains=phpIdentifier,phpMemberSelector,phpVarSelector,phpIdentifierComplexP contained extend + syn region phpIdentifierComplexP matchgroup=phpParent start="\[" end="]" contains=@phpClInside contained + " define a cluster to get all interpolation syntaxes for double-quoted strings + syn cluster phpInterpDouble contains=phpInterpSimple,phpInterpSimpleCurly,phpInterpDollarCurly1,phpInterpDollarCurly2,phpInterpBogusDollarCurley,phpInterpComplex + +" Methoden +syn match phpMethodsVar "->\h\w*" contained contains=phpMethods,phpMemberSelector display + +" Include +syn keyword phpInclude include require include_once require_once use contained + +" Define +syn keyword phpDefine new clone contained + +" Boolean +syn keyword phpBoolean true false contained + +" Number +syn match phpNumber "-\=\<\d\+\>" contained display +syn match phpNumber "\<0x\x\{1,8}\>" contained display + +" Float +syn match phpFloat "\(-\=\<\d+\|-\=\)\.\d\+\>" contained display + +" Backslash escapes + syn case match + " for double quotes and heredoc + syn match phpBackslashSequences "\\[fnrtv\\\"$]" contained display + syn match phpBackslashSequences "\\\d\{1,3}" contained contains=phpOctalError display + syn match phpBackslashSequences "\\x\x\{1,2}" contained display + " additional sequence for double quotes only + syn match phpBackslashDoubleQuote "\\[\"]" contained display + " for single quotes only + syn match phpBackslashSingleQuote "\\[\\']" contained display + syn case ignore + + +" Error +syn match phpOctalError "[89]" contained display +if exists("php_parent_error_close") + syn match phpParentError "[)\]}]" contained display +endif + +" Todo +syn keyword phpTodo todo fixme xxx contained + +" Comment +if exists("php_parent_error_open") + syn region phpComment start="/\*" end="\*/" contained contains=phpTodo,@Spell +else + syn region phpComment start="/\*" end="\*/" contained contains=phpTodo,@Spell extend +endif +syn match phpComment "#.\{-}\(?>\|$\)\@=" contained contains=phpTodo,@Spell +syn match phpComment "//.\{-}\(?>\|$\)\@=" contained contains=phpTodo,@Spell + +" String +if exists("php_parent_error_open") + syn region phpStringDouble matchgroup=phpStringDouble start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@phpAddStrings,phpBackslashSequences,phpBackslashDoubleQuote,@phpInterpDouble,@Spell contained keepend + syn region phpBacktick matchgroup=phpBacktick start=+`+ skip=+\\\\\|\\"+ end=+`+ contains=@phpAddStrings,phpIdentifier,phpBackslashSequences,phpIdentifierSimply,phpIdentifierComplex contained keepend + syn region phpStringSingle matchgroup=phpStringSingle start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@phpAddStrings,phpBackslashSingleQuote,@Spell contained keepend +else + syn region phpStringDouble matchgroup=phpStringDouble start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@phpAddStrings,phpBackslashSequences,phpBackslashDoubleQuote,@phpInterpDouble,@Spell contained extend keepend + syn region phpBacktick matchgroup=phpBacktick start=+`+ skip=+\\\\\|\\"+ end=+`+ contains=@phpAddStrings,phpIdentifier,phpBackslashSequences,phpIdentifierSimply,phpIdentifierComplex contained extend keepend + syn region phpStringSingle matchgroup=phpStringSingle start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@phpAddStrings,phpBackslashSingleQuote,@Spell contained keepend extend +endif + +" HereDoc and NowDoc +syn case match + +" HereDoc +syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\I\i*\)\2$" end="^\z1\(;\=$\)\@=" contained contains=phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar,@Spell keepend extend +" including HTML,JavaScript,SQL even if not enabled via options +syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\(\I\i*\)\=\(html\)\c\(\i*\)\)\2$" end="^\z1\(;\=$\)\@=" contained contains=@htmlTop,phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar,@Spell keepend extend +syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\(\I\i*\)\=\(sql\)\c\(\i*\)\)\2$" end="^\z1\(;\=$\)\@=" contained contains=@sqlTop,phpIdentifier,phpIdentifierSimply,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar,@Spell keepend extend +syn region phpHereDoc matchgroup=Delimiter start="\(<<<\)\@<=\(\"\=\)\z(\(\I\i*\)\=\(javascript\)\c\(\i*\)\)\2$" end="^\z1\(;\=$\)\@=" contained contains=@htmlJavascript,phpIdentifierSimply,phpIdentifier,phpIdentifierComplex,phpBackslashSequences,phpMethodsVar,@Spell keepend extend + +" NowDoc +syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\I\i*\)'$" end="^\z1\(;\=$\)\@=" contained contains=@Spell keepend extend +" including HTML,JavaScript,SQL even if not enabled via options +syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\(\I\i*\)\=\(html\)\c\(\i*\)\)'$" end="^\z1\(;\=$\)\@=" contained contains=@htmlTop,@Spell keepend extend +syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\(\I\i*\)\=\(sql\)\c\(\i*\)\)'$" end="^\z1\(;\=$\)\@=" contained contains=@sqlTop,@Spell keepend extend +syn region phpNowDoc matchgroup=Delimiter start="\(<<<\)\@<='\z(\(\I\i*\)\=\(javascript\)\c\(\i*\)\)'$" end="^\z1\(;\=$\)\@=" contained contains=@htmlJavascript,@Spell keepend extend +syn case ignore + +" Parent +if exists("php_parent_error_close") || exists("php_parent_error_open") + syn match phpParent "[{}]" contained + syn region phpParent matchgroup=Delimiter start="(" end=")" contained contains=@phpClInside transparent + syn region phpParent matchgroup=Delimiter start="\[" end="\]" contained contains=@phpClInside transparent + if !exists("php_parent_error_close") + syn match phpParent "[\])]" contained + endif +else + syn match phpParent "[({[\]})]" contained +endif + +syn cluster phpClConst contains=phpFunctions,phpIdentifier,phpConditional,phpRepeat,phpStatement,phpOperator,phpRelation,phpStringSingle,phpStringDouble,phpBacktick,phpNumber,phpFloat,phpKeyword,phpType,phpBoolean,phpStructure,phpMethodsVar,phpConstant,phpCoreConstant,phpException +syn cluster phpClInside contains=@phpClConst,phpComment,phpLabel,phpParent,phpParentError,phpInclude,phpHereDoc,phpNowDoc +syn cluster phpClFunction contains=@phpClInside,phpDefine,phpParentError,phpStorageClass +syn cluster phpClTop contains=@phpClFunction,phpFoldFunction,phpFoldClass,phpFoldInterface,phpFoldTry,phpFoldCatch + +" Php Region +if exists("php_parent_error_open") + if exists("php_noShortTags") + syn region phpRegion matchgroup=Delimiter start="" contains=@phpClTop + else + syn region phpRegion matchgroup=Delimiter start="" contains=@phpClTop + endif + syn region phpRegionSc matchgroup=Delimiter start=++ contains=@phpClTop + if exists("php_asp_tags") + syn region phpRegionAsp matchgroup=Delimiter start="<%\(=\)\=" end="%>" contains=@phpClTop + endif +else + if exists("php_noShortTags") + syn region phpRegion matchgroup=Delimiter start="" contains=@phpClTop keepend + else + syn region phpRegion matchgroup=Delimiter start="" contains=@phpClTop keepend + endif + syn region phpRegionSc matchgroup=Delimiter start=++ contains=@phpClTop keepend + if exists("php_asp_tags") + syn region phpRegionAsp matchgroup=Delimiter start="<%\(=\)\=" end="%>" contains=@phpClTop keepend + endif +endif + +" Fold +if exists("php_folding") && php_folding==1 +" match one line constructs here and skip them at folding + syn keyword phpSCKeyword abstract final private protected public static contained + syn keyword phpFCKeyword function contained + syn keyword phpStorageClass global contained + syn match phpDefine "\(\s\|^\)\(abstract\s\+\|final\s\+\|private\s\+\|protected\s\+\|public\s\+\|static\s\+\)*function\(\s\+.*[;}]\)\@=" contained contains=phpSCKeyword + syn match phpStructure "\(\s\|^\)\(abstract\s\+\|final\s\+\)*\(trait\|class\)\(\s\+.*}\)\@=" contained + syn match phpStructure "\(\s\|^\)interface\(\s\+.*}\)\@=" contained + syn match phpException "\(\s\|^\)try\(\s\+.*}\)\@=" contained + syn match phpException "\(\s\|^\)catch\(\s\+.*}\)\@=" contained + syn match phpException "\(\s\|^\)finally\(\s\+.*}\)\@=" contained + + set foldmethod=syntax + syn region phpFoldHtmlInside matchgroup=Delimiter start="?>" end="" end="-]@]\=?[<>]@!" contained containedin=phpRegion + + " highlight the 'instanceof' operator as a comparison operator rather than a structure + syntax case ignore + syntax keyword phpComparison instanceof contained containedin=phpRegion + + hi def link phpComparison Statement +endif + +" ================================================================ + +" Sync +if php_sync_method==-1 + if exists("php_noShortTags") + syn sync match phpRegionSync grouphere phpRegion "^\s*\s*$+ + if exists("php_asp_tags") + syn sync match phpRegionSync grouphere phpRegionAsp "^\s*<%\(=\)\=\s*$" + endif + syn sync match phpRegionSync grouphere NONE "^\s*?>\s*$" + syn sync match phpRegionSync grouphere NONE "^\s*%>\s*$" + syn sync match phpRegionSync grouphere phpRegion "function\s.*(.*\$" + "syn sync match phpRegionSync grouphere NONE "/\i*>\s*$" +elseif php_sync_method>0 + exec "syn sync minlines=" . php_sync_method +else + exec "syn sync fromstart" +endif + +syntax match phpDocCustomTags "@[a-zA-Z]*\(\s\+\|\n\|\r\)" containedin=phpComment +syntax region phpDocTags start="{@\(example\|id\|internal\|inheritdoc\|link\|source\|toc\|tutorial\)" end="}" containedin=phpComment +syntax match phpDocTags "@\(abstract\|access\|author\|category\|copyright\|deprecated\|example\|final\|global\|ignore\|internal\|license\|link\|method\|name\|package\|param\|property\|return\|see\|since\|static\|staticvar\|subpackage\|tutorial\|uses\|var\|version\|contributor\|modified\|filename\|description\|filesource\|throws\)\(\s\+\)\?" containedin=phpComment +syntax match phpDocTodo "@\(todo\|fixme\|xxx\)\(\s\+\)\?" containedin=phpComment + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link phpConstant Constant +hi def link phpCoreConstant Constant +hi def link phpComment Comment +hi def link phpDocTags PreProc +hi def link phpDocCustomTags Type +hi def link phpException Exception +hi def link phpBoolean Boolean +hi def link phpStorageClass StorageClass +hi def link phpSCKeyword StorageClass +hi def link phpFCKeyword Define +hi def link phpStructure Structure +hi def link phpStringSingle String +hi def link phpStringDouble String +hi def link phpBacktick String +hi def link phpNumber Number +hi def link phpFloat Float +hi def link phpMethods Function +hi def link phpFunctions Function +hi def link phpBaselib Function +hi def link phpRepeat Repeat +hi def link phpConditional Conditional +hi def link phpLabel Label +hi def link phpStatement Statement +hi def link phpKeyword Statement +hi def link phpType Type +hi def link phpInclude Include +hi def link phpDefine Define +hi def link phpBackslashSequences SpecialChar +hi def link phpBackslashDoubleQuote SpecialChar +hi def link phpBackslashSingleQuote SpecialChar +hi def link phpParent Delimiter +hi def link phpBrackets Delimiter +hi def link phpIdentifierConst Delimiter +hi def link phpParentError Error +hi def link phpOctalError Error +hi def link phpInterpSimpleError Error +hi def link phpInterpBogusDollarCurley Error +hi def link phpInterpDollarCurly1 Error +hi def link phpInterpDollarCurly2 Error +hi def link phpInterpSimpleBracketsInner String +hi def link phpInterpSimpleCurly Delimiter +hi def link phpInterpVarname Identifier +hi def link phpTodo Todo +hi def link phpDocTodo Todo +hi def link phpMemberSelector Structure +if exists("php_oldStyle") + hi def phpIntVar guifg=Red ctermfg=DarkRed + hi def phpEnvVar guifg=Red ctermfg=DarkRed + hi def phpOperator guifg=SeaGreen ctermfg=DarkGreen + hi def phpVarSelector guifg=SeaGreen ctermfg=DarkGreen + hi def phpRelation guifg=SeaGreen ctermfg=DarkGreen + hi def phpIdentifier guifg=DarkGray ctermfg=Brown + hi def phpIdentifierSimply guifg=DarkGray ctermfg=Brown +else + hi def link phpIntVar Identifier + hi def link phpEnvVar Identifier + hi def link phpOperator Operator + hi def link phpVarSelector Operator + hi def link phpRelation Operator + hi def link phpIdentifier Identifier + hi def link phpIdentifierSimply Identifier +endif + + +let b:current_syntax = "php" + +if main_syntax == 'php' + unlet main_syntax +endif + +" put cpoptions back the way we found it +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 sts=2 sw=2 expandtab + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'php') == -1 " Vim syntax file diff --git a/syntax/phtml.vim b/syntax/phtml.vim new file mode 100644 index 0000000..d00ced9 --- /dev/null +++ b/syntax/phtml.vim @@ -0,0 +1,10 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" PHTML used to be the filetype for PHP 2.0. Now everything is PHP. + +if !exists("b:current_syntax") + runtime! syntax/php.vim +endif + +endif diff --git a/syntax/pic.vim b/syntax/pic.vim new file mode 100644 index 0000000..c12ca89 --- /dev/null +++ b/syntax/pic.vim @@ -0,0 +1,118 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PIC16F84 Assembler (Microchip's microcontroller) +" Maintainer: Aleksandar Veselinovic +" Last Change: 2003 May 11 +" URL: http://galeb.etf.bg.ac.yu/~alexa/vim/syntax/pic.vim +" Revision: 1.01 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match +syn keyword picTodo NOTE TODO XXX contained + +syn case ignore + +syn match picIdentifier "[a-z_$][a-z0-9_$]*" +syn match picLabel "^[A-Z_$][A-Z0-9_$]*" +syn match picLabel "^[A-Z_$][A-Z0-9_$]*:"me=e-1 + +syn match picASCII "A\='.'" +syn match picBinary "B'[0-1]\+'" +syn match picDecimal "D'\d\+'" +syn match picDecimal "\d\+" +syn match picHexadecimal "0x\x\+" +syn match picHexadecimal "H'\x\+'" +syn match picHexadecimal "[0-9]\x*h" +syn match picOctal "O'[0-7]\o*'" + + +syn match picComment ";.*" contains=picTodo + +syn region picString start=+"+ end=+"+ + +syn keyword picRegister INDF TMR0 PCL STATUS FSR PORTA PORTB +syn keyword picRegister EEDATA EEADR PCLATH INTCON INDF OPTION_REG PCL +syn keyword picRegister FSR TRISA TRISB EECON1 EECON2 INTCON OPTION + + +" Register --- bits + +" STATUS +syn keyword picRegisterPart IRP RP1 RP0 TO PD Z DC C + +" PORTA +syn keyword picRegisterPart T0CKI +syn match picRegisterPart "RA[0-4]" + +" PORTB +syn keyword picRegisterPart INT +syn match picRegisterPart "RB[0-7]" + +" INTCON +syn keyword picRegisterPart GIE EEIE T0IE INTE RBIE T0IF INTF RBIF + +" OPTION +syn keyword picRegisterPart RBPU INTEDG T0CS T0SE PSA PS2 PS1 PS0 + +" EECON2 +syn keyword picRegisterPart EEIF WRERR WREN WR RD + +" INTCON +syn keyword picRegisterPart GIE EEIE T0IE INTE RBIE T0IF INTF RBIF + + +" OpCodes... +syn keyword picOpcode ADDWF ANDWF CLRF CLRW COMF DECF DECFSZ INCF INCFSZ +syn keyword picOpcode IORWF MOVF MOVWF NOP RLF RRF SUBWF SWAPF XORWF +syn keyword picOpcode BCF BSF BTFSC BTFSS +syn keyword picOpcode ADDLW ANDLW CALL CLRWDT GOTO IORLW MOVLW RETFIE +syn keyword picOpcode RETLW RETURN SLEEP SUBLW XORLW +syn keyword picOpcode GOTO + + +" Directives +syn keyword picDirective __BADRAM BANKISEL BANKSEL CBLOCK CODE __CONFIG +syn keyword picDirective CONSTANT DATA DB DE DT DW ELSE END ENDC +syn keyword picDirective ENDIF ENDM ENDW EQU ERROR ERRORLEVEL EXITM EXPAND +syn keyword picDirective EXTERN FILL GLOBAL IDATA __IDLOCS IF IFDEF IFNDEF +syn keyword picDirective INCLUDE LIST LOCAL MACRO __MAXRAM MESSG NOEXPAND +syn keyword picDirective NOLIST ORG PAGE PAGESEL PROCESSOR RADIX RES SET +syn keyword picDirective SPACE SUBTITLE TITLE UDATA UDATA_OVR UDATA_SHR +syn keyword picDirective VARIABLE WHILE INCLUDE +syn match picDirective "#\=UNDEFINE" +syn match picDirective "#\=INCLUDE" +syn match picDirective "#\=DEFINE" + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link picTodo Todo +hi def link picComment Comment +hi def link picDirective Statement +hi def link picLabel Label +hi def link picString String + +"hi def link picOpcode Keyword +"hi def link picRegister Structure +"hi def link picRegisterPart Special + +hi def link picASCII String +hi def link picBinary Number +hi def link picDecimal Number +hi def link picHexadecimal Number +hi def link picOctal Number + +hi def link picIdentifier Identifier + + +let b:current_syntax = "pic" + +" vim: ts=8 + +endif diff --git a/syntax/pike.vim b/syntax/pike.vim new file mode 100644 index 0000000..fd89121 --- /dev/null +++ b/syntax/pike.vim @@ -0,0 +1,146 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Pike +" Maintainer: Francesco Chemolli +" Last Change: 2001 May 10 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful C keywords +syn keyword pikeStatement goto break return continue +syn keyword pikeLabel case default +syn keyword pikeConditional if else switch +syn keyword pikeRepeat while for foreach do +syn keyword pikeStatement gauge destruct lambda inherit import typeof +syn keyword pikeException catch +syn keyword pikeType inline nomask private protected public static + + +syn keyword pikeTodo contained TODO FIXME XXX + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match pikeSpecial contained "\\[0-7][0-7][0-7]\=\|\\." +syn region pikeString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=pikeSpecial +syn match pikeCharacter "'[^\\]'" +syn match pikeSpecialCharacter "'\\.'" +syn match pikeSpecialCharacter "'\\[0-7][0-7]'" +syn match pikeSpecialCharacter "'\\[0-7][0-7][0-7]'" + +" Compound data types +syn region pikeCompoundType start='({' contains=pikeString,pikeCompoundType,pikeNumber,pikeFloat end='})' +syn region pikeCompoundType start='(\[' contains=pikeString,pikeCompoundType,pikeNumber,pikeFloat end='\])' +syn region pikeCompoundType start='(<' contains=pikeString,pikeCompoundType,pikeNumber,pikeFloat end='>)' + +"catch errors caused by wrong parenthesis +syn region pikeParen transparent start='([^{[<(]' end=')' contains=ALLBUT,pikeParenError,pikeIncluded,pikeSpecial,pikeTodo,pikeUserLabel,pikeBitField +syn match pikeParenError ")" +syn match pikeInParen contained "[^(][{}][^)]" + +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match pikeNumber "\<\d\+\(u\=l\=\|lu\|f\)\>" +"floating point number, with dot, optional exponent +syn match pikeFloat "\<\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, starting with a dot, optional exponent +syn match pikeFloat "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match pikeFloat "\<\d\+e[-+]\=\d\+[fl]\=\>" +"hex number +syn match pikeNumber "\<0x[0-9a-f]\+\(u\=l\=\|lu\)\>" +"syn match pikeIdentifier "\<[a-z_][a-z0-9_]*\>" +syn case match +" flag an octal number with wrong digits +syn match pikeOctalError "\<0[0-7]*[89]" + +if exists("c_comment_strings") + " A comment can contain pikeString, pikeCharacter and pikeNumber. + " But a "*/" inside a pikeString in a pikeComment DOES end the comment! So we + " need to use a special type of pikeString: pikeCommentString, which also ends on + " "*/", and sees a "*" at the start of the line as comment again. + " Unfortunately this doesn't very well work for // type of comments :-( + syntax match pikeCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region pikeCommentString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end=+\*/+me=s-1 contains=pikeSpecial,pikeCommentSkip + syntax region pikeComment2String contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end="$" contains=pikeSpecial + syntax region pikeComment start="/\*" end="\*/" contains=pikeTodo,pikeCommentString,pikeCharacter,pikeNumber,pikeFloat + syntax match pikeComment "//.*" contains=pikeTodo,pikeComment2String,pikeCharacter,pikeNumber + syntax match pikeComment "#\!.*" contains=pikeTodo,pikeComment2String,pikeCharacter,pikeNumber +else + syn region pikeComment start="/\*" end="\*/" contains=pikeTodo + syn match pikeComment "//.*" contains=pikeTodo + syn match pikeComment "#!.*" contains=pikeTodo +endif +syntax match pikeCommentError "\*/" + +syn keyword pikeOperator sizeof +syn keyword pikeType int string void float mapping array multiset mixed +syn keyword pikeType program object function + +syn region pikePreCondit start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=pikeComment,pikeString,pikeCharacter,pikeNumber,pikeCommentError +syn region pikeIncluded contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match pikeIncluded contained "<[^>]*>" +syn match pikeInclude "^\s*#\s*include\>\s*["<]" contains=pikeIncluded +"syn match pikeLineSkip "\\$" +syn region pikeDefine start="^\s*#\s*\(define\>\|undef\>\)" skip="\\$" end="$" contains=ALLBUT,pikePreCondit,pikeIncluded,pikeInclude,pikeDefine,pikeInParen +syn region pikePreProc start="^\s*#\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" contains=ALLBUT,pikePreCondit,pikeIncluded,pikeInclude,pikeDefine,pikeInParen + +" Highlight User Labels +syn region pikeMulti transparent start='?' end=':' contains=ALLBUT,pikeIncluded,pikeSpecial,pikeTodo,pikeUserLabel,pikeBitField +" Avoid matching foo::bar() in C++ by requiring that the next char is not ':' +syn match pikeUserLabel "^\s*\I\i*\s*:$" +syn match pikeUserLabel ";\s*\I\i*\s*:$"ms=s+1 +syn match pikeUserLabel "^\s*\I\i*\s*:[^:]"me=e-1 +syn match pikeUserLabel ";\s*\I\i*\s*:[^:]"ms=s+1,me=e-1 + +" Avoid recognizing most bitfields as labels +syn match pikeBitField "^\s*\I\i*\s*:\s*[1-9]"me=e-1 +syn match pikeBitField ";\s*\I\i*\s*:\s*[1-9]"me=e-1 + +syn sync ccomment pikeComment minlines=10 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link pikeLabel Label +hi def link pikeUserLabel Label +hi def link pikeConditional Conditional +hi def link pikeRepeat Repeat +hi def link pikeCharacter Character +hi def link pikeSpecialCharacter pikeSpecial +hi def link pikeNumber Number +hi def link pikeFloat Float +hi def link pikeOctalError pikeError +hi def link pikeParenError pikeError +hi def link pikeInParen pikeError +hi def link pikeCommentError pikeError +hi def link pikeOperator Operator +hi def link pikeInclude Include +hi def link pikePreProc PreProc +hi def link pikeDefine Macro +hi def link pikeIncluded pikeString +hi def link pikeError Error +hi def link pikeStatement Statement +hi def link pikePreCondit PreCondit +hi def link pikeType Type +hi def link pikeCommentError pikeError +hi def link pikeCommentString pikeString +hi def link pikeComment2String pikeString +hi def link pikeCommentSkip pikeComment +hi def link pikeString String +hi def link pikeComment Comment +hi def link pikeSpecial SpecialChar +hi def link pikeTodo Todo +hi def link pikeException pikeStatement +hi def link pikeCompoundType Constant +"hi def link pikeIdentifier Identifier + + +let b:current_syntax = "pike" + +" vim: ts=8 + +endif diff --git a/syntax/pilrc.vim b/syntax/pilrc.vim new file mode 100644 index 0000000..04030b6 --- /dev/null +++ b/syntax/pilrc.vim @@ -0,0 +1,140 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: pilrc - a resource compiler for Palm OS development +" Maintainer: Brian Schau +" Last change: 2003 May 11 +" Available on: http://www.schau.com/pilrcvim/pilrc.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" Notes: TRANSPARENT, FONT and FONT ID are defined in the specials +" section below. Beware of the order of the specials! +" Look in the syntax.txt and usr_27.txt files in vim\vim{version}\doc +" directory for regexps etc. + +" Keywords - basic +syn keyword pilrcKeyword ALERT APPLICATION APPLICATIONICONNAME AREA +syn keyword pilrcKeyword BITMAP BITMAPCOLOR BITMAPCOLOR16 BITMAPCOLOR16K +syn keyword pilrcKeyword BITMAPFAMILY BITMAPFAMILYEX BITMAPFAMILYSPECIAL +syn keyword pilrcKeyword BITMAPGREY BITMAPGREY16 BITMAPSCREENFAMILY +syn keyword pilrcKeyword BOOTSCREENFAMILY BUTTON BUTTONS BYTELIST +syn keyword pilrcKeyword CATEGORIES CHECKBOX COUNTRYLOCALISATION +syn keyword pilrcKeyword DATA +syn keyword pilrcKeyword FEATURE FIELD FONTINDEX FORM FORMBITMAP +syn keyword pilrcKeyword GADGET GENERATEHEADER +syn keyword pilrcKeyword GRAFFITIINPUTAREA GRAFFITISTATEINDICATOR +syn keyword pilrcKeyword HEX +syn keyword pilrcKeyword ICON ICONFAMILY ICONFAMILYEX INTEGER +syn keyword pilrcKeyword KEYBOARD +syn keyword pilrcKeyword LABEL LAUNCHERCATEGORY LIST LONGWORDLIST +syn keyword pilrcKeyword MENU MENUITEM MESSAGE MIDI +syn keyword pilrcKeyword PALETTETABLE POPUPLIST POPUPTRIGGER +syn keyword pilrcKeyword PULLDOWN PUSHBUTTON +syn keyword pilrcKeyword REPEATBUTTON RESETAUTOID +syn keyword pilrcKeyword SCROLLBAR SELECTORTRIGGER SLIDER SMALLICON +syn keyword pilrcKeyword SMALLICONFAMILY SMALLICONFAMILYEX STRING STRINGTABLE +syn keyword pilrcKeyword TABLE TITLE TRANSLATION TRAP +syn keyword pilrcKeyword VERSION +syn keyword pilrcKeyword WORDLIST + +" Types +syn keyword pilrcType AT AUTOSHIFT +syn keyword pilrcType BACKGROUNDID BITMAPID BOLDFRAME BPP +syn keyword pilrcType CHECKED COLORTABLE COLUMNS COLUMNWIDTHS COMPRESS +syn keyword pilrcType COMPRESSBEST COMPRESSPACKBITS COMPRESSRLE COMPRESSSCANLINE +syn keyword pilrcType CONFIRMATION COUNTRY CREATOR CURRENCYDECIMALPLACES +syn keyword pilrcType CURRENCYNAME CURRENCYSYMBOL CURRENCYUNIQUESYMBOL +syn keyword pilrcType DATEFORMAT DAYLIGHTSAVINGS DEFAULTBTNID DEFAULTBUTTON +syn keyword pilrcType DENSITY DISABLED DYNAMICSIZE +syn keyword pilrcType EDITABLE ENTRY ERROR EXTENDED +syn keyword pilrcType FEEDBACK FILE FONTID FORCECOMPRESS FRAME +syn keyword pilrcType GRAFFITI GRAPHICAL GROUP +syn keyword pilrcType HASSCROLLBAR HELPID +syn keyword pilrcType ID INDEX INFORMATION +syn keyword pilrcType KEYDOWNCHR KEYDOWNKEYCODE KEYDOWNMODIFIERS +syn keyword pilrcType LANGUAGE LEFTALIGN LEFTANCHOR LONGDATEFORMAT +syn keyword pilrcType MAX MAXCHARS MEASUREMENTSYSTEM MENUID MIN LOCALE +syn keyword pilrcType MINUTESWESTOFGMT MODAL MULTIPLELINES +syn keyword pilrcType NAME NOCOLORTABLE NOCOMPRESS NOFRAME NONEDITABLE +syn keyword pilrcType NONEXTENDED NONUSABLE NOSAVEBEHIND NUMBER NUMBERFORMAT +syn keyword pilrcType NUMERIC +syn keyword pilrcType PAGESIZE +syn keyword pilrcType RECTFRAME RIGHTALIGN RIGHTANCHOR ROWS +syn keyword pilrcType SAVEBEHIND SEARCH SCREEN SELECTEDBITMAPID SINGLELINE +syn keyword pilrcType THUMBID TRANSPARENTINDEX TIMEFORMAT +syn keyword pilrcType UNDERLINED USABLE +syn keyword pilrcType VALUE VERTICAL VISIBLEITEMS +syn keyword pilrcType WARNING WEEKSTARTDAY + +" Country +syn keyword pilrcCountry Australia Austria Belgium Brazil Canada Denmark +syn keyword pilrcCountry Finland France Germany HongKong Iceland Indian +syn keyword pilrcCountry Indonesia Ireland Italy Japan Korea Luxembourg Malaysia +syn keyword pilrcCountry Mexico Netherlands NewZealand Norway Philippines +syn keyword pilrcCountry RepChina Singapore Spain Sweden Switzerland Thailand +syn keyword pilrcCountry Taiwan UnitedKingdom UnitedStates + +" Language +syn keyword pilrcLanguage English French German Italian Japanese Spanish + +" String +syn match pilrcString "\"[^"]*\"" + +" Number +syn match pilrcNumber "\<0x\x\+\>" +syn match pilrcNumber "\<\d\+\>" + +" Comment +syn region pilrcComment start="/\*" end="\*/" +syn region pilrcComment start="//" end="$" + +" Constants +syn keyword pilrcConstant AUTO AUTOID BOTTOM CENTER PREVBOTTOM PREVHEIGHT +syn keyword pilrcConstant PREVLEFT PREVRIGHT PREVTOP PREVWIDTH RIGHT +syn keyword pilrcConstant SEPARATOR + +" Identifier +syn match pilrcIdentifier "\<\h\w*\>" + +" Specials +syn match pilrcType "\" +syn match pilrcKeyword "\\s*\" +syn match pilrcType "\" + +" Function +syn keyword pilrcFunction BEGIN END + +" Include +syn match pilrcInclude "\#include" +syn match pilrcInclude "\#define" +syn keyword pilrcInclude equ +syn keyword pilrcInclude package +syn region pilrcInclude start="public class" end="}" + +syn sync ccomment pilrcComment + + +" The default methods for highlighting +hi def link pilrcKeyword Statement +hi def link pilrcType Type +hi def link pilrcError Error +hi def link pilrcCountry SpecialChar +hi def link pilrcLanguage SpecialChar +hi def link pilrcString SpecialChar +hi def link pilrcNumber Number +hi def link pilrcComment Comment +hi def link pilrcConstant Constant +hi def link pilrcFunction Function +hi def link pilrcInclude SpecialChar +hi def link pilrcIdentifier Number + + +let b:current_syntax = "pilrc" + +endif diff --git a/syntax/pine.vim b/syntax/pine.vim new file mode 100644 index 0000000..a632503 --- /dev/null +++ b/syntax/pine.vim @@ -0,0 +1,359 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Pine (email program) run commands +" Maintainer: David Pascoe +" Last Change: Thu Feb 27 10:18:48 WST 2003, update for pine 4.53 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=@,48-57,_,128-167,224-235,- + +syn keyword pineConfig addrbook-sort-rule +syn keyword pineConfig address-book +syn keyword pineConfig addressbook-formats +syn keyword pineConfig alt-addresses +syn keyword pineConfig bugs-additional-data +syn keyword pineConfig bugs-address +syn keyword pineConfig bugs-fullname +syn keyword pineConfig character-set +syn keyword pineConfig color-style +syn keyword pineConfig compose-mime +syn keyword pineConfig composer-wrap-column +syn keyword pineConfig current-indexline-style +syn keyword pineConfig cursor-style +syn keyword pineConfig customized-hdrs +syn keyword pineConfig debug-memory +syn keyword pineConfig default-composer-hdrs +syn keyword pineConfig default-fcc +syn keyword pineConfig default-saved-msg-folder +syn keyword pineConfig disable-these-authenticators +syn keyword pineConfig disable-these-drivers +syn keyword pineConfig display-filters +syn keyword pineConfig download-command +syn keyword pineConfig download-command-prefix +syn keyword pineConfig editor +syn keyword pineConfig elm-style-save +syn keyword pineConfig empty-header-message +syn keyword pineConfig fcc-name-rule +syn keyword pineConfig feature-level +syn keyword pineConfig feature-list +syn keyword pineConfig file-directory +syn keyword pineConfig folder-collections +syn keyword pineConfig folder-extension +syn keyword pineConfig folder-sort-rule +syn keyword pineConfig font-char-set +syn keyword pineConfig font-name +syn keyword pineConfig font-size +syn keyword pineConfig font-style +syn keyword pineConfig forced-abook-entry +syn keyword pineConfig form-letter-folder +syn keyword pineConfig global-address-book +syn keyword pineConfig goto-default-rule +syn keyword pineConfig header-in-reply +syn keyword pineConfig image-viewer +syn keyword pineConfig inbox-path +syn keyword pineConfig incoming-archive-folders +syn keyword pineConfig incoming-folders +syn keyword pineConfig incoming-startup-rule +syn keyword pineConfig index-answered-background-color +syn keyword pineConfig index-answered-foreground-color +syn keyword pineConfig index-deleted-background-color +syn keyword pineConfig index-deleted-foreground-color +syn keyword pineConfig index-format +syn keyword pineConfig index-important-background-color +syn keyword pineConfig index-important-foreground-color +syn keyword pineConfig index-new-background-color +syn keyword pineConfig index-new-foreground-color +syn keyword pineConfig index-recent-background-color +syn keyword pineConfig index-recent-foreground-color +syn keyword pineConfig index-to-me-background-color +syn keyword pineConfig index-to-me-foreground-color +syn keyword pineConfig index-unseen-background-color +syn keyword pineConfig index-unseen-foreground-color +syn keyword pineConfig initial-keystroke-list +syn keyword pineConfig kblock-passwd-count +syn keyword pineConfig keylabel-background-color +syn keyword pineConfig keylabel-foreground-color +syn keyword pineConfig keyname-background-color +syn keyword pineConfig keyname-foreground-color +syn keyword pineConfig last-time-prune-questioned +syn keyword pineConfig last-version-used +syn keyword pineConfig ldap-servers +syn keyword pineConfig literal-signature +syn keyword pineConfig local-address +syn keyword pineConfig local-fullname +syn keyword pineConfig mail-check-interval +syn keyword pineConfig mail-directory +syn keyword pineConfig mailcap-search-path +syn keyword pineConfig mimetype-search-path +syn keyword pineConfig new-version-threshold +syn keyword pineConfig news-active-file-path +syn keyword pineConfig news-collections +syn keyword pineConfig news-spool-directory +syn keyword pineConfig newsrc-path +syn keyword pineConfig nntp-server +syn keyword pineConfig normal-background-color +syn keyword pineConfig normal-foreground-color +syn keyword pineConfig old-style-reply +syn keyword pineConfig operating-dir +syn keyword pineConfig patterns +syn keyword pineConfig patterns-filters +syn keyword pineConfig patterns-filters2 +syn keyword pineConfig patterns-indexcolors +syn keyword pineConfig patterns-other +syn keyword pineConfig patterns-roles +syn keyword pineConfig patterns-scores +syn keyword pineConfig patterns-scores2 +syn keyword pineConfig personal-name +syn keyword pineConfig personal-print-category +syn keyword pineConfig personal-print-command +syn keyword pineConfig postponed-folder +syn keyword pineConfig print-font-char-set +syn keyword pineConfig print-font-name +syn keyword pineConfig print-font-size +syn keyword pineConfig print-font-style +syn keyword pineConfig printer +syn keyword pineConfig prompt-background-color +syn keyword pineConfig prompt-foreground-color +syn keyword pineConfig pruned-folders +syn keyword pineConfig pruning-rule +syn keyword pineConfig quote1-background-color +syn keyword pineConfig quote1-foreground-color +syn keyword pineConfig quote2-background-color +syn keyword pineConfig quote2-foreground-color +syn keyword pineConfig quote3-background-color +syn keyword pineConfig quote3-foreground-color +syn keyword pineConfig read-message-folder +syn keyword pineConfig remote-abook-history +syn keyword pineConfig remote-abook-metafile +syn keyword pineConfig remote-abook-validity +syn keyword pineConfig reply-indent-string +syn keyword pineConfig reply-leadin +syn keyword pineConfig reverse-background-color +syn keyword pineConfig reverse-foreground-color +syn keyword pineConfig rsh-command +syn keyword pineConfig rsh-open-timeout +syn keyword pineConfig rsh-path +syn keyword pineConfig save-by-sender +syn keyword pineConfig saved-msg-name-rule +syn keyword pineConfig scroll-margin +syn keyword pineConfig selectable-item-background-color +syn keyword pineConfig selectable-item-foreground-color +syn keyword pineConfig sending-filters +syn keyword pineConfig sendmail-path +syn keyword pineConfig show-all-characters +syn keyword pineConfig signature-file +syn keyword pineConfig smtp-server +syn keyword pineConfig sort-key +syn keyword pineConfig speller +syn keyword pineConfig ssh-command +syn keyword pineConfig ssh-open-timeout +syn keyword pineConfig ssh-path +syn keyword pineConfig standard-printer +syn keyword pineConfig status-background-color +syn keyword pineConfig status-foreground-color +syn keyword pineConfig status-message-delay +syn keyword pineConfig suggest-address +syn keyword pineConfig suggest-fullname +syn keyword pineConfig tcp-open-timeout +syn keyword pineConfig tcp-query-timeout +syn keyword pineConfig tcp-read-warning-timeout +syn keyword pineConfig tcp-write-warning-timeout +syn keyword pineConfig threading-display-style +syn keyword pineConfig threading-expanded-character +syn keyword pineConfig threading-index-style +syn keyword pineConfig threading-indicator-character +syn keyword pineConfig threading-lastreply-character +syn keyword pineConfig title-background-color +syn keyword pineConfig title-foreground-color +syn keyword pineConfig titlebar-color-style +syn keyword pineConfig upload-command +syn keyword pineConfig upload-command-prefix +syn keyword pineConfig url-viewers +syn keyword pineConfig use-only-domain-name +syn keyword pineConfig user-domain +syn keyword pineConfig user-id +syn keyword pineConfig user-id +syn keyword pineConfig user-input-timeout +syn keyword pineConfig viewer-hdr-colors +syn keyword pineConfig viewer-hdrs +syn keyword pineConfig viewer-overlap +syn keyword pineConfig window-position + +syn keyword pineOption allow-changing-from +syn keyword pineOption allow-talk +syn keyword pineOption alternate-compose-menu +syn keyword pineOption assume-slow-link +syn keyword pineOption auto-move-read-msgs +syn keyword pineOption auto-open-next-unread +syn keyword pineOption auto-unzoom-after-apply +syn keyword pineOption auto-zoom-after-select +syn keyword pineOption cache-remote-pinerc +syn keyword pineOption check-newmail-when-quitting +syn keyword pineOption combined-addrbook-display +syn keyword pineOption combined-folder-display +syn keyword pineOption combined-subdirectory-display +syn keyword pineOption compose-cut-from-cursor +syn keyword pineOption compose-maps-delete-key-to-ctrl-d +syn keyword pineOption compose-rejects-unqualified-addrs +syn keyword pineOption compose-send-offers-first-filter +syn keyword pineOption compose-sets-newsgroup-without-confirm +syn keyword pineOption confirm-role-even-for-default +syn keyword pineOption continue-tab-without-confirm +syn keyword pineOption delete-skips-deleted +syn keyword pineOption disable-2022-jp-conversions +syn keyword pineOption disable-busy-alarm +syn keyword pineOption disable-charset-conversions +syn keyword pineOption disable-config-cmd +syn keyword pineOption disable-keyboard-lock-cmd +syn keyword pineOption disable-keymenu +syn keyword pineOption disable-password-caching +syn keyword pineOption disable-password-cmd +syn keyword pineOption disable-pipes-in-sigs +syn keyword pineOption disable-pipes-in-templates +syn keyword pineOption disable-roles-setup-cmd +syn keyword pineOption disable-roles-sig-edit +syn keyword pineOption disable-roles-template-edit +syn keyword pineOption disable-sender +syn keyword pineOption disable-shared-namespaces +syn keyword pineOption disable-signature-edit-cmd +syn keyword pineOption disable-take-last-comma-first +syn keyword pineOption enable-8bit-esmtp-negotiation +syn keyword pineOption enable-8bit-nntp-posting +syn keyword pineOption enable-aggregate-command-set +syn keyword pineOption enable-alternate-editor-cmd +syn keyword pineOption enable-alternate-editor-implicitly +syn keyword pineOption enable-arrow-navigation +syn keyword pineOption enable-arrow-navigation-relaxed +syn keyword pineOption enable-background-sending +syn keyword pineOption enable-bounce-cmd +syn keyword pineOption enable-cruise-mode +syn keyword pineOption enable-cruise-mode-delete +syn keyword pineOption enable-delivery-status-notification +syn keyword pineOption enable-dot-files +syn keyword pineOption enable-dot-folders +syn keyword pineOption enable-exit-via-lessthan-command +syn keyword pineOption enable-fast-recent-test +syn keyword pineOption enable-flag-cmd +syn keyword pineOption enable-flag-screen-implicitly +syn keyword pineOption enable-full-header-and-text +syn keyword pineOption enable-full-header-cmd +syn keyword pineOption enable-goto-in-file-browser +syn keyword pineOption enable-incoming-folders +syn keyword pineOption enable-jump-shortcut +syn keyword pineOption enable-lame-list-mode +syn keyword pineOption enable-mail-check-cue +syn keyword pineOption enable-mailcap-param-substitution +syn keyword pineOption enable-mouse-in-xterm +syn keyword pineOption enable-msg-view-addresses +syn keyword pineOption enable-msg-view-attachments +syn keyword pineOption enable-msg-view-forced-arrows +syn keyword pineOption enable-msg-view-urls +syn keyword pineOption enable-msg-view-web-hostnames +syn keyword pineOption enable-newmail-in-xterm-icon +syn keyword pineOption enable-partial-match-lists +syn keyword pineOption enable-print-via-y-command +syn keyword pineOption enable-reply-indent-string-editing +syn keyword pineOption enable-rules-under-take +syn keyword pineOption enable-search-and-replace +syn keyword pineOption enable-sigdashes +syn keyword pineOption enable-suspend +syn keyword pineOption enable-tab-completion +syn keyword pineOption enable-take-export +syn keyword pineOption enable-tray-icon +syn keyword pineOption enable-unix-pipe-cmd +syn keyword pineOption enable-verbose-smtp-posting +syn keyword pineOption expanded-view-of-addressbooks +syn keyword pineOption expanded-view-of-distribution-lists +syn keyword pineOption expanded-view-of-folders +syn keyword pineOption expose-hidden-config +syn keyword pineOption expunge-only-manually +syn keyword pineOption expunge-without-confirm +syn keyword pineOption expunge-without-confirm-everywhere +syn keyword pineOption fcc-on-bounce +syn keyword pineOption fcc-only-without-confirm +syn keyword pineOption fcc-without-attachments +syn keyword pineOption include-attachments-in-reply +syn keyword pineOption include-header-in-reply +syn keyword pineOption include-text-in-reply +syn keyword pineOption ldap-result-to-addrbook-add +syn keyword pineOption mark-fcc-seen +syn keyword pineOption mark-for-cc +syn keyword pineOption news-approximates-new-status +syn keyword pineOption news-deletes-across-groups +syn keyword pineOption news-offers-catchup-on-close +syn keyword pineOption news-post-without-validation +syn keyword pineOption news-read-in-newsrc-order +syn keyword pineOption next-thread-without-confirm +syn keyword pineOption old-growth +syn keyword pineOption pass-control-characters-as-is +syn keyword pineOption prefer-plain-text +syn keyword pineOption preserve-start-stop-characters +syn keyword pineOption print-formfeed-between-messages +syn keyword pineOption print-includes-from-line +syn keyword pineOption print-index-enabled +syn keyword pineOption print-offers-custom-cmd-prompt +syn keyword pineOption quell-attachment-extra-prompt +syn keyword pineOption quell-berkeley-format-timezone +syn keyword pineOption quell-content-id +syn keyword pineOption quell-dead-letter-on-cancel +syn keyword pineOption quell-empty-directories +syn keyword pineOption quell-extra-post-prompt +syn keyword pineOption quell-folder-internal-msg +syn keyword pineOption quell-imap-envelope-update +syn keyword pineOption quell-lock-failure-warnings +syn keyword pineOption quell-maildomain-warning +syn keyword pineOption quell-news-envelope-update +syn keyword pineOption quell-partial-fetching +syn keyword pineOption quell-ssl-largeblocks +syn keyword pineOption quell-status-message-beeping +syn keyword pineOption quell-timezone-comment-when-sending +syn keyword pineOption quell-user-lookup-in-passwd-file +syn keyword pineOption quit-without-confirm +syn keyword pineOption reply-always-uses-reply-to +syn keyword pineOption save-aggregates-copy-sequence +syn keyword pineOption save-will-advance +syn keyword pineOption save-will-not-delete +syn keyword pineOption save-will-quote-leading-froms +syn keyword pineOption scramble-message-id +syn keyword pineOption select-without-confirm +syn keyword pineOption selectable-item-nobold +syn keyword pineOption separate-folder-and-directory-entries +syn keyword pineOption show-cursor +syn keyword pineOption show-plain-text-internally +syn keyword pineOption show-selected-in-boldface +syn keyword pineOption signature-at-bottom +syn keyword pineOption single-column-folder-list +syn keyword pineOption slash-collapses-entire-thread +syn keyword pineOption spell-check-before-sending +syn keyword pineOption store-window-position-in-config +syn keyword pineOption strip-from-sigdashes-on-reply +syn keyword pineOption tab-visits-next-new-message-only +syn keyword pineOption termdef-takes-precedence +syn keyword pineOption thread-index-shows-important-color +syn keyword pineOption try-alternative-authentication-driver-first +syn keyword pineOption unselect-will-not-advance +syn keyword pineOption use-current-dir +syn keyword pineOption use-function-keys +syn keyword pineOption use-sender-not-x-sender +syn keyword pineOption use-subshell-for-suspend +syn keyword pineOption vertical-folder-list + +syn match pineComment "^#.*$" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link pineConfig Type +hi def link pineComment Comment +hi def link pineOption Macro + +let b:current_syntax = "pine" + +" vim: ts=8 + +endif diff --git a/syntax/pinfo.vim b/syntax/pinfo.vim new file mode 100644 index 0000000..a6c8e03 --- /dev/null +++ b/syntax/pinfo.vim @@ -0,0 +1,114 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: pinfo(1) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2007-06-17 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword+=- + +syn case ignore + +syn keyword pinfoTodo contained FIXME TODO XXX NOTE + +syn region pinfoComment start='^#' end='$' contains=pinfoTodo,@Spell + +syn keyword pinfoOptions MANUAL CUT-MAN-HEADERS CUT-EMPTY-MAN-LINES + \ RAW-FILENAME APROPOS + \ DONT-HANDLE-WITHOUT-TAG-TABLE HTTPVIEWER + \ FTPVIEWER MAILEDITOR PRINTUTILITY MANLINKS + \ INFOPATH MAN-OPTIONS STDERR-REDIRECTION + \ LONG-MANUAL-LINKS FILTER-0xB7 + \ QUIT-CONFIRMATION QUIT-CONFIRM-DEFAULT + \ CLEAR-SCREEN-AT-EXIT CALL-READLINE-HISTORY + \ HIGHLIGHTREGEXP SAFE-USER SAFE-GROUP + +syn keyword pinfoColors COL_NORMAL COL_TOPLINE COL_BOTTOMLINE + \ COL_MENU COL_MENUSELECTED COL_NOTE + \ COL_NOTESELECTED COL_URL COL_URLSELECTED + \ COL_INFOHIGHLIGHT COL_MANUALBOLD + \ COL_MANUALITALIC COL_SEARCHHIGHLIGHT + +syn keyword pinfoColorDefault COLOR_DEFAULT +syn keyword pinfoColorBold BOLD +syn keyword pinfoColorNoBold NO_BOLD +syn keyword pinfoColorBlink BLINK +syn keyword pinfoColorNoBlink NO_BLINK +syn keyword pinfoColorBlack COLOR_BLACK +syn keyword pinfoColorRed COLOR_RED +syn keyword pinfoColorGreen COLOR_GREEN +syn keyword pinfoColorYellow COLOR_YELLOW +syn keyword pinfoColorBlue COLOR_BLUE +syn keyword pinfoColorMagenta COLOR_MAGENTA +syn keyword pinfoColorCyan COLOR_CYAN +syn keyword pinfoColorWhite COLOR_WHITE + +syn keyword pinfoKeys KEY_TOTALSEARCH_1 KEY_TOTALSEARCH_2 + \ KEY_SEARCH_1 KEY_SEARCH_2 + \ KEY_SEARCH_AGAIN_1 KEY_SEARCH_AGAIN_2 + \ KEY_GOTO_1 KEY_GOTO_2 KEY_PREVNODE_1 + \ KEY_PREVNODE_2 KEY_NEXTNODE_1 + \ KEY_NEXTNODE_2 KEY_UP_1 KEY_UP_2 KEY_END_1 + \ KEY_END_2 KEY_PGDN_1 KEY_PGDN_2 + \ KEY_PGDN_AUTO_1 KEY_PGDN_AUTO_2 KEY_HOME_1 + \ KEY_HOME_2 KEY_PGUP_1 KEY_PGUP_2 + \ KEY_PGUP_AUTO_1 KEY_PGUP_AUTO_2 KEY_DOWN_1 + \ KEY_DOWN_2 KEY_TOP_1 KEY_TOP_2 KEY_BACK_1 + \ KEY_BACK_2 KEY_FOLLOWLINK_1 + \ KEY_FOLLOWLINK_2 KEY_REFRESH_1 + \ KEY_REFRESH_2 KEY_SHELLFEED_1 + \ KEY_SHELLFEED_2 KEY_QUIT_1 KEY_QUIT_2 + \ KEY_GOLINE_1 KEY_GOLINE_2 KEY_PRINT_1 + \ KEY_PRINT_2 KEY_DIRPAGE_1 KEY_DIRPAGE_2 + \ KEY_TWODOWN_1 KEY_TWODOWN_2 KEY_TWOUP_1 + \ KEY_TWOUP_2 + +syn keyword pinfoSpecialKeys KEY_BREAK KEY_DOWN KEY_UP KEY_LEFT KEY_RIGHT + \ KEY_DOWN KEY_HOME KEY_BACKSPACE KEY_NPAGE + \ KEY_PPAGE KEY_END KEY_IC KEY_DC +syn region pinfoSpecialKeys matchgroup=pinfoSpecialKeys transparent + \ start=+KEY_\%(F\|CTRL\|ALT\)(+ end=+)+ +syn region pinfoSimpleKey start=+'+ skip=+\\'+ end=+'+ + \ contains=pinfoSimpleKeyEscape +syn match pinfoSimpleKeyEscape +\\[\\nt']+ +syn match pinfoKeycode '\<\d\+\>' + +syn keyword pinfoConstants TRUE FALSE YES NO + +hi def link pinfoTodo Todo +hi def link pinfoComment Comment +hi def link pinfoOptions Keyword +hi def link pinfoColors Keyword +hi def link pinfoColorDefault Normal +hi def link pinfoSpecialKeys SpecialChar +hi def link pinfoSimpleKey String +hi def link pinfoSimpleKeyEscape SpecialChar +hi def link pinfoKeycode Number +hi def link pinfoConstants Constant +hi def link pinfoKeys Keyword +hi def pinfoColorBold cterm=bold +hi def pinfoColorNoBold cterm=none +hi def pinfoColorBlink cterm=inverse +hi def pinfoColorNoBlink cterm=none +hi def pinfoColorBlack ctermfg=Black guifg=Black +hi def pinfoColorRed ctermfg=DarkRed guifg=DarkRed +hi def pinfoColorGreen ctermfg=DarkGreen guifg=DarkGreen +hi def pinfoColorYellow ctermfg=DarkYellow guifg=DarkYellow +hi def pinfoColorBlue ctermfg=DarkBlue guifg=DarkBlue +hi def pinfoColorMagenta ctermfg=DarkMagenta guifg=DarkMagenta +hi def pinfoColorCyan ctermfg=DarkCyan guifg=DarkCyan +hi def pinfoColorWhite ctermfg=LightGray guifg=LightGray + +let b:current_syntax = "pinfo" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/plaintex.vim b/syntax/plaintex.vim new file mode 100644 index 0000000..12a89b7 --- /dev/null +++ b/syntax/plaintex.vim @@ -0,0 +1,174 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TeX (plain.tex format) +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-10-26 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match plaintexControlSequence display contains=@NoSpell + \ '\\[a-zA-Z@]\+' + +runtime! syntax/initex.vim +unlet b:current_syntax + +syn match plaintexComment display + \ contains=ALLBUT,initexComment,plaintexComment + \ '^\s*%[CDM].*$' + +if exists("g:plaintex_delimiters") + syn match plaintexDelimiter display '[][{}]' +endif + +syn match plaintexRepeat display contains=@NoSpell + \ '\\\%(loop\|repeat\)\>' + +syn match plaintexCommand display contains=@NoSpell + \ '\\\%(plainoutput\|TeX\)\>' +syn match plaintexBoxCommand display contains=@NoSpell + \ '\\\%(null\|strut\)\>' +syn match plaintexDebuggingCommand display contains=@NoSpell + \ '\\\%(showhyphens\|tracingall\|wlog\)\>' +syn match plaintexFontsCommand display contains=@NoSpell + \ '\\\%(bf\|\%(five\|seven\)\%(bf\|i\|rm\|sy\)\|it\|oldstyle\|rm\|sl\|ten\%(bf\|ex\|it\=\|rm\|sl\|sy\|tt\)\|tt\)\>' +syn match plaintexGlueCommand display contains=@NoSpell + \ '\\\%(\%(big\|en\|med\|\%(no\|off\)interline\|small\)skip\|\%(center\|left\|right\)\=line\|\%(dot\|\%(left\|right\)arrow\)fill\|[hv]glue\|[lr]lap\|q\=quad\|space\|topglue\)\>' +syn match plaintexInsertsCommand display contains=@NoSpell + \ '\\\%(\%(end\|top\)insert\|v\=footnote\)\>' +syn match plaintexJobCommand display contains=@NoSpell + \ '\\\%(bye\|fmt\%(name\|version\)\)\>' +syn match plaintexInsertsCommand display contains=@NoSpell + \ '\\\%(mid\|page\)insert\>' +syn match plaintexKernCommand display contains=@NoSpell + \ '\\\%(en\|\%(neg\)\=thin\)space\>' +syn match plaintexMacroCommand display contains=@NoSpell + \ '\\\%(active\|[be]group\|empty\)\>' +syn match plaintexPageCommand display contains=@NoSpell + \ '\\\%(\%(super\)\=eject\|nopagenumbers\|\%(normal\|ragged\)bottom\)\>' +syn match plaintexParagraphCommand display contains=@NoSpell + \ '\\\%(endgraf\|\%(non\)\=frenchspacing\|hang\|item\%(item\)\=\|narrower\|normalbaselines\|obey\%(lines\|spaces\)\|openup\|proclaim\|\%(tt\)\=raggedright\|textindent\)\>' +syn match plaintexPenaltiesCommand display contains=@NoSpell + \ '\\\%(allow\|big\|fil\|good\|med\|no\|small\)\=break\>' +syn match plaintexRegistersCommand display contains=@NoSpell + \ '\\\%(advancepageno\|new\%(box\|count\|dimen\|fam\|help\|if\|insert\|language\|muskip\|read\|skip\|toks\|write\)\)\>' +syn match plaintexTablesCommand display contains=@NoSpell + \ '&\|\\+\|\\\%(cleartabs\|endline\|hidewidth\|ialign\|multispan\|settabs\|tabalign\)\>' + +if !exists("g:plaintex_no_math") + syn region plaintexMath matchgroup=plaintexMath + \ contains=@plaintexMath,@NoSpell + \ start='\$' skip='\\\\\|\\\$' end='\$' + syn region plaintexMath matchgroup=plaintexMath + \ contains=@plaintexMath,@NoSpell keepend + \ start='\$\$' skip='\\\\\|\\\$' end='\$\$' +endif + +" Keep this after plaintexMath, as we don’t want math mode started at a \$. +syn match plaintexCharacterCommand display contains=@NoSpell + \ /\\\%(["#$%&'.=^_`~]\|``\|''\|-\{2,3}\|[?!]`\|^^L\|\~\|\%(a[ae]\|A[AE]\|acute\|[cdHoOPStuvijlL]\|copyright\|d\=dag\|folio\|ldotp\|[lr]q\|oe\|OE\|slash\|ss\|underbar\)\>\)/ + +syn cluster plaintexMath + \ contains=plaintexMathCommand,plaintexMathBoxCommand, + \ plaintexMathCharacterCommand,plaintexMathDelimiter, + \ plaintexMathFontsCommand,plaintexMathLetter,plaintexMathSymbol, + \ plaintexMathFunction,plaintexMathOperator,plaintexMathPunctuation, + \ plaintexMathRelation + +syn match plaintexMathCommand display contains=@NoSpell contained + \ '\\\%([!*,;>{}|_^]\|\%([aA]rrowvert\|[bB]ig\%(g[lmr]\=\|r\)\=\|\%(border\|p\)\=matrix\|displaylines\|\%(down\|up\)bracefill\|eqalign\%(no\)\|leqalignno\|[lr]moustache\|mathpalette\|root\|s[bp]\|skew\|sqrt\)\>\)' +syn match plaintexMathBoxCommand display contains=@NoSpell contained + \ '\\\%([hv]\=phantom\|mathstrut\|smash\)\>' +syn match plaintexMathCharacterCommand display contains=@NoSpell contained + \ '\\\%(b\|bar\|breve\|check\|d\=dots\=\|grave\|hat\|[lv]dots\|tilde\|vec\|wide\%(hat\|tilde\)\)\>' +syn match plaintexMathDelimiter display contains=@NoSpell contained + \ '\\\%(brace\%(vert\)\=\|brack\|cases\|choose\|[lr]\%(angle\|brace\|brack\|ceil\|floor\|group\)\|over\%(brace\|\%(left\|right\)arrow\)\|underbrace\)\>' +syn match plaintexMathFontsCommand display contains=@NoSpell contained + \ '\\\%(\%(bf\|it\|sl\|tt\)fam\|cal\|mit\)\>' +syn match plaintexMathLetter display contains=@NoSpell contained + \ '\\\%(aleph\|alpha\|beta\|chi\|[dD]elta\|ell\|epsilon\|eta\|[gG]amma\|[ij]math\|iota\|kappa\|[lL]ambda\|[mn]u\|[oO]mega\|[pP][hs]\=i\|rho\|[sS]igma\|tau\|[tT]heta\|[uU]psilon\|var\%(epsilon\|ph\=i\|rho\|sigma\|theta\)\|[xX]i\|zeta\)\>' +syn match plaintexMathSymbol display contains=@NoSpell contained + \ '\\\%(angle\|backslash\|bot\|clubsuit\|emptyset\|epsilon\|exists\|flat\|forall\|hbar\|heartsuit\|Im\|infty\|int\|lnot\|nabla\|natural\|neg\|pmod\|prime\|Re\|sharp\|smallint\|spadesuit\|surd\|top\|triangle\%(left\|right\)\=\|vdash\|wp\)\>' +syn match plaintexMathFunction display contains=@NoSpell contained + \ '\\\%(arc\%(cos\|sin\|tan\)\|arg\|\%(cos\|sin\|tan\)h\=\|coth\=\|csc\|de[gt]\|dim\|exp\|gcd\|hom\|inf\|ker\|lo\=g\|lim\%(inf\|sup\)\=\|ln\|max\|min\|Pr\|sec\|sup\)\>' +syn match plaintexMathOperator display contains=@NoSpell contained + \ '\\\%(amalg\|ast\|big\%(c[au]p\|circ\|o\%(dot\|plus\|times\|sqcup\)\|triangle\%(down\|up\)\|uplus\|vee\|wedge\|bmod\|bullet\)\|c[au]p\|cdot[ps]\=\|circ\|coprod\|d\=dagger\|diamond\%(suit\)\=\|div\|land\|lor\|mp\|o\%(dot\|int\|minus\|plus\|slash\|times\)pm\|prod\|setminus\|sqc[au]p\|sqsu[bp]seteq\|star\|su[bp]set\%(eq\)\=\|sum\|times\|uplus\|vee\|wedge\|wr\)\>' +syn match plaintexMathPunctuation display contains=@NoSpell contained + \ '\\\%(colon\)\>' +syn match plaintexMathRelation display contains=@NoSpell contained + \ '\\\%(approx\|asymp\|bowtie\|buildrel\|cong\|dashv\|doteq\|[dD]ownarrow\|equiv\|frown\|geq\=\|gets\|gg\|hook\%(left\|right\)arrow\|iff\|in\|leq\=\|[lL]eftarrow\|\%(left\|right\)harpoon\%(down\|up\)\|[lL]eftrightarrow\|ll\|[lL]ongleftrightarrow\|longmapsto\|[lL]ongrightarrow\|mapsto\|mid\|models\|[ns][ew]arrow\|neq\=\|ni\|not\%(in\)\=\|owns\|parallel\|perp\|prec\%(eq\)\=\|propto\|[rR]ightarrow\|rightleftharpoons\|sim\%(eq\)\=\|smile\|succ\%(eq\)\=\|to\|[uU]parrow\|[uU]pdownarrow\|[vV]ert\)\>' + +syn match plaintexParameterDimen display contains=@NoSpell + \ '\\maxdimen\>' +syn match plaintexMathParameterDimen display contains=@NoSpell + \ '\\jot\>' +syn match plaintexParagraphParameterGlue display contains=@NoSpell + \ '\\\%(\%(big\|med\|small\)skipamount\|normalbaselineskip\|normallineskip\%(limit\)\=\)\>' + +syn match plaintexFontParameterInteger display contains=@NoSpell + \ '\\magstep\%(half\)\=\>' +syn match plaintexJobParameterInteger display contains=@NoSpell + \ '\\magnification\>' +syn match plaintexPageParameterInteger display contains=@NoSpell + \ '\\pageno\>' + +syn match plaintexPageParameterToken display contains=@NoSpell + \ '\\\%(foot\|head\)line\>' + +hi def link plaintexOperator Operator + +hi def link plaintexDelimiter Delimiter + +hi def link plaintexControlSequence Identifier +hi def link plaintexComment Comment +hi def link plaintexInclude Include +hi def link plaintexRepeat Repeat + +hi def link plaintexCommand initexCommand +hi def link plaintexBoxCommand plaintexCommand +hi def link plaintexCharacterCommand initexCharacterCommand +hi def link plaintexDebuggingCommand initexDebuggingCommand +hi def link plaintexFontsCommand initexFontsCommand +hi def link plaintexGlueCommand plaintexCommand +hi def link plaintexInsertsCommand plaintexCommand +hi def link plaintexJobCommand initexJobCommand +hi def link plaintexKernCommand plaintexCommand +hi def link plaintexMacroCommand initexMacroCommand +hi def link plaintexPageCommand plaintexCommand +hi def link plaintexParagraphCommand plaintexCommand +hi def link plaintexPenaltiesCommand plaintexCommand +hi def link plaintexRegistersCommand plaintexCommand +hi def link plaintexTablesCommand plaintexCommand + +hi def link plaintexMath String +hi def link plaintexMathCommand plaintexCommand +hi def link plaintexMathBoxCommand plaintexBoxCommand +hi def link plaintexMathCharacterCommand plaintexCharacterCommand +hi def link plaintexMathDelimiter plaintexDelimiter +hi def link plaintexMathFontsCommand plaintexFontsCommand +hi def link plaintexMathLetter plaintexMathCharacterCommand +hi def link plaintexMathSymbol plaintexMathLetter +hi def link plaintexMathFunction Function +hi def link plaintexMathOperator plaintexOperator +hi def link plaintexMathPunctuation plaintexCharacterCommand +hi def link plaintexMathRelation plaintexOperator + +hi def link plaintexParameterDimen initexParameterDimen +hi def link plaintexMathParameterDimen initexMathParameterDimen +hi def link plaintexParagraphParameterGlue initexParagraphParameterGlue +hi def link plaintexFontParameterInteger initexFontParameterInteger +hi def link plaintexJobParameterInteger initexJobParameterInteger +hi def link plaintexPageParameterInteger initexPageParameterInteger +hi def link plaintexPageParameterToken initexParameterToken + +let b:current_syntax = "plaintex" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/pli.vim b/syntax/pli.vim new file mode 100644 index 0000000..6f64319 --- /dev/null +++ b/syntax/pli.vim @@ -0,0 +1,270 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Modified from http://plnet.org/files/vim/ +" using keywords from http://www.kednos.com/pli/docs/reference_manual/6291pro_contents.html +" 2012-11-13 Alan Thompson + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" Todo. +syn keyword pl1Todo TODO FIXME XXX DEBUG NOTE + +" pl1CommentGroup allows adding matches for special things in comments +" 20010723az: Added this so that these could be matched in comments... +syn cluster pl1CommentGroup contains=pl1Todo + +syn match pl1Garbage "[^ \t()]" +syn match pl1Identifier "[a-z][a-z0-9$_#]*" +syn match pl1HostIdentifier ":[a-z][a-z0-9$_#]*" + +" 20010723az: When wanted, highlight the trailing whitespace -- this is +" based on c_space_errors +if exists("c_space_errors") + if !exists("c_no_trail_space_error") + syn match pl1SpaceError "\s\+$" + endif + if !exists("c_no_tab_space_error") + syn match pl1SpaceError " \+\t"me=e-1 + endif +endif + +" Symbols. +syn match pl1Symbol "\(;\|,\|\.\)" +syn match pl1PreProcSym "%" + +" Operators. +syn match pl1Operator "\(&\|:\|!\|+\|-\|\*\|/\|=\|<\|>\|@\|\*\*\|!=\|\~=\)" +syn match pl1Operator "\(\^\|\^=\|<=\|>=\|:=\|=>\|\.\.\|||\|<<\|>>\|\"\)" + +" Attributes +syn keyword pl1Attribute BACKWARDS BUFFERED BUF CONNECTED CONN CONSTANT EVENT +syn keyword pl1Attribute EXCLUSIVE EXCL FORMAT GENERIC IRREDUCIBLE IRRED LOCAL +syn keyword pl1Attribute REDUCIBLE RED TASK TRANSIENT UNBUFFERED UNBUF ALIGNED ANY +syn keyword pl1Attribute AREA AUTOMATIC AUTO BASED BUILTIN CONDITION COND CONTROLLED +syn keyword pl1Attribute CTL DEFINED DEF DIRECT ENVIRONMENT ENV EXTERNAL EXT FILE +syn keyword pl1Attribute GLOBALDEF GLOBALREF INITIAL INIT INPUT INTERNAL INT KEYED +syn keyword pl1Attribute LABEL LIKE LIST MEMBER NONVARYING NONVAR OPTIONAL OPTIONS +syn keyword pl1Attribute OUTPUT PARAMETER PARM PICTURE PIC POSITION POS PRECISION +syn keyword pl1Attribute PREC PRINT READONLY RECORD REFER RETURNS SEQUENTIAL SEQL +syn keyword pl1Attribute STATIC STREAM STRUCTURE TRUNCATE UNALIGNED UNAL UNION UPDATE +syn keyword pl1Attribute VARIABLE VARYING VAR COMPLEX CPLX REAL BINARY BIN BIT +syn keyword pl1Attribute CHARACTER CHAR DECIMAL DEC DESCRIPTOR DESC DIMENSION DIM +syn keyword pl1Attribute FIXED FLOAT OFFSET POINTER PTR REFERENCE VALUE VAL + +" Functions +syn keyword pl1Function AFTER ALL ANY BEFORE COMPLETION CPLN CONJG COUNT +syn keyword pl1Function CURRENTSTORAGE CSTG DATAFIELD DECAT DOT ERF ERFC IMAG +syn keyword pl1Function ONCOUNT ONFIELD ONLOC POLY PRIORITY REPEAT SAMEKEY STATUS +syn keyword pl1Function STORAGE STG ABS ACOS ACTUALCOUNT ADD ADDR ADDREL ALLOCATION +syn keyword pl1Function ALLOCN ASIN ATAN ATAND ATANH BOOL BYTE BYTESIZE CEIL COLLATE +syn keyword pl1Function COPY COS COSD COSH DATE DATETIME DECODE DISPLAY DIVIDE EMPTY +syn keyword pl1Function ENCODE ERROR EVERY EXP EXTEND FLOOR FLUSH FREE HBOUND HIGH +syn keyword pl1Function INDEX INFORM INT LBOUND LENGTH LINE LINENO LOG LOG10 LOG2 +syn keyword pl1Function LOW LTRIM MAX MAXLENGTH MIN MOD MULTIPLY NEXT_VOLUME NULL +syn keyword pl1Function ONARGSLIST ONCHAR ONCODE ONFILE ONKEY ONSOURCE PAGENO POSINT +syn keyword pl1Function PRESENT PROD RANK RELEASE RESIGNAL REVERSE REWIND ROUND +syn keyword pl1Function RTRIM SEARCH SIGN SIN SIND SINH SIZE SOME SPACEBLOCK SQRT +syn keyword pl1Function STRING SUBSTR SUBTRACT SUM TAN TAND TANH TIME TRANSLATE TRIM +syn keyword pl1Function TRUNC UNSPEC VALID VARIANT VERIFY WARN + +" Other keywords +syn keyword pl1Other ATTENTION ATTN C CONVERSION CONV DATA NAME NOCONVERSION +syn keyword pl1Other NOCONV NOFIXEDOVERFLOW NOFOFL NOOVERFLOW NOSIZE +syn keyword pl1Other NOSTRINGRANGE NOSTRG NOSTRINGSIZE NOSTRZ NOSUBSCRIPTRANGE +syn keyword pl1Other NOSUBRG NOZERODIVIDE NOZDIV OVERFLOW OFL PENDING RECORD +syn keyword pl1Other REENTRANT SIZE STRINGRANGE STRG STRINGSIZE STRZ +syn keyword pl1Other SUBSCRIPTRANGE SUBRG TRANSMIT A ANYCONDITION APPEND B B1 B2 +syn keyword pl1Other B3 B4 BACKUP_DATE BATCH BLOCK_BOUNDARY_FORMAT BLOCK_IO +syn keyword pl1Other BLOCK_SIZE BUCKET_SIZE BY CANCEL_CONTROL_O +syn keyword pl1Other CARRIAGE_RETURN_FORMAT COLUMN COL CONTIGUOUS +syn keyword pl1Other CONTIGUOUS_BEST_TRY CONVERSION CONV CREATION_DATE +syn keyword pl1Other CURRENT_POSITION DEFAULT_FILE_NAME DEFERRED_WRITE E EDIT +syn keyword pl1Other ENDFILE ENDPAGE EXPIRATION_DATE EXTENSION_SIZE F FAST_DELETE +syn keyword pl1Other FILE_ID FILE_ID_TO FILE_SIZE FINISH FIXEDOVERFLOW FOFL +syn keyword pl1Other FIXED_CONTROL_FROM FIXED_CONTROL_SIZE FIXED_CONTROL_SIZE_TO +syn keyword pl1Other FIXED_CONTROL_TO FIXED_LENGTH_RECORDS FROM GROUP_PROTECTION +syn keyword pl1Other IDENT IGNORE_LINE_MARKS IN INDEXED INDEX_NUMBER INITIAL_FILL +syn keyword pl1Other INTO KEY KEYFROM KEYTO LINESIZE LOCK_ON_READ LOCK_ON_WRITE +syn keyword pl1Other MAIN MANUAL_UNLOCKING MATCH_GREATER MATCH_GREATER_EQUAL +syn keyword pl1Other MATCH_NEXT MATCH_NEXT_EQUAL MAXIMUM_RECORD_NUMBER +syn keyword pl1Other MAXIMUM_RECORD_SIZE MULTIBLOCK_COUNT MULTIBUFFER_COUNT +syn keyword pl1Other NOLOCK NONEXISTENT_RECORD NONRECURSIVE NO_ECHO NO_FILTER +syn keyword pl1Other NO_SHARE OVERFLOW OFL OWNER_GROUP OWNER_ID OWNER_MEMBER +syn keyword pl1Other OWNER_PROTECTION P PAGE PAGESIZE PRINTER_FORMAT PROMPT +syn keyword pl1Other PURGE_TYPE_AHEAD R READ_AHEAD READ_CHECK READ_REGARDLESS +syn keyword pl1Other RECORD_ID RECORD_ID_ACCESS RECORD_ID_TO RECURSIVE REPEAT +syn keyword pl1Other RETRIEVAL_POINTERS REVISION_DATE REWIND_ON_CLOSE +syn keyword pl1Other REWIND_ON_OPEN SCALARVARYING SET SHARED_READ SHARED_WRITE +syn keyword pl1Other SKIP SPOOL STORAGE STRINGRANGE STRG SUBSCRIPTRANGE SUBRG +syn keyword pl1Other SUPERSEDE SYSIN SYSPRINT SYSTEM_PROTECTION TAB TEMPORARY +syn keyword pl1Other TIMEOUT_PERIOD TITLE TO UNDEFINEDFILE UNDF UNDERFLOW UFL +syn keyword pl1Other UNTIL USER_OPEN VAXCONDITION WAIT_FOR_RECORD WHILE +syn keyword pl1Other WORLD_PROTECTION WRITE_BEHIND WRITE_CHECK X ZERODIVIDE ZDIV + +" PreProcessor keywords +syn keyword pl1PreProc ACTIVATE DEACTIVATE DECLARE DCL DICTIONARY DO END ERROR +syn keyword pl1PreProc FATAL GOTO IF INCLUDE INFORM LIST NOLIST PAGE PROCEDURE PROC +syn keyword pl1PreProc REPLACE RETURN SBTTL TITLE WARN THEN ELSE + +" Statements +syn keyword pl1Statement CALL SUB ENTRY BY NAME CASE CHECK COPY DEFAULT DFT DELAY +syn keyword pl1Statement DESCRIPTORS DISPLAY EXIT FETCH HALT IGNORE LIST LOCATE +syn keyword pl1Statement NOCHECK NOLOCK NONE ORDER RANGE RELEASE REORDER REPLY SNAP +syn keyword pl1Statement SYSTEM TAB UNLOCK WAIT ALLOCATE ALLOC BEGIN CALL CLOSE +syn keyword pl1Statement DECLARE DCL DELETE DO ELSE END FORMAT GET GOTO GO TO IF +syn keyword pl1Statement LEAVE NORESCAN ON OPEN OTHERWISE OTHER PROCEDURE PROC PUT +syn keyword pl1Statement READ RESCAN RETURN REVERT REWRITE SELECT SIGNAL SNAP +syn keyword pl1Statement STATEMENT STOP SYSTEM THEN WHEN WRITE + +" PL1's own keywords +" syn match pl1Keyword "\" +" syn match pl1Keyword "\.COUNT\>"hs=s+1 +" syn match pl1Keyword "\.EXISTS\>"hs=s+1 +" syn match pl1Keyword "\.FIRST\>"hs=s+1 +" syn match pl1Keyword "\.LAST\>"hs=s+1 +" syn match pl1Keyword "\.DELETE\>"hs=s+1 +" syn match pl1Keyword "\.PREV\>"hs=s+1 +" syn match pl1Keyword "\.NEXT\>"hs=s+1 + +if exists("pl1_highlight_triggers") + syn keyword pl1Trigger INSERTING UPDATING DELETING +endif + +" Conditionals. +syn keyword pl1Conditional ELSIF ELSE IF +syn match pl1Conditional "\" + +" Loops. +syn keyword pl1Repeat FOR LOOP WHILE FORALL +syn match pl1Repeat "\" + +" Various types of comments. +" 20010723az: Added the ability to treat strings within comments just like +" C does. +if exists("c_comment_strings") + syntax match pl1CommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region pl1CommentString contained start=+L\="+ skip=+\\\\\|\\"+ end=+"+ end=+\*/+me=s-1 contains=pl1CommentSkip + syntax region pl1Comment2String contained start=+L\="+ skip=+\\\\\|\\"+ end=+"+ end="$" + syntax region pl1CommentL start="--" skip="\\$" end="$" keepend contains=@pl1CommentGroup,pl1Comment2String,pl1CharLiteral,pl1BooleanLiteral,pl1NumbersCom,pl1SpaceError + syntax region pl1Comment start="/\*" end="\*/" contains=@pl1CommentGroup,pl1Comment2String,pl1CharLiteral,pl1BooleanLiteral,pl1NumbersCom,pl1SpaceError +else + syntax region pl1CommentL start="--" skip="\\$" end="$" keepend contains=@pl1CommentGroup,pl1SpaceError + syntax region pl1Comment start="/\*" end="\*/" contains=@pl1CommentGroup,pl1SpaceError +endif + +" 20010723az: These are the old comment commands ... commented out. +" syn match pl1Comment "--.*$" contains=pl1Todo +" syn region pl1Comment start="/\*" end="\*/" contains=pl1Todo +syn sync ccomment pl1Comment +syn sync ccomment pl1CommentL + +" To catch unterminated string literals. +syn match pl1StringError "'.*$" + +" Various types of literals. +" 20010723az: Added stuff for comment matching. +syn match pl1Numbers transparent "\<[+-]\=\d\|[+-]\=\.\d" contains=pl1IntLiteral,pl1FloatLiteral +syn match pl1NumbersCom contained transparent "\<[+-]\=\d\|[+-]\=\.\d" contains=pl1IntLiteral,pl1FloatLiteral +syn match pl1IntLiteral contained "[+-]\=\d\+" +syn match pl1FloatLiteral contained "[+-]\=\d\+\.\d*" +syn match pl1FloatLiteral contained "[+-]\=\d*\.\d*" +"syn match pl1FloatLiteral "[+-]\=\([0-9]*\.[0-9]\+\|[0-9]\+\.[0-9]\+\)\(e[+-]\=[0-9]\+\)\=" +syn match pl1CharLiteral "'[^']'" +syn match pl1StringLiteral "'\([^']\|''\)*'" +syn keyword pl1BooleanLiteral TRUE FALSE NULL + +" The built-in types. +syn keyword pl1Storage ANYDATA ANYTYPE BFILE BINARY_INTEGER BLOB BOOLEAN +syn keyword pl1Storage BYTE CHAR CHARACTER CLOB CURSOR DATE DAY DEC DECIMAL +syn keyword pl1Storage DOUBLE DSINTERVAL_UNCONSTRAINED FLOAT HOUR +syn keyword pl1Storage INT INTEGER INTERVAL LOB LONG MINUTE +syn keyword pl1Storage MLSLABEL MONTH NATURAL NATURALN NCHAR NCHAR_CS NCLOB +syn keyword pl1Storage NUMBER NUMERIC NVARCHAR PLS_INT PLS_INTEGER +syn keyword pl1Storage POSITIVE POSITIVEN PRECISION RAW REAL RECORD +syn keyword pl1Storage SECOND SIGNTYPE SMALLINT STRING SYS_REFCURSOR TABLE TIME +syn keyword pl1Storage TIMESTAMP TIMESTAMP_UNCONSTRAINED +syn keyword pl1Storage TIMESTAMP_TZ_UNCONSTRAINED +syn keyword pl1Storage TIMESTAMP_LTZ_UNCONSTRAINED UROWID VARCHAR +syn keyword pl1Storage VARCHAR2 YEAR YMINTERVAL_UNCONSTRAINED ZONE + +" A type-attribute is really a type. +" 20020916bp: Removed leading part of pattern to avoid highlighting the +" object +syn match pl1TypeAttribute "%\(TYPE\|ROWTYPE\)\>" + +" All other attributes. +syn match pl1Attribute "%\(BULK_EXCEPTIONS\|BULK_ROWCOUNT\|ISOPEN\|FOUND\|NOTFOUND\|ROWCOUNT\)\>" + +" Catch errors caused by wrong parentheses and brackets +" 20010723az: significantly more powerful than the values -- commented out +" below the replaced values. This adds the C functionality to PL/SQL. +syn cluster pl1ParenGroup contains=pl1ParenError,@pl1CommentGroup,pl1CommentSkip,pl1IntLiteral,pl1FloatLiteral,pl1NumbersCom +if exists("c_no_bracket_error") + syn region pl1Paren transparent start='(' end=')' contains=ALLBUT,@pl1ParenGroup + syn match pl1ParenError ")" + syn match pl1ErrInParen contained "[{}]" +else + syn region pl1Paren transparent start='(' end=')' contains=ALLBUT,@pl1ParenGroup,pl1ErrInBracket + syn match pl1ParenError "[\])]" + syn match pl1ErrInParen contained "[{}]" + syn region pl1Bracket transparent start='\[' end=']' contains=ALLBUT,@pl1ParenGroup,pl1ErrInParen + syn match pl1ErrInBracket contained "[);{}]" +endif +" syn region pl1Paren transparent start='(' end=')' contains=ALLBUT,pl1ParenError +" syn match pl1ParenError ")" + +" Syntax Synchronizing +syn sync minlines=10 maxlines=100 + +" Define the default highlighting. +" Only when and item doesn't have highlighting yet. + +hi def link pl1Attribute Macro +hi def link pl1BlockError Error +hi def link pl1BooleanLiteral Boolean +hi def link pl1CharLiteral Character +hi def link pl1Comment Comment +hi def link pl1CommentL Comment +hi def link pl1Conditional Conditional +hi def link pl1Error Error +hi def link pl1ErrInBracket Error +hi def link pl1ErrInBlock Error +hi def link pl1ErrInParen Error +hi def link pl1Exception Function +hi def link pl1FloatLiteral Float +hi def link pl1Function Function +hi def link pl1Garbage Error +hi def link pl1HostIdentifier Label +hi def link pl1Identifier Normal +hi def link pl1IntLiteral Number +hi def link pl1Operator Operator +hi def link pl1Paren Normal +hi def link pl1ParenError Error +hi def link pl1SpaceError Error +hi def link pl1Pseudo PreProc +hi def link pl1PreProc PreProc +hi def link pl1PreProcSym PreProc +hi def link pl1Keyword Keyword +hi def link pl1Other Keyword +hi def link pl1Repeat Repeat +hi def link pl1Statement Keyword +hi def link pl1Storage StorageClass +hi def link pl1StringError Error +hi def link pl1StringLiteral String +hi def link pl1CommentString String +hi def link pl1Comment2String String +hi def link pl1Symbol Normal +hi def link pl1Trigger Function +hi def link pl1TypeAttribute StorageClass +hi def link pl1Todo Todo + + +let b:current_syntax = "pl1" + +endif diff --git a/syntax/plm.vim b/syntax/plm.vim new file mode 100644 index 0000000..e8c3390 --- /dev/null +++ b/syntax/plm.vim @@ -0,0 +1,138 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PL/M +" Maintainer: Philippe Coulonges +" Last change: 2003 May 11 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" PL/M is a case insensitive language +syn case ignore + +syn keyword plmTodo contained TODO FIXME XXX + +" String +syn region plmString start=+'+ end=+'+ + +syn match plmOperator "[@=\+\-\*\/\<\>]" + +syn match plmIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>" + +syn match plmDelimiter "[();,]" + +syn region plmPreProc start="^\s*\$\s*" skip="\\$" end="$" + +" FIXME : No Number support for floats, as I'm working on an embedded +" project that doesn't use any. +syn match plmNumber "-\=\<\d\+\>" +syn match plmNumber "\<[0-9a-fA-F]*[hH]*\>" + +" If you don't like tabs +"syn match plmShowTab "\t" +"syn match plmShowTabc "\t" + +"when wanted, highlight trailing white space +if exists("c_space_errors") + syn match plmSpaceError "\s*$" + syn match plmSpaceError " \+\t"me=e-1 +endif + +" + " Use the same control variable as C language for I believe + " users will want the same behavior +if exists("c_comment_strings") + " FIXME : don't work fine with c_comment_strings set, + " which I don't care as I don't use + + " A comment can contain plmString, plmCharacter and plmNumber. + " But a "*/" inside a plmString in a plmComment DOES end the comment! So we + " need to use a special type of plmString: plmCommentString, which also ends on + " "*/", and sees a "*" at the start of the line as comment again. + syntax match plmCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region plmCommentString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end=+\*/+me=s-1 contains=plmSpecial,plmCommentSkip + syntax region plmComment2String contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end="$" contains=plmSpecial + syntax region plmComment start="/\*" end="\*/" contains=plmTodo,plmCommentString,plmCharacter,plmNumber,plmFloat,plmSpaceError + syntax match plmComment "//.*" contains=plmTodo,plmComment2String,plmCharacter,plmNumber,plmSpaceError +else + syn region plmComment start="/\*" end="\*/" contains=plmTodo,plmSpaceError + syn match plmComment "//.*" contains=plmTodo,plmSpaceError +endif + +syntax match plmCommentError "\*/" + +syn keyword plmReserved ADDRESS AND AT BASED BY BYTE CALL CASE +syn keyword plmReserved DATA DECLARE DISABLE DO DWORD +syn keyword plmReserved ELSE ENABLE END EOF EXTERNAL +syn keyword plmReserved GO GOTO HALT IF INITIAL INTEGER INTERRUPT +syn keyword plmReserved LABEL LITERALLY MINUS MOD NOT OR +syn keyword plmReserved PLUS POINTER PROCEDURE PUBLIC +syn keyword plmReserved REAL REENTRANT RETURN SELECTOR STRUCTURE +syn keyword plmReserved THEN TO WHILE WORD XOR +syn keyword plm386Reserved CHARINT HWORD LONGINT OFFSET QWORD SHORTINT + +syn keyword plmBuiltIn ABS ADJUSTRPL BLOCKINPUT BLOCKINWORD BLOCKOUTPUT +syn keyword plmBuiltIn BLOCKOUTWORD BUILPTR CARRY CAUSEINTERRUPT CMPB +syn keyword plmBuiltIn CMPW DEC DOUBLE FINDB FINDRB FINDRW FINDW FIX +syn keyword plmBuiltIn FLAGS FLOAT GETREALERROR HIGH IABS INITREALMATHUNIT +syn keyword plmBuiltIn INPUT INT INWORD LAST LOCKSET LENGTH LOW MOVB MOVE +syn keyword plmBuiltIn MOVRB MOVRW MOVW NIL OUTPUT OUTWORD RESTOREREALSTATUS +syn keyword plmBuiltIn ROL ROR SAL SAVEREALSTATUS SCL SCR SELECTOROF SETB +syn keyword plmBuiltIn SETREALMODE SETW SHL SHR SIGN SIGNED SIZE SKIPB +syn keyword plmBuiltIn SKIPRB SKIPRW SKIPW STACKBASE STACKPTR TIME SIZE +syn keyword plmBuiltIn UNSIGN XLAT ZERO +syn keyword plm386BuiltIn INTERRUPT SETINTERRUPT +syn keyword plm286BuiltIn CLEARTASKSWITCHEDFLAG GETACCESSRIGHTS +syn keyword plm286BuiltIn GETSEGMENTLIMIT LOCALTABLE MACHINESTATUS +syn keyword plm286BuiltIn OFFSETOF PARITY RESTOREGLOBALTABLE +syn keyword plm286BuiltIn RESTOREINTERRUPTTABLE SAVEGLOBALTABLE +syn keyword plm286BuiltIn SAVEINTERRUPTTABLE SEGMENTREADABLE +syn keyword plm286BuiltIn SEGMENTWRITABLE TASKREGISTER WAITFORINTERRUPT +syn keyword plm386BuiltIn CONTROLREGISTER DEBUGREGISTER FINDHW +syn keyword plm386BuiltIn FINDRHW INHWORD MOVBIT MOVRBIT MOVHW MOVRHW +syn keyword plm386BuiltIn OUTHWORD SCANBIT SCANRBIT SETHW SHLD SHRD +syn keyword plm386BuiltIn SKIPHW SKIPRHW TESTREGISTER +syn keyword plm386w16BuiltIn BLOCKINDWORD BLOCKOUTDWORD CMPD FINDD +syn keyword plm386w16BuiltIn FINDRD INDWORD MOVD MOVRD OUTDWORD +syn keyword plm386w16BuiltIn SETD SKIPD SKIPRD + +syn sync lines=50 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +" hi def link plmLabel Label +" hi def link plmConditional Conditional +" hi def link plmRepeat Repeat +hi def link plmTodo Todo +hi def link plmNumber Number +hi def link plmOperator Operator +hi def link plmDelimiter Operator +"hi def link plmShowTab Error +"hi def link plmShowTabc Error +hi def link plmIdentifier Identifier +hi def link plmBuiltIn Statement +hi def link plm286BuiltIn Statement +hi def link plm386BuiltIn Statement +hi def link plm386w16BuiltIn Statement +hi def link plmReserved Statement +hi def link plm386Reserved Statement +hi def link plmPreProc PreProc +hi def link plmCommentError plmError +hi def link plmCommentString plmString +hi def link plmComment2String plmString +hi def link plmCommentSkip plmComment +hi def link plmString String +hi def link plmComment Comment + + +let b:current_syntax = "plm" + +" vim: ts=8 sw=2 + + +endif diff --git a/syntax/plp.vim b/syntax/plp.vim new file mode 100644 index 0000000..12a83d3 --- /dev/null +++ b/syntax/plp.vim @@ -0,0 +1,41 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PLP (Perl in HTML) +" Maintainer: Juerd +" Last Change: 2003 Apr 25 +" Cloned From: aspperl.vim + +" Add to filetype.vim the following line (without quote sign): +" au BufNewFile,BufRead *.plp setf plp + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'perlscript' +endif + +runtime! syntax/html.vim +unlet b:current_syntax +syn include @PLPperl syntax/perl.vim + +syn cluster htmlPreproc add=PLPperlblock + +syn keyword perlControl PLP_END +syn keyword perlStatementInclude include Include +syn keyword perlStatementFiles ReadFile WriteFile Counter +syn keyword perlStatementScalar Entity AutoURL DecodeURI EncodeURI + +syn cluster PLPperlcode contains=perlStatement.*,perlFunction,perlOperator,perlVarPlain,perlVarNotInMatches,perlShellCommand,perlFloat,perlNumber,perlStringUnexpanded,perlString,perlQQ,perlControl,perlConditional,perlRepeat,perlComment,perlPOD,perlHereDoc,perlPackageDecl,perlElseIfError,perlFiledescRead,perlMatch + +syn region PLPperlblock keepend matchgroup=Delimiter start=+<:=\=+ end=+:>+ transparent contains=@PLPperlcode + +syn region PLPinclude keepend matchgroup=Delimiter start=+<(+ end=+)>+ + +let b:current_syntax = "plp" + + +endif diff --git a/syntax/plsql.vim b/syntax/plsql.vim new file mode 100644 index 0000000..a213d0b --- /dev/null +++ b/syntax/plsql.vim @@ -0,0 +1,268 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Oracle Procedureal SQL (PL/SQL) +" Maintainer: Jeff Lanzarotta (jefflanzarotta at yahoo dot com) +" Original Maintainer: C. Laurence Gonsalves (clgonsal@kami.com) +" URL: http://lanzarotta.tripod.com/vim/syntax/plsql.vim.zip +" Last Change: September 18, 2002 +" History: Geoff Evans & Bill Pribyl (bill at plnet dot org) +" Added 9i keywords. +" Austin Ziegler (austin at halostatue dot ca) +" Added 8i+ features. +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Todo. +syn keyword plsqlTodo TODO FIXME XXX DEBUG NOTE +syn cluster plsqlCommentGroup contains=plsqlTodo + +syn case ignore + +syn match plsqlGarbage "[^ \t()]" +syn match plsqlIdentifier "[a-z][a-z0-9$_#]*" +syn match plsqlHostIdentifier ":[a-z][a-z0-9$_#]*" + +" When wanted, highlight the trailing whitespace. +if exists("c_space_errors") + if !exists("c_no_trail_space_error") + syn match plsqlSpaceError "\s\+$" + endif + + if !exists("c_no_tab_space_error") + syn match plsqlSpaceError " \+\t"me=e-1 + endif +endif + +" Symbols. +syn match plsqlSymbol "\(;\|,\|\.\)" + +" Operators. +syn match plsqlOperator "\(+\|-\|\*\|/\|=\|<\|>\|@\|\*\*\|!=\|\~=\)" +syn match plsqlOperator "\(^=\|<=\|>=\|:=\|=>\|\.\.\|||\|<<\|>>\|\"\)" + +" Some of Oracle's SQL keywords. +syn keyword plsqlSQLKeyword ABORT ACCESS ACCESSED ADD AFTER ALL ALTER AND ANY +syn keyword plsqlSQLKeyword AS ASC ATTRIBUTE AUDIT AUTHORIZATION AVG BASE_TABLE +syn keyword plsqlSQLKeyword BEFORE BETWEEN BY CASCADE CAST CHECK CLUSTER +syn keyword plsqlSQLKeyword CLUSTERS COLAUTH COLUMN COMMENT COMPRESS CONNECT +syn keyword plsqlSQLKeyword CONSTRAINT CRASH CREATE CURRENT DATA DATABASE +syn keyword plsqlSQLKeyword DATA_BASE DBA DEFAULT DELAY DELETE DESC DISTINCT +syn keyword plsqlSQLKeyword DROP DUAL ELSE EXCLUSIVE EXISTS EXTENDS EXTRACT +syn keyword plsqlSQLKeyword FILE FORCE FOREIGN FROM GRANT GROUP HAVING HEAP +syn keyword plsqlSQLKeyword IDENTIFIED IDENTIFIER IMMEDIATE IN INCLUDING +syn keyword plsqlSQLKeyword INCREMENT INDEX INDEXES INITIAL INSERT INSTEAD +syn keyword plsqlSQLKeyword INTERSECT INTO INVALIDATE IS ISOLATION KEY LIBRARY +syn keyword plsqlSQLKeyword LIKE LOCK MAXEXTENTS MINUS MODE MODIFY MULTISET +syn keyword plsqlSQLKeyword NESTED NOAUDIT NOCOMPRESS NOT NOWAIT OF OFF OFFLINE +syn keyword plsqlSQLKeyword ON ONLINE OPERATOR OPTION OR ORDER ORGANIZATION +syn keyword plsqlSQLKeyword PCTFREE PRIMARY PRIOR PRIVATE PRIVILEGES PUBLIC +syn keyword plsqlSQLKeyword QUOTA RELEASE RENAME REPLACE RESOURCE REVOKE ROLLBACK +syn keyword plsqlSQLKeyword ROW ROWLABEL ROWS SCHEMA SELECT SEPARATE SESSION SET +syn keyword plsqlSQLKeyword SHARE SIZE SPACE START STORE SUCCESSFUL SYNONYM +syn keyword plsqlSQLKeyword SYSDATE TABLE TABLES TABLESPACE TEMPORARY TO TREAT +syn keyword plsqlSQLKeyword TRIGGER TRUNCATE UID UNION UNIQUE UNLIMITED UPDATE +syn keyword plsqlSQLKeyword USE USER VALIDATE VALUES VIEW WHENEVER WHERE WITH + +" PL/SQL's own keywords. +syn keyword plsqlKeyword AGENT AND ANY ARRAY ASSIGN AS AT AUTHID BEGIN BODY BY +syn keyword plsqlKeyword BULK C CASE CHAR_BASE CHARSETFORM CHARSETID CLOSE +syn keyword plsqlKeyword COLLECT CONSTANT CONSTRUCTOR CONTEXT CURRVAL DECLARE +syn keyword plsqlKeyword DVOID EXCEPTION EXCEPTION_INIT EXECUTE EXIT FETCH +syn keyword plsqlKeyword FINAL FUNCTION GOTO HASH IMMEDIATE IN INDICATOR +syn keyword plsqlKeyword INSTANTIABLE IS JAVA LANGUAGE LIBRARY MAP MAXLEN +syn keyword plsqlKeyword MEMBER NAME NEW NOCOPY NUMBER_BASE OBJECT OCICOLL +syn keyword plsqlKeyword OCIDATE OCIDATETIME OCILOBLOCATOR OCINUMBER OCIRAW +syn keyword plsqlKeyword OCISTRING OF OPAQUE OPEN OR ORDER OTHERS OUT +syn keyword plsqlKeyword OVERRIDING PACKAGE PARALLEL_ENABLE PARAMETERS +syn keyword plsqlKeyword PARTITION PIPELINED PRAGMA PROCEDURE RAISE RANGE REF +syn keyword plsqlKeyword RESULT RETURN REVERSE ROWTYPE SB1 SELF SHORT SIZE_T +syn keyword plsqlKeyword SQL SQLCODE SQLERRM STATIC STRUCT SUBTYPE TDO THEN +syn keyword plsqlKeyword TABLE TIMEZONE_ABBR TIMEZONE_HOUR TIMEZONE_MINUTE +syn keyword plsqlKeyword TIMEZONE_REGION TYPE UNDER UNSIGNED USING VARIANCE +syn keyword plsqlKeyword VARRAY VARYING WHEN WRITE +syn match plsqlKeyword "\" +syn match plsqlKeyword "\.COUNT\>"hs=s+1 +syn match plsqlKeyword "\.EXISTS\>"hs=s+1 +syn match plsqlKeyword "\.FIRST\>"hs=s+1 +syn match plsqlKeyword "\.LAST\>"hs=s+1 +syn match plsqlKeyword "\.DELETE\>"hs=s+1 +syn match plsqlKeyword "\.PREV\>"hs=s+1 +syn match plsqlKeyword "\.NEXT\>"hs=s+1 + +" PL/SQL functions. +syn keyword plsqlFunction ABS ACOS ADD_MONTHS ASCII ASCIISTR ASIN ATAN ATAN2 +syn keyword plsqlFunction BFILENAME BITAND CEIL CHARTOROWID CHR COALESCE +syn keyword plsqlFunction COMMIT COMMIT_CM COMPOSE CONCAT CONVERT COS COSH +syn keyword plsqlFunction COUNT CUBE CURRENT_DATE CURRENT_TIME CURRENT_TIMESTAMP +syn keyword plsqlFunction DBTIMEZONE DECODE DECOMPOSE DEREF DUMP EMPTY_BLOB +syn keyword plsqlFunction EMPTY_CLOB EXISTS EXP FLOOR FROM_TZ GETBND GLB +syn keyword plsqlFunction GREATEST GREATEST_LB GROUPING HEXTORAW INITCAP +syn keyword plsqlFunction INSTR INSTR2 INSTR4 INSTRB INSTRC ISNCHAR LAST_DAY +syn keyword plsqlFunction LEAST LEAST_UB LENGTH LENGTH2 LENGTH4 LENGTHB LENGTHC +syn keyword plsqlFunction LN LOCALTIME LOCALTIMESTAMP LOG LOWER LPAD +syn keyword plsqlFunction LTRIM LUB MAKE_REF MAX MIN MOD MONTHS_BETWEEN +syn keyword plsqlFunction NCHARTOROWID NCHR NEW_TIME NEXT_DAY NHEXTORAW +syn keyword plsqlFunction NLS_CHARSET_DECL_LEN NLS_CHARSET_ID NLS_CHARSET_NAME +syn keyword plsqlFunction NLS_INITCAP NLS_LOWER NLSSORT NLS_UPPER NULLFN NULLIF +syn keyword plsqlFunction NUMTODSINTERVAL NUMTOYMINTERVAL NVL POWER +syn keyword plsqlFunction RAISE_APPLICATION_ERROR RAWTOHEX RAWTONHEX REF +syn keyword plsqlFunction REFTOHEX REPLACE ROLLBACK_NR ROLLBACK_SV ROLLUP ROUND +syn keyword plsqlFunction ROWIDTOCHAR ROWIDTONCHAR ROWLABEL RPAD RTRIM +syn keyword plsqlFunction SAVEPOINT SESSIONTIMEZONE SETBND SET_TRANSACTION_USE +syn keyword plsqlFunction SIGN SIN SINH SOUNDEX SQLCODE SQLERRM SQRT STDDEV +syn keyword plsqlFunction SUBSTR SUBSTR2 SUBSTR4 SUBSTRB SUBSTRC SUM +syn keyword plsqlFunction SYS_AT_TIME_ZONE SYS_CONTEXT SYSDATE SYS_EXTRACT_UTC +syn keyword plsqlFunction SYS_GUID SYS_LITERALTODATE SYS_LITERALTODSINTERVAL +syn keyword plsqlFunction SYS_LITERALTOTIME SYS_LITERALTOTIMESTAMP +syn keyword plsqlFunction SYS_LITERALTOTZTIME SYS_LITERALTOTZTIMESTAMP +syn keyword plsqlFunction SYS_LITERALTOYMINTERVAL SYS_OVER__DD SYS_OVER__DI +syn keyword plsqlFunction SYS_OVER__ID SYS_OVER_IID SYS_OVER_IIT +syn keyword plsqlFunction SYS_OVER__IT SYS_OVER__TI SYS_OVER__TT +syn keyword plsqlFunction SYSTIMESTAMP TAN TANH TO_ANYLOB TO_BLOB TO_CHAR +syn keyword plsqlFunction TO_CLOB TO_DATE TO_DSINTERVAL TO_LABEL TO_MULTI_BYTE +syn keyword plsqlFunction TO_NCHAR TO_NCLOB TO_NUMBER TO_RAW TO_SINGLE_BYTE +syn keyword plsqlFunction TO_TIME TO_TIMESTAMP TO_TIMESTAMP_TZ TO_TIME_TZ +syn keyword plsqlFunction TO_YMINTERVAL TRANSLATE TREAT TRIM TRUNC TZ_OFFSET UID +syn keyword plsqlFunction UNISTR UPPER UROWID USER USERENV VALUE VARIANCE +syn keyword plsqlFunction VSIZE WORK XOR +syn match plsqlFunction "\" + +" PL/SQL Exceptions +syn keyword plsqlException ACCESS_INTO_NULL CASE_NOT_FOUND COLLECTION_IS_NULL +syn keyword plsqlException CURSOR_ALREADY_OPEN DUP_VAL_ON_INDEX INVALID_CURSOR +syn keyword plsqlException INVALID_NUMBER LOGIN_DENIED NO_DATA_FOUND +syn keyword plsqlException NOT_LOGGED_ON PROGRAM_ERROR ROWTYPE_MISMATCH +syn keyword plsqlException SELF_IS_NULL STORAGE_ERROR SUBSCRIPT_BEYOND_COUNT +syn keyword plsqlException SUBSCRIPT_OUTSIDE_LIMIT SYS_INVALID_ROWID +syn keyword plsqlException TIMEOUT_ON_RESOURCE TOO_MANY_ROWS VALUE_ERROR +syn keyword plsqlException ZERO_DIVIDE + +" Oracle Pseudo Colums. +syn keyword plsqlPseudo CURRVAL LEVEL NEXTVAL ROWID ROWNUM + +if exists("plsql_highlight_triggers") + syn keyword plsqlTrigger INSERTING UPDATING DELETING +endif + +" Conditionals. +syn keyword plsqlConditional ELSIF ELSE IF +syn match plsqlConditional "\" + +" Loops. +syn keyword plsqlRepeat FOR LOOP WHILE FORALL +syn match plsqlRepeat "\" + +" Various types of comments. +if exists("c_comment_strings") + syntax match plsqlCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region plsqlCommentString contained start=+L\="+ skip=+\\\\\|\\"+ end=+"+ end=+\*/+me=s-1 contains=plsqlCommentSkip + syntax region plsqlComment2String contained start=+L\="+ skip=+\\\\\|\\"+ end=+"+ end="$" + syntax region plsqlCommentL start="--" skip="\\$" end="$" keepend contains=@plsqlCommentGroup,plsqlComment2String,plsqlCharLiteral,plsqlBooleanLiteral,plsqlNumbersCom,plsqlSpaceError + syntax region plsqlComment start="/\*" end="\*/" contains=@plsqlCommentGroup,plsqlComment2String,plsqlCharLiteral,plsqlBooleanLiteral,plsqlNumbersCom,plsqlSpaceError +else + syntax region plsqlCommentL start="--" skip="\\$" end="$" keepend contains=@plsqlCommentGroup,plsqlSpaceError + syntax region plsqlComment start="/\*" end="\*/" contains=@plsqlCommentGroup,plsqlSpaceError +endif + +syn sync ccomment plsqlComment +syn sync ccomment plsqlCommentL + +" To catch unterminated string literals. +syn match plsqlStringError "'.*$" + +" Various types of literals. +syn match plsqlNumbers transparent "\<[+-]\=\d\|[+-]\=\.\d" contains=plsqlIntLiteral,plsqlFloatLiteral +syn match plsqlNumbersCom contained transparent "\<[+-]\=\d\|[+-]\=\.\d" contains=plsqlIntLiteral,plsqlFloatLiteral +syn match plsqlIntLiteral contained "[+-]\=\d\+" +syn match plsqlFloatLiteral contained "[+-]\=\d\+\.\d*" +syn match plsqlFloatLiteral contained "[+-]\=\d*\.\d*" +syn match plsqlCharLiteral "'[^']'" +syn match plsqlStringLiteral "'\([^']\|''\)*'" +syn keyword plsqlBooleanLiteral TRUE FALSE NULL + +" The built-in types. +syn keyword plsqlStorage ANYDATA ANYTYPE BFILE BINARY_INTEGER BLOB BOOLEAN +syn keyword plsqlStorage BYTE CHAR CHARACTER CLOB CURSOR DATE DAY DEC DECIMAL +syn keyword plsqlStorage DOUBLE DSINTERVAL_UNCONSTRAINED FLOAT HOUR +syn keyword plsqlStorage INT INTEGER INTERVAL LOB LONG MINUTE +syn keyword plsqlStorage MLSLABEL MONTH NATURAL NATURALN NCHAR NCHAR_CS NCLOB +syn keyword plsqlStorage NUMBER NUMERIC NVARCHAR PLS_INT PLS_INTEGER +syn keyword plsqlStorage POSITIVE POSITIVEN PRECISION RAW REAL RECORD +syn keyword plsqlStorage SECOND SIGNTYPE SMALLINT STRING SYS_REFCURSOR TABLE TIME +syn keyword plsqlStorage TIMESTAMP TIMESTAMP_UNCONSTRAINED +syn keyword plsqlStorage TIMESTAMP_TZ_UNCONSTRAINED +syn keyword plsqlStorage TIMESTAMP_LTZ_UNCONSTRAINED UROWID VARCHAR +syn keyword plsqlStorage VARCHAR2 YEAR YMINTERVAL_UNCONSTRAINED ZONE + +" A type-attribute is really a type. +syn match plsqlTypeAttribute "%\(TYPE\|ROWTYPE\)\>" + +" All other attributes. +syn match plsqlAttribute "%\(BULK_EXCEPTIONS\|BULK_ROWCOUNT\|ISOPEN\|FOUND\|NOTFOUND\|ROWCOUNT\)\>" + +" This'll catch mis-matched close-parens. +syn cluster plsqlParenGroup contains=plsqlParenError,@plsqlCommentGroup,plsqlCommentSkip,plsqlIntLiteral,plsqlFloatLiteral,plsqlNumbersCom +if exists("c_no_bracket_error") + syn region plsqlParen transparent start='(' end=')' contains=ALLBUT,@plsqlParenGroup + syn match plsqlParenError ")" + syn match plsqlErrInParen contained "[{}]" +else + syn region plsqlParen transparent start='(' end=')' contains=ALLBUT,@plsqlParenGroup,plsqlErrInBracket + syn match plsqlParenError "[\])]" + syn match plsqlErrInParen contained "[{}]" + syn region plsqlBracket transparent start='\[' end=']' contains=ALLBUT,@plsqlParenGroup,plsqlErrInParen + syn match plsqlErrInBracket contained "[);{}]" +endif + +" Syntax Synchronizing +syn sync minlines=10 maxlines=100 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet. + +hi def link plsqlAttribute Macro +hi def link plsqlBlockError Error +hi def link plsqlBooleanLiteral Boolean +hi def link plsqlCharLiteral Character +hi def link plsqlComment Comment +hi def link plsqlCommentL Comment +hi def link plsqlConditional Conditional +hi def link plsqlError Error +hi def link plsqlErrInBracket Error +hi def link plsqlErrInBlock Error +hi def link plsqlErrInParen Error +hi def link plsqlException Function +hi def link plsqlFloatLiteral Float +hi def link plsqlFunction Function +hi def link plsqlGarbage Error +hi def link plsqlHostIdentifier Label +hi def link plsqlIdentifier Normal +hi def link plsqlIntLiteral Number +hi def link plsqlOperator Operator +hi def link plsqlParen Normal +hi def link plsqlParenError Error +hi def link plsqlSpaceError Error +hi def link plsqlPseudo PreProc +hi def link plsqlKeyword Keyword +hi def link plsqlRepeat Repeat +hi def link plsqlStorage StorageClass +hi def link plsqlSQLKeyword Function +hi def link plsqlStringError Error +hi def link plsqlStringLiteral String +hi def link plsqlCommentString String +hi def link plsqlComment2String String +hi def link plsqlSymbol Normal +hi def link plsqlTrigger Function +hi def link plsqlTypeAttribute StorageClass +hi def link plsqlTodo Todo + + +let b:current_syntax = "plsql" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/po.vim b/syntax/po.vim new file mode 100644 index 0000000..2012273 --- /dev/null +++ b/syntax/po.vim @@ -0,0 +1,137 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: po (gettext) +" Maintainer: Dwayne Bailey +" Last Change: 2015 Jun 07 +" Contributors: Dwayne Bailey (Most advanced syntax highlighting) +" Leonardo Fontenelle (Spell checking) +" Nam SungHyun (Original maintainer) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +syn sync minlines=10 + +" Identifiers +syn match poStatementMsgCTxt "^msgctxt" +syn match poStatementMsgidplural "^msgid_plural" contained +syn match poPluralCaseN "[0-9]" contained +syn match poStatementMsgstr "^msgstr\(\[[0-9]\]\)" contains=poPluralCaseN + +" Simple HTML and XML highlighting +syn match poHtml "<\_[^<>]\+>" contains=poHtmlTranslatables,poLineBreak +syn match poHtmlNot +"<[^<]\+>"+ms=s+1,me=e-1 +syn region poHtmlTranslatables start=+\(abbr\|alt\|content\|summary\|standby\|title\)=\\"+ms=e-1 end=+\\"+ contained contains=@Spell +syn match poLineBreak +"\n"+ contained + +" Translation blocks +syn region poMsgCTxt matchgroup=poStatementMsgCTxt start=+^msgctxt "+rs=e-1 matchgroup=poStringCTxt end=+^msgid "+me=s-1 contains=poStringCTxt +syn region poMsgID matchgroup=poStatementMsgid start=+^msgid "+rs=e-1 matchgroup=poStringID end=+^msgstr\(\|\[[\]0\[]\]\) "+me=s-1 contains=poStringID,poStatementMsgidplural,poStatementMsgid +syn region poMsgSTR matchgroup=poStatementMsgstr start=+^msgstr\(\|\[[\]0\[]\]\) "+rs=e-1 matchgroup=poStringSTR end=+\n\n+me=s-1 contains=poStringSTR,poStatementMsgstr +syn region poStringCTxt start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn region poStringID start=+"+ skip=+\\\\\|\\"+ end=+"+ contained + \ contains=poSpecial,poFormat,poCommentKDE,poPluralKDE,poKDEdesktopFile,poHtml,poAcceleratorId,poHtmlNot,poVariable +syn region poStringSTR start=+"+ skip=+\\\\\|\\"+ end=+"+ contained + \ contains=@Spell,poSpecial,poFormat,poHeaderItem,poCommentKDEError,poHeaderUndefined,poPluralKDEError,poMsguniqError,poKDEdesktopFile,poHtml,poAcceleratorStr,poHtmlNot,poVariable + +" Header and Copyright +syn match poHeaderItem "\(Project-Id-Version\|Report-Msgid-Bugs-To\|POT-Creation-Date\|PO-Revision-Date\|Last-Translator\|Language-Team\|Language\|MIME-Version\|Content-Type\|Content-Transfer-Encoding\|Plural-Forms\|X-Generator\): " contained +syn match poHeaderUndefined "\(PACKAGE VERSION\|YEAR-MO-DA HO:MI+ZONE\|FULL NAME \|LANGUAGE \|CHARSET\|ENCODING\|INTEGER\|EXPRESSION\)" contained +syn match poCopyrightUnset "SOME DESCRIPTIVE TITLE\|FIRST AUTHOR , YEAR\|Copyright (C) YEAR Free Software Foundation, Inc\|YEAR THE PACKAGE\'S COPYRIGHT HOLDER\|PACKAGE" contained + +" Translation comment block including: translator comment, automatic coments, flags and locations +syn match poComment "^#.*$" +syn keyword poFlagFuzzy fuzzy contained +syn match poCommentTranslator "^# .*$" contains=poCopyrightUnset +syn match poCommentAutomatic "^#\..*$" +syn match poCommentSources "^#:.*$" +syn match poCommentFlags "^#,.*$" contains=poFlagFuzzy +syn match poDiffOld '\(^#| "[^{]*+}\|{+[^}]*+}\|{+[^}]*\|"$\)' contained +syn match poDiffNew '\(^#| "[^{]*-}\|{-[^}]*-}\|{-[^}]*\|"$\)' contained +syn match poCommentDiff "^#|.*$" contains=poDiffOld,poDiffNew + +" Translations (also includes header fields as they appear in a translation msgstr) +syn region poCommentKDE start=+"_: +ms=s+1 end="\\n" end="\"\n^msgstr"me=s-1 contained +syn region poCommentKDEError start=+"\(\|\s\+\)_:+ms=s+1 end="\\n" end=+"\n\n+me=s-1 contained +syn match poPluralKDE +"_n: +ms=s+1 contained +syn region poPluralKDEError start=+"\(\|\s\+\)_n:+ms=s+1 end="\"\n\n"me=s-1 contained +syn match poSpecial contained "\\\(x\x\+\|\o\{1,3}\|.\|$\)" +syn match poFormat "%\(\d\+\$\)\=[-+' #0*]*\(\d*\|\*\|\*\d\+\$\)\(\.\(\d*\|\*\|\*\d\+\$\)\)\=\([hlL]\|ll\)\=\([diuoxXfeEgGcCsSpn]\|\[\^\=.[^]]*\]\)" contained +syn match poFormat "%%" contained + +" msguniq and msgcat conflicts +syn region poMsguniqError matchgroup=poMsguniqErrorMarkers start="#-#-#-#-#" end='#\("\n"\|\)-\("\n"\|\)#\("\n"\|\)-\("\n"\|\)#\("\n"\|\)-\("\n"\|\)#\("\n"\|\)-\("\n"\|\)#\("\n"\|\)\\n' contained + +" Obsolete messages +syn match poObsolete "^#\~.*$" + +" KDE Name= handling +syn match poKDEdesktopFile "\"\(Name\|Comment\|GenericName\|Description\|Keywords\|About\)="ms=s+1,me=e-1 + +" Accelerator keys - this messes up if the preceding or following char is a multibyte unicode char +syn match poAcceleratorId contained "[^&_~][&_~]\(\a\|\d\)[^:]"ms=s+1,me=e-1 +syn match poAcceleratorStr contained "[^&_~][&_~]\(\a\|\d\)[^:]"ms=s+1,me=e-1 contains=@Spell + +" Variables simple +syn match poVariable contained "%\d" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link poCommentSources PreProc +hi def link poComment Comment +hi def link poCommentAutomatic Comment +hi def link poCommentTranslator Comment +hi def link poCommentFlags Special +hi def link poCommentDiff Comment +hi def link poCopyrightUnset Todo +hi def link poFlagFuzzy Todo +hi def link poDiffOld Todo +hi def link poDiffNew Special +hi def link poObsolete Comment + +hi def link poStatementMsgid Statement +hi def link poStatementMsgstr Statement +hi def link poStatementMsgidplural Statement +hi def link poStatementMsgCTxt Statement +hi def link poPluralCaseN Constant + +hi def link poStringCTxt Comment +hi def link poStringID String +hi def link poStringSTR String +hi def link poCommentKDE Comment +hi def link poCommentKDEError Error +hi def link poPluralKDE Comment +hi def link poPluralKDEError Error +hi def link poHeaderItem Identifier +hi def link poHeaderUndefined Todo +hi def link poKDEdesktopFile Identifier + +hi def link poHtml Identifier +hi def link poHtmlNot String +hi def link poHtmlTranslatables String +hi def link poLineBreak String + +hi def link poFormat poSpecial +hi def link poSpecial Special +hi def link poAcceleratorId Special +hi def link poAcceleratorStr Special +hi def link poVariable Special + +hi def link poMsguniqError Special +hi def link poMsguniqErrorMarkers Comment + + +let b:current_syntax = "po" + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim:set ts=8 sts=2 sw=2 noet: + +endif diff --git a/syntax/pod.vim b/syntax/pod.vim index c337de8..8d325d5 100644 --- a/syntax/pod.vim +++ b/syntax/pod.vim @@ -1,3 +1,182 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Perl POD format +" Maintainer: vim-perl +" Previously: Scott Bigham +" Homepage: http://github.com/vim-perl/vim-perl +" Bugs/requests: http://github.com/vim-perl/vim-perl/issues +" Last Change: 2017-09-12 + +" To add embedded POD documentation highlighting to your syntax file, add +" the commands: +" +" syn include @Pod :p:h/pod.vim +" syn region myPOD start="^=pod" start="^=head" end="^=cut" keepend contained contains=@Pod +" +" and add myPod to the contains= list of some existing region, probably a +" comment. The "keepend" flag is needed because "=cut" is matched as a +" pattern in its own right. + + +" Remove any old syntax stuff hanging around (this is suppressed +" automatically by ":syn include" if necessary). +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" POD commands +syn match podCommand "^=encoding" nextgroup=podCmdText contains=@NoSpell +syn match podCommand "^=head[1234]" nextgroup=podCmdText contains=@NoSpell +syn match podCommand "^=item" nextgroup=podCmdText contains=@NoSpell +syn match podCommand "^=over" nextgroup=podOverIndent skipwhite contains=@NoSpell +syn match podCommand "^=back" contains=@NoSpell +syn match podCommand "^=cut" contains=@NoSpell +syn match podCommand "^=pod" contains=@NoSpell +syn match podCommand "^=for" nextgroup=podForKeywd skipwhite contains=@NoSpell +syn match podCommand "^=begin" nextgroup=podForKeywd skipwhite contains=@NoSpell +syn match podCommand "^=end" nextgroup=podForKeywd skipwhite contains=@NoSpell + +" Text of a =head1, =head2 or =item command +syn match podCmdText ".*$" contained contains=podFormat,@NoSpell + +" Indent amount of =over command +syn match podOverIndent "\d\+" contained contains=@NoSpell + +" Formatter identifier keyword for =for, =begin and =end commands +syn match podForKeywd "\S\+" contained contains=@NoSpell + +" An indented line, to be displayed verbatim +syn match podVerbatimLine "^\s.*$" contains=@NoSpell + +" Inline textual items handled specially by POD +syn match podSpecial "\(\<\|&\)\I\i*\(::\I\i*\)*([^)]*)" contains=@NoSpell +syn match podSpecial "[$@%]\I\i*\(::\I\i*\)*\>" contains=@NoSpell + +" Special formatting sequences +syn region podFormat start="[IBSCLFX]<[^<]"me=e-1 end=">" oneline contains=podFormat,@NoSpell +syn region podFormat start="[IBSCLFX]<<\s" end="\s>>" oneline contains=podFormat,@NoSpell +syn match podFormat "Z<>" +syn match podFormat "E<\(\d\+\|\I\i*\)>" contains=podEscape,podEscape2,@NoSpell +syn match podEscape "\I\i*>"me=e-1 contained contains=@NoSpell +syn match podEscape2 "\d\+>"me=e-1 contained contains=@NoSpell + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link podCommand Statement +hi def link podCmdText String +hi def link podOverIndent Number +hi def link podForKeywd Identifier +hi def link podFormat Identifier +hi def link podVerbatimLine PreProc +hi def link podSpecial Identifier +hi def link podEscape String +hi def link podEscape2 Number + +if exists("perl_pod_spellcheck_headings") + " Spell-check headings + syn clear podCmdText + syn match podCmdText ".*$" contained contains=podFormat +endif + +if exists("perl_pod_formatting") + " By default, escapes like C<> are not checked for spelling. Remove B<> + " and I<> from the list of escapes. + syn clear podFormat + syn region podFormat start="[CLF]<[^<]"me=e-1 end=">" oneline contains=podFormat,@NoSpell + syn region podFormat start="[CLF]<<\s" end="\s>>" oneline contains=podFormat,@NoSpell + + " Don't spell-check inside E<>, but ensure that the E< itself isn't + " marked as a spelling mistake. + syn match podFormat "E<\(\d\+\|\I\i*\)>" contains=podEscape,podEscape2,@NoSpell + + " Z<> is a mock formatting code. Ensure Z<> on its own isn't marked as a + " spelling mistake. + syn match podFormat "Z<>" contains=podEscape,podEscape2,@NoSpell + + " These are required so that whatever is *within* B<...>, I<...>, etc. is + " spell-checked, but not the B, I, ... itself. + syn match podBoldOpen "B<" contains=@NoSpell + syn match podItalicOpen "I<" contains=@NoSpell + syn match podNoSpaceOpen "S<" contains=@NoSpell + syn match podIndexOpen "X<" contains=@NoSpell + + " Same as above but for the << >> syntax. + syn match podBoldAlternativeDelimOpen "B<< " contains=@NoSpell + syn match podItalicAlternativeDelimOpen "I<< " contains=@NoSpell + syn match podNoSpaceAlternativeDelimOpen "S<< " contains=@NoSpell + syn match podIndexAlternativeDelimOpen "X<< " contains=@NoSpell + + " Add support for spell checking text inside B<>, I<>, S<> and X<>. + syn region podBold start="B<[^<]"me=e end=">" oneline contains=podBoldItalic,podBoldOpen + syn region podBoldAlternativeDelim start="B<<\s" end="\s>>" oneline contains=podBoldAlternativeDelimOpen + + syn region podItalic start="I<[^<]"me=e end=">" oneline contains=podItalicBold,podItalicOpen + syn region podItalicAlternativeDelim start="I<<\s" end="\s>>" oneline contains=podItalicAlternativeDelimOpen + + " Nested bold/italic and vice-versa + syn region podBoldItalic contained start="I<[^<]"me=e end=">" oneline + syn region podItalicBold contained start="B<[^<]"me=e end=">" oneline + + syn region podNoSpace start="S<[^<]"ms=s-2 end=">"me=e oneline contains=podNoSpaceOpen + syn region podNoSpaceAlternativeDelim start="S<<\s"ms=s-2 end="\s>>"me=e oneline contains=podNoSpaceAlternativeDelimOpen + + syn region podIndex start="X<[^<]"ms=s-2 end=">"me=e oneline contains=podIndexOpen + syn region podIndexAlternativeDelim start="X<<\s"ms=s-2 end="\s>>"me=e oneline contains=podIndexAlternativeDelimOpen + + " Restore this (otherwise B<> is shown as bold inside verbatim) + syn match podVerbatimLine "^\s.*$" contains=@NoSpell + + " Ensure formatted text can be displayed in headings and items + syn clear podCmdText + + if exists("perl_pod_spellcheck_headings") + syn match podCmdText ".*$" contained contains=podFormat,podBold, + \podBoldAlternativeDelim,podItalic,podItalicAlternativeDelim, + \podBoldOpen,podItalicOpen,podBoldAlternativeDelimOpen, + \podItalicAlternativeDelimOpen,podNoSpaceOpen + else + syn match podCmdText ".*$" contained contains=podFormat,podBold, + \podBoldAlternativeDelim,podItalic,podItalicAlternativeDelim, + \@NoSpell + endif + + " Specify how to display these + hi def podBold term=bold cterm=bold gui=bold + + hi link podBoldAlternativeDelim podBold + hi link podBoldAlternativeDelimOpen podBold + hi link podBoldOpen podBold + + hi link podNoSpace Identifier + hi link podNoSpaceAlternativeDelim Identifier + + hi link podIndex Identifier + hi link podIndexAlternativeDelim Identifier + + hi def podItalic term=italic cterm=italic gui=italic + + hi link podItalicAlternativeDelim podItalic + hi link podItalicAlternativeDelimOpen podItalic + hi link podItalicOpen podItalic + + hi def podBoldItalic term=italic,bold cterm=italic,bold gui=italic,bold + hi def podItalicBold term=italic,bold cterm=italic,bold gui=italic,bold +endif + +let b:current_syntax = "pod" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Vim syntax file diff --git a/syntax/postscr.vim b/syntax/postscr.vim new file mode 100644 index 0000000..039a0a4 --- /dev/null +++ b/syntax/postscr.vim @@ -0,0 +1,784 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PostScript - all Levels, selectable +" Maintainer: Mike Williams +" Filenames: *.ps,*.eps +" Last Change: 31st October 2007 +" URL: http://www.eandem.co.uk/mrw/vim +" +" Options Flags: +" postscr_level - language level to use for highligting (1, 2, or 3) +" postscr_display - include display PS operators +" postscr_ghostscript - include GS extensions +" postscr_fonts - highlight standard font names (a lot for PS 3) +" postscr_encodings - highlight encoding names (there are a lot) +" postscr_andornot_binary - highlight and, or, and not as binary operators (not logical) +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" PostScript is case sensitive +syn case match + +" Keyword characters - all 7-bit ASCII bar PS delimiters and ws +setlocal iskeyword=33-127,^(,^),^<,^>,^[,^],^{,^},^/,^% + +" Yer trusty old TODO highlghter! +syn keyword postscrTodo contained TODO + +" Comment +syn match postscrComment "%.*$" contains=postscrTodo,@Spell +" DSC comment start line (NB: defines DSC level, not PS level!) +syn match postscrDSCComment "^%!PS-Adobe-\d\+\.\d\+\s*.*$" +" DSC comment line (no check on possible comments - another language!) +syn match postscrDSCComment "^%%\u\+.*$" contains=@postscrString,@postscrNumber,@Spell +" DSC continuation line (no check that previous line is DSC comment) +syn match postscrDSCComment "^%%+ *.*$" contains=@postscrString,@postscrNumber,@Spell + +" Names +syn match postscrName "\k\+" + +" Identifiers +syn match postscrIdentifierError "/\{1,2}[[:space:]\[\]{}]"me=e-1 +syn match postscrIdentifier "/\{1,2}\k\+" contains=postscrConstant,postscrBoolean,postscrCustConstant + +" Numbers +syn case ignore +" In file hex data - usually complete lines +syn match postscrHex "^[[:xdigit:]][[:xdigit:][:space:]]*$" +"syn match postscrHex "\<\x\{2,}\>" +" Integers +syn match postscrInteger "\<[+-]\=\d\+\>" +" Radix +syn match postscrRadix "\d\+#\x\+\>" +" Reals - upper and lower case e is allowed +syn match postscrFloat "[+-]\=\d\+\.\>" +syn match postscrFloat "[+-]\=\d\+\.\d*\(e[+-]\=\d\+\)\=\>" +syn match postscrFloat "[+-]\=\.\d\+\(e[+-]\=\d\+\)\=\>" +syn match postscrFloat "[+-]\=\d\+e[+-]\=\d\+\>" +syn cluster postscrNumber contains=postscrInteger,postscrRadix,postscrFloat +syn case match + +" Escaped characters +syn match postscrSpecialChar contained "\\[nrtbf\\()]" +syn match postscrSpecialCharError contained "\\[^nrtbf\\()]"he=e-1 +" Escaped octal characters +syn match postscrSpecialChar contained "\\\o\{1,3}" + +" Strings +" ASCII strings +syn region postscrASCIIString start=+(+ end=+)+ skip=+([^)]*)+ contains=postscrSpecialChar,postscrSpecialCharError,@Spell +syn match postscrASCIIStringError ")" +" Hex strings +syn match postscrHexCharError contained "[^<>[:xdigit:][:space:]]" +syn region postscrHexString start=+<\($\|[^<]\)+ end=+>+ contains=postscrHexCharError +syn match postscrHexString "<>" +" ASCII85 strings +syn match postscrASCII85CharError contained "[^<>\~!-uz[:space:]]" +syn region postscrASCII85String start=+<\~+ end=+\~>+ contains=postscrASCII85CharError +syn cluster postscrString contains=postscrASCIIString,postscrHexString,postscrASCII85String + + +" Set default highlighting to level 2 - most common at the moment +if !exists("postscr_level") + let postscr_level = 2 +endif + + +" PS level 1 operators - common to all levels (well ...) + +" Stack operators +syn keyword postscrOperator pop exch dup copy index roll clear count mark cleartomark counttomark + +" Math operators +syn keyword postscrMathOperator add div idiv mod mul sub abs neg ceiling floor round truncate sqrt atan cos +syn keyword postscrMathOperator sin exp ln log rand srand rrand + +" Array operators +syn match postscrOperator "[\[\]{}]" +syn keyword postscrOperator array length get put getinterval putinterval astore aload copy +syn keyword postscrRepeat forall + +" Dictionary operators +syn keyword postscrOperator dict maxlength begin end def load store known where currentdict +syn keyword postscrOperator countdictstack dictstack cleardictstack internaldict +syn keyword postscrConstant $error systemdict userdict statusdict errordict + +" String operators +syn keyword postscrOperator string anchorsearch search token + +" Logic operators +syn keyword postscrLogicalOperator eq ne ge gt le lt and not or +if exists("postscr_andornot_binaryop") + syn keyword postscrBinaryOperator and or not +else + syn keyword postscrLogicalOperator and not or +endif +syn keyword postscrBinaryOperator xor bitshift +syn keyword postscrBoolean true false + +" PS Type names +syn keyword postscrConstant arraytype booleantype conditiontype dicttype filetype fonttype gstatetype +syn keyword postscrConstant integertype locktype marktype nametype nulltype operatortype +syn keyword postscrConstant packedarraytype realtype savetype stringtype + +" Control operators +syn keyword postscrConditional if ifelse +syn keyword postscrRepeat for repeat loop +syn keyword postscrOperator exec exit stop stopped countexecstack execstack quit +syn keyword postscrProcedure start + +" Object operators +syn keyword postscrOperator type cvlit cvx xcheck executeonly noaccess readonly rcheck wcheck cvi cvn cvr +syn keyword postscrOperator cvrs cvs + +" File operators +syn keyword postscrOperator file closefile read write readhexstring writehexstring readstring writestring +syn keyword postscrOperator bytesavailable flush flushfile resetfile status run currentfile print +syn keyword postscrOperator stack pstack readline deletefile setfileposition fileposition renamefile +syn keyword postscrRepeat filenameforall +syn keyword postscrProcedure = == + +" VM operators +syn keyword postscrOperator save restore + +" Misc operators +syn keyword postscrOperator bind null usertime executive echo realtime +syn keyword postscrConstant product revision serialnumber version +syn keyword postscrProcedure prompt + +" GState operators +syn keyword postscrOperator gsave grestore grestoreall initgraphics setlinewidth setlinecap currentgray +syn keyword postscrOperator currentlinejoin setmiterlimit currentmiterlimit setdash currentdash setgray +syn keyword postscrOperator sethsbcolor currenthsbcolor setrgbcolor currentrgbcolor currentlinewidth +syn keyword postscrOperator currentlinecap setlinejoin setcmykcolor currentcmykcolor + +" Device gstate operators +syn keyword postscrOperator setscreen currentscreen settransfer currenttransfer setflat currentflat +syn keyword postscrOperator currentblackgeneration setblackgeneration setundercolorremoval +syn keyword postscrOperator setcolorscreen currentcolorscreen setcolortransfer currentcolortransfer +syn keyword postscrOperator currentundercolorremoval + +" Matrix operators +syn keyword postscrOperator matrix initmatrix identmatrix defaultmatrix currentmatrix setmatrix translate +syn keyword postscrOperator concat concatmatrix transform dtransform itransform idtransform invertmatrix +syn keyword postscrOperator scale rotate + +" Path operators +syn keyword postscrOperator newpath currentpoint moveto rmoveto lineto rlineto arc arcn arcto curveto +syn keyword postscrOperator closepath flattenpath reversepath strokepath charpath clippath pathbbox +syn keyword postscrOperator initclip clip eoclip rcurveto +syn keyword postscrRepeat pathforall + +" Painting operators +syn keyword postscrOperator erasepage fill eofill stroke image imagemask colorimage + +" Device operators +syn keyword postscrOperator showpage copypage nulldevice + +" Character operators +syn keyword postscrProcedure findfont +syn keyword postscrConstant FontDirectory ISOLatin1Encoding StandardEncoding +syn keyword postscrOperator definefont scalefont makefont setfont currentfont show ashow +syn keyword postscrOperator stringwidth kshow setcachedevice +syn keyword postscrOperator setcharwidth widthshow awidthshow findencoding cshow rootfont setcachedevice2 + +" Interpreter operators +syn keyword postscrOperator vmstatus cachestatus setcachelimit + +" PS constants +syn keyword postscrConstant contained Gray Red Green Blue All None DeviceGray DeviceRGB + +" PS Filters +syn keyword postscrConstant contained ASCIIHexDecode ASCIIHexEncode ASCII85Decode ASCII85Encode LZWDecode +syn keyword postscrConstant contained RunLengthDecode RunLengthEncode SubFileDecode NullEncode +syn keyword postscrConstant contained GIFDecode PNGDecode LZWEncode + +" PS JPEG filter dictionary entries +syn keyword postscrConstant contained DCTEncode DCTDecode Colors HSamples VSamples QuantTables QFactor +syn keyword postscrConstant contained HuffTables ColorTransform + +" PS CCITT filter dictionary entries +syn keyword postscrConstant contained CCITTFaxEncode CCITTFaxDecode Uncompressed K EndOfLine +syn keyword postscrConstant contained Columns Rows EndOfBlock Blacks1 DamagedRowsBeforeError +syn keyword postscrConstant contained EncodedByteAlign + +" PS Form dictionary entries +syn keyword postscrConstant contained FormType XUID BBox Matrix PaintProc Implementation + +" PS Errors +syn keyword postscrProcedure handleerror +syn keyword postscrConstant contained configurationerror dictfull dictstackunderflow dictstackoverflow +syn keyword postscrConstant contained execstackoverflow interrupt invalidaccess +syn keyword postscrConstant contained invalidcontext invalidexit invalidfileaccess invalidfont +syn keyword postscrConstant contained invalidid invalidrestore ioerror limitcheck nocurrentpoint +syn keyword postscrConstant contained rangecheck stackoverflow stackunderflow syntaxerror timeout +syn keyword postscrConstant contained typecheck undefined undefinedfilename undefinedresource +syn keyword postscrConstant contained undefinedresult unmatchedmark unregistered VMerror + +if exists("postscr_fonts") +" Font names + syn keyword postscrConstant contained Symbol Times-Roman Times-Italic Times-Bold Times-BoldItalic + syn keyword postscrConstant contained Helvetica Helvetica-Oblique Helvetica-Bold Helvetica-BoldOblique + syn keyword postscrConstant contained Courier Courier-Oblique Courier-Bold Courier-BoldOblique +endif + + +if exists("postscr_display") +" Display PS only operators + syn keyword postscrOperator currentcontext fork join detach lock monitor condition wait notify yield + syn keyword postscrOperator viewclip eoviewclip rectviewclip initviewclip viewclippath deviceinfo + syn keyword postscrOperator sethalftonephase currenthalftonephase wtranslation defineusername +endif + +" PS Character encoding names +if exists("postscr_encodings") +" Common encoding names + syn keyword postscrConstant contained .notdef + +" Standard and ISO encoding names + syn keyword postscrConstant contained space exclam quotedbl numbersign dollar percent ampersand quoteright + syn keyword postscrConstant contained parenleft parenright asterisk plus comma hyphen period slash zero + syn keyword postscrConstant contained one two three four five six seven eight nine colon semicolon less + syn keyword postscrConstant contained equal greater question at + syn keyword postscrConstant contained bracketleft backslash bracketright asciicircum underscore quoteleft + syn keyword postscrConstant contained braceleft bar braceright asciitilde + syn keyword postscrConstant contained exclamdown cent sterling fraction yen florin section currency + syn keyword postscrConstant contained quotesingle quotedblleft guillemotleft guilsinglleft guilsinglright + syn keyword postscrConstant contained fi fl endash dagger daggerdbl periodcentered paragraph bullet + syn keyword postscrConstant contained quotesinglbase quotedblbase quotedblright guillemotright ellipsis + syn keyword postscrConstant contained perthousand questiondown grave acute circumflex tilde macron breve + syn keyword postscrConstant contained dotaccent dieresis ring cedilla hungarumlaut ogonek caron emdash + syn keyword postscrConstant contained AE ordfeminine Lslash Oslash OE ordmasculine ae dotlessi lslash + syn keyword postscrConstant contained oslash oe germandbls +" The following are valid names, but are used as short procedure names in generated PS! +" 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 +" 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 + +" Symbol encoding names + syn keyword postscrConstant contained universal existential suchthat asteriskmath minus + syn keyword postscrConstant contained congruent Alpha Beta Chi Delta Epsilon Phi Gamma Eta Iota theta1 + syn keyword postscrConstant contained Kappa Lambda Mu Nu Omicron Pi Theta Rho Sigma Tau Upsilon sigma1 + syn keyword postscrConstant contained Omega Xi Psi Zeta therefore perpendicular + syn keyword postscrConstant contained radicalex alpha beta chi delta epsilon phi gamma eta iota phi1 + syn keyword postscrConstant contained kappa lambda mu nu omicron pi theta rho sigma tau upsilon omega1 + syn keyword postscrConstant contained Upsilon1 minute lessequal infinity club diamond heart spade + syn keyword postscrConstant contained arrowboth arrowleft arrowup arrowright arrowdown degree plusminus + syn keyword postscrConstant contained second greaterequal multiply proportional partialdiff divide + syn keyword postscrConstant contained notequal equivalence approxequal arrowvertex arrowhorizex + syn keyword postscrConstant contained aleph Ifraktur Rfraktur weierstrass circlemultiply circleplus + syn keyword postscrConstant contained emptyset intersection union propersuperset reflexsuperset notsubset + syn keyword postscrConstant contained propersubset reflexsubset element notelement angle gradient + syn keyword postscrConstant contained registerserif copyrightserif trademarkserif radical dotmath + syn keyword postscrConstant contained logicalnot logicaland logicalor arrowdblboth arrowdblleft arrowdblup + syn keyword postscrConstant contained arrowdblright arrowdbldown omega xi psi zeta similar carriagereturn + syn keyword postscrConstant contained lozenge angleleft registersans copyrightsans trademarksans summation + syn keyword postscrConstant contained parenlefttp parenleftex parenleftbt bracketlefttp bracketleftex + syn keyword postscrConstant contained bracketleftbt bracelefttp braceleftmid braceleftbt braceex euro + syn keyword postscrConstant contained angleright integral integraltp integralex integralbt parenrighttp + syn keyword postscrConstant contained parenrightex parenrightbt bracketrighttp bracketrightex + syn keyword postscrConstant contained bracketrightbt bracerighttp bracerightmid bracerightbt + +" ISO Latin1 encoding names + syn keyword postscrConstant contained brokenbar copyright registered twosuperior threesuperior + syn keyword postscrConstant contained onesuperior onequarter onehalf threequarters + syn keyword postscrConstant contained Agrave Aacute Acircumflex Atilde Adieresis Aring Ccedilla Egrave + syn keyword postscrConstant contained Eacute Ecircumflex Edieresis Igrave Iacute Icircumflex Idieresis + syn keyword postscrConstant contained Eth Ntilde Ograve Oacute Ocircumflex Otilde Odieresis Ugrave Uacute + syn keyword postscrConstant contained Ucircumflex Udieresis Yacute Thorn + syn keyword postscrConstant contained agrave aacute acircumflex atilde adieresis aring ccedilla egrave + syn keyword postscrConstant contained eacute ecircumflex edieresis igrave iacute icircumflex idieresis + syn keyword postscrConstant contained eth ntilde ograve oacute ocircumflex otilde odieresis ugrave uacute + syn keyword postscrConstant contained ucircumflex udieresis yacute thorn ydieresis + syn keyword postscrConstant contained zcaron exclamsmall Hungarumlautsmall dollaroldstyle dollarsuperior + syn keyword postscrConstant contained ampersandsmall Acutesmall parenleftsuperior parenrightsuperior + syn keyword postscrConstant contained twodotenleader onedotenleader zerooldstyle oneoldstyle twooldstyle + syn keyword postscrConstant contained threeoldstyle fouroldstyle fiveoldstyle sixoldstyle sevenoldstyle + syn keyword postscrConstant contained eightoldstyle nineoldstyle commasuperior + syn keyword postscrConstant contained threequartersemdash periodsuperior questionsmall asuperior bsuperior + syn keyword postscrConstant contained centsuperior dsuperior esuperior isuperior lsuperior msuperior + syn keyword postscrConstant contained nsuperior osuperior rsuperior ssuperior tsuperior ff ffi ffl + syn keyword postscrConstant contained parenleftinferior parenrightinferior Circumflexsmall hyphensuperior + syn keyword postscrConstant contained Gravesmall Asmall Bsmall Csmall Dsmall Esmall Fsmall Gsmall Hsmall + syn keyword postscrConstant contained Ismall Jsmall Ksmall Lsmall Msmall Nsmall Osmall Psmall Qsmall + syn keyword postscrConstant contained Rsmall Ssmall Tsmall Usmall Vsmall Wsmall Xsmall Ysmall Zsmall + syn keyword postscrConstant contained colonmonetary onefitted rupiah Tildesmall exclamdownsmall + syn keyword postscrConstant contained centoldstyle Lslashsmall Scaronsmall Zcaronsmall Dieresissmall + syn keyword postscrConstant contained Brevesmall Caronsmall Dotaccentsmall Macronsmall figuredash + syn keyword postscrConstant contained hypheninferior Ogoneksmall Ringsmall Cedillasmall questiondownsmall + syn keyword postscrConstant contained oneeighth threeeighths fiveeighths seveneighths onethird twothirds + syn keyword postscrConstant contained zerosuperior foursuperior fivesuperior sixsuperior sevensuperior + syn keyword postscrConstant contained eightsuperior ninesuperior zeroinferior oneinferior twoinferior + syn keyword postscrConstant contained threeinferior fourinferior fiveinferior sixinferior seveninferior + syn keyword postscrConstant contained eightinferior nineinferior centinferior dollarinferior periodinferior + syn keyword postscrConstant contained commainferior Agravesmall Aacutesmall Acircumflexsmall + syn keyword postscrConstant contained Atildesmall Adieresissmall Aringsmall AEsmall Ccedillasmall + syn keyword postscrConstant contained Egravesmall Eacutesmall Ecircumflexsmall Edieresissmall Igravesmall + syn keyword postscrConstant contained Iacutesmall Icircumflexsmall Idieresissmall Ethsmall Ntildesmall + syn keyword postscrConstant contained Ogravesmall Oacutesmall Ocircumflexsmall Otildesmall Odieresissmall + syn keyword postscrConstant contained OEsmall Oslashsmall Ugravesmall Uacutesmall Ucircumflexsmall + syn keyword postscrConstant contained Udieresissmall Yacutesmall Thornsmall Ydieresissmall Black Bold Book + syn keyword postscrConstant contained Light Medium Regular Roman Semibold + +" Sundry standard and expert encoding names + syn keyword postscrConstant contained trademark Scaron Ydieresis Zcaron scaron softhyphen overscore + syn keyword postscrConstant contained graybox Sacute Tcaron Zacute sacute tcaron zacute Aogonek Scedilla + syn keyword postscrConstant contained Zdotaccent aogonek scedilla Lcaron lcaron zdotaccent Racute Abreve + syn keyword postscrConstant contained Lacute Cacute Ccaron Eogonek Ecaron Dcaron Dcroat Nacute Ncaron + syn keyword postscrConstant contained Ohungarumlaut Rcaron Uring Uhungarumlaut Tcommaaccent racute abreve + syn keyword postscrConstant contained lacute cacute ccaron eogonek ecaron dcaron dcroat nacute ncaron + syn keyword postscrConstant contained ohungarumlaut rcaron uring uhungarumlaut tcommaaccent Gbreve + syn keyword postscrConstant contained Idotaccent gbreve blank apple +endif + + +" By default level 3 includes all level 2 operators +if postscr_level == 2 || postscr_level == 3 +" Dictionary operators + syn match postscrL2Operator "\(<<\|>>\)" + syn keyword postscrL2Operator undef + syn keyword postscrConstant globaldict shareddict + +" Device operators + syn keyword postscrL2Operator setpagedevice currentpagedevice + +" Path operators + syn keyword postscrL2Operator rectclip setbbox uappend ucache upath ustrokepath arct + +" Painting operators + syn keyword postscrL2Operator rectfill rectstroke ufill ueofill ustroke + +" Array operators + syn keyword postscrL2Operator currentpacking setpacking packedarray + +" Misc operators + syn keyword postscrL2Operator languagelevel + +" Insideness operators + syn keyword postscrL2Operator infill ineofill instroke inufill inueofill inustroke + +" GState operators + syn keyword postscrL2Operator gstate setgstate currentgstate setcolor + syn keyword postscrL2Operator setcolorspace currentcolorspace setstrokeadjust currentstrokeadjust + syn keyword postscrL2Operator currentcolor + +" Device gstate operators + syn keyword postscrL2Operator sethalftone currenthalftone setoverprint currentoverprint + syn keyword postscrL2Operator setcolorrendering currentcolorrendering + +" Character operators + syn keyword postscrL2Constant GlobalFontDirectory SharedFontDirectory + syn keyword postscrL2Operator glyphshow selectfont + syn keyword postscrL2Operator addglyph undefinefont xshow xyshow yshow + +" Pattern operators + syn keyword postscrL2Operator makepattern setpattern execform + +" Resource operators + syn keyword postscrL2Operator defineresource undefineresource findresource resourcestatus + syn keyword postscrL2Repeat resourceforall + +" File operators + syn keyword postscrL2Operator filter printobject writeobject setobjectformat currentobjectformat + +" VM operators + syn keyword postscrL2Operator currentshared setshared defineuserobject execuserobject undefineuserobject + syn keyword postscrL2Operator gcheck scheck startjob currentglobal setglobal + syn keyword postscrConstant UserObjects + +" Interpreter operators + syn keyword postscrL2Operator setucacheparams setvmthreshold ucachestatus setsystemparams + syn keyword postscrL2Operator setuserparams currentuserparams setcacheparams currentcacheparams + syn keyword postscrL2Operator currentdevparams setdevparams vmreclaim currentsystemparams + +" PS2 constants + syn keyword postscrConstant contained DeviceCMYK Pattern Indexed Separation Cyan Magenta Yellow Black + syn keyword postscrConstant contained CIEBasedA CIEBasedABC CIEBasedDEF CIEBasedDEFG + +" PS2 $error dictionary entries + syn keyword postscrConstant contained newerror errorname command errorinfo ostack estack dstack + syn keyword postscrConstant contained recordstacks binary + +" PS2 Category dictionary + syn keyword postscrConstant contained DefineResource UndefineResource FindResource ResourceStatus + syn keyword postscrConstant contained ResourceForAll Category InstanceType ResourceFileName + +" PS2 Category names + syn keyword postscrConstant contained Font Encoding Form Pattern ProcSet ColorSpace Halftone + syn keyword postscrConstant contained ColorRendering Filter ColorSpaceFamily Emulator IODevice + syn keyword postscrConstant contained ColorRenderingType FMapType FontType FormType HalftoneType + syn keyword postscrConstant contained ImageType PatternType Category Generic + +" PS2 pagedevice dictionary entries + syn keyword postscrConstant contained PageSize MediaColor MediaWeight MediaType InputAttributes ManualFeed + syn keyword postscrConstant contained OutputType OutputAttributes NumCopies Collate Duplex Tumble + syn keyword postscrConstant contained Separations HWResolution Margins NegativePrint MirrorPrint + syn keyword postscrConstant contained CutMedia AdvanceMedia AdvanceDistance ImagingBBox + syn keyword postscrConstant contained Policies Install BeginPage EndPage PolicyNotFound PolicyReport + syn keyword postscrConstant contained ManualSize OutputFaceUp Jog + syn keyword postscrConstant contained Bind BindDetails Booklet BookletDetails CollateDetails + syn keyword postscrConstant contained DeviceRenderingInfo ExitJamRecovery Fold FoldDetails Laminate + syn keyword postscrConstant contained ManualFeedTimeout Orientation OutputPage + syn keyword postscrConstant contained PostRenderingEnhance PostRenderingEnhanceDetails + syn keyword postscrConstant contained PreRenderingEnhance PreRenderingEnhanceDetails + syn keyword postscrConstant contained Signature SlipSheet Staple StapleDetails Trim + syn keyword postscrConstant contained ProofSet REValue PrintQuality ValuesPerColorComponent AntiAlias + +" PS2 PDL resource entries + syn keyword postscrConstant contained Selector LanguageFamily LanguageVersion + +" PS2 halftone dictionary entries + syn keyword postscrConstant contained HalftoneType HalftoneName + syn keyword postscrConstant contained AccurateScreens ActualAngle Xsquare Ysquare AccurateFrequency + syn keyword postscrConstant contained Frequency SpotFunction Angle Width Height Thresholds + syn keyword postscrConstant contained RedFrequency RedSpotFunction RedAngle RedWidth RedHeight + syn keyword postscrConstant contained GreenFrequency GreenSpotFunction GreenAngle GreenWidth GreenHeight + syn keyword postscrConstant contained BlueFrequency BlueSpotFunction BlueAngle BlueWidth BlueHeight + syn keyword postscrConstant contained GrayFrequency GrayAngle GraySpotFunction GrayWidth GrayHeight + syn keyword postscrConstant contained GrayThresholds BlueThresholds GreenThresholds RedThresholds + syn keyword postscrConstant contained TransferFunction + +" PS2 CSR dictionaries + syn keyword postscrConstant contained RangeA DecodeA MatrixA RangeABC DecodeABC MatrixABC BlackPoint + syn keyword postscrConstant contained RangeLMN DecodeLMN MatrixLMN WhitePoint RangeDEF DecodeDEF RangeHIJ + syn keyword postscrConstant contained RangeDEFG DecodeDEFG RangeHIJK Table + +" PS2 CRD dictionaries + syn keyword postscrConstant contained ColorRenderingType EncodeLMB EncodeABC RangePQR MatrixPQR + syn keyword postscrConstant contained AbsoluteColorimetric RelativeColorimetric Saturation Perceptual + syn keyword postscrConstant contained TransformPQR RenderTable + +" PS2 Pattern dictionary + syn keyword postscrConstant contained PatternType PaintType TilingType XStep YStep + +" PS2 Image dictionary + syn keyword postscrConstant contained ImageType ImageMatrix MultipleDataSources DataSource + syn keyword postscrConstant contained BitsPerComponent Decode Interpolate + +" PS2 Font dictionaries + syn keyword postscrConstant contained FontType FontMatrix FontName FontInfo LanguageLevel WMode Encoding + syn keyword postscrConstant contained UniqueID StrokeWidth Metrics Metrics2 CDevProc CharStrings Private + syn keyword postscrConstant contained FullName Notice version ItalicAngle isFixedPitch UnderlinePosition + syn keyword postscrConstant contained FMapType Encoding FDepVector PrefEnc EscChar ShiftOut ShiftIn + syn keyword postscrConstant contained WeightVector Blend $Blend CIDFontType sfnts CIDSystemInfo CodeMap + syn keyword postscrConstant contained CMap CIDFontName CIDSystemInfo UIDBase CIDDevProc CIDCount + syn keyword postscrConstant contained CIDMapOffset FDArray FDBytes GDBytes GlyphData GlyphDictionary + syn keyword postscrConstant contained SDBytes SubrMapOffset SubrCount BuildGlyph CIDMap FID MIDVector + syn keyword postscrConstant contained Ordering Registry Supplement CMapName CMapVersion UIDOffset + syn keyword postscrConstant contained SubsVector UnderlineThickness FamilyName FontBBox CurMID + syn keyword postscrConstant contained Weight + +" PS2 User paramters + syn keyword postscrConstant contained MaxFontItem MinFontCompress MaxUPathItem MaxFormItem MaxPatternItem + syn keyword postscrConstant contained MaxScreenItem MaxOpStack MaxDictStack MaxExecStack MaxLocalVM + syn keyword postscrConstant contained VMReclaim VMThreshold + +" PS2 System paramters + syn keyword postscrConstant contained SystemParamsPassword StartJobPassword BuildTime ByteOrder RealFormat + syn keyword postscrConstant contained MaxFontCache CurFontCache MaxOutlineCache CurOutlineCache + syn keyword postscrConstant contained MaxUPathCache CurUPathCache MaxFormCache CurFormCache + syn keyword postscrConstant contained MaxPatternCache CurPatternCache MaxScreenStorage CurScreenStorage + syn keyword postscrConstant contained MaxDisplayList CurDisplayList + +" PS2 LZW Filters + syn keyword postscrConstant contained Predictor + +" Paper Size operators + syn keyword postscrL2Operator letter lettersmall legal ledger 11x17 a4 a3 a4small b5 note + +" Paper Tray operators + syn keyword postscrL2Operator lettertray legaltray ledgertray a3tray a4tray b5tray 11x17tray + +" SCC compatibility operators + syn keyword postscrL2Operator sccbatch sccinteractive setsccbatch setsccinteractive + +" Page duplexing operators + syn keyword postscrL2Operator duplexmode firstside newsheet setduplexmode settumble tumble + +" Device compatability operators + syn keyword postscrL2Operator devdismount devformat devmount devstatus + syn keyword postscrL2Repeat devforall + +" Imagesetter compatability operators + syn keyword postscrL2Operator accuratescreens checkscreen pagemargin pageparams setaccuratescreens setpage + syn keyword postscrL2Operator setpagemargin setpageparams + +" Misc compatability operators + syn keyword postscrL2Operator appletalktype buildtime byteorder checkpassword defaulttimeouts diskonline + syn keyword postscrL2Operator diskstatus manualfeed manualfeedtimeout margins mirrorprint pagecount + syn keyword postscrL2Operator pagestackorder printername processcolors sethardwareiomode setjobtimeout + syn keyword postscrL2Operator setpagestockorder setprintername setresolution doprinterrors dostartpage + syn keyword postscrL2Operator hardwareiomode initializedisk jobname jobtimeout ramsize realformat resolution + syn keyword postscrL2Operator setdefaulttimeouts setdoprinterrors setdostartpage setdosysstart + syn keyword postscrL2Operator setuserdiskpercent softwareiomode userdiskpercent waittimeout + syn keyword postscrL2Operator setsoftwareiomode dosysstart emulate setmargins setmirrorprint + +endif " PS2 highlighting + +if postscr_level == 3 +" Shading operators + syn keyword postscrL3Operator setsmoothness currentsmoothness shfill + +" Clip operators + syn keyword postscrL3Operator clipsave cliprestore + +" Pagedevive operators + syn keyword postscrL3Operator setpage setpageparams + +" Device gstate operators + syn keyword postscrL3Operator findcolorrendering + +" Font operators + syn keyword postscrL3Operator composefont + +" PS LL3 Output device resource entries + syn keyword postscrConstant contained DeviceN TrappingDetailsType + +" PS LL3 pagdevice dictionary entries + syn keyword postscrConstant contained DeferredMediaSelection ImageShift InsertSheet LeadingEdge MaxSeparations + syn keyword postscrConstant contained MediaClass MediaPosition OutputDevice PageDeviceName PageOffset ProcessColorModel + syn keyword postscrConstant contained RollFedMedia SeparationColorNames SeparationOrder Trapping TrappingDetails + syn keyword postscrConstant contained TraySwitch UseCIEColor + syn keyword postscrConstant contained ColorantDetails ColorantName ColorantType NeutralDensity TrappingOrder + syn keyword postscrConstant contained ColorantSetName + +" PS LL3 trapping dictionary entries + syn keyword postscrConstant contained BlackColorLimit BlackDensityLimit BlackWidth ColorantZoneDetails + syn keyword postscrConstant contained SlidingTrapLimit StepLimit TrapColorScaling TrapSetName TrapWidth + syn keyword postscrConstant contained ImageResolution ImageToObjectTrapping ImageTrapPlacement + syn keyword postscrConstant contained StepLimit TrapColorScaling Enabled ImageInternalTrapping + +" PS LL3 filters and entries + syn keyword postscrConstant contained ReusableStreamDecode CloseSource CloseTarget UnitSize LowBitFirst + syn keyword postscrConstant contained FlateEncode FlateDecode DecodeParams Intent AsyncRead + +" PS LL3 halftone dictionary entries + syn keyword postscrConstant contained Height2 Width2 + +" PS LL3 function dictionary entries + syn keyword postscrConstant contained FunctionType Domain Range Order BitsPerSample Encode Size C0 C1 N + syn keyword postscrConstant contained Functions Bounds + +" PS LL3 image dictionary entries + syn keyword postscrConstant contained InterleaveType MaskDict DataDict MaskColor + +" PS LL3 Pattern and shading dictionary entries + syn keyword postscrConstant contained Shading ShadingType Background ColorSpace Coords Extend Function + syn keyword postscrConstant contained VerticesPerRow BitsPerCoordinate BitsPerFlag + +" PS LL3 image dictionary entries + syn keyword postscrConstant contained XOrigin YOrigin UnpaintedPath PixelCopy + +" PS LL3 colorrendering procedures + syn keyword postscrProcedure GetHalftoneName GetPageDeviceName GetSubstituteCRD + +" PS LL3 CIDInit procedures + syn keyword postscrProcedure beginbfchar beginbfrange begincidchar begincidrange begincmap begincodespacerange + syn keyword postscrProcedure beginnotdefchar beginnotdefrange beginrearrangedfont beginusematrix + syn keyword postscrProcedure endbfchar endbfrange endcidchar endcidrange endcmap endcodespacerange + syn keyword postscrProcedure endnotdefchar endnotdefrange endrearrangedfont endusematrix + syn keyword postscrProcedure StartData usefont usecmp + +" PS LL3 Trapping procedures + syn keyword postscrProcedure settrapparams currenttrapparams settrapzone + +" PS LL3 BitmapFontInit procedures + syn keyword postscrProcedure removeall removeglyphs + +" PS LL3 Font names + if exists("postscr_fonts") + syn keyword postscrConstant contained AlbertusMT AlbertusMT-Italic AlbertusMT-Light Apple-Chancery Apple-ChanceryCE + syn keyword postscrConstant contained AntiqueOlive-Roman AntiqueOlive-Italic AntiqueOlive-Bold AntiqueOlive-Compact + syn keyword postscrConstant contained AntiqueOliveCE-Roman AntiqueOliveCE-Italic AntiqueOliveCE-Bold AntiqueOliveCE-Compact + syn keyword postscrConstant contained ArialMT Arial-ItalicMT Arial-LightMT Arial-BoldMT Arial-BoldItalicMT + syn keyword postscrConstant contained ArialCE ArialCE-Italic ArialCE-Light ArialCE-Bold ArialCE-BoldItalic + syn keyword postscrConstant contained AvantGarde-Book AvantGarde-BookOblique AvantGarde-Demi AvantGarde-DemiOblique + syn keyword postscrConstant contained AvantGardeCE-Book AvantGardeCE-BookOblique AvantGardeCE-Demi AvantGardeCE-DemiOblique + syn keyword postscrConstant contained Bodoni Bodoni-Italic Bodoni-Bold Bodoni-BoldItalic Bodoni-Poster Bodoni-PosterCompressed + syn keyword postscrConstant contained BodoniCE BodoniCE-Italic BodoniCE-Bold BodoniCE-BoldItalic BodoniCE-Poster BodoniCE-PosterCompressed + syn keyword postscrConstant contained Bookman-Light Bookman-LightItalic Bookman-Demi Bookman-DemiItalic + syn keyword postscrConstant contained BookmanCE-Light BookmanCE-LightItalic BookmanCE-Demi BookmanCE-DemiItalic + syn keyword postscrConstant contained Carta Chicago ChicagoCE Clarendon Clarendon-Light Clarendon-Bold + syn keyword postscrConstant contained ClarendonCE ClarendonCE-Light ClarendonCE-Bold CooperBlack CooperBlack-Italic + syn keyword postscrConstant contained Copperplate-ThirtyTwoBC CopperPlate-ThirtyThreeBC Coronet-Regular CoronetCE-Regular + syn keyword postscrConstant contained CourierCE CourierCE-Oblique CourierCE-Bold CourierCE-BoldOblique + syn keyword postscrConstant contained Eurostile Eurostile-Bold Eurostile-ExtendedTwo Eurostile-BoldExtendedTwo + syn keyword postscrConstant contained Eurostile EurostileCE-Bold EurostileCE-ExtendedTwo EurostileCE-BoldExtendedTwo + syn keyword postscrConstant contained Geneva GenevaCE GillSans GillSans-Italic GillSans-Bold GillSans-BoldItalic GillSans-BoldCondensed + syn keyword postscrConstant contained GillSans-Light GillSans-LightItalic GillSans-ExtraBold + syn keyword postscrConstant contained GillSansCE-Roman GillSansCE-Italic GillSansCE-Bold GillSansCE-BoldItalic GillSansCE-BoldCondensed + syn keyword postscrConstant contained GillSansCE-Light GillSansCE-LightItalic GillSansCE-ExtraBold + syn keyword postscrConstant contained Goudy Goudy-Italic Goudy-Bold Goudy-BoldItalic Goudy-ExtraBould + syn keyword postscrConstant contained HelveticaCE HelveticaCE-Oblique HelveticaCE-Bold HelveticaCE-BoldOblique + syn keyword postscrConstant contained Helvetica-Condensed Helvetica-Condensed-Oblique Helvetica-Condensed-Bold Helvetica-Condensed-BoldObl + syn keyword postscrConstant contained HelveticaCE-Condensed HelveticaCE-Condensed-Oblique HelveticaCE-Condensed-Bold + syn keyword postscrConstant contained HelveticaCE-Condensed-BoldObl Helvetica-Narrow Helvetica-Narrow-Oblique Helvetica-Narrow-Bold + syn keyword postscrConstant contained Helvetica-Narrow-BoldOblique HelveticaCE-Narrow HelveticaCE-Narrow-Oblique HelveticaCE-Narrow-Bold + syn keyword postscrConstant contained HelveticaCE-Narrow-BoldOblique HoeflerText-Regular HoeflerText-Italic HoeflerText-Black + syn keyword postscrConstant contained HoeflerText-BlackItalic HoeflerText-Ornaments HoeflerTextCE-Regular HoeflerTextCE-Italic + syn keyword postscrConstant contained HoeflerTextCE-Black HoeflerTextCE-BlackItalic + syn keyword postscrConstant contained JoannaMT JoannaMT-Italic JoannaMT-Bold JoannaMT-BoldItalic + syn keyword postscrConstant contained JoannaMTCE JoannaMTCE-Italic JoannaMTCE-Bold JoannaMTCE-BoldItalic + syn keyword postscrConstant contained LetterGothic LetterGothic-Slanted LetterGothic-Bold LetterGothic-BoldSlanted + syn keyword postscrConstant contained LetterGothicCE LetterGothicCE-Slanted LetterGothicCE-Bold LetterGothicCE-BoldSlanted + syn keyword postscrConstant contained LubalinGraph-Book LubalinGraph-BookOblique LubalinGraph-Demi LubalinGraph-DemiOblique + syn keyword postscrConstant contained LubalinGraphCE-Book LubalinGraphCE-BookOblique LubalinGraphCE-Demi LubalinGraphCE-DemiOblique + syn keyword postscrConstant contained Marigold Monaco MonacoCE MonaLisa-Recut Oxford Symbol Tekton + syn keyword postscrConstant contained NewCennturySchlbk-Roman NewCenturySchlbk-Italic NewCenturySchlbk-Bold NewCenturySchlbk-BoldItalic + syn keyword postscrConstant contained NewCenturySchlbkCE-Roman NewCenturySchlbkCE-Italic NewCenturySchlbkCE-Bold + syn keyword postscrConstant contained NewCenturySchlbkCE-BoldItalic NewYork NewYorkCE + syn keyword postscrConstant contained Optima Optima-Italic Optima-Bold Optima-BoldItalic + syn keyword postscrConstant contained OptimaCE OptimaCE-Italic OptimaCE-Bold OptimaCE-BoldItalic + syn keyword postscrConstant contained Palatino-Roman Palatino-Italic Palatino-Bold Palatino-BoldItalic + syn keyword postscrConstant contained PalatinoCE-Roman PalatinoCE-Italic PalatinoCE-Bold PalatinoCE-BoldItalic + syn keyword postscrConstant contained StempelGaramond-Roman StempelGaramond-Italic StempelGaramond-Bold StempelGaramond-BoldItalic + syn keyword postscrConstant contained StempelGaramondCE-Roman StempelGaramondCE-Italic StempelGaramondCE-Bold StempelGaramondCE-BoldItalic + syn keyword postscrConstant contained TimesCE-Roman TimesCE-Italic TimesCE-Bold TimesCE-BoldItalic + syn keyword postscrConstant contained TimesNewRomanPSMT TimesNewRomanPS-ItalicMT TimesNewRomanPS-BoldMT TimesNewRomanPS-BoldItalicMT + syn keyword postscrConstant contained TimesNewRomanCE TimesNewRomanCE-Italic TimesNewRomanCE-Bold TimesNewRomanCE-BoldItalic + syn keyword postscrConstant contained Univers Univers-Oblique Univers-Bold Univers-BoldOblique + syn keyword postscrConstant contained UniversCE-Medium UniversCE-Oblique UniversCE-Bold UniversCE-BoldOblique + syn keyword postscrConstant contained Univers-Light Univers-LightOblique UniversCE-Light UniversCE-LightOblique + syn keyword postscrConstant contained Univers-Condensed Univers-CondensedOblique Univers-CondensedBold Univers-CondensedBoldOblique + syn keyword postscrConstant contained UniversCE-Condensed UniversCE-CondensedOblique UniversCE-CondensedBold UniversCE-CondensedBoldOblique + syn keyword postscrConstant contained Univers-Extended Univers-ExtendedObl Univers-BoldExt Univers-BoldExtObl + syn keyword postscrConstant contained UniversCE-Extended UniversCE-ExtendedObl UniversCE-BoldExt UniversCE-BoldExtObl + syn keyword postscrConstant contained Wingdings-Regular ZapfChancery-MediumItalic ZapfChanceryCE-MediumItalic ZapfDingBats + endif " Font names + +endif " PS LL3 highlighting + + +if exists("postscr_ghostscript") + " GS gstate operators + syn keyword postscrGSOperator .setaccuratecurves .currentaccuratecurves .setclipoutside + syn keyword postscrGSOperator .setdashadapt .currentdashadapt .setdefaultmatrix .setdotlength + syn keyword postscrGSOperator .currentdotlength .setfilladjust2 .currentfilladjust2 + syn keyword postscrGSOperator .currentclipoutside .setcurvejoin .currentcurvejoin + syn keyword postscrGSOperator .setblendmode .currentblendmode .setopacityalpha .currentopacityalpha .setshapealpha .currentshapealpha + syn keyword postscrGSOperator .setlimitclamp .currentlimitclamp .setoverprintmode .currentoverprintmode + + " GS path operators + syn keyword postscrGSOperator .dashpath .rectappend + + " GS painting operators + syn keyword postscrGSOperator .setrasterop .currentrasterop .setsourcetransparent + syn keyword postscrGSOperator .settexturetransparent .currenttexturetransparent + syn keyword postscrGSOperator .currentsourcetransparent + + " GS character operators + syn keyword postscrGSOperator .charboxpath .type1execchar %Type1BuildChar %Type1BuildGlyph + + " GS mathematical operators + syn keyword postscrGSMathOperator arccos arcsin + + " GS dictionary operators + syn keyword postscrGSOperator .dicttomark .forceput .forceundef .knownget .setmaxlength + + " GS byte and string operators + syn keyword postscrGSOperator .type1encrypt .type1decrypt + syn keyword postscrGSOperator .bytestring .namestring .stringmatch + + " GS relational operators (seem like math ones to me!) + syn keyword postscrGSMathOperator max min + + " GS file operators + syn keyword postscrGSOperator findlibfile unread writeppmfile + syn keyword postscrGSOperator .filename .fileposition .peekstring .unread + + " GS vm operators + syn keyword postscrGSOperator .forgetsave + + " GS device operators + syn keyword postscrGSOperator copydevice .getdevice makeimagedevice makewordimagedevice copyscanlines + syn keyword postscrGSOperator setdevice currentdevice getdeviceprops putdeviceprops flushpage + syn keyword postscrGSOperator finddevice findprotodevice .getbitsrect + + " GS misc operators + syn keyword postscrGSOperator getenv .makeoperator .setdebug .oserrno .oserror .execn + + " GS rendering stack operators + syn keyword postscrGSOperator .begintransparencygroup .discardtransparencygroup .endtransparencygroup + syn keyword postscrGSOperator .begintransparencymask .discardtransparencymask .endtransparencymask .inittransparencymask + syn keyword postscrGSOperator .settextknockout .currenttextknockout + + " GS filters + syn keyword postscrConstant contained BCPEncode BCPDecode eexecEncode eexecDecode PCXDecode + syn keyword postscrConstant contained PixelDifferenceEncode PixelDifferenceDecode + syn keyword postscrConstant contained PNGPredictorDecode TBCPEncode TBCPDecode zlibEncode + syn keyword postscrConstant contained zlibDecode PNGPredictorEncode PFBDecode + syn keyword postscrConstant contained MD5Encode + + " GS filter keys + syn keyword postscrConstant contained InitialCodeLength FirstBitLowOrder BlockData DecodedByteAlign + + " GS device parameters + syn keyword postscrConstant contained BitsPerPixel .HWMargins HWSize Name GrayValues + syn keyword postscrConstant contained ColorValues TextAlphaBits GraphicsAlphaBits BufferSpace + syn keyword postscrConstant contained OpenOutputFile PageCount BandHeight BandWidth BandBufferSpace + syn keyword postscrConstant contained ViewerPreProcess GreenValues BlueValues OutputFile + syn keyword postscrConstant contained MaxBitmap RedValues + +endif " GhostScript highlighting + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link postscrComment Comment + +hi def link postscrConstant Constant +hi def link postscrString String +hi def link postscrASCIIString postscrString +hi def link postscrHexString postscrString +hi def link postscrASCII85String postscrString +hi def link postscrNumber Number +hi def link postscrInteger postscrNumber +hi def link postscrHex postscrNumber +hi def link postscrRadix postscrNumber +hi def link postscrFloat Float +hi def link postscrBoolean Boolean + +hi def link postscrIdentifier Identifier +hi def link postscrProcedure Function + +hi def link postscrName Statement +hi def link postscrConditional Conditional +hi def link postscrRepeat Repeat +hi def link postscrL2Repeat postscrRepeat +hi def link postscrOperator Operator +hi def link postscrL1Operator postscrOperator +hi def link postscrL2Operator postscrOperator +hi def link postscrL3Operator postscrOperator +hi def link postscrMathOperator postscrOperator +hi def link postscrLogicalOperator postscrOperator +hi def link postscrBinaryOperator postscrOperator + +hi def link postscrDSCComment SpecialComment +hi def link postscrSpecialChar SpecialChar + +hi def link postscrTodo Todo + +hi def link postscrError Error +hi def link postscrSpecialCharError postscrError +hi def link postscrASCII85CharError postscrError +hi def link postscrHexCharError postscrError +hi def link postscrASCIIStringError postscrError +hi def link postscrIdentifierError postscrError + +if exists("postscr_ghostscript") +hi def link postscrGSOperator postscrOperator +hi def link postscrGSMathOperator postscrMathOperator +else +hi def link postscrGSOperator postscrError +hi def link postscrGSMathOperator postscrError +endif + + +let b:current_syntax = "postscr" + +" vim: ts=8 + +endif diff --git a/syntax/pov.vim b/syntax/pov.vim new file mode 100644 index 0000000..45ed505 --- /dev/null +++ b/syntax/pov.vim @@ -0,0 +1,148 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PoV-Ray(tm) 3.7 Scene Description Language +" Maintainer: David Necas (Yeti) +" Last Change: 2011-04-23 +" Required Vim Version: 6.0 + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +" Top level stuff +syn keyword povCommands global_settings +syn keyword povObjects array atmosphere background bicubic_patch blob box camera component cone cubic cylinder disc fog height_field isosurface julia_fractal lathe light_group light_source mesh mesh2 object ovus parametric pattern photons plane poly polygon polynomial prism quadric quartic rainbow sky_sphere smooth_triangle sor sphere sphere_sweep spline superellipsoid text torus triangle +syn keyword povCSG clipped_by composite contained_by difference intersection merge union +syn keyword povAppearance interior material media texture interior_texture texture_list +syn keyword povGlobalSettings ambient_light assumed_gamma charset hf_gray_16 irid_wavelength max_intersections max_trace_level number_of_waves radiosity noise_generator +syn keyword povTransform inverse matrix rotate scale translate transform + +" Descriptors +syn keyword povDescriptors finish inside_vector normal pigment uv_mapping uv_vectors vertex_vectors +syn keyword povDescriptors adc_bailout always_sample brightness count error_bound distance_maximum gray_threshold load_file low_error_factor maximum_reuse max_sample media minimum_reuse mm_per_unit nearest_count normal pretrace_end pretrace_start recursion_limit save_file +syn keyword povDescriptors color colour rgb rgbt rgbf rgbft srgb srgbf srgbt srgbft +syn match povDescriptors "\<\(red\|green\|blue\|gray\)\>" +syn keyword povDescriptors bump_map color_map colour_map image_map material_map pigment_map quick_color quick_colour normal_map texture_map image_pattern pigment_pattern +syn keyword povDescriptors ambient brilliance conserve_energy crand diffuse fresnel irid metallic phong phong_size refraction reflection reflection_exponent roughness specular subsurface +syn keyword povDescriptors cylinder fisheye mesh_camera omnimax orthographic panoramic perspective spherical ultra_wide_angle +syn keyword povDescriptors agate aoi average brick boxed bozo bumps cells checker crackle cylindrical dents facets function gradient granite hexagon julia leopard magnet mandel marble onion pavement planar quilted radial ripples slope spherical spiral1 spiral2 spotted square tiles tile2 tiling toroidal triangular waves wood wrinkles +syn keyword povDescriptors density_file +syn keyword povDescriptors area_light shadowless spotlight parallel +syn keyword povDescriptors absorption confidence density emission intervals ratio samples scattering variance +syn keyword povDescriptors distance fog_alt fog_offset fog_type turb_depth +syn keyword povDescriptors b_spline bezier_spline cubic_spline evaluate face_indices form linear_spline max_gradient natural_spline normal_indices normal_vectors quadratic_spline uv_indices +syn keyword povDescriptors target + +" Modifiers +syn keyword povModifiers caustics dispersion dispersion_samples fade_color fade_colour fade_distance fade_power ior +syn keyword povModifiers bounded_by double_illuminate hierarchy hollow no_shadow open smooth sturm threshold water_level +syn keyword povModifiers importance no_radiosity +syn keyword povModifiers hypercomplex max_iteration precision quaternion slice +syn keyword povModifiers conic_sweep linear_sweep +syn keyword povModifiers flatness type u_steps v_steps +syn keyword povModifiers aa_level aa_threshold adaptive area_illumination falloff jitter looks_like media_attenuation media_interaction method point_at radius tightness +syn keyword povModifiers angle aperture bokeh blur_samples confidence direction focal_point h_angle location look_at right sky up v_angle variance +syn keyword povModifiers all bump_size gamma interpolate map_type once premultiplied slope_map use_alpha use_color use_colour use_index +syn match povModifiers "\<\(filter\|transmit\)\>" +syn keyword povModifiers black_hole agate_turb brick_size control0 control1 cubic_wave density_map flip frequency interpolate inverse lambda metric mortar octaves offset omega phase poly_wave ramp_wave repeat scallop_wave sine_wave size strength triangle_wave thickness turbulence turb_depth type warp +syn keyword povModifiers eccentricity extinction +syn keyword povModifiers arc_angle falloff_angle width +syn keyword povModifiers accuracy all_intersections altitude autostop circular collect coords cutaway_textures dist_exp expand_thresholds exponent exterior gather global_lights major_radius max_trace no_bump_scale no_image no_reflection orient orientation pass_through precompute projected_through range_divider solid spacing split_union tolerance + +" Words not marked `reserved' in documentation, but... +syn keyword povBMPType alpha exr gif hdr iff jpeg pgm png pot ppm sys tga tiff +syn keyword povFontType ttf contained +syn keyword povDensityType df3 contained +syn keyword povCharset ascii utf8 contained + +" Math functions on floats, vectors and strings +syn keyword povFunctions abs acos acosh asc asin asinh atan atan2 atanh bitwise_and bitwise_or bitwise_xor ceil cos cosh defined degrees dimensions dimension_size div exp file_exists floor inside int internal ln log max min mod pow prod radians rand seed select sin sinh sqrt strcmp strlen sum tan tanh val vdot vlength vstr vturbulence +syn keyword povFunctions min_extent max_extent trace vcross vrotate vaxis_rotate vnormalize vturbulence +syn keyword povFunctions chr concat datetime now substr str strupr strlwr +syn keyword povJuliaFunctions acosh asinh atan cosh cube pwr reciprocal sinh sqr tanh + +" Specialities +syn keyword povConsts clock clock_delta clock_on final_clock final_frame frame_number initial_clock initial_frame input_file_name image_width image_height false no off on pi true version yes +syn match povConsts "\<[tuvxyz]\>" +syn match povDotItem "\.\@<=\(blue\|green\|gray\|filter\|red\|transmit\|hf\|t\|u\|v\|x\|y\|z\)\>" display + +" Comments +syn region povComment start="/\*" end="\*/" contains=povTodo,povComment +syn match povComment "//.*" contains=povTodo +syn match povCommentError "\*/" +syn sync ccomment povComment +syn sync minlines=50 +syn keyword povTodo TODO FIXME XXX NOT contained +syn cluster povPRIVATE add=povTodo + +" Language directives +syn match povConditionalDir "#\s*\(else\|end\|for\|if\|ifdef\|ifndef\|switch\|while\)\>" +syn match povLabelDir "#\s*\(break\|case\|default\|range\)\>" +syn match povDeclareDir "#\s*\(declare\|default\|local\|macro\|undef\|version\)\>" nextgroup=povDeclareOption skipwhite +syn keyword povDeclareOption deprecated once contained nextgroup=povDeclareOption skipwhite +syn match povIncludeDir "#\s*include\>" +syn match povFileDir "#\s*\(fclose\|fopen\|read\|write\)\>" +syn keyword povFileDataType uint8 sint8 unit16be uint16le sint16be sint16le sint32le sint32be +syn match povMessageDir "#\s*\(debug\|error\|render\|statistics\|warning\)\>" +syn region povFileOpen start="#\s*fopen\>" skip=+"[^"]*"+ matchgroup=povOpenType end="\<\(read\|write\|append\)\>" contains=ALLBUT,PovParenError,PovBraceError,@PovPRIVATE transparent keepend + +" Literal strings +syn match povSpecialChar "\\u\x\{4}\|\\\d\d\d\|\\." contained +syn region povString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=povSpecialChar oneline +syn cluster povPRIVATE add=povSpecialChar + +" Catch errors caused by wrong parenthesization +syn region povParen start='(' end=')' contains=ALLBUT,povParenError,@povPRIVATE transparent +syn match povParenError ")" +syn region povBrace start='{' end='}' contains=ALLBUT,povBraceError,@povPRIVATE transparent +syn match povBraceError "}" + +" Numbers +syn match povNumber "\(^\|\W\)\@<=[+-]\=\(\d\+\)\=\.\=\d\+\([eE][+-]\=\d\+\)\=" + +" Define the default highlighting +hi def link povComment Comment +hi def link povTodo Todo +hi def link povNumber Number +hi def link povString String +hi def link povFileOpen Constant +hi def link povConsts Constant +hi def link povDotItem povSpecial +hi def link povBMPType povSpecial +hi def link povCharset povSpecial +hi def link povDensityType povSpecial +hi def link povFontType povSpecial +hi def link povOpenType povSpecial +hi def link povSpecialChar povSpecial +hi def link povSpecial Special +hi def link povConditionalDir PreProc +hi def link povLabelDir PreProc +hi def link povDeclareDir Define +hi def link povDeclareOption Define +hi def link povIncludeDir Include +hi def link povFileDir PreProc +hi def link povFileDataType Special +hi def link povMessageDir Debug +hi def link povAppearance povDescriptors +hi def link povObjects povDescriptors +hi def link povGlobalSettings povDescriptors +hi def link povDescriptors Type +hi def link povJuliaFunctions PovFunctions +hi def link povModifiers povFunctions +hi def link povFunctions Function +hi def link povCommands Operator +hi def link povTransform Operator +hi def link povCSG Operator +hi def link povParenError povError +hi def link povBraceError povError +hi def link povCommentError povError +hi def link povError Error + +let b:current_syntax = "pov" + +endif diff --git a/syntax/povini.vim b/syntax/povini.vim new file mode 100644 index 0000000..8e75d5a --- /dev/null +++ b/syntax/povini.vim @@ -0,0 +1,60 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PoV-Ray(tm) 3.7 configuration/initialization files +" Maintainer: David Necas (Yeti) +" Last Change: 2011-04-24 +" Required Vim Version: 6.0 + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" Syntax +syn match poviniInclude "^\s*[^[+-;]\S*\s*$" contains=poviniSection +syn match poviniLabel "^.\{-1,}\ze=" transparent contains=poviniKeyword nextgroup=poviniBool,poviniNumber +syn keyword poviniBool On Off True False Yes No +syn match poviniNumber "\<\d*\.\=\d\+\>" +syn keyword poviniKeyword Clock Initial_Frame Final_Frame Frame_Final Frame_Step Initial_Clock Final_Clock Subset_Start_Frame Subset_End_Frame Cyclic_Animation Clockless_Animation Real_Time_Raytracing Field_Render Odd_Field Work_Threads +syn keyword poviniKeyword Width Height Start_Column Start_Row End_Column End_Row Test_Abort Test_Abort_Count Continue_Trace Create_Ini +syn keyword poviniKeyword Display Video_Mode Palette Display_Gamma Pause_When_Done Verbose Draw_Vistas Preview_Start_Size Preview_End_Size Render_Block_Size Render_Block_Step Render_Pattern Max_Image_Buffer_Memory +syn keyword poviniKeyword Output_to_File Output_File_Type Output_Alpha Bits_Per_Color Output_File_Name Buffer_Output Buffer_Size Dither Dither_Method File_Gamma +syn keyword poviniKeyword BSP_Base BSP_Child BSP_Isect BSP_Max BSP_Miss +syn keyword poviniKeyword Histogram_Type Histogram_Grid_Size Histogram_Name +syn keyword poviniKeyword Input_File_Name Include_Header Library_Path Version +syn keyword poviniKeyword Debug_Console Fatal_Console Render_Console Statistic_Console Warning_Console All_Console Debug_File Fatal_File Render_File Statistic_File Warning_File All_File Warning_Level +syn keyword poviniKeyword Quality Bounding Bounding_Method Bounding_Threshold Light_Buffer Vista_Buffer Remove_Bounds Split_Unions Antialias Sampling_Method Antialias_Threshold Jitter Jitter_Amount Antialias_Depth Antialias_Gamma +syn keyword poviniKeyword Pre_Scene_Return Pre_Frame_Return Post_Scene_Return Post_Frame_Return User_Abort_Return Fatal_Error_Return +syn keyword poviniKeyword Radiosity Radiosity_File_Name Radiosity_From_File Radiosity_To_File Radiosity_Vain_Pretrace High_Reproducibility +syn match poviniShellOut "^\s*\(Pre_Scene_Command\|Pre_Frame_Command\|Post_Scene_Command\|Post_Frame_Command\|User_Abort_Command\|Fatal_Error_Command\)\>" nextgroup=poviniShellOutEq skipwhite +syn match poviniShellOutEq "=" nextgroup=poviniShellOutRHS skipwhite contained +syn match poviniShellOutRHS "[^;]\+" skipwhite contained contains=poviniShellOutSpecial +syn match poviniShellOutSpecial "%[osnkhw%]" contained +syn keyword poviniDeclare Declare +syn match poviniComment ";.*$" +syn match poviniOption "^\s*[+-]\S*" +syn match poviniIncludeLabel "^\s*Include_INI\s*=" nextgroup=poviniIncludedFile skipwhite +syn match poviniIncludedFile "[^;]\+" contains=poviniSection contained +syn region poviniSection start="\[" end="\]" + +" Define the default highlighting +hi def link poviniSection Special +hi def link poviniComment Comment +hi def link poviniDeclare poviniKeyword +hi def link poviniShellOut poviniKeyword +hi def link poviniIncludeLabel poviniKeyword +hi def link poviniKeyword Type +hi def link poviniShellOutSpecial Special +hi def link poviniIncludedFile poviniInclude +hi def link poviniInclude Include +hi def link poviniOption Keyword +hi def link poviniBool Constant +hi def link poviniNumber Number + +let b:current_syntax = "povini" + +endif diff --git a/syntax/ppd.vim b/syntax/ppd.vim new file mode 100644 index 0000000..9fcece9 --- /dev/null +++ b/syntax/ppd.vim @@ -0,0 +1,39 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PPD (PostScript printer description) file +" Maintainer: Bjoern Jacke +" Last Change: 2001-10-06 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +syn match ppdComment "^\*%.*" +syn match ppdDef "\*[a-zA-Z0-9]\+" +syn match ppdDefine "\*[a-zA-Z0-9\-_]\+:" +syn match ppdUI "\*[a-zA-Z]*\(Open\|Close\)UI" +syn match ppdUIGroup "\*[a-zA-Z]*\(Open\|Close\)Group" +syn match ppdGUIText "/.*:" +syn match ppdContraints "^*UIConstraints:" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + + +hi def link ppdComment Comment +hi def link ppdDefine Statement +hi def link ppdUI Function +hi def link ppdUIGroup Function +hi def link ppdDef String +hi def link ppdGUIText Type +hi def link ppdContraints Special + + +let b:current_syntax = "ppd" + +" vim: ts=8 + +endif diff --git a/syntax/ppwiz.vim b/syntax/ppwiz.vim new file mode 100644 index 0000000..62df127 --- /dev/null +++ b/syntax/ppwiz.vim @@ -0,0 +1,88 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PPWizard (preprocessor by Dennis Bareis) +" Maintainer: Stefan Schwarzer +" URL: http://www.ndh.net/home/sschwarzer/download/ppwiz.vim +" Last Change: 2003 May 11 +" Filename: ppwiz.vim + +" Remove old syntax stuff +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +if !exists("ppwiz_highlight_defs") + let ppwiz_highlight_defs = 1 +endif + +if !exists("ppwiz_with_html") + let ppwiz_with_html = 1 +endif + +" comments +syn match ppwizComment "^;.*$" +syn match ppwizComment ";;.*$" +" HTML +if ppwiz_with_html > 0 + syn region ppwizHTML start="<" end=">" contains=ppwizArg,ppwizMacro + syn match ppwizHTML "\&\w\+;" +endif +" define, evaluate etc. +if ppwiz_highlight_defs == 1 + syn match ppwizDef "^\s*\#\S\+\s\+\S\+" contains=ALL + syn match ppwizDef "^\s*\#\(if\|else\|endif\)" contains=ALL + syn match ppwizDef "^\s*\#\({\|break\|continue\|}\)" contains=ALL +" elseif ppwiz_highlight_defs == 2 +" syn region ppwizDef start="^\s*\#" end="[^\\]$" end="^$" keepend contains=ALL +else + syn region ppwizDef start="^\s*\#" end="[^\\]$" end="^$" keepend contains=ppwizCont +endif +syn match ppwizError "\s.\\$" +syn match ppwizCont "\s\([+\-%]\|\)\\$" +" macros to execute +syn region ppwizMacro start="<\$" end=">" contains=@ppwizArgVal,ppwizCont +" macro arguments +syn region ppwizArg start="{" end="}" contains=ppwizEqual,ppwizString +syn match ppwizEqual "=" contained +syn match ppwizOperator "<>\|=\|<\|>" contained +" standard variables (builtin) +syn region ppwizStdVar start="" contains=@ppwizArgVal +" Rexx variables +syn region ppwizRexxVar start="" contains=@ppwizArgVal +" Constants +syn region ppwizString start=+"+ end=+"+ contained contains=ppwizMacro,ppwizArg,ppwizHTML,ppwizCont,ppwizStdVar,ppwizRexxVar +syn region ppwizString start=+'+ end=+'+ contained contains=ppwizMacro,ppwizArg,ppwizHTML,ppwizCont,ppwizStdVar,ppwizRexxVar +syn match ppwizInteger "\d\+" contained + +" Clusters +syn cluster ppwizArgVal add=ppwizString,ppwizInteger + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link ppwizSpecial Special +hi def link ppwizEqual ppwizSpecial +hi def link ppwizOperator ppwizSpecial +hi def link ppwizComment Comment +hi def link ppwizDef PreProc +hi def link ppwizMacro Statement +hi def link ppwizArg Identifier +hi def link ppwizStdVar Identifier +hi def link ppwizRexxVar Identifier +hi def link ppwizString Constant +hi def link ppwizInteger Constant +hi def link ppwizCont ppwizSpecial +hi def link ppwizError Error +hi def link ppwizHTML Type + + +let b:current_syntax = "ppwiz" + +" vim: ts=4 + + +endif diff --git a/syntax/prescribe.vim b/syntax/prescribe.vim new file mode 100644 index 0000000..5251016 --- /dev/null +++ b/syntax/prescribe.vim @@ -0,0 +1,60 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Kyocera PreScribe2e +" Maintainer: Klaus Muth +" URL: http://www.hampft.de/vim/syntax/prescribe.vim +" Last Change: 2005 Mar 04 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match prescribeSpecial "!R!" + +" all prescribe commands +syn keyword prescribeStatement ALTF AMCR ARC ASFN ASTK BARC BLK BOX CALL +syn keyword prescribeStatement CASS CIR CLIP CLPR CLSP COPY CPTH CSET CSTK +syn keyword prescribeStatement CTXT DAF DAM DAP DELF DELM DPAT DRP DRPA DUPX +syn keyword prescribeStatement DXPG DXSD DZP ENDD ENDM ENDR EPL EPRM EXIT +syn keyword prescribeStatement FDIR FILL FLAT FLST FONT FPAT FRPO FSET FTMD +syn keyword prescribeStatement GPAT ICCD INTL JOG LDFC MAP MCRO MDAT MID +syn keyword prescribeStatement MLST MRP MRPA MSTK MTYP MZP NEWP PAGE PARC PAT +syn keyword prescribeStatement PCRP PCZP PDIR RDRP PDZP PELP PIE PMRA PMRP PMZP +syn keyword prescribeStatement PRBX PRRC PSRC PXPL RDMP RES RSL RGST RPCS RPF +syn keyword prescribeStatement RPG RPP RPU RTTX RTXT RVCD RVRD SBM SCAP SCCS +syn keyword prescribeStatement SCF SCG SCP SCPI SCRC SCS SCU SDP SEM SETF SFA +syn keyword prescribeStatement SFNT SIMG SIR SLJN SLM SLPI SLPP SLS SMLT SPD +syn keyword prescribeStatement SPL SPLT SPO SPSZ SPW SRM SRO SROP SSTK STAT STRK +syn keyword prescribeStatement SULP SVCP TATR TEXT TPRS UNIT UOM WIDE WRED XPAT +syn match prescribeStatement "\" +syn match prescribeStatement "\" +syn match prescribeStatement "\" +syn match prescribeStatement "\" +syn match prescribeStatement "\" +syn match prescribeStatement "\" +syn match prescribeStatement "\" + +syn match prescribeCSETArg "[0-9]\{1,3}[A-Z]" +syn match prescribeFRPOArg "[A-Z][0-9]\{1,2}" +syn match prescribeNumber "[0-9]\+" +syn region prescribeString start=+'+ end=+'+ skip=+\\'+ +syn region prescribeComment start=+CMNT+ end=+;+ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link prescribeSpecial PreProc +hi def link prescribeStatement Statement +hi def link prescribeNumber Number +hi def link prescribeCSETArg String +hi def link prescribeFRPOArg String +hi def link prescribeComment Comment + + +let b:current_syntax = "prescribe" + +" vim: ts=8 + +endif diff --git a/syntax/privoxy.vim b/syntax/privoxy.vim new file mode 100644 index 0000000..860f740 --- /dev/null +++ b/syntax/privoxy.vim @@ -0,0 +1,75 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Privoxy actions file +" Maintainer: Doug Kearns +" URL: http://gus.gscit.monash.edu.au/~djkea2/vim/syntax/privoxy.vim +" Last Change: 2007 Mar 30 + +" Privoxy 3.0.6 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword=@,48-57,_,- + +syn keyword privoxyTodo contained TODO FIXME XXX NOTE +syn match privoxyComment "#.*" contains=privoxyTodo,@Spell + +syn region privoxyActionLine matchgroup=privoxyActionLineDelimiter start="^\s*\zs{" end="}\ze\s*$" + \ contains=privoxyEnabledPrefix,privoxyDisabledPrefix + +syn match privoxyEnabledPrefix "\%(^\|\s\|{\)\@<=+\l\@=" nextgroup=privoxyAction,privoxyFilterAction contained +syn match privoxyDisabledPrefix "\%(^\|\s\|{\)\@<=-\l\@=" nextgroup=privoxyAction,privoxyFilterAction contained + +syn match privoxyAction "\%(add-header\|block\|content-type-overwrite\|crunch-client-header\|crunch-if-none-match\)\>" contained +syn match privoxyAction "\%(crunch-incoming-cookies\|crunch-outgoing-cookies\|crunch-server-header\|deanimate-gifs\)\>" contained +syn match privoxyAction "\%(downgrade-http-version\|fast-redirects\|filter-client-headers\|filter-server-headers\)\>" contained +syn match privoxyAction "\%(filter\|force-text-mode\|handle-as-empty-document\|handle-as-image\)\>" contained +syn match privoxyAction "\%(hide-accept-language\|hide-content-disposition\|hide-forwarded-for-headers\)\>" contained +syn match privoxyAction "\%(hide-from-header\|hide-if-modified-since\|hide-referrer\|hide-user-agent\|inspect-jpegs\)\>" contained +syn match privoxyAction "\%(kill-popups\|limit-connect\|overwrite-last-modified\|prevent-compression\|redirect\)\>" contained +syn match privoxyAction "\%(send-vanilla-wafer\|send-wafer\|session-cookies-only\|set-image-blocker\)\>" contained +syn match privoxyAction "\%(treat-forbidden-connects-like-blocks\)\>" + +syn match privoxyFilterAction "filter{[^}]*}" contained contains=privoxyFilterArg,privoxyActionBraces +syn match privoxyActionBraces "[{}]" contained +syn keyword privoxyFilterArg js-annoyances js-events html-annoyances content-cookies refresh-tags unsolicited-popups all-popups + \ img-reorder banners-by-size banners-by-link webbugs tiny-textforms jumping-windows frameset-borders demoronizer + \ shockwave-flash quicktime-kioskmode fun crude-parental ie-exploits site-specifics no-ping google yahoo msn blogspot + \ x-httpd-php-to-html html-to-xml xml-to-html hide-tor-exit-notation contained + +" Alternative spellings +syn match privoxyAction "\%(kill-popup\|hide-referer\|prevent-keeping-cookies\)\>" contained + +" Pre-3.0 compatibility +syn match privoxyAction "\%(no-cookie-read\|no-cookie-set\|prevent-reading-cookies\|prevent-setting-cookies\)\>" contained +syn match privoxyAction "\%(downgrade\|hide-forwarded\|hide-from\|image\|image-blocker\|no-compression\)\>" contained +syn match privoxyAction "\%(no-cookies-keep\|no-cookies-read\|no-cookies-set\|no-popups\|vanilla-wafer\|wafer\)\>" contained + +syn match privoxySetting "\" + +syn match privoxyHeader "^\s*\zs{{\%(alias\|settings\)}}\ze\s*$" + +hi def link privoxyAction Identifier +hi def link privoxyFilterAction Identifier +hi def link privoxyActionLineDelimiter Delimiter +hi def link privoxyDisabledPrefix SpecialChar +hi def link privoxyEnabledPrefix SpecialChar +hi def link privoxyHeader PreProc +hi def link privoxySetting Identifier +hi def link privoxyFilterArg Constant + +hi def link privoxyComment Comment +hi def link privoxyTodo Todo + +let b:current_syntax = "privoxy" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/procmail.vim b/syntax/procmail.vim new file mode 100644 index 0000000..520b035 --- /dev/null +++ b/syntax/procmail.vim @@ -0,0 +1,58 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Procmail definition file +" Maintainer: Melchior FRANZ +" Last Change: 2003 Aug 14 +" Author: Sonia Heimann + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match procmailComment "#.*$" contains=procmailTodo +syn keyword procmailTodo contained Todo TBD + +syn region procmailString start=+"+ skip=+\\"+ end=+"+ +syn region procmailString start=+'+ skip=+\\'+ end=+'+ + +syn region procmailVarDeclRegion start="^\s*[a-zA-Z0-9_]\+\s*="hs=e-1 skip=+\\$+ end=+$+ contains=procmailVar,procmailVarDecl,procmailString +syn match procmailVarDecl contained "^\s*[a-zA-Z0-9_]\+" +syn match procmailVar "$[a-zA-Z0-9_]\+" + +syn match procmailCondition contained "^\s*\*.*" + +syn match procmailActionFolder contained "^\s*[-_a-zA-Z0-9/]\+" +syn match procmailActionVariable contained "^\s*$[a-zA-Z_]\+" +syn region procmailActionForward start=+^\s*!+ skip=+\\$+ end=+$+ +syn region procmailActionPipe start=+^\s*|+ skip=+\\$+ end=+$+ +syn region procmailActionNested start=+^\s*{+ end=+^\s*}+ contains=procmailRecipe,procmailComment,procmailVarDeclRegion + +syn region procmailRecipe start=+^\s*:.*$+ end=+^\s*\($\|}\)+me=e-1 contains=procmailComment,procmailCondition,procmailActionFolder,procmailActionVariable,procmailActionForward,procmailActionPipe,procmailActionNested,procmailVarDeclRegion + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link procmailComment Comment +hi def link procmailTodo Todo + +hi def link procmailRecipe Statement +"hi def link procmailCondition Statement + +hi def link procmailActionFolder procmailAction +hi def link procmailActionVariable procmailAction +hi def link procmailActionForward procmailAction +hi def link procmailActionPipe procmailAction +hi def link procmailAction Function +hi def link procmailVar Identifier +hi def link procmailVarDecl Identifier + +hi def link procmailString String + + +let b:current_syntax = "procmail" + +" vim: ts=8 + +endif diff --git a/syntax/progress.vim b/syntax/progress.vim new file mode 100644 index 0000000..c828fa3 --- /dev/null +++ b/syntax/progress.vim @@ -0,0 +1,316 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Progress 4GL +" Filename extensions: *.p (collides with Pascal), +" *.i (collides with assembler) +" *.w (collides with cweb) +" Maintainer: Philip Uren Remove SPAXY spam block +" Contributors: Matthew Stickney +" Chris Ruprecht +" Mikhail Kuperblum +" John Florian +" Version: 13 +" Last Change: Nov 11 2012 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword=@,48-57,_,-,!,#,$,% + +" The Progress editor doesn't cope with tabs very well. +set expandtab + +syn case ignore + +" Progress Blocks of code and mismatched "end." errors. +syn match ProgressEndError "\" +syn region ProgressDoBlock transparent matchgroup=ProgressDo start="\" matchgroup=ProgressDo end="\" contains=ALLBUT,ProgressProcedure,ProgressFunction +syn region ProgressForBlock transparent matchgroup=ProgressFor start="\" matchgroup=ProgressFor end="\" contains=ALLBUT,ProgressProcedure,ProgressFunction +syn region ProgressRepeatBlock transparent matchgroup=ProgressRepeat start="\" matchgroup=ProgressRepeat end="\" contains=ALLBUT,ProgressProcedure,ProgressFunction +syn region ProgressCaseBlock transparent matchgroup=ProgressCase start="\" matchgroup=ProgressCase end="\\|\" contains=ALLBUT,ProgressProcedure,ProgressFunction + +" These are Progress reserved words, +" and they could go in ProgressReserved, +" but I found it more helpful to highlight them in a different color. +syn keyword ProgressConditional if else then when otherwise +syn keyword ProgressFor each where + +" Make those TODO and debugging notes stand out! +syn keyword ProgressTodo contained TODO BUG FIX +syn keyword ProgressDebug contained DEBUG +syn keyword ProgressDebug debugger + +" If you like to highlight the whole line of +" the start and end of procedures +" to make the whole block of code stand out: +syn match ProgressProcedure "^\s*procedure.*" +syn match ProgressProcedure "^\s*end\s\s*procedure.*" +syn match ProgressFunction "^\s*function.*" +syn match ProgressFunction "^\s*end\s\s*function.*" +" ... otherwise use this: +" syn keyword ProgressFunction procedure function + +syn keyword ProgressReserved accum[ulate] active-form active-window add alias all alter ambig[uous] analyz[e] and any apply as asc[ending] +syn keyword ProgressReserved assign asynchronous at attr[-space] audit-control audit-policy authorization auto-ret[urn] avail[able] back[ground] +syn keyword ProgressReserved before-h[ide] begins bell between big-endian blank break buffer-comp[are] buffer-copy by by-pointer by-variant-point[er] call +syn keyword ProgressReserved can-do can-find case case-sen[sitive] cast center[ed] check chr clear clipboard codebase-locator colon color column-lab[el] +syn keyword ProgressReserved col[umns] com-self compiler connected control copy-lob count-of cpstream create current current-changed current-lang[uage] +syn keyword ProgressReserved current-window current_date curs[or] database dataservers dataset dataset-handle db-remote-host dbcodepage dbcollation dbname +syn keyword ProgressReserved dbparam dbrest[rictions] dbtaskid dbtype dbvers[ion] dde deblank debug-list debugger decimals declare default +syn keyword ProgressReserved default-noxl[ate] default-window def[ine] delete delimiter desc[ending] dict[ionary] disable discon[nect] disp[lay] distinct do dos +syn keyword ProgressReserved down drop dynamic-cast dynamic-func[tion] dynamic-new each editing else enable encode end entry error-stat[us] escape +syn keyword ProgressReserved etime event-procedure except exclusive[-lock] exclusive-web[-user] exists export false fetch field[s] file-info[rmation] +syn keyword ProgressReserved fill find find-case-sensitive find-global find-next-occurrence find-prev-occurrence find-select find-wrap-around first +syn keyword ProgressReserved first-of focus font for form[at] fram[e] frame-col frame-db frame-down frame-field frame-file frame-inde[x] frame-line +syn keyword ProgressReserved frame-name frame-row frame-val[ue] from from-c[hars] from-p[ixels] function-call-type gateway[s] get-attr-call-type get-byte +syn keyword ProgressReserved get-codepage[s] get-coll[ations] get-column get-error-column get-error-row get-file-name get-file-offse[t] get-key-val[ue] +syn keyword ProgressReserved get-message-type get-row getbyte global go-on go-pend[ing] grant graphic-e[dge] group having header help hide host-byte-order if +syn keyword ProgressReserved import in index indicator input input-o[utput] insert into is is-attr[-space] join kblabel key-code key-func[tion] key-label +syn keyword ProgressReserved keycode keyfunc[tion] keylabel keys keyword label last last-even[t] last-key last-of lastkey ldbname leave library like +syn keyword ProgressReserved like-sequential line-count[er] listi[ng] little-endian locked log-manager lookup machine-class map member message message-lines mouse +syn keyword ProgressReserved mpe new next next-prompt no no-attr[-space] no-error no-f[ill] no-help no-hide no-label[s] no-lobs no-lock no-map +syn keyword ProgressReserved no-mes[sage] no-pause no-prefe[tch] no-return-val[ue] no-undo no-val[idate] no-wait not now null num-ali[ases] num-dbs num-entries +syn keyword ProgressReserved of off old on open opsys option or os-append os-command os-copy os-create-dir os-delete os-dir os-drive[s] os-error +syn keyword ProgressReserved os-rename otherwise output overlay page page-bot[tom] page-num[ber] page-top param[eter] password-field pause pdbname +syn keyword ProgressReserved persist[ent] pixels preproc[ess] privileges proc-ha[ndle] proc-st[atus] procedure-call-type process profiler program-name progress +syn keyword ProgressReserved prompt[-for] promsgs propath provers[ion] publish put put-byte put-key-val[ue] putbyte query query-tuning quit r-index +syn keyword ProgressReserved rcode-info[rmation] read-available read-exact-num readkey recid record-len[gth] rect[angle] release repeat reposition retain retry return +syn keyword ProgressReserved return-val[ue] revert revoke row-created row-deleted row-modified row-unmodified run save sax-comple[te] sax-parser-error +syn keyword ProgressReserved sax-running sax-uninitialized sax-write-begin sax-write-complete sax-write-content sax-write-element sax-write-error +syn keyword ProgressReserved sax-write-idle sax-write-tag schema screen screen-io screen-lines scroll sdbname search search-self search-target security-policy +syn keyword ProgressReserved seek select self session set set-attr-call-type setuser[id] share[-lock] shared show-stat[s] skip some source-procedure +syn keyword ProgressReserved space status stream stream-handle stream-io string-xref subscribe super system-dialog table table-handle target-procedure +syn keyword ProgressReserved term[inal] text text-cursor text-seg[-grow] then this-object this-procedure time title to today top-only trans[action] trigger +syn keyword ProgressReserved triggers trim true underl[ine] undo unform[atted] union unique unix unless-hidden unsubscribe up update use-index use-revvideo +syn keyword ProgressReserved use-underline user[id] using value values view view-as wait-for web-con[text] when where while window window-delayed-min[imize] +syn keyword ProgressReserved window-maxim[ized] window-minim[ized] window-normal with work-tab[le] workfile write xcode xcode-session-key xref xref-xml yes + +" Strings. Handles embedded quotes. +" Note that, for some reason, Progress doesn't use the backslash, "\" +" as the escape character; it uses tilde, "~". +syn region ProgressString matchgroup=ProgressQuote start=+"+ end=+"+ skip=+\~'\|\~\~\|\~"+ contains=@Spell +syn region ProgressString matchgroup=ProgressQuote start=+'+ end=+'+ skip=+\~'\|\~\~\|\~"+ contains=@Spell + +syn match ProgressIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>()" + +" syn match ProgressDelimiter "()" + +syn match ProgressMatrixDelimiter "[][]" +" If you prefer you can highlight the range: +"syn match ProgressMatrixDelimiter "[\d\+\.\.\d\+]" + +syn match ProgressNumber "\<\-\=\d\+\(u\=l\=\|lu\|f\)\>" +syn match ProgressByte "\$[0-9a-fA-F]\+" + +" More values: Logicals, and Progress's unknown value, ?. +syn match ProgressNumber "?" +syn keyword ProgressNumber true false yes no + +" If you don't like tabs: +syn match ProgressShowTab "\t" + +" If you don't like white space on the end of lines, uncomment this: +" syn match ProgressSpaceError "\s\+$" + +syn region ProgressComment start="/\*" end="\*/" contains=ProgressComment,ProgressTodo,ProgressDebug,@Spell +syn region ProgressInclude start="^[ ]*[{]" end="[}]" contains=ProgressPreProc,ProgressOperator,ProgressString,ProgressComment +syn region ProgressPreProc start="&" end="\>" contained + +" This next line works reasonably well. +" syn match ProgressOperator "[!;|)(:.><+*=-]" +" +" Progress allows a '-' to be part of an identifier. To be considered +" the subtraction/negation operation operator it needs a non-word +" character on either side. Also valid are cases where the minus +" operation appears at the beginning or end of a line. +" This next line trips up on "no-undo" etc. +" syn match ProgressOperator "[!;|)(:.><+*=]\|\W-\W\|^-\W\|\W-$" +syn match ProgressOperator "[!;|)(:.><+*=]\|\s-\s\|^-\s\|\s-$" + +syn keyword ProgressOperator <= <> >= +syn keyword ProgressOperator abs[olute] accelerator accept-changes accept-row-changes across active actor add-buffer add-calc-col[umn] +syn keyword ProgressOperator add-columns-from add-events-proc[edure] add-fields-from add-first add-header-entry add-index-field add-interval add-last +syn keyword ProgressOperator add-like-col[umn] add-like-field add-like-index add-new-field add-new-index add-rel[ation] add-schema-location add-source-buffer +syn keyword ProgressOperator add-super-proc[edure] adm-data advise after-buffer after-rowid after-table alert-box allow-column-searching allow-replication alternate-key +syn keyword ProgressOperator always-on-top ansi-only anywhere append append-child appl-alert[-boxes] appl-context-id application apply-callback appserver-info +syn keyword ProgressOperator appserver-password appserver-userid array-m[essage] ask-overwrite assembly async-request-count async-request-handle attach-data-source +syn keyword ProgressOperator attached-pairlist attach attribute-names audit-enabled audit-event-context authentication-failed auto-comp[letion] auto-delete +syn keyword ProgressOperator auto-delete-xml auto-end-key auto-endkey auto-go auto-ind[ent] auto-resize auto-synchronize auto-val[idate] auto-z[ap] automatic +syn keyword ProgressOperator available-formats ave[rage] avg backward[s] base-ade base-key basic-logging batch[-mode] batch-size before-buffer before-rowid +syn keyword ProgressOperator before-table begin-event-group bgc[olor] binary bind bind-where blob block-iteration-display border-b[ottom-chars] +syn keyword ProgressOperator border-bottom-p[ixels] border-l[eft-chars] border-left-p[ixels] border-r[ight-chars] border-right-p[ixels] border-t[op-chars] +syn keyword ProgressOperator border-top-p[ixels] both bottom box box-select[able] browse buffer buffer-chars buffer-create buffer-delete buffer-field buffer-handle +syn keyword ProgressOperator buffer-lines buffer-n[ame] buffer-releas[e] buffer-validate buffer-value button[s] by-reference by-value byte bytes-read +syn keyword ProgressOperator bytes-written cache cache-size call-name call-type can-crea[te] can-dele[te] can-query can-read can-set can-writ[e] cancel-break +syn keyword ProgressOperator cancel-button cancel-requests cancelled caps careful-paint catch cdecl chained char[acter] character_length charset checked +syn keyword ProgressOperator child-buffer child-num choose class class-type clear-appl-context clear-log clear-select[ion] clear-sort-arrow[s] +syn keyword ProgressOperator client-connection-id client-principal client-tty client-type client-workstation clob clone-node close close-log code codepage +syn keyword ProgressOperator codepage-convert col-of collate colon-align[ed] color-table column-bgc[olor] column-codepage column-dcolor column-fgc[olor] +syn keyword ProgressOperator column-font column-movable column-of column-pfc[olor] column-read-only column-resizable column-sc[rolling] com-handle combo-box +syn keyword ProgressOperator command compare[s] compile complete config-name connect constructor contents context context-help context-help-file +syn keyword ProgressOperator context-help-id context-pop[up] control-box control-fram[e] convert convert-to-offs[et] copy-dataset copy-sax-attributes +syn keyword ProgressOperator copy-temp-table count cpcase cpcoll cpint[ernal] cplog cpprint cprcodein cprcodeout cpterm crc-val[ue] create-like +syn keyword ProgressOperator create-like-sequential create-node create-node-namespace create-result-list-entry create-test-file current-column current-env[ironment] +syn keyword ProgressOperator current-iteration current-query current-result-row current-row-modified current-value cursor-char cursor-line cursor-offset data-b[ind] +syn keyword ProgressOperator data-entry-ret[urn] data-rel[ation] data-source data-source-complete-map data-source-modified data-source-rowid data-t[ype] date +syn keyword ProgressOperator date-f[ormat] day db-references dcolor dde-error dde-i[d] dde-item dde-name dde-topic debu[g] debug-alert +syn keyword ProgressOperator declare-namespace decrypt default-buffer-handle default-but[ton] default-commit default-ex[tension] default-string +syn keyword ProgressOperator default-value define-user-event-manager defined delete-char delete-current-row delete-header-entry delete-line delete-node +syn keyword ProgressOperator delete-result-list-entry delete-selected-row delete-selected-rows descript[ion] deselect-focused-row deselect-rows deselect-selected-row +syn keyword ProgressOperator destructor detach-data-source dialog-box dir directory disable-auto-zap disable-connections disable-dump-triggers +syn keyword ProgressOperator disable-load-triggers disabled display-message display-timezone display-t[ype] domain-description domain-name domain-type double +syn keyword ProgressOperator drag-enabled drop-down drop-down-list drop-target dump dump-logging-now dynamic dynamic-current-value dynamic-next-value echo +syn keyword ProgressOperator edge[-chars] edge-p[ixels] edit-can-paste edit-can-undo edit-clear edit-copy edit-cut edit-paste edit-undo editor empty +syn keyword ProgressOperator empty-dataset empty-temp-table enable-connections enabled encoding encrypt encrypt-audit-mac-key encryption-salt end-document +syn keyword ProgressOperator end-element end-event-group end-file-drop end-key end-user-prompt endkey entered entry-types-list eq error error-col[umn] +syn keyword ProgressOperator error-object-detail error-row error-stack-trace error-string event-group-id event-procedure-context event-t[ype] events exclusive-id +syn keyword ProgressOperator execute execution-log exp expand expandable expire explicit export-principal extended extent external extract +syn keyword ProgressOperator fetch-selected-row fgc[olor] file file-create-d[ate] file-create-t[ime] file-mod-d[ate] file-mod-t[ime] file-name file-off[set] +syn keyword ProgressOperator file-size file-type filename fill-in fill-mode fill-where-string filled filters final finally find-by-rowid find-current +syn keyword ProgressOperator find-first find-last find-unique finder first-async[-request] first-buffer first-child first-column first-data-source +syn keyword ProgressOperator first-dataset first-form first-object first-proc[edure] first-query first-serv[er] first-server-socket first-socket +syn keyword ProgressOperator first-tab-i[tem] fit-last-column fix-codepage fixed-only flat-button float focused-row focused-row-selected font-table force-file +syn keyword ProgressOperator fore[ground] foreign-key-hidden form-input form-long-input formatte[d] forward-only forward[s] fragmen[t] frame-spa[cing] frame-x +syn keyword ProgressOperator frame-y frequency from-cur[rent] full-height[-chars] full-height-p[ixels] full-pathn[ame] full-width[-chars] +syn keyword ProgressOperator full-width-p[ixels] function ge generate-pbe-key generate-pbe-salt generate-random-key generate-uuid get get-attribute get-attribute-node +syn keyword ProgressOperator get-binary-data get-bits get-blue[-value] get-browse-col[umn] get-buffer-handle get-byte-order get-bytes get-bytes-available +syn keyword ProgressOperator get-callback-proc-context get-callback-proc-name get-cgi-list get-cgi-long-value get-cgi-value get-changes get-child get-child-rel[ation] +syn keyword ProgressOperator get-config-value get-curr[ent] get-dataset-buffer get-dir get-document-element get-double get-dropped-file get-dynamic get-file +syn keyword ProgressOperator get-firs[t] get-float get-green[-value] get-header-entr[y] get-index-by-namespace-name get-index-by-qname get-iteration get-last +syn keyword ProgressOperator get-localname-by-index get-long get-message get-next get-node get-number get-parent get-pointer-value get-prev get-printers get-property +syn keyword ProgressOperator get-qname-by-index get-red[-value] get-rel[ation] get-repositioned-row get-rgb[-value] get-selected[-widget] get-serialized get-short +syn keyword ProgressOperator get-signature get-size get-socket-option get-source-buffer get-string get-tab-item get-text-height[-chars] get-text-height-p[ixels] +syn keyword ProgressOperator get-text-width[-chars] get-text-width-p[ixels] get-top-buffer get-type-by-index get-type-by-namespace-name get-type-by-qname +syn keyword ProgressOperator get-unsigned-long get-unsigned-short get-uri-by-index get-value-by-index get-value-by-namespace-name get-value-by-qname +syn keyword ProgressOperator get-wait[-state] grayed grid-factor-h[orizontal] grid-factor-v[ertical] grid-snap grid-unit-height[-chars] grid-unit-height-p[ixels] +syn keyword ProgressOperator grid-unit-width[-chars] grid-unit-width-p[ixels] grid-visible group-box gt guid handle handler has-lobs has-records height[-chars] +syn keyword ProgressOperator height-p[ixels] help-topic hex-decode hex-encode hidden hint hori[zontal] html-charset html-end-of-line html-end-of-page +syn keyword ProgressOperator html-frame-begin html-frame-end html-header-begin html-header-end html-title-begin html-title-end hwnd icfparam[eter] icon +syn keyword ProgressOperator ignore-current-mod[ified] image image-down image-insensitive image-size image-size-c[hars] image-size-p[ixels] image-up immediate-display +syn keyword ProgressOperator implements import-node import-principal in-handle increment-exclusive-id index-hint index-info[rmation] indexed-reposition +syn keyword ProgressOperator info[rmation] inherit-bgc[olor] inherit-fgc[olor] inherits init[ial] initial-dir initial-filter initialize-document-type initiate +syn keyword ProgressOperator inner inner-chars inner-lines input-value insert-attribute insert-b[acktab] insert-before insert-file insert-row +syn keyword ProgressOperator insert-string insert-t[ab] instantiating-procedure int[eger] interface internal-entries interval invoke is-clas[s] +syn keyword ProgressOperator is-codepage-fixed is-column-codepage is-lead-byte is-open is-parameter-set is-row-selected is-selected is-xml iso-date item +syn keyword ProgressOperator items-per-row join-by-sqldb keep-connection-open keep-frame-z[-order] keep-messages keep-security-cache keep-tab-order key +syn keyword ProgressOperator keyword-all label-bgc[olor] label-dc[olor] label-fgc[olor] label-font label-pfc[olor] labels landscape language[s] large +syn keyword ProgressOperator large-to-small last-async[-request] last-batch last-child last-form last-object last-proce[dure] last-serv[er] last-server-socket +syn keyword ProgressOperator last-socket last-tab-i[tem] lc le leading left left-align[ed] left-trim length line list-events list-item-pairs list-items +syn keyword ProgressOperator list-property-names list-query-attrs list-set-attrs list-widgets literal-question load load-domains load-icon load-image load-image-down +syn keyword ProgressOperator load-image-insensitive load-image-up load-mouse-p[ointer] load-picture load-small-icon lob-dir local-host local-name local-port +syn keyword ProgressOperator locator-column-number locator-line-number locator-public-id locator-system-id locator-type lock-registration log log-audit-event +syn keyword ProgressOperator log-entry-types log-threshold logfile-name logging-level logical login-expiration-timestamp login-host login-state logout long[char] +syn keyword ProgressOperator longchar-to-node-value lookahead lower lt mandatory manual-highlight margin-extra margin-height[-chars] margin-height-p[ixels] +syn keyword ProgressOperator margin-width[-chars] margin-width-p[ixels] mark-new mark-row-state matches max-button max-chars max-data-guess max-height[-chars] +syn keyword ProgressOperator max-height-p[ixels] max-rows max-size max-val[ue] max-width[-chars] max-width-p[ixels] maximize max[imum] maximum-level memory memptr +syn keyword ProgressOperator memptr-to-node-value menu menu-bar menu-item menu-k[ey] menu-m[ouse] menubar merge-by-field merge-changes merge-row-changes message-area +syn keyword ProgressOperator message-area-font method min-button min-column-width-c[hars] min-column-width-p[ixels] min-height[-chars] min-height-p[ixels] +syn keyword ProgressOperator min-schema-marshal min-size min-val[ue] min-width[-chars] min-width-p[ixels] min[imum] modified mod[ulo] month mouse-p[ointer] movable +syn keyword ProgressOperator move-after[-tab-item] move-befor[e-tab-item] move-col[umn] move-to-b[ottom] move-to-eof move-to-t[op] mtime multi-compile multiple +syn keyword ProgressOperator multiple-key multitasking-interval must-exist must-understand name namespace-prefix namespace-uri native ne needs-appserver-prompt +syn keyword ProgressOperator needs-prompt nested new-instance new-row next-col[umn] next-rowid next-sibling next-tab-ite[m] next-value no-apply +syn keyword ProgressOperator no-array-m[essage] no-assign no-attr-l[ist] no-auto-validate no-bind-where no-box no-console no-convert no-current-value no-debug +syn keyword ProgressOperator no-drag no-echo no-empty-space no-focus no-index-hint no-inherit-bgc[olor] no-inherit-fgc[olor] no-join-by-sqldb no-lookahead +syn keyword ProgressOperator no-row-markers no-schema-marshal no-scrollbar-v[ertical] no-separate-connection no-separators no-tab[-stop] no-und[erline] +syn keyword ProgressOperator no-word-wrap node-value node-value-to-longchar node-value-to-memptr nonamespace-schema-location none normalize not-active +syn keyword ProgressOperator num-buffers num-but[tons] num-child-relations num-children num-col[umns] num-copies num-dropped-files num-fields num-formats +syn keyword ProgressOperator num-header-entries num-items num-iterations num-lines num-locked-col[umns] num-log-files num-messages num-parameters num-references +syn keyword ProgressOperator num-relations num-repl[aced] num-results num-selected-rows num-selected[-widgets] num-source-buffers num-tabs num-to-retain +syn keyword ProgressOperator num-top-buffers num-visible-col[umns] numeric numeric-dec[imal-point] numeric-f[ormat] numeric-sep[arator] object ok ok-cancel +syn keyword ProgressOperator on-frame[-border] ordered-join ordinal orientation origin-handle origin-rowid os-getenv outer outer-join override owner owner-document +syn keyword ProgressOperator page-size page-wid[th] paged parent parent-buffer parent-rel[ation] parse-status partial-key pascal pathname +syn keyword ProgressOperator pbe-hash-alg[orithm] pbe-key-rounds perf[ormance] persistent-cache-disabled persistent-procedure pfc[olor] pixels-per-col[umn] +syn keyword ProgressOperator pixels-per-row popup-m[enu] popup-o[nly] portrait position precision prefer-dataset prepare-string prepared presel[ect] prev +syn keyword ProgressOperator prev-col[umn] prev-sibling prev-tab-i[tem] primary printer printer-control-handle printer-hdc printer-name printer-port +syn keyword ProgressOperator printer-setup private private-d[ata] proce[dure] procedure-name progress-s[ource] property protected proxy proxy-password +syn keyword ProgressOperator proxy-userid public public-id published-events put-bits put-bytes put-double put-float put-long put-short put-string +syn keyword ProgressOperator put-unsigned-long put-unsigned-short query-close query-off-end query-open query-prepare question quoter radio-buttons radio-set random +syn keyword ProgressOperator raw raw-transfer read read-file read-only read-xml read-xmlschema real recursive reference-only refresh +syn keyword ProgressOperator refresh-audit-policy refreshable register-domain reject-changes reject-row-changes rejected relation-fi[elds] relations-active remote +syn keyword ProgressOperator remote-host remote-port remove-attribute remove-child remove-events-proc[edure] remove-super-proc[edure] replace replace-child +syn keyword ProgressOperator replace-selection-text replication-create replication-delete replication-write reposition-back[ward] reposition-forw[ard] reposition-to-row +syn keyword ProgressOperator reposition-to-rowid request reset resiza[ble] resize restart-row restart-rowid result retain-s[hape] retry-cancel return-ins[erted] +syn keyword ProgressOperator return-to-start-di[r] return-value-data-type returns reverse-from rgb-v[alue] right right-align[ed] right-trim roles round rounded +syn keyword ProgressOperator routine-level row row-height[-chars] row-height-p[ixels] row-ma[rkers] row-of row-resizable row-state rowid rule run-proc[edure] +syn keyword ProgressOperator save-as save-file save-row-changes save-where-string sax-attributes sax-parse sax-parse-first sax-parse-next sax-reader +syn keyword ProgressOperator sax-writer schema-change schema-location schema-marshal schema-path screen-val[ue] scroll-bars scroll-delta scroll-offset +syn keyword ProgressOperator scroll-to-current-row scroll-to-i[tem] scroll-to-selected-row scrollable scrollbar-h[orizontal] scrollbar-v[ertical] +syn keyword ProgressOperator scrolled-row-pos[ition] scrolling seal seal-timestamp section select-all select-focused-row select-next-row select-prev-row select-row +syn keyword ProgressOperator selectable selected selection-end selection-list selection-start selection-text send sensitive separate-connection +syn keyword ProgressOperator separator-fgc[olor] separators server server-connection-bo[und] server-connection-bound-re[quest] server-connection-co[ntext] +syn keyword ProgressOperator server-connection-id server-operating-mode server-socket session-end session-id set-actor set-appl-context set-attribute +syn keyword ProgressOperator set-attribute-node set-blue[-value] set-break set-buffers set-byte-order set-callback set-callback-procedure set-client set-commit +syn keyword ProgressOperator set-connect-procedure set-contents set-db-client set-dynamic set-green[-value] set-input-source set-must-understand set-node +syn keyword ProgressOperator set-numeric-form[at] set-option set-output-destination set-parameter set-pointer-val[ue] set-property set-read-response-procedure +syn keyword ProgressOperator set-red[-value] set-repositioned-row set-rgb[-value] set-rollback set-selection set-serialized set-size set-socket-option +syn keyword ProgressOperator set-sort-arrow set-wait[-state] short show-in-task[bar] side-label-h[andle] side-lab[els] silent simple single single-character size +syn keyword ProgressOperator size-c[hars] size-p[ixels] skip-deleted-rec[ord] slider small-icon small-title smallint soap-fault soap-fault-actor +syn keyword ProgressOperator soap-fault-code soap-fault-detail soap-fault-string soap-header soap-header-entryref socket sort sort-ascending sort-number source +syn keyword ProgressOperator sql sqrt ssl-server-name standalone start-document start-element start[ing] startup-parameters state-detail static +syn keyword ProgressOperator status-area status-area-font stdcall stop stop-parsing stoppe[d] stored-proc[edure] stretch-to-fit strict string string-value +syn keyword ProgressOperator sub-ave[rage] sub-count sub-max[imum] sub-menu sub-menu-help sub-min[imum] sub-total subst[itute] substr[ing] subtype sum +syn keyword ProgressOperator super-proc[edures] suppress-namespace-processing suppress-w[arnings] suspend symmetric-encryption-algorithm symmetric-encryption-iv +syn keyword ProgressOperator symmetric-encryption-key symmetric-support synchronize system-alert[-boxes] system-help system-id tab-position tab-stop table-crc-list +syn keyword ProgressOperator table-list table-num[ber] target temp-dir[ectory] temp-table temp-table-prepar[e] terminate text-selected three-d through throw +syn keyword ProgressOperator thru tic-marks time-source timezone title-bgc[olor] title-dc[olor] title-fgc[olor] title-fo[nt] to-rowid toggle-box +syn keyword ProgressOperator tooltip tooltips top top-nav-query topic total tracking-changes trailing trans-init-proc[edure] transaction-mode +syn keyword ProgressOperator transpar[ent] trunc[ate] ttcodepage type type-of unbox unbuff[ered] unique-id unique-match unload unsigned-byte unsigned-integer +syn keyword ProgressOperator unsigned-long unsigned-short update-attribute upper url url-decode url-encode url-password url-userid use use-dic[t-exps] +syn keyword ProgressOperator use-filename use-text use-widget-pool user-id valid-event valid-handle valid-object validate validate-expressio[n] +syn keyword ProgressOperator validate-message validate-seal validate-xml validation-enabled var[iable] verb[ose] version vert[ical] view-first-column-on-reopen +syn keyword ProgressOperator virtual-height[-chars] virtual-height-p[ixels] virtual-width[-chars] virtual-width-p[ixels] visible void wait warning weekday where-string +syn keyword ProgressOperator widget widget-e[nter] widget-h[andle] widget-id widget-l[eave] widget-pool width[-chars] width-p[ixels] window-name +syn keyword ProgressOperator window-sta[te] window-sys[tem] word-index word-wrap work-area-height-p[ixels] work-area-width-p[ixels] work-area-x work-area-y +syn keyword ProgressOperator write-cdata write-characters write-comment write-data-element write-empty-element write-entity-ref write-external-dtd +syn keyword ProgressOperator write-fragment write-message write-processing-instruction write-status write-xml write-xmlschema x x-document x-noderef x-of +syn keyword ProgressOperator xml-data-type xml-node-name xml-node-type xml-schema-pat[h] xml-suppress-namespace-processing y y-of year year-offset yes-no +syn keyword ProgressOperator yes-no-cancel + +syn keyword ProgressType char[acter] int[eger] int64 dec[imal] log[ical] da[te] datetime datetime-tz + +syn sync lines=800 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later. +hi def link ProgressByte Number +hi def link ProgressCase Repeat +hi def link ProgressComment Comment +hi def link ProgressConditional Conditional +hi def link ProgressDebug Debug +hi def link ProgressDo Repeat +hi def link ProgressEndError Error +hi def link ProgressFor Repeat +hi def link ProgressFunction Procedure +hi def link ProgressIdentifier Identifier +hi def link ProgressInclude Include +hi def link ProgressMatrixDelimiter Identifier +hi def link ProgressNumber Number +hi def link ProgressOperator Operator +hi def link ProgressPreProc PreProc +hi def link ProgressProcedure Procedure +hi def link ProgressQuote Delimiter +hi def link ProgressRepeat Repeat +hi def link ProgressReserved Statement +hi def link ProgressSpaceError Error +hi def link ProgressString String +hi def link ProgressTodo Todo +hi def link ProgressType Statement +hi def link ProgressShowTab Error + + +let b:current_syntax = "progress" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 sw=8 + +endif diff --git a/syntax/prolog.vim b/syntax/prolog.vim new file mode 100644 index 0000000..4b86d60 --- /dev/null +++ b/syntax/prolog.vim @@ -0,0 +1,117 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: PROLOG +" Maintainer: Thomas Koehler +" Please be aware: I'm often slow to answer email due to a high +" non-computer related workload (sometimes 4-8 weeks) +" Last Change: 2016 September 6 +" URL: http://gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/vim/syntax/prolog.vim + +" There are two sets of highlighting in here: +" If the "prolog_highlighting_clean" variable exists, it is rather sparse. +" Otherwise you get more highlighting. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Prolog is case sensitive. +syn case match + +" Very simple highlighting for comments, clause heads and +" character codes. It respects prolog strings and atoms. + +syn region prologCComment start=+/\*+ end=+\*/+ +syn match prologComment +%.*+ + +syn keyword prologKeyword module meta_predicate multifile dynamic +syn match prologCharCode +0'\\\=.+ +syn region prologString start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn region prologAtom start=+'+ skip=+\\\\\|\\'+ end=+'+ +syn region prologClause matchgroup=prologClauseHead start=+^\s*[a-z]\w*+ matchgroup=Normal end=+\.\s\|\.$+ contains=ALLBUT,prologClause + +if !exists("prolog_highlighting_clean") + + " some keywords + " some common predicates are also highlighted as keywords + " is there a better solution? + syn keyword prologKeyword abolish current_output peek_code + syn keyword prologKeyword append current_predicate put_byte + syn keyword prologKeyword arg current_prolog_flag put_char + syn keyword prologKeyword asserta fail put_code + syn keyword prologKeyword assertz findall read + syn keyword prologKeyword at_end_of_stream float read_term + syn keyword prologKeyword atom flush_output repeat + syn keyword prologKeyword atom_chars functor retract + syn keyword prologKeyword atom_codes get_byte set_input + syn keyword prologKeyword atom_concat get_char set_output + syn keyword prologKeyword atom_length get_code set_prolog_flag + syn keyword prologKeyword atomic halt set_stream_position + syn keyword prologKeyword bagof integer setof + syn keyword prologKeyword call is stream_property + syn keyword prologKeyword catch nl sub_atom + syn keyword prologKeyword char_code nonvar throw + syn keyword prologKeyword char_conversion number true + syn keyword prologKeyword clause number_chars unify_with_occurs_check + syn keyword prologKeyword close number_codes var + syn keyword prologKeyword compound once write + syn keyword prologKeyword copy_term op write_canonical + syn keyword prologKeyword current_char_conversion open write_term + syn keyword prologKeyword current_input peek_byte writeq + syn keyword prologKeyword current_op peek_char + + syn match prologOperator "=\\=\|=:=\|\\==\|=<\|==\|>=\|\\=\|\\+\|<\|>\|=" + syn match prologAsIs "===\|\\===\|<=\|=>" + + syn match prologNumber "\<[0123456789]*\>'\@!" + syn match prologCommentError "\*/" + syn match prologSpecialCharacter ";" + syn match prologSpecialCharacter "!" + syn match prologSpecialCharacter ":-" + syn match prologSpecialCharacter "-->" + syn match prologQuestion "?-.*\." contains=prologNumber + + +endif + +syn sync maxlines=50 + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default highlighting. +hi def link prologComment Comment +hi def link prologCComment Comment +hi def link prologCharCode Special + +if exists ("prolog_highlighting_clean") + +hi def link prologKeyword Statement +hi def link prologClauseHead Statement +hi def link prologClause Normal + +else + +hi def link prologKeyword Keyword +hi def link prologClauseHead Constant +hi def link prologClause Normal +hi def link prologQuestion PreProc +hi def link prologSpecialCharacter Special +hi def link prologNumber Number +hi def link prologAsIs Normal +hi def link prologCommentError Error +hi def link prologAtom String +hi def link prologString String +hi def link prologOperator Operator + +endif + + +let b:current_syntax = "prolog" + +" vim: ts=8 + +endif diff --git a/syntax/promela.vim b/syntax/promela.vim new file mode 100644 index 0000000..f4a144b --- /dev/null +++ b/syntax/promela.vim @@ -0,0 +1,57 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: ProMeLa +" Maintainer: Maurizio Tranchero - +" First Release: Mon Oct 16 08:49:46 CEST 2006 +" Last Change: Thu Aug 7 21:22:48 CEST 2008 +" Version: 0.5 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" case is significant +" syn case ignore +" ProMeLa Keywords +syn keyword promelaStatement proctype if else while chan do od fi break goto unless +syn keyword promelaStatement active assert label atomic +syn keyword promelaFunctions skip timeout run +syn keyword promelaTodo contained TODO +" ProMeLa Types +syn keyword promelaType bit bool byte short int +" Operators and special characters +syn match promelaOperator "!" +syn match promelaOperator "?" +syn match promelaOperator "->" +syn match promelaOperator "=" +syn match promelaOperator "+" +syn match promelaOperator "*" +syn match promelaOperator "/" +syn match promelaOperator "-" +syn match promelaOperator "<" +syn match promelaOperator ">" +syn match promelaOperator "<=" +syn match promelaOperator ">=" +syn match promelaSpecial "\[" +syn match promelaSpecial "\]" +syn match promelaSpecial ";" +syn match promelaSpecial "::" +" ProMeLa Comments +syn region promelaComment start="/\*" end="\*/" contains=promelaTodo,@Spell +syn match promelaComment "//.*" contains=promelaTodo,@Spell + +" Class Linking +hi def link promelaStatement Statement +hi def link promelaType Type +hi def link promelaComment Comment +hi def link promelaOperator Type +hi def link promelaSpecial Special +hi def link promelaFunctions Special +hi def link promelaString String +hi def link promelaTodo Todo + +let b:current_syntax = "promela" + +endif diff --git a/syntax/proto.vim b/syntax/proto.vim index 1f7c3c1..fffd4e8 100644 --- a/syntax/proto.vim +++ b/syntax/proto.vim @@ -1,3 +1,80 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" syntax file for Protocol Buffers - Google's data interchange format +" +" Copyright 2008 Google Inc. All rights reserved. +" +" Permission is hereby granted, free of charge, to any person obtaining a copy +" of this software and associated documentation files (the "Software"), to deal +" in the Software without restriction, including without limitation the rights +" to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +" copies of the Software, and to permit persons to whom the Software is +" furnished to do so, subject to the following conditions: +" +" The above copyright notice and this permission notice shall be included in +" all copies or substantial portions of the Software. +" +" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +" AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +" OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +" THE SOFTWARE. +" +" http://code.google.com/p/protobuf/ + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +syn keyword protoTodo contained TODO FIXME XXX +syn cluster protoCommentGrp contains=protoTodo + +syn keyword protoSyntax syntax import option +syn keyword protoStructure package message group +syn keyword protoRepeat optional required repeated +syn keyword protoDefault default +syn keyword protoExtend extend extensions to max +syn keyword protoRPC service rpc returns + +syn keyword protoType int32 int64 uint32 uint64 sint32 sint64 +syn keyword protoType fixed32 fixed64 sfixed32 sfixed64 +syn keyword protoType float double bool string bytes +syn keyword protoTypedef enum +syn keyword protoBool true false + +syn match protoInt /-\?\<\d\+\>/ +syn match protoInt /\<0[xX]\x+\>/ +syn match protoFloat /\<-\?\d*\(\.\d*\)\?/ +syn region protoComment start="\/\*" end="\*\/" contains=@protoCommentGrp +syn region protoComment start="//" skip="\\$" end="$" keepend contains=@protoCommentGrp +syn region protoString start=/"/ skip=/\\./ end=/"/ +syn region protoString start=/'/ skip=/\\./ end=/'/ + +hi def link protoTodo Todo + +hi def link protoSyntax Include +hi def link protoStructure Structure +hi def link protoRepeat Repeat +hi def link protoDefault Keyword +hi def link protoExtend Keyword +hi def link protoRPC Keyword +hi def link protoType Type +hi def link protoTypedef Typedef +hi def link protoBool Boolean + +hi def link protoInt Number +hi def link protoFloat Float +hi def link protoComment Comment +hi def link protoString String + +let b:current_syntax = "proto" + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'protobuf') == -1 " Protocol Buffers - Google's data interchange format diff --git a/syntax/protocols.vim b/syntax/protocols.vim new file mode 100644 index 0000000..fd36cd9 --- /dev/null +++ b/syntax/protocols.vim @@ -0,0 +1,48 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: protocols(5) - Internet protocols definition file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match protocolsBegin display '^' + \ nextgroup=protocolsName,protocolsComment + +syn match protocolsName contained display '[[:graph:]]\+' + \ nextgroup=protocolsPort skipwhite + +syn match protocolsPort contained display '\d\+' + \ nextgroup=protocolsAliases,protocolsComment + \ skipwhite + +syn match protocolsAliases contained display '\S\+' + \ nextgroup=protocolsAliases,protocolsComment + \ skipwhite + +syn keyword protocolsTodo contained TODO FIXME XXX NOTE + +syn region protocolsComment display oneline start='#' end='$' + \ contains=protocolsTodo,@Spell + +hi def link protocolsTodo Todo +hi def link protocolsComment Comment +hi def link protocolsName Identifier +hi def link protocolsPort Number +hi def link protocolsPPDiv Delimiter +hi def link protocolsPPDivDepr Error +hi def link protocolsProtocol Type +hi def link protocolsAliases Macro + +let b:current_syntax = "protocols" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/psf.vim b/syntax/psf.vim new file mode 100644 index 0000000..015cada --- /dev/null +++ b/syntax/psf.vim @@ -0,0 +1,95 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Software Distributor product specification file +" (POSIX 1387.2-1995). +" Maintainer: Rex Barzee +" Last change: 25 Apr 2001 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Product specification files are case sensitive +syn case match + +syn keyword psfObject bundle category control_file depot distribution +syn keyword psfObject end file fileset host installed_software media +syn keyword psfObject product root subproduct vendor + +syn match psfUnquotString +[^"# ][^#]*+ contained +syn region psfQuotString start=+"+ skip=+\\"+ end=+"+ contained + +syn match psfObjTag "\<[-_+A-Z0-9a-z]\+\(\.[-_+A-Z0-9a-z]\+\)*" contained +syn match psfAttAbbrev ",\<\(fa\|fr\|[aclqrv]\)\(<\|>\|<=\|>=\|=\|==\)[^,]\+" contained +syn match psfObjTags "\<[-_+A-Z0-9a-z]\+\(\.[-_+A-Z0-9a-z]\+\)*\(\s\+\<[-_+A-Z0-9a-z]\+\(\.[-_+A-Z0-9a-z]\+\)*\)*" contained + +syn match psfNumber "\<\d\+\>" contained +syn match psfFloat "\<\d\+\>\(\.\<\d\+\>\)*" contained + +syn match psfLongDate "\<\d\d\d\d\d\d\d\d\d\d\d\d\.\d\d\>" contained + +syn keyword psfState available configured corrupt installed transient contained +syn keyword psfPState applied committed superseded contained + +syn keyword psfBoolean false true contained + + +"Some of the attributes covered by attUnquotString and attQuotString: +" architecture category_tag control_directory copyright +" create_date description directory file_permissions install_source +" install_type location machine_type mod_date number os_name os_release +" os_version pose_as_os_name pose_as_os_release readme revision +" share_link title vendor_tag +syn region psfAttUnquotString matchgroup=psfAttrib start=~^\s*[^# ]\+\s\+[^#" ]~rs=e-1 contains=psfUnquotString,psfComment end=~$~ keepend oneline + +syn region psfAttQuotString matchgroup=psfAttrib start=~^\s*[^# ]\+\s\+"~rs=e-1 contains=psfQuotString,psfComment skip=~\\"~ matchgroup=psfQuotString end=~"~ keepend + + +" These regions are defined in attempt to do syntax checking for some +" of the attributes. +syn region psfAttTag matchgroup=psfAttrib start="^\s*tag\s\+" contains=psfObjTag,psfComment end="$" keepend oneline + +syn region psfAttSpec matchgroup=psfAttrib start="^\s*\(ancestor\|applied_patches\|applied_to\|contents\|corequisites\|exrequisites\|prerequisites\|software_spec\|supersedes\|superseded_by\)\s\+" contains=psfObjTag,psfAttAbbrev,psfComment end="$" keepend + +syn region psfAttTags matchgroup=psfAttrib start="^\s*all_filesets\s\+" contains=psfObjTags,psfComment end="$" keepend + +syn region psfAttNumber matchgroup=psfAttrib start="^\s*\(compressed_size\|instance_id\|media_sequence_number\|sequence_number\|size\)\s\+" contains=psfNumber,psfComment end="$" keepend oneline + +syn region psfAttTime matchgroup=psfAttrib start="^\s*\(create_time\|ctime\|mod_time\|mtime\|timestamp\)\s\+" contains=psfNumber,psfComment end="$" keepend oneline + +syn region psfAttFloat matchgroup=psfAttrib start="^\s*\(data_model_revision\|layout_version\)\s\+" contains=psfFloat,psfComment end="$" keepend oneline + +syn region psfAttLongDate matchgroup=psfAttrib start="^\s*install_date\s\+" contains=psfLongDate,psfComment end="$" keepend oneline + +syn region psfAttState matchgroup=psfAttrib start="^\s*\(state\)\s\+" contains=psfState,psfComment end="$" keepend oneline + +syn region psfAttPState matchgroup=psfAttrib start="^\s*\(patch_state\)\s\+" contains=psfPState,psfComment end="$" keepend oneline + +syn region psfAttBoolean matchgroup=psfAttrib start="^\s*\(is_kernel\|is_locatable\|is_patch\|is_protected\|is_reboot\|is_reference\|is_secure\|is_sparse\)\s\+" contains=psfBoolean,psfComment end="$" keepend oneline + +syn match psfComment "#.*$" + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link psfObject Statement +hi def link psfAttrib Type +hi def link psfQuotString String +hi def link psfObjTag Identifier +hi def link psfAttAbbrev PreProc +hi def link psfObjTags Identifier + +hi def link psfComment Comment + + +" Long descriptions and copyrights confuse the syntax highlighting, so +" force vim to backup at least 100 lines before the top visible line +" looking for a sync location. +syn sync lines=100 + +let b:current_syntax = "psf" + +endif diff --git a/syntax/ptcap.vim b/syntax/ptcap.vim new file mode 100644 index 0000000..df30924 --- /dev/null +++ b/syntax/ptcap.vim @@ -0,0 +1,99 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: printcap/termcap database +" Maintainer: Haakon Riiser +" URL: http://folk.uio.no/hakonrk/vim/syntax/ptcap.vim +" Last Change: 2001 May 15 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Since I only highlight based on the structure of the databases, not +" specific keywords, case sensitivity isn't required +syn case ignore + +" Since everything that is not caught by the syntax patterns is assumed +" to be an error, we start parsing 20 lines up, unless something else +" is specified +if exists("ptcap_minlines") + exe "syn sync lines=".ptcap_minlines +else + syn sync lines=20 +endif + +" Highlight everything that isn't caught by the rules as errors, +" except blank lines +syn match ptcapError "^.*\S.*$" + +syn match ptcapLeadBlank "^\s\+" contained + +" `:' and `|' are delimiters for fields and names, and should not be +" highlighted. Hence, they are linked to `NONE' +syn match ptcapDelimiter "[:|]" contained + +" Escaped characters receive special highlighting +syn match ptcapEscapedChar "\\." contained +syn match ptcapEscapedChar "\^." contained +syn match ptcapEscapedChar "\\\o\{3}" contained + +" A backslash at the end of a line will suppress the newline +syn match ptcapLineCont "\\$" contained + +" A number follows the same rules as an integer in C +syn match ptcapNumber "#\(+\|-\)\=\d\+"lc=1 contained +syn match ptcapNumberError "#\d*[^[:digit:]:\\]"lc=1 contained +syn match ptcapNumber "#0x\x\{1,8}"lc=1 contained +syn match ptcapNumberError "#0x\X"me=e-1,lc=1 contained +syn match ptcapNumberError "#0x\x\{9}"lc=1 contained +syn match ptcapNumberError "#0x\x*[^[:xdigit:]:\\]"lc=1 contained + +" The `@' operator clears a flag (i.e., sets it to zero) +" The `#' operator assigns a following number to the flag +" The `=' operator assigns a string to the preceding flag +syn match ptcapOperator "[@#=]" contained + +" Some terminal capabilites have special names like `#5' and `@1', and we +" need special rules to match these properly +syn match ptcapSpecialCap "\W[#@]\d" contains=ptcapDelimiter contained + +" If editing a termcap file, an entry in the database is terminated by +" a (non-escaped) newline. Otherwise, it is terminated by a line which +" does not start with a colon (:) +if exists("b:ptcap_type") && b:ptcap_type[0] == 't' + syn region ptcapEntry start="^\s*[^[:space:]:]" end="[^\\]\(\\\\\)*$" end="^$" contains=ptcapNames,ptcapField,ptcapLeadBlank keepend +else + syn region ptcapEntry start="^\s*[^[:space:]:]"me=e-1 end="^\s*[^[:space:]:#]"me=e-1 contains=ptcapNames,ptcapField,ptcapLeadBlank,ptcapComment +endif +syn region ptcapNames start="^\s*[^[:space:]:]" skip="[^\\]\(\\\\\)*\\:" end=":"me=e-1 contains=ptcapDelimiter,ptcapEscapedChar,ptcapLineCont,ptcapLeadBlank,ptcapComment keepend contained +syn region ptcapField start=":" skip="[^\\]\(\\\\\)*\\$" end="[^\\]\(\\\\\)*:"me=e-1 end="$" contains=ptcapDelimiter,ptcapString,ptcapNumber,ptcapNumberError,ptcapOperator,ptcapLineCont,ptcapSpecialCap,ptcapLeadBlank,ptcapComment keepend contained +syn region ptcapString matchgroup=ptcapOperator start="=" skip="[^\\]\(\\\\\)*\\:" matchgroup=ptcapDelimiter end=":"me=e-1 matchgroup=NONE end="[^\\]\(\\\\\)*[^\\]$" end="^$" contains=ptcapEscapedChar,ptcapLineCont keepend contained +syn region ptcapComment start="^\s*#" end="$" contains=ptcapLeadBlank + + +hi def link ptcapComment Comment +hi def link ptcapDelimiter Delimiter +" The highlighting of "ptcapEntry" should always be overridden by +" its contents, so I use Todo highlighting to indicate that there +" is work to be done with the syntax file if you can see it :-) +hi def link ptcapEntry Todo +hi def link ptcapError Error +hi def link ptcapEscapedChar SpecialChar +hi def link ptcapField Type +hi def link ptcapLeadBlank NONE +hi def link ptcapLineCont Special +hi def link ptcapNames Label +hi def link ptcapNumber NONE +hi def link ptcapNumberError Error +hi def link ptcapOperator Operator +hi def link ptcapSpecialCap Type +hi def link ptcapString NONE + + +let b:current_syntax = "ptcap" + +" vim: sts=4 sw=4 ts=8 + +endif diff --git a/syntax/purifylog.vim b/syntax/purifylog.vim new file mode 100644 index 0000000..2a5d804 --- /dev/null +++ b/syntax/purifylog.vim @@ -0,0 +1,110 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: purify log files +" Maintainer: Gautam H. Mudunuri +" Last Change: 2003 May 11 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Purify header +syn match purifyLogHeader "^\*\*\*\*.*$" + +" Informational messages +syn match purifyLogFIU "^FIU:.*$" +syn match purifyLogMAF "^MAF:.*$" +syn match purifyLogMIU "^MIU:.*$" +syn match purifyLogSIG "^SIG:.*$" +syn match purifyLogWPF "^WPF:.*$" +syn match purifyLogWPM "^WPM:.*$" +syn match purifyLogWPN "^WPN:.*$" +syn match purifyLogWPR "^WPR:.*$" +syn match purifyLogWPW "^WPW:.*$" +syn match purifyLogWPX "^WPX:.*$" + +" Warning messages +syn match purifyLogABR "^ABR:.*$" +syn match purifyLogBSR "^BSR:.*$" +syn match purifyLogBSW "^BSW:.*$" +syn match purifyLogFMR "^FMR:.*$" +syn match purifyLogMLK "^MLK:.*$" +syn match purifyLogMSE "^MSE:.*$" +syn match purifyLogPAR "^PAR:.*$" +syn match purifyLogPLK "^PLK:.*$" +syn match purifyLogSBR "^SBR:.*$" +syn match purifyLogSOF "^SOF:.*$" +syn match purifyLogUMC "^UMC:.*$" +syn match purifyLogUMR "^UMR:.*$" + +" Corrupting messages +syn match purifyLogABW "^ABW:.*$" +syn match purifyLogBRK "^BRK:.*$" +syn match purifyLogFMW "^FMW:.*$" +syn match purifyLogFNH "^FNH:.*$" +syn match purifyLogFUM "^FUM:.*$" +syn match purifyLogMRE "^MRE:.*$" +syn match purifyLogSBW "^SBW:.*$" + +" Fatal messages +syn match purifyLogCOR "^COR:.*$" +syn match purifyLogNPR "^NPR:.*$" +syn match purifyLogNPW "^NPW:.*$" +syn match purifyLogZPR "^ZPR:.*$" +syn match purifyLogZPW "^ZPW:.*$" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link purifyLogFIU purifyLogInformational +hi def link purifyLogMAF purifyLogInformational +hi def link purifyLogMIU purifyLogInformational +hi def link purifyLogSIG purifyLogInformational +hi def link purifyLogWPF purifyLogInformational +hi def link purifyLogWPM purifyLogInformational +hi def link purifyLogWPN purifyLogInformational +hi def link purifyLogWPR purifyLogInformational +hi def link purifyLogWPW purifyLogInformational +hi def link purifyLogWPX purifyLogInformational + +hi def link purifyLogABR purifyLogWarning +hi def link purifyLogBSR purifyLogWarning +hi def link purifyLogBSW purifyLogWarning +hi def link purifyLogFMR purifyLogWarning +hi def link purifyLogMLK purifyLogWarning +hi def link purifyLogMSE purifyLogWarning +hi def link purifyLogPAR purifyLogWarning +hi def link purifyLogPLK purifyLogWarning +hi def link purifyLogSBR purifyLogWarning +hi def link purifyLogSOF purifyLogWarning +hi def link purifyLogUMC purifyLogWarning +hi def link purifyLogUMR purifyLogWarning + +hi def link purifyLogABW purifyLogCorrupting +hi def link purifyLogBRK purifyLogCorrupting +hi def link purifyLogFMW purifyLogCorrupting +hi def link purifyLogFNH purifyLogCorrupting +hi def link purifyLogFUM purifyLogCorrupting +hi def link purifyLogMRE purifyLogCorrupting +hi def link purifyLogSBW purifyLogCorrupting + +hi def link purifyLogCOR purifyLogFatal +hi def link purifyLogNPR purifyLogFatal +hi def link purifyLogNPW purifyLogFatal +hi def link purifyLogZPR purifyLogFatal +hi def link purifyLogZPW purifyLogFatal + +hi def link purifyLogHeader Comment +hi def link purifyLogInformational PreProc +hi def link purifyLogWarning Type +hi def link purifyLogCorrupting Error +hi def link purifyLogFatal Error + + +let b:current_syntax = "purifylog" + +" vim:ts=8 + +endif diff --git a/syntax/pyrex.vim b/syntax/pyrex.vim new file mode 100644 index 0000000..93e4066 --- /dev/null +++ b/syntax/pyrex.vim @@ -0,0 +1,55 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Pyrex +" Maintainer: Marco Barisione +" URL: http://marcobari.altervista.org/pyrex_vim.html +" Last Change: 2009 Nov 09 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read the Python syntax to start with +runtime! syntax/python.vim +unlet b:current_syntax + +" Pyrex extentions +syn keyword pyrexStatement cdef typedef ctypedef sizeof +syn keyword pyrexType int long short float double char object void +syn keyword pyrexType signed unsigned +syn keyword pyrexStructure struct union enum +syn keyword pyrexInclude include cimport +syn keyword pyrexAccess public private property readonly extern +" If someome wants Python's built-ins highlighted probably he +" also wants Pyrex's built-ins highlighted +if exists("python_highlight_builtins") || exists("pyrex_highlight_builtins") + syn keyword pyrexBuiltin NULL +endif + +" This deletes "from" from the keywords and re-adds it as a +" match with lower priority than pyrexForFrom +syn clear pythonInclude +syn keyword pythonInclude import +syn match pythonInclude "from" + +" With "for[^:]*\zsfrom" VIM does not match "for" anymore, so +" I used the slower "\@<=" form +syn match pyrexForFrom "\(for[^:]*\)\@<=from" + +" Default highlighting +hi def link pyrexStatement Statement +hi def link pyrexType Type +hi def link pyrexStructure Structure +hi def link pyrexInclude PreCondit +hi def link pyrexAccess pyrexStatement +if exists("python_highlight_builtins") || exists("pyrex_highlight_builtins") +hi def link pyrexBuiltin Function +endif +hi def link pyrexForFrom Statement + + +let b:current_syntax = "pyrex" + +endif diff --git a/syntax/python.vim b/syntax/python.vim index 55f20a3..83d3528 100644 --- a/syntax/python.vim +++ b/syntax/python.vim @@ -1,3 +1,346 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Python +" Maintainer: Zvezdan Petkovic +" Last Change: 2016 Oct 29 +" Credits: Neil Schemenauer +" Dmitry Vasiliev +" +" This version is a major rewrite by Zvezdan Petkovic. +" +" - introduced highlighting of doctests +" - updated keywords, built-ins, and exceptions +" - corrected regular expressions for +" +" * functions +" * decorators +" * strings +" * escapes +" * numbers +" * space error +" +" - corrected synchronization +" - more highlighting is ON by default, except +" - space error highlighting is OFF by default +" +" Optional highlighting can be controlled using these variables. +" +" let python_no_builtin_highlight = 1 +" let python_no_doctest_code_highlight = 1 +" let python_no_doctest_highlight = 1 +" let python_no_exception_highlight = 1 +" let python_no_number_highlight = 1 +" let python_space_error_highlight = 1 +" +" All the options above can be switched on together. +" +" let python_highlight_all = 1 +" + +" quit when a syntax file was already loaded. +if exists("b:current_syntax") + finish +endif + +" We need nocompatible mode in order to continue lines with backslashes. +" Original setting will be restored. +let s:cpo_save = &cpo +set cpo&vim + +if exists("python_no_doctest_highlight") + let python_no_doctest_code_highlight = 1 +endif + +if exists("python_highlight_all") + if exists("python_no_builtin_highlight") + unlet python_no_builtin_highlight + endif + if exists("python_no_doctest_code_highlight") + unlet python_no_doctest_code_highlight + endif + if exists("python_no_doctest_highlight") + unlet python_no_doctest_highlight + endif + if exists("python_no_exception_highlight") + unlet python_no_exception_highlight + endif + if exists("python_no_number_highlight") + unlet python_no_number_highlight + endif + let python_space_error_highlight = 1 +endif + +" Keep Python keywords in alphabetical order inside groups for easy +" comparison with the table in the 'Python Language Reference' +" https://docs.python.org/2/reference/lexical_analysis.html#keywords, +" https://docs.python.org/3/reference/lexical_analysis.html#keywords. +" Groups are in the order presented in NAMING CONVENTIONS in syntax.txt. +" Exceptions come last at the end of each group (class and def below). +" +" Keywords 'with' and 'as' are new in Python 2.6 +" (use 'from __future__ import with_statement' in Python 2.5). +" +" Some compromises had to be made to support both Python 3 and 2. +" We include Python 3 features, but when a definition is duplicated, +" the last definition takes precedence. +" +" - 'False', 'None', and 'True' are keywords in Python 3 but they are +" built-ins in 2 and will be highlighted as built-ins below. +" - 'exec' is a built-in in Python 3 and will be highlighted as +" built-in below. +" - 'nonlocal' is a keyword in Python 3 and will be highlighted. +" - 'print' is a built-in in Python 3 and will be highlighted as +" built-in below (use 'from __future__ import print_function' in 2) +" - async and await were added in Python 3.5 and are soft keywords. +" +syn keyword pythonStatement False None True +syn keyword pythonStatement as assert break continue del exec global +syn keyword pythonStatement lambda nonlocal pass print return with yield +syn keyword pythonStatement class def nextgroup=pythonFunction skipwhite +syn keyword pythonConditional elif else if +syn keyword pythonRepeat for while +syn keyword pythonOperator and in is not or +syn keyword pythonException except finally raise try +syn keyword pythonInclude from import +syn keyword pythonAsync async await + +" Decorators (new in Python 2.4) +" A dot must be allowed because of @MyClass.myfunc decorators. +syn match pythonDecorator "@" display contained +syn match pythonDecoratorName "@\s*\h\%(\w\|\.\)*" display contains=pythonDecorator + +" Python 3.5 introduced the use of the same symbol for matrix multiplication: +" https://www.python.org/dev/peps/pep-0465/. We now have to exclude the +" symbol from highlighting when used in that context. +" Single line multiplication. +syn match pythonMatrixMultiply + \ "\%(\w\|[])]\)\s*@" + \ contains=ALLBUT,pythonDecoratorName,pythonDecorator,pythonFunction,pythonDoctestValue + \ transparent +" Multiplication continued on the next line after backslash. +syn match pythonMatrixMultiply + \ "[^\\]\\\s*\n\%(\s*\.\.\.\s\)\=\s\+@" + \ contains=ALLBUT,pythonDecoratorName,pythonDecorator,pythonFunction,pythonDoctestValue + \ transparent +" Multiplication in a parenthesized expression over multiple lines with @ at +" the start of each continued line; very similar to decorators and complex. +syn match pythonMatrixMultiply + \ "^\s*\%(\%(>>>\|\.\.\.\)\s\+\)\=\zs\%(\h\|\%(\h\|[[(]\).\{-}\%(\w\|[])]\)\)\s*\n\%(\s*\.\.\.\s\)\=\s\+@\%(.\{-}\n\%(\s*\.\.\.\s\)\=\s\+@\)*" + \ contains=ALLBUT,pythonDecoratorName,pythonDecorator,pythonFunction,pythonDoctestValue + \ transparent + +syn match pythonFunction "\h\w*" display contained + +syn match pythonComment "#.*$" contains=pythonTodo,@Spell +syn keyword pythonTodo FIXME NOTE NOTES TODO XXX contained + +" Triple-quoted strings can contain doctests. +syn region pythonString matchgroup=pythonQuotes + \ start=+[uU]\=\z(['"]\)+ end="\z1" skip="\\\\\|\\\z1" + \ contains=pythonEscape,@Spell +syn region pythonString matchgroup=pythonTripleQuotes + \ start=+[uU]\=\z('''\|"""\)+ end="\z1" keepend + \ contains=pythonEscape,pythonSpaceError,pythonDoctest,@Spell +syn region pythonRawString matchgroup=pythonQuotes + \ start=+[uU]\=[rR]\z(['"]\)+ end="\z1" skip="\\\\\|\\\z1" + \ contains=@Spell +syn region pythonRawString matchgroup=pythonTripleQuotes + \ start=+[uU]\=[rR]\z('''\|"""\)+ end="\z1" keepend + \ contains=pythonSpaceError,pythonDoctest,@Spell + +syn match pythonEscape +\\[abfnrtv'"\\]+ contained +syn match pythonEscape "\\\o\{1,3}" contained +syn match pythonEscape "\\x\x\{2}" contained +syn match pythonEscape "\%(\\u\x\{4}\|\\U\x\{8}\)" contained +" Python allows case-insensitive Unicode IDs: http://www.unicode.org/charts/ +syn match pythonEscape "\\N{\a\+\%(\s\a\+\)*}" contained +syn match pythonEscape "\\$" + +" It is very important to understand all details before changing the +" regular expressions below or their order. +" The word boundaries are *not* the floating-point number boundaries +" because of a possible leading or trailing decimal point. +" The expressions below ensure that all valid number literals are +" highlighted, and invalid number literals are not. For example, +" +" - a decimal point in '4.' at the end of a line is highlighted, +" - a second dot in 1.0.0 is not highlighted, +" - 08 is not highlighted, +" - 08e0 or 08j are highlighted, +" +" and so on, as specified in the 'Python Language Reference'. +" https://docs.python.org/2/reference/lexical_analysis.html#numeric-literals +" https://docs.python.org/3/reference/lexical_analysis.html#numeric-literals +if !exists("python_no_number_highlight") + " numbers (including longs and complex) + syn match pythonNumber "\<0[oO]\=\o\+[Ll]\=\>" + syn match pythonNumber "\<0[xX]\x\+[Ll]\=\>" + syn match pythonNumber "\<0[bB][01]\+[Ll]\=\>" + syn match pythonNumber "\<\%([1-9]\d*\|0\)[Ll]\=\>" + syn match pythonNumber "\<\d\+[jJ]\>" + syn match pythonNumber "\<\d\+[eE][+-]\=\d\+[jJ]\=\>" + syn match pythonNumber + \ "\<\d\+\.\%([eE][+-]\=\d\+\)\=[jJ]\=\%(\W\|$\)\@=" + syn match pythonNumber + \ "\%(^\|\W\)\zs\d*\.\d\+\%([eE][+-]\=\d\+\)\=[jJ]\=\>" +endif + +" Group the built-ins in the order in the 'Python Library Reference' for +" easier comparison. +" https://docs.python.org/2/library/constants.html +" https://docs.python.org/3/library/constants.html +" http://docs.python.org/2/library/functions.html +" http://docs.python.org/3/library/functions.html +" http://docs.python.org/2/library/functions.html#non-essential-built-in-functions +" http://docs.python.org/3/library/functions.html#non-essential-built-in-functions +" Python built-in functions are in alphabetical order. +if !exists("python_no_builtin_highlight") + " built-in constants + " 'False', 'True', and 'None' are also reserved words in Python 3 + syn keyword pythonBuiltin False True None + syn keyword pythonBuiltin NotImplemented Ellipsis __debug__ + " built-in functions + syn keyword pythonBuiltin abs all any bin bool bytearray callable chr + syn keyword pythonBuiltin classmethod compile complex delattr dict dir + syn keyword pythonBuiltin divmod enumerate eval filter float format + syn keyword pythonBuiltin frozenset getattr globals hasattr hash + syn keyword pythonBuiltin help hex id input int isinstance + syn keyword pythonBuiltin issubclass iter len list locals map max + syn keyword pythonBuiltin memoryview min next object oct open ord pow + syn keyword pythonBuiltin print property range repr reversed round set + syn keyword pythonBuiltin setattr slice sorted staticmethod str + syn keyword pythonBuiltin sum super tuple type vars zip __import__ + " Python 2 only + syn keyword pythonBuiltin basestring cmp execfile file + syn keyword pythonBuiltin long raw_input reduce reload unichr + syn keyword pythonBuiltin unicode xrange + " Python 3 only + syn keyword pythonBuiltin ascii bytes exec + " non-essential built-in functions; Python 2 only + syn keyword pythonBuiltin apply buffer coerce intern + " avoid highlighting attributes as builtins + syn match pythonAttribute /\.\h\w*/hs=s+1 + \ contains=ALLBUT,pythonBuiltin,pythonFunction,pythonAsync + \ transparent +endif + +" From the 'Python Library Reference' class hierarchy at the bottom. +" http://docs.python.org/2/library/exceptions.html +" http://docs.python.org/3/library/exceptions.html +if !exists("python_no_exception_highlight") + " builtin base exceptions (used mostly as base classes for other exceptions) + syn keyword pythonExceptions BaseException Exception + syn keyword pythonExceptions ArithmeticError BufferError + syn keyword pythonExceptions LookupError + " builtin base exceptions removed in Python 3 + syn keyword pythonExceptions EnvironmentError StandardError + " builtin exceptions (actually raised) + syn keyword pythonExceptions AssertionError AttributeError + syn keyword pythonExceptions EOFError FloatingPointError GeneratorExit + syn keyword pythonExceptions ImportError IndentationError + syn keyword pythonExceptions IndexError KeyError KeyboardInterrupt + syn keyword pythonExceptions MemoryError NameError NotImplementedError + syn keyword pythonExceptions OSError OverflowError ReferenceError + syn keyword pythonExceptions RuntimeError StopIteration SyntaxError + syn keyword pythonExceptions SystemError SystemExit TabError TypeError + syn keyword pythonExceptions UnboundLocalError UnicodeError + syn keyword pythonExceptions UnicodeDecodeError UnicodeEncodeError + syn keyword pythonExceptions UnicodeTranslateError ValueError + syn keyword pythonExceptions ZeroDivisionError + " builtin OS exceptions in Python 3 + syn keyword pythonExceptions BlockingIOError BrokenPipeError + syn keyword pythonExceptions ChildProcessError ConnectionAbortedError + syn keyword pythonExceptions ConnectionError ConnectionRefusedError + syn keyword pythonExceptions ConnectionResetError FileExistsError + syn keyword pythonExceptions FileNotFoundError InterruptedError + syn keyword pythonExceptions IsADirectoryError NotADirectoryError + syn keyword pythonExceptions PermissionError ProcessLookupError + syn keyword pythonExceptions RecursionError StopAsyncIteration + syn keyword pythonExceptions TimeoutError + " builtin exceptions deprecated/removed in Python 3 + syn keyword pythonExceptions IOError VMSError WindowsError + " builtin warnings + syn keyword pythonExceptions BytesWarning DeprecationWarning FutureWarning + syn keyword pythonExceptions ImportWarning PendingDeprecationWarning + syn keyword pythonExceptions RuntimeWarning SyntaxWarning UnicodeWarning + syn keyword pythonExceptions UserWarning Warning + " builtin warnings in Python 3 + syn keyword pythonExceptions ResourceWarning +endif + +if exists("python_space_error_highlight") + " trailing whitespace + syn match pythonSpaceError display excludenl "\s\+$" + " mixed tabs and spaces + syn match pythonSpaceError display " \+\t" + syn match pythonSpaceError display "\t\+ " +endif + +" Do not spell doctests inside strings. +" Notice that the end of a string, either ''', or """, will end the contained +" doctest too. Thus, we do *not* need to have it as an end pattern. +if !exists("python_no_doctest_highlight") + if !exists("python_no_doctest_code_highlight") + syn region pythonDoctest + \ start="^\s*>>>\s" end="^\s*$" + \ contained contains=ALLBUT,pythonDoctest,pythonFunction,@Spell + syn region pythonDoctestValue + \ start=+^\s*\%(>>>\s\|\.\.\.\s\|"""\|'''\)\@!\S\++ end="$" + \ contained + else + syn region pythonDoctest + \ start="^\s*>>>" end="^\s*$" + \ contained contains=@NoSpell + endif +endif + +" Sync at the beginning of class, function, or method definition. +syn sync match pythonSync grouphere NONE "^\%(def\|class\)\s\+\h\w*\s*[(:]" + +" The default highlight links. Can be overridden later. +hi def link pythonStatement Statement +hi def link pythonConditional Conditional +hi def link pythonRepeat Repeat +hi def link pythonOperator Operator +hi def link pythonException Exception +hi def link pythonInclude Include +hi def link pythonAsync Statement +hi def link pythonDecorator Define +hi def link pythonDecoratorName Function +hi def link pythonFunction Function +hi def link pythonComment Comment +hi def link pythonTodo Todo +hi def link pythonString String +hi def link pythonRawString String +hi def link pythonQuotes String +hi def link pythonTripleQuotes pythonQuotes +hi def link pythonEscape Special +if !exists("python_no_number_highlight") + hi def link pythonNumber Number +endif +if !exists("python_no_builtin_highlight") + hi def link pythonBuiltin Function +endif +if !exists("python_no_exception_highlight") + hi def link pythonExceptions Structure +endif +if exists("python_space_error_highlight") + hi def link pythonSpaceError Error +endif +if !exists("python_no_doctest_highlight") + hi def link pythonDoctest Special + hi def link pythonDoctestValue Define +endif + +let b:current_syntax = "python" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim:set sw=2 sts=2 ts=8 noet: + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'python') == -1 " Vim syntax file diff --git a/syntax/qf.vim b/syntax/qf.vim new file mode 100644 index 0000000..5348ed0 --- /dev/null +++ b/syntax/qf.vim @@ -0,0 +1,28 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Quickfix window +" Maintainer: Bram Moolenaar +" Last change: 2001 Jan 15 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful C keywords +syn match qfFileName "^[^|]*" nextgroup=qfSeparator +syn match qfSeparator "|" nextgroup=qfLineNr contained +syn match qfLineNr "[^|]*" contained contains=qfError +syn match qfError "error" contained + +" The default highlighting. +hi def link qfFileName Directory +hi def link qfLineNr LineNr +hi def link qfError Error + +let b:current_syntax = "qf" + +" vim: ts=8 + +endif diff --git a/syntax/quake.vim b/syntax/quake.vim new file mode 100644 index 0000000..6491833 --- /dev/null +++ b/syntax/quake.vim @@ -0,0 +1,174 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Quake[1-3] configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2007-06-17 +" quake_is_quake1 - the syntax is to be used for quake1 configs +" quake_is_quake2 - the syntax is to be used for quake2 configs +" quake_is_quake3 - the syntax is to be used for quake3 configs +" Credits: Tomasz Kalkosinski wrote the original quake3Colors stuff + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword+=-,+ + +syn keyword quakeTodo contained TODO FIXME XXX NOTE + +syn region quakeComment display oneline start='//' end='$' end=';' + \ keepend contains=quakeTodo,@Spell + +syn region quakeString display oneline start=+"+ skip=+\\\\\|\\"+ + \ end=+"\|$+ contains=quakeNumbers, + \ @quakeCommands,@quake3Colors + +syn case ignore + +syn match quakeNumbers display transparent '\<-\=\d\|\.\d' + \ contains=quakeNumber,quakeFloat, + \ quakeOctalError,quakeOctal +syn match quakeNumber contained display '\d\+\>' +syn match quakeFloat contained display '\d\+\.\d*' +syn match quakeFloat contained display '\.\d\+\>' + +if exists("quake_is_quake1") || exists("quake_is_quake2") + syn match quakeOctal contained display '0\o\+\>' + \ contains=quakeOctalZero + syn match quakeOctalZero contained display '\<0' + syn match quakeOctalError contained display '0\o*[89]\d*' +endif + +syn cluster quakeCommands contains=quakeCommand,quake1Command, + \ quake12Command,Quake2Command,Quake23Command, + \ Quake3Command + +syn keyword quakeCommand +attack +back +forward +left +lookdown +lookup +syn keyword quakeCommand +mlook +movedown +moveleft +moveright +moveup +syn keyword quakeCommand +right +speed +strafe -attack -back bind +syn keyword quakeCommand bindlist centerview clear connect cvarlist dir +syn keyword quakeCommand disconnect dumpuser echo error exec -forward +syn keyword quakeCommand god heartbeat joy_advancedupdate kick kill +syn keyword quakeCommand killserver -left -lookdown -lookup map +syn keyword quakeCommand messagemode messagemode2 -mlook modellist +syn keyword quakeCommand -movedown -moveleft -moveright -moveup play +syn keyword quakeCommand quit rcon reconnect record -right say say_team +syn keyword quakeCommand screenshot serverinfo serverrecord serverstop +syn keyword quakeCommand set sizedown sizeup snd_restart soundinfo +syn keyword quakeCommand soundlist -speed spmap status -strafe stopsound +syn keyword quakeCommand toggleconsole unbind unbindall userinfo pause +syn keyword quakeCommand vid_restart viewpos wait weapnext weapprev + +if exists("quake_is_quake1") + syn keyword quake1Command sv +endif + +if exists("quake_is_quake1") || exists("quake_is_quake2") + syn keyword quake12Command +klook alias cd impulse link load save + syn keyword quake12Command timerefresh changing info loading + syn keyword quake12Command pingservers playerlist players score +endif + +if exists("quake_is_quake2") + syn keyword quake2Command cmd demomap +use condump download drop gamemap + syn keyword quake2Command give gun_model setmaster sky sv_maplist wave + syn keyword quake2Command cmdlist gameversiona gun_next gun_prev invdrop + syn keyword quake2Command inven invnext invnextp invnextw invprev + syn keyword quake2Command invprevp invprevw invuse menu_addressbook + syn keyword quake2Command menu_credits menu_dmoptions menu_game + syn keyword quake2Command menu_joinserver menu_keys menu_loadgame + syn keyword quake2Command menu_main menu_multiplayer menu_options + syn keyword quake2Command menu_playerconfig menu_quit menu_savegame + syn keyword quake2Command menu_startserver menu_video + syn keyword quake2Command notarget precache prog togglechat vid_front + syn keyword quake2Command weaplast +endif + +if exists("quake_is_quake2") || exists("quake_is_quake3") + syn keyword quake23Command imagelist modellist path z_stats +endif + +if exists("quake_is_quake3") + syn keyword quake3Command +info +scores +zoom addbot arena banClient + syn keyword quake3Command banUser callteamvote callvote changeVectors + syn keyword quake3Command cinematic clientinfo clientkick cmd cmdlist + syn keyword quake3Command condump configstrings crash cvar_restart devmap + syn keyword quake3Command fdir follow freeze fs_openedList Fs_pureList + syn keyword quake3Command Fs_referencedList gfxinfo globalservers + syn keyword quake3Command hunk_stats in_restart -info levelshot + syn keyword quake3Command loaddeferred localservers map_restart mem_info + syn keyword quake3Command messagemode3 messagemode4 midiinfo model music + syn keyword quake3Command modelist net_restart nextframe nextskin noclip + syn keyword quake3Command notarget ping prevframe prevskin reset restart + syn keyword quake3Command s_disable_a3d s_enable_a3d s_info s_list s_stop + syn keyword quake3Command scanservers -scores screenshotJPEG sectorlist + syn keyword quake3Command serverstatus seta setenv sets setu setviewpos + syn keyword quake3Command shaderlist showip skinlist spdevmap startOribt + syn keyword quake3Command stats stopdemo stoprecord systeminfo togglemenu + syn keyword quake3Command tcmd team teamtask teamvote tell tell_attacker + syn keyword quake3Command tell_target testgun testmodel testshader toggle + syn keyword quake3Command touchFile vminfo vmprofile vmtest vosay + syn keyword quake3Command vosay_team vote votell vsay vsay_team vstr + syn keyword quake3Command vtaunt vtell vtell_attacker vtell_target weapon + syn keyword quake3Command writeconfig -zoom + syn match quake3Command display "\<[+-]button\(\d\|1[0-4]\)\>" +endif + +if exists("quake_is_quake3") + syn cluster quake3Colors contains=quake3Red,quake3Green,quake3Yellow, + \ quake3Blue,quake3Cyan,quake3Purple,quake3White, + \ quake3Orange,quake3Grey,quake3Black,quake3Shadow + + syn region quake3Red contained start=+\^1+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Green contained start=+\^2+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Yellow contained start=+\^3+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Blue contained start=+\^4+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Cyan contained start=+\^5+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Purple contained start=+\^6+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3White contained start=+\^7+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Orange contained start=+\^8+hs=e+1 end=+[$^\"\n]+he=e-1 + syn region quake3Grey contained start=+\^9+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Black contained start=+\^0+hs=e+1 end=+[$^"\n]+he=e-1 + syn region quake3Shadow contained start=+\^[Xx]+hs=e+1 end=+[$^"\n]+he=e-1 +endif + +hi def link quakeComment Comment +hi def link quakeTodo Todo +hi def link quakeString String +hi def link quakeNumber Number +hi def link quakeOctal Number +hi def link quakeOctalZero PreProc +hi def link quakeFloat Number +hi def link quakeOctalError Error +hi def link quakeCommand quakeCommands +hi def link quake1Command quakeCommands +hi def link quake12Command quakeCommands +hi def link quake2Command quakeCommands +hi def link quake23Command quakeCommands +hi def link quake3Command quakeCommands +hi def link quakeCommands Keyword + +if exists("quake_is_quake3") + hi quake3Red ctermfg=Red guifg=Red + hi quake3Green ctermfg=Green guifg=Green + hi quake3Yellow ctermfg=Yellow guifg=Yellow + hi quake3Blue ctermfg=Blue guifg=Blue + hi quake3Cyan ctermfg=Cyan guifg=Cyan + hi quake3Purple ctermfg=DarkMagenta guifg=Purple + hi quake3White ctermfg=White guifg=White + hi quake3Black ctermfg=Black guifg=Black + hi quake3Orange ctermfg=Brown guifg=Orange + hi quake3Grey ctermfg=LightGrey guifg=LightGrey + hi quake3Shadow cterm=underline gui=underline +endif + +let b:current_syntax = "quake" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/r.vim b/syntax/r.vim new file mode 100644 index 0000000..3970d06 --- /dev/null +++ b/syntax/r.vim @@ -0,0 +1,378 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: R (GNU S) +" Maintainer: Jakson Aquino +" Former Maintainers: Vaidotas Zemlys +" Tom Payne +" Contributor: Johannes Ranke +" Homepage: https://github.com/jalvesaq/R-Vim-runtime +" Last Change: Sat Apr 08, 2017 07:01PM +" Filenames: *.R *.r *.Rhistory *.Rt +" +" NOTE: The highlighting of R functions might be defined in +" runtime files created by a filetype plugin, if installed. +" +" CONFIGURATION: +" Syntax folding can be turned on by +" +" let r_syntax_folding = 1 +" +" ROxygen highlighting can be turned off by +" +" let r_syntax_hl_roxygen = 0 +" +" Some lines of code were borrowed from Zhuojun Chen. + +if exists("b:current_syntax") + finish +endif + +if has("patch-7.4.1142") + syn iskeyword @,48-57,_,. +else + setlocal iskeyword=@,48-57,_,. +endif + +" The variables g:r_hl_roxygen and g:r_syn_minlines were renamed on April 8, 2017. +if exists("g:r_hl_roxygen") + let g:r_syntax_hl_roxygen = g:r_hl_roxygen +endif +if exists("g:r_syn_minlines") + let g:r_syntax_minlines = g:r_syn_minlines +endif + +if exists("g:r_syntax_folding") && g:r_syntax_folding + setlocal foldmethod=syntax +endif +if !exists("g:r_syntax_hl_roxygen") + let g:r_syntax_hl_roxygen = 1 +endif + +syn case match + +" Comment +syn match rCommentTodo contained "\(BUG\|FIXME\|NOTE\|TODO\):" +syn match rComment contains=@Spell,rCommentTodo,rOBlock "#.*" + +" Roxygen +if g:r_syntax_hl_roxygen + " A roxygen block can start at the beginning of a file (first version) and + " after a blank line (second version). It ends when a line that does not + " contain a roxygen comment. In the following comments, any line containing + " a roxygen comment marker (one or two hash signs # followed by a single + " quote ' and preceded only by whitespace) is called a roxygen line. A + " roxygen line containing only a roxygen comment marker, optionally followed + " by whitespace is called an empty roxygen line. + + " First we match all roxygen blocks as containing only a title. In case an + " empty roxygen line ending the title or a tag is found, this will be + " overriden later by the definitions of rOBlock. + syn match rOTitleBlock "\%^\(\s*#\{1,2}' .*\n\)\{1,}" contains=rOCommentKey,rOTitleTag + syn match rOTitleBlock "^\s*\n\(\s*#\{1,2}' .*\n\)\{1,}" contains=rOCommentKey,rOTitleTag + + " When a roxygen block has a title and additional content, the title + " consists of one or more roxygen lines (as little as possible are matched), + " followed either by an empty roxygen line + syn region rOBlock start="\%^\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*$" end="^\s*\(#\{1,2}'\)\@!" contains=rOTitle,rOTag,rOExamples,@Spell keepend fold + syn region rOBlock start="^\s*\n\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*$" end="^\s*\(#\{1,2}'\)\@!" contains=rOTitle,rOTag,rOExamples,@Spell keepend fold + + " or by a roxygen tag (we match everything starting with @ but not @@ which is used as escape sequence for a literal @). + syn region rOBlock start="\%^\(\s*#\{1,2}' .*\n\)\{-}\s*#\{1,2}' @\(@\)\@!" end="^\s*\(#\{1,2}'\)\@!" contains=rOTitle,rOTag,rOExamples,@Spell keepend fold + syn region rOBlock start="^\s*\n\(\s*#\{1,2}' .*\n\)\{-}\s*#\{1,2}' @\(@\)\@!" end="^\s*\(#\{1,2}'\)\@!" contains=rOTitle,rOTag,rOExamples,@Spell keepend fold + + " If a block contains an @rdname, @describeIn tag, it may have paragraph breaks, but does not have a title + syn region rOBlockNoTitle start="\%^\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*\n\(\s*#\{1,2}'.*\n\)\{-}\s*#\{1,2}' @rdname" end="^\s*\(#\{1,2}'\)\@!" contains=rOTag,rOExamples,@Spell keepend fold + syn region rOBlockNoTitle start="^\s*\n\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*\n\(\s*#\{1,2}'.*\n\)\{-}\s*#\{1,2}' @rdname" end="^\s*\(#\{1,2}'\)\@!" contains=rOTag,rOExamples,@Spell keepend fold + syn region rOBlockNoTitle start="\%^\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*\n\(\s*#\{1,2}'.*\n\)\{-}\s*#\{1,2}' @describeIn" end="^\s*\(#\{1,2}'\)\@!" contains=rOTag,rOExamples,@Spell keepend fold + syn region rOBlockNoTitle start="^\s*\n\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*\n\(\s*#\{1,2}'.*\n\)\{-}\s*#\{1,2}' @describeIn" end="^\s*\(#\{1,2}'\)\@!" contains=rOTag,rOExamples,@Spell keepend fold + + " A title as part of a block is always at the beginning of the block, i.e. + " either at the start of a file or after a completely empty line. + syn match rOTitle "\%^\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*$" contained contains=rOCommentKey,rOTitleTag + syn match rOTitle "^\s*\n\(\s*#\{1,2}' .*\n\)\{-1,}\s*#\{1,2}'\s*$" contained contains=rOCommentKey,rOTitleTag + syn match rOTitleTag contained "@title" + + syn match rOCommentKey "#\{1,2}'" contained + syn region rOExamples start="^#\{1,2}' @examples.*"rs=e+1,hs=e+1 end="^\(#\{1,2}' @.*\)\@=" end="^\(#\{1,2}'\)\@!" contained contains=rOTag fold + + " rOTag list generated from the lists in + " https://github.com/klutometis/roxygen/R/rd.R and + " https://github.com/klutometis/roxygen/R/namespace.R + " using s/^ \([A-Za-z0-9]*\) = .*/ syn match rOTag contained "@\1"/ + " Plus we need the @include tag + + " rd.R + syn match rOTag contained "@aliases" + syn match rOTag contained "@author" + syn match rOTag contained "@backref" + syn match rOTag contained "@concept" + syn match rOTag contained "@describeIn" + syn match rOTag contained "@description" + syn match rOTag contained "@details" + syn match rOTag contained "@docType" + syn match rOTag contained "@encoding" + syn match rOTag contained "@evalRd" + syn match rOTag contained "@example" + syn match rOTag contained "@examples" + syn match rOTag contained "@family" + syn match rOTag contained "@field" + syn match rOTag contained "@format" + syn match rOTag contained "@inherit" + syn match rOTag contained "@inheritParams" + syn match rOTag contained "@inheritDotParams" + syn match rOTag contained "@inheritSection" + syn match rOTag contained "@keywords" + syn match rOTag contained "@method" + syn match rOTag contained "@name" + syn match rOTag contained "@md" + syn match rOTag contained "@noMd" + syn match rOTag contained "@noRd" + syn match rOTag contained "@note" + syn match rOTag contained "@param" + syn match rOTag contained "@rdname" + syn match rOTag contained "@rawRd" + syn match rOTag contained "@references" + syn match rOTag contained "@return" + syn match rOTag contained "@section" + syn match rOTag contained "@seealso" + syn match rOTag contained "@slot" + syn match rOTag contained "@source" + syn match rOTag contained "@template" + syn match rOTag contained "@templateVar" + syn match rOTag contained "@title" + syn match rOTag contained "@usage" + " namespace.R + syn match rOTag contained "@export" + syn match rOTag contained "@exportClass" + syn match rOTag contained "@exportMethod" + syn match rOTag contained "@exportPattern" + syn match rOTag contained "@import" + syn match rOTag contained "@importClassesFrom" + syn match rOTag contained "@importFrom" + syn match rOTag contained "@importMethodsFrom" + syn match rOTag contained "@rawNamespace" + syn match rOTag contained "@S3method" + syn match rOTag contained "@useDynLib" + " other + syn match rOTag contained "@include" +endif + + +if &filetype == "rhelp" + " string enclosed in double quotes + syn region rString contains=rSpecial,@Spell start=/"/ skip=/\\\\\|\\"/ end=/"/ + " string enclosed in single quotes + syn region rString contains=rSpecial,@Spell start=/'/ skip=/\\\\\|\\'/ end=/'/ +else + " string enclosed in double quotes + syn region rString contains=rSpecial,rStrError,@Spell start=/"/ skip=/\\\\\|\\"/ end=/"/ + " string enclosed in single quotes + syn region rString contains=rSpecial,rStrError,@Spell start=/'/ skip=/\\\\\|\\'/ end=/'/ +endif + +syn match rStrError display contained "\\." + + +" New line, carriage return, tab, backspace, bell, feed, vertical tab, backslash +syn match rSpecial display contained "\\\(n\|r\|t\|b\|a\|f\|v\|'\|\"\)\|\\\\" + +" Hexadecimal and Octal digits +syn match rSpecial display contained "\\\(x\x\{1,2}\|[0-8]\{1,3}\)" + +" Unicode characters +syn match rSpecial display contained "\\u\x\{1,4}" +syn match rSpecial display contained "\\U\x\{1,8}" +syn match rSpecial display contained "\\u{\x\{1,4}}" +syn match rSpecial display contained "\\U{\x\{1,8}}" + +" Statement +syn keyword rStatement break next return +syn keyword rConditional if else +syn keyword rRepeat for in repeat while + +" Constant (not really) +syn keyword rConstant T F LETTERS letters month.abb month.name pi +syn keyword rConstant R.version.string + +syn keyword rNumber NA_integer_ NA_real_ NA_complex_ NA_character_ + +" Constants +syn keyword rConstant NULL +syn keyword rBoolean FALSE TRUE +syn keyword rNumber NA Inf NaN + +" integer +syn match rInteger "\<\d\+L" +syn match rInteger "\<0x\([0-9]\|[a-f]\|[A-F]\)\+L" +syn match rInteger "\<\d\+[Ee]+\=\d\+L" + +" number with no fractional part or exponent +syn match rNumber "\<\d\+\>" +" hexadecimal number +syn match rNumber "\<0x\([0-9]\|[a-f]\|[A-F]\)\+" + +" floating point number with integer and fractional parts and optional exponent +syn match rFloat "\<\d\+\.\d*\([Ee][-+]\=\d\+\)\=" +" floating point number with no integer part and optional exponent +syn match rFloat "\<\.\d\+\([Ee][-+]\=\d\+\)\=" +" floating point number with no fractional part and optional exponent +syn match rFloat "\<\d\+[Ee][-+]\=\d\+" + +" complex number +syn match rComplex "\<\d\+i" +syn match rComplex "\<\d\++\d\+i" +syn match rComplex "\<0x\([0-9]\|[a-f]\|[A-F]\)\+i" +syn match rComplex "\<\d\+\.\d*\([Ee][-+]\=\d\+\)\=i" +syn match rComplex "\<\.\d\+\([Ee][-+]\=\d\+\)\=i" +syn match rComplex "\<\d\+[Ee][-+]\=\d\+i" + +syn match rAssign '=' +syn match rOperator "&" +syn match rOperator '-' +syn match rOperator '\*' +syn match rOperator '+' +if &filetype != "rmd" && &filetype != "rrst" + syn match rOperator "[|!<>^~/:]" +else + syn match rOperator "[|!<>^~`/:]" +endif +syn match rOperator "%\{2}\|%\S\{-}%" +syn match rOperator '\([!><]\)\@<==' +syn match rOperator '==' +syn match rOpError '\*\{3}' +syn match rOpError '//' +syn match rOpError '&&&' +syn match rOpError '|||' +syn match rOpError '<<' +syn match rOpError '>>' + +syn match rAssign "<\{1,2}-" +syn match rAssign "->\{1,2}" + +" Special +syn match rDelimiter "[,;:]" + +" Error +if exists("g:r_syntax_folding") + syn region rRegion matchgroup=Delimiter start=/(/ matchgroup=Delimiter end=/)/ transparent contains=ALLBUT,rError,rBraceError,rCurlyError fold + syn region rRegion matchgroup=Delimiter start=/{/ matchgroup=Delimiter end=/}/ transparent contains=ALLBUT,rError,rBraceError,rParenError fold + syn region rRegion matchgroup=Delimiter start=/\[/ matchgroup=Delimiter end=/]/ transparent contains=ALLBUT,rError,rCurlyError,rParenError fold +else + syn region rRegion matchgroup=Delimiter start=/(/ matchgroup=Delimiter end=/)/ transparent contains=ALLBUT,rError,rBraceError,rCurlyError + syn region rRegion matchgroup=Delimiter start=/{/ matchgroup=Delimiter end=/}/ transparent contains=ALLBUT,rError,rBraceError,rParenError + syn region rRegion matchgroup=Delimiter start=/\[/ matchgroup=Delimiter end=/]/ transparent contains=ALLBUT,rError,rCurlyError,rParenError +endif + +syn match rError "[)\]}]" +syn match rBraceError "[)}]" contained +syn match rCurlyError "[)\]]" contained +syn match rParenError "[\]}]" contained + +" Use Nvim-R to highlight functions dynamically if it is installed +if !exists("g:r_syntax_fun_pattern") + let s:ff = split(substitute(globpath(&rtp, "R/functions.vim"), "functions.vim", "", "g"), "\n") + if len(s:ff) > 0 + let g:r_syntax_fun_pattern = 0 + else + let g:r_syntax_fun_pattern = 1 + endif +endif + +" Only use Nvim-R to highlight functions if they should not be highlighted +" according to a generic pattern +if g:r_syntax_fun_pattern == 1 + syn match rFunction '[0-9a-zA-Z_\.]\+\s*\ze(' +else + if !exists("g:R_hi_fun") + let g:R_hi_fun = 1 + endif + if g:R_hi_fun + " Nvim-R: + runtime R/functions.vim + endif +endif + +syn match rDollar display contained "\$" +syn match rDollar display contained "@" + +" List elements will not be highlighted as functions: +syn match rLstElmt "\$[a-zA-Z0-9\\._]*" contains=rDollar +syn match rLstElmt "@[a-zA-Z0-9\\._]*" contains=rDollar + +" Functions that may add new objects +syn keyword rPreProc library require attach detach source + +if &filetype == "rhelp" + syn match rHelpIdent '\\method' + syn match rHelpIdent '\\S4method' +endif + +" Type +syn keyword rType array category character complex double function integer list logical matrix numeric vector data.frame + +" Name of object with spaces +if &filetype != "rmd" && &filetype != "rrst" + syn region rNameWSpace start="`" end="`" +endif + +if &filetype == "rhelp" + syn match rhPreProc "^#ifdef.*" + syn match rhPreProc "^#endif.*" + syn match rhSection "\\dontrun\>" +endif + +if exists("r_syntax_minlines") + exe "syn sync minlines=" . r_syntax_minlines +else + syn sync minlines=40 +endif + +" Define the default highlighting. +hi def link rAssign Statement +hi def link rBoolean Boolean +hi def link rBraceError Error +hi def link rComment Comment +hi def link rCommentTodo Todo +hi def link rComplex Number +hi def link rConditional Conditional +hi def link rConstant Constant +hi def link rCurlyError Error +hi def link rDelimiter Delimiter +hi def link rDollar SpecialChar +hi def link rError Error +hi def link rFloat Float +hi def link rFunction Function +hi def link rHelpIdent Identifier +hi def link rhPreProc PreProc +hi def link rhSection PreCondit +hi def link rInteger Number +hi def link rLstElmt Normal +hi def link rNameWSpace Normal +hi def link rNumber Number +hi def link rOperator Operator +hi def link rOpError Error +hi def link rParenError Error +hi def link rPreProc PreProc +hi def link rRepeat Repeat +hi def link rSpecial SpecialChar +hi def link rStatement Statement +hi def link rString String +hi def link rStrError Error +hi def link rType Type +if g:r_syntax_hl_roxygen + hi def link rOTitleTag Operator + hi def link rOTag Operator + hi def link rOTitleBlock Title + hi def link rOBlock Comment + hi def link rOBlockNoTitle Comment + hi def link rOTitle Title + hi def link rOCommentKey Comment + hi def link rOExamples SpecialComment +endif + +let b:current_syntax="r" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/racc.vim b/syntax/racc.vim new file mode 100644 index 0000000..36ba807 --- /dev/null +++ b/syntax/racc.vim @@ -0,0 +1,146 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim default file +" Language: Racc input file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2008-06-22 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword raccTodo contained TODO FIXME XXX NOTE + +syn region raccComment start='/\*' end='\*/' + \ contains=raccTodo,@Spell +syn region raccComment display oneline start='#' end='$' + \ contains=raccTodo,@Spell + +syn region raccClass transparent matchgroup=raccKeyword + \ start='\' end='\'he=e-4 + \ contains=raccComment,raccPrecedence, + \ raccTokenDecl,raccExpect,raccOptions,raccConvert, + \ raccStart, + +syn region raccPrecedence transparent matchgroup=raccKeyword + \ start='\' end='\' + \ contains=raccComment,raccPrecSpec + +syn keyword raccPrecSpec contained nonassoc left right + \ nextgroup=raccPrecToken,raccPrecString skipwhite + \ skipnl + +syn match raccPrecToken contained '\<\u[A-Z0-9_]*\>' + \ nextgroup=raccPrecToken,raccPrecString skipwhite + \ skipnl + +syn region raccPrecString matchgroup=raccPrecString start=+"+ + \ skip=+\\\\\|\\"+ end=+"+ + \ contains=raccSpecial + \ nextgroup=raccPrecToken,raccPrecString skipwhite + \ skipnl +syn region raccPrecString matchgroup=raccPrecString start=+'+ + \ skip=+\\\\\|\\'+ end=+'+ contains=raccSpecial + \ nextgroup=raccPrecToken,raccPrecString skipwhite + \ skipnl + +syn keyword raccTokenDecl contained token + \ nextgroup=raccTokenR skipwhite skipnl + +syn match raccTokenR contained '\<\u[A-Z0-9_]*\>' + \ nextgroup=raccTokenR skipwhite skipnl + +syn keyword raccExpect contained expect + \ nextgroup=raccNumber skipwhite skipnl + +syn match raccNumber contained '\<\d\+\>' + +syn keyword raccOptions contained options + \ nextgroup=raccOptionsR skipwhite skipnl + +syn keyword raccOptionsR contained omit_action_call result_var + \ nextgroup=raccOptionsR skipwhite skipnl + +syn region raccConvert transparent contained matchgroup=raccKeyword + \ start='\' end='\' + \ contains=raccComment,raccConvToken skipwhite + \ skipnl + +syn match raccConvToken contained '\<\u[A-Z0-9_]*\>' + \ nextgroup=raccString skipwhite skipnl + +syn keyword raccStart contained start + \ nextgroup=raccTargetS skipwhite skipnl + +syn match raccTargetS contained '\<\l[a-z0-9_]*\>' + +syn match raccSpecial contained '\\["'\\]' + +syn region raccString start=+"+ skip=+\\\\\|\\"+ end=+"+ + \ contains=raccSpecial +syn region raccString start=+'+ skip=+\\\\\|\\'+ end=+'+ + \ contains=raccSpecial + +syn region raccRules transparent matchgroup=raccKeyword start='\' + \ end='\' contains=raccComment,raccString, + \ raccNumber,raccToken,raccTarget,raccDelimiter, + \ raccAction + +syn match raccTarget contained '\<\l[a-z0-9_]*\>' + +syn match raccDelimiter contained '[:|]' + +syn match raccToken contained '\<\u[A-Z0-9_]*\>' + +syn include @raccRuby syntax/ruby.vim + +syn region raccAction transparent matchgroup=raccDelimiter + \ start='{' end='}' contains=@raccRuby + +syn region raccHeader transparent matchgroup=raccPreProc + \ start='^---- header.*' end='^----'he=e-4 + \ contains=@raccRuby + +syn region raccInner transparent matchgroup=raccPreProc + \ start='^---- inner.*' end='^----'he=e-4 + \ contains=@raccRuby + +syn region raccFooter transparent matchgroup=raccPreProc + \ start='^---- footer.*' end='^----'he=e-4 + \ contains=@raccRuby + +syn sync match raccSyncHeader grouphere raccHeader '^---- header' +syn sync match raccSyncInner grouphere raccInner '^---- inner' +syn sync match raccSyncFooter grouphere raccFooter '^---- footer' + +hi def link raccTodo Todo +hi def link raccComment Comment +hi def link raccPrecSpec Type +hi def link raccPrecToken raccToken +hi def link raccPrecString raccString +hi def link raccTokenDecl Keyword +hi def link raccToken Identifier +hi def link raccTokenR raccToken +hi def link raccExpect Keyword +hi def link raccNumber Number +hi def link raccOptions Keyword +hi def link raccOptionsR Identifier +hi def link raccConvToken raccToken +hi def link raccStart Keyword +hi def link raccTargetS Type +hi def link raccSpecial special +hi def link raccString String +hi def link raccTarget Type +hi def link raccDelimiter Delimiter +hi def link raccPreProc PreProc +hi def link raccKeyword Keyword + +let b:current_syntax = "racc" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/radiance.vim b/syntax/radiance.vim new file mode 100644 index 0000000..f0a82b9 --- /dev/null +++ b/syntax/radiance.vim @@ -0,0 +1,146 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Radiance Scene Description +" Maintainer: Georg Mischler +" Last change: 26. April. 2001 + +" Radiance is a lighting simulation software package written +" by Gregory Ward-Larson ("the computer artist formerly known +" as Greg Ward"), then at LBNL. +" +" http://radsite.lbl.gov/radiance/HOME.html +" +" Of course, there is also information available about it +" from http://www.schorsch.com/ + + +" We take a minimalist approach here, highlighting just the +" essential properties of each object, its type and ID, as well as +" comments, external command names and the null-modifier "void". + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" all printing characters except '#' and '!' are valid in names. +setlocal iskeyword=\",$-~ + +" The null-modifier +syn keyword radianceKeyword void + +" The different kinds of scene description object types +" Reference types +syn keyword radianceExtraType contained alias instance +" Surface types +syn keyword radianceSurfType contained ring polygon sphere bubble +syn keyword radianceSurfType contained cone cup cylinder tube source +" Emitting material types +syn keyword radianceLightType contained light glow illum spotlight +" Material types +syn keyword radianceMatType contained mirror mist prism1 prism2 +syn keyword radianceMatType contained metal plastic trans +syn keyword radianceMatType contained metal2 plastic2 trans2 +syn keyword radianceMatType contained metfunc plasfunc transfunc +syn keyword radianceMatType contained metdata plasdata transdata +syn keyword radianceMatType contained dielectric interface glass +syn keyword radianceMatType contained BRTDfunc antimatter +" Pattern modifier types +syn keyword radiancePatType contained colorfunc brightfunc +syn keyword radiancePatType contained colordata colorpict brightdata +syn keyword radiancePatType contained colortext brighttext +" Texture modifier types +syn keyword radianceTexType contained texfunc texdata +" Mixture types +syn keyword radianceMixType contained mixfunc mixdata mixpict mixtext + + +" Each type name is followed by an ID. +" This doesn't work correctly if the id is one of the type names of the +" same class (which is legal for radiance), in which case the id will get +" type color as well, and the int count (or alias reference) gets id color. + +syn region radianceID start="\" end="\<\k*\>" contains=radianceExtraType +syn region radianceID start="\" end="\<\k*\>" contains=radianceExtraType + +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType +syn region radianceID start="\" end="\<\k*\>" contains=radianceSurfType + +syn region radianceID start="\" end="\<\k*\>" contains=radianceLightType +syn region radianceID start="\" end="\<\k*\>" contains=radianceLightType +syn region radianceID start="\" end="\<\k*\>" contains=radianceLightType +syn region radianceID start="\" end="\<\k*\>" contains=radianceLightType + +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMatType + +syn region radianceID start="\" end="\<\k*\>" contains=radiancePatType +syn region radianceID start="\" end="\<\k*\>" contains=radiancePatType +syn region radianceID start="\" end="\<\k*\>" contains=radiancePatType +syn region radianceID start="\" end="\<\k*\>" contains=radiancePatType +syn region radianceID start="\" end="\<\k*\>" contains=radiancePatType +syn region radianceID start="\" end="\<\k*\>" contains=radiancePatType +syn region radianceID start="\" end="\<\k*\>" contains=radiancePatType + +syn region radianceID start="\" end="\<\k*\>" contains=radianceTexType +syn region radianceID start="\" end="\<\k*\>" contains=radianceTexType + +syn region radianceID start="\" end="\<\k*\>" contains=radianceMixType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMixType +syn region radianceID start="\" end="\<\k*\>" contains=radianceMixType + +" external commands (generators, xform et al.) +syn match radianceCommand "^\s*!\s*[^\s]\+\>" + +" The usual suspects +syn keyword radianceTodo contained TODO XXX +syn match radianceComment "#.*$" contains=radianceTodo + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link radianceKeyword Keyword +hi def link radianceExtraType Type +hi def link radianceSurfType Type +hi def link radianceLightType Type +hi def link radianceMatType Type +hi def link radiancePatType Type +hi def link radianceTexType Type +hi def link radianceMixType Type +hi def link radianceComment Comment +hi def link radianceCommand Function +hi def link radianceID String +hi def link radianceTodo Todo + +let b:current_syntax = "radiance" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/ratpoison.vim b/syntax/ratpoison.vim new file mode 100644 index 0000000..c65952d --- /dev/null +++ b/syntax/ratpoison.vim @@ -0,0 +1,271 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Ratpoison configuration/commands file ( /etc/ratpoisonrc ~/.ratpoisonrc ) +" Maintainer: Magnus Woldrich +" URL: http://github.com/trapd00r/vim-syntax-ratpoison +" Last Change: 2011 Apr 11 +" Previous Maintainer: Doug Kearns + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match ratpoisonComment "^\s*#.*$" contains=ratpoisonTodo + +syn keyword ratpoisonTodo TODO NOTE FIXME XXX contained + +syn case ignore +syn keyword ratpoisonBooleanArg on off contained +syn case match + +syn keyword ratpoisonCommandArg abort addhook alias banish chdir contained +syn keyword ratpoisonCommandArg clrunmanaged cnext colon compat cother contained +syn keyword ratpoisonCommandArg cprev curframe dedicate definekey delete contained +syn keyword ratpoisonCommandArg delkmap describekey echo escape exec contained +syn keyword ratpoisonCommandArg fdump focus focusdown focuslast focusleft contained +syn keyword ratpoisonCommandArg focusprev focusright focusup frestore fselect contained +syn keyword ratpoisonCommandArg gdelete getenv getsel gmerge gmove contained +syn keyword ratpoisonCommandArg gnew gnewbg gnext gprev gravity contained +syn keyword ratpoisonCommandArg groups gselect help hsplit inext contained +syn keyword ratpoisonCommandArg info iother iprev kill lastmsg contained +syn keyword ratpoisonCommandArg license link listhook meta msgwait contained +syn keyword ratpoisonCommandArg newkmap newwm next nextscreen number contained +syn keyword ratpoisonCommandArg only other prev prevscreen prompt contained +syn keyword ratpoisonCommandArg putsel quit ratclick rathold ratrelwarp contained +syn keyword ratpoisonCommandArg ratwarp readkey redisplay redo remhook contained +syn keyword ratpoisonCommandArg remove resize restart rudeness sdump contained +syn keyword ratpoisonCommandArg select set setenv sfdump shrink contained +syn keyword ratpoisonCommandArg source sselect startup_message time title contained +syn keyword ratpoisonCommandArg tmpwm unalias undefinekey undo unmanage contained +syn keyword ratpoisonCommandArg unsetenv verbexec version vsplit warp contained +syn keyword ratpoisonCommandArg windows contained + +syn match ratpoisonGravityArg "\<\(n\|north\)\>" contained +syn match ratpoisonGravityArg "\<\(nw\|northwest\)\>" contained +syn match ratpoisonGravityArg "\<\(ne\|northeast\)\>" contained +syn match ratpoisonGravityArg "\<\(w\|west\)\>" contained +syn match ratpoisonGravityArg "\<\(c\|center\)\>" contained +syn match ratpoisonGravityArg "\<\(e\|east\)\>" contained +syn match ratpoisonGravityArg "\<\(s\|south\)\>" contained +syn match ratpoisonGravityArg "\<\(sw\|southwest\)\>" contained +syn match ratpoisonGravityArg "\<\(se\|southeast\)\>" contained +syn case match + +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(F[1-9][0-9]\=\|\(\a\|\d\)\)\>" contained nextgroup=ratpoisonCommandArg skipwhite + +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(space\|exclam\|quotedbl\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(numbersign\|dollar\|percent\|ampersand\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(apostrophe\|quoteright\|parenleft\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(parenright\|asterisk\|plus\|comma\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(minus\|period\|slash\|colon\|semicolon\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(less\|equal\|greater\|question\|at\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(bracketleft\|backslash\|bracketright\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(asciicircum\|underscore\|grave\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(quoteleft\|braceleft\|bar\|braceright\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(asciitilde\)\>" contained nextgroup=ratpoisonCommandArg skipwhite + +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(BackSpace\|Tab\|Linefeed\|Clear\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(Return\|Pause\|Scroll_Lock\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(Sys_Req\|Escape\|Delete\)\>" contained nextgroup=ratpoisonCommandArg skipwhite + +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(Home\|Left\|Up\|Right\|Down\|Prior\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(Page_Up\|Next\|Page_Down\|End\|Begin\)\>" contained nextgroup=ratpoisonCommandArg skipwhite + +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(Select\|Print\|Execute\|Insert\|Undo\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(Redo\|Menu\|Find\|Cancel\|Help\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=\(Break\|Mode_switch\|script_switch\|Num_Lock\)\>" contained nextgroup=ratpoisonCommandArg skipwhite + +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=KP_\(Space\|Tab\|Enter\|F[1234]\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=KP_\(Home\|Left\|Up\|Right\|Down\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=KP_\(Prior\|Page_Up\|Next\|Page_Down\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=KP_\(End\|Begin\|Insert\|Delete\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=KP_\(Equal\|Multiply\|Add\|Separator\)\>" contained nextgroup=ratpoisonCommandArg skipwhite +syn match ratpoisonKeySeqArg "\<\([CMASH]\(-[CMASH]\)\{,4}-\)\=KP_\(Subtract\|Decimal\|Divide\|\d\)\>" contained nextgroup=ratpoisonCommandArg skipwhite + +syn match ratpoisonHookArg "\<\(key\|switchwin\|switchframe\|switchgroup\|quit\|restart\)\>" contained + +syn match ratpoisonNumberArg "\<\d\+\>" contained nextgroup=ratpoisonNumberArg skipwhite + +syn keyword ratpoisonSetArg barborder contained nextgroup=ratpoisonNumberArg +syn keyword ratpoisonSetArg bargravity contained nextgroup=ratpoisonGravityArg +syn keyword ratpoisonSetArg barpadding contained nextgroup=ratpoisonNumberArg +syn keyword ratpoisonSetArg bgcolor +syn keyword ratpoisonSetArg border contained nextgroup=ratpoisonNumberArg +syn keyword ratpoisonSetArg fgcolor +syn keyword ratpoisonSetArg fwcolor +syn keyword ratpoisonSetArg bwcolor +syn keyword ratpoisonSetArg historysize +syn keyword ratpoisonSetArg historycompaction +syn keyword ratpoisonSetArg historyexpansion +syn keyword ratpoisonSetArg topkmap +syn keyword ratpoisonSetArg barinpadding +syn keyword ratpoisonSetArg font +syn keyword ratpoisonSetArg framesels +syn keyword ratpoisonSetArg inputwidth contained nextgroup=ratpoisonNumberArg +syn keyword ratpoisonSetArg maxsizegravity contained nextgroup=ratpoisonGravityArg +syn keyword ratpoisonSetArg padding contained nextgroup=ratpoisonNumberArg +syn keyword ratpoisonSetArg resizeunit contained nextgroup=ratpoisonNumberArg +syn keyword ratpoisonSetArg transgravity contained nextgroup=ratpoisonGravityArg +syn keyword ratpoisonSetArg waitcursor contained nextgroup=ratpoisonNumberArg +syn keyword ratpoisonSetArg winfmt contained nextgroup=ratpoisonWinFmtArg +syn keyword ratpoisonSetArg wingravity contained nextgroup=ratpoisonGravityArg +syn keyword ratpoisonSetArg winliststyle contained nextgroup=ratpoisonWinListArg +syn keyword ratpoisonSetArg winname contained nextgroup=ratpoisonWinNameArg + +syn match ratpoisonWinFmtArg "%[nstacil]" contained nextgroup=ratpoisonWinFmtArg skipwhite + +syn match ratpoisonWinListArg "\<\(row\|column\)\>" contained + +syn match ratpoisonWinNameArg "\<\(name\|title\|class\)\>" contained + +syn match ratpoisonDefCommand "^\s*set\s*" nextgroup=ratpoisonSetArg +syn match ratpoisonDefCommand "^\s*defbarborder\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonDefCommand "^\s*defbargravity\s*" nextgroup=ratpoisonGravityArg +syn match ratpoisonDefCommand "^\s*defbarpadding\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonDefCommand "^\s*defbgcolor\s*" +syn match ratpoisonDefCommand "^\s*defborder\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonDefCommand "^\s*deffgcolor\s*" +syn match ratpoisonDefCommand "^\s*deffont\s*" +syn match ratpoisonDefCommand "^\s*defframesels\s*" +syn match ratpoisonDefCommand "^\s*definputwidth\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonDefCommand "^\s*defmaxsizegravity\s*" nextgroup=ratpoisonGravityArg +syn match ratpoisonDefCommand "^\s*defpadding\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonDefCommand "^\s*defresizeunit\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonDefCommand "^\s*deftransgravity\s*" nextgroup=ratpoisonGravityArg +syn match ratpoisonDefCommand "^\s*defwaitcursor\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonDefCommand "^\s*defwinfmt\s*" nextgroup=ratpoisonWinFmtArg +syn match ratpoisonDefCommand "^\s*defwingravity\s*" nextgroup=ratpoisonGravityArg +syn match ratpoisonDefCommand "^\s*defwinliststyle\s*" nextgroup=ratpoisonWinListArg +syn match ratpoisonDefCommand "^\s*defwinname\s*" nextgroup=ratpoisonWinNameArg +syn match ratpoisonDefCommand "^\s*msgwait\s*" nextgroup=ratpoisonNumberArg + +syn match ratpoisonStringCommand "^\s*\zsaddhook\ze\s*" nextgroup=ratpoisonHookArg +syn match ratpoisonStringCommand "^\s*\zsalias\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsbind\ze\s*" nextgroup=ratpoisonKeySeqArg +syn match ratpoisonStringCommand "^\s*\zschdir\ze\s*" +syn match ratpoisonStringCommand "^\s*\zscolon\ze\s*" nextgroup=ratpoisonCommandArg +syn match ratpoisonStringCommand "^\s*\zsdedicate\ze\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonStringCommand "^\s*\zsdefinekey\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsdelkmap\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsdescribekey\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsecho\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsescape\ze\s*" nextgroup=ratpoisonKeySeqArg +syn match ratpoisonStringCommand "^\s*\zsexec\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsfdump\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsfrestore\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsgdelete\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsgetenv\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsgravity\ze\s*" nextgroup=ratpoisonGravityArg +syn match ratpoisonStringCommand "^\s*\zsgselect\ze\s*" +syn match ratpoisonStringCommand "^\s*\zslink\ze\s*" nextgroup=ratpoisonKeySeqArg +syn match ratpoisonStringCommand "^\s*\zslisthook\ze\s*" nextgroup=ratpoisonHookArg +syn match ratpoisonStringCommand "^\s*\zsnewkmap\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsnewwm\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsnumber\ze\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonStringCommand "^\s*\zsprompt\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsratwarp\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsratrelwarp\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsratclick\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsrathold\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsreadkey\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsremhook\ze\s*" nextgroup=ratpoisonHookArg +syn match ratpoisonStringCommand "^\s*\zsresize\ze\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonStringCommand "^\s*\zsrudeness\ze\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonStringCommand "^\s*\zsselect\ze\s*" nextgroup=ratpoisonNumberArg +syn match ratpoisonStringCommand "^\s*\zssetenv\ze\s*" +syn match ratpoisonStringCommand "^\s*\zssource\ze\s*" +syn match ratpoisonStringCommand "^\s*\zssselect\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsstartup_message\ze\s*" nextgroup=ratpoisonBooleanArg +syn match ratpoisonStringCommand "^\s*\zstitle\ze\s*" +syn match ratpoisonStringCommand "^\s*\zstmpwm\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsunalias\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsunbind\ze\s*" nextgroup=ratpoisonKeySeqArg +syn match ratpoisonStringCommand "^\s*\zsundefinekey\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsunmanage\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsunsetenv\ze\s*" +syn match ratpoisonStringCommand "^\s*\zsverbexec\ze\s*" +syn match ratpoisonStringCommand "^\s*\zswarp\ze\s*" nextgroup=ratpoisonBooleanArg + +syn match ratpoisonVoidCommand "^\s*\zsabort\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsbanish\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsclrunmanaged\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zscnext\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zscompat\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zscother\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zscprev\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zscurframe\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsdelete\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfocusdown\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfocuslast\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfocusleft\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfocusprev\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfocusright\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfocusup\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfocus\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsfselect\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgetsel\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgmerge\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgmove\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgnewbg\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgnew\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgnext\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgprev\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsgroups\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zshelp\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zshsplit\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsinext\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsinfo\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsiother\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsiprev\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zskill\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zslastmsg\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zslicense\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsmeta\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsnextscreen\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsnext\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsonly\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsother\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsprevscreen\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsprev\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsputsel\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsquit\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsredisplay\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsredo\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsremove\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsrestart\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zssdump\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zssfdump\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsshrink\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zssplit\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zstime\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsundo\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsversion\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zsvsplit\ze\s*$" +syn match ratpoisonVoidCommand "^\s*\zswindows\ze\s*$" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link ratpoisonBooleanArg Boolean +hi def link ratpoisonCommandArg Keyword +hi def link ratpoisonComment Comment +hi def link ratpoisonDefCommand Identifier +hi def link ratpoisonGravityArg Constant +hi def link ratpoisonKeySeqArg Special +hi def link ratpoisonNumberArg Number +hi def link ratpoisonSetArg Keyword +hi def link ratpoisonStringCommand Identifier +hi def link ratpoisonTodo Todo +hi def link ratpoisonVoidCommand Identifier +hi def link ratpoisonWinFmtArg Special +hi def link ratpoisonWinNameArg Constant +hi def link ratpoisonWinListArg Constant + + +let b:current_syntax = "ratpoison" + +" vim: ts=8 + +endif diff --git a/syntax/rc.vim b/syntax/rc.vim new file mode 100644 index 0000000..0fb8bf1 --- /dev/null +++ b/syntax/rc.vim @@ -0,0 +1,194 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: M$ Resource files (*.rc) +" Maintainer: Christian Brabandt +" Last Change: 2015-05-29 +" Repository: https://github.com/chrisbra/vim-rc-syntax +" License: Vim (see :h license) +" Previous Maintainer: Heiko Erhardt + +" This file is based on the c.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Common RC keywords +syn keyword rcLanguage LANGUAGE + +syn keyword rcMainObject TEXTINCLUDE VERSIONINFO BITMAP ICON CURSOR CURSOR +syn keyword rcMainObject MENU ACCELERATORS TOOLBAR DIALOG +syn keyword rcMainObject STRINGTABLE MESSAGETABLE RCDATA DLGINIT DESIGNINFO + +syn keyword rcSubObject POPUP MENUITEM SEPARATOR +syn keyword rcSubObject CONTROL LTEXT CTEXT RTEXT EDITTEXT +syn keyword rcSubObject BUTTON PUSHBUTTON DEFPUSHBUTTON GROUPBOX LISTBOX COMBOBOX +syn keyword rcSubObject FILEVERSION PRODUCTVERSION FILEFLAGSMASK FILEFLAGS FILEOS +syn keyword rcSubObject FILETYPE FILESUBTYPE + +syn keyword rcCaptionParam CAPTION +syn keyword rcParam CHARACTERISTICS CLASS STYLE EXSTYLE VERSION FONT + +syn keyword rcStatement BEGIN END BLOCK VALUE + +syn keyword rcCommonAttribute PRELOAD LOADONCALL FIXED MOVEABLE DISCARDABLE PURE IMPURE + +syn keyword rcAttribute WS_OVERLAPPED WS_POPUP WS_CHILD WS_MINIMIZE WS_VISIBLE WS_DISABLED WS_CLIPSIBLINGS +syn keyword rcAttribute WS_CLIPCHILDREN WS_MAXIMIZE WS_CAPTION WS_BORDER WS_DLGFRAME WS_VSCROLL WS_HSCROLL +syn keyword rcAttribute WS_SYSMENU WS_THICKFRAME WS_GROUP WS_TABSTOP WS_MINIMIZEBOX WS_MAXIMIZEBOX WS_TILED +syn keyword rcAttribute WS_ICONIC WS_SIZEBOX WS_TILEDWINDOW WS_OVERLAPPEDWINDOW WS_POPUPWINDOW WS_CHILDWINDOW +syn keyword rcAttribute WS_EX_DLGMODALFRAME WS_EX_NOPARENTNOTIFY WS_EX_TOPMOST WS_EX_ACCEPTFILES +syn keyword rcAttribute WS_EX_TRANSPARENT WS_EX_MDICHILD WS_EX_TOOLWINDOW WS_EX_WINDOWEDGE WS_EX_CLIENTEDGE +syn keyword rcAttribute WS_EX_CONTEXTHELP WS_EX_RIGHT WS_EX_LEFT WS_EX_RTLREADING WS_EX_LTRREADING +syn keyword rcAttribute WS_EX_LEFTSCROLLBAR WS_EX_RIGHTSCROLLBAR WS_EX_CONTROLPARENT WS_EX_STATICEDGE +syn keyword rcAttribute WS_EX_APPWINDOW WS_EX_OVERLAPPEDWINDOW WS_EX_PALETTEWINDOW +syn keyword rcAttribute ES_LEFT ES_CENTER ES_RIGHT ES_MULTILINE ES_UPPERCASE ES_LOWERCASE ES_PASSWORD +syn keyword rcAttribute ES_AUTOVSCROLL ES_AUTOHSCROLL ES_NOHIDESEL ES_OEMCONVERT ES_READONLY ES_WANTRETURN +syn keyword rcAttribute ES_NUMBER +syn keyword rcAttribute BS_PUSHBUTTON BS_DEFPUSHBUTTON BS_CHECKBOX BS_AUTOCHECKBOX BS_RADIOBUTTON BS_3STATE +syn keyword rcAttribute BS_AUTO3STATE BS_GROUPBOX BS_USERBUTTON BS_AUTORADIOBUTTON BS_OWNERDRAW BS_LEFTTEXT +syn keyword rcAttribute BS_TEXT BS_ICON BS_BITMAP BS_LEFT BS_RIGHT BS_CENTER BS_TOP BS_BOTTOM BS_VCENTER +syn keyword rcAttribute BS_PUSHLIKE BS_MULTILINE BS_NOTIFY BS_FLAT BS_RIGHTBUTTON +syn keyword rcAttribute SS_LEFT SS_CENTER SS_RIGHT SS_ICON SS_BLACKRECT SS_GRAYRECT SS_WHITERECT +syn keyword rcAttribute SS_BLACKFRAME SS_GRAYFRAME SS_WHITEFRAME SS_USERITEM SS_SIMPLE SS_LEFTNOWORDWRAP +syn keyword rcAttribute SS_OWNERDRAW SS_BITMAP SS_ENHMETAFILE SS_ETCHEDHORZ SS_ETCHEDVERT SS_ETCHEDFRAME +syn keyword rcAttribute SS_TYPEMASK SS_NOPREFIX SS_NOTIFY SS_CENTERIMAGE SS_RIGHTJUST SS_REALSIZEIMAGE +syn keyword rcAttribute SS_SUNKEN SS_ENDELLIPSIS SS_PATHELLIPSIS SS_WORDELLIPSIS SS_ELLIPSISMASK +syn keyword rcAttribute DS_ABSALIGN DS_SYSMODAL DS_LOCALEDIT DS_SETFONT DS_MODALFRAME DS_NOIDLEMSG +syn keyword rcAttribute DS_SETFOREGROUND DS_3DLOOK DS_FIXEDSYS DS_NOFAILCREATE DS_CONTROL DS_CENTER +syn keyword rcAttribute DS_CENTERMOUSE DS_CONTEXTHELP +syn keyword rcAttribute LBS_NOTIFY LBS_SORT LBS_NOREDRAW LBS_MULTIPLESEL LBS_OWNERDRAWFIXED +syn keyword rcAttribute LBS_OWNERDRAWVARIABLE LBS_HASSTRINGS LBS_USETABSTOPS LBS_NOINTEGRALHEIGHT +syn keyword rcAttribute LBS_MULTICOLUMN LBS_WANTKEYBOARDINPUT LBS_EXTENDEDSEL LBS_DISABLENOSCROLL +syn keyword rcAttribute LBS_NODATA LBS_NOSEL LBS_STANDARD +syn keyword rcAttribute CBS_SIMPLE CBS_DROPDOWN CBS_DROPDOWNLIST CBS_OWNERDRAWFIXED CBS_OWNERDRAWVARIABLE +syn keyword rcAttribute CBS_AUTOHSCROLL CBS_OEMCONVERT CBS_SORT CBS_HASSTRINGS CBS_NOINTEGRALHEIGHT +syn keyword rcAttribute CBS_DISABLENOSCROLL CBS_UPPERCASE CBS_LOWERCASE +syn keyword rcAttribute SBS_HORZ SBS_VERT SBS_TOPALIGN SBS_LEFTALIGN SBS_BOTTOMALIGN SBS_RIGHTALIGN +syn keyword rcAttribute SBS_SIZEBOXTOPLEFTALIGN SBS_SIZEBOXBOTTOMRIGHTALIGN SBS_SIZEBOX SBS_SIZEGRIP +syn keyword rcAttribute CCS_TOP CCS_NOMOVEY CCS_BOTTOM CCS_NORESIZE CCS_NOPARENTALIGN CCS_ADJUSTABLE +syn keyword rcAttribute CCS_NODIVIDER +syn keyword rcAttribute LVS_ICON LVS_REPORT LVS_SMALLICON LVS_LIST LVS_TYPEMASK LVS_SINGLESEL LVS_SHOWSELALWAYS +syn keyword rcAttribute LVS_SORTASCENDING LVS_SORTDESCENDING LVS_SHAREIMAGELISTS LVS_NOLABELWRAP +syn keyword rcAttribute LVS_EDITLABELS LVS_OWNERDATA LVS_NOSCROLL LVS_TYPESTYLEMASK LVS_ALIGNTOP LVS_ALIGNLEFT +syn keyword rcAttribute LVS_ALIGNMASK LVS_OWNERDRAWFIXED LVS_NOCOLUMNHEADER LVS_NOSORTHEADER LVS_AUTOARRANGE +syn keyword rcAttribute TVS_HASBUTTONS TVS_HASLINES TVS_LINESATROOT TVS_EDITLABELS TVS_DISABLEDRAGDROP +syn keyword rcAttribute TVS_SHOWSELALWAYS +syn keyword rcAttribute TCS_FORCEICONLEFT TCS_FORCELABELLEFT TCS_TABS TCS_BUTTONS TCS_SINGLELINE TCS_MULTILINE +syn keyword rcAttribute TCS_RIGHTJUSTIFY TCS_FIXEDWIDTH TCS_RAGGEDRIGHT TCS_FOCUSONBUTTONDOWN +syn keyword rcAttribute TCS_OWNERDRAWFIXED TCS_TOOLTIPS TCS_FOCUSNEVER +syn keyword rcAttribute ACS_CENTER ACS_TRANSPARENT ACS_AUTOPLAY +syn keyword rcStdId IDI_APPLICATION IDI_HAND IDI_QUESTION IDI_EXCLAMATION IDI_ASTERISK IDI_WINLOGO IDI_WINLOGO +syn keyword rcStdId IDI_WARNING IDI_ERROR IDI_INFORMATION +syn keyword rcStdId IDCANCEL IDABORT IDRETRY IDIGNORE IDYES IDNO IDCLOSE IDHELP IDC_STATIC + +" Common RC keywords + +" Common RC keywords +syn keyword rcTodo contained TODO FIXME XXX + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match rcSpecial contained "\\[0-7][0-7][0-7]\=\|\\." +syn region rcString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=rcSpecial +syn match rcCharacter "'[^\\]'" +syn match rcSpecialCharacter "'\\.'" +syn match rcSpecialCharacter "'\\[0-7][0-7]'" +syn match rcSpecialCharacter "'\\[0-7][0-7][0-7]'" + +"catch errors caused by wrong parenthesis +syn region rcParen transparent start='(' end=')' contains=ALLBUT,rcParenError,rcIncluded,rcSpecial,rcTodo +syn match rcParenError ")" +syn match rcInParen contained "[{}]" + +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match rcNumber "\<\d\+\(u\=l\=\|lu\|f\)\>" +"floating point number, with dot, optional exponent +syn match rcFloat "\<\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, starting with a dot, optional exponent +syn match rcFloat "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match rcFloat "\<\d\+e[-+]\=\d\+[fl]\=\>" +"hex number +syn match rcNumber "\<0x[0-9a-f]\+\(u\=l\=\|lu\)\>" +"syn match rcIdentifier "\<[a-z_][a-z0-9_]*\>" +syn case match +" flag an octal number with wrong digits +syn match rcOctalError "\<0[0-7]*[89]" + +if exists("rc_comment_strings") + " A comment can contain rcString, rcCharacter and rcNumber. + " But a "*/" inside a rcString in a rcComment DOES end the comment! So we + " need to use a special type of rcString: rcCommentString, which also ends on + " "*/", and sees a "*" at the start of the line as comment again. + " Unfortunately this doesn't very well work for // type of comments :-( + syntax match rcCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region rcCommentString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end=+\*/+me=s-1 contains=rcSpecial,rcCommentSkip + syntax region rcComment2String contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end="$" contains=rcSpecial + syntax region rcComment start="/\*" end="\*/" contains=rcTodo,rcCommentString,rcCharacter,rcNumber,rcFloat + syntax match rcComment "//.*" contains=rcTodo,rcComment2String,rcCharacter,rcNumber +else + syn region rcComment start="/\*" end="\*/" contains=rcTodo + syn match rcComment "//.*" contains=rcTodo +endif +syntax match rcCommentError "\*/" + +syn region rcPreCondit start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=rcComment,rcString,rcCharacter,rcNumber,rcCommentError +syn region rcIncluded contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match rcIncluded contained "<[^>]*>" +syn match rcInclude "^\s*#\s*include\>\s*["<]" contains=rcIncluded +"syn match rcLineSkip "\\$" +syn region rcDefine start="^\s*#\s*\(define\>\|undef\>\)" skip="\\$" end="$" contains=ALLBUT,rcPreCondit,rcIncluded,rcInclude,rcDefine,rcInParen +syn region rcPreProc start="^\s*#\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" contains=ALLBUT,rcPreCondit,rcIncluded,rcInclude,rcDefine,rcInParen + +syn sync ccomment rcComment minlines=10 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link rcCharacter Character +hi def link rcSpecialCharacter rcSpecial +hi def link rcNumber Number +hi def link rcFloat Float +hi def link rcOctalError rcError +hi def link rcParenError rcError +hi def link rcInParen rcError +hi def link rcCommentError rcError +hi def link rcInclude Include +hi def link rcPreProc PreProc +hi def link rcDefine Macro +hi def link rcIncluded rcString +hi def link rcError Error +hi def link rcPreCondit PreCondit +hi def link rcCommentString rcString +hi def link rcComment2String rcString +hi def link rcCommentSkip rcComment +hi def link rcString String +hi def link rcComment Comment +hi def link rcSpecial SpecialChar +hi def link rcTodo Todo + +hi def link rcAttribute rcCommonAttribute +hi def link rcStdId rcStatement +hi def link rcStatement Statement + +" Default color overrides +hi def rcLanguage term=reverse ctermbg=Red ctermfg=Yellow guibg=Red guifg=Yellow +hi def rcMainObject term=underline ctermfg=Blue guifg=Blue +hi def rcSubObject ctermfg=Green guifg=Green +hi def rcCaptionParam term=underline ctermfg=DarkGreen guifg=Green +hi def rcParam ctermfg=DarkGreen guifg=DarkGreen +hi def rcStatement ctermfg=DarkGreen guifg=DarkGreen +hi def rcCommonAttribute ctermfg=Brown guifg=Brown + +"hi def link rcIdentifier Identifier + + +let b:current_syntax = "rc" + +" vim: ts=8 + +endif diff --git a/syntax/rcs.vim b/syntax/rcs.vim new file mode 100644 index 0000000..1e5e6c4 --- /dev/null +++ b/syntax/rcs.vim @@ -0,0 +1,67 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: RCS file +" Maintainer: Dmitry Vasiliev +" URL: https://github.com/hdima/vim-scripts/blob/master/syntax/rcs.vim +" Last Change: 2012-02-11 +" Filenames: *,v +" Version: 1.12 + +" Options: +" rcs_folding = 1 For folding strings + +" quit when a syntax file was already loaded. +if exists("b:current_syntax") + finish +endif + +" RCS file must end with a newline. +syn match rcsEOFError ".\%$" containedin=ALL + +" Keywords. +syn keyword rcsKeyword head branch access symbols locks strict +syn keyword rcsKeyword comment expand date author state branches +syn keyword rcsKeyword next desc log +syn keyword rcsKeyword text nextgroup=rcsTextStr skipwhite skipempty + +" Revision numbers and dates. +syn match rcsNumber "\<[0-9.]\+\>" display + +" Strings. +if exists("rcs_folding") && has("folding") + " Folded strings. + syn region rcsString matchgroup=rcsString start="@" end="@" skip="@@" fold contains=rcsSpecial + syn region rcsTextStr matchgroup=rcsTextStr start="@" end="@" skip="@@" fold contained contains=rcsSpecial,rcsDiffLines +else + syn region rcsString matchgroup=rcsString start="@" end="@" skip="@@" contains=rcsSpecial + syn region rcsTextStr matchgroup=rcsTextStr start="@" end="@" skip="@@" contained contains=rcsSpecial,rcsDiffLines +endif +syn match rcsSpecial "@@" contained +syn match rcsDiffLines "[da]\d\+ \d\+$" contained + +" Synchronization. +syn sync clear +if exists("rcs_folding") && has("folding") + syn sync fromstart +else + " We have incorrect folding if following sync patterns is turned on. + syn sync match rcsSync grouphere rcsString "[0-9.]\+\(\s\|\n\)\+log\(\s\|\n\)\+@"me=e-1 + syn sync match rcsSync grouphere rcsTextStr "@\(\s\|\n\)\+text\(\s\|\n\)\+@"me=e-1 +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet. + +hi def link rcsKeyword Keyword +hi def link rcsNumber Identifier +hi def link rcsString String +hi def link rcsTextStr String +hi def link rcsSpecial Special +hi def link rcsDiffLines Special +hi def link rcsEOFError Error + + +let b:current_syntax = "rcs" + +endif diff --git a/syntax/rcslog.vim b/syntax/rcslog.vim new file mode 100644 index 0000000..0c60c12 --- /dev/null +++ b/syntax/rcslog.vim @@ -0,0 +1,29 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: RCS log output +" Maintainer: Joe Karthauser +" Last Change: 2001 May 09 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match rcslogRevision "^revision.*$" +syn match rcslogFile "^RCS file:.*" +syn match rcslogDate "^date: .*$" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link rcslogFile Type +hi def link rcslogRevision Constant +hi def link rcslogDate Identifier + + +let b:current_syntax = "rcslog" + +" vim: ts=8 + +endif diff --git a/syntax/readline.vim b/syntax/readline.vim new file mode 100644 index 0000000..2b89932 --- /dev/null +++ b/syntax/readline.vim @@ -0,0 +1,402 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: readline(3) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2017-06-25 +" readline_has_bash - if defined add support for bash specific +" settings/functions + +if exists('b:current_syntax') + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword+=- + +syn match readlineKey contained + \ '\S' + \ nextgroup=readlineKeyTerminator + +syn match readlineBegin display '^' + \ nextgroup=readlineComment, + \ readlineConditional, + \ readlineInclude, + \ readlineKeyName, + \ readlineKey, + \ readlineKeySeq, + \ readlineKeyword + \ skipwhite + +syn region readlineComment contained display oneline + \ start='#' + \ end='$' + \ contains=readlineTodo, + \ @Spell + +syn keyword readlineTodo contained + \ TODO + \ FIXME + \ XXX + \ NOTE + +syn match readlineConditional contained + \ '$if\>' + \ nextgroup=readlineTest, + \ readlineTestApp + \ skipwhite + +syn keyword readlineTest contained + \ mode + \ nextgroup=readlineTestModeEq + +syn match readlineTestModeEq contained + \ '=' + \ nextgroup=readlineEditingMode + +syn keyword readlineTest contained + \ term + \ nextgroup=readlineTestTermEq + +syn match readlineTestTermEq contained + \ '=' + \ nextgroup=readlineTestTerm + +syn match readlineTestTerm contained + \ '\S\+' + +syn match readlineTestApp contained + \ '\S\+' + +syn match readlineConditional contained display + \ '$\%(else\|endif\)\>' + +syn match readlineInclude contained display + \ '$include\>' + \ nextgroup=readlinePath + +syn match readlinePath contained display + \ '.\+' + +syn case ignore +syn match readlineKeyName contained display + \ nextgroup=readlineKeySeparator, + \ readlineKeyTerminator + \ '\%(Control\|Del\|Esc\|Escape\|LFD\|Meta\|Newline\|Ret\|Return\|Rubout\|Space\|Spc\|Tab\)' +syn case match + +syn match readlineKeySeparator contained + \ '-' + \ nextgroup=readlineKeyName, + \ readlineKey + +syn match readlineKeyTerminator contained + \ ':' + \ nextgroup=readlineFunction + \ skipwhite + +syn region readlineKeySeq contained display oneline + \ start=+"+ + \ skip=+\\\\\|\\"+ + \ end=+"+ + \ contains=readlineKeyEscape + \ nextgroup=readlineKeyTerminator + +syn match readlineKeyEscape contained display + \ +\\\([CM]-\|[e\\"'abdfnrtv]\|\o\{3}\|x\x\{2}\)+ + +syn keyword readlineKeyword contained + \ set + \ nextgroup=readlineVariable + \ skipwhite + +syn keyword readlineVariable contained + \ nextgroup=readlineBellStyle + \ skipwhite + \ bell-style + +syn keyword readlineVariable contained + \ nextgroup=readlineBoolean + \ skipwhite + \ bind-tty-special-chars + \ colored-stats + \ completion-ignore-case + \ completion-map-case + \ convert-meta + \ disable-completion + \ echo-control-characters + \ enable-keypad + \ enable-meta-key + \ expand-tilde + \ history-preserve-point + \ horizontal-scroll-mode + \ input-meta + \ meta-flag + \ mark-directories + \ mark-modified-lines + \ mark-symlinked-directories + \ match-hidden-files + \ menu-complete-display-prefix + \ output-meta + \ page-completions + \ print-completions-horizontally + \ revert-all-at-newline + \ show-all-if-ambiguous + \ show-all-if-unmodified + \ show-mode-in-prompt + \ skip-completed-text + \ visible-stats + +syn keyword readlineVariable contained + \ nextgroup=readlineString + \ skipwhite + \ comment-begin + \ isearch-terminators + +syn keyword readlineVariable contained + \ nextgroup=readlineNumber + \ skipwhite + \ completion-display-width + \ completion-prefix-display-length + \ completion-query-items + \ history-size + \ keyseq-timeout + +syn keyword readlineVariable contained + \ nextgroup=readlineEditingMode + \ skipwhite + \ editing-mode + +syn keyword readlineVariable contained + \ nextgroup=readlineKeymap + \ skipwhite + \ keymap + +syn keyword readlineBellStyle contained + \ audible + \ visible + \ none + +syn case ignore +syn keyword readlineBoolean contained + \ on + \ off +syn case match + +syn region readlineString contained display oneline + \ matchgroup=readlineStringDelimiter + \ start=+"+ + \ skip=+\\\\\|\\"+ + \ end=+"+ + +syn match readlineNumber contained display + \ '[+-]\d\+\>' + +syn keyword readlineEditingMode contained + \ emacs + \ vi + +syn match readlineKeymap contained display + \ 'emacs\%(-\%(standard\|meta\|ctlx\)\)\=\|vi\%(-\%(move\|command\|insert\)\)\=' + +syn keyword readlineFunction contained + \ beginning-of-line + \ end-of-line + \ forward-char + \ backward-char + \ forward-word + \ backward-word + \ clear-screen + \ redraw-current-line + \ + \ accept-line + \ previous-history + \ next-history + \ beginning-of-history + \ end-of-history + \ reverse-search-history + \ forward-search-history + \ non-incremental-reverse-search-history + \ non-incremental-forward-search-history + \ history-search-forward + \ history-search-backward + \ yank-nth-arg + \ yank-last-arg + \ + \ delete-char + \ backward-delete-char + \ forward-backward-delete-char + \ quoted-insert + \ tab-insert + \ self-insert + \ transpose-chars + \ transpose-words + \ upcase-word + \ downcase-word + \ capitalize-word + \ overwrite-mode + \ + \ kill-line + \ backward-kill-line + \ unix-line-discard + \ kill-whole-line + \ kill-word + \ backward-kill-word + \ unix-word-rubout + \ unix-filename-rubout + \ delete-horizontal-space + \ kill-region + \ copy-region-as-kill + \ copy-backward-word + \ copy-forward-word + \ yank + \ yank-pop + \ + \ digit-argument + \ universal-argument + \ + \ complete + \ possible-completions + \ insert-completions + \ menu-complete + \ menu-complete-backward + \ delete-char-or-list + \ + \ start-kbd-macro + \ end-kbd-macro + \ call-last-kbd-macro + \ + \ re-read-init-file + \ abort + \ do-uppercase-version + \ prefix-meta + \ undo + \ revert-line + \ tilde-expand + \ set-mark + \ exchange-point-and-mark + \ character-search + \ character-search-backward + \ skip-csi-sequence + \ insert-comment + \ dump-functions + \ dump-variables + \ dump-macros + \ emacs-editing-mode + \ vi-editing-mode + \ + \ vi-eof-maybe + \ vi-movement-mode + \ vi-undo + \ vi-match + \ vi-tilde-expand + \ vi-complete + \ vi-char-search + \ vi-redo + \ vi-search + \ vi-arg-digit + \ vi-append-eol + \ vi-prev-word + \ vi-change-to + \ vi-delete-to + \ vi-end-word + \ vi-char-search + \ vi-fetch-history + \ vi-insert-beg + \ vi-search-again + \ vi-put + \ vi-replace + \ vi-subst + \ vi-char-search + \ vi-next-word + \ vi-yank-to + \ vi-first-print + \ vi-yank-arg + \ vi-goto-mark + \ vi-append-mode + \ vi-prev-word + \ vi-change-to + \ vi-delete-to + \ vi-end-word + \ vi-char-search + \ vi-insert-mode + \ vi-set-mark + \ vi-search-again + \ vi-put + \ vi-change-char + \ vi-subst + \ vi-char-search + \ vi-undo + \ vi-next-word + \ vi-delete + \ vi-yank-to + \ vi-column + \ vi-change-case + +if exists("readline_has_bash") + syn keyword readlineFunction contained + \ shell-expand-line + \ history-expand-line + \ magic-space + \ alias-expand-line + \ history-and-alias-expand-line + \ insert-last-argument + \ operate-and-get-next + \ forward-backward-delete-char + \ delete-char-or-list + \ complete-filename + \ possible-filename-completions + \ complete-username + \ possible-username-completions + \ complete-variable + \ possible-variable-completions + \ complete-hostname + \ possible-hostname-completions + \ complete-command + \ possible-command-completions + \ dynamic-complete-history + \ complete-into-braces + \ glob-expand-word + \ glob-list-expansions + \ display-shell-version + \ glob-complete-word + \ edit-and-execute-command +endif + +hi def link readlineKey readlineKeySeq +hi def link readlineComment Comment +hi def link readlineTodo Todo +hi def link readlineConditional Conditional +hi def link readlineTest Type +hi def link readlineDelimiter Delimiter +hi def link readlineTestModeEq readlineEq +hi def link readlineTestTermEq readlineEq +hi def link readlineTestTerm readlineString +hi def link readlineTestAppEq readlineEq +hi def link readlineTestApp readlineString +hi def link readlineInclude Include +hi def link readlinePath String +hi def link readlineKeyName SpecialChar +hi def link readlineKeySeparator readlineKeySeq +hi def link readlineKeyTerminator readlineDelimiter +hi def link readlineKeySeq String +hi def link readlineKeyEscape SpecialChar +hi def link readlineKeyword Keyword +hi def link readlineVariable Identifier +hi def link readlineBellStyle Constant +hi def link readlineBoolean Boolean +hi def link readlineString String +hi def link readlineStringDelimiter readlineString +hi def link readlineNumber Number +hi def link readlineEditingMode Constant +hi def link readlineKeymap Constant +hi def link readlineFunction Function + +let b:current_syntax = 'readline' + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/rebol.vim b/syntax/rebol.vim new file mode 100644 index 0000000..17f2d7f --- /dev/null +++ b/syntax/rebol.vim @@ -0,0 +1,203 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Rebol +" Maintainer: Mike Williams +" Filenames: *.r +" Last Change: 27th June 2002 +" URL: http://www.eandem.co.uk/mrw/vim +" + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Rebol is case insensitive +syn case ignore + +" As per current users documentation +setlocal isk=@,48-57,?,!,.,',+,-,*,&,\|,=,_,~ + +" Yer TODO highlighter +syn keyword rebolTodo contained TODO + +" Comments +syn match rebolComment ";.*$" contains=rebolTodo + +" Words +syn match rebolWord "\a\k*" +syn match rebolWordPath "[^[:space:]]/[^[:space]]"ms=s+1,me=e-1 + +" Booleans +syn keyword rebolBoolean true false on off yes no + +" Values +" Integers +syn match rebolInteger "\<[+-]\=\d\+\('\d*\)*\>" +" Decimals +syn match rebolDecimal "[+-]\=\(\d\+\('\d*\)*\)\=[,.]\d*\(e[+-]\=\d\+\)\=" +syn match rebolDecimal "[+-]\=\d\+\('\d*\)*\(e[+-]\=\d\+\)\=" +" Time +syn match rebolTime "[+-]\=\(\d\+\('\d*\)*\:\)\{1,2}\d\+\('\d*\)*\([.,]\d\+\)\=\([AP]M\)\=\>" +syn match rebolTime "[+-]\=:\d\+\([.,]\d*\)\=\([AP]M\)\=\>" +" Dates +" DD-MMM-YY & YYYY format +syn match rebolDate "\d\{1,2}\([/-]\)\(Jan\|Feb\|Mar\|Apr\|May\|Jun\|Jul\|Aug\|Sep\|Oct\|Nov\|Dec\)\1\(\d\{2}\)\{1,2}\>" +" DD-month-YY & YYYY format +syn match rebolDate "\d\{1,2}\([/-]\)\(January\|February\|March\|April\|May\|June\|July\|August\|September\|October\|November\|December\)\1\(\d\{2}\)\{1,2}\>" +" DD-MM-YY & YY format +syn match rebolDate "\d\{1,2}\([/-]\)\d\{1,2}\1\(\d\{2}\)\{1,2}\>" +" YYYY-MM-YY format +syn match rebolDate "\d\{4}-\d\{1,2}-\d\{1,2}\>" +" DD.MM.YYYY format +syn match rebolDate "\d\{1,2}\.\d\{1,2}\.\d\{4}\>" +" Money +syn match rebolMoney "\a*\$\d\+\('\d*\)*\([,.]\d\+\)\=" +" Strings +syn region rebolString oneline start=+"+ skip=+^"+ end=+"+ contains=rebolSpecialCharacter +syn region rebolString start=+[^#]{+ end=+}+ skip=+{[^}]*}+ contains=rebolSpecialCharacter +" Binary +syn region rebolBinary start=+\d*#{+ end=+}+ contains=rebolComment +" Email +syn match rebolEmail "\<\k\+@\(\k\+\.\)*\k\+\>" +" File +syn match rebolFile "%\(\k\+/\)*\k\+[/]\=" contains=rebolSpecialCharacter +syn region rebolFile oneline start=+%"+ end=+"+ contains=rebolSpecialCharacter +" URLs +syn match rebolURL "http://\k\+\(\.\k\+\)*\(:\d\+\)\=\(/\(\k\+/\)*\(\k\+\)\=\)*" +syn match rebolURL "file://\k\+\(\.\k\+\)*/\(\k\+/\)*\k\+" +syn match rebolURL "ftp://\(\k\+:\k\+@\)\=\k\+\(\.\k\+\)*\(:\d\+\)\=/\(\k\+/\)*\k\+" +syn match rebolURL "mailto:\k\+\(\.\k\+\)*@\k\+\(\.\k\+\)*" +" Issues +syn match rebolIssue "#\(\d\+-\)*\d\+" +" Tuples +syn match rebolTuple "\(\d\+\.\)\{2,}" + +" Characters +syn match rebolSpecialCharacter contained "\^[^[:space:][]" +syn match rebolSpecialCharacter contained "%\d\+" + + +" Operators +" Math operators +syn match rebolMathOperator "\(\*\{1,2}\|+\|-\|/\{1,2}\)" +syn keyword rebolMathFunction abs absolute add arccosine arcsine arctangent cosine +syn keyword rebolMathFunction divide exp log-10 log-2 log-e max maximum min +syn keyword rebolMathFunction minimum multiply negate power random remainder sine +syn keyword rebolMathFunction square-root subtract tangent +" Binary operators +syn keyword rebolBinaryOperator complement and or xor ~ +" Logic operators +syn match rebolLogicOperator "[<>=]=\=" +syn match rebolLogicOperator "<>" +syn keyword rebolLogicOperator not +syn keyword rebolLogicFunction all any +syn keyword rebolLogicFunction head? tail? +syn keyword rebolLogicFunction negative? positive? zero? even? odd? +syn keyword rebolLogicFunction binary? block? char? date? decimal? email? empty? +syn keyword rebolLogicFunction file? found? function? integer? issue? logic? money? +syn keyword rebolLogicFunction native? none? object? paren? path? port? series? +syn keyword rebolLogicFunction string? time? tuple? url? word? +syn keyword rebolLogicFunction exists? input? same? value? + +" Datatypes +syn keyword rebolType binary! block! char! date! decimal! email! file! +syn keyword rebolType function! integer! issue! logic! money! native! +syn keyword rebolType none! object! paren! path! port! string! time! +syn keyword rebolType tuple! url! word! +syn keyword rebolTypeFunction type? + +" Control statements +syn keyword rebolStatement break catch exit halt reduce return shield +syn keyword rebolConditional if else +syn keyword rebolRepeat for forall foreach forskip loop repeat while until do + +" Series statements +syn keyword rebolStatement change clear copy fifth find first format fourth free +syn keyword rebolStatement func function head insert last match next parse past +syn keyword rebolStatement pick remove second select skip sort tail third trim length? + +" Context +syn keyword rebolStatement alias bind use + +" Object +syn keyword rebolStatement import make make-object rebol info? + +" I/O statements +syn keyword rebolStatement delete echo form format import input load mold prin +syn keyword rebolStatement print probe read save secure send write +syn keyword rebolOperator size? modified? + +" Debug statement +syn keyword rebolStatement help probe trace + +" Misc statements +syn keyword rebolStatement func function free + +" Constants +syn keyword rebolConstant none + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link rebolTodo Todo + +hi def link rebolStatement Statement +hi def link rebolLabel Label +hi def link rebolConditional Conditional +hi def link rebolRepeat Repeat + +hi def link rebolOperator Operator +hi def link rebolLogicOperator rebolOperator +hi def link rebolLogicFunction rebolLogicOperator +hi def link rebolMathOperator rebolOperator +hi def link rebolMathFunction rebolMathOperator +hi def link rebolBinaryOperator rebolOperator +hi def link rebolBinaryFunction rebolBinaryOperator + +hi def link rebolType Type +hi def link rebolTypeFunction rebolOperator + +hi def link rebolWord Identifier +hi def link rebolWordPath rebolWord +hi def link rebolFunction Function + +hi def link rebolCharacter Character +hi def link rebolSpecialCharacter SpecialChar +hi def link rebolString String + +hi def link rebolNumber Number +hi def link rebolInteger rebolNumber +hi def link rebolDecimal rebolNumber +hi def link rebolTime rebolNumber +hi def link rebolDate rebolNumber +hi def link rebolMoney rebolNumber +hi def link rebolBinary rebolNumber +hi def link rebolEmail rebolString +hi def link rebolFile rebolString +hi def link rebolURL rebolString +hi def link rebolIssue rebolNumber +hi def link rebolTuple rebolNumber +hi def link rebolFloat Float +hi def link rebolBoolean Boolean + +hi def link rebolConstant Constant + +hi def link rebolComment Comment + +hi def link rebolError Error + + +if exists("my_rebol_file") + if file_readable(expand(my_rebol_file)) + execute "source " . my_rebol_file + endif +endif + +let b:current_syntax = "rebol" + +" vim: ts=8 + +endif diff --git a/syntax/redif.vim b/syntax/redif.vim new file mode 100644 index 0000000..d1ccc00 --- /dev/null +++ b/syntax/redif.vim @@ -0,0 +1,974 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: ReDIF +" Maintainer: Axel Castellane +" Last Change: 2013 April 17 +" Original Author: Axel Castellane +" Source: http://openlib.org/acmes/root/docu/redif_1.html +" File Extension: rdf +" Note: The ReDIF format is used by RePEc. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" ReDIF is case-insensitive +syntax case ignore + +" Structure: Some fields determine what fields can come next. For example: +" Template-Type +" *-Name +" File-URL +" *-Institution +" Those fields span a syntax region over several lines so that these regions +" can only contain their respective items. + +" Any line which is not a correct template or part of an argument is an error. +" This comes at the very beginning, so it has the lowest priority and will +" only match if nothing else did. +syntax match redifWrongLine /^.\+/ display + +highlight def link redifWrongLine redifError + +" Comments must start with # and it must be the first character of the line, +" otherwise I believe that they are considered as part of an argument. +syntax match redifComment /^#.*/ containedin=ALL display + +" Defines the 9 possible multi-lines regions of Template-Type and the fields +" they can contain. +syntax region redifRegionTemplatePaper start=/^Template-Type:\_s*ReDIF-Paper \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsPaper,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile fold +syntax region redifRegionTemplateArticle start=/^Template-Type:\_s*ReDIF-Article \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsArticle,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile fold +syntax region redifRegionTemplateChapter start=/^Template-Type:\_s*ReDIF-Chapter \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsChapter,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor fold +syntax region redifRegionTemplateBook start=/^Template-Type:\_s*ReDIF-Book \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsBook,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor fold +syntax region redifRegionTemplateSoftware start=/^Template-Type:\_s*ReDIF-Software \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsSoftware,redifWrongLine,redifRegionClusterAuthor,redifRegionClusterFile fold +syntax region redifRegionTemplateArchive start=/^Template-Type:\_s*ReDIF-Archive \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsArchive,redifWrongLine fold +syntax region redifRegionTemplateSeries start=/^Template-Type:\_s*ReDIF-Series \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsSeries,redifWrongLine,redifRegionClusterProvider,redifRegionClusterPublisher,redifRegionClusterEditor fold +syntax region redifRegionTemplateInstitution start=/^Template-Type:\_s*ReDIF-Institution \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsInstitution,redifWrongLine,redifRegionClusterPrimary,redifRegionClusterSecondary,redifRegionClusterTertiary,redifRegionClusterQuaternary fold +syntax region redifRegionTemplatePerson start=/^Template-Type:\_s*ReDIF-Person \d\+\.\d\+/ end=/^Template-Type:/me=s-1 contains=redifContainerFieldsPerson,redifWrongLine,redifRegionClusterWorkplace fold + +" All fields are foldable (These come before clusters, so they have lower +" priority). So they are contained in a foldable syntax region. +syntax region redifContainerFieldsPaper start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTitle,redifFieldHandleOfWork,redifFieldLanguage,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNumber,redifFieldCreationDate,redifFieldRevisionDate,redifFieldPublicationStatus,redifFieldNote,redifFieldLength,redifFieldSeries,redifFieldAvailability,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldRestriction,redifFieldPrice,redifFieldNotification,redifFieldPublicationType,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsArticle start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTitle,redifFieldHandleOfWork,redifFieldLanguage,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNumber,redifFieldCreationDate,redifFieldPublicationStatus,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldRestriction,redifFieldPrice,redifFieldNotification,redifFieldPublicationType,redifFieldJournal,redifFieldVolume,redifFieldYear,redifFieldIssue,redifFieldMonth,redifFieldPages,redifFieldNumber,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsChapter start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfWork,redifFieldTitle,redifFieldContactEmail,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldBookTitle,redifFieldYear,redifFieldMonth,redifFieldPages,redifFieldChapter,redifFieldVolume,redifFieldEdition,redifFieldSeries,redifFieldISBN,redifFieldPublicationStatus,redifFieldNote,redifFieldInBook,redifFieldOrderURL,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsBook start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTitle,redifFieldHandleOfWork,redifFieldContactEmail,redifFieldYear,redifFieldMonth,redifFieldVolume,redifFieldEdition,redifFieldSeries,redifFieldISBN,redifFieldPublicationStatus,redifFieldNote,redifFieldAbstract,redifFieldClassificationJEL,redifFieldKeywords,redifFieldHasChapter,redifFieldPrice,redifFieldOrderURL,redifFieldNumber,redifFieldCreationDate,redifFieldPublicationDate,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsSoftware start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfWork,redifFieldTitle,redifFieldProgrammingLanguage,redifFieldAbstract,redifFieldNumber,redifFieldVersion,redifFieldClassificationJEL,redifFieldKeywords,redifFieldSize,redifFieldSeries,redifFieldCreationDate,redifFieldRevisionDate,redifFieldNote,redifFieldRequires,redifFieldArticleHandle,redifFieldBookHandle,redifFieldChapterHandle,redifFieldPaperHandle,redifFieldSoftwareHandle,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsArchive start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfArchive,redifFieldURL,redifFieldMaintainerEmail,redifFieldName,redifFieldMaintainerName,redifFieldMaintainerPhone,redifFieldMaintainerFax,redifFieldClassificationJEL,redifFieldHomepage,redifFieldDescription,redifFieldNotification,redifFieldRestriction,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsSeries start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldName,redifFieldHandleOfSeries,redifFieldMaintainerEmail,redifFieldType,redifFieldOrderEmail,redifFieldOrderHomepage,redifFieldOrderPostal,redifFieldPrice,redifFieldRestriction,redifFieldMaintainerPhone,redifFieldMaintainerFax,redifFieldMaintainerName,redifFieldDescription,redifFieldClassificationJEL,redifFieldKeywords,redifFieldNotification,redifFieldISSN,redifFieldFollowup,redifFieldPredecessor,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsInstitution start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfInstitution,redifFieldPrimaryDefunct,redifFieldSecondaryDefunct,redifFieldTertiaryDefunct,redifFieldTemplateType,redifWrongLine contained transparent fold +syntax region redifContainerFieldsPerson start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldHandleOfPerson,redifFieldNameFull,redifFieldNameFirst,redifFieldNameLast,redifFieldNamePrefix,redifFieldNameMiddle,redifFieldNameSuffix,redifFieldNameASCII,redifFieldEmail,redifFieldHomepage,redifFieldFax,redifFieldPostal,redifFieldPhone,redifFieldWorkplaceOrganization,redifFieldAuthorPaper,redifFieldAuthorArticle,redifFieldAuthorSoftware,redifFieldAuthorBook,redifFieldAuthorChapter,redifFieldEditorBook,redifFieldEditorSeries,redifFieldClassificationJEL,redifFieldShortId,redifFieldLastLoginDate,redifFieldRegisteredDate,redifWrongLine contained transparent fold + +" Defines the 10 possible clusters and what they can contain +" A field not in the cluster ends the cluster. +syntax region redifRegionClusterWorkplace start=/^Workplace-Name:/ skip=/^Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsWorkplace fold +syntax region redifRegionClusterPrimary start=/^Primary-Name:/ skip=/^Primary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsPrimary fold +syntax region redifRegionClusterSecondary start=/^Secondary-Name:/ skip=/^Secondary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsSecondary fold +syntax region redifRegionClusterTertiary start=/^Tertiary-Name:/ skip=/^Tertiary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsTertiary fold +syntax region redifRegionClusterQuaternary start=/^Quaternary-Name:/ skip=/^Quaternary-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsQuaternary fold +syntax region redifRegionClusterProvider start=/^Provider-Name:/ skip=/^Provider-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsProvider fold +syntax region redifRegionClusterPublisher start=/^Publisher-Name:/ skip=/^Publisher-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsPublisher fold +syntax region redifRegionClusterAuthor start=/^Author-Name:/ skip=/^Author-\%(Name\%(-First\|-Last\)\|Homepage\|Email\|Fax\|Postal\|Phone\|Person\|Workplace-Name\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifRegionClusterAuthorWorkplace,redifContainerFieldsAuthor fold +syntax region redifRegionClusterEditor start=/^Editor-Name:/ skip=/^Editor-\%(Name\%(-First\|-Last\)\|Homepage\|Email\|Fax\|Postal\|Phone\|Person\|Workplace-Name\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifRegionClusterEditorWorkplace,redifContainerFieldsEditor fold +syntax region redifRegionClusterFile start=/^File-URL:/ skip=/^File-\%(Format\|Function\|Size\|Restriction\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsFile fold + +" The foldable containers of the clusters. +syntax region redifContainerFieldsWorkplace start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldWorkplaceName,redifFieldWorkplaceHomepage,redifFieldWorkplaceNameEnglish,redifFieldWorkplacePostal,redifFieldWorkplaceLocation,redifFieldWorkplaceEmail,redifFieldWorkplacePhone,redifFieldWorkplaceFax,redifFieldWorkplaceInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsPrimary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldPrimaryName,redifFieldPrimaryHomepage,redifFieldPrimaryNameEnglish,redifFieldPrimaryPostal,redifFieldPrimaryLocation,redifFieldPrimaryEmail,redifFieldPrimaryPhone,redifFieldPrimaryFax,redifFieldPrimaryInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsSecondary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldSecondaryName,redifFieldSecondaryHomepage,redifFieldSecondaryNameEnglish,redifFieldSecondaryPostal,redifFieldSecondaryLocation,redifFieldSecondaryEmail,redifFieldSecondaryPhone,redifFieldSecondaryFax,redifFieldSecondaryInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsTertiary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldTertiaryName,redifFieldTertiaryHomepage,redifFieldTertiaryNameEnglish,redifFieldTertiaryPostal,redifFieldTertiaryLocation,redifFieldTertiaryEmail,redifFieldTertiaryPhone,redifFieldTertiaryFax,redifFieldTertiaryInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsQuaternary start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldQuaternaryName,redifFieldQuaternaryHomepage,redifFieldQuaternaryNameEnglish,redifFieldQuaternaryPostal,redifFieldQuaternaryLocation,redifFieldQuaternaryEmail,redifFieldQuaternaryPhone,redifFieldQuaternaryFax,redifFieldQuaternaryInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsProvider start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldProviderName,redifFieldProviderHomepage,redifFieldProviderNameEnglish,redifFieldProviderPostal,redifFieldProviderLocation,redifFieldProviderEmail,redifFieldProviderPhone,redifFieldProviderFax,redifFieldProviderInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsPublisher start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldPublisherName,redifFieldPublisherHomepage,redifFieldPublisherNameEnglish,redifFieldPublisherPostal,redifFieldPublisherLocation,redifFieldPublisherEmail,redifFieldPublisherPhone,redifFieldPublisherFax,redifFieldPublisherInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsAuthor start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldAuthorName,redifFieldAuthorNameFirst,redifFieldAuthorNameLast,redifFieldAuthorHomepage,redifFieldAuthorEmail,redifFieldAuthorFax,redifFieldAuthorPostal,redifFieldAuthorPhone,redifFieldAuthorPerson,redifWrongLine contained transparent fold +syntax region redifContainerFieldsEditor start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldEditorName,redifFieldEditorNameFirst,redifFieldEditorNameLast,redifFieldEditorHomepage,redifFieldEditorEmail,redifFieldEditorFax,redifFieldEditorPostal,redifFieldEditorPhone,redifFieldEditorPerson,redifWrongLine contained transparent fold +syntax region redifContainerFieldsFile start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldFileURL,redifFieldFileFormat,redifFieldFileFunction,redifFieldFileSize,redifFieldFileRestriction,redifWrongLine contained transparent fold + +" The two clusters in cluster (must be presented after to have priority over +" fields containers) +syntax region redifRegionClusterAuthorWorkplace start=/^Author-Workplace-Name:/ skip=/^Author-Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsAuthorWorkplace fold +syntax region redifRegionClusterEditorWorkplace start=/^Editor-Workplace-Name:/ skip=/^Editor-Workplace-\%(Name-English\|Homepage\|Postal\|Location\|Email\|Phone\|Fax\|Institution\):/ end=/^\S\{-}:/me=s-1 contained contains=redifWrongLine,redifContainerFieldsEditorWorkplace fold + +" Their foldable fields containers +syntax region redifContainerFieldsAuthorWorkplace start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldAuthorWorkplaceName,redifFieldAuthorWorkplaceHomepage,redifFieldAuthorWorkplaceNameEnglish,redifFieldAuthorWorkplacePostal,redifFieldAuthorWorkplaceLocation,redifFieldAuthorWorkplaceEmail,redifFieldAuthorWorkplacePhone,redifFieldAuthorWorkplaceFax,redifFieldAuthorWorkplaceInstitution,redifWrongLine contained transparent fold +syntax region redifContainerFieldsEditorWorkplace start=/^\S\{-}:/ end=/^\S\{-}:/me=s-1 contains=redifFieldEditorWorkplaceName,redifFieldEditorWorkplaceHomepage,redifFieldEditorWorkplaceNameEnglish,redifFieldEditorWorkplacePostal,redifFieldEditorWorkplaceLocation,redifFieldEditorWorkplaceEmail,redifFieldEditorWorkplacePhone,redifFieldEditorWorkplaceFax,redifFieldEditorWorkplaceInstitution,redifWrongLine contained transparent fold + +" All the possible fields +" Note: The "Handle" field is handled a little bit differently, because it +" does not have the same meaning depending on the Template-Type. See: +" /redifFieldHandleOf.... +syntax match redifFieldAbstract /^Abstract:/ skipwhite skipempty nextgroup=redifArgumentAbstract contained +syntax match redifFieldArticleHandle /^Article-Handle:/ skipwhite skipempty nextgroup=redifArgumentArticleHandle contained +syntax match redifFieldAuthorArticle /^Author-Article:/ skipwhite skipempty nextgroup=redifArgumentAuthorArticle contained +syntax match redifFieldAuthorBook /^Author-Book:/ skipwhite skipempty nextgroup=redifArgumentAuthorBook contained +syntax match redifFieldAuthorChapter /^Author-Chapter:/ skipwhite skipempty nextgroup=redifArgumentAuthorChapter contained +syntax match redifFieldAuthorEmail /^Author-Email:/ skipwhite skipempty nextgroup=redifArgumentAuthorEmail contained +syntax match redifFieldAuthorFax /^Author-Fax:/ skipwhite skipempty nextgroup=redifArgumentAuthorFax contained +syntax match redifFieldAuthorHomepage /^Author-Homepage:/ skipwhite skipempty nextgroup=redifArgumentAuthorHomepage contained +syntax match redifFieldAuthorName /^Author-Name:/ skipwhite skipempty nextgroup=redifArgumentAuthorName contained +syntax match redifFieldAuthorNameFirst /^Author-Name-First:/ skipwhite skipempty nextgroup=redifArgumentAuthorNameFirst contained +syntax match redifFieldAuthorNameLast /^Author-Name-Last:/ skipwhite skipempty nextgroup=redifArgumentAuthorNameLast contained +syntax match redifFieldAuthorPaper /^Author-Paper:/ skipwhite skipempty nextgroup=redifArgumentAuthorPaper contained +syntax match redifFieldAuthorPerson /^Author-Person:/ skipwhite skipempty nextgroup=redifArgumentAuthorPerson contained +syntax match redifFieldAuthorPhone /^Author-Phone:/ skipwhite skipempty nextgroup=redifArgumentAuthorPhone contained +syntax match redifFieldAuthorPostal /^Author-Postal:/ skipwhite skipempty nextgroup=redifArgumentAuthorPostal contained +syntax match redifFieldAuthorSoftware /^Author-Software:/ skipwhite skipempty nextgroup=redifArgumentAuthorSoftware contained +syntax match redifFieldAuthorWorkplaceEmail /^Author-Workplace-Email:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplaceEmail contained +syntax match redifFieldAuthorWorkplaceFax /^Author-Workplace-Fax:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplaceFax contained +syntax match redifFieldAuthorWorkplaceHomepage /^Author-Workplace-Homepage:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplaceHomepage contained +syntax match redifFieldAuthorWorkplaceInstitution /^Author-Workplace-Institution:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplaceInstitution contained +syntax match redifFieldAuthorWorkplaceLocation /^Author-Workplace-Location:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplaceLocation contained +syntax match redifFieldAuthorWorkplaceName /^Author-Workplace-Name:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplaceName contained +syntax match redifFieldAuthorWorkplaceNameEnglish /^Author-Workplace-Name-English:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplaceNameEnglish contained +syntax match redifFieldAuthorWorkplacePhone /^Author-Workplace-Phone:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplacePhone contained +syntax match redifFieldAuthorWorkplacePostal /^Author-Workplace-Postal:/ skipwhite skipempty nextgroup=redifArgumentAuthorWorkplacePostal contained +syntax match redifFieldAvailability /^Availability:/ skipwhite skipempty nextgroup=redifArgumentAvailability contained +syntax match redifFieldBookHandle /^Book-Handle:/ skipwhite skipempty nextgroup=redifArgumentBookHandle contained +syntax match redifFieldBookTitle /^Book-Title:/ skipwhite skipempty nextgroup=redifArgumentBookTitle contained +syntax match redifFieldChapterHandle /^Chapter-Handle:/ skipwhite skipempty nextgroup=redifArgumentChapterHandle contained +syntax match redifFieldChapter /^Chapter:/ skipwhite skipempty nextgroup=redifArgumentChapter contained +syntax match redifFieldClassificationJEL /^Classification-JEL:/ skipwhite skipempty nextgroup=redifArgumentClassificationJEL contained +syntax match redifFieldContactEmail /^Contact-Email:/ skipwhite skipempty nextgroup=redifArgumentContactEmail contained +syntax match redifFieldCreationDate /^Creation-Date:/ skipwhite skipempty nextgroup=redifArgumentCreationDate contained +syntax match redifFieldDescription /^Description:/ skipwhite skipempty nextgroup=redifArgumentDescription contained +syntax match redifFieldEdition /^Edition:/ skipwhite skipempty nextgroup=redifArgumentEdition contained +syntax match redifFieldEditorBook /^Editor-Book:/ skipwhite skipempty nextgroup=redifArgumentEditorBook contained +syntax match redifFieldEditorEmail /^Editor-Email:/ skipwhite skipempty nextgroup=redifArgumentEditorEmail contained +syntax match redifFieldEditorFax /^Editor-Fax:/ skipwhite skipempty nextgroup=redifArgumentEditorFax contained +syntax match redifFieldEditorHomepage /^Editor-Homepage:/ skipwhite skipempty nextgroup=redifArgumentEditorHomepage contained +syntax match redifFieldEditorName /^Editor-Name:/ skipwhite skipempty nextgroup=redifArgumentEditorName contained +syntax match redifFieldEditorNameFirst /^Editor-Name-First:/ skipwhite skipempty nextgroup=redifArgumentEditorNameFirst contained +syntax match redifFieldEditorNameLast /^Editor-Name-Last:/ skipwhite skipempty nextgroup=redifArgumentEditorNameLast contained +syntax match redifFieldEditorPerson /^Editor-Person:/ skipwhite skipempty nextgroup=redifArgumentEditorPerson contained +syntax match redifFieldEditorPhone /^Editor-Phone:/ skipwhite skipempty nextgroup=redifArgumentEditorPhone contained +syntax match redifFieldEditorPostal /^Editor-Postal:/ skipwhite skipempty nextgroup=redifArgumentEditorPostal contained +syntax match redifFieldEditorSeries /^Editor-Series:/ skipwhite skipempty nextgroup=redifArgumentEditorSeries contained +syntax match redifFieldEditorWorkplaceEmail /^Editor-Workplace-Email:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplaceEmail contained +syntax match redifFieldEditorWorkplaceFax /^Editor-Workplace-Fax:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplaceFax contained +syntax match redifFieldEditorWorkplaceHomepage /^Editor-Workplace-Homepage:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplaceHomepage contained +syntax match redifFieldEditorWorkplaceInstitution /^Editor-Workplace-Institution:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplaceInstitution contained +syntax match redifFieldEditorWorkplaceLocation /^Editor-Workplace-Location:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplaceLocation contained +syntax match redifFieldEditorWorkplaceName /^Editor-Workplace-Name:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplaceName contained +syntax match redifFieldEditorWorkplaceNameEnglish /^Editor-Workplace-Name-English:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplaceNameEnglish contained +syntax match redifFieldEditorWorkplacePhone /^Editor-Workplace-Phone:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplacePhone contained +syntax match redifFieldEditorWorkplacePostal /^Editor-Workplace-Postal:/ skipwhite skipempty nextgroup=redifArgumentEditorWorkplacePostal contained +syntax match redifFieldEmail /^Email:/ skipwhite skipempty nextgroup=redifArgumentEmail contained +syntax match redifFieldFax /^Fax:/ skipwhite skipempty nextgroup=redifArgumentFax contained +syntax match redifFieldFileFormat /^File-Format:/ skipwhite skipempty nextgroup=redifArgumentFileFormat contained +syntax match redifFieldFileFunction /^File-Function:/ skipwhite skipempty nextgroup=redifArgumentFileFunction contained +syntax match redifFieldFileRestriction /^File-Restriction:/ skipwhite skipempty nextgroup=redifArgumentFileRestriction contained +syntax match redifFieldFileSize /^File-Size:/ skipwhite skipempty nextgroup=redifArgumentFileSize contained +syntax match redifFieldFileURL /^File-URL:/ skipwhite skipempty nextgroup=redifArgumentFileURL contained +syntax match redifFieldFollowup /^Followup:/ skipwhite skipempty nextgroup=redifArgumentFollowup contained +syntax match redifFieldHandleOfArchive /^Handle:/ skipwhite skipempty nextgroup=redifArgumentHandleOfArchive contained +syntax match redifFieldHandleOfInstitution /^Handle:/ skipwhite skipempty nextgroup=redifArgumentHandleOfInstitution contained +syntax match redifFieldHandleOfPerson /^Handle:/ skipwhite skipempty nextgroup=redifArgumentHandleOfPerson contained +syntax match redifFieldHandleOfSeries /^Handle:/ skipwhite skipempty nextgroup=redifArgumentHandleOfSeries contained +syntax match redifFieldHandleOfWork /^Handle:/ skipwhite skipempty nextgroup=redifArgumentHandleOfWork contained +syntax match redifFieldHasChapter /^HasChapter:/ skipwhite skipempty nextgroup=redifArgumentHasChapter contained +syntax match redifFieldHomepage /^Homepage:/ skipwhite skipempty nextgroup=redifArgumentHomepage contained +syntax match redifFieldInBook /^In-Book:/ skipwhite skipempty nextgroup=redifArgumentInBook contained +syntax match redifFieldISBN /^ISBN:/ skipwhite skipempty nextgroup=redifArgumentISBN contained +syntax match redifFieldISSN /^ISSN:/ skipwhite skipempty nextgroup=redifArgumentISSN contained +syntax match redifFieldIssue /^Issue:/ skipwhite skipempty nextgroup=redifArgumentIssue contained +syntax match redifFieldJournal /^Journal:/ skipwhite skipempty nextgroup=redifArgumentJournal contained +syntax match redifFieldKeywords /^Keywords:/ skipwhite skipempty nextgroup=redifArgumentKeywords contained +syntax match redifFieldKeywords /^Keywords:/ skipwhite skipempty nextgroup=redifArgumentKeywords contained +syntax match redifFieldLanguage /^Language:/ skipwhite skipempty nextgroup=redifArgumentLanguage contained +syntax match redifFieldLastLoginDate /^Last-Login-Date:/ skipwhite skipempty nextgroup=redifArgumentLastLoginDate contained +syntax match redifFieldLength /^Length:/ skipwhite skipempty nextgroup=redifArgumentLength contained +syntax match redifFieldMaintainerEmail /^Maintainer-Email:/ skipwhite skipempty nextgroup=redifArgumentMaintainerEmail contained +syntax match redifFieldMaintainerFax /^Maintainer-Fax:/ skipwhite skipempty nextgroup=redifArgumentMaintainerFax contained +syntax match redifFieldMaintainerName /^Maintainer-Name:/ skipwhite skipempty nextgroup=redifArgumentMaintainerName contained +syntax match redifFieldMaintainerPhone /^Maintainer-Phone:/ skipwhite skipempty nextgroup=redifArgumentMaintainerPhone contained +syntax match redifFieldMonth /^Month:/ skipwhite skipempty nextgroup=redifArgumentMonth contained +syntax match redifFieldNameASCII /^Name-ASCII:/ skipwhite skipempty nextgroup=redifArgumentNameASCII contained +syntax match redifFieldNameFirst /^Name-First:/ skipwhite skipempty nextgroup=redifArgumentNameFirst contained +syntax match redifFieldNameFull /^Name-Full:/ skipwhite skipempty nextgroup=redifArgumentNameFull contained +syntax match redifFieldNameLast /^Name-Last:/ skipwhite skipempty nextgroup=redifArgumentNameLast contained +syntax match redifFieldNameMiddle /^Name-Middle:/ skipwhite skipempty nextgroup=redifArgumentNameMiddle contained +syntax match redifFieldNamePrefix /^Name-Prefix:/ skipwhite skipempty nextgroup=redifArgumentNamePrefix contained +syntax match redifFieldNameSuffix /^Name-Suffix:/ skipwhite skipempty nextgroup=redifArgumentNameSuffix contained +syntax match redifFieldName /^Name:/ skipwhite skipempty nextgroup=redifArgumentName contained +syntax match redifFieldNote /^Note:/ skipwhite skipempty nextgroup=redifArgumentNote contained +syntax match redifFieldNotification /^Notification:/ skipwhite skipempty nextgroup=redifArgumentNotification contained +syntax match redifFieldNumber /^Number:/ skipwhite skipempty nextgroup=redifArgumentNumber contained +syntax match redifFieldOrderEmail /^Order-Email:/ skipwhite skipempty nextgroup=redifArgumentOrderEmail contained +syntax match redifFieldOrderHomepage /^Order-Homepage:/ skipwhite skipempty nextgroup=redifArgumentOrderHomepage contained +syntax match redifFieldOrderPostal /^Order-Postal:/ skipwhite skipempty nextgroup=redifArgumentOrderPostal contained +syntax match redifFieldOrderURL /^Order-URL:/ skipwhite skipempty nextgroup=redifArgumentOrderURL contained +syntax match redifFieldPages /^Pages:/ skipwhite skipempty nextgroup=redifArgumentPages contained +syntax match redifFieldPaperHandle /^Paper-Handle:/ skipwhite skipempty nextgroup=redifArgumentPaperHandle contained +syntax match redifFieldPhone /^Phone:/ skipwhite skipempty nextgroup=redifArgumentPhone contained +syntax match redifFieldPostal /^Postal:/ skipwhite skipempty nextgroup=redifArgumentPostal contained +syntax match redifFieldPredecessor /^Predecessor:/ skipwhite skipempty nextgroup=redifArgumentPredecessor contained +syntax match redifFieldPrice /^Price:/ skipwhite skipempty nextgroup=redifArgumentPrice contained +syntax match redifFieldPrimaryDefunct /^Primary-Defunct:/ skipwhite skipempty nextgroup=redifArgumentPrimaryDefunct contained +syntax match redifFieldPrimaryEmail /^Primary-Email:/ skipwhite skipempty nextgroup=redifArgumentPrimaryEmail contained +syntax match redifFieldPrimaryFax /^Primary-Fax:/ skipwhite skipempty nextgroup=redifArgumentPrimaryFax contained +syntax match redifFieldPrimaryHomepage /^Primary-Homepage:/ skipwhite skipempty nextgroup=redifArgumentPrimaryHomepage contained +syntax match redifFieldPrimaryInstitution /^Primary-Institution:/ skipwhite skipempty nextgroup=redifArgumentPrimaryInstitution contained +syntax match redifFieldPrimaryLocation /^Primary-Location:/ skipwhite skipempty nextgroup=redifArgumentPrimaryLocation contained +syntax match redifFieldPrimaryName /^Primary-Name:/ skipwhite skipempty nextgroup=redifArgumentPrimaryName contained +syntax match redifFieldPrimaryNameEnglish /^Primary-Name-English:/ skipwhite skipempty nextgroup=redifArgumentPrimaryNameEnglish contained +syntax match redifFieldPrimaryPhone /^Primary-Phone:/ skipwhite skipempty nextgroup=redifArgumentPrimaryPhone contained +syntax match redifFieldPrimaryPostal /^Primary-Postal:/ skipwhite skipempty nextgroup=redifArgumentPrimaryPostal contained +syntax match redifFieldProgrammingLanguage /^Programming-Language:/ skipwhite skipempty nextgroup=redifArgumentProgrammingLanguage contained +syntax match redifFieldProviderEmail /^Provider-Email:/ skipwhite skipempty nextgroup=redifArgumentProviderEmail contained +syntax match redifFieldProviderFax /^Provider-Fax:/ skipwhite skipempty nextgroup=redifArgumentProviderFax contained +syntax match redifFieldProviderHomepage /^Provider-Homepage:/ skipwhite skipempty nextgroup=redifArgumentProviderHomepage contained +syntax match redifFieldProviderInstitution /^Provider-Institution:/ skipwhite skipempty nextgroup=redifArgumentProviderInstitution contained +syntax match redifFieldProviderLocation /^Provider-Location:/ skipwhite skipempty nextgroup=redifArgumentProviderLocation contained +syntax match redifFieldProviderName /^Provider-Name:/ skipwhite skipempty nextgroup=redifArgumentProviderName contained +syntax match redifFieldProviderNameEnglish /^Provider-Name-English:/ skipwhite skipempty nextgroup=redifArgumentProviderNameEnglish contained +syntax match redifFieldProviderPhone /^Provider-Phone:/ skipwhite skipempty nextgroup=redifArgumentProviderPhone contained +syntax match redifFieldProviderPostal /^Provider-Postal:/ skipwhite skipempty nextgroup=redifArgumentProviderPostal contained +syntax match redifFieldPublicationDate /^Publication-Date:/ skipwhite skipempty nextgroup=redifArgumentPublicationDate contained +syntax match redifFieldPublicationStatus /^Publication-Status:/ skipwhite skipempty nextgroup=redifArgumentPublicationStatus contained +syntax match redifFieldPublicationType /^Publication-Type:/ skipwhite skipempty nextgroup=redifArgumentPublicationType contained +syntax match redifFieldQuaternaryEmail /^Quaternary-Email:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryEmail contained +syntax match redifFieldQuaternaryFax /^Quaternary-Fax:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryFax contained +syntax match redifFieldQuaternaryHomepage /^Quaternary-Homepage:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryHomepage contained +syntax match redifFieldQuaternaryInstitution /^Quaternary-Institution:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryInstitution contained +syntax match redifFieldQuaternaryLocation /^Quaternary-Location:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryLocation contained +syntax match redifFieldQuaternaryName /^Quaternary-Name:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryName contained +syntax match redifFieldQuaternaryNameEnglish /^Quaternary-Name-English:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryNameEnglish contained +syntax match redifFieldQuaternaryPhone /^Quaternary-Phone:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryPhone contained +syntax match redifFieldQuaternaryPostal /^Quaternary-Postal:/ skipwhite skipempty nextgroup=redifArgumentQuaternaryPostal contained +syntax match redifFieldRegisteredDate /^Registered-Date:/ skipwhite skipempty nextgroup=redifArgumentRegisteredDate contained +syntax match redifFieldRequires /^Requires:/ skipwhite skipempty nextgroup=redifArgumentRequires contained +syntax match redifFieldRestriction /^Restriction:/ skipwhite skipempty nextgroup=redifArgumentRestriction contained +syntax match redifFieldRevisionDate /^Revision-Date:/ skipwhite skipempty nextgroup=redifArgumentRevisionDate contained +syntax match redifFieldSecondaryDefunct /^Secondary-Defunct:/ skipwhite skipempty nextgroup=redifArgumentSecondaryDefunct contained +syntax match redifFieldSecondaryEmail /^Secondary-Email:/ skipwhite skipempty nextgroup=redifArgumentSecondaryEmail contained +syntax match redifFieldSecondaryFax /^Secondary-Fax:/ skipwhite skipempty nextgroup=redifArgumentSecondaryFax contained +syntax match redifFieldSecondaryHomepage /^Secondary-Homepage:/ skipwhite skipempty nextgroup=redifArgumentSecondaryHomepage contained +syntax match redifFieldSecondaryInstitution /^Secondary-Institution:/ skipwhite skipempty nextgroup=redifArgumentSecondaryInstitution contained +syntax match redifFieldSecondaryLocation /^Secondary-Location:/ skipwhite skipempty nextgroup=redifArgumentSecondaryLocation contained +syntax match redifFieldSecondaryName /^Secondary-Name:/ skipwhite skipempty nextgroup=redifArgumentSecondaryName contained +syntax match redifFieldSecondaryNameEnglish /^Secondary-Name-English:/ skipwhite skipempty nextgroup=redifArgumentSecondaryNameEnglish contained +syntax match redifFieldSecondaryPhone /^Secondary-Phone:/ skipwhite skipempty nextgroup=redifArgumentSecondaryPhone contained +syntax match redifFieldSecondaryPostal /^Secondary-Postal:/ skipwhite skipempty nextgroup=redifArgumentSecondaryPostal contained +syntax match redifFieldSeries /^Series:/ skipwhite skipempty nextgroup=redifArgumentSeries contained +syntax match redifFieldShortId /^Short-Id:/ skipwhite skipempty nextgroup=redifArgumentShortId contained +syntax match redifFieldSize /^Size:/ skipwhite skipempty nextgroup=redifArgumentSize contained +syntax match redifFieldSoftwareHandle /^Software-Handle:/ skipwhite skipempty nextgroup=redifArgumentSoftwareHandle contained +syntax match redifFieldTemplateType /^Template-Type:/ skipwhite skipempty nextgroup=redifArgumentTemplateType contained +syntax match redifFieldTertiaryDefunct /^Tertiary-Defunct:/ skipwhite skipempty nextgroup=redifArgumentTertiaryDefunct contained +syntax match redifFieldTertiaryEmail /^Tertiary-Email:/ skipwhite skipempty nextgroup=redifArgumentTertiaryEmail contained +syntax match redifFieldTertiaryFax /^Tertiary-Fax:/ skipwhite skipempty nextgroup=redifArgumentTertiaryFax contained +syntax match redifFieldTertiaryHomepage /^Tertiary-Homepage:/ skipwhite skipempty nextgroup=redifArgumentTertiaryHomepage contained +syntax match redifFieldTertiaryInstitution /^Tertiary-Institution:/ skipwhite skipempty nextgroup=redifArgumentTertiaryInstitution contained +syntax match redifFieldTertiaryLocation /^Tertiary-Location:/ skipwhite skipempty nextgroup=redifArgumentTertiaryLocation contained +syntax match redifFieldTertiaryName /^Tertiary-Name:/ skipwhite skipempty nextgroup=redifArgumentTertiaryName contained +syntax match redifFieldTertiaryNameEnglish /^Tertiary-Name-English:/ skipwhite skipempty nextgroup=redifArgumentTertiaryNameEnglish contained +syntax match redifFieldTertiaryPhone /^Tertiary-Phone:/ skipwhite skipempty nextgroup=redifArgumentTertiaryPhone contained +syntax match redifFieldTertiaryPostal /^Tertiary-Postal:/ skipwhite skipempty nextgroup=redifArgumentTertiaryPostal contained +syntax match redifFieldTitle /^Title:/ skipwhite skipempty nextgroup=redifArgumentTitle contained +syntax match redifFieldType /^Type:/ skipwhite skipempty nextgroup=redifArgumentType contained +syntax match redifFieldURL /^URL:/ skipwhite skipempty nextgroup=redifArgumentURL contained +syntax match redifFieldVersion /^Version:/ skipwhite skipempty nextgroup=redifArgumentVersion contained +syntax match redifFieldVolume /^Volume:/ skipwhite skipempty nextgroup=redifArgumentVolume contained +syntax match redifFieldWorkplaceEmail /^Workplace-Email:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceEmail contained +syntax match redifFieldWorkplaceFax /^Workplace-Fax:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceFax contained +syntax match redifFieldWorkplaceHomepage /^Workplace-Homepage:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceHomepage contained +syntax match redifFieldWorkplaceInstitution /^Workplace-Institution:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceInstitution contained +syntax match redifFieldWorkplaceLocation /^Workplace-Location:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceLocation contained +syntax match redifFieldWorkplaceName /^Workplace-Name:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceName contained +syntax match redifFieldWorkplaceNameEnglish /^Workplace-Name-English:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceNameEnglish contained +syntax match redifFieldWorkplaceOrganization /^Workplace-Organization:/ skipwhite skipempty nextgroup=redifArgumentWorkplaceOrganization contained +syntax match redifFieldWorkplacePhone /^Workplace-Phone:/ skipwhite skipempty nextgroup=redifArgumentWorkplacePhone contained +syntax match redifFieldWorkplacePostal /^Workplace-Postal:/ skipwhite skipempty nextgroup=redifArgumentWorkplacePostal contained +syntax match redifFieldYear /^Year:/ skipwhite skipempty nextgroup=redifArgumentYear contained + +highlight def link redifFieldAbstract redifField +highlight def link redifFieldArticleHandle redifField +highlight def link redifFieldAuthorArticle redifField +highlight def link redifFieldAuthorBook redifField +highlight def link redifFieldAuthorChapter redifField +highlight def link redifFieldAuthorEmail redifField +highlight def link redifFieldAuthorFax redifField +highlight def link redifFieldAuthorHomepage redifField +highlight def link redifFieldAuthorName redifField +highlight def link redifFieldAuthorNameFirst redifField +highlight def link redifFieldAuthorNameLast redifField +highlight def link redifFieldAuthorPaper redifField +highlight def link redifFieldAuthorPerson redifField +highlight def link redifFieldAuthorPhone redifField +highlight def link redifFieldAuthorPostal redifField +highlight def link redifFieldAuthorSoftware redifField +highlight def link redifFieldAuthorWorkplaceEmail redifField +highlight def link redifFieldAuthorWorkplaceFax redifField +highlight def link redifFieldAuthorWorkplaceHomepage redifField +highlight def link redifFieldAuthorWorkplaceInstitution redifField +highlight def link redifFieldAuthorWorkplaceLocation redifField +highlight def link redifFieldAuthorWorkplaceName redifField +highlight def link redifFieldAuthorWorkplaceNameEnglish redifField +highlight def link redifFieldAuthorWorkplacePhone redifField +highlight def link redifFieldAuthorWorkplacePostal redifField +highlight def link redifFieldAvailability redifField +highlight def link redifFieldBookHandle redifField +highlight def link redifFieldBookTitle redifField +highlight def link redifFieldChapterHandle redifField +highlight def link redifFieldChapter redifField +highlight def link redifFieldClassificationJEL redifField +highlight def link redifFieldContactEmail redifField +highlight def link redifFieldCreationDate redifField +highlight def link redifFieldDescription redifField +highlight def link redifFieldEdition redifField +highlight def link redifFieldEditorBook redifField +highlight def link redifFieldEditorEmail redifField +highlight def link redifFieldEditorFax redifField +highlight def link redifFieldEditorHomepage redifField +highlight def link redifFieldEditorName redifField +highlight def link redifFieldEditorNameFirst redifField +highlight def link redifFieldEditorNameLast redifField +highlight def link redifFieldEditorPerson redifField +highlight def link redifFieldEditorPhone redifField +highlight def link redifFieldEditorPostal redifField +highlight def link redifFieldEditorSeries redifField +highlight def link redifFieldEditorWorkplaceEmail redifField +highlight def link redifFieldEditorWorkplaceFax redifField +highlight def link redifFieldEditorWorkplaceHomepage redifField +highlight def link redifFieldEditorWorkplaceInstitution redifField +highlight def link redifFieldEditorWorkplaceLocation redifField +highlight def link redifFieldEditorWorkplaceName redifField +highlight def link redifFieldEditorWorkplaceNameEnglish redifField +highlight def link redifFieldEditorWorkplacePhone redifField +highlight def link redifFieldEditorWorkplacePostal redifField +highlight def link redifFieldEmail redifField +highlight def link redifFieldFax redifField +highlight def link redifFieldFileFormat redifField +highlight def link redifFieldFileFunction redifField +highlight def link redifFieldFileRestriction redifField +highlight def link redifFieldFileSize redifField +highlight def link redifFieldFileURL redifField +highlight def link redifFieldFollowup redifField +highlight def link redifFieldHandleOfArchive redifField +highlight def link redifFieldHandleOfInstitution redifField +highlight def link redifFieldHandleOfPerson redifField +highlight def link redifFieldHandleOfSeries redifField +highlight def link redifFieldHandleOfWork redifField +highlight def link redifFieldHasChapter redifField +highlight def link redifFieldHomepage redifField +highlight def link redifFieldInBook redifField +highlight def link redifFieldISBN redifField +highlight def link redifFieldISSN redifField +highlight def link redifFieldIssue redifField +highlight def link redifFieldJournal redifField +highlight def link redifFieldKeywords redifField +highlight def link redifFieldKeywords redifField +highlight def link redifFieldLanguage redifField +highlight def link redifFieldLastLoginDate redifField +highlight def link redifFieldLength redifField +highlight def link redifFieldMaintainerEmail redifField +highlight def link redifFieldMaintainerFax redifField +highlight def link redifFieldMaintainerName redifField +highlight def link redifFieldMaintainerPhone redifField +highlight def link redifFieldMonth redifField +highlight def link redifFieldNameASCII redifField +highlight def link redifFieldNameFirst redifField +highlight def link redifFieldNameFull redifField +highlight def link redifFieldNameLast redifField +highlight def link redifFieldNameMiddle redifField +highlight def link redifFieldNamePrefix redifField +highlight def link redifFieldNameSuffix redifField +highlight def link redifFieldName redifField +highlight def link redifFieldNote redifField +highlight def link redifFieldNotification redifField +highlight def link redifFieldNumber redifField +highlight def link redifFieldOrderEmail redifField +highlight def link redifFieldOrderHomepage redifField +highlight def link redifFieldOrderPostal redifField +highlight def link redifFieldOrderURL redifField +highlight def link redifFieldPages redifField +highlight def link redifFieldPaperHandle redifField +highlight def link redifFieldPhone redifField +highlight def link redifFieldPostal redifField +highlight def link redifFieldPredecessor redifField +highlight def link redifFieldPrice redifField +highlight def link redifFieldPrimaryDefunct redifField +highlight def link redifFieldPrimaryEmail redifField +highlight def link redifFieldPrimaryFax redifField +highlight def link redifFieldPrimaryHomepage redifField +highlight def link redifFieldPrimaryInstitution redifField +highlight def link redifFieldPrimaryLocation redifField +highlight def link redifFieldPrimaryName redifField +highlight def link redifFieldPrimaryNameEnglish redifField +highlight def link redifFieldPrimaryPhone redifField +highlight def link redifFieldPrimaryPostal redifField +highlight def link redifFieldProgrammingLanguage redifField +highlight def link redifFieldProviderEmail redifField +highlight def link redifFieldProviderFax redifField +highlight def link redifFieldProviderHomepage redifField +highlight def link redifFieldProviderInstitution redifField +highlight def link redifFieldProviderLocation redifField +highlight def link redifFieldProviderName redifField +highlight def link redifFieldProviderNameEnglish redifField +highlight def link redifFieldProviderPhone redifField +highlight def link redifFieldProviderPostal redifField +highlight def link redifFieldPublicationDate redifField +highlight def link redifFieldPublicationStatus redifField +highlight def link redifFieldPublicationType redifField +highlight def link redifFieldQuaternaryEmail redifField +highlight def link redifFieldQuaternaryFax redifField +highlight def link redifFieldQuaternaryHomepage redifField +highlight def link redifFieldQuaternaryInstitution redifField +highlight def link redifFieldQuaternaryLocation redifField +highlight def link redifFieldQuaternaryName redifField +highlight def link redifFieldQuaternaryNameEnglish redifField +highlight def link redifFieldQuaternaryPhone redifField +highlight def link redifFieldQuaternaryPostal redifField +highlight def link redifFieldRegisteredDate redifField +highlight def link redifFieldRequires redifField +highlight def link redifFieldRestriction redifField +highlight def link redifFieldRevisionDate redifField +highlight def link redifFieldSecondaryDefunct redifField +highlight def link redifFieldSecondaryEmail redifField +highlight def link redifFieldSecondaryFax redifField +highlight def link redifFieldSecondaryHomepage redifField +highlight def link redifFieldSecondaryInstitution redifField +highlight def link redifFieldSecondaryLocation redifField +highlight def link redifFieldSecondaryName redifField +highlight def link redifFieldSecondaryNameEnglish redifField +highlight def link redifFieldSecondaryPhone redifField +highlight def link redifFieldSecondaryPostal redifField +highlight def link redifFieldSeries redifField +highlight def link redifFieldShortId redifField +highlight def link redifFieldSize redifField +highlight def link redifFieldSoftwareHandle redifField +highlight def link redifFieldTemplateType redifField +highlight def link redifFieldTertiaryDefunct redifField +highlight def link redifFieldTertiaryEmail redifField +highlight def link redifFieldTertiaryFax redifField +highlight def link redifFieldTertiaryHomepage redifField +highlight def link redifFieldTertiaryInstitution redifField +highlight def link redifFieldTertiaryLocation redifField +highlight def link redifFieldTertiaryName redifField +highlight def link redifFieldTertiaryNameEnglish redifField +highlight def link redifFieldTertiaryPhone redifField +highlight def link redifFieldTertiaryPostal redifField +highlight def link redifFieldTitle redifField +highlight def link redifFieldTitle redifField +highlight def link redifFieldType redifField +highlight def link redifFieldURL redifField +highlight def link redifFieldVersion redifField +highlight def link redifFieldVolume redifField +highlight def link redifFieldWorkplaceEmail redifField +highlight def link redifFieldWorkplaceFax redifField +highlight def link redifFieldWorkplaceHomepage redifField +highlight def link redifFieldWorkplaceInstitution redifField +highlight def link redifFieldWorkplaceLocation redifField +highlight def link redifFieldWorkplaceName redifField +highlight def link redifFieldWorkplaceNameEnglish redifField +highlight def link redifFieldWorkplaceOrganization redifField +highlight def link redifFieldWorkplacePhone redifField +highlight def link redifFieldWorkplacePostal redifField +highlight def link redifFieldYear redifField + +" Deprecated +" same as Provider-* +" nextgroup=redifArgumentProvider* +syntax match redifFieldPublisherEmail /^Publisher-Email:/ skipwhite skipempty nextgroup=redifArgumentProviderEmail contained +syntax match redifFieldPublisherFax /^Publisher-Fax:/ skipwhite skipempty nextgroup=redifArgumentProviderFax contained +syntax match redifFieldPublisherHomepage /^Publisher-Homepage:/ skipwhite skipempty nextgroup=redifArgumentProviderHomepage contained +syntax match redifFieldPublisherInstitution /^Publisher-Institution:/ skipwhite skipempty nextgroup=redifArgumentProviderInstitution contained +syntax match redifFieldPublisherLocation /^Publisher-Location:/ skipwhite skipempty nextgroup=redifArgumentProviderLocation contained +syntax match redifFieldPublisherName /^Publisher-Name:/ skipwhite skipempty nextgroup=redifArgumentProviderName contained +syntax match redifFieldPublisherNameEnglish /^Publisher-Name-English:/ skipwhite skipempty nextgroup=redifArgumentProviderNameEnglish contained +syntax match redifFieldPublisherPhone /^Publisher-Phone:/ skipwhite skipempty nextgroup=redifArgumentProviderPhone contained +syntax match redifFieldPublisherPostal /^Publisher-Postal:/ skipwhite skipempty nextgroup=redifArgumentProviderPostal contained + +highlight def link redifFieldPublisherEmail redifFieldDeprecated +highlight def link redifFieldPublisherFax redifFieldDeprecated +highlight def link redifFieldPublisherHomepage redifFieldDeprecated +highlight def link redifFieldPublisherInstitution redifFieldDeprecated +highlight def link redifFieldPublisherLocation redifFieldDeprecated +highlight def link redifFieldPublisherName redifFieldDeprecated +highlight def link redifFieldPublisherNameEnglish redifFieldDeprecated +highlight def link redifFieldPublisherPhone redifFieldDeprecated +highlight def link redifFieldPublisherPostal redifFieldDeprecated + +" Standard arguments +" By default, they contain all the argument until another field is started: +" start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 +" For arguments that must not span more than one line, use a match: +" /\%(^\S\{-}:\)\@!\S.*/ +" AND ADD "display" +" This is faster. +" +" Those arguments are not highlighted so far. They are here for future +" extensions. +" TODO Find more RegEx for these arguments +" TODO Fax, Phone +" TODO URL, Homepage +" TODO Keywords +" TODO Classification-JEL +" TODO Short-Id, Author-Person, Editor-Person +" +" Arguments that may span several lines: +syntax region redifArgumentAuthorWorkplaceLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorWorkplacePostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorWorkplacePostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentFileFunction start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentIssue start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentJournal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentOrderPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrice start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrimaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrimaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentProviderLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentProviderPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentQuaternaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentQuaternaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentRequires start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSecondaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSecondaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSize start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentTertiaryLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentTertiaryPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentVersion start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplaceLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplacePhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplacePostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained + +" Arguments that may not span several lines: +" If you are sure that these arguments cannot span several lines, change +" them to a match: +" /\%(^\S\{-}:\)\@!\S.*/ +" AND ADD "display" after "contained" +" You can use this command on each line that you want to change: +" :s+\Vregion \(\w\+\) start=/\\%(^\\S\\{-}:\\)\\@!\\S/ end=/^\\S\\{-}:/me=s-1 contained+match \1 /\\%(^\\S\\{-}:\\)\\@!\\S.*/ contained display +syntax region redifArgumentAuthorFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorNameFirst start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorNameLast start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorPerson start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorPostal start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorWorkplaceFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorWorkplaceHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorWorkplaceName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorWorkplaceNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentAuthorWorkplacePhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorNameFirst start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorNameLast start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorPerson start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorWorkplaceFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorWorkplaceHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorWorkplaceLocation start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorWorkplaceName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorWorkplaceNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentEditorWorkplacePhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentFileURL start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentMaintainerFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentMaintainerName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentMaintainerPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentNameFirst start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentNameFull start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentNameLast start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentNameMiddle start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentNamePrefix start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentNameSuffix start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentNumber start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentOrderHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentOrderURL start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrimaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrimaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrimaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrimaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentPrimaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentProviderFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentProviderHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentProviderName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentProviderNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentProviderPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentQuaternaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentQuaternaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentQuaternaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentQuaternaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentQuaternaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSecondaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSecondaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSecondaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSecondaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSecondaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentSeries start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentShortId start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentTertiaryFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentTertiaryHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentTertiaryName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentTertiaryNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentTertiaryPhone start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentURL start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplaceFax start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplaceHomepage start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplaceName start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplaceNameEnglish start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained +syntax region redifArgumentWorkplaceOrganization start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contained + +" Special arguments +" Those arguments require special values +" TODO Improve some RegEx +" TODO Improve Emails +" TODO Improve ISBN +" TODO Improve ISSN +" TODO Improve spell check (add words from economics. +" expl=macroeconometrics, Schumpeterian, IS-LM, etc.) +" +" Template-Type +syntax match redifArgumentTemplateType /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectTemplateType contained display +syntax match redifCorrectTemplateType /ReDIF-\%(Paper\|Article\|Chapter\|Book\|Software\|Archive\|Series\|Institution\|Person\)/ nextgroup=redifTemplateVersionNumberContainer contained display +syntax match redifTemplateVersionNumberContainer /.\+/ contains=redifTemplateVersionNumber contained display +syntax match redifTemplateVersionNumber / \d\+\.\d\+/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentTemplateType redifError +highlight def link redifCorrectTemplateType Constant +highlight def link redifTemplateVersionNumber Number +highlight def link redifTemplateVersionNumberContainer redifError + +" Handles: +" +" Handles of Works: +syntax match redifArgumentHandleOfWork /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentAuthorArticle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentAuthorBook /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentAuthorChapter /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentAuthorPaper /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentAuthorSoftware /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentEditorBook /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentEditorSeries /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentInBook /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentHasChapter /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentArticleHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentBookHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentChapterHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentPaperHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifArgumentSoftwareHandle /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfWork contained display +syntax match redifCorrectHandleOfWork /RePEc:\a\a\a:\%(_\@!\w\)\{6}:\S\+/ contains=redifForbiddenCharactersInHandle,redifBestPracticeInHandle nextgroup=redifWrongLineEnding contained display +" TODO Are those characters really forbidden??? +syntax match redifForbiddenCharactersInHandle /[\/*?"<>|]/ contained display +syntax match redifBestPracticeInHandle /\<\%([vi]:[1-9]\d*\|y:[1-9]\d\{3}\|p:[1-9]\d*-[1-9]\d*\|i:\%(jan\|feb\|mar\|apr\|may\|jun\|jul\|aug\|sep\|oct\|nov\|dec\|spr\|sum\|aut\|win\|spe\|Q[1-4]\|\d\d-\d\d\)\|Q:[1-4]\)\>/ contained display + +highlight def link redifArgumentHandleOfWork redifError +highlight def link redifArgumentAuthorArticle redifError +highlight def link redifArgumentAuthorBook redifError +highlight def link redifArgumentAuthorChapter redifError +highlight def link redifArgumentAuthorPaper redifError +highlight def link redifArgumentAuthorSoftware redifError +highlight def link redifArgumentEditorBook redifError +highlight def link redifArgumentEditorSeries redifError +highlight def link redifArgumentInBook redifError +highlight def link redifArgumentHasChapter redifError +highlight def link redifArgumentArticleHandle redifError +highlight def link redifArgumentBookHandle redifError +highlight def link redifArgumentChapterHandle redifError +highlight def link redifArgumentPaperHandle redifError +highlight def link redifArgumentSoftwareHandle redifError +highlight def link redifForbiddenCharactersInHandle redifError +highlight def link redifBestPracticeInHandle redifSpecial + +" Handles of Series: +syntax match redifArgumentHandleOfSeries /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfSeries contained display +syntax match redifArgumentFollowup /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfSeries contained display +syntax match redifArgumentPredecessor /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfSeries contained display +syntax match redifCorrectHandleOfSeries /RePEc:\a\a\a:\%(_\@!\w\)\{6}/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentHandleOfSeries redifError +highlight def link redifArgumentFollowup redifError +highlight def link redifArgumentPredecessor redifError + +" Handles of Archives: +syntax match redifArgumentHandleOfArchive /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfArchive contained display +syntax match redifCorrectHandleOfArchive /RePEc:\a\a\a/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentHandleOfArchive redifError + +" Handles of Person: +syntax match redifArgumentHandleOfPerson /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfPerson contained display +syntax match redifCorrectHandleOfPerson /\%(\%(:\@!\S\)\{-}:\)\{2}[1-9]\d\{3}\%(-02\%(-[12]\d\|-0[1-9]\)\|-\%(0[469]\|11\)\%(-30\|-[12]\d\|-0[1-9]\)\|-\%(0[13578]\|1[02]\)\%(-3[01]\|-[12]\d\|-0[1-9]\)\):\S\+/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentHandleOfPerson redifError + +" Handles of Institution: +syntax match redifArgumentAuthorWorkplaceInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentEditorWorkplaceInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentPrimaryInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentProviderInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentPublisherInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentQuaternaryInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentSecondaryInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentTertiaryInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentWorkplaceInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentHandleOfInstitution /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentPrimaryDefunct /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentSecondaryDefunct /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +syntax match redifArgumentTertiaryDefunct /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectHandleOfInstitution contained display +" TODO Are digits authorized? Apparently not. +" Country codes: +" http://www.iso.org/iso/country_codes/iso_3166_code_lists/country_names_and_code_elements.htm +syntax match redifCorrectHandleOfInstitution /RePEc:\a\a\a:\a\{5}\(ea\|af\|ax\|al\|dz\|as\|ad\|ao\|ai\|aq\|ag\|ar\|am\|aw\|au\|at\|az\|bs\|bh\|bd\|bb\|by\|be\|bz\|bj\|bm\|bt\|bo\|bq\|ba\|bw\|bv\|br\|io\|bn\|bg\|bf\|bi\|kh\|cm\|ca\|cv\|ky\|cf\|td\|cl\|cn\|cx\|cc\|co\|km\|cg\|cd\|ck\|cr\|ci\|hr\|cu\|cw\|cy\|cz\|dk\|dj\|dm\|do\|ec\|eg\|sv\|gq\|er\|ee\|et\|fk\|fo\|fj\|fi\|fr\|gf\|pf\|tf\|ga\|gm\|ge\|de\|gh\|gi\|gr\|gl\|gd\|gp\|gu\|gt\|gg\|gn\|gw\|gy\|ht\|hm\|va\|hn\|hk\|hu\|is\|in\|id\|ir\|iq\|ie\|im\|il\|it\|jm\|jp\|je\|jo\|kz\|ke\|ki\|kp\|kr\|kw\|kg\|la\|lv\|lb\|ls\|lr\|ly\|li\|lt\|lu\|mo\|mk\|mg\|mw\|my\|mv\|ml\|mt\|mh\|mq\|mr\|mu\|yt\|mx\|fm\|md\|mc\|mn\|me\|ms\|ma\|mz\|mm\|na\|nr\|np\|nl\|nc\|nz\|ni\|ne\|ng\|nu\|nf\|mp\|no\|om\|pk\|pw\|ps\|pa\|pg\|py\|pe\|ph\|pn\|pl\|pt\|pr\|qa\|re\|ro\|ru\|rw\|bl\|sh\|kn\|lc\|mf\|pm\|vc\|ws\|sm\|st\|sa\|sn\|rs\|sc\|sl\|sg\|sx\|sk\|si\|sb\|so\|za\|gs\|ss\|es\|lk\|sd\|sr\|sj\|sz\|se\|ch\|sy\|tw\|tj\|tz\|th\|tl\|tg\|tk\|to\|tt\|tn\|tr\|tm\|tc\|tv\|ug\|ua\|ae\|gb\|us\|um\|uy\|uz\|vu\|ve\|vn\|vg\|vi\|wf\|eh\|ye\|zm\|zw\)/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentHandleOfInstitution redifError +highlight def link redifArgumentPrimaryDefunct redifError +highlight def link redifArgumentSecondaryDefunct redifError +highlight def link redifArgumentTertiaryDefunct redifError + +" Emails: +syntax match redifArgumentAuthorEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentAuthorWorkplaceEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentContactEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentEditorEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentEditorWorkplaceEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentMaintainerEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentOrderEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentPrimaryEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentProviderEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentPublisherEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentQuaternaryEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentSecondaryEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentTertiaryEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifArgumentWorkplaceEmail /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectEmail contained display +syntax match redifCorrectEmail /\%(@\@!\S\)\+@\%(@\@!\S\)\+/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentAuthorEmail redifError +highlight def link redifArgumentAuthorWorkplaceEmail redifError +highlight def link redifArgumentContactEmail redifError +highlight def link redifArgumentEditorEmail redifError +highlight def link redifArgumentEditorWorkplaceEmail redifError +highlight def link redifArgumentEmail redifError +highlight def link redifArgumentMaintainerEmail redifError +highlight def link redifArgumentOrderEmail redifError +highlight def link redifArgumentPrimaryEmail redifError +highlight def link redifArgumentProviderEmail redifError +highlight def link redifArgumentPublisherEmail redifError +highlight def link redifArgumentQuaternaryEmail redifError +highlight def link redifArgumentSecondaryEmail redifError +highlight def link redifArgumentTertiaryEmail redifError +highlight def link redifArgumentWorkplaceEmail redifError + +" Language +" Source: https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes +syntax match redifArgumentLanguage /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectLanguage contained display +syntax match redifCorrectLanguage /\<\(aa\|ab\|af\|ak\|als\|am\|an\|ang\|ar\|arc\|as\|ast\|av\|ay\|az\|ba\|bar\|bat-smg\|bcl\|be\|be-x-old\|bg\|bh\|bi\|bm\|bn\|bo\|bpy\|br\|bs\|bug\|bxr\|ca\|ce\|ceb\|ch\|cho\|chr\|chy\|co\|cr\|cs\|csb\|cu\|cv\|cy\|da\|de\|diq\|dsb\|dv\|dz\|ee\|el\|en\|eo\|es\|et\|eu\|ext\|fa\|ff\|fi\|fiu-vro\|fj\|fo\|fr\|frp\|fur\|fy\|ga\|gd\|gil\|gl\|gn\|got\|gu\|gv\|ha\|haw\|he\|hi\|ho\|hr\|ht\|hu\|hy\|hz\|ia\|id\|ie\|ig\|ii\|ik\|ilo\|io\|is\|it\|iu\|ja\|jbo\|jv\|ka\|kg\|ki\|kj\|kk\|kl\|km\|kn\|khw\|ko\|kr\|ks\|ksh\|ku\|kv\|kw\|ky\|la\|lad\|lan\|lb\|lg\|li\|lij\|lmo\|ln\|lo\|lt\|lv\|map-bms\|mg\|mh\|mi\|mk\|ml\|mn\|mo\|mr\|ms\|mt\|mus\|my\|na\|nah\|nap\|nd\|nds\|nds-nl\|ne\|new\|ng\|nl\|nn\|no\|nr\|nso\|nrm\|nv\|ny\|oc\|oj\|om\|or\|os\|pa\|pag\|pam\|pap\|pdc\|pi\|pih\|pl\|pms\|ps\|pt\|qu\|rm\|rmy\|rn\|ro\|roa-rup\|ru\|rw\|sa\|sc\|scn\|sco\|sd\|se\|sg\|sh\|si\|simple\|sk\|sl\|sm\|sn\|so\|sq\|sr\|ss\|st\|su\|sv\|sw\|ta\|te\|tet\|tg\|th\|ti\|tk\|tl\|tlh\|tn\|to\|tpi\|tr\|ts\|tt\|tum\|tw\|ty\|udm\|ug\|uk\|ur\|uz\|ve\|vi\|vec\|vls\|vo\|wa\|war\|wo\|xal\|xh\|yi\|yo\|za\|zh\|zh-min-nan\|zh-yue\|zu\)\>/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentLanguage redifError +highlight def link redifCorrectLanguage redifSpecial + +" Length +" Based on the example in the documentation. But apparently any field is +" possible +syntax region redifArgumentLength start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=redifGoodLength contained +syntax match redifGoodLength /1 page\|[1-9]\d*\%( pages\)\=/ contained display + +highlight def link redifGoodLength redifSpecial + +" Publication-Type +syntax match redifArgumentPublicationType /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectPublicationType contained display +syntax match redifCorrectPublicationType /\<\(journal article\|book\|book chapter\|working paper\|conference paper\|report\|other\)\>/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentPublicationType redifError +highlight def link redifCorrectPublicationType redifSpecial + +" Publication-Status +syntax region redifArgumentPublicationStatus start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=redifSpecialPublicationStatus contained +syntax match redifSpecialPublicationStatus /published\|forthcoming/ nextgroup=redifCorrectPublicationStatus contained display +syntax region redifCorrectPublicationStatus start=/./ end=/^\S\{-}:/me=s-1 contained + +highlight def link redifArgumentPublicationStatus redifError +highlight def link redifSpecialPublicationStatus redifSpecial + +" Month +" TODO Are numbers also allowed? +syntax match redifArgumentMonth /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodMonth contained display +syntax match redifGoodMonth /\<\(Jan\%(uary\)\=\|Feb\%(ruary\)\=\|Mar\%(ch\)\=\|Apr\%(il\)\=\|May\|June\=\|July\=\|Aug\%(ust\)\=\|Sep\%(tember\)\=\|Oct\%(ober\)\=\|Nov\%(ember\)\=\|Dec\%(ember\)\=\)\>/ contained display + +highlight def link redifGoodMonth redifSpecial + +" Integers: Volume, Chapter +syntax match redifArgumentVolume /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectInteger contained display +syntax match redifArgumentChapter /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectInteger contained display +syntax match redifCorrectInteger /[1-9]\d*/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentVolume redifError +highlight def link redifArgumentChapter redifError + +" Year +syntax match redifArgumentYear /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectYear contained display +syntax match redifCorrectYear /[1-9]\d\{3}/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentYear redifError + +" Edition +" Based on the example in the documentation. +syntax match redifArgumentEdition /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodEdition contained display +syntax match redifGoodEdition /1st\|2nd\|3rd\|[4-9]th\|[1-9]\d*\%(1st\|2nd\|3rd\|[4-9]th\)\|[1-9]\d*/ contained display + +highlight def link redifGoodEdition redifSpecial + +" ISBN +syntax match redifArgumentISBN /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodISBN contained display +syntax match redifGoodISBN /\d[0-9-]\{8,15}\d/ contained display + +highlight def link redifGoodISBN redifSpecial + +" ISSN +syntax match redifArgumentISSN /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodISSN contained display +syntax match redifGoodISSN /\d\{4}-\d\{3}[0-9X]/ contained display + +highlight def link redifGoodISSN redifSpecial + +" File-Size +" Based on the example in the documentation. +syntax region redifArgumentFileSize start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=redifGoodSize contained +syntax match redifGoodSize /kb\|bytes/ contained display + +highlight def link redifGoodSize redifSpecial + +" Type +syntax match redifArgumentType /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectType contained display +syntax match redifCorrectType /ReDIF-Paper\|ReDIF-Software\|ReDIF-Article\|ReDIF-Chapter\|ReDIF-Book/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentType redifError +highlight def link redifCorrectType redifSpecial + +" Dates: Publication-Date, Creation-Date, Revision-Date, +" Last-Login-Date, Registration-Date +syntax match redifArgumentCreationDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display +syntax match redifArgumentLastLoginDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display +syntax match redifArgumentPublicationDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display +syntax match redifArgumentRegisteredDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display +syntax match redifArgumentRevisionDate /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectDate contained display +syntax match redifCorrectDate /[1-9]\d\{3}\%(-02\%(-[12]\d\|-0[1-9]\)\=\|-\%(0[469]\|11\)\%(-30\|-[12]\d\|-0[1-9]\)\=\|-\%(0[13578]\|1[02]\)\%(-3[01]\|-[12]\d\|-0[1-9]\)\=\)\=/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentCreationDate redifError +highlight def link redifArgumentLastLoginDate redifError +highlight def link redifArgumentPublicationDate redifError +highlight def link redifArgumentRegisteredDate redifError +highlight def link redifArgumentRevisionDate redifError + +" Classification-JEL +syntax match redifArgumentClassificationJEL /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectJEL contained display +syntax match redifCorrectJEL /\<\%(\u\d\{,2}[,; \t]\s*\)*\u\d\{,2}/ contains=redifSpecialJEL nextgroup=redifWrongLineEnding contained display +syntax match redifSpecialJEL /\<\u\d\{,2}/ contained display + +highlight def link redifArgumentClassificationJEL redifError +highlight def link redifSpecialJEL redifSpecial + +" Pages +syntax match redifArgumentPages /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectPages contained display +syntax match redifCorrectPages /[1-9]\d*-[1-9]\d*/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifArgumentPages redifError + +" Name-ASCII +syntax match redifArgumentNameASCII /\%(^\S\{-}:\)\@!\S.*/ contains=redifCorrectNameASCII contained display +syntax match redifCorrectNameASCII /[ -~]/ contained display + +highlight def link redifArgumentNameASCII redifError + +" Programming-Language +syntax match redifArgumentProgrammingLanguage /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodProgrammingLanguage contained display +syntax match redifGoodProgrammingLanguage /\/ nextgroup=redifWrongLineEnding contained display + +highlight def link redifGoodProgrammingLanguage redifSpecial + +" File-Format +" TODO The link in the documentation that gives the list of possible formats is broken. +" ftp://ftp.isi.edu/in-notes/iana/assignments/media-types/media-types +" These are based on the examples in the documentation. +syntax match redifArgumentFileFormat /\%(^\S\{-}:\)\@!\S.*/ contains=redifGoodFormat contained display +syntax match redifGoodFormat "\a\+/[[:alpha:]+-]\+" nextgroup=redifWrongLineEnding contains=redifSpecialFormat contained display +syntax match redifSpecialFormat "application/atom+xml\|application/ecmascript\|application/EDI-X12\|application/EDIFACT\|application/json\|application/javascript\|application/octet-stream\|application/ogg\|application/pdf\|application/postscript\|application/rdf+xml\|application/rss+xml\|application/soap+xml\|application/font-woff\|application/xhtml+xml\|application/xml\|application/xml-dtd\|application/xop+xml\|application/zip\|application/gzip\|audio/basic\|audio/L24\|audio/mp4\|audio/mpeg\|audio/ogg\|audio/vorbis\|audio/vnd.rn-realaudio\|audio/vnd.wave\|audio/webm\|image/gif\|image/jpeg\|image/pjpeg\|image/png\|image/svg+xml\|image/tiff\|image/vnd.microsoft.icon\|message/http\|message/imdn+xml\|message/partial\|message/rfc822\|model/example\|model/iges\|model/mesh\|model/vrml\|model/x3d+binary\|model/x3d+vrml\|model/x3d+xml\|multipart/mixed\|multipart/alternative\|multipart/related\|multipart/form-data\|multipart/signed\|multipart/encrypted\|text/cmd\|text/css\|text/csv\|text/html\|text/javascript\|text/plain\|text/vcard\|text/xml\|video/mpeg\|video/mp4\|video/ogg\|video/quicktime\|video/webm\|video/x-matroska\|video/x-ms-wmv\|video/x-flv" contained display + +highlight def link redifSpecialFormat redifSpecial +highlight def link redifArgumentFileFormat redifError + +" Keywords +" Spell checked +syntax match redifArgumentKeywords /\%(^\S\{-}:\)\@!\S.*/ contains=@Spell,redifKeywordsSemicolon contained +syntax match redifKeywordsSemicolon /;/ contained + +highlight def link redifKeywordsSemicolon redifSpecial + +" Other spell-checked arguments +" Very useful when copy-pasting abstracts that may contain hyphens or +" ligatures. +syntax region redifArgumentAbstract start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentAvailability start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentBookTitle start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentDescription start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentFileRestriction start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentNote start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentNotification start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentRestriction start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained +syntax region redifArgumentTitle start=/\%(^\S\{-}:\)\@!\S/ end=/^\S\{-}:/me=s-1 contains=@Spell contained + +" Wrong line ending +syntax match redifWrongLineEnding /.\+/ contained display + +highlight def link redifWrongLineEnding redifError + +" Final highlight +highlight def link redifComment Comment +highlight def link redifError Error +highlight def link redifField Identifier +highlight def link redifFieldDeprecated Identifier +highlight def link redifSpecial Special +" For deprecated fields: +highlight redifFieldDeprecated term=undercurl cterm=undercurl gui=undercurl guisp=DarkGrey + +" Sync: The template-type (ReDIF-Paper, ReDIF-Archive, etc.) influences which +" fields can follow. Thus sync must search backwards for it. +" +" I would like to simply ask VIM to search backward for the first occurence of +" /^Template-Type:/, but it does not seem to be possible, so I have to start +" from the beginning of the file... This might slow down a lot for files that +" contain a lot of Template-Type statements. +syntax sync fromstart + +" The problem with syntax sync match (tried below), it is that, for example, +" it cannot realize when it is inside a Author-Name cluster, which is inside a +" Template-Type template... +" +" TODO Is this linecont pattern really useful? It seems to work anyway... +"syntax sync linecont /^\(Template-Type:\)\=\s*$/ +" TODO This sync is surprising... It seems to work on several lines even +" though I replaced \_s* by \s*, even without the linecont pattern... +"syntax sync match redifSyncForTemplatePaper groupthere redifRegionTemplatePaper /^Template-Type:\s*ReDIF-Paper \d\+\.\d\+/ +"syntax sync match redifSyncForTemplateArticle groupthere redifRegionTemplateArticle /^Template-Type:\s*ReDIF-Article \d\+\.\d\+/ +"syntax sync match redifSyncForTemplateChapter groupthere redifRegionTemplateChapter /^Template-Type:\s*ReDIF-Chapter \d\+\.\d\+/ +"syntax sync match redifSyncForTemplateBook groupthere redifRegionTemplateBook /^Template-Type:\s*ReDIF-Book \d\+\.\d\+/ +"syntax sync match redifSyncForTemplateSoftware groupthere redifRegionTemplateSoftware /^Template-Type:\s*ReDIF-Software \d\+\.\d\+/ +"syntax sync match redifSyncForTemplateArchive groupthere redifRegionTemplateArchive /^Template-Type:\s*ReDIF-Archive \d\+\.\d\+/ +"syntax sync match redifSyncForTemplateSeries groupthere redifRegionTemplateSeries /^Template-Type:\s*ReDIF-Series \d\+\.\d\+/ +"syntax sync match redifSyncForTemplateInstitution groupthere redifRegionTemplateInstitution /^Template-Type:\s*ReDIF-Institution \d\+\.\d\+/ +"syntax sync match redifSyncForTemplatePerson groupthere redifRegionTemplatePerson /^Template-Type:\s*ReDIF-Person \d\+\.\d\+/ + +" I do not really know how sync linebreaks works, but it helps when making +" changes on the argument when this argument is not on the same line than its +" field. I just assume that people won't leave more than one line of +" whitespace between fields and arguments (which is already very unlikely) +" hence the value of 2. +syntax sync linebreaks=2 + +" Since folding is defined by the syntax, set foldmethod to syntax. +set foldmethod=syntax + +" Set "b:current_syntax" to the name of the syntax at the end: +let b:current_syntax="redif" + +endif diff --git a/syntax/registry.vim b/syntax/registry.vim new file mode 100644 index 0000000..3d66602 --- /dev/null +++ b/syntax/registry.vim @@ -0,0 +1,107 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Windows Registry export with regedit (*.reg) +" Maintainer: Dominique Stéphan (dominique@mggen.com) +" URL: http://www.mggen.com/vim/syntax/registry.zip (doesn't work) +" Last change: 2014 Oct 31 +" Included patch from Alexander A. Ulitin + +" clear any unwanted syntax defs +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" shut case off +syn case ignore + +" Head of regedit .reg files, it's REGEDIT4 on Win9#/NT +syn match registryHead "^REGEDIT[0-9]*\s*$\|^Windows Registry Editor Version \d*\.\d*\s*$" + +" Comment +syn match registryComment "^;.*$" + +" Registry Key constant +syn keyword registryHKEY HKEY_LOCAL_MACHINE HKEY_CLASSES_ROOT HKEY_CURRENT_USER +syn keyword registryHKEY HKEY_USERS HKEY_CURRENT_CONFIG HKEY_DYN_DATA +" Registry Key shortcuts +syn keyword registryHKEY HKLM HKCR HKCU HKU HKCC HKDD + +" Some values often found in the registry +" GUID (Global Unique IDentifier) +syn match registryGUID "{[0-9A-Fa-f]\{8}\-[0-9A-Fa-f]\{4}\-[0-9A-Fa-f]\{4}\-[0-9A-Fa-f]\{4}\-[0-9A-Fa-f]\{12}}" contains=registrySpecial + +" Disk +" syn match registryDisk "[a-zA-Z]:\\\\" + +" Special and Separator characters +syn match registrySpecial "\\" +syn match registrySpecial "\\\\" +syn match registrySpecial "\\\"" +syn match registrySpecial "\." +syn match registrySpecial "," +syn match registrySpecial "\/" +syn match registrySpecial ":" +syn match registrySpecial "-" + +" String +syn match registryString "\".*\"" contains=registryGUID,registrySpecial + +" Path +syn region registryPath start="\[" end="\]" contains=registryHKEY,registryGUID,registrySpecial + +" Path to remove +" like preceding path but with a "-" at begin +syn region registryRemove start="\[\-" end="\]" contains=registryHKEY,registryGUID,registrySpecial + +" Subkey +syn match registrySubKey "^\".*\"=" +" Default value +syn match registrySubKey "^@=" + +" Numbers + +" Hex or Binary +" The format can be precised between () : +" 0 REG_NONE +" 1 REG_SZ +" 2 REG_EXPAND_SZ +" 3 REG_BINARY +" 4 REG_DWORD, REG_DWORD_LITTLE_ENDIAN +" 5 REG_DWORD_BIG_ENDIAN +" 6 REG_LINK +" 7 REG_MULTI_SZ +" 8 REG_RESOURCE_LIST +" 9 REG_FULL_RESOURCE_DESCRIPTOR +" 10 REG_RESOURCE_REQUIREMENTS_LIST +" The value can take several lines, if \ ends the line +" The limit to 999 matches is arbitrary, it avoids Vim crashing on a very long +" line of hex values that ends in a comma. +"syn match registryHex "hex\(([0-9]\{0,2})\)\=:\([0-9a-fA-F]\{2},\)\{0,999}\([0-9a-fA-F]\{2}\|\\\)$" contains=registrySpecial +syn match registryHex "hex\(([0-9]\{0,2})\)\=:\([0-9a-fA-F]\{2},\)*\([0-9a-fA-F]\{2}\|\\\)$" contains=registrySpecial +syn match registryHex "^\s*\([0-9a-fA-F]\{2},\)\{0,999}\([0-9a-fA-F]\{2}\|\\\)$" contains=registrySpecial +" Dword (32 bits) +syn match registryDword "dword:[0-9a-fA-F]\{8}$" contains=registrySpecial + + +" The default methods for highlighting. Can be overridden later +hi def link registryComment Comment +hi def link registryHead Constant +hi def link registryHKEY Constant +hi def link registryPath Special +hi def link registryRemove PreProc +hi def link registryGUID Identifier +hi def link registrySpecial Special +hi def link registrySubKey Type +hi def link registryString String +hi def link registryHex Number +hi def link registryDword Number + + + +let b:current_syntax = "registry" + +" vim:ts=8 + +endif diff --git a/syntax/remind.vim b/syntax/remind.vim new file mode 100644 index 0000000..a0e79b6 --- /dev/null +++ b/syntax/remind.vim @@ -0,0 +1,77 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Remind +" Maintainer: Davide Alberani +" Last Change: 02 Nov 2015 +" Version: 0.7 +" URL: http://ismito.it/vim/syntax/remind.vim +" +" Remind is a sophisticated calendar and alarm program. +" You can download remind from: +" https://www.roaringpenguin.com/products/remind +" +" Changelog +" version 0.7: updated email and link +" version 0.6: added THROUGH keyword (courtesy of Ben Orchard) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" shut case off. +syn case ignore + +syn keyword remindCommands REM OMIT SET FSET UNSET +syn keyword remindExpiry UNTIL FROM SCANFROM SCAN WARN SCHED THROUGH +syn keyword remindTag PRIORITY TAG +syn keyword remindTimed AT DURATION +syn keyword remindMove ONCE SKIP BEFORE AFTER +syn keyword remindSpecial INCLUDE INC BANNER PUSH-OMIT-CONTEXT PUSH CLEAR-OMIT-CONTEXT CLEAR POP-OMIT-CONTEXT POP COLOR +syn keyword remindRun MSG MSF RUN CAL SATISFY SPECIAL PS PSFILE SHADE MOON +syn keyword remindConditional IF ELSE ENDIF IFTRIG +syn keyword remindDebug DEBUG DUMPVARS DUMP ERRMSG FLUSH PRESERVE +syn match remindComment "#.*$" +syn region remindString start=+'+ end=+'+ skip=+\\\\\|\\'+ oneline +syn region remindString start=+"+ end=+"+ skip=+\\\\\|\\"+ oneline +syn match remindVar "\$[_a-zA-Z][_a-zA-Z0-9]*" +syn match remindSubst "%[^ ]" +syn match remindAdvanceNumber "\(\*\|+\|-\|++\|--\)[0-9]\+" +" XXX: use different separators for dates and times? +syn match remindDateSeparators "[/:@\.-]" contained +syn match remindTimes "[0-9]\{1,2}[:\.][0-9]\{1,2}" contains=remindDateSeparators +" XXX: why not match only valid dates? Ok, checking for 'Feb the 30' would +" be impossible, but at least check for valid months and times. +syn match remindDates "'[0-9]\{4}[/-][0-9]\{1,2}[/-][0-9]\{1,2}\(@[0-9]\{1,2}[:\.][0-9]\{1,2}\)\?'" contains=remindDateSeparators +" This will match trailing whitespaces that seem to break rem2ps. +" Courtesy of Michael Dunn. +syn match remindWarning display excludenl "\S\s\+$"ms=s+1 + + + +hi def link remindCommands Function +hi def link remindExpiry Repeat +hi def link remindTag Label +hi def link remindTimed Statement +hi def link remindMove Statement +hi def link remindSpecial Include +hi def link remindRun Function +hi def link remindConditional Conditional +hi def link remindComment Comment +hi def link remindTimes String +hi def link remindString String +hi def link remindDebug Debug +hi def link remindVar Identifier +hi def link remindSubst Constant +hi def link remindAdvanceNumber Number +hi def link remindDateSeparators Comment +hi def link remindDates String +hi def link remindWarning Error + + +let b:current_syntax = "remind" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/resolv.vim b/syntax/resolv.vim new file mode 100644 index 0000000..26730e1 --- /dev/null +++ b/syntax/resolv.vim @@ -0,0 +1,82 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: resolver configuration file +" Maintainer: Radu Dineiu +" URL: https://raw.github.com/rid9/vim-resolv/master/resolv.vim +" Last Change: 2013 May 21 +" Version: 1.0 +" +" Credits: +" David Necas (Yeti) +" Stefano Zacchiroli + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Errors, comments and operators +syn match resolvError /./ +syn match resolvComment /\s*[#;].*$/ +syn match resolvOperator /[\/:]/ contained + +" IP +syn cluster resolvIPCluster contains=resolvIPError,resolvIPSpecial +syn match resolvIPError /\%(\d\{4,}\|25[6-9]\|2[6-9]\d\|[3-9]\d\{2}\)[\.0-9]*/ contained +syn match resolvIPSpecial /\%(127\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}\)/ contained + +" General +syn match resolvIP contained /\%(\d\{1,4}\.\)\{3}\d\{1,4}/ contains=@resolvIPCluster +syn match resolvIPNetmask contained /\%(\d\{1,4}\.\)\{3}\d\{1,4}\%(\/\%(\%(\d\{1,4}\.\)\{,3}\d\{1,4}\)\)\?/ contains=resolvOperator,@resolvIPCluster +syn match resolvHostname contained /\w\{-}\.[-0-9A-Za-z_\.]*/ + +" Particular +syn match resolvIPNameserver contained /\%(\%(\d\{1,4}\.\)\{3}\d\{1,4}\%(\s\|$\)\)\+/ contains=@resolvIPCluster +syn match resolvHostnameSearch contained /\%(\%([-0-9A-Za-z_]\+\.\)*[-0-9A-Za-z_]\+\.\?\%(\s\|$\)\)\+/ +syn match resolvIPNetmaskSortList contained /\%(\%(\d\{1,4}\.\)\{3}\d\{1,4}\%(\/\%(\%(\d\{1,4}\.\)\{,3}\d\{1,4}\)\)\?\%(\s\|$\)\)\+/ contains=resolvOperator,@resolvIPCluster + +" Identifiers +syn match resolvNameserver /^\s*nameserver\>/ nextgroup=resolvIPNameserver skipwhite +syn match resolvLwserver /^\s*lwserver\>/ nextgroup=resolvIPNameserver skipwhite +syn match resolvDomain /^\s*domain\>/ nextgroup=resolvHostname skipwhite +syn match resolvSearch /^\s*search\>/ nextgroup=resolvHostnameSearch skipwhite +syn match resolvSortList /^\s*sortlist\>/ nextgroup=resolvIPNetmaskSortList skipwhite +syn match resolvOptions /^\s*options\>/ nextgroup=resolvOption skipwhite + +" Options +syn match resolvOption /\<\%(debug\|no_tld_query\|rotate\|no-check-names\|inet6\)\>/ contained nextgroup=resolvOption skipwhite +syn match resolvOption /\<\%(ndots\|timeout\|attempts\):\d\+\>/ contained contains=resolvOperator nextgroup=resolvOption skipwhite + +" Additional errors +syn match resolvError /^search .\{257,}/ + + +hi def link resolvIP Number +hi def link resolvIPNetmask Number +hi def link resolvHostname String +hi def link resolvOption String + +hi def link resolvIPNameserver Number +hi def link resolvHostnameSearch String +hi def link resolvIPNetmaskSortList Number + +hi def link resolvNameServer Identifier +hi def link resolvLwserver Identifier +hi def link resolvDomain Identifier +hi def link resolvSearch Identifier +hi def link resolvSortList Identifier +hi def link resolvOptions Identifier + +hi def link resolvComment Comment +hi def link resolvOperator Operator +hi def link resolvError Error +hi def link resolvIPError Error +hi def link resolvIPSpecial Special + + +let b:current_syntax = "resolv" + +" vim: ts=8 ft=vim + +endif diff --git a/syntax/reva.vim b/syntax/reva.vim new file mode 100644 index 0000000..6194f14 --- /dev/null +++ b/syntax/reva.vim @@ -0,0 +1,195 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Reva Forth +" Version: 2011.2 +" Last Change: 2012/02/13 +" Maintainer: Ron Aaron +" URL: http://ronware.org/reva/ +" Filetypes: *.rf *.frt +" NOTE: You should also have the ftplugin/reva.vim file to set 'isk' + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn clear + +" Synchronization method +syn sync ccomment +syn sync maxlines=100 + + +syn case ignore +" Some special, non-FORTH keywords +"syn keyword revaTodo contained todo fixme bugbug todo: bugbug: note: +syn match revaTodo contained '\(todo\|fixme\|bugbug\|note\)[:]*' +syn match revaTodo contained 'copyright\(\s(c)\)\=\(\s[0-9]\{2,4}\)\=' + +syn match revaHelpDesc '\S.*' contained +syn match revaHelpStuff '\<\(def\|stack\|ctx\|ver\|os\|related\):\s.*' +syn region revaHelpStuff start='\' end='^\S' contains=revaHelpDesc +syn region revaEOF start='\<|||\>' end='{$}' contains=revaHelpStuff + + +syn case match +" basic mathematical and logical operators +syn keyword revaoperators + - * / mod /mod negate abs min max umin umax +syn keyword revaoperators and or xor not invert 1+ 1- +syn keyword revaoperators m+ */ */mod m* um* m*/ um/mod fm/mod sm/rem +syn keyword revaoperators d+ d- dnegate dabs dmin dmax > < = >> << u< <> + + +" stack manipulations +syn keyword revastack drop nip dup over tuck swap rot -rot ?dup pick roll +syn keyword revastack 2drop 2nip 2dup 2over 2swap 2rot 3drop +syn keyword revastack >r r> r@ rdrop +" syn keyword revastack sp@ sp! rp@ rp! + +" address operations +syn keyword revamemory @ ! +! c@ c! 2@ 2! align aligned allot allocate here free resize +syn keyword revaadrarith chars char+ cells cell+ cell cell- 2cell+ 2cell- 3cell+ 4cell+ +syn keyword revamemblks move fill + +" conditionals +syn keyword revacond if else then =if >if if if0 ;; catch throw + +" iterations +syn keyword revaloop while repeat until again +syn keyword revaloop do loop i j leave unloop skip more + +" new words +syn match revaColonDef '\ immediate +syn keyword revadefine compile literal ' ['] + +" Built in words +com! -nargs=+ Builtin syn keyword revaBuiltin +Builtin execute ahead interp bye >body here pad words make +Builtin accept close cr creat delete ekey emit fsize ioerr key? +Builtin mtime open/r open/rw read rename seek space spaces stat +Builtin tell type type_ write (seek) (argv) (save) 0; 0drop; +Builtin >class >lz >name >xt alias alias: appname argc asciiz, asciizl, +Builtin body> clamp depth disassemble findprev fnvhash getenv here, +Builtin iterate last! last@ later link lz> lzmax os parse/ peek +Builtin peek-n pop prior push put rp@ rpick save setenv slurp +Builtin stack-empty? stack-iterate stack-size stack: THROW_BADFUNC +Builtin THROW_BADLIB THROW_GENERIC used xt>size z, +Builtin +lplace +place -chop /char /string bounds c+lplace c+place +Builtin chop cmp cmpi count lc lcount lplace place quote rsplit search split +Builtin zcount zt \\char +Builtin chdir g32 k32 u32 getcwd getpid hinst osname stdin stdout +Builtin (-lib) (bye) (call) (else) (find) (func) (here) (if (lib) (s0) (s^) +Builtin (to~) (while) >in >rel ?literal appstart cold compiling? context? d0 default_class +Builtin defer? dict dolstr dostr find-word h0 if) interp isa onexit +Builtin onstartup pdoes pop>ebx prompt rel> rp0 s0 src srcstr state str0 then,> then> tib +Builtin tp vector vector! word? xt? .ver revaver revaver# && '' 'constant 'context +Builtin 'create 'defer 'does 'forth 'inline 'macro 'macront 'notail 'value 'variable +Builtin (.r) (context) (create) (header) (hide) (inline) (p.r) (words~) (xfind) +Builtin ++ -- , -2drop -2nip -link -swap . .2x .classes .contexts .funcs .libs .needs .r +Builtin .rs .x 00; 0do 0if 1, 2, 3, 2* 2/ 2constant 2variable 3dup 4dup ;then >base >defer +Builtin >rr ? ?do @execute @rem appdir argv as back base base! between chain cleanup-libs +Builtin cmove> context?? ctrl-c ctx>name data: defer: defer@def dictgone do_cr eleave +Builtin endcase endof eval exception exec false find func: header heapgone help help/ +Builtin hex# hide inline{ last lastxt lib libdir literal, makeexename mnotail ms ms@ +Builtin newclass noop nosavedict notail nul of off on p: padchar parse parseln +Builtin parsews rangeof rdepth remains reset reva revaused rol8 rr> scratch setclass sp +Builtin strof super> temp time&date true turnkey? undo vfunc: w! w@ +Builtin xchg xchg2 xfind xt>name xwords { {{ }} } _+ _1+ _1- pathsep case \|| +" p[ [''] [ ['] + + +" debugging +syn keyword revadebug .s dump see + +" basic character operations +" syn keyword revaCharOps (.) CHAR EXPECT FIND WORD TYPE -TRAILING EMIT KEY +" syn keyword revaCharOps KEY? TIB CR +" syn match revaCharOps '\d >digit digit> >single >double >number >float + +" contexts +syn keyword revavocs forth macro inline +syn keyword revavocs context: +syn match revavocs /\<\~[^~ ]*/ +syn match revavocs /[^~ ]*\~\>/ + +" numbers +syn keyword revamath decimal hex base binary octal +syn match revainteger '\<-\=[0-9.]*[0-9.]\+\>' +" recognize hex and binary numbers, the '$' and '%' notation is for greva +syn match revainteger '\<\$\x*\x\+\>' " *1* --- dont't mess +syn match revainteger '\<\x*\d\x*\>' " *2* --- this order! +syn match revainteger '\<%[0-1]*[0-1]\+\>' +syn match revainteger "\<'.\>" + +" Strings +" syn region revaString start=+\.\?\"+ end=+"+ end=+$+ +syn region revaString start=/"/ skip=/\\"/ end=/"/ + +" Comments +syn region revaComment start='\\S\s' end='.*' contains=revaTodo +syn match revaComment '\.(\s[^)]\{-})' contains=revaTodo +syn region revaComment start='(\s' skip='\\)' end=')' contains=revaTodo +syn match revaComment '(\s[^\-]*\-\-[^\-]\{-})' contains=revaTodo +syn match revaComment '\<|\s.*$' contains=revaTodo +syn match revaColonDef '\<:m\?\s*[^ \t]\+\>' contains=revaComment + +" Include files +syn match revaInclude '\<\(include\|needs\)\s\+\S\+' + + +" Define the default highlighting. +if !exists("did_reva_syntax_inits") + let did_reva_syntax_inits=1 + " The default methods for highlighting. Can be overriden later. + hi def link revaEOF cIf0 + hi def link revaHelpStuff special + hi def link revaHelpDesc Comment + hi def link revaTodo Todo + hi def link revaOperators Operator + hi def link revaMath Number + hi def link revaInteger Number + hi def link revaStack Special + hi def link revaFStack Special + hi def link revaSP Special + hi def link revaMemory Operator + hi def link revaAdrArith Function + hi def link revaMemBlks Function + hi def link revaCond Conditional + hi def link revaLoop Repeat + hi def link revaColonDef Define + hi def link revaEndOfColonDef Define + hi def link revaDefine Define + hi def link revaDebug Debug + hi def link revaCharOps Character + hi def link revaConversion String + hi def link revaForth Statement + hi def link revaVocs Statement + hi def link revaString String + hi def link revaComment Comment + hi def link revaClassDef Define + hi def link revaEndOfClassDef Define + hi def link revaObjectDef Define + hi def link revaEndOfObjectDef Define + hi def link revaInclude Include + hi def link revaBuiltin Keyword +endif + +let b:current_syntax = "reva" +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8:sw=4:nocindent:smartindent: + +endif diff --git a/syntax/rexx.vim b/syntax/rexx.vim new file mode 100644 index 0000000..03feda3 --- /dev/null +++ b/syntax/rexx.vim @@ -0,0 +1,322 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Rexx +" Maintainer: Thomas Geulig +" Last Change: 2012 Sep 14, added support for new ooRexx 4.0 features +" URL: http://www.geulig.de/vim/rexx.vim +" Special Thanks to Dan Sharp and Rony G. Flatscher +" for comments and additions + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" add to valid identifier chars +setlocal iskeyword+=. +setlocal iskeyword+=! +setlocal iskeyword+=? + +" ---rgf, position important: must be before comments etc. ! +syn match rexxOperator "[=|\/\\\+\*\[\],;:<>&\~%\-]" + +" rgf syn match rexxIdentifier "\<[a-zA-Z\!\?_]\([a-zA-Z0-9._?!]\)*\>" +syn match rexxIdentifier "\<\K\k*\>" +syn match rexxEnvironmentSymbol "\<\.\k\+\>" + +" A Keyword is the first symbol in a clause. A clause begins at the start +" of a line or after a semicolon. THEN, ELSE, OTHERWISE, and colons are always +" followed by an implied semicolon. +syn match rexxClause "\(^\|;\|:\|then \|else \|when \|otherwise \)\s*\S*" contains=ALLBUT,rexxParse2,rexxRaise2,rexxForward2 + +" Considered keywords when used together in a phrase and begin a clause +syn match rexxParse "\\|version\)\>" containedin=rexxClause contains=rexxParse2 +syn match rexxParse2 "\" containedin=rexxParse + +syn match rexxKeyword contained "\" +syn match rexxKeyword contained "\<\(address\|trace\)\( value\)\?\>" +syn match rexxKeyword contained "\" + +syn match rexxKeyword contained "\<\(do\|loop\)\>\(\s\+label\s\+\k*\)\?\(\s\+forever\)\?\>" +syn match rexxKeyword contained "\\s*\(strict\s*\)\?\" + +" Another keyword phrase, separated to aid highlighting in rexxFunction +syn match rexxRegularCallSignal contained "\<\(call\|signal\)\s\(\s*on\>\|\s*off\>\)\@!\(\k\+\ze\|\ze(\)\(\s*\|;\|$\|(\)" +syn region rexxLabel contained start="\<\(call\|signal\)\>\s*\zs\(\k*\|(\)" end="\ze\(\s*\|;\|$\|(\)" containedin=rexxRegularCallSignal + +syn match rexxExceptionHandling contained "\<\(call\|signal\)\>\s\+\<\(on\|off\)\>.*\(;\|$\)" contains=rexxComment + +" hilite label given after keyword "name" +syn match rexxLabel "name\s\+\zs\k\+\ze" containedin=rexxExceptionHandling +" hilite condition name (serves as label) +syn match rexxLabel "\<\(call\|signal\)\>\s\+\<\(on\|off\)\>\s*\zs\k\+\ze\s*\(;\|$\)" containedin=rexxExceptionHandling +" user exception handling, hilite user defined name +syn region rexxLabel contained start="user\s\+\zs\k" end="\ze\(\s\|;\|$\)" containedin=rexxExceptionHandling + +" Considered keywords when they begin a clause +syn match rexxKeywordStatements "\<\(arg\|catch\|do\|drop\|end\|exit\|expose\|finally\|forward\|if\|interpret\|iterate\|leave\|loop\|nop\)\>" +syn match rexxKeywordStatements "\<\(options\|pull\|push\|queue\|raise\|reply\|return\|say\|select\|trace\)\>" + +" Conditional keywords starting a new statement +syn match rexxConditional "\<\(then\|else\|when\|otherwise\)\(\s*\|;\|\_$\|\)\>" contains=rexxKeywordStatements + +" Conditional phrases +syn match rexxLoopKeywords "\<\(to\|by\|for\|until\|while\|over\)\>" containedin=doLoopSelectLabelRegion + +" must be after Conditional phrases! +syn match doLoopSelectLabelRegion "\<\(do\|loop\|select\)\>\s\+\(label\s\+\)\?\(\s\+\k\+\s\+\zs\\)\?\k*\(\s\+forever\)\?\(\s\|;\|$\)" contains=doLoopSelectLabelRegion,rexxStartValueAssignment,rexxLoopKeywords + +" color label's name +syn match rexxLabel2 "\<\(do\|loop\|select\)\>\s\+label\s\+\zs\k*\ze" containedin=doLoopSelectLabelRegion + +" make sure control variable is normal +" TODO: re-activate ? +"rgf syn match rexxControlVariable "\<\(do\|loop\)\>\(\s\+label\s\+\k*\)\?\s\+\zs.*\ze\s\+\" containedin=doLoopSelectLabelRegion + +" make sure control variable assignment is normal +syn match rexxStartValueAssignment "\<\(do\|loop\)\>\(\s\+label\s\+\k*\)\?\s\+\zs.*\ze\(=.*\)\?\s\+\" containedin=doLoopSelectLabelRegion + +" highlight label name +syn match endIterateLeaveLabelRegion "\<\(end\|leave\|iterate\)\>\(\s\+\K\k*\)" contains=rexxLabel2 +syn match rexxLabel2 "\<\(end\|leave\|iterate\)\>\s\+\zs\k*\ze" containedin=endIterateLeaveLabelRegion + +" Guard statement +syn match rexxGuard "\(^\|;\|:\)\s*\\s\+\<\(on\|off\)\>" + +" Trace statement +syn match rexxTrace "\(^\|;\|:\)\s*\\s\+\<\K\k*\>" + +" Raise statement +" syn match rexxRaise "\(^\|;\|:\)\s\+\\s*\<\(propagate\|error\|failure\|syntax\|user\)\>\?" contains=rexxRaise2 +syn match rexxRaise "\(^\|;\|:\)\s*\\s*\<\(propagate\|error\|failure\|syntax\|user\)\>\?" contains=rexxRaise2 +syn match rexxRaise2 "\<\(additional\|array\|description\|exit\|propagate\|return\)\>" containedin=rexxRaise + +" Forward statement +syn match rexxForward "\(^\|;\|:\)\\s*" contains=rexxForward2 +syn match rexxForward2 "\<\(arguments\|array\|continue\|message\|class\|to\)\>" contained + +" Functions/Procedures +syn match rexxFunction "\<\<[a-zA-Z\!\?_]\k*\>("me=e-1 +syn match rexxFunction "[()]" + +" String constants +syn region rexxString start=+"+ skip=+""+ end=+"\(x\|b\)\?+ oneline +syn region rexxString start=+'+ skip=+''+ end=+'\(x\|b\)\?+ oneline + +syn region rexxParen transparent start='(' end=')' contains=ALLBUT,rexxParenError,rexxTodo,rexxLabel,rexxKeyword +" Catch errors caused by wrong parenthesis +syn match rexxParenError ")" +syn match rexxInParen "[\\[\\]{}]" + +" Comments +syn region rexxComment start="/\*" end="\*/" contains=rexxTodo,rexxComment +syn match rexxCommentError "\*/" +syn region rexxLineComment start="--" end="\_$" oneline + +" Highlight User Labels +" check for labels between comments, labels stated in a statement in the middle of a line +syn match rexxLabel "\(\_^\|;\)\s*\(\/\*.*\*\/\)*\s*\k\+\s*\(\/\*.*\*\/\)*\s*:"me=e-1 contains=rexxTodo,rexxComment + +syn keyword rexxTodo contained TODO FIXME XXX + +" ooRexx messages +syn region rexxMessageOperator start="\(\~\|\~\~\)" end="\(\S\|\s\)"me=e-1 +syn match rexxMessage "\(\~\|\~\~\)\s*\<\.*[a-zA-Z]\([a-zA-Z0-9._?!]\)*\>" contains=rexxMessageOperator + +" line continuations, take care of (line-)comments after it +syn match rexxLineContinue ",\ze\s*\(--.*\|\/\*.*\)*$" + +" the following is necessary, otherwise three consecutive dashes will cause it to highlight the first one +syn match rexxLineContinue "-\ze-\@!\s*\(--.*\|\s*\/\*.*\)\?$" + +" Special Variables +syn keyword rexxSpecialVariable sigl rc result self super +syn keyword rexxSpecialVariable .environment .error .input .local .methods .output .rs .stderr .stdin .stdout .stdque + +" Constants +syn keyword rexxConst .true .false .nil .endOfLine .line .context + +" Rexx numbers +" int like number +syn match rexxNumber '\d\+' contained +syn match rexxNumber '[-+]\s*\d\+' contained + +" Floating point number with decimal +syn match rexxNumber '\d\+\.\d*' contained +syn match rexxNumber '[-+]\s*\d\+\.\d*' contained + +" Floating point like number with E +syn match rexxNumber '[-+]\s*\d*[eE][\-+]\d\+' contained +syn match rexxNumber '\d*[eE][\-+]\d\+' contained + +" Floating point like number with E and decimal point (+,-) +syn match rexxNumber '[-+]\s*\d*\.\d*[eE][\-+]\d\+' contained +syn match rexxNumber '\d*\.\d*[eE][\-+]\d\+' contained + + +" ooRexx builtin classes (as of version 3.2.0, fall 2007), first define dot to be o.k. in keywords +syn keyword rexxBuiltinClass .Alarm .ArgUtil .Array .Bag .CaselessColumnComparator +syn keyword rexxBuiltinClass .CaselessComparator .CaselessDescendingComparator .CircularQueue +syn keyword rexxBuiltinClass .Class .Collection .ColumnComparator .Comparable .Comparator +syn keyword rexxBuiltinClass .DateTime .DescendingComparator .Directory .File .InputOutputStream +syn keyword rexxBuiltinClass .InputStream .InvertingComparator .List .MapCollection +syn keyword rexxBuiltinClass .Message .Method .Monitor .MutableBuffer .Object +syn keyword rexxBuiltinClass .OrderedCollection .OutputStream .Package .Properties .Queue +syn keyword rexxBuiltinClass .RegularExpression .Relation .RexxContext .RexxQueue .Routine +syn keyword rexxBuiltinClass .Set .SetCollection .Stem .Stream +syn keyword rexxBuiltinClass .StreamSupplier .String .Supplier .Table .TimeSpan + +" Windows-only classes +syn keyword rexxBuiltinClass .AdvancedControls .AnimatedButton .BaseDialog .ButtonControl +syn keyword rexxBuiltinClass .CategoryDialog .CheckBox .CheckList .ComboBox .DialogControl +syn keyword rexxBuiltinClass .DialogExtensions .DlgArea .DlgAreaU .DynamicDialog +syn keyword rexxBuiltinClass .EditControl .InputBox .IntegerBox .ListBox .ListChoice +syn keyword rexxBuiltinClass .ListControl .MenuObject .MessageExtensions .MultiInputBox +syn keyword rexxBuiltinClass .MultiListChoice .OLEObject .OLEVariant +syn keyword rexxBuiltinClass .PasswordBox .PlainBaseDialog .PlainUserDialog +syn keyword rexxBuiltinClass .ProgressBar .ProgressIndicator .PropertySheet .RadioButton +syn keyword rexxBuiltinClass .RcDialog .ResDialog .ScrollBar .SingleSelection .SliderControl +syn keyword rexxBuiltinClass .StateIndicator .StaticControl .TabControl .TimedMessage +syn keyword rexxBuiltinClass .TreeControl .UserDialog .VirtualKeyCodes .WindowBase +syn keyword rexxBuiltinClass .WindowExtensions .WindowObject .WindowsClassesBase .WindowsClipboard +syn keyword rexxBuiltinClass .WindowsEventLog .WindowsManager .WindowsProgramManager .WindowsRegistry + +" BSF4ooRexx classes +syn keyword rexxBuiltinClass .BSF .bsf.dialog .bsf_proxy +syn keyword rexxBuiltinClass .UNO .UNO_ENUM .UNO_CONSTANTS .UNO_PROPERTIES + +" ooRexx directives, ---rgf location important, otherwise directives in top of file not matched! +syn region rexxClassDirective start="::\s*class\s*"ms=e+1 end="\ze\(\s\|;\|$\)" +syn region rexxMethodDirective start="::\s*method\s*"ms=e+1 end="\ze\(\s\|;\|$\)" +syn region rexxRequiresDirective start="::\s*requires\s*"ms=e+1 end="\ze\(\s\|;\|$\)" +syn region rexxRoutineDirective start="::\s*routine\s*"ms=e+1 end="\ze\(\s\|;\|$\)" +syn region rexxAttributeDirective start="::\s*attribute\s*"ms=e+1 end="\ze\(\s\|;\|$\)" +" rgf, 2012-09-09 +syn region rexxOptionsDirective start="::\s*options\s*"ms=e+1 end="\ze\(\s\|;\|$\)" +syn region rexxConstantDirective start="::\s*constant\s*"ms=e+1 end="\ze\(\s\|;\|$\)" + +syn region rexxDirective start="\(^\|;\)\s*::\s*\w\+" end="\($\|;\)" contains=rexxString,rexxNumber,rexxComment,rexxLineComment,rexxClassDirective,rexxMethodDirective,rexxRoutineDirective,rexxRequiresDirective,rexxAttributeDirective,rexxOptionsDirective,rexxConstantDirective keepend + +syn match rexxOptionsDirective2 "\<\(digits\|form\|fuzz\|trace\)\>" containedin = rexxOptionsDirective3 +syn region rexxOptionsDirective3 start="\(^\|;\)\s*::\s*options\s"ms=e+1 end="\($\|;\)" contains=rexxString,rexxNumber,rexxVariable,rexxComment,rexxLineComment containedin = rexxDirective + + +syn region rexxVariable start="\zs\<\(\.\)\@!\K\k\+\>\ze\s*\(=\|,\|)\|%\|\]\|\\\||\|&\|+=\|-=\|<\|>\)" end="\(\_$\|.\)"me=e-1 +syn match rexxVariable "\(=\|,\|)\|%\|\]\|\\\||\|&\|+=\|-=\|<\|>\)\s*\zs\K\k*\ze" + +" rgf, 2007-07-22: unfortunately, the entire region is colored (not only the +" patterns), hence useless (vim 7.0)! (syntax-docs hint that that should work) +" attempt: just colorize the parenthesis in matching colors, keep content +" transparent to keep the formatting already done to it! +" TODO: test on 7.3 +" syn region par1 matchgroup=par1 start="(" matchgroup=par1 end=")" transparent contains=par2 +" syn region par2 matchgroup=par2 start="(" matchgroup=par2 end=")" transparent contains=par3 contained +" syn region par3 matchgroup=par3 start="(" matchgroup=par3 end=")" transparent contains=par4 contained +" syn region par4 matchgroup=par4 start="(" matchgroup=par4 end=")" transparent contains=par5 contained +" syn region par5 matchgroup=par5 start="(" matchgroup=par5 end=")" transparent contains=par1 contained + +" this will colorize the entire region, removing any colorizing already done! +" syn region par1 matchgroup=par1 start="(" end=")" contains=par2 +" syn region par2 matchgroup=par2 start="(" end=")" contains=par3 contained +" syn region par3 matchgroup=par3 start="(" end=")" contains=par4 contained +" syn region par4 matchgroup=par4 start="(" end=")" contains=par5 contained +" syn region par5 matchgroup=par5 start="(" end=")" contains=par1 contained + +hi par1 ctermfg=red guifg=red "guibg=grey +hi par2 ctermfg=blue guifg=blue "guibg=grey +hi par3 ctermfg=darkgreen guifg=darkgreen "guibg=grey +hi par4 ctermfg=darkyellow guifg=darkyellow "guibg=grey +hi par5 ctermfg=darkgrey guifg=darkgrey "guibg=grey + +" line continuation (trailing comma or single dash) +syn sync linecont "\(,\|-\ze-\@!\)\ze\s*\(--.*\|\/\*.*\)*$" + +" if !exists("rexx_minlines") +" let rexx_minlines = 500 +" endif +" exec "syn sync ccomment rexxComment minlines=" . rexx_minlines + +" always scan from start, PCs have long become to be powerful enough for that +exec "syn sync fromstart" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" make binary and hex strings stand out +hi rexxStringConstant term=bold,underline ctermfg=5 cterm=bold guifg=darkMagenta gui=bold + +hi def link rexxLabel2 Function +hi def link doLoopSelectLabelRegion rexxKeyword +hi def link endIterateLeaveLabelRegion rexxKeyword +hi def link rexxLoopKeywords rexxKeyword " Todo + +hi def link rexxNumber Normal "DiffChange +" hi def link rexxIdentifier DiffChange + +hi def link rexxRegularCallSignal Statement +hi def link rexxExceptionHandling Statement + +hi def link rexxLabel Function +hi def link rexxCharacter Character +hi def link rexxParenError rexxError +hi def link rexxInParen rexxError +hi def link rexxCommentError rexxError +hi def link rexxError Error +hi def link rexxKeyword Statement +hi def link rexxKeywordStatements Statement + +hi def link rexxFunction Function +hi def link rexxString String +hi def link rexxComment Comment +hi def link rexxTodo Todo +hi def link rexxSpecialVariable Special +hi def link rexxConditional rexxKeyword + +hi def link rexxOperator Operator +hi def link rexxMessageOperator rexxOperator +hi def link rexxLineComment Comment + +hi def link rexxLineContinue WildMenu + +hi def link rexxDirective rexxKeyword +hi def link rexxClassDirective Type +hi def link rexxMethodDirective rexxFunction +hi def link rexxAttributeDirective rexxFunction +hi def link rexxRequiresDirective Include +hi def link rexxRoutineDirective rexxFunction + +" rgf, 2012-09-09 +hi def link rexxOptionsDirective rexxFunction +hi def link rexxOptionsDirective2 rexxOptionsDirective +hi def link rexxOptionsDirective3 Normal " rexxOptionsDirective + +hi def link rexxConstantDirective rexxFunction + +hi def link rexxConst Constant +hi def link rexxTypeSpecifier Type +hi def link rexxBuiltinClass rexxTypeSpecifier + +hi def link rexxEnvironmentSymbol rexxConst +hi def link rexxMessage rexxFunction + +hi def link rexxParse rexxKeyword +hi def link rexxParse2 rexxParse + +hi def link rexxGuard rexxKeyword +hi def link rexxTrace rexxKeyword + +hi def link rexxRaise rexxKeyword +hi def link rexxRaise2 rexxRaise + +hi def link rexxForward rexxKeyword +hi def link rexxForward2 rexxForward + + +let b:current_syntax = "rexx" + +"vim: ts=8 + +endif diff --git a/syntax/rhelp.vim b/syntax/rhelp.vim index ea4fca0..f4aae90 100644 --- a/syntax/rhelp.vim +++ b/syntax/rhelp.vim @@ -1,3 +1,281 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: R Help File +" Maintainer: Jakson Aquino +" Former Maintainer: Johannes Ranke +" Homepage: https://github.com/jalvesaq/R-Vim-runtime +" Last Change: Tue Jun 28, 2016 08:53AM +" Remarks: - Includes R syntax highlighting in the appropriate +" sections if an r.vim file is in the same directory or in the +" default debian location. +" - There is no Latex markup in equations +" - Thanks to Will Gray for finding and fixing a bug +" - No support for \var tag within quoted string + +" Version Clears: {{{1 +if exists("b:current_syntax") + finish +endif + +scriptencoding utf-8 + +syn case match + +" R help identifiers {{{1 +syn region rhelpIdentifier matchgroup=rhelpSection start="\\name{" end="}" +syn region rhelpIdentifier matchgroup=rhelpSection start="\\alias{" end="}" +syn region rhelpIdentifier matchgroup=rhelpSection start="\\pkg{" end="}" contains=rhelpLink +syn region rhelpIdentifier matchgroup=rhelpSection start="\\CRANpkg{" end="}" contains=rhelpLink +syn region rhelpIdentifier matchgroup=rhelpSection start="\\method{" end="}" contained +syn region rhelpIdentifier matchgroup=rhelpSection start="\\Rdversion{" end="}" + + +" Highlighting of R code using an existing r.vim syntax file if available {{{1 +syn include @R syntax/r.vim + +" Strings {{{1 +syn region rhelpString start=/"/ skip=/\\"/ end=/"/ contains=rhelpSpecialChar,rhelpCodeSpecial,rhelpLink contained + +" Special characters in R strings +syn match rhelpCodeSpecial display contained "\\\\\(n\|r\|t\|b\|a\|f\|v\|'\|\"\)\|\\\\" + +" Special characters ( \$ \& \% \# \{ \} \_) +syn match rhelpSpecialChar "\\[$&%#{}_]" + + +" R code {{{1 +syn match rhelpDots "\\dots" containedin=@R +syn region rhelpRcode matchgroup=Delimiter start="\\examples{" matchgroup=Delimiter transparent end="}" contains=@R,rhelpLink,rhelpIdentifier,rhelpString,rhelpSpecialChar,rhelpSection +syn region rhelpRcode matchgroup=Delimiter start="\\usage{" matchgroup=Delimiter transparent end="}" contains=@R,rhelpIdentifier,rhelpS4method +syn region rhelpRcode matchgroup=Delimiter start="\\synopsis{" matchgroup=Delimiter transparent end="}" contains=@R +syn region rhelpRcode matchgroup=Delimiter start="\\special{" matchgroup=Delimiter transparent end="}" contains=@R + +if v:version > 703 + syn region rhelpRcode matchgroup=Delimiter start="\\code{" skip='\\\@1" +syn match rhelpKeyword "\\ldots\>" +syn match rhelpKeyword "\\sspace\>" +syn match rhelpKeyword "--" +syn match rhelpKeyword "---" + +" Condition Keywords {{{2 +syn match rhelpKeyword "\\if\>" +syn match rhelpKeyword "\\ifelse\>" +syn match rhelpKeyword "\\out\>" +" Examples of usage: +" \ifelse{latex}{\eqn{p = 5 + 6 - 7 \times 8}}{\eqn{p = 5 + 6 - 7 * 8}} +" \ifelse{latex}{\out{$\alpha$}}{\ifelse{html}{\out{α}}{alpha}} + +" Keywords and operators valid only if in math mode {{{2 +syn match rhelpMathOp "<" contained +syn match rhelpMathOp ">" contained +syn match rhelpMathOp "+" contained +syn match rhelpMathOp "-" contained +syn match rhelpMathOp "=" contained + +" Conceal function based on syntax/tex.vim {{{2 +if exists("g:tex_conceal") + let s:tex_conceal = g:tex_conceal +else + let s:tex_conceal = 'gm' +endif +function s:HideSymbol(pat, cchar, hide) + if a:hide + exe "syn match rhelpMathSymb '" . a:pat . "' contained conceal cchar=" . a:cchar + else + exe "syn match rhelpMathSymb '" . a:pat . "' contained" + endif +endfunction + +" Math symbols {{{2 +if s:tex_conceal =~ 'm' + let s:hd = 1 +else + let s:hd = 0 +endif +call s:HideSymbol('\\infty\>', '∞', s:hd) +call s:HideSymbol('\\ge\>', '≥', s:hd) +call s:HideSymbol('\\le\>', '≤', s:hd) +call s:HideSymbol('\\prod\>', 'âˆ', s:hd) +call s:HideSymbol('\\sum\>', '∑', s:hd) +syn match rhelpMathSymb "\\sqrt\>" contained + +" Greek letters {{{2 +if s:tex_conceal =~ 'g' + let s:hd = 1 +else + let s:hd = 0 +endif +call s:HideSymbol('\\alpha\>', 'α', s:hd) +call s:HideSymbol('\\beta\>', 'β', s:hd) +call s:HideSymbol('\\gamma\>', 'γ', s:hd) +call s:HideSymbol('\\delta\>', 'δ', s:hd) +call s:HideSymbol('\\epsilon\>', 'ϵ', s:hd) +call s:HideSymbol('\\zeta\>', 'ζ', s:hd) +call s:HideSymbol('\\eta\>', 'η', s:hd) +call s:HideSymbol('\\theta\>', 'θ', s:hd) +call s:HideSymbol('\\iota\>', 'ι', s:hd) +call s:HideSymbol('\\kappa\>', 'κ', s:hd) +call s:HideSymbol('\\lambda\>', 'λ', s:hd) +call s:HideSymbol('\\mu\>', 'μ', s:hd) +call s:HideSymbol('\\nu\>', 'ν', s:hd) +call s:HideSymbol('\\xi\>', 'ξ', s:hd) +call s:HideSymbol('\\pi\>', 'Ï€', s:hd) +call s:HideSymbol('\\rho\>', 'Ï', s:hd) +call s:HideSymbol('\\sigma\>', 'σ', s:hd) +call s:HideSymbol('\\tau\>', 'Ï„', s:hd) +call s:HideSymbol('\\upsilon\>', 'Ï…', s:hd) +call s:HideSymbol('\\phi\>', 'Ï•', s:hd) +call s:HideSymbol('\\chi\>', 'χ', s:hd) +call s:HideSymbol('\\psi\>', 'ψ', s:hd) +call s:HideSymbol('\\omega\>', 'ω', s:hd) +call s:HideSymbol('\\Gamma\>', 'Γ', s:hd) +call s:HideSymbol('\\Delta\>', 'Δ', s:hd) +call s:HideSymbol('\\Theta\>', 'Θ', s:hd) +call s:HideSymbol('\\Lambda\>', 'Λ', s:hd) +call s:HideSymbol('\\Xi\>', 'Ξ', s:hd) +call s:HideSymbol('\\Pi\>', 'Π', s:hd) +call s:HideSymbol('\\Sigma\>', 'Σ', s:hd) +call s:HideSymbol('\\Upsilon\>', 'Î¥', s:hd) +call s:HideSymbol('\\Phi\>', 'Φ', s:hd) +call s:HideSymbol('\\Psi\>', 'Ψ', s:hd) +call s:HideSymbol('\\Omega\>', 'Ω', s:hd) +delfunction s:HideSymbol +" Note: The letters 'omicron', 'Alpha', 'Beta', 'Epsilon', 'Zeta', 'Eta', +" 'Iota', 'Kappa', 'Mu', 'Nu', 'Omicron', 'Rho', 'Tau' and 'Chi' are listed +" at src/library/tools/R/Rd2txt.R because they are valid in HTML, although +" they do not make valid LaTeX code (e.g. Α versus \Alpha). + +" Links {{{1 +syn region rhelpLink matchgroup=rhelpType start="\\link{" end="}" contained keepend extend +syn region rhelpLink matchgroup=rhelpType start="\\link\[.\{-}\]{" end="}" contained keepend extend +syn region rhelpLink matchgroup=rhelpType start="\\linkS4class{" end="}" contained keepend extend +syn region rhelpLink matchgroup=rhelpType start="\\url{" end="}" contained keepend extend +syn region rhelpLink matchgroup=rhelpType start="\\href{" end="}" contained keepend extend +syn region rhelpLink matchgroup=rhelpType start="\\figure{" end="}" contained keepend extend + +" Verbatim like {{{1 +syn region rhelpVerbatim matchgroup=rhelpType start="\\samp{" skip='\\\@1" +syn match rhelpType "\\strong\>" +syn match rhelpType "\\bold\>" +syn match rhelpType "\\sQuote\>" +syn match rhelpType "\\dQuote\>" +syn match rhelpType "\\preformatted\>" +syn match rhelpType "\\kbd\>" +syn match rhelpType "\\file\>" +syn match rhelpType "\\email\>" +syn match rhelpType "\\enc\>" +syn match rhelpType "\\var\>" +syn match rhelpType "\\env\>" +syn match rhelpType "\\option\>" +syn match rhelpType "\\command\>" +syn match rhelpType "\\newcommand\>" +syn match rhelpType "\\renewcommand\>" +syn match rhelpType "\\dfn\>" +syn match rhelpType "\\cite\>" +syn match rhelpType "\\acronym\>" +syn match rhelpType "\\doi\>" + +" rhelp sections {{{1 +syn match rhelpSection "\\encoding\>" +syn match rhelpSection "\\title\>" +syn match rhelpSection "\\item\>" +syn match rhelpSection "\\description\>" +syn match rhelpSection "\\concept\>" +syn match rhelpSection "\\arguments\>" +syn match rhelpSection "\\details\>" +syn match rhelpSection "\\value\>" +syn match rhelpSection "\\references\>" +syn match rhelpSection "\\note\>" +syn match rhelpSection "\\author\>" +syn match rhelpSection "\\seealso\>" +syn match rhelpSection "\\keyword\>" +syn match rhelpSection "\\docType\>" +syn match rhelpSection "\\format\>" +syn match rhelpSection "\\source\>" +syn match rhelpSection "\\itemize\>" +syn match rhelpSection "\\describe\>" +syn match rhelpSection "\\enumerate\>" +syn match rhelpSection "\\item " +syn match rhelpSection "\\item$" +syn match rhelpSection "\\tabular{[lcr]*}" +syn match rhelpSection "\\dontrun\>" +syn match rhelpSection "\\dontshow\>" +syn match rhelpSection "\\testonly\>" +syn match rhelpSection "\\donttest\>" + +" Freely named Sections {{{1 +syn region rhelpFreesec matchgroup=Delimiter start="\\section{" matchgroup=Delimiter transparent end="}" +syn region rhelpFreesubsec matchgroup=Delimiter start="\\subsection{" matchgroup=Delimiter transparent end="}" + +syn match rhelpDelimiter "{\|\[\|(\|)\|\]\|}" + +" R help file comments {{{1 +syn match rhelpComment /%.*$/ + +" Error {{{1 +syn region rhelpRegion matchgroup=Delimiter start=/(/ matchgroup=Delimiter end=/)/ contains=@Spell,rhelpCodeSpecial,rhelpComment,rhelpDelimiter,rhelpDots,rhelpFreesec,rhelpFreesubsec,rhelpIdentifier,rhelpKeyword,rhelpLink,rhelpPreProc,rhelpRComment,rhelpRcode,rhelpRegion,rhelpS4method,rhelpSection,rhelpSexpr,rhelpSpecialChar,rhelpString,rhelpType,rhelpVerbatim,rhelpEquation +syn region rhelpRegion matchgroup=Delimiter start=/{/ matchgroup=Delimiter end=/}/ contains=@Spell,rhelpCodeSpecial,rhelpComment,rhelpDelimiter,rhelpDots,rhelpFreesec,rhelpFreesubsec,rhelpIdentifier,rhelpKeyword,rhelpLink,rhelpPreProc,rhelpRComment,rhelpRcode,rhelpRegion,rhelpS4method,rhelpSection,rhelpSexpr,rhelpSpecialChar,rhelpString,rhelpType,rhelpVerbatim,rhelpEquation +syn region rhelpRegion matchgroup=Delimiter start=/\[/ matchgroup=Delimiter end=/]/ contains=@Spell,rhelpCodeSpecial,rhelpComment,rhelpDelimiter,rhelpDots,rhelpFreesec,rhelpFreesubsec,rhelpIdentifier,rhelpKeyword,rhelpLink,rhelpPreProc,rhelpRComment,rhelpRcode,rhelpRegion,rhelpS4method,rhelpSection,rhelpSexpr,rhelpSpecialChar,rhelpString,rhelpType,rhelpVerbatim,rhelpEquation +syn match rhelpError /[)\]}]/ +syn match rhelpBraceError /[)}]/ contained +syn match rhelpCurlyError /[)\]]/ contained +syn match rhelpParenError /[\]}]/ contained + +syntax sync match rhelpSyncRcode grouphere rhelpRcode "\\examples{" + +" Define the default highlighting {{{1 +hi def link rhelpVerbatim String +hi def link rhelpDelimiter Delimiter +hi def link rhelpIdentifier Identifier +hi def link rhelpString String +hi def link rhelpCodeSpecial Special +hi def link rhelpKeyword Keyword +hi def link rhelpDots Keyword +hi def link rhelpLink Underlined +hi def link rhelpType Type +hi def link rhelpSection PreCondit +hi def link rhelpError Error +hi def link rhelpBraceError Error +hi def link rhelpCurlyError Error +hi def link rhelpParenError Error +hi def link rhelpPreProc PreProc +hi def link rhelpDelimiter Delimiter +hi def link rhelpComment Comment +hi def link rhelpRComment Comment +hi def link rhelpSpecialChar SpecialChar +hi def link rhelpMathSymb Special +hi def link rhelpMathOp Operator + +let b:current_syntax = "rhelp" + +" vim: foldmethod=marker sw=2 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'r-lang') == -1 " Vim syntax file diff --git a/syntax/rib.vim b/syntax/rib.vim new file mode 100644 index 0000000..0b8c0b3 --- /dev/null +++ b/syntax/rib.vim @@ -0,0 +1,66 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Renderman Interface Bytestream +" Maintainer: Andrew Bromage +" Last Change: 2003 May 11 +" + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +" Comments +syn match ribLineComment "#.*$" +syn match ribStructureComment "##.*$" + +syn case ignore +syn match ribCommand /[A-Z][a-zA-Z]*/ +syn case match + +syn region ribString start=/"/ skip=/\\"/ end=/"/ + +syn match ribStructure "[A-Z][a-zA-Z]*Begin\>\|[A-Z][a-zA-Z]*End" +syn region ribSectionFold start="FrameBegin" end="FrameEnd" fold transparent keepend extend +syn region ribSectionFold start="WorldBegin" end="WorldEnd" fold transparent keepend extend +syn region ribSectionFold start="TransformBegin" end="TransformEnd" fold transparent keepend extend +syn region ribSectionFold start="AttributeBegin" end="AttributeEnd" fold transparent keepend extend +syn region ribSectionFold start="MotionBegin" end="MotionEnd" fold transparent keepend extend +syn region ribSectionFold start="SolidBegin" end="SolidEnd" fold transparent keepend extend +syn region ribSectionFold start="ObjectBegin" end="ObjectEnd" fold transparent keepend extend + +syn sync fromstart + +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match ribNumbers display transparent "[-]\=\<\d\|\.\d" contains=ribNumber,ribFloat +syn match ribNumber display contained "[-]\=\d\+\>" +"floating point number, with dot, optional exponent +syn match ribFloat display contained "[-]\=\d\+\.\d*\(e[-+]\=\d\+\)\=" +"floating point number, starting with a dot, optional exponent +syn match ribFloat display contained "[-]\=\.\d\+\(e[-+]\=\d\+\)\=\>" +"floating point number, without dot, with exponent +syn match ribFloat display contained "[-]\=\d\+e[-+]\d\+\>" +syn case match + + +hi def link ribStructure Structure +hi def link ribCommand Statement + +hi def link ribStructureComment SpecialComment +hi def link ribLineComment Comment + +hi def link ribString String +hi def link ribNumber Number +hi def link ribFloat Float + + + +let b:current_syntax = "rib" + +" Options for vi: ts=8 sw=2 sts=2 nowrap noexpandtab ft=vim + +endif diff --git a/syntax/rmd.vim b/syntax/rmd.vim new file mode 100644 index 0000000..6077e31 --- /dev/null +++ b/syntax/rmd.vim @@ -0,0 +1,127 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" markdown Text with R statements +" Language: markdown with R code chunks +" Homepage: https://github.com/jalvesaq/R-Vim-runtime +" Last Change: Sat Jan 28, 2017 10:06PM +" +" CONFIGURATION: +" To highlight chunk headers as R code, put in your vimrc (e.g. .config/nvim/init.vim): +" let rmd_syn_hl_chunk = 1 +" +" For highlighting pandoc extensions to markdown like citations and TeX and +" many other advanced features like folding of markdown sections, it is +" recommended to install the vim-pandoc filetype plugin as well as the +" vim-pandoc-syntax filetype plugin from https://github.com/vim-pandoc. +" +" TODO: +" - Provide highlighting for rmarkdown parameters in yaml header + +if exists("b:current_syntax") + finish +endif + +" load all of pandoc info, e.g. from +" https://github.com/vim-pandoc/vim-pandoc-syntax +runtime syntax/pandoc.vim +if exists("b:current_syntax") + let rmdIsPandoc = 1 + unlet b:current_syntax +else + let rmdIsPandoc = 0 + runtime syntax/markdown.vim + if exists("b:current_syntax") + unlet b:current_syntax + endif + + " load all of the yaml syntax highlighting rules into @yaml + syntax include @yaml syntax/yaml.vim + if exists("b:current_syntax") + unlet b:current_syntax + endif + + " highlight yaml block commonly used for front matter + syntax region rmdYamlBlock matchgroup=rmdYamlBlockDelim start="^---" matchgroup=rmdYamlBlockDelim end="^---" contains=@yaml keepend fold +endif + +if !exists("g:rmd_syn_langs") + let g:rmd_syn_langs = ["r"] +else + let s:hasr = 0 + for s:lng in g:rmd_syn_langs + if s:lng == "r" + let s:hasr = 1 + endif + endfor + if s:hasr == 0 + let g:rmd_syn_langs += ["r"] + endif +endif + +for s:lng in g:rmd_syn_langs + exe 'syntax include @' . toupper(s:lng) . ' syntax/'. s:lng . '.vim' + if exists("b:current_syntax") + unlet b:current_syntax + endif + exe 'syntax region rmd' . toupper(s:lng) . 'Chunk start="^[ \t]*``` *{\(' . s:lng . '\|r.*engine\s*=\s*["' . "']" . s:lng . "['" . '"]\).*}$" end="^[ \t]*```$" contains=@' . toupper(s:lng) . ',rmd' . toupper(s:lng) . 'ChunkDelim keepend fold' + + if exists("g:rmd_syn_hl_chunk") && s:lng == "r" + " highlight R code inside chunk header + syntax match rmdRChunkDelim "^[ \t]*```{r" contained + syntax match rmdRChunkDelim "}$" contained + else + exe 'syntax match rmd' . toupper(s:lng) . 'ChunkDelim "^[ \t]*```{\(' . s:lng . '\|r.*engine\s*=\s*["' . "']" . s:lng . "['" . '"]\).*}$" contained' + endif + exe 'syntax match rmd' . toupper(s:lng) . 'ChunkDelim "^[ \t]*```$" contained' +endfor + + +" also match and syntax highlight in-line R code +syntax region rmdrInline matchgroup=rmdInlineDelim start="`r " end="`" contains=@R containedin=pandocLaTeXRegion,yamlFlowString keepend +" I was not able to highlight rmdrInline inside a pandocLaTeXCommand, although +" highlighting works within pandocLaTeXRegion and yamlFlowString. +syntax cluster texMathZoneGroup add=rmdrInline + +" match slidify special marker +syntax match rmdSlidifySpecial "\*\*\*" + + +if rmdIsPandoc == 0 + syn match rmdBlockQuote /^\s*>.*\n\(.*\n\@" contains=@texMathZoneGroup + " Region + syntax match rmdLaTeXRegDelim "\$\$" contained + syntax match rmdLaTeXRegDelim "\$\$latex$" contained + syntax match rmdLaTeXSt "\\[a-zA-Z]\+" + syntax region rmdLaTeXRegion start="^\$\$" skip="\\\$" end="\$\$$" contains=@LaTeX,rmdLaTeXRegDelim keepend + syntax region rmdLaTeXRegion2 start="^\\\[" end="\\\]" contains=@LaTeX,rmdLaTeXRegDelim keepend + hi def link rmdBlockQuote Comment + hi def link rmdLaTeXSt Statement + hi def link rmdLaTeXInlDelim Special + hi def link rmdLaTeXRegDelim Special +endif + +for s:lng in g:rmd_syn_langs + exe 'syn sync match rmd' . toupper(s:lng) . 'SyncChunk grouphere rmd' . toupper(s:lng) . 'Chunk /^[ \t]*``` *{\(' . s:lng . '\|r.*engine\s*=\s*["' . "']" . s:lng . "['" . '"]\)/' +endfor + +hi def link rmdYamlBlockDelim Delim +for s:lng in g:rmd_syn_langs + exe 'hi def link rmd' . toupper(s:lng) . 'ChunkDelim Special' +endfor +hi def link rmdInlineDelim Special +hi def link rmdSlidifySpecial Special + +let b:current_syntax = "rmd" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/rnc.vim b/syntax/rnc.vim new file mode 100644 index 0000000..81586c7 --- /dev/null +++ b/syntax/rnc.vim @@ -0,0 +1,72 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Relax NG compact syntax +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2007-06-17 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +setlocal iskeyword+=-,. + +syn keyword rncTodo contained TODO FIXME XXX NOTE + +syn region rncComment display oneline start='^\s*#' end='$' + \ contains=rncTodo,@Spell + +syn match rncOperator display '[-|,&+?*~]' +syn match rncOperator display '\%(|&\)\==' +syn match rncOperator display '>>' + +syn match rncNamespace display '\<\k\+:' + +syn match rncQuoted display '\\\k\+\>' + +syn match rncSpecial display '\\x{\x\+}' + +syn region rncAnnotation transparent start='\[' end='\]' + \ contains=ALLBUT,rncComment,rncTodo + +syn region rncLiteral display oneline start=+"+ end=+"+ + \ contains=rncSpecial +syn region rncLiteral display oneline start=+'+ end=+'+ +syn region rncLiteral display oneline start=+"""+ end=+"""+ + \ contains=rncSpecial +syn region rncLiteral display oneline start=+'''+ end=+'''+ + +syn match rncDelimiter display '[{},()]' + +syn keyword rncKeyword datatypes default div empty external grammar +syn keyword rncKeyword include inherit list mixed name namespace +syn keyword rncKeyword notAllowed parent start string text token + +syn match rncIdentifier display '\k\+\_s*\%(=\|&=\||=\)\@=' + \ nextgroup=rncOperator +syn keyword rncKeyword element attribute + \ nextgroup=rncIdName skipwhite skipempty +syn match rncIdName contained '\k\+' + +hi def link rncTodo Todo +hi def link rncComment Comment +hi def link rncOperator Operator +hi def link rncNamespace Identifier +hi def link rncQuoted Special +hi def link rncSpecial SpecialChar +hi def link rncAnnotation Special +hi def link rncLiteral String +hi def link rncDelimiter Delimiter +hi def link rncKeyword Keyword +hi def link rncIdentifier Identifier +hi def link rncIdName Identifier + +let b:current_syntax = "rnc" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/rng.vim b/syntax/rng.vim new file mode 100644 index 0000000..a148fbe --- /dev/null +++ b/syntax/rng.vim @@ -0,0 +1,29 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: RELAX NG +" Maintainer: Jaromir Hradilek +" URL: https://github.com/jhradilek/vim-rng +" Last Change: 25 March 2013 +" Description: A syntax file for RELAX NG, a schema language for XML + +if exists('b:current_syntax') + finish +endif + +do Syntax xml +syn spell toplevel +syn cluster xmlTagHook add=rngTagName +syn case match + +syn keyword rngTagName anyName attribute choice data define div contained +syn keyword rngTagName element empty except externalRef grammar contained +syn keyword rngTagName group include interleave list mixed name contained +syn keyword rngTagName notAllowed nsName oneOrMore optional param contained +syn keyword rngTagName parentRef ref start text value zeroOrMore contained + +hi def link rngTagName Statement + +let b:current_syntax = 'rng' + +endif diff --git a/syntax/rnoweb.vim b/syntax/rnoweb.vim index 437c31c..b519236 100644 --- a/syntax/rnoweb.vim +++ b/syntax/rnoweb.vim @@ -1,3 +1,59 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: R noweb Files +" Maintainer: Johannes Ranke +" Last Change: Sat Feb 06, 2016 06:47AM +" Version: 0.9.1 +" Remarks: - This file is inspired by the proposal of +" Fernando Henrique Ferraz Pereira da Rosa +" http://www.ime.usp.br/~feferraz/en/sweavevim.html +" + +if exists("b:current_syntax") + finish +endif + +syn case match + +" Extension of Tex clusters {{{1 +runtime syntax/tex.vim +unlet b:current_syntax + +syn cluster texMatchGroup add=@rnoweb +syn cluster texMathMatchGroup add=rnowebSexpr +syn cluster texMathZoneGroup add=rnowebSexpr +syn cluster texEnvGroup add=@rnoweb +syn cluster texFoldGroup add=@rnoweb +syn cluster texDocGroup add=@rnoweb +syn cluster texPartGroup add=@rnoweb +syn cluster texChapterGroup add=@rnoweb +syn cluster texSectionGroup add=@rnoweb +syn cluster texSubSectionGroup add=@rnoweb +syn cluster texSubSubSectionGroup add=@rnoweb +syn cluster texParaGroup add=@rnoweb + +" Highlighting of R code using an existing r.vim syntax file if available {{{1 +syn include @rnowebR syntax/r.vim +syn region rnowebChunk matchgroup=rnowebDelimiter start="^<<.*>>=" matchgroup=rnowebDelimiter end="^@" contains=@rnowebR,rnowebChunkReference,rnowebChunk fold keepend +syn match rnowebChunkReference "^<<.*>>$" contained +syn region rnowebSexpr matchgroup=Delimiter start="\\Sexpr{" matchgroup=Delimiter end="}" contains=@rnowebR contained + +" Sweave options command {{{1 +syn region rnowebSweaveopts matchgroup=Delimiter start="\\SweaveOpts{" matchgroup=Delimiter end="}" + +" rnoweb Cluster {{{1 +syn cluster rnoweb contains=rnowebChunk,rnowebChunkReference,rnowebDelimiter,rnowebSexpr,rnowebSweaveopts + +" Highlighting {{{1 +hi def link rnowebDelimiter Delimiter +hi def link rnowebSweaveOpts Statement +hi def link rnowebChunkReference Delimiter + +let b:current_syntax = "rnoweb" +" vim: foldmethod=marker: + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'r-lang') == -1 " Vim syntax file diff --git a/syntax/robots.vim b/syntax/robots.vim new file mode 100644 index 0000000..4e890ff --- /dev/null +++ b/syntax/robots.vim @@ -0,0 +1,61 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: "Robots.txt" files +" Robots.txt files indicate to WWW robots which parts of a web site should not be accessed. +" Maintainer: Dominique Stéphan (dominique@mggen.com) +" URL: http://www.mggen.com/vim/syntax/robots.zip +" Last change: 2001 May 09 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +" shut case off +syn case ignore + +" Comment +syn match robotsComment "#.*$" contains=robotsUrl,robotsMail,robotsString + +" Star * (means all spiders) +syn match robotsStar "\*" + +" : +syn match robotsDelimiter ":" + + +" The keywords +" User-agent +syn match robotsAgent "^[Uu][Ss][Ee][Rr]\-[Aa][Gg][Ee][Nn][Tt]" +" Disallow +syn match robotsDisallow "^[Dd][Ii][Ss][Aa][Ll][Ll][Oo][Ww]" + +" Disallow: or User-Agent: and the rest of the line before an eventual comment +synt match robotsLine "\(^[Uu][Ss][Ee][Rr]\-[Aa][Gg][Ee][Nn][Tt]\|^[Dd][Ii][Ss][Aa][Ll][Ll][Oo][Ww]\):[^#]*" contains=robotsAgent,robotsDisallow,robotsStar,robotsDelimiter + +" Some frequent things in comments +syn match robotsUrl "http[s]\=://\S*" +syn match robotsMail "\S*@\S*" +syn region robotsString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ + + +hi def link robotsComment Comment +hi def link robotsAgent Type +hi def link robotsDisallow Statement +hi def link robotsLine Special +hi def link robotsStar Operator +hi def link robotsDelimiter Delimiter +hi def link robotsUrl String +hi def link robotsMail String +hi def link robotsString String + + + +let b:current_syntax = "robots" + +" vim: ts=8 sw=2 + + +endif diff --git a/syntax/rpcgen.vim b/syntax/rpcgen.vim new file mode 100644 index 0000000..15789d5 --- /dev/null +++ b/syntax/rpcgen.vim @@ -0,0 +1,50 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: rpcgen +" Maintainer: Charles E. Campbell +" Last Change: Aug 31, 2016 +" Version: 12 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_RPCGEN + +if exists("b:current_syntax") + finish +endif + +" Read the C syntax to start with +runtime! syntax/c.vim + +syn keyword rpcProgram program skipnl skipwhite nextgroup=rpcProgName +syn match rpcProgName contained "\<\i\I*\>" skipnl skipwhite nextgroup=rpcProgZone +syn region rpcProgZone contained matchgroup=Delimiter start="{" matchgroup=Delimiter end="}\s*=\s*\(\d\+\|0x[23]\x\{7}\)\s*;"me=e-1 contains=rpcVersion,cComment,rpcProgNmbrErr +syn keyword rpcVersion contained version skipnl skipwhite nextgroup=rpcVersName +syn match rpcVersName contained "\<\i\I*\>" skipnl skipwhite nextgroup=rpcVersZone +syn region rpcVersZone contained matchgroup=Delimiter start="{" matchgroup=Delimiter end="}\s*=\s*\d\+\s*;"me=e-1 contains=cType,cStructure,cStorageClass,rpcDecl,rpcProcNmbr,cComment +syn keyword rpcDecl contained string +syn match rpcProcNmbr contained "=\s*\d\+;"me=e-1 +syn match rpcProgNmbrErr contained "=\s*0x[^23]\x*"ms=s+1 +syn match rpcPassThru "^\s*%.*$" + +" Define the default highlighting. +if !exists("skip_rpcgen_syntax_inits") + + hi def link rpcProgName rpcName + hi def link rpcProgram rpcStatement + hi def link rpcVersName rpcName + hi def link rpcVersion rpcStatement + + hi def link rpcDecl cType + hi def link rpcPassThru cComment + + hi def link rpcName Special + hi def link rpcProcNmbr Delimiter + hi def link rpcProgNmbrErr Error + hi def link rpcStatement Statement + +endif + +let b:current_syntax = "rpcgen" + +" vim: ts=8 + +endif diff --git a/syntax/rpl.vim b/syntax/rpl.vim new file mode 100644 index 0000000..3087223 --- /dev/null +++ b/syntax/rpl.vim @@ -0,0 +1,487 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: RPL/2 +" Version: 0.15.15 against RPL/2 version 4.00pre7i +" Last Change: 2012 Feb 03 by Thilo Six +" Maintainer: Joël BERTRAND +" URL: http://www.makalis.fr/~bertrand/rpl2/download/vim/indent/rpl.vim +" Credits: Nothing + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Keyword characters (not used) +" set iskeyword=33-127 + +" Case sensitive +syntax case match + +" Constants +syntax match rplConstant "\(^\|\s\+\)\(e\|i\)\ze\($\|\s\+\)" + +" Any binary number +syntax match rplBinaryError "\(^\|\s\+\)#\s*\S\+b\ze" +syntax match rplBinary "\(^\|\s\+\)#\s*[01]\+b\ze\($\|\s\+\)" +syntax match rplOctalError "\(^\|\s\+\)#\s*\S\+o\ze" +syntax match rplOctal "\(^\|\s\+\)#\s*\o\+o\ze\($\|\s\+\)" +syntax match rplDecimalError "\(^\|\s\+\)#\s*\S\+d\ze" +syntax match rplDecimal "\(^\|\s\+\)#\s*\d\+d\ze\($\|\s\+\)" +syntax match rplHexadecimalError "\(^\|\s\+\)#\s*\S\+h\ze" +syntax match rplHexadecimal "\(^\|\s\+\)#\s*\x\+h\ze\($\|\s\+\)" + +" Case unsensitive +syntax case ignore + +syntax match rplControl "\(^\|\s\+\)abort\ze\($\|\s\+\)" +syntax match rplControl "\(^\|\s\+\)kill\ze\($\|\s\+\)" +syntax match rplControl "\(^\|\s\+\)cont\ze\($\|\s\+\)" +syntax match rplControl "\(^\|\s\+\)halt\ze\($\|\s\+\)" +syntax match rplControl "\(^\|\s\+\)cmlf\ze\($\|\s\+\)" +syntax match rplControl "\(^\|\s\+\)sst\ze\($\|\s\+\)" + +syntax match rplConstant "\(^\|\s\+\)pi\ze\($\|\s\+\)" + +syntax match rplStatement "\(^\|\s\+\)return\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)last\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)syzeval\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)wait\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)type\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)kind\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)eval\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)use\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)remove\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)external\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)dup\([2n]\|\)\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)drop\([2n]\|\)\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)depth\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)roll\(d\|\)\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)pick\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)rot\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)swap\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)over\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)clear\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)warranty\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)copyright\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)convert\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)date\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)time\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)mem\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)clmf\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)->num\ze\($\|\s\+\)" +syntax match rplStatement "\(^\|\s\+\)help\ze\($\|\s\+\)" + +syntax match rplStorage "\(^\|\s\+\)get\(i\|r\|c\|\)\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)put\(i\|r\|c\|\)\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)rcl\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)purge\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)sinv\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)sneg\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)sconj\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)steq\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)rceq\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)vars\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)clusr\ze\($\|\s\+\)" +syntax match rplStorage "\(^\|\s\+\)sto\([+-/\*]\|\)\ze\($\|\s\+\)" + +syntax match rplAlgConditional "\(^\|\s\+\)ift\(e\|\)\ze\($\|\s\+\)" + +syntax match rplOperator "\(^\|\s\+\)and\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)\(x\|\)or\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)not\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)same\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)==\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)<=\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)=<\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)=>\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)>=\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)<>\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)>\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)<\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)[+-]\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)[/\*]\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)\^\ze\($\|\s\+\)" +syntax match rplOperator "\(^\|\s\+\)\*\*\ze\($\|\s\+\)" + +syntax match rplBoolean "\(^\|\s\+\)true\ze\($\|\s\+\)" +syntax match rplBoolean "\(^\|\s\+\)false\ze\($\|\s\+\)" + +syntax match rplReadWrite "\(^\|\s\+\)store\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)recall\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\(\|wf\|un\)lock\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)open\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)close\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)delete\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)create\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)format\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)rewind\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)backspace\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\(\|re\)write\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)read\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)inquire\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)sync\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)append\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)suppress\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)seek\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)pr\(1\|int\|st\|stc\|lcd\|var\|usr\|md\)\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)paper\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)cr\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)erase\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)disp\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)input\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)prompt\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)key\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)cllcd\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\(\|re\)draw\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)drax\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)indep\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)depnd\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)res\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)axes\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)label\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)pmin\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)pmax\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)centr\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)persist\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)title\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\(slice\|auto\|log\|\)scale\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)eyept\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\(p\|s\)par\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)function\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)polar\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)scatter\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)plotter\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)wireframe\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)parametric\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)slice\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\*w\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\*h\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\*d\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)\*s\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)->lcd\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)lcd->\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)edit\ze\($\|\s\+\)" +syntax match rplReadWrite "\(^\|\s\+\)visit\ze\($\|\s\+\)" + +syntax match rplIntrinsic "\(^\|\s\+\)abs\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)arg\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)conj\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)re\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)im\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)mant\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)xpon\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)ceil\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)fact\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)fp\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)floor\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)inv\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)ip\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)max\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)min\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)mod\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)neg\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)relax\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)sign\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)sq\(\|rt\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)xroot\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)cos\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)sin\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)tan\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)tg\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)a\(\|rc\)cos\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)a\(\|rc\)sin\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)atan\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)arctg\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|a\)cosh\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|a\)sinh\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|a\)tanh\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|arg\)th\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)arg[cst]h\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|a\)log\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)ln\(\|1\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)exp\(\|m\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)trn\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)con\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)idn\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)rdm\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)rsd\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)cnrm\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)cross\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)d[eo]t\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)[cr]swp\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)rci\(j\|\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(in\|de\)cr\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)bessel\ze\($\|\s\+\)" + +syntax match rplIntrinsic "\(^\|\s\+\)\(\|g\)egvl\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|g\)\(\|l\|r\)egv\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)rnrm\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(std\|fix\|sci\|eng\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(rad\|deg\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|n\)rand\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)rdz\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|i\)fft\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(dec\|bin\|oct\|hex\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)rclf\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)stof\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)[cs]f\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)chr\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)num\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)pos\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)sub\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)size\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(st\|rc\)ws\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(r\|s\)\(r\|l\)\(\|b\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)as\(r\|l\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(int\|der\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)stos\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|r\)cls\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)drws\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)scls\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)ns\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)tot\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)mean\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|p\)sdev\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|p\)var\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)maxs\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)mins\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|p\)cov\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)cols\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)s\(x\(\|y\|2\)\|y\(\|2\)\)\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(x\|y\)col\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)corr\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)utp[cfnt]\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)comb\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)perm\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)\(\|p\)lu\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)[lu]chol\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)schur\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)%\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)%ch\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)%t\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)hms->\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)->hms\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)hms+\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)hms-\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)d->r\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)r->d\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)b->r\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)r->b\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)c->r\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)r->c\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)r->p\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)p->r\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)str->\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)->str\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)array->\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)->array\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)list->\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)->list\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)s+\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)s-\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)col-\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)col+\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)row-\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)row+\ze\($\|\s\+\)" +syntax match rplIntrinsic "\(^\|\s\+\)->q\ze\($\|\s\+\)" + +syntax match rplObsolete "\(^\|\s\+\)arry->\ze\($\|\s\+\)"hs=e-5 +syntax match rplObsolete "\(^\|\s\+\)->arry\ze\($\|\s\+\)"hs=e-5 + +" Conditional structures +syntax match rplConditionalError "\(^\|\s\+\)case\ze\($\|\s\+\)"hs=e-3 +syntax match rplConditionalError "\(^\|\s\+\)then\ze\($\|\s\+\)"hs=e-3 +syntax match rplConditionalError "\(^\|\s\+\)else\ze\($\|\s\+\)"hs=e-3 +syntax match rplConditionalError "\(^\|\s\+\)elseif\ze\($\|\s\+\)"hs=e-5 +syntax match rplConditionalError "\(^\|\s\+\)end\ze\($\|\s\+\)"hs=e-2 +syntax match rplConditionalError "\(^\|\s\+\)\(step\|next\)\ze\($\|\s\+\)"hs=e-3 +syntax match rplConditionalError "\(^\|\s\+\)until\ze\($\|\s\+\)"hs=e-4 +syntax match rplConditionalError "\(^\|\s\+\)repeat\ze\($\|\s\+\)"hs=e-5 +syntax match rplConditionalError "\(^\|\s\+\)default\ze\($\|\s\+\)"hs=e-6 + +" FOR/(CYCLE)/(EXIT)/NEXT +" FOR/(CYCLE)/(EXIT)/STEP +" START/(CYCLE)/(EXIT)/NEXT +" START/(CYCLE)/(EXIT)/STEP +syntax match rplCycle "\(^\|\s\+\)\(cycle\|exit\)\ze\($\|\s\+\)" +syntax region rplForNext matchgroup=rplRepeat start="\(^\|\s\+\)\(for\|start\)\ze\($\|\s\+\)" end="\(^\|\s\+\)\(next\|step\)\ze\($\|\s\+\)" contains=ALL keepend extend + +" ELSEIF/END +syntax region rplElseifEnd matchgroup=rplConditional start="\(^\|\s\+\)elseif\ze\($\|\s\+\)" end="\(^\|\s\+\)end\ze\($\|\s\+\)" contained contains=ALLBUT,rplElseEnd keepend + +" ELSE/END +syntax region rplElseEnd matchgroup=rplConditional start="\(^\|\s\+\)else\ze\($\|\s\+\)" end="\(^\|\s\+\)end\ze\($\|\s\+\)" contained contains=ALLBUT,rplElseEnd,rplThenEnd,rplElseifEnd keepend + +" THEN/END +syntax region rplThenEnd matchgroup=rplConditional start="\(^\|\s\+\)then\ze\($\|\s\+\)" end="\(^\|\s\+\)end\ze\($\|\s\+\)" contained containedin=rplIfEnd contains=ALLBUT,rplThenEnd keepend + +" IF/END +syntax region rplIfEnd matchgroup=rplConditional start="\(^\|\s\+\)if\(err\|\)\ze\($\|\s\+\)" end="\(^\|\s\+\)end\ze\($\|\s\+\)" contains=ALLBUT,rplElseEnd,rplElseifEnd keepend extend +" if end is accepted ! +" select end too ! + +" CASE/THEN +syntax region rplCaseThen matchgroup=rplConditional start="\(^\|\s\+\)case\ze\($\|\s\+\)" end="\(^\|\s\+\)then\ze\($\|\s\+\)" contains=ALLBUT,rplCaseThen,rplCaseEnd,rplThenEnd keepend extend contained containedin=rplCaseEnd + +" CASE/END +syntax region rplCaseEnd matchgroup=rplConditional start="\(^\|\s\+\)case\ze\($\|\s\+\)" end="\(^\|\s\+\)end\ze\($\|\s\+\)" contains=ALLBUT,rplCaseEnd,rplThenEnd,rplElseEnd keepend extend contained containedin=rplSelectEnd + +" DEFAULT/END +syntax region rplDefaultEnd matchgroup=rplConditional start="\(^\|\s\+\)default\ze\($\|\s\+\)" end="\(^\|\s\+\)end\ze\($\|\s\+\)" contains=ALLBUT,rplDefaultEnd keepend contained containedin=rplSelectEnd + +" SELECT/END +syntax region rplSelectEnd matchgroup=rplConditional start="\(^\|\s\+\)select\ze\($\|\s\+\)" end="\(^\|\s\+\)end\ze\($\|\s\+\)" contains=ALLBUT,rplThenEnd keepend extend +" select end is accepted ! + +" DO/UNTIL/END +syntax region rplUntilEnd matchgroup=rplConditional start="\(^\|\s\+\)until\ze\($\|\s\+\)" end="\(^\|\s\+\)\zsend\ze\($\|\s\+\)" contains=ALLBUT,rplUntilEnd contained containedin=rplDoUntil extend keepend +syntax region rplDoUntil matchgroup=rplConditional start="\(^\|\s\+\)do\ze\($\|\s\+\)" end="\(^\|\s\+\)until\ze\($\|\s\+\)" contains=ALL keepend extend + +" WHILE/REPEAT/END +syntax region rplRepeatEnd matchgroup=rplConditional start="\(^\|\s\+\)repeat\ze\($\|\s\+\)" end="\(^\|\s\+\)\zsend\ze\($\|\s\+\)" contains=ALLBUT,rplRepeatEnd contained containedin=rplWhileRepeat extend keepend +syntax region rplWhileRepeat matchgroup=rplConditional start="\(^\|\s\+\)while\ze\($\|\s\+\)" end="\(^\|\s\+\)repeat\ze\($\|\s\+\)" contains=ALL keepend extend + +" Comments +syntax match rplCommentError "\*/" +syntax region rplCommentString contained start=+"+ end=+"+ end=+\*/+me=s-1 +syntax region rplCommentLine start="\(^\|\s\+\)//\ze" skip="\\$" end="$" contains=NONE keepend extend +syntax region rplComment start="\(^\|\s\+\)/\*\ze" end="\*/" contains=rplCommentString keepend extend + +" Catch errors caused by too many right parentheses +syntax region rplParen transparent start="(" end=")" contains=ALLBUT,rplParenError,rplComplex,rplIncluded keepend extend +syntax match rplParenError ")" + +" Subroutines +" Catch errors caused by too many right '>>' +syntax match rplSubError "\(^\|\s\+\)>>\ze\($\|\s\+\)"hs=e-1 +syntax region rplSub matchgroup=rplSubDelimitor start="\(^\|\s\+\)<<\ze\($\|\s\+\)" end="\(^\|\s\+\)>>\ze\($\|\s\+\)" contains=ALLBUT,rplSubError,rplIncluded,rplDefaultEnd,rplStorageSub keepend extend + +" Expressions +syntax region rplExpr start="\(^\|\s\+\)'" end="'\ze\($\|\s\+\)" contains=rplParen,rplParenError + +" Local variables +syntax match rplStorageError "\(^\|\s\+\)->\ze\($\|\s\+\)"hs=e-1 +syntax region rplStorageSub matchgroup=rplStorage start="\(^\|\s\+\)<<\ze\($\|\s\+\)" end="\(^\|\s\+\)>>\ze\($\|\s\+\)" contains=ALLBUT,rplSubError,rplIncluded,rplDefaultEnd,rplStorageExpr contained containedin=rplLocalStorage keepend extend +syntax region rplStorageExpr matchgroup=rplStorage start="\(^\|\s\+\)'" end="'\ze\($\|\s\+\)" contains=rplParen,rplParenError extend contained containedin=rplLocalStorage +syntax region rplLocalStorage matchgroup=rplStorage start="\(^\|\s\+\)->\ze\($\|\s\+\)" end="\(^\|\s\+\)\(<<\ze\($\|\s\+\)\|'\)" contains=rplStorageSub,rplStorageExpr,rplComment,rplCommentLine keepend extend + +" Catch errors caused by too many right brackets +syntax match rplArrayError "\]" +syntax match rplArray "\]" contained containedin=rplArray +syntax region rplArray matchgroup=rplArray start="\[" end="\]" contains=ALLBUT,rplArrayError keepend extend + +" Catch errors caused by too many right '}' +syntax match rplListError "}" +syntax match rplList "}" contained containedin=rplList +syntax region rplList matchgroup=rplList start="{" end="}" contains=ALLBUT,rplListError,rplIncluded keepend extend + +" cpp is used by RPL/2 +syntax match rplPreProc "\_^#\s*\(define\|undef\)\>" +syntax match rplPreProc "\_^#\s*\(warning\|error\)\>" +syntax match rplPreCondit "\_^#\s*\(if\|ifdef\|ifndef\|elif\|else\|endif\)\>" +syntax match rplIncluded contained "\<<\s*\S*\s*>\>" +syntax match rplInclude "\_^#\s*include\>\s*["<]" contains=rplIncluded,rplString +"syntax match rplExecPath "\%^\_^#!\s*\S*" +syntax match rplExecPath "\%^\_^#!\p*\_$" + +" Any integer +syntax match rplInteger "\(^\|\s\+\)[-+]\=\d\+\ze\($\|\s\+\)" + +" Floating point number +" [S][ip].[fp] +syntax match rplFloat "\(^\|\s\+\)[-+]\=\(\d*\)\=[\.,]\(\d*\)\=\ze\($\|\s\+\)" contains=ALLBUT,rplPoint,rplSign +" [S]ip[.fp]E[S]exp +syntax match rplFloat "\(^\|\s\+\)[-+]\=\d\+\([\.,]\d*\)\=[eE]\([-+]\)\=\d\+\ze\($\|\s\+\)" contains=ALLBUT,rplPoint,rplSign +" [S].fpE[S]exp +syntax match rplFloat "\(^\|\s\+\)[-+]\=\(\d*\)\=[\.,]\d\+[eE]\([-+]\)\=\d\+\ze\($\|\s\+\)" contains=ALLBUT,rplPoint,rplSign +syntax match rplPoint "\<[\.,]\>" +syntax match rplSign "\<[+-]\>" + +" Complex number +" (x,y) +syntax match rplComplex "\(^\|\s\+\)([-+]\=\(\d*\)\=\.\=\d*\([eE][-+]\=\d\+\)\=\s*,\s*[-+]\=\(\d*\)\=\.\=\d*\([eE][-+]\=\d\+\)\=)\ze\($\|\s\+\)" +" (x.y) +syntax match rplComplex "\(^\|\s\+\)([-+]\=\(\d*\)\=,\=\d*\([eE][-+]\=\d\+\)\=\s*\.\s*[-+]\=\(\d*\)\=,\=\d*\([eE][-+]\=\d\+\)\=)\ze\($\|\s\+\)" + +" Strings +syntax match rplStringGuilles "\\\"" +syntax match rplStringAntislash "\\\\" +syntax region rplString start=+\(^\|\s\+\)"+ end=+"\ze\($\|\s\+\)+ contains=rplStringGuilles,rplStringAntislash + +syntax match rplTab "\t" transparent + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default highlighting. + +hi def link rplControl Statement +hi def link rplStatement Statement +hi def link rplAlgConditional Conditional +hi def link rplConditional Repeat +hi def link rplConditionalError Error +hi def link rplRepeat Repeat +hi def link rplCycle Repeat +hi def link rplUntil Repeat +hi def link rplIntrinsic Special +hi def link rplStorage StorageClass +hi def link rplStorageExpr StorageClass +hi def link rplStorageError Error +hi def link rplReadWrite rplIntrinsic + +hi def link rplOperator Operator + +hi def link rplList Special +hi def link rplArray Special +hi def link rplConstant Identifier +hi def link rplExpr Type + +hi def link rplString String +hi def link rplStringGuilles String +hi def link rplStringAntislash String + +hi def link rplBinary Boolean +hi def link rplOctal Boolean +hi def link rplDecimal Boolean +hi def link rplHexadecimal Boolean +hi def link rplInteger Number +hi def link rplFloat Float +hi def link rplComplex Float +hi def link rplBoolean Identifier + +hi def link rplObsolete Todo + +hi def link rplPreCondit PreCondit +hi def link rplInclude Include +hi def link rplIncluded rplString +hi def link rplInclude Include +hi def link rplExecPath Include +hi def link rplPreProc PreProc +hi def link rplComment Comment +hi def link rplCommentLine Comment +hi def link rplCommentString Comment +hi def link rplSubDelimitor rplStorage +hi def link rplCommentError Error +hi def link rplParenError Error +hi def link rplSubError Error +hi def link rplArrayError Error +hi def link rplListError Error +hi def link rplTab Error +hi def link rplBinaryError Error +hi def link rplOctalError Error +hi def link rplDecimalError Error +hi def link rplHexadecimalError Error + + +let b:current_syntax = "rpl" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 tw=132 + +endif diff --git a/syntax/rrst.vim b/syntax/rrst.vim new file mode 100644 index 0000000..7c66eb9 --- /dev/null +++ b/syntax/rrst.vim @@ -0,0 +1,47 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" reStructured Text with R statements +" Language: reST with R code chunks +" Maintainer: Alex Zvoleff, azvoleff@mail.sdsu.edu +" Homepage: https://github.com/jalvesaq/R-Vim-runtime +" Last Change: Tue Jun 28, 2016 08:53AM +" +" CONFIGURATION: +" To highlight chunk headers as R code, put in your vimrc: +" let rrst_syn_hl_chunk = 1 + +if exists("b:current_syntax") + finish +endif + +" load all of the rst info +runtime syntax/rst.vim +unlet b:current_syntax + +" load all of the r syntax highlighting rules into @R +syntax include @R syntax/r.vim + +" highlight R chunks +if exists("g:rrst_syn_hl_chunk") + " highlight R code inside chunk header + syntax match rrstChunkDelim "^\.\. {r" contained + syntax match rrstChunkDelim "}$" contained +else + syntax match rrstChunkDelim "^\.\. {r .*}$" contained +endif +syntax match rrstChunkDelim "^\.\. \.\.$" contained +syntax region rrstChunk start="^\.\. {r.*}$" end="^\.\. \.\.$" contains=@R,rrstChunkDelim keepend transparent fold + +" also highlight in-line R code +syntax match rrstInlineDelim "`" contained +syntax match rrstInlineDelim ":r:" contained +syntax region rrstInline start=":r: *`" skip=/\\\\\|\\`/ end="`" contains=@R,rrstInlineDelim keepend + +hi def link rrstChunkDelim Special +hi def link rrstInlineDelim Special + +let b:current_syntax = "rrst" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/rst.vim b/syntax/rst.vim new file mode 100644 index 0000000..8c67234 --- /dev/null +++ b/syntax/rst.vim @@ -0,0 +1,211 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: reStructuredText documentation format +" Maintainer: Marshall Ward +" Previous Maintainer: Nikolai Weibull +" Website: https://github.com/marshallward/vim-restructuredtext +" Latest Revision: 2016-08-18 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case ignore + +syn match rstTransition /^[=`:.'"~^_*+#-]\{4,}\s*$/ + +syn cluster rstCruft contains=rstEmphasis,rstStrongEmphasis, + \ rstInterpretedText,rstInlineLiteral,rstSubstitutionReference, + \ rstInlineInternalTargets,rstFootnoteReference,rstHyperlinkReference + +syn region rstLiteralBlock matchgroup=rstDelimiter + \ start='::\_s*\n\ze\z(\s\+\)' skip='^$' end='^\z1\@!' + \ contains=@NoSpell + +syn region rstQuotedLiteralBlock matchgroup=rstDelimiter + \ start="::\_s*\n\ze\z([!\"#$%&'()*+,-./:;<=>?@[\]^_`{|}~]\)" + \ end='^\z1\@!' contains=@NoSpell + +syn region rstDoctestBlock oneline display matchgroup=rstDelimiter + \ start='^>>>\s' end='^$' + +syn region rstTable transparent start='^\n\s*+[-=+]\+' end='^$' + \ contains=rstTableLines,@rstCruft +syn match rstTableLines contained display '|\|+\%(=\+\|-\+\)\=' + +syn region rstSimpleTable transparent + \ start='^\n\%(\s*\)\@>\%(\%(=\+\)\@>\%(\s\+\)\@>\)\%(\%(\%(=\+\)\@>\%(\s*\)\@>\)\+\)\@>$' + \ end='^$' + \ contains=rstSimpleTableLines,@rstCruft +syn match rstSimpleTableLines contained display + \ '^\%(\s*\)\@>\%(\%(=\+\)\@>\%(\s\+\)\@>\)\%(\%(\%(=\+\)\@>\%(\s*\)\@>\)\+\)\@>$' +syn match rstSimpleTableLines contained display + \ '^\%(\s*\)\@>\%(\%(-\+\)\@>\%(\s\+\)\@>\)\%(\%(\%(-\+\)\@>\%(\s*\)\@>\)\+\)\@>$' + +syn cluster rstDirectives contains=rstFootnote,rstCitation, + \ rstHyperlinkTarget,rstExDirective + +syn match rstExplicitMarkup '^\s*\.\.\_s' + \ nextgroup=@rstDirectives,rstComment,rstSubstitutionDefinition + +let s:ReferenceName = '[[:alnum:]]\+\%([_.-][[:alnum:]]\+\)*' + +syn keyword rstTodo contained FIXME TODO XXX NOTE + +execute 'syn region rstComment contained' . + \ ' start=/.*/' + \ ' end=/^\s\@!/ contains=rstTodo' + +execute 'syn region rstFootnote contained matchgroup=rstDirective' . + \ ' start=+\[\%(\d\+\|#\%(' . s:ReferenceName . '\)\=\|\*\)\]\_s+' . + \ ' skip=+^$+' . + \ ' end=+^\s\@!+ contains=@rstCruft,@NoSpell' + +execute 'syn region rstCitation contained matchgroup=rstDirective' . + \ ' start=+\[' . s:ReferenceName . '\]\_s+' . + \ ' skip=+^$+' . + \ ' end=+^\s\@!+ contains=@rstCruft,@NoSpell' + +syn region rstHyperlinkTarget contained matchgroup=rstDirective + \ start='_\%(_\|[^:\\]*\%(\\.[^:\\]*\)*\):\_s' skip=+^$+ end=+^\s\@!+ + +syn region rstHyperlinkTarget contained matchgroup=rstDirective + \ start='_`[^`\\]*\%(\\.[^`\\]*\)*`:\_s' skip=+^$+ end=+^\s\@!+ + +syn region rstHyperlinkTarget matchgroup=rstDirective + \ start=+^__\_s+ skip=+^$+ end=+^\s\@!+ + +execute 'syn region rstExDirective contained matchgroup=rstDirective' . + \ ' start=+' . s:ReferenceName . '::\_s+' . + \ ' skip=+^$+' . + \ ' end=+^\s\@!+ contains=@rstCruft,rstLiteralBlock' + +execute 'syn match rstSubstitutionDefinition contained' . + \ ' /|' . s:ReferenceName . '|\_s\+/ nextgroup=@rstDirectives' + +function! s:DefineOneInlineMarkup(name, start, middle, end, char_left, char_right) + execute 'syn region rst' . a:name . + \ ' start=+' . a:char_left . '\zs' . a:start . + \ '\ze[^[:space:]' . a:char_right . a:start[strlen(a:start) - 1] . ']+' . + \ a:middle . + \ ' end=+\S' . a:end . '\ze\%($\|\s\|[''"’)\]}>/:.,;!?\\-]\)+' +endfunction + +function! s:DefineInlineMarkup(name, start, middle, end) + let middle = a:middle != "" ? + \ (' skip=+\\\\\|\\' . a:middle . '+') : + \ "" + + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, "'", "'") + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, '"', '"') + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, '(', ')') + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, '\[', '\]') + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, '{', '}') + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, '<', '>') + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, '’', '’') + " TODO: Additional Unicode Pd, Po, Pi, Pf, Ps characters + + call s:DefineOneInlineMarkup(a:name, a:start, middle, a:end, '\%(^\|\s\|[/:]\)', '') + + execute 'syn match rst' . a:name . + \ ' +\%(^\|\s\|[''"([{/:.,;!?\\-]\)+' + + execute 'hi def link rst' . a:name . 'Delimiter' . ' rst' . a:name +endfunction + +call s:DefineInlineMarkup('Emphasis', '\*', '\*', '\*') +call s:DefineInlineMarkup('StrongEmphasis', '\*\*', '\*', '\*\*') +call s:DefineInlineMarkup('InterpretedTextOrHyperlinkReference', '`', '`', '`_\{0,2}') +call s:DefineInlineMarkup('InlineLiteral', '``', "", '``') +call s:DefineInlineMarkup('SubstitutionReference', '|', '|', '|_\{0,2}') +call s:DefineInlineMarkup('InlineInternalTargets', '_`', '`', '`') + +syn match rstSections "^\%(\([=`:.'"~^_*+#-]\)\1\+\n\)\=.\+\n\([=`:.'"~^_*+#-]\)\2\+$" + +" TODO: Can’t remember why these two can’t be defined like the ones above. +execute 'syn match rstFootnoteReference contains=@NoSpell' . + \ ' +\[\%(\d\+\|#\%(' . s:ReferenceName . '\)\=\|\*\)\]_+' + +execute 'syn match rstCitationReference contains=@NoSpell' . + \ ' +\[' . s:ReferenceName . '\]_\ze\%($\|\s\|[''")\]}>/:.,;!?\\-]\)+' + +execute 'syn match rstHyperlinkReference' . + \ ' /\<' . s:ReferenceName . '__\=\ze\%($\|\s\|[''")\]}>/:.,;!?\\-]\)/' + +syn match rstStandaloneHyperlink contains=@NoSpell + \ "\<\%(\%(\%(https\=\|file\|ftp\|gopher\)://\|\%(mailto\|news\):\)[^[:space:]'\"<>]\+\|www[[:alnum:]_-]*\.[[:alnum:]_-]\+\.[^[:space:]'\"<>]\+\)[[:alnum:]/]" + +syn region rstCodeBlock contained matchgroup=rstDirective + \ start=+\%(sourcecode\|code\%(-block\)\=\)::\s\+\w*\_s*\n\ze\z(\s\+\)+ + \ skip=+^$+ + \ end=+^\z1\@!+ + \ contains=@NoSpell +syn cluster rstDirectives add=rstCodeBlock + +if !exists('g:rst_syntax_code_list') + let g:rst_syntax_code_list = ['vim', 'java', 'cpp', 'lisp', 'php', + \ 'python', 'perl', 'sh'] +endif + +for code in g:rst_syntax_code_list + unlet! b:current_syntax + " guard against setting 'isk' option which might cause problems (issue #108) + let prior_isk = &l:iskeyword + exe 'syn include @rst'.code.' syntax/'.code.'.vim' + exe 'syn region rstDirective'.code.' matchgroup=rstDirective fold' + \.' start=#\%(sourcecode\|code\%(-block\)\=\)::\s\+'.code.'\_s*\n\ze\z(\s\+\)#' + \.' skip=#^$#' + \.' end=#^\z1\@!#' + \.' contains=@NoSpell,@rst'.code + exe 'syn cluster rstDirectives add=rstDirective'.code + " reset 'isk' setting, if it has been changed + if &l:iskeyword !=# prior_isk + let &l:iskeyword = prior_isk + endif + unlet! prior_isk +endfor + +" TODO: Use better syncing. +syn sync minlines=50 linebreaks=2 + +hi def link rstTodo Todo +hi def link rstComment Comment +hi def link rstSections Title +hi def link rstTransition rstSections +hi def link rstLiteralBlock String +hi def link rstQuotedLiteralBlock String +hi def link rstDoctestBlock PreProc +hi def link rstTableLines rstDelimiter +hi def link rstSimpleTableLines rstTableLines +hi def link rstExplicitMarkup rstDirective +hi def link rstDirective Keyword +hi def link rstFootnote String +hi def link rstCitation String +hi def link rstHyperlinkTarget String +hi def link rstExDirective String +hi def link rstSubstitutionDefinition rstDirective +hi def link rstDelimiter Delimiter +hi def rstEmphasis ctermfg=13 term=italic cterm=italic gui=italic +hi def rstStrongEmphasis ctermfg=1 term=bold cterm=bold gui=bold +hi def link rstInterpretedTextOrHyperlinkReference Identifier +hi def link rstInlineLiteral String +hi def link rstSubstitutionReference PreProc +hi def link rstInlineInternalTargets Identifier +hi def link rstFootnoteReference Identifier +hi def link rstCitationReference Identifier +hi def link rstHyperLinkReference Identifier +hi def link rstStandaloneHyperlink Identifier +hi def link rstCodeBlock String + +let b:current_syntax = "rst" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/rtf.vim b/syntax/rtf.vim new file mode 100644 index 0000000..daee3f1 --- /dev/null +++ b/syntax/rtf.vim @@ -0,0 +1,79 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Rich Text Format +" "*.rtf" files +" +" The Rich Text Format (RTF) Specification is a method of encoding formatted +" text and graphics for easy transfer between applications. +" .hlp (windows help files) use compiled rtf files +" rtf documentation at http://night.primate.wisc.edu/software/RTF/ +" +" Maintainer: Dominique Stéphan (dominique@mggen.com) +" URL: http://www.mggen.com/vim/syntax/rtf.zip +" Last change: 2001 Mai 02 + +" TODO: render underline, italic, bold + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" case on (all controls must be lower case) +syn case match + +" Control Words +syn match rtfControlWord "\\[a-z]\+[\-]\=[0-9]*" + +" New Control Words (not in the 1987 specifications) +syn match rtfNewControlWord "\\\*\\[a-z]\+[\-]\=[0-9]*" + +" Control Symbol : any \ plus a non alpha symbol, *, \, { and } and ' +syn match rtfControlSymbol "\\[^a-zA-Z\*\{\}\\']" + +" { } and \ are special characters, to use them +" we add a backslash \ +syn match rtfCharacter "\\\\" +syn match rtfCharacter "\\{" +syn match rtfCharacter "\\}" +" Escaped characters (for 8 bytes characters upper than 127) +syn match rtfCharacter "\\'[A-Za-z0-9][A-Za-z0-9]" +" Unicode +syn match rtfUnicodeCharacter "\\u[0-9][0-9]*" + +" Color values, we will put this value in Red, Green or Blue +syn match rtfRed "\\red[0-9][0-9]*" +syn match rtfGreen "\\green[0-9][0-9]*" +syn match rtfBlue "\\blue[0-9][0-9]*" + +" Some stuff for help files +syn match rtfFootNote "[#$K+]{\\footnote.*}" contains=rtfControlWord,rtfNewControlWord + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + + +hi def link rtfControlWord Statement +hi def link rtfNewControlWord Special +hi def link rtfControlSymbol Constant +hi def link rtfCharacter Character +hi def link rtfUnicodeCharacter SpecialChar +hi def link rtfFootNote Comment + +" Define colors for the syntax file +hi rtfRed term=underline cterm=underline ctermfg=DarkRed gui=underline guifg=DarkRed +hi rtfGreen term=underline cterm=underline ctermfg=DarkGreen gui=underline guifg=DarkGreen +hi rtfBlue term=underline cterm=underline ctermfg=DarkBlue gui=underline guifg=DarkBlue + +hi def link rtfRed rtfRed +hi def link rtfGreen rtfGreen +hi def link rtfBlue rtfBlue + + + +let b:current_syntax = "rtf" + +" vim:ts=8 + +endif diff --git a/syntax/ruby.vim b/syntax/ruby.vim index da1ad8f..cd41d29 100644 --- a/syntax/ruby.vim +++ b/syntax/ruby.vim @@ -1,3 +1,559 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Ruby +" Maintainer: Doug Kearns +" URL: https://github.com/vim-ruby/vim-ruby +" Release Coordinator: Doug Kearns +" ---------------------------------------------------------------------------- +" +" Previous Maintainer: Mirko Nasato +" Thanks to perl.vim authors, and to Reimer Behrends. :-) (MN) +" ---------------------------------------------------------------------------- + +" Prelude {{{1 +if exists("b:current_syntax") + finish +endif + +" this file uses line continuations +let s:cpo_sav = &cpo +set cpo&vim + +" Folding Config {{{1 +if has("folding") && exists("ruby_fold") + setlocal foldmethod=syntax +endif + +let s:foldable_groups = split( + \ get( + \ b:, + \ 'ruby_foldable_groups', + \ get(g:, 'ruby_foldable_groups', 'ALL') + \ ) + \ ) + +function! s:foldable(...) abort + if index(s:foldable_groups, 'ALL') > -1 + return 1 + endif + + for l:i in a:000 + if index(s:foldable_groups, l:i) > -1 + return 1 + endif + endfor + + return 0 +endfunction " }}} + +syn cluster rubyNotTop contains=@rubyExtendedStringSpecial,@rubyRegexpSpecial,@rubyDeclaration,rubyConditional,rubyExceptional,rubyMethodExceptional,rubyTodo + +" Whitespace Errors {{{1 +if exists("ruby_space_errors") + if !exists("ruby_no_trail_space_error") + syn match rubySpaceError display excludenl "\s\+$" + endif + if !exists("ruby_no_tab_space_error") + syn match rubySpaceError display " \+\t"me=e-1 + endif +endif + +" Operators {{{1 +if exists("ruby_operators") + syn match rubyOperator "[~!^|*/%+-]\|&\.\@!\|\%(class\s*\)\@\|<=\|\%(<\|\>\|>=\|=\@1\|\*\*\|\.\.\.\|\.\.\|::" + syn match rubyOperator "->\|-=\|/=\|\*\*=\|\*=\|&&=\|&=\|&&\|||=\||=\|||\|%=\|+=\|!\~\|!=" + syn region rubyBracketOperator matchgroup=rubyOperator start="\%(\w[?!]\=\|[]})]\)\@2<=\[\s*" end="\s*]" contains=ALLBUT,@rubyNotTop +endif + +" Expression Substitution and Backslash Notation {{{1 +syn match rubyStringEscape "\\\\\|\\[abefnrstv]\|\\\o\{1,3}\|\\x\x\{1,2}" contained display +syn match rubyStringEscape "\%(\\M-\\C-\|\\C-\\M-\|\\M-\\c\|\\c\\M-\|\\c\|\\C-\|\\M-\)\%(\\\o\{1,3}\|\\x\x\{1,2}\|\\\=\S\)" contained display +syn match rubyQuoteEscape "\\[\\']" contained display + +syn region rubyInterpolation matchgroup=rubyInterpolationDelimiter start="#{" end="}" contained contains=ALLBUT,@rubyNotTop +syn match rubyInterpolation "#\%(\$\|@@\=\)\w\+" display contained contains=rubyInterpolationDelimiter,rubyInstanceVariable,rubyClassVariable,rubyGlobalVariable,rubyPredefinedVariable +syn match rubyInterpolationDelimiter "#\ze\%(\$\|@@\=\)\w\+" display contained +syn match rubyInterpolation "#\$\%(-\w\|\W\)" display contained contains=rubyInterpolationDelimiter,rubyPredefinedVariable,rubyInvalidVariable +syn match rubyInterpolationDelimiter "#\ze\$\%(-\w\|\W\)" display contained +syn region rubyNoInterpolation start="\\#{" end="}" contained +syn match rubyNoInterpolation "\\#{" display contained +syn match rubyNoInterpolation "\\#\%(\$\|@@\=\)\w\+" display contained +syn match rubyNoInterpolation "\\#\$\W" display contained + +syn match rubyDelimiterEscape "\\[(<{\[)>}\]]" transparent display contained contains=NONE + +syn region rubyNestedParentheses start="(" skip="\\\\\|\\)" matchgroup=rubyString end=")" transparent contained +syn region rubyNestedCurlyBraces start="{" skip="\\\\\|\\}" matchgroup=rubyString end="}" transparent contained +syn region rubyNestedAngleBrackets start="<" skip="\\\\\|\\>" matchgroup=rubyString end=">" transparent contained +syn region rubyNestedSquareBrackets start="\[" skip="\\\\\|\\\]" matchgroup=rubyString end="\]" transparent contained + +" Regular Expression Metacharacters {{{1 +" These are mostly Oniguruma ready +syn region rubyRegexpComment matchgroup=rubyRegexpSpecial start="(?#" skip="\\)" end=")" contained +syn region rubyRegexpParens matchgroup=rubyRegexpSpecial start="(\(?:\|?<\=[=!]\|?>\|?<[a-z_]\w*>\|?[imx]*-[imx]*:\=\|\%(?#\)\@!\)" skip="\\)" end=")" contained transparent contains=@rubyRegexpSpecial +syn region rubyRegexpBrackets matchgroup=rubyRegexpCharClass start="\[\^\=" skip="\\\]" end="\]" contained transparent contains=rubyStringEscape,rubyRegexpEscape,rubyRegexpCharClass oneline +syn match rubyRegexpCharClass "\\[DdHhSsWw]" contained display +syn match rubyRegexpCharClass "\[:\^\=\%(alnum\|alpha\|ascii\|blank\|cntrl\|digit\|graph\|lower\|print\|punct\|space\|upper\|xdigit\):\]" contained +syn match rubyRegexpEscape "\\[].*?+^$|\\/(){}[]" contained +syn match rubyRegexpQuantifier "[*?+][?+]\=" contained display +syn match rubyRegexpQuantifier "{\d\+\%(,\d*\)\=}?\=" contained display +syn match rubyRegexpAnchor "[$^]\|\\[ABbGZz]" contained display +syn match rubyRegexpDot "\." contained display +syn match rubyRegexpSpecial "|" contained display +syn match rubyRegexpSpecial "\\[1-9]\d\=\d\@!" contained display +syn match rubyRegexpSpecial "\\k<\%([a-z_]\w*\|-\=\d\+\)\%([+-]\d\+\)\=>" contained display +syn match rubyRegexpSpecial "\\k'\%([a-z_]\w*\|-\=\d\+\)\%([+-]\d\+\)\='" contained display +syn match rubyRegexpSpecial "\\g<\%([a-z_]\w*\|-\=\d\+\)>" contained display +syn match rubyRegexpSpecial "\\g'\%([a-z_]\w*\|-\=\d\+\)'" contained display + +syn cluster rubyStringSpecial contains=rubyInterpolation,rubyNoInterpolation,rubyStringEscape +syn cluster rubyExtendedStringSpecial contains=@rubyStringSpecial,rubyNestedParentheses,rubyNestedCurlyBraces,rubyNestedAngleBrackets,rubyNestedSquareBrackets +syn cluster rubyRegexpSpecial contains=rubyInterpolation,rubyNoInterpolation,rubyStringEscape,rubyRegexpSpecial,rubyRegexpEscape,rubyRegexpBrackets,rubyRegexpCharClass,rubyRegexpDot,rubyRegexpQuantifier,rubyRegexpAnchor,rubyRegexpParens,rubyRegexpComment + +" Numbers and ASCII Codes {{{1 +syn match rubyASCIICode "\%(\w\|[]})\"'/]\)\@1" display +syn match rubyInteger "\%(\%(\w\|[]})\"']\s*\)\@" display +syn match rubyInteger "\%(\%(\w\|[]})\"']\s*\)\@" display +syn match rubyInteger "\%(\%(\w\|[]})\"']\s*\)\@" display +syn match rubyFloat "\%(\%(\w\|[]})\"']\s*\)\@" display +syn match rubyFloat "\%(\%(\w\|[]})\"']\s*\)\@" display + +" Identifiers {{{1 +syn match rubyLocalVariableOrMethod "\<[_[:lower:]][_[:alnum:]]*[?!=]\=" contains=NONE display transparent +syn match rubyBlockArgument "&[_[:lower:]][_[:alnum:]]" contains=NONE display transparent + +syn match rubyConstant "\%(\%(^\|[^.]\)\.\s*\)\@\%(\s*(\)\@!" +syn match rubyClassVariable "@@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display +syn match rubyInstanceVariable "@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display +syn match rubyGlobalVariable "$\%(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\|-.\)" +syn match rubySymbol "[]})\"':]\@1\|<=\|<\|===\|[=!]=\|[=!]\~\|!@\|!\|>>\|>=\|>\||\|-@\|-\|/\|\[]=\|\[]\|\*\*\|\*\|&\|%\|+@\|+\|`\)" +syn match rubySymbol "[]})\"':]\@1_,;:!?/.'"@$*\&+0]\)" +syn match rubySymbol "[]})\"':]\@1\@!\)\=" + +if s:foldable(':') + syn region rubySymbol start="[]})\"':]\@1\%(\s*(\)*\s*(\@=" + +syn match rubyBlockParameter "\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" contained +syn region rubyBlockParameterList start="\%(\%(\\|{\)\_s*\)\@32<=|" end="|" oneline display contains=rubyBlockParameter + +syn match rubyInvalidVariable "$[^ A-Za-z_-]" +syn match rubyPredefinedVariable #$[!$&"'*+,./0:;<=>?@\`~]# +syn match rubyPredefinedVariable "$\d\+" display +syn match rubyPredefinedVariable "$_\>" display +syn match rubyPredefinedVariable "$-[0FIKadilpvw]\>" display +syn match rubyPredefinedVariable "$\%(deferr\|defout\|stderr\|stdin\|stdout\)\>" display +syn match rubyPredefinedVariable "$\%(DEBUG\|FILENAME\|KCODE\|LOADED_FEATURES\|LOAD_PATH\|PROGRAM_NAME\|SAFE\|VERBOSE\)\>" display +syn match rubyPredefinedConstant "\%(\%(^\|[^.]\)\.\s*\)\@\%(\s*(\)\@!" +syn match rubyPredefinedConstant "\%(\%(^\|[^.]\)\.\s*\)\@\%(\s*(\)\@!" + +" Normal Regular Expression {{{1 +if s:foldable('/') + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\%(^\|\<\%(and\|or\|while\|until\|unless\|if\|elsif\|when\|not\|then\|else\)\|[;\~=!|&(,{[<>?:*+-]\)\s*\)\@<=/" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial fold + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\h\k*\s\+\)\@<=/[ \t=]\@!" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial fold +else + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\%(^\|\<\%(and\|or\|while\|until\|unless\|if\|elsif\|when\|not\|then\|else\)\|[;\~=!|&(,{[<>?:*+-]\)\s*\)\@<=/" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\h\k*\s\+\)\@<=/[ \t=]\@!" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial +endif + +" Generalized Regular Expression {{{1 +if s:foldable('%') + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial fold + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r{" end="}[iomxneus]*" skip="\\\\\|\\}" contains=@rubyRegexpSpecial fold + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r<" end=">[iomxneus]*" skip="\\\\\|\\>" contains=@rubyRegexpSpecial,rubyNestedAngleBrackets,rubyDelimiterEscape fold + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r\[" end="\][iomxneus]*" skip="\\\\\|\\\]" contains=@rubyRegexpSpecial fold + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r(" end=")[iomxneus]*" skip="\\\\\|\\)" contains=@rubyRegexpSpecial fold + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r\z(\s\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial fold +else + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r{" end="}[iomxneus]*" skip="\\\\\|\\}" contains=@rubyRegexpSpecial + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r<" end=">[iomxneus]*" skip="\\\\\|\\>" contains=@rubyRegexpSpecial,rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r\[" end="\][iomxneus]*" skip="\\\\\|\\\]" contains=@rubyRegexpSpecial + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r(" end=")[iomxneus]*" skip="\\\\\|\\)" contains=@rubyRegexpSpecial + syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="%r\z(\s\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial +endif + +" Normal String {{{1 +let s:spell_cluster = exists('ruby_spellcheck_strings') ? ',@Spell' : '' +exe 'syn region rubyString matchgroup=rubyStringDelimiter start="\"" end="\"" skip="\\\\\|\\\"" ' . + \ (s:foldable('%') ? 'fold' : '') . ' contains=@rubyStringSpecial' . s:spell_cluster +exe 'syn region rubyString matchgroup=rubyStringDelimiter start="''" end="''" skip="\\\\\|\\''" ' . + \ (s:foldable('%') ? 'fold' : '') . ' contains=rubyQuoteEscape' . s:spell_cluster + +" Shell Command Output {{{1 +if s:foldable('%') + syn region rubyString matchgroup=rubyStringDelimiter start="`" end="`" skip="\\\\\|\\`" contains=@rubyStringSpecial fold +else + syn region rubyString matchgroup=rubyStringDelimiter start="`" end="`" skip="\\\\\|\\`" contains=@rubyStringSpecial +endif + +" Generalized Single Quoted String, Symbol and Array of Strings {{{1 +if s:foldable('%') + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" fold + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]{" end="}" skip="\\\\\|\\}" fold contains=rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]<" end=">" skip="\\\\\|\\>" fold contains=rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]\[" end="\]" skip="\\\\\|\\\]" fold contains=rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw](" end=")" skip="\\\\\|\\)" fold contains=rubyNestedParentheses,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%q\z(\s\)" end="\z1" skip="\\\\\|\\\z1" fold + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" fold + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s{" end="}" skip="\\\\\|\\}" fold contains=rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s<" end=">" skip="\\\\\|\\>" fold contains=rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s\[" end="\]" skip="\\\\\|\\\]" fold contains=rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s(" end=")" skip="\\\\\|\\)" fold contains=rubyNestedParentheses,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%s\z(\s\)" end="\z1" skip="\\\\\|\\\z1" fold +else + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]{" end="}" skip="\\\\\|\\}" contains=rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]<" end=">" skip="\\\\\|\\>" contains=rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw]\[" end="\]" skip="\\\\\|\\\]" contains=rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[qw](" end=")" skip="\\\\\|\\)" contains=rubyNestedParentheses,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%q\z(\s\)" end="\z1" skip="\\\\\|\\\z1" + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s{" end="}" skip="\\\\\|\\}" contains=rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s<" end=">" skip="\\\\\|\\>" contains=rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s\[" end="\]" skip="\\\\\|\\\]" contains=rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%s(" end=")" skip="\\\\\|\\)" contains=rubyNestedParentheses,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%s\z(\s\)" end="\z1" skip="\\\\\|\\\z1" +endif + +" Generalized Double Quoted String and Array of Strings and Shell Command Output {{{1 +" Note: %= is not matched here as the beginning of a double quoted string +if s:foldable('%') + syn region rubyString matchgroup=rubyStringDelimiter start="%\z([~`!@#$%^&*_\-+|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial fold + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial fold + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\={" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces,rubyDelimiterEscape fold + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\=<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets,rubyDelimiterEscape fold + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\=\[" end="\]" skip="\\\\\|\\\]" contains=@rubyStringSpecial,rubyNestedSquareBrackets,rubyDelimiterEscape fold + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\=(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses,rubyDelimiterEscape fold + syn region rubyString matchgroup=rubyStringDelimiter start="%[Qx]\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial fold +else + syn region rubyString matchgroup=rubyStringDelimiter start="%\z([~`!@#$%^&*_\-+|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\={" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\=<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\=\[" end="\]" skip="\\\\\|\\\]" contains=@rubyStringSpecial,rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[QWx]\=(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses,rubyDelimiterEscape + syn region rubyString matchgroup=rubyStringDelimiter start="%[Qx]\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial +endif + +" Array of Symbols {{{1 +if s:foldable('%') + " Array of Symbols + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" fold + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i{" end="}" skip="\\\\\|\\}" fold contains=rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i<" end=">" skip="\\\\\|\\>" fold contains=rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i\[" end="\]" skip="\\\\\|\\\]" fold contains=rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i(" end=")" skip="\\\\\|\\)" fold contains=rubyNestedParentheses,rubyDelimiterEscape + + " Array of interpolated Symbols + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial fold + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I{" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces,rubyDelimiterEscape fold + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets,rubyDelimiterEscape fold + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I\[" end="\]" skip="\\\\\|\\\]" contains=@rubyStringSpecial,rubyNestedSquareBrackets,rubyDelimiterEscape fold + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses,rubyDelimiterEscape fold +else + " Array of Symbols + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i{" end="}" skip="\\\\\|\\}" contains=rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i<" end=">" skip="\\\\\|\\>" contains=rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i\[" end="\]" skip="\\\\\|\\\]" contains=rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%i(" end=")" skip="\\\\\|\\)" contains=rubyNestedParentheses,rubyDelimiterEscape + + " Array of interpolated Symbols + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I{" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I\[" end="\]" skip="\\\\\|\\\]" contains=@rubyStringSpecial,rubyNestedSquareBrackets,rubyDelimiterEscape + syn region rubySymbol matchgroup=rubySymbolDelimiter start="%I(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses,rubyDelimiterEscape +endif + +" Here Document {{{1 +syn region rubyHeredocStart matchgroup=rubyStringDelimiter start=+\%(\%(class\s*\|\%([]})"'.]\|::\)\)\_s*\|\w\)\@>\|[<>]=\=\|<=>\|===\|[=!]=\|[=!]\~\|!\|`\)\%([[:space:];#(]\|$\)\@=" contained containedin=rubyAliasDeclaration,rubyAliasDeclaration2,rubyMethodDeclaration + +syn cluster rubyDeclaration contains=rubyAliasDeclaration,rubyAliasDeclaration2,rubyMethodDeclaration,rubyModuleDeclaration,rubyClassDeclaration,rubyFunction,rubyBlockParameter + +" Keywords {{{1 +" Note: the following keywords have already been defined: +" begin case class def do end for if module unless until while +syn match rubyControl "\<\%(and\|break\|in\|next\|not\|or\|redo\|rescue\|retry\|return\)\>[?!]\@!" +syn match rubyOperator "\[?!]\@!" +syn match rubyBoolean "\<\%(true\|false\)\>[?!]\@!" +syn match rubyPseudoVariable "\<\%(nil\|self\|__ENCODING__\|__dir__\|__FILE__\|__LINE__\|__callee__\|__method__\)\>[?!]\@!" " TODO: reorganise +syn match rubyBeginEnd "\<\%(BEGIN\|END\)\>[?!]\@!" + +" Expensive Mode {{{1 +" Match 'end' with the appropriate opening keyword for syntax based folding +" and special highlighting of module/class/method definitions +if !exists("b:ruby_no_expensive") && !exists("ruby_no_expensive") + syn match rubyDefine "\" nextgroup=rubyAliasDeclaration skipwhite skipnl + syn match rubyDefine "\" nextgroup=rubyMethodDeclaration skipwhite skipnl + syn match rubyDefine "\" nextgroup=rubyFunction skipwhite skipnl + syn match rubyClass "\" nextgroup=rubyClassDeclaration skipwhite skipnl + syn match rubyModule "\" nextgroup=rubyModuleDeclaration skipwhite skipnl + + if s:foldable('def') + syn region rubyMethodBlock start="\" matchgroup=rubyDefine end="\%(\" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyMethodBlock start="\" matchgroup=rubyDefine end="\%(\" contains=ALLBUT,@rubyNotTop + endif + + if s:foldable('class') + syn region rubyBlock start="\" matchgroup=rubyClass end="\" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyBlock start="\" matchgroup=rubyClass end="\" contains=ALLBUT,@rubyNotTop + endif + + if s:foldable('module') + syn region rubyBlock start="\" matchgroup=rubyModule end="\" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyBlock start="\" matchgroup=rubyModule end="\" contains=ALLBUT,@rubyNotTop + endif + + " modifiers + syn match rubyLineContinuation "\\$" nextgroup=rubyConditionalModifier,rubyRepeatModifier skipwhite skipnl + syn match rubyConditionalModifier "\<\%(if\|unless\)\>" + syn match rubyRepeatModifier "\<\%(while\|until\)\>" + + if s:foldable('do') + syn region rubyDoBlock matchgroup=rubyControl start="\" end="\" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyDoBlock matchgroup=rubyControl start="\" end="\" contains=ALLBUT,@rubyNotTop + endif + + " curly bracket block or hash literal + if s:foldable('{') + syn region rubyCurlyBlock matchgroup=rubyCurlyBlockDelimiter start="{" end="}" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyCurlyBlock matchgroup=rubyCurlyBlockDelimiter start="{" end="}" contains=ALLBUT,@rubyNotTop + endif + + if s:foldable('[') + syn region rubyArrayLiteral matchgroup=rubyArrayDelimiter start="\%(\w\|[\]})]\)\@" end="\" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyBlockExpression matchgroup=rubyControl start="\" end="\" contains=ALLBUT,@rubyNotTop + endif + + if s:foldable('case') + syn region rubyCaseExpression matchgroup=rubyConditional start="\" end="\" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyCaseExpression matchgroup=rubyConditional start="\" end="\" contains=ALLBUT,@rubyNotTop + endif + + if s:foldable('if') + syn region rubyConditionalExpression matchgroup=rubyConditional start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*%&^|+=-]\|\%(\<[_[:lower:]][_[:alnum:]]*\)\@" end="\%(\%(\%(\.\@1" contains=ALLBUT,@rubyNotTop fold + else + syn region rubyConditionalExpression matchgroup=rubyConditional start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*%&^|+=-]\|\%(\<[_[:lower:]][_[:alnum:]]*\)\@" end="\%(\%(\%(\.\@1" contains=ALLBUT,@rubyNotTop + endif + + syn match rubyConditional "\<\%(then\|else\|when\)\>[?!]\@!" contained containedin=rubyCaseExpression + syn match rubyConditional "\<\%(then\|else\|elsif\)\>[?!]\@!" contained containedin=rubyConditionalExpression + + syn match rubyExceptional "\<\%(\%(\%(;\|^\)\s*\)\@<=rescue\|else\|ensure\)\>[?!]\@!" contained containedin=rubyBlockExpression + syn match rubyMethodExceptional "\<\%(\%(\%(;\|^\)\s*\)\@<=rescue\|else\|ensure\)\>[?!]\@!" contained containedin=rubyMethodBlock + + " statements with optional 'do' + syn region rubyOptionalDoLine matchgroup=rubyRepeat start="\[?!]\@!" start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+-]\|\%(\<[_[:lower:]][_[:alnum:]]*\)\@" matchgroup=rubyOptionalDo end="\%(\\)" end="\ze\%(;\|$\)" oneline contains=ALLBUT,@rubyNotTop + + if s:foldable('for') + syn region rubyRepeatExpression start="\[?!]\@!" start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+-]\|\%(\<[_[:lower:]][_[:alnum:]]*\)\@" matchgroup=rubyRepeat end="\" contains=ALLBUT,@rubyNotTop nextgroup=rubyOptionalDoLine fold + else + syn region rubyRepeatExpression start="\[?!]\@!" start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+-]\|\%(\<[_[:lower:]][_[:alnum:]]*\)\@" matchgroup=rubyRepeat end="\" contains=ALLBUT,@rubyNotTop nextgroup=rubyOptionalDoLine + endif + + if !exists("ruby_minlines") + let ruby_minlines = 500 + endif + exec "syn sync minlines=" . ruby_minlines + +else + syn match rubyControl "\[?!]\@!" nextgroup=rubyMethodDeclaration skipwhite skipnl + syn match rubyControl "\[?!]\@!" nextgroup=rubyClassDeclaration skipwhite skipnl + syn match rubyControl "\[?!]\@!" nextgroup=rubyModuleDeclaration skipwhite skipnl + syn match rubyControl "\<\%(case\|begin\|do\|for\|if\|unless\|while\|until\|else\|elsif\|ensure\|then\|when\|end\)\>[?!]\@!" + syn match rubyKeyword "\<\%(alias\|undef\)\>[?!]\@!" +endif + +" Special Methods {{{1 +if !exists("ruby_no_special_methods") + syn keyword rubyAccess public protected private public_class_method private_class_method public_constant private_constant module_function + " attr is a common variable name + syn match rubyAttribute "\%(\%(^\|;\)\s*\)\@<=attr\>\(\s*[.=]\)\@!" + syn keyword rubyAttribute attr_accessor attr_reader attr_writer + syn match rubyControl "\<\%(exit!\|\%(abort\|at_exit\|exit\|fork\|loop\|trap\)\>[?!]\@!\)" + syn keyword rubyEval eval class_eval instance_eval module_eval + syn keyword rubyException raise fail catch throw + " false positive with 'include?' + syn match rubyInclude "\[?!]\@!" + syn keyword rubyInclude autoload extend load prepend refine require require_relative using + syn keyword rubyKeyword callcc caller lambda proc +endif + +" Comments and Documentation {{{1 +syn match rubySharpBang "\%^#!.*" display +syn keyword rubyTodo FIXME NOTE TODO OPTIMIZE HACK REVIEW XXX todo contained +syn match rubyComment "#.*" contains=rubySharpBang,rubySpaceError,rubyTodo,@Spell +if !exists("ruby_no_comment_fold") && s:foldable('#') + syn region rubyMultilineComment start="^\s*#.*\n\%(^\s*#\)\@=" end="^\s*#.*\n\%(^\s*#\)\@!" contains=rubyComment transparent fold keepend + syn region rubyDocumentation start="^=begin\ze\%(\s.*\)\=$" end="^=end\%(\s.*\)\=$" contains=rubySpaceError,rubyTodo,@Spell fold +else + syn region rubyDocumentation start="^=begin\s*$" end="^=end\s*$" contains=rubySpaceError,rubyTodo,@Spell +endif + +" Keyword Nobbling {{{1 +" Note: this is a hack to prevent 'keywords' being highlighted as such when called as methods with an explicit receiver +syn match rubyKeywordAsMethod "\%(\%(\.\@1\)" transparent contains=NONE +syn match rubyKeywordAsMethod "\(defined?\|exit!\)\@!\<[_[:lower:]][_[:alnum:]]*[?!]" transparent contains=NONE + +" More Symbols {{{1 +syn match rubySymbol "\%([{(,]\_s*\)\zs\l\w*[!?]\=::\@!"he=e-1 +syn match rubySymbol "[]})\"':]\@1 +" Maintainer: Ben Blum +" Maintainer: Chris Morgan +" Last Change: Feb 24, 2016 +" For bugs, patches and license go to https://github.com/rust-lang/rust.vim + +if version < 600 + syntax clear +elseif exists("b:current_syntax") + finish +endif + +" Syntax definitions {{{1 +" Basic keywords {{{2 +syn keyword rustConditional match if else +syn keyword rustRepeat for loop while +syn keyword rustTypedef type nextgroup=rustIdentifier skipwhite skipempty +syn keyword rustStructure struct enum nextgroup=rustIdentifier skipwhite skipempty +syn keyword rustUnion union nextgroup=rustIdentifier skipwhite skipempty contained +syn match rustUnionContextual /\/ + +syn keyword rustInvalidBareKeyword crate + +syn keyword rustPubScopeCrate crate contained +syn match rustPubScopeDelim /[()]/ contained +syn match rustPubScope /([^()]*)/ contained contains=rustPubScopeDelim,rustPubScopeCrate,rustSuper,rustModPath,rustModPathSep,rustSelf transparent + +syn keyword rustExternCrate crate contained nextgroup=rustIdentifier,rustExternCrateString skipwhite skipempty +" This is to get the `bar` part of `extern crate "foo" as bar;` highlighting. +syn match rustExternCrateString /".*"\_s*as/ contained nextgroup=rustIdentifier skipwhite transparent skipempty contains=rustString,rustOperator +syn keyword rustObsoleteExternMod mod contained nextgroup=rustIdentifier skipwhite skipempty + +syn match rustIdentifier contains=rustIdentifierPrime "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained +syn match rustFuncName "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained + +syn region rustBoxPlacement matchgroup=rustBoxPlacementParens start="(" end=")" contains=TOP contained +" Ideally we'd have syntax rules set up to match arbitrary expressions. Since +" we don't, we'll just define temporary contained rules to handle balancing +" delimiters. +syn region rustBoxPlacementBalance start="(" end=")" containedin=rustBoxPlacement transparent +syn region rustBoxPlacementBalance start="\[" end="\]" containedin=rustBoxPlacement transparent +" {} are handled by rustFoldBraces + +syn region rustMacroRepeat matchgroup=rustMacroRepeatDelimiters start="$(" end=")" contains=TOP nextgroup=rustMacroRepeatCount +syn match rustMacroRepeatCount ".\?[*+]" contained +syn match rustMacroVariable "$\w\+" + +" Reserved (but not yet used) keywords {{{2 +syn keyword rustReservedKeyword alignof become do offsetof priv pure sizeof typeof unsized yield abstract virtual final override macro + +" Built-in types {{{2 +syn keyword rustType isize usize char bool u8 u16 u32 u64 u128 f32 +syn keyword rustType f64 i8 i16 i32 i64 i128 str Self + +" Things from the libstd v1 prelude (src/libstd/prelude/v1.rs) {{{2 +" This section is just straight transformation of the contents of the prelude, +" to make it easy to update. + +" Reexported core operators {{{3 +syn keyword rustTrait Copy Send Sized Sync +syn keyword rustTrait Drop Fn FnMut FnOnce + +" Reexported functions {{{3 +" There’s no point in highlighting these; when one writes drop( or drop::< it +" gets the same highlighting anyway, and if someone writes `let drop = …;` we +" don’t really want *that* drop to be highlighted. +"syn keyword rustFunction drop + +" Reexported types and traits {{{3 +syn keyword rustTrait Box +syn keyword rustTrait ToOwned +syn keyword rustTrait Clone +syn keyword rustTrait PartialEq PartialOrd Eq Ord +syn keyword rustTrait AsRef AsMut Into From +syn keyword rustTrait Default +syn keyword rustTrait Iterator Extend IntoIterator +syn keyword rustTrait DoubleEndedIterator ExactSizeIterator +syn keyword rustEnum Option +syn keyword rustEnumVariant Some None +syn keyword rustEnum Result +syn keyword rustEnumVariant Ok Err +syn keyword rustTrait SliceConcatExt +syn keyword rustTrait String ToString +syn keyword rustTrait Vec + +" Other syntax {{{2 +syn keyword rustSelf self +syn keyword rustBoolean true false + +" If foo::bar changes to foo.bar, change this ("::" to "\."). +" If foo::bar changes to Foo::bar, change this (first "\w" to "\u"). +syn match rustModPath "\w\(\w\)*::[^<]"he=e-3,me=e-3 +syn match rustModPathSep "::" + +syn match rustFuncCall "\w\(\w\)*("he=e-1,me=e-1 +syn match rustFuncCall "\w\(\w\)*::<"he=e-3,me=e-3 " foo::(); + +" This is merely a convention; note also the use of [A-Z], restricting it to +" latin identifiers rather than the full Unicode uppercase. I have not used +" [:upper:] as it depends upon 'noignorecase' +"syn match rustCapsIdent display "[A-Z]\w\(\w\)*" + +syn match rustOperator display "\%(+\|-\|/\|*\|=\|\^\|&\||\|!\|>\|<\|%\)=\?" +" This one isn't *quite* right, as we could have binary-& with a reference +syn match rustSigil display /&\s\+[&~@*][^)= \t\r\n]/he=e-1,me=e-1 +syn match rustSigil display /[&~@*][^)= \t\r\n]/he=e-1,me=e-1 +" This isn't actually correct; a closure with no arguments can be `|| { }`. +" Last, because the & in && isn't a sigil +syn match rustOperator display "&&\|||" +" This is rustArrowCharacter rather than rustArrow for the sake of matchparen, +" so it skips the ->; see http://stackoverflow.com/a/30309949 for details. +syn match rustArrowCharacter display "->" +syn match rustQuestionMark display "?\([a-zA-Z]\+\)\@!" + +syn match rustMacro '\w\(\w\)*!' contains=rustAssert,rustPanic +syn match rustMacro '#\w\(\w\)*' contains=rustAssert,rustPanic + +syn match rustEscapeError display contained /\\./ +syn match rustEscape display contained /\\\([nrt0\\'"]\|x\x\{2}\)/ +syn match rustEscapeUnicode display contained /\\u{\x\{1,6}}/ +syn match rustStringContinuation display contained /\\\n\s*/ +syn region rustString start=+b"+ skip=+\\\\\|\\"+ end=+"+ contains=rustEscape,rustEscapeError,rustStringContinuation +syn region rustString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=rustEscape,rustEscapeUnicode,rustEscapeError,rustStringContinuation,@Spell +syn region rustString start='b\?r\z(#*\)"' end='"\z1' contains=@Spell + +syn region rustAttribute start="#!\?\[" end="\]" contains=rustString,rustDerive,rustCommentLine,rustCommentBlock,rustCommentLineDocError,rustCommentBlockDocError +syn region rustDerive start="derive(" end=")" contained contains=rustDeriveTrait +" This list comes from src/libsyntax/ext/deriving/mod.rs +" Some are deprecated (Encodable, Decodable) or to be removed after a new snapshot (Show). +syn keyword rustDeriveTrait contained Clone Hash RustcEncodable RustcDecodable Encodable Decodable PartialEq Eq PartialOrd Ord Rand Show Debug Default FromPrimitive Send Sync Copy + +" Number literals +syn match rustDecNumber display "\<[0-9][0-9_]*\%([iu]\%(size\|8\|16\|32\|64\|128\)\)\=" +syn match rustHexNumber display "\<0x[a-fA-F0-9_]\+\%([iu]\%(size\|8\|16\|32\|64\|128\)\)\=" +syn match rustOctNumber display "\<0o[0-7_]\+\%([iu]\%(size\|8\|16\|32\|64\|128\)\)\=" +syn match rustBinNumber display "\<0b[01_]\+\%([iu]\%(size\|8\|16\|32\|64\|128\)\)\=" + +" Special case for numbers of the form "1." which are float literals, unless followed by +" an identifier, which makes them integer literals with a method call or field access, +" or by another ".", which makes them integer literals followed by the ".." token. +" (This must go first so the others take precedence.) +syn match rustFloat display "\<[0-9][0-9_]*\.\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\|\.\)\@!" +" To mark a number as a normal float, it must have at least one of the three things integral values don't have: +" a decimal point and more numbers; an exponent; and a type suffix. +syn match rustFloat display "\<[0-9][0-9_]*\%(\.[0-9][0-9_]*\)\%([eE][+-]\=[0-9_]\+\)\=\(f32\|f64\)\=" +syn match rustFloat display "\<[0-9][0-9_]*\%(\.[0-9][0-9_]*\)\=\%([eE][+-]\=[0-9_]\+\)\(f32\|f64\)\=" +syn match rustFloat display "\<[0-9][0-9_]*\%(\.[0-9][0-9_]*\)\=\%([eE][+-]\=[0-9_]\+\)\=\(f32\|f64\)" + +" For the benefit of delimitMate +syn region rustLifetimeCandidate display start=/&'\%(\([^'\\]\|\\\(['nrt0\\\"]\|x\x\{2}\|u{\x\{1,6}}\)\)'\)\@!/ end=/[[:cntrl:][:space:][:punct:]]\@=\|$/ contains=rustSigil,rustLifetime +syn region rustGenericRegion display start=/<\%('\|[^[cntrl:][:space:][:punct:]]\)\@=')\S\@=/ end=/>/ contains=rustGenericLifetimeCandidate +syn region rustGenericLifetimeCandidate display start=/\%(<\|,\s*\)\@<='/ end=/[[:cntrl:][:space:][:punct:]]\@=\|$/ contains=rustSigil,rustLifetime + +"rustLifetime must appear before rustCharacter, or chars will get the lifetime highlighting +syn match rustLifetime display "\'\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" +syn match rustLabel display "\'\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*:" +syn match rustCharacterInvalid display contained /b\?'\zs[\n\r\t']\ze'/ +" The groups negated here add up to 0-255 but nothing else (they do not seem to go beyond ASCII). +syn match rustCharacterInvalidUnicode display contained /b'\zs[^[:cntrl:][:graph:][:alnum:][:space:]]\ze'/ +syn match rustCharacter /b'\([^\\]\|\\\(.\|x\x\{2}\)\)'/ contains=rustEscape,rustEscapeError,rustCharacterInvalid,rustCharacterInvalidUnicode +syn match rustCharacter /'\([^\\]\|\\\(.\|x\x\{2}\|u{\x\{1,6}}\)\)'/ contains=rustEscape,rustEscapeUnicode,rustEscapeError,rustCharacterInvalid + +syn match rustShebang /\%^#![^[].*/ +syn region rustCommentLine start="//" end="$" contains=rustTodo,@Spell +syn region rustCommentLineDoc start="//\%(//\@!\|!\)" end="$" contains=rustTodo,@Spell +syn region rustCommentLineDocError start="//\%(//\@!\|!\)" end="$" contains=rustTodo,@Spell contained +syn region rustCommentBlock matchgroup=rustCommentBlock start="/\*\%(!\|\*[*/]\@!\)\@!" end="\*/" contains=rustTodo,rustCommentBlockNest,@Spell +syn region rustCommentBlockDoc matchgroup=rustCommentBlockDoc start="/\*\%(!\|\*[*/]\@!\)" end="\*/" contains=rustTodo,rustCommentBlockDocNest,@Spell +syn region rustCommentBlockDocError matchgroup=rustCommentBlockDocError start="/\*\%(!\|\*[*/]\@!\)" end="\*/" contains=rustTodo,rustCommentBlockDocNestError,@Spell contained +syn region rustCommentBlockNest matchgroup=rustCommentBlock start="/\*" end="\*/" contains=rustTodo,rustCommentBlockNest,@Spell contained transparent +syn region rustCommentBlockDocNest matchgroup=rustCommentBlockDoc start="/\*" end="\*/" contains=rustTodo,rustCommentBlockDocNest,@Spell contained transparent +syn region rustCommentBlockDocNestError matchgroup=rustCommentBlockDocError start="/\*" end="\*/" contains=rustTodo,rustCommentBlockDocNestError,@Spell contained transparent +" FIXME: this is a really ugly and not fully correct implementation. Most +" importantly, a case like ``/* */*`` should have the final ``*`` not being in +" a comment, but in practice at present it leaves comments open two levels +" deep. But as long as you stay away from that particular case, I *believe* +" the highlighting is correct. Due to the way Vim's syntax engine works +" (greedy for start matches, unlike Rust's tokeniser which is searching for +" the earliest-starting match, start or end), I believe this cannot be solved. +" Oh you who would fix it, don't bother with things like duplicating the Block +" rules and putting ``\*\@ +" URL: http://rgarciasuarez.free.fr/vim/syntax/samba.vim +" Last change: 2009 Aug 06 +" +" New maintainer wanted! +" +" Don't forget to run your config file through testparm(1)! + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +syn match sambaParameter /^[a-zA-Z \t]\+=/ contains=sambaKeyword +syn match sambaSection /^\s*\[[a-zA-Z0-9_\-.$ ]\+\]/ +syn match sambaMacro /%[SPugUGHvhmLMNpRdaITD]/ +syn match sambaMacro /%$([a-zA-Z0-9_]\+)/ +syn match sambaComment /^\s*[;#].*/ +syn match sambaContinue /\\$/ +syn keyword sambaBoolean true false yes no + +" Keywords for Samba 2.0.5a +syn keyword sambaKeyword contained account acl action add address admin aliases +syn keyword sambaKeyword contained allow alternate always announce anonymous +syn keyword sambaKeyword contained archive as auto available bind blocking +syn keyword sambaKeyword contained bmpx break browsable browse browseable ca +syn keyword sambaKeyword contained cache case casesignames cert certDir +syn keyword sambaKeyword contained certFile change char character chars chat +syn keyword sambaKeyword contained ciphers client clientcert code coding +syn keyword sambaKeyword contained command comment compatibility config +syn keyword sambaKeyword contained connections contention controller copy +syn keyword sambaKeyword contained create deadtime debug debuglevel default +syn keyword sambaKeyword contained delete deny descend dfree dir directory +syn keyword sambaKeyword contained disk dns domain domains dont dos dot drive +syn keyword sambaKeyword contained driver encrypt encrypted equiv exec fake +syn keyword sambaKeyword contained file files filetime filetimes filter follow +syn keyword sambaKeyword contained force fstype getwd group groups guest +syn keyword sambaKeyword contained hidden hide home homedir hosts include +syn keyword sambaKeyword contained interfaces interval invalid keepalive +syn keyword sambaKeyword contained kernel key ldap length level level2 limit +syn keyword sambaKeyword contained links list lm load local location lock +syn keyword sambaKeyword contained locking locks log logon logons logs lppause +syn keyword sambaKeyword contained lpq lpresume lprm machine magic mangle +syn keyword sambaKeyword contained mangled mangling map mask master max mem +syn keyword sambaKeyword contained message min mode modes mux name names +syn keyword sambaKeyword contained netbios nis notify nt null offset ok ole +syn keyword sambaKeyword contained only open oplock oplocks options order os +syn keyword sambaKeyword contained output packet page panic passwd password +syn keyword sambaKeyword contained passwords path permissions pipe port ports +syn keyword sambaKeyword contained postexec postscript prediction preexec +syn keyword sambaKeyword contained prefered preferred preload preserve print +syn keyword sambaKeyword contained printable printcap printer printers +syn keyword sambaKeyword contained printing program protocol proxy public +syn keyword sambaKeyword contained queuepause queueresume raw read readonly +syn keyword sambaKeyword contained realname remote require resign resolution +syn keyword sambaKeyword contained resolve restrict revalidate rhosts root +syn keyword sambaKeyword contained script security sensitive server servercert +syn keyword sambaKeyword contained service services set share shared short +syn keyword sambaKeyword contained size smb smbrun socket space ssl stack stat +syn keyword sambaKeyword contained status strict string strip suffix support +syn keyword sambaKeyword contained symlinks sync syslog system time timeout +syn keyword sambaKeyword contained times timestamp to trusted ttl unix update +syn keyword sambaKeyword contained use user username users valid version veto +syn keyword sambaKeyword contained volume wait wide wins workgroup writable +syn keyword sambaKeyword contained write writeable xmit + +" New keywords for Samba 2.0.6 +syn keyword sambaKeyword contained hook hires pid uid close rootpreexec + +" New keywords for Samba 2.0.7 +syn keyword sambaKeyword contained utmp wtmp hostname consolidate +syn keyword sambaKeyword contained inherit source environment + +" New keywords for Samba 2.2.0 +syn keyword sambaKeyword contained addprinter auth browsing deleteprinter +syn keyword sambaKeyword contained enhanced enumports filemode gid host jobs +syn keyword sambaKeyword contained lanman msdfs object os2 posix processes +syn keyword sambaKeyword contained scope separator shell show smbd template +syn keyword sambaKeyword contained total vfs winbind wizard + +" New keywords for Samba 2.2.1 +syn keyword sambaKeyword contained large obey pam readwrite restrictions +syn keyword sambaKeyword contained unreadable + +" New keywords for Samba 2.2.2 - 2.2.4 +syn keyword sambaKeyword contained acls allocate bytes count csc devmode +syn keyword sambaKeyword contained disable dn egd entropy enum extensions mmap +syn keyword sambaKeyword contained policy spin spoolss + +" Since Samba 3.0.2 +syn keyword sambaKeyword contained abort afs algorithmic backend +syn keyword sambaKeyword contained charset cups defer display +syn keyword sambaKeyword contained enable idmap kerberos lookups +syn keyword sambaKeyword contained methods modules nested NIS ntlm NTLMv2 +syn keyword sambaKeyword contained objects paranoid partners passdb +syn keyword sambaKeyword contained plaintext prefix primary private +syn keyword sambaKeyword contained profile quota realm replication +syn keyword sambaKeyword contained reported rid schannel sendfile sharing +syn keyword sambaKeyword contained shutdown signing special spnego +syn keyword sambaKeyword contained store unknown unwriteable + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link sambaParameter Normal +hi def link sambaKeyword Type +hi def link sambaSection Statement +hi def link sambaMacro PreProc +hi def link sambaComment Comment +hi def link sambaContinue Operator +hi def link sambaBoolean Constant + +let b:current_syntax = "samba" + +" vim: ts=8 + +endif diff --git a/syntax/sas.vim b/syntax/sas.vim new file mode 100644 index 0000000..9043fa3 --- /dev/null +++ b/syntax/sas.vim @@ -0,0 +1,269 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SAS +" Maintainer: Zhen-Huan Hu +" Original Maintainer: James Kidd +" Version: 3.0.0 +" Last Change: Aug 26, 2017 +" +" 2017 Mar 7 +" +" Upgrade version number to 3.0. Improvements include: +" - Improve sync speed +" - Largely enhance precision +" - Update keywords in the latest SAS (as of Mar 2017) +" - Add syntaxes for date/time constants +" - Add syntax for data lines +" - Add (back) syntax for TODO in comments +" +" 2017 Feb 9 +" +" Add syntax folding +" +" 2016 Oct 10 +" +" Add highlighting for functions +" +" 2016 Sep 14 +" +" Change the implementation of syntaxing +" macro function names so that macro parameters same +" as SAS keywords won't be highlighted +" (Thank Joug Raw for the suggestion) +" Add section highlighting: +" - Use /** and **/ to define a section +" - It functions the same as a comment but +" with different highlighting +" +" 2016 Jun 14 +" +" Major changes so upgrade version number to 2.0 +" Overhaul the entire script (again). Improvements include: +" - Higher precision +" - Faster synchronization +" - Separate color for control statements +" - Highlight hash and java objects +" - Highlight macro variables in double quoted strings +" - Update all syntaxes based on SAS 9.4 +" - Add complete SAS/GRAPH and SAS/STAT procedure syntaxes +" - Add Proc TEMPLATE and GTL syntaxes +" - Add complete DS2 syntaxes +" - Add basic IML syntaxes +" - Many other improvements and bug fixes +" Drop support for VIM version < 600 + +if version < 600 + syntax clear +elseif exists('b:current_syntax') + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case ignore + +" Basic SAS syntaxes +syn keyword sasOperator and eq ge gt in le lt ne not of or +syn keyword sasReserved _all_ _automatic_ _char_ _character_ _data_ _infile_ _last_ _n_ _name_ _null_ _num_ _numeric_ _temporary_ _user_ _webout_ +" Strings +syn region sasString start=+'+ skip=+''+ end=+'+ contains=@Spell +syn region sasString start=+"+ skip=+""+ end=+"+ contains=sasMacroVariable,@Spell +" Constants +syn match sasNumber /\v<\d+%(\.\d+)=%(>|e[\-+]=\d+>)/ display +syn match sasDateTime /\v(['"])\d{2}%(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\d{2}%(\d{2})=:\d{2}:\d{2}%(:\d{2})=%(am|pm)\1dt>/ display +syn match sasDateTime /\v(['"])\d{2}%(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\d{2}%(\d{2})=\1d>/ display +syn match sasDateTime /\v(['"])\d{2}:\d{2}%(:\d{2})=%(am|pm)\1t>/ display +" Comments +syn keyword sasTodo todo tbd fixme contained +syn region sasComment start='/\*' end='\*/' contains=sasTodo +syn region sasComment start='\v%(^|;)\s*\zs\%=\*' end=';'me=s-1 contains=sasTodo +syn region sasSectLbl matchgroup=sasSectLblEnds start='/\*\*\s*' end='\s*\*\*/' concealends +" Macros +syn match sasMacroVariable '\v\&+\w+%(\.\w+)=' display +syn match sasMacroReserved '\v\%%(abort|by|copy|display|do|else|end|global|goto|if|include|input|let|list|local|macro|mend|put|return|run|symdel|syscall|sysexec|syslput|sysrput|then|to|until|window|while)>' display +syn region sasMacroFunction matchgroup=sasMacroFunctionName start='\v\%\w+\ze\(' end=')'he=s-1 contains=@sasBasicSyntax,sasMacroFunction +syn region sasMacroFunction matchgroup=sasMacroFunctionName start='\v\%q=sysfunc\ze\(' end=')'he=s-1 contains=@sasBasicSyntax,sasMacroFunction,sasDataStepFunction +" Syntax cluster for basic SAS syntaxes +syn cluster sasBasicSyntax contains=sasOperator,sasReserved,sasNumber,sasDateTime,sasString,sasComment,sasMacroReserved,sasMacroFunction,sasMacroVariable,sasSectLbl + +" Formats +syn match sasFormat '\v\$\w+\.' display contained +syn match sasFormat '\v<\w+\.%(\d+>)=' display contained +syn region sasFormatContext start='.' end=';'me=s-1 contained contains=@sasBasicSyntax,sasFormat + +" Define global statements that can be accessed out of data step or procedures +syn keyword sasGlobalStatementKeyword catname dm endsas filename footnote footnote1 footnote2 footnote3 footnote4 footnote5 footnote6 footnote7 footnote8 footnote9 footnote10 missing libname lock ods options page quit resetline run sasfile skip sysecho title title1 title2 title3 title4 title5 title6 title7 title8 title9 title10 contained +syn keyword sasGlobalStatementODSKeyword chtml csvall docbook document escapechar epub epub2 epub3 exclude excel graphics html html3 html5 htmlcss imode listing markup output package path pcl pdf preferences phtml powerpoint printer proclabel proctitle ps results rtf select show tagsets trace usegopt verify wml contained +syn match sasGlobalStatement '\v%(^|;)\s*\zs\h\w*>' display transparent contains=sasGlobalStatementKeyword +syn match sasGlobalStatement '\v%(^|;)\s*\zsods>' display transparent contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty + +" Data step statements, 9.4 +syn keyword sasDataStepFunctionName abs addr addrlong airy allcomb allperm anyalnum anyalpha anycntrl anydigit anyfirst anygraph anylower anyname anyprint anypunct anyspace anyupper anyxdigit arcos arcosh arsin arsinh artanh atan atan2 attrc attrn band beta betainv blackclprc blackptprc blkshclprc blkshptprc blshift bnot bor brshift bxor byte cat catq cats catt catx cdf ceil ceilz cexist char choosec choosen cinv close cmiss cnonct coalesce coalescec collate comb compare compbl compfuzz compged complev compound compress constant convx convxp cos cosh cot count countc countw csc css cumipmt cumprinc curobs cv daccdb daccdbsl daccsl daccsyd dacctab dairy datdif date datejul datepart datetime day dclose dcreate depdb depdbsl depsl depsyd deptab dequote deviance dhms dif digamma dim dinfo divide dnum dopen doptname doptnum dosubl dread dropnote dsname dsncatlgd dur durp effrate envlen erf erfc euclid exist exp fact fappend fclose fcol fcopy fdelete fetch fetchobs fexist fget fileexist filename fileref finance find findc findw finfo finv fipname fipnamel fipstate first floor floorz fmtinfo fnonct fnote fopen foptname foptnum fpoint fpos fput fread frewind frlen fsep fuzz fwrite gaminv gamma garkhclprc garkhptprc gcd geodist geomean geomeanz getoption getvarc getvarn graycode harmean harmeanz hbound hms holiday holidayck holidaycount holidayname holidaynx holidayny holidaytest hour htmldecode htmlencode ibessel ifc ifn index indexc indexw input inputc inputn int intcindex intck intcycle intfit intfmt intget intindex intnx intrr intseas intshift inttest intz iorcmsg ipmt iqr irr jbessel juldate juldate7 kurtosis lag largest lbound lcm lcomb left length lengthc lengthm lengthn lexcomb lexcombi lexperk lexperm lfact lgamma libname libref log log1px log10 log2 logbeta logcdf logistic logpdf logsdf lowcase lperm lpnorm mad margrclprc margrptprc max md5 mdy mean median min minute missing mod modexist module modulec modulen modz month mopen mort msplint mvalid contained +syn keyword sasDataStepFunctionName n netpv nliteral nmiss nomrate normal notalnum notalpha notcntrl notdigit note notfirst notgraph notlower notname notprint notpunct notspace notupper notxdigit npv nvalid nwkdom open ordinal pathname pctl pdf peek peekc peekclong peeklong perm pmt point poisson ppmt probbeta probbnml probbnrm probchi probf probgam probhypr probit probmc probnegb probnorm probt propcase prxchange prxmatch prxparen prxparse prxposn ptrlongadd put putc putn pvp qtr quantile quote ranbin rancau rand ranexp rangam range rank rannor ranpoi rantbl rantri ranuni rename repeat resolve reverse rewind right rms round rounde roundz saving savings scan sdf sec second sha256 sha256hex sha256hmachex sign sin sinh skewness sleep smallest soapweb soapwebmeta soapwipservice soapwipsrs soapws soapwsmeta soundex spedis sqrt squantile std stderr stfips stname stnamel strip subpad substr substrn sum sumabs symexist symget symglobl symlocal sysexist sysget sysmsg sysparm sysprocessid sysprocessname sysprod sysrc system tan tanh time timepart timevalue tinv tnonct today translate transtrn tranwrd trigamma trim trimn trunc tso typeof tzoneid tzonename tzoneoff tzones2u tzoneu2s uniform upcase urldecode urlencode uss uuidgen var varfmt varinfmt varlabel varlen varname varnum varray varrayx vartype verify vformat vformatd vformatdx vformatn vformatnx vformatw vformatwx vformatx vinarray vinarrayx vinformat vinformatd vinformatdx vinformatn vinformatnx vinformatw vinformatwx vinformatx vlabel vlabelx vlength vlengthx vname vnamex vtype vtypex vvalue vvaluex week weekday whichc whichn wto year yieldp yrdif yyq zipcity zipcitydistance zipfips zipname zipnamel zipstate contained +syn keyword sasDataStepCallRoutineName allcomb allcombi allperm cats catt catx compcost execute graycode is8601_convert label lexcomb lexcombi lexperk lexperm logistic missing module poke pokelong prxchange prxdebug prxfree prxnext prxposn prxsubstr ranbin rancau rancomb ranexp rangam rannor ranperk ranperm ranpoi rantbl rantri ranuni scan set sleep softmax sortc sortn stdize streaminit symput symputx system tanh tso vname vnext wto contained +syn region sasDataStepFunctionContext start='(' end=')' contained contains=@sasBasicSyntax,sasDataStepFunction +syn region sasDataStepFunctionFormatContext start='(' end=')' contained contains=@sasBasicSyntax,sasDataStepFunction,sasFormat +syn match sasDataStepFunction '\v<\w+\ze\(' contained contains=sasDataStepFunctionName,sasDataStepCallRoutineName nextgroup=sasDataStepFunctionContext +syn match sasDataStepFunction '\v%(input|put)\ze\(' contained contains=sasDataStepFunctionName nextgroup=sasDataStepFunctionFormatContext +syn keyword sasDataStepHashMethodName add check clear definedata definedone definekey delete do_over equals find find_next find_prev first has_next has_prev last next output prev ref remove removedup replace replacedup reset_dup setcur sum sumdup contained +syn region sasDataStepHashMethodContext start='(' end=')' contained contains=@sasBasicSyntax,sasDataStepFunction +syn match sasDataStepHashMethod '\v\.\w+\ze\(' contained contains=sasDataStepHashMethodName nextgroup=sasDataStepHashMethodContext +syn keyword sasDataStepHashAttributeName item_size num_items contained +syn match sasDataStepHashAttribute '\v\.\w+>\ze\_[^(]' display contained contains=sasDataStepHashAttributeName +syn keyword sasDataStepControl continue do end go goto if leave link otherwise over return select to until when while contained +syn keyword sasDataStepControl else then contained nextgroup=sasDataStepStatementKeyword skipwhite skipnl skipempty +syn keyword sasDataStepHashOperator _new_ contained +syn keyword sasDataStepStatementKeyword abort array attrib by call cards cards4 datalines datalines4 dcl declare delete describe display drop error execute file format infile informat input keep label length lines lines4 list lostcard merge modify output put putlog redirect remove rename replace retain set stop update where window contained +syn keyword sasDataStepStatementHashKeyword hash hiter javaobj contained +syn match sasDataStepStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasDataStepStatementKeyword,sasGlobalStatementKeyword +syn match sasDataStepStatement '\v%(^|;)\s*\zs%(dcl|declare)>' display contained contains=sasDataStepStatementKeyword nextgroup=sasDataStepStatementHashKeyword skipwhite skipnl skipempty +syn match sasDataStepStatement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn match sasDataStepStatement '\v%(^|;)\s*\zs%(format|informat|input|put)>' display contained contains=sasDataStepStatementKeyword nextgroup=sasFormatContext skipwhite skipnl skipempty +syn match sasDataStepStatement '\v%(^|;)\s*\zs%(cards|datalines|lines)4=\s*;' display contained contains=sasDataStepStatementKeyword nextgroup=sasDataLine skipwhite skipnl skipempty +syn region sasDataLine start='^' end='^\s*;'me=s-1 contained +syn region sasDataStep matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsdata>' end='\v%(^|;)\s*%(run|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,@sasDataStepSyntax +syn cluster sasDataStepSyntax contains=sasDataStepFunction,sasDataStepHashOperator,sasDataStepHashAttribute,sasDataStepHashMethod,sasDataStepControl,sasDataStepStatement + +" Procedures, base SAS, 9.4 +syn keyword sasProcStatementKeyword abort age append array attrib audit block break by calid cdfplot change checkbox class classlev column compute contents copy create datarow dbencoding define delete deletefunc deletesubr delimiter device dialog dur endcomp exact exchange exclude explore fin fmtlib fontfile fontpath format formats freq function getnames guessingrows hbar hdfs histogram holidur holifin holistart holivar id idlabel informat inset invalue item key keylabel keyword label line link listfunc listsubr mapmiss mapreduce mean menu messages meta modify opentype outargs outdur outfin output outstart pageby partial picture pie pig plot ppplot printer probplot profile prompter qqplot radiobox ranks rbreak rbutton rebuild record remove rename repair report roptions save select selection separator source star start statistics struct submenu subroutine sum sumby table tables test text trantab truetype type1 types value var vbar ways weight where with write contained +syn match sasProcStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasProcStatementKeyword,sasGlobalStatementKeyword +syn match sasProcStatement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn match sasProcStatement '\v%(^|;)\s*\zs%(format|informat)>' display contained contains=sasProcStatementKeyword nextgroup=sasFormatContext skipwhite skipnl skipempty +syn region sasProc matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc%(\s+\h\w*)=>' end='\v%(^|;)\s*%(run|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDataStepFunction,sasProcStatement +syn region sasProc matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+%(catalog|chart|datasets|document|plot)>' end='\v%(^|;)\s*%(quit|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDataStepFunction,sasProcStatement + +" Procedures, SAS/GRAPH, 9.4 +syn keyword sasGraphProcStatementKeyword add area axis bar block bubble2 byline cc ccopy cdef cdelete chart cmap choro copy delete device dial donut exclude flow format fs goptions gout grid group hbar hbar3d hbullet hslider htrafficlight id igout label legend list modify move nobyline note pattern pie pie3d plot plot2 preview prism quit rename replay select scatter speedometer star surface symbol tc tcopy tdef tdelete template tile toggle treplay vbar vbar3d vtrafficlight vbullet vslider where contained +syn match sasGraphProcStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasGraphProcStatementKeyword,sasGlobalStatementKeyword +syn match sasGraphProcStatement '\v%(^|;)\s*\zsformat>' display contained contains=sasGraphProcStatementKeyword nextgroup=sasFormatContext skipwhite skipnl skipempty +syn region sasGraphProc matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+%(g3d|g3grid|ganno|gcontour|gdevice|geocode|gfont|ginside|goptions|gproject|greduce|gremove|mapimport)>' end='\v%(^|;)\s*%(run|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDataStepFunction,sasGraphProcStatement +syn region sasGraphProc matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+%(gareabar|gbarline|gchart|gkpi|gmap|gplot|gradar|greplay|gslide|gtile)>' end='\v%(^|;)\s*%(quit|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDataStepFunction,sasGraphProcStatement + +" Procedures, SAS/STAT, 14.1 +syn keyword sasAnalyticalProcStatementKeyword absorb add array assess baseline bayes beginnodata bivar bootstrap bounds by cdfplot cells class cluster code compute condition contrast control coordinates copy cosan cov covtest coxreg der design determ deviance direct directions domain effect effectplot effpart em endnodata equality estimate exact exactoptions factor factors fcs filter fitindex format freq fwdlink gender grid group grow hazardratio height hyperprior id impjoint inset insetgroup invar invlink ippplot lincon lineqs lismod lmtests location logistic loglin lpredplot lsmeans lsmestimate manova matings matrix mcmc mean means missmodel mnar model modelaverage modeleffects monotone mstruct mtest multreg name nlincon nloptions oddsratio onecorr onesamplefreq onesamplemeans onewayanova outfiles output paired pairedfreq pairedmeans parameters parent parms partial partition path pathdiagram pcov performance plot population poststrata power preddist predict predpplot priors process probmodel profile prune pvar ram random ratio reference refit refmodel renameparm repeated replicate repweights response restore restrict retain reweight ridge rmsstd roc roccontrast rules samplesize samplingunit seed size scale score selection show simtests simulate slice std stderr store strata structeq supplementary table tables test testclass testfreq testfunc testid time transform treatments trend twosamplefreq twosamplemeans towsamplesurvival twosamplewilcoxon uds units univar var variance varnames weight where with zeromodel contained +syn match sasAnalyticalProcStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasAnalyticalProcStatementKeyword,sasGlobalStatementKeyword +syn match sasAnalyticalProcStatement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn match sasAnalyticalProcStatement '\v%(^|;)\s*\zsformat>' display contained contains=sasAnalyticalProcStatementKeyword nextgroup=sasFormatContext skipwhite skipnl skipempty +syn region sasAnalyticalProc matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+%(aceclus|adaptivereg|bchoice|boxplot|calis|cancorr|candisc|cluster|corresp|discrim|distance|factor|fastclus|fmm|freq|gam|gampl|gee|genmod|glimmix|glmmod|glmpower|glmselect|hpcandisc|hpfmm|hpgenselect|hplmixed|hplogistic|hpmixed|hpnlmod|hppls|hpprincomp|hpquantselect|hpreg|hpsplit|iclifetest|icphreg|inbreed|irt|kde|krige2d|lattice|lifereg|lifetest|loess|logistic|mcmc|mds|mi|mianalyze|mixed|modeclus|multtest|nested|nlin|nlmixed|npar1way|orthoreg|phreg|plm|pls|power|princomp|prinqual|probit|quantlife|quantreg|quantselect|robustreg|rsreg|score|seqdesign|seqtest|sim2d|simnormal|spp|stdize|stdrate|stepdisc|surveyfreq|surveyimpute|surveylogistic|surveymeans|surveyphreg|surveyreg|surveyselect|tpspline|transreg|tree|ttest|varclus|varcomp|variogram)>' end='\v%(^|;)\s*%(run|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDataStepControl,sasDataStepFunction,sasAnalyticalProcStatement +syn region sasAnalyticalProc matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+%(anova|arima|catmod|factex|glm|model|optex|plan|reg)>' end='\v%(^|;)\s*%(quit|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDataStepControl,sasDataStepFunction,sasAnalyticalProcStatement + +" Procedures, ODS graphics, 9.4 +syn keyword sasODSGraphicsProcStatementKeyword band block bubble by colaxis compare dattrvar density dot dropline dynamic ellipse ellipseparm format fringe gradlegend hbar hbarbasic hbarparm hbox heatmap heatmapparm highlow histogram hline inset keylegend label lineparm loess matrix needle parent panelby pbspline plot polygon refline reg rowaxis scatter series spline step style styleattrs symbolchar symbolimage text vbar vbarbasic vbarparm vbox vector vline waterfall where xaxis x2axis yaxis y2axis yaxistable contained +syn match sasODSGraphicsProcStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasODSGraphicsProcStatementKeyword,sasGlobalStatementKeyword +syn match sasODSGraphicsProcStatement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn match sasODSGraphicsProcStatement '\v%(^|;)\s*\zsformat>' display contained contains=sasODSGraphicsProcStatementKeyword nextgroup=sasFormatContext skipwhite skipnl skipempty +syn region sasODSGraphicsProc matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+%(sgdesign|sgpanel|sgplot|sgrender|sgscatter)>' end='\v%(^|;)\s*%(run|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDataStepFunction,sasODSGraphicsProcStatement + +" Proc TEMPLATE, 9.4 +syn keyword sasProcTemplateClause as into +syn keyword sasProcTemplateStatementKeyword block break cellstyle class close column compute continue define delete delstream do done dynamic edit else end eval flush footer header import iterate link list mvar ndent next nmvar notes open path put putl putlog putq putstream putvars replace set source stop style test text text2 text3 translate trigger unblock unset xdent contained +syn keyword sasProcTemplateStatementComplexKeyword cellvalue column crosstabs event footer header statgraph style table tagset contained +syn keyword sasProcTemplateGTLStatementKeyword axislegend axistable bandplot barchart barchartparm begingraph beginpolygon beginpolyline bihistogram3dparm blockplot boxplot boxplotparm bubbleplot continuouslegend contourplotparm dendrogram discretelegend drawarrow drawimage drawline drawoval drawrectangle drawtext dropline ellipse ellipseparm endgraph endinnermargin endlayout endpolygon endpolyline endsidebar entry entryfootnote entrytitle fringeplot heatmap heatmapparm highlowplot histogram histogramparm innermargin layout legenditem legendtextitems linechart lineparm loessplot mergedlegend modelband needleplot pbsplineplot polygonplot referenceline regressionplot scatterplot seriesplot sidebar stepplot surfaceplotparm symbolchar symbolimage textplot vectorplot waterfallchart contained +syn keyword sasProcTemplateGTLComplexKeyword datalattice datapanel globallegend gridded lattice overlay overlayequated overlay3d region contained +syn match sasProcTemplateStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasProcTemplateStatementKeyword,sasProcTemplateGTLStatementKeyword,sasGlobalStatementKeyword +syn match sasProcTemplateStatement '\v%(^|;)\s*\zsdefine>' display contained contains=sasProcTemplateStatementKeyword nextgroup=sasProcTemplateStatementComplexKeyword skipwhite skipnl skipempty +syn match sasProcTemplateStatement '\v%(^|;)\s*\zslayout>' display contained contains=sasProcTemplateGTLStatementKeyword nextgroup=sasProcTemplateGTLComplexKeyword skipwhite skipnl skipempty +syn match sasProcTemplateStatement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn region sasProcTemplate matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+template>' end='\v%(^|;)\s*%(run|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasProcTemplateClause,sasProcTemplateStatement + +" Proc SQL, 9.4 +syn keyword sasProcSQLFunctionName avg count css cv freq max mean median min n nmiss prt range std stderr sum sumwgt t uss var contained +syn region sasProcSQLFunctionContext start='(' end=')' contained contains=@sasBasicSyntax,sasProcSQLFunction +syn match sasProcSQLFunction '\v<\w+\ze\(' contained contains=sasProcSQLFunctionName,sasDataStepFunctionName nextgroup=sasProcSQLFunctionContext +syn keyword sasProcSQLClause add asc between by calculated cascade case check connection constraint cross desc distinct drop else end escape except exists foreign from full group having in inner intersect into is join key left libname like modify natural newline notrim null on order outer primary references restrict right separated set then to trimmed union unique user using values when where contained +syn keyword sasProcSQLClause as contained nextgroup=sasProcSQLStatementKeyword skipwhite skipnl skipempty +syn keyword sasProcSQLStatementKeyword connect delete disconnect execute insert reset select update validate contained +syn keyword sasProcSQLStatementComplexKeyword alter create describe drop contained nextgroup=sasProcSQLStatementNextKeyword skipwhite skipnl skipempty +syn keyword sasProcSQLStatementNextKeyword index table view contained +syn match sasProcSQLStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasProcSQLStatementKeyword,sasGlobalStatementKeyword +syn match sasProcSQLStatement '\v%(^|;)\s*\zs%(alter|create|describe|drop)>' display contained contains=sasProcSQLStatementComplexKeyword nextgroup=sasProcSQLStatementNextKeyword skipwhite skipnl skipempty +syn match sasProcSQLStatement '\v%(^|;)\s*\zsvalidate>' display contained contains=sasProcSQLStatementKeyword nextgroup=sasProcSQLStatementKeyword,sasProcSQLStatementComplexKeyword skipwhite skipnl skipempty +syn match sasProcSQLStatement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn region sasProcSQL matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+sql>' end='\v%(^|;)\s*%(quit|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasProcSQLFunction,sasProcSQLClause,sasProcSQLStatement + +" SAS/DS2, 9.4 +syn keyword sasDS2FunctionName abs anyalnum anyalpha anycntrl anydigit anyfirst anygraph anylower anyname anyprint anypunct anyspace anyupper anyxdigit arcos arcosh arsin arsinh artanh atan atan2 band beta betainv blackclprc blackptprc blkshclprc blkshptprc blshift bnot bor brshift bxor byte cat cats catt catx ceil ceilz choosec choosen cmp cmpt coalesce coalescec comb compare compbl compfuzz compound compress constant convx convxp cos cosh count countc countw css cumipmt cumprinc cv datdif date datejul datepart datetime day dequote deviance dhms dif digamma dim divide dur durp effrate erf erfc exp fact find findc findw floor floorz fmtinfo fuzz gaminv gamma garkhclprc garkhptprc gcd geodist geomean geomeanz harmean harmeanz hbound hms holiday hour index indexc indexw inputc inputn int intcindex intck intcycle intdt intfit intget intindex intnest intnx intrr intseas intshift inttest intts intz ipmt iqr irr juldate juldate7 kcount kstrcat kstrip kupdate kupdates kurtosis lag largest lbound lcm left length lengthc lengthm lengthn lgamma log logbeta log10 log1px log2 lowcase mad margrclprc margrptprc max md5 mdy mean median min minute missing mod modz month mort n ndims netpv nmiss nomrate notalnum notalpha notcntrl notdigit notfirst notgraph notlower notname notprint notpunct notspace notupper notxdigit npv null nwkdom ordinal pctl perm pmt poisson power ppmt probbeta probbnml probbnrm probchi probdf probf probgam probhypr probit probmc probmed probnegb probnorm probt prxchange prxmatch prxparse prxposn put pvp qtr quote ranbin rancau rand ranexp rangam range rank rannor ranpoi rantbl rantri ranuni repeat reverse right rms round rounde roundz savings scan sec second sha256hex sha256hmachex sign sin sinh skewness sleep smallest sqlexec sqrt std stderr streaminit strip substr substrn sum sumabs tan tanh time timepart timevalue tinv to_date to_double to_time to_timestamp today translate transtrn tranwrd trigamma trim trimn trunc uniform upcase uss uuidgen var verify vformat vinarray vinformat vlabel vlength vname vtype week weekday whichc whichn year yieldp yrdif yyq contained +syn region sasDS2FunctionContext start='(' end=')' contained contains=@sasBasicSyntax,sasDS2Function +syn match sasDS2Function '\v<\w+\ze\(' contained contains=sasDS2FunctionName nextgroup=sasDS2FunctionContext +syn keyword sasDS2Control continue data dcl declare do drop else end enddata endpackage endthread from go goto if leave method otherwise package point return select then thread to until when while contained +syn keyword sasDS2StatementKeyword array by forward keep merge output put rename retain set stop vararray varlist contained +syn keyword sasDS2StatementComplexKeyword package thread contained +syn match sasDS2Statement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasDS2StatementKeyword,sasGlobalStatementKeyword +syn match sasDS2Statement '\v%(^|;)\s*\zs%(dcl|declare|drop)>' display contained contains=sasDS2StatementKeyword nextgroup=sasDS2StatementComplexKeyword skipwhite skipnl skipempty +syn match sasDS2Statement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn region sasDS2 matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+ds2>' end='\v%(^|;)\s*%(quit|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasDS2Function,sasDS2Control,sasDS2Statement + +" SAS/IML, 14.1 +syn keyword sasIMLFunctionName abs all allcomb allperm any apply armasim bin blankstr block branks bspline btran byte char choose col colvec concat contents convexit corr corr2cov countmiss countn countunique cov cov2corr covlag cshape cusum cuprod cv cvexhull datasets design designf det diag dif dimension distance do duration echelon eigval eigvec element exp expmatrix expandgrid fft forward froot full gasetup geomean ginv hadamard half hankel harmean hdir hermite homogen i ifft insert int inv invupdt isempty isskipped j jroot kurtosis lag length loc log logabsdet mad magic mahalanobis max mean median min mod moduleic modulein name ncol ndx2sub nleng norm normal nrow num opscal orpol parentname palette polyroot prod product pv quartile rancomb randdirichlet randfun randmultinomial randmvt randnormal randwishart ranperk ranperm range rank ranktie rates ratio remove repeat root row rowcat rowcatc rowvec rsubstr sample setdif shape shapecol skewness solve sparse splinev spot sqrsym sqrt sqrvech ssq standard std storage sub2ndx substr sum sweep symsqr t toeplitz trace trisolv type uniform union unique uniqueby value var vecdiag vech xmult xsect yield contained +syn keyword sasIMLCallRoutineName appcort armacov armalik bar box change comport delete eigen execute exportdatasettor exportmatrixtor farmacov farmafit farmalik farmasim fdif gaend gagetmem gagetval gainit gareeval garegen gasetcro gasetmut gasetobj gasetsel gblkvp gblkvpd gclose gdelete gdraw gdrawl geneig ggrid ginclude gopen gpie gpiexy gpoint gpoly gport gportpop gportstk gscale gscript gset gshow gsorth gstart gstop gstrlen gtext gvtext gwindow gxaxis gyaxis heatmapcont heatmapdisc histogram importdatasetfromr importmatrixfromr ipf itsolver kalcvf kalcvs kaldff kaldfs lav lcp lms lp lpsolve lts lupdt marg maxqform mcd milpsolve modulei mve nlpcg nlpdd nlpfdd nlpfea nlphqn nlplm nlpnms nlpnra nlpnrr nlpqn nlpqua nlptr ode odsgraph ortvec pgraf push qntl qr quad queue randgen randseed rdodt rupdt rename rupdt rzlind scatter seq seqscale seqshift seqscale seqshift series solvelin sort sortndx sound spline splinec svd tabulate tpspline tpsplnev tsbaysea tsdecomp tsmlocar tsmlomar tsmulmar tspears tspred tsroot tstvcar tsunimar valset varmacov varmalik varmasim vnormal vtsroot wavft wavget wavift wavprint wavthrsh contained +syn region sasIMLFunctionContext start='(' end=')' contained contains=@sasBasicSyntax,sasIMLFunction +syn match sasIMLFunction '\v<\w+\ze\(' contained contains=sasIMLFunctionName,sasDataStepFunction nextgroup=sasIMLFunctionContext +syn keyword sasIMLControl abort by do else end finish goto if link pause quit resume return run start stop then to until while contained +syn keyword sasIMLStatementKeyword append call close closefile create delete display edit file find force free index infile input list load mattrib print purge read remove replace reset save setin setout show sort store summary use window contained +syn match sasIMLStatement '\v%(^|;)\s*\zs\h\w*>' display contained contains=sasIMLStatementKeyword,sasGlobalStatementKeyword +syn match sasIMLStatement '\v%(^|;)\s*\zsods>' display contained contains=sasGlobalStatementKeyword nextgroup=sasGlobalStatementODSKeyword skipwhite skipnl skipempty +syn region sasIML matchgroup=sasSectionKeyword start='\v%(^|;)\s*\zsproc\s+iml>' end='\v%(^|;)\s*%(quit|data|proc|endsas)>'me=s-1 fold contains=@sasBasicSyntax,sasIMLFunction,sasIMLControl,sasIMLStatement + +" Macro definition +syn region sasMacro start='\v\%macro>' end='\v\%mend>' fold keepend contains=@sasBasicSyntax,@sasDataStepSyntax,sasDataStep,sasProc,sasODSGraphicsProc,sasGraphProc,sasAnalyticalProc,sasProcTemplate,sasProcSQL,sasDS2,sasIML + +" Define default highlighting +hi def link sasComment Comment +hi def link sasTodo Delimiter +hi def link sasSectLbl Title +hi def link sasSectLblEnds Comment +hi def link sasNumber Number +hi def link sasDateTime Constant +hi def link sasString String +hi def link sasDataStepControl Keyword +hi def link sasProcTemplateClause Keyword +hi def link sasProcSQLClause Keyword +hi def link sasDS2Control Keyword +hi def link sasIMLControl Keyword +hi def link sasOperator Operator +hi def link sasGlobalStatementKeyword Statement +hi def link sasGlobalStatementODSKeyword Statement +hi def link sasSectionKeyword Statement +hi def link sasDataStepFunctionName Function +hi def link sasDataStepCallRoutineName Function +hi def link sasDataStepStatementKeyword Statement +hi def link sasDataStepStatementHashKeyword Statement +hi def link sasDataStepHashOperator Operator +hi def link sasDataStepHashMethodName Function +hi def link sasDataStepHashAttributeName Identifier +hi def link sasProcStatementKeyword Statement +hi def link sasODSGraphicsProcStatementKeyword Statement +hi def link sasGraphProcStatementKeyword Statement +hi def link sasAnalyticalProcStatementKeyword Statement +hi def link sasProcTemplateStatementKeyword Statement +hi def link sasProcTemplateStatementComplexKeyword Statement +hi def link sasProcTemplateGTLStatementKeyword Statement +hi def link sasProcTemplateGTLComplexKeyword Statement +hi def link sasProcSQLFunctionName Function +hi def link sasProcSQLStatementKeyword Statement +hi def link sasProcSQLStatementComplexKeyword Statement +hi def link sasProcSQLStatementNextKeyword Statement +hi def link sasDS2FunctionName Function +hi def link sasDS2StatementKeyword Statement +hi def link sasIMLFunctionName Function +hi def link sasIMLCallRoutineName Function +hi def link sasIMLStatementKeyword Statement +hi def link sasMacroReserved PreProc +hi def link sasMacroVariable Define +hi def link sasMacroFunctionName Define +hi def link sasDataLine SpecialChar +hi def link sasFormat SpecialChar +hi def link sasReserved Special + +" Syncronize from beginning to keep large blocks from losing +" syntax coloring while moving through code. +syn sync fromstart + +let b:current_syntax = "sas" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/sass.vim b/syntax/sass.vim new file mode 100644 index 0000000..edfd0a0 --- /dev/null +++ b/syntax/sass.vim @@ -0,0 +1,110 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Sass +" Maintainer: Tim Pope +" Filenames: *.sass +" Last Change: 2016 Aug 29 + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/css.vim + +syn case ignore + +syn cluster sassCssProperties contains=cssFontProp,cssFontDescriptorProp,cssColorProp,cssTextProp,cssBoxProp,cssGeneratedContentProp,cssPagingProp,cssUIProp,cssRenderProp,cssAuralProp,cssTableProp +syn cluster sassCssAttributes contains=css.*Attr,sassEndOfLineComment,scssComment,cssValue.*,cssColor,cssURL,sassDefault,cssImportant,cssError,cssStringQ,cssStringQQ,cssFunction,cssUnicodeEscape,cssRenderProp + +syn region sassDefinition matchgroup=cssBraces start="{" end="}" contains=TOP + +syn match sassProperty "\%([{};]\s*\|^\)\@<=\%([[:alnum:]-]\|#{[^{}]*}\)\+\s*:" contains=css.*Prop skipwhite nextgroup=sassCssAttribute contained containedin=sassDefinition +syn match sassProperty "^\s*\zs\s\%(\%([[:alnum:]-]\|#{[^{}]*}\)\+\s*:\|:[[:alnum:]-]\+\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=sassCssAttribute +syn match sassProperty "^\s*\zs\s\%(:\=[[:alnum:]-]\+\s*=\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=sassCssAttribute +syn match sassCssAttribute +\%("\%([^"]\|\\"\)*"\|'\%([^']\|\\'\)*'\|#{[^{}]*}\|[^{};]\)*+ contained contains=@sassCssAttributes,sassVariable,sassFunction,sassInterpolation +syn match sassDefault "!default\>" contained +syn match sassVariable "!\%(important\>\|default\>\)\@![[:alnum:]_-]\+" +syn match sassVariable "$[[:alnum:]_-]\+" +syn match sassVariableAssignment "\%([!$][[:alnum:]_-]\+\s*\)\@<=\%(||\)\==" nextgroup=sassCssAttribute skipwhite +syn match sassVariableAssignment "\%([!$][[:alnum:]_-]\+\s*\)\@<=:" nextgroup=sassCssAttribute skipwhite + +syn match sassFunction "\<\%(rgb\|rgba\|red\|green\|blue\|mix\)\>(\@=" contained +syn match sassFunction "\<\%(hsl\|hsla\|hue\|saturation\|lightness\|adjust-hue\|lighten\|darken\|saturate\|desaturate\|grayscale\|complement\)\>(\@=" contained +syn match sassFunction "\<\%(alpha\|opacity\|rgba\|opacify\|fade-in\|transparentize\|fade-out\)\>(\@=" contained +syn match sassFunction "\<\%(unquote\|quote\)\>(\@=" contained +syn match sassFunction "\<\%(percentage\|round\|ceil\|floor\|abs\)\>(\@=" contained +syn match sassFunction "\<\%(type-of\|unit\|unitless\|comparable\)\>(\@=" contained + +syn region sassInterpolation matchgroup=sassInterpolationDelimiter start="#{" end="}" contains=@sassCssAttributes,sassVariable,sassFunction containedin=cssStringQ,cssStringQQ,cssPseudoClass,sassProperty + +syn match sassMixinName "[[:alnum:]_-]\+" contained nextgroup=sassCssAttribute +syn match sassMixin "^=" nextgroup=sassMixinName skipwhite +syn match sassMixin "\%([{};]\s*\|^\s*\)\@<=@mixin" nextgroup=sassMixinName skipwhite +syn match sassMixing "^\s\+\zs+" nextgroup=sassMixinName +syn match sassMixing "\%([{};]\s*\|^\s*\)\@<=@include" nextgroup=sassMixinName skipwhite +syn match sassExtend "\%([{};]\s*\|^\s*\)\@<=@extend" +syn match sassPlaceholder "\%([{};]\s*\|^\s*\)\@<=%" nextgroup=sassMixinName skipwhite + +syn match sassFunctionName "[[:alnum:]_-]\+" contained nextgroup=sassCssAttribute +syn match sassFunctionDecl "\%([{};]\s*\|^\s*\)\@<=@function" nextgroup=sassFunctionName skipwhite +syn match sassReturn "\%([{};]\s*\|^\s*\)\@<=@return" + +syn match sassEscape "^\s*\zs\\" +syn match sassIdChar "#[[:alnum:]_-]\@=" nextgroup=sassId +syn match sassId "[[:alnum:]_-]\+" contained +syn match sassClassChar "\.[[:alnum:]_-]\@=" nextgroup=sassClass +syn match sassClass "[[:alnum:]_-]\+" contained +syn match sassAmpersand "&" + +" TODO: Attribute namespaces +" TODO: Arithmetic (including strings and concatenation) + +syn region sassMediaQuery matchgroup=sassMedia start="@media" end="[{};]\@=\|$" contains=sassMediaOperators +syn keyword sassMediaOperators and not only contained +syn region sassCharset start="@charset" end=";\|$" contains=scssComment,cssStringQ,cssStringQQ,cssURL,cssUnicodeEscape,cssMediaType +syn region sassInclude start="@import" end=";\|$" contains=scssComment,cssStringQ,cssStringQQ,cssURL,cssUnicodeEscape,cssMediaType +syn region sassDebugLine end=";\|$" matchgroup=sassDebug start="@debug\>" contains=@sassCssAttributes,sassVariable,sassFunction +syn region sassWarnLine end=";\|$" matchgroup=sassWarn start="@warn\>" contains=@sassCssAttributes,sassVariable,sassFunction +syn region sassControlLine matchgroup=sassControl start="@\%(if\|else\%(\s\+if\)\=\|while\|for\|each\)\>" end="[{};]\@=\|$" contains=sassFor,@sassCssAttributes,sassVariable,sassFunction +syn keyword sassFor from to through in contained + +syn keyword sassTodo FIXME NOTE TODO OPTIMIZE XXX contained +syn region sassComment start="^\z(\s*\)//" end="^\%(\z1 \)\@!" contains=sassTodo,@Spell +syn region sassCssComment start="^\z(\s*\)/\*" end="^\%(\z1 \)\@!" contains=sassTodo,@Spell +syn match sassEndOfLineComment "//.*" contains=sassComment,sassTodo,@Spell + +hi def link sassEndOfLineComment sassComment +hi def link sassCssComment sassComment +hi def link sassComment Comment +hi def link sassDefault cssImportant +hi def link sassVariable Identifier +hi def link sassFunction Function +hi def link sassMixing PreProc +hi def link sassMixin PreProc +hi def link sassPlaceholder PreProc +hi def link sassExtend PreProc +hi def link sassFunctionDecl PreProc +hi def link sassReturn PreProc +hi def link sassTodo Todo +hi def link sassCharset PreProc +hi def link sassMedia PreProc +hi def link sassMediaOperators PreProc +hi def link sassInclude Include +hi def link sassDebug sassControl +hi def link sassWarn sassControl +hi def link sassControl PreProc +hi def link sassFor PreProc +hi def link sassEscape Special +hi def link sassIdChar Special +hi def link sassClassChar Special +hi def link sassInterpolationDelimiter Delimiter +hi def link sassAmpersand Character +hi def link sassId Identifier +hi def link sassClass Type + +let b:current_syntax = "sass" + +" vim:set sw=2: + +endif diff --git a/syntax/sather.vim b/syntax/sather.vim new file mode 100644 index 0000000..cccd786 --- /dev/null +++ b/syntax/sather.vim @@ -0,0 +1,96 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Sather/pSather +" Maintainer: Claudio Fleiner +" URL: http://www.fleiner.com/vim/syntax/sather.vim +" Last Change: 2003 May 11 + +" Sather is a OO-language developped at the International Computer Science +" Institute (ICSI) in Berkeley, CA. pSather is a parallel extension to Sather. +" Homepage: http://www.icsi.berkeley.edu/~sather +" Sather files use .sa as suffix + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" keyword definitions +syn keyword satherExternal extern +syn keyword satherBranch break continue +syn keyword satherLabel when then +syn keyword satherConditional if else elsif end case typecase assert with +syn match satherConditional "near$" +syn match satherConditional "far$" +syn match satherConditional "near *[^(]"he=e-1 +syn match satherConditional "far *[^(]"he=e-1 +syn keyword satherSynchronize lock guard sync +syn keyword satherRepeat loop parloop do +syn match satherRepeat "while!" +syn match satherRepeat "break!" +syn match satherRepeat "until!" +syn keyword satherBoolValue true false +syn keyword satherValue self here cluster +syn keyword satherOperator new "== != & ^ | && || +syn keyword satherOperator and or not +syn match satherOperator "[#!]" +syn match satherOperator ":-" +syn keyword satherType void attr where +syn match satherType "near *("he=e-1 +syn match satherType "far *("he=e-1 +syn keyword satherStatement return +syn keyword satherStorageClass static const +syn keyword satherExceptions try raise catch +syn keyword satherMethodDecl is pre post +syn keyword satherClassDecl abstract value class include +syn keyword satherScopeDecl public private readonly + + +syn match satherSpecial contained "\\\d\d\d\|\\." +syn region satherString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=satherSpecial +syn match satherCharacter "'[^\\]'" +syn match satherSpecialCharacter "'\\.'" +syn match satherNumber "-\=\<\d\+L\=\>\|0[xX][0-9a-fA-F]\+\>" +syn match satherCommentSkip contained "^\s*\*\($\|\s\+\)" +syn region satherComment2String contained start=+"+ skip=+\\\\\|\\"+ end=+$\|"+ contains=satherSpecial +syn match satherComment "--.*" contains=satherComment2String,satherCharacter,satherNumber + + +syn sync ccomment satherComment + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link satherBranch satherStatement +hi def link satherLabel satherStatement +hi def link satherConditional satherStatement +hi def link satherSynchronize satherStatement +hi def link satherRepeat satherStatement +hi def link satherExceptions satherStatement +hi def link satherStorageClass satherDeclarative +hi def link satherMethodDecl satherDeclarative +hi def link satherClassDecl satherDeclarative +hi def link satherScopeDecl satherDeclarative +hi def link satherBoolValue satherValue +hi def link satherSpecial satherValue +hi def link satherString satherValue +hi def link satherCharacter satherValue +hi def link satherSpecialCharacter satherValue +hi def link satherNumber satherValue +hi def link satherStatement Statement +hi def link satherOperator Statement +hi def link satherComment Comment +hi def link satherType Type +hi def link satherValue String +hi def link satherString String +hi def link satherSpecial String +hi def link satherCharacter String +hi def link satherDeclarative Type +hi def link satherExternal PreCondit + +let b:current_syntax = "sather" + +" vim: ts=8 + +endif diff --git a/syntax/sbt.vim b/syntax/sbt.vim index e82e64d..29f8a3d 100644 --- a/syntax/sbt.vim +++ b/syntax/sbt.vim @@ -1,3 +1,39 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sbt +" Maintainer: Steven Dobay +" Last Change: 2017.04.30 + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/scala.vim + +syn region sbtString start="\"[^"]" skip="\\\"" end="\"" contains=sbtStringEscape +syn match sbtStringEscape "\\u[0-9a-fA-F]\{4}" contained +syn match sbtStringEscape "\\[nrfvb\\\"]" contained + +syn match sbtIdentitifer "^\S\+\ze\s*\(:=\|++=\|+=\|<<=\|<+=\)" +syn match sbtBeginningSeq "^[Ss]eq\>" + +syn match sbtSpecial "\(:=\|++=\|+=\|<<=\|<+=\)" + +syn match sbtLineComment "//.*" +syn region sbtComment start="/\*" end="\*/" +syn region sbtDocComment start="/\*\*" end="\*/" keepend + +hi link sbtString String +hi link sbtIdentitifer Keyword +hi link sbtBeginningSeq Keyword +hi link sbtSpecial Special +hi link sbtComment Comment +hi link sbtLineComment Comment +hi link sbtDocComment Comment + + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'sbt') == -1 " Vim syntax file diff --git a/syntax/scala.vim b/syntax/scala.vim index 5e12b99..0f41dbc 100644 --- a/syntax/scala.vim +++ b/syntax/scala.vim @@ -1,3 +1,239 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Scala +" Maintainer: Derek Wyatt +" URL: https://github.com/derekwyatt/vim-scala +" License: Same as Vim +" Last Change: 20 May 2016 +" ---------------------------------------------------------------------------- + +if !exists('main_syntax') + " quit when a syntax file was already loaded + if exists("b:current_syntax") + finish + endif + let main_syntax = 'scala' +endif + +scriptencoding utf-8 + +let b:current_syntax = "scala" + +" Allows for embedding, see #59; main_syntax convention instead? Refactor TOP +" +" The @Spell here is a weird hack, it means *exclude* if the first group is +" TOP. Otherwise we get spelling errors highlighted on code elements that +" match scalaBlock, even with `syn spell notoplevel`. +function! s:ContainedGroup() + try + silent syn list @scala + return '@scala,@NoSpell' + catch /E392/ + return 'TOP,@Spell' + endtry +endfunction + +unlet! b:current_syntax + +syn case match +syn sync minlines=200 maxlines=1000 + +syn keyword scalaKeyword catch do else final finally for forSome if +syn keyword scalaKeyword match return throw try while yield macro +syn keyword scalaKeyword class trait object extends with nextgroup=scalaInstanceDeclaration skipwhite +syn keyword scalaKeyword case nextgroup=scalaKeyword,scalaCaseFollowing skipwhite +syn keyword scalaKeyword val nextgroup=scalaNameDefinition,scalaQuasiQuotes skipwhite +syn keyword scalaKeyword def var nextgroup=scalaNameDefinition skipwhite +hi link scalaKeyword Keyword + +exe 'syn region scalaBlock start=/{/ end=/}/ contains=' . s:ContainedGroup() . ' fold' + +syn keyword scalaAkkaSpecialWord when goto using startWith initialize onTransition stay become unbecome +hi link scalaAkkaSpecialWord PreProc + +syn keyword scalatestSpecialWord shouldBe +syn match scalatestShouldDSLA /^\s\+\zsit should/ +syn match scalatestShouldDSLB /\/ +hi link scalatestSpecialWord PreProc +hi link scalatestShouldDSLA PreProc +hi link scalatestShouldDSLB PreProc + +syn match scalaSymbol /'[_A-Za-z0-9$]\+/ +hi link scalaSymbol Number + +syn match scalaChar /'.'/ +syn match scalaChar /'\\[\\"'ntbrf]'/ contains=scalaEscapedChar +syn match scalaChar /'\\u[A-Fa-f0-9]\{4}'/ contains=scalaUnicodeChar +syn match scalaEscapedChar /\\[\\"'ntbrf]/ +syn match scalaUnicodeChar /\\u[A-Fa-f0-9]\{4}/ +hi link scalaChar Character +hi link scalaEscapedChar Function +hi link scalaUnicodeChar Special + +syn match scalaOperator "||" +syn match scalaOperator "&&" +syn match scalaOperator "|" +syn match scalaOperator "&" +hi link scalaOperator Special + +syn match scalaNameDefinition /\<[_A-Za-z0-9$]\+\>/ contained nextgroup=scalaPostNameDefinition,scalaVariableDeclarationList +syn match scalaNameDefinition /`[^`]\+`/ contained nextgroup=scalaPostNameDefinition +syn match scalaVariableDeclarationList /\s*,\s*/ contained nextgroup=scalaNameDefinition +syn match scalaPostNameDefinition /\_s*:\_s*/ contained nextgroup=scalaTypeDeclaration +hi link scalaNameDefinition Function + +syn match scalaInstanceDeclaration /\<[_\.A-Za-z0-9$]\+\>/ contained nextgroup=scalaInstanceHash +syn match scalaInstanceDeclaration /`[^`]\+`/ contained +syn match scalaInstanceHash /#/ contained nextgroup=scalaInstanceDeclaration +hi link scalaInstanceDeclaration Special +hi link scalaInstanceHash Type + +syn match scalaUnimplemented /???/ +hi link scalaUnimplemented ERROR + +syn match scalaCapitalWord /\<[A-Z][A-Za-z0-9$]*\>/ +hi link scalaCapitalWord Special + +" Handle type declarations specially +syn region scalaTypeStatement matchgroup=Keyword start=/\\)\ze/ contained nextgroup=scalaTypeTypeDeclaration contains=scalaTypeTypeExtension skipwhite +syn match scalaTypeTypeDeclaration /\<[_\.A-Za-z0-9$]\+\>/ contained nextgroup=scalaTypeTypeExtension,scalaTypeTypeEquals skipwhite +syn match scalaTypeTypeEquals /=\ze[^>]/ contained nextgroup=scalaTypeTypePostDeclaration skipwhite +syn match scalaTypeTypeExtension /)\?\_s*\zs\%(⇒\|=>\|<:\|:>\|=:=\|::\|#\)/ contained nextgroup=scalaTypeTypeDeclaration skipwhite +syn match scalaTypeTypePostDeclaration /\<[_\.A-Za-z0-9$]\+\>/ contained nextgroup=scalaTypeTypePostExtension skipwhite +syn match scalaTypeTypePostExtension /\%(⇒\|=>\|<:\|:>\|=:=\|::\)/ contained nextgroup=scalaTypeTypePostDeclaration skipwhite +hi link scalaTypeTypeDeclaration Type +hi link scalaTypeTypeExtension Keyword +hi link scalaTypeTypePostDeclaration Special +hi link scalaTypeTypePostExtension Keyword + +syn match scalaTypeDeclaration /(/ contained nextgroup=scalaTypeExtension contains=scalaRoundBrackets skipwhite +syn match scalaTypeDeclaration /\%(⇒\|=>\)\ze/ contained nextgroup=scalaTypeDeclaration contains=scalaTypeExtension skipwhite +syn match scalaTypeDeclaration /\<[_\.A-Za-z0-9$]\+\>/ contained nextgroup=scalaTypeExtension skipwhite +syn match scalaTypeExtension /)\?\_s*\zs\%(⇒\|=>\|<:\|:>\|=:=\|::\|#\)/ contained nextgroup=scalaTypeDeclaration skipwhite +hi link scalaTypeDeclaration Type +hi link scalaTypeExtension Keyword +hi link scalaTypePostExtension Keyword + +syn match scalaTypeAnnotation /\%([_a-zA-Z0-9$\s]:\_s*\)\ze[_=(\.A-Za-z0-9$]\+/ skipwhite nextgroup=scalaTypeDeclaration contains=scalaRoundBrackets +syn match scalaTypeAnnotation /)\_s*:\_s*\ze[_=(\.A-Za-z0-9$]\+/ skipwhite nextgroup=scalaTypeDeclaration +hi link scalaTypeAnnotation Normal + +syn match scalaCaseFollowing /\<[_\.A-Za-z0-9$]\+\>/ contained +syn match scalaCaseFollowing /`[^`]\+`/ contained +hi link scalaCaseFollowing Special + +syn keyword scalaKeywordModifier abstract override final lazy implicit implicitly private protected sealed null require super +hi link scalaKeywordModifier Function + +syn keyword scalaSpecial this true false ne eq +syn keyword scalaSpecial new nextgroup=scalaInstanceDeclaration skipwhite +syn match scalaSpecial "\%(=>\|⇒\|<-\|â†\|->\|→\)" +syn match scalaSpecial /`[^`]\+`/ " Backtick literals +hi link scalaSpecial PreProc + +syn keyword scalaExternal package import +hi link scalaExternal Include + +syn match scalaStringEmbeddedQuote /\\"/ contained +syn region scalaString start=/"/ end=/"/ contains=scalaStringEmbeddedQuote,scalaEscapedChar,scalaUnicodeChar +hi link scalaString String +hi link scalaStringEmbeddedQuote String + +syn region scalaIString matchgroup=scalaInterpolationBrackets start=/\<[a-zA-Z][a-zA-Z0-9_]*"/ skip=/\\"/ end=/"/ contains=scalaInterpolation,scalaInterpolationB,scalaEscapedChar,scalaUnicodeChar +syn region scalaTripleIString matchgroup=scalaInterpolationBrackets start=/\<[a-zA-Z][a-zA-Z0-9_]*"""/ end=/"""\ze\%([^"]\|$\)/ contains=scalaInterpolation,scalaInterpolationB,scalaEscapedChar,scalaUnicodeChar +hi link scalaIString String +hi link scalaTripleIString String + +syn match scalaInterpolation /\$[a-zA-Z0-9_$]\+/ contained +exe 'syn region scalaInterpolationB matchgroup=scalaInterpolationBoundary start=/\${/ end=/}/ contained contains=' . s:ContainedGroup() +hi link scalaInterpolation Function +hi link scalaInterpolationB Normal + +syn region scalaFString matchgroup=scalaInterpolationBrackets start=/f"/ skip=/\\"/ end=/"/ contains=scalaFInterpolation,scalaFInterpolationB,scalaEscapedChar,scalaUnicodeChar +syn match scalaFInterpolation /\$[a-zA-Z0-9_$]\+\(%[-A-Za-z0-9\.]\+\)\?/ contained +exe 'syn region scalaFInterpolationB matchgroup=scalaInterpolationBoundary start=/${/ end=/}\(%[-A-Za-z0-9\.]\+\)\?/ contained contains=' . s:ContainedGroup() +hi link scalaFString String +hi link scalaFInterpolation Function +hi link scalaFInterpolationB Normal + +syn region scalaTripleString start=/"""/ end=/"""\%([^"]\|$\)/ contains=scalaEscapedChar,scalaUnicodeChar +syn region scalaTripleFString matchgroup=scalaInterpolationBrackets start=/f"""/ end=/"""\%([^"]\|$\)/ contains=scalaFInterpolation,scalaFInterpolationB,scalaEscapedChar,scalaUnicodeChar +hi link scalaTripleString String +hi link scalaTripleFString String + +hi link scalaInterpolationBrackets Special +hi link scalaInterpolationBoundary Function + +syn match scalaNumber /\<0[dDfFlL]\?\>/ " Just a bare 0 +syn match scalaNumber /\<[1-9]\d*[dDfFlL]\?\>/ " A multi-digit number - octal numbers with leading 0's are deprecated in Scala +syn match scalaNumber /\<0[xX][0-9a-fA-F]\+[dDfFlL]\?\>/ " Hex number +syn match scalaNumber /\%(\<\d\+\.\d*\|\.\d\+\)\%([eE][-+]\=\d\+\)\=[fFdD]\=/ " exponential notation 1 +syn match scalaNumber /\<\d\+[eE][-+]\=\d\+[fFdD]\=\>/ " exponential notation 2 +syn match scalaNumber /\<\d\+\%([eE][-+]\=\d\+\)\=[fFdD]\>/ " exponential notation 3 +hi link scalaNumber Number + +syn region scalaRoundBrackets start="(" end=")" skipwhite contained contains=scalaTypeDeclaration,scalaSquareBrackets,scalaRoundBrackets + +syn region scalaSquareBrackets matchgroup=scalaSquareBracketsBrackets start="\[" end="\]" skipwhite nextgroup=scalaTypeExtension contains=scalaTypeDeclaration,scalaSquareBrackets,scalaTypeOperator,scalaTypeAnnotationParameter +syn match scalaTypeOperator /[-+=:<>]\+/ contained +syn match scalaTypeAnnotationParameter /@\<[`_A-Za-z0-9$]\+\>/ contained +hi link scalaSquareBracketsBrackets Type +hi link scalaTypeOperator Keyword +hi link scalaTypeAnnotationParameter Function + +syn match scalaShebang "\%^#!.*" display +syn region scalaMultilineComment start="/\*" end="\*/" contains=scalaMultilineComment,scalaDocLinks,scalaParameterAnnotation,scalaCommentAnnotation,scalaTodo,scalaCommentCodeBlock,@Spell keepend fold +syn match scalaCommentAnnotation "@[_A-Za-z0-9$]\+" contained +syn match scalaParameterAnnotation "\%(@tparam\|@param\|@see\)" nextgroup=scalaParamAnnotationValue skipwhite contained +syn match scalaParamAnnotationValue /[.`_A-Za-z0-9$]\+/ contained +syn region scalaDocLinks start="\[\[" end="\]\]" contained +syn region scalaCommentCodeBlock matchgroup=Keyword start="{{{" end="}}}" contained +syn match scalaTodo "\vTODO|FIXME|XXX" contained +hi link scalaShebang Comment +hi link scalaMultilineComment Comment +hi link scalaDocLinks Function +hi link scalaParameterAnnotation Function +hi link scalaParamAnnotationValue Keyword +hi link scalaCommentAnnotation Function +hi link scalaCommentCodeBlockBrackets String +hi link scalaCommentCodeBlock String +hi link scalaTodo Todo + +syn match scalaAnnotation /@\<[`_A-Za-z0-9$]\+\>/ +hi link scalaAnnotation PreProc + +syn match scalaTrailingComment "//.*$" contains=scalaTodo,@Spell +hi link scalaTrailingComment Comment + +syn match scalaAkkaFSM /goto([^)]*)\_s\+\/ contains=scalaAkkaFSMGotoUsing +syn match scalaAkkaFSM /stay\_s\+using/ +syn match scalaAkkaFSM /^\s*stay\s*$/ +syn match scalaAkkaFSM /when\ze([^)]*)/ +syn match scalaAkkaFSM /startWith\ze([^)]*)/ +syn match scalaAkkaFSM /initialize\ze()/ +syn match scalaAkkaFSM /onTransition/ +syn match scalaAkkaFSM /onTermination/ +syn match scalaAkkaFSM /whenUnhandled/ +syn match scalaAkkaFSMGotoUsing /\/ +syn match scalaAkkaFSMGotoUsing /\/ +hi link scalaAkkaFSM PreProc +hi link scalaAkkaFSMGotoUsing PreProc + +let b:current_syntax = 'scala' + +if main_syntax ==# 'scala' + unlet main_syntax +endif + +" vim:set sw=2 sts=2 ts=8 et: + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'scala') == -1 " Vim syntax file diff --git a/syntax/scheme.vim b/syntax/scheme.vim new file mode 100644 index 0000000..1726c3c --- /dev/null +++ b/syntax/scheme.vim @@ -0,0 +1,332 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Scheme (R5RS + some R6RS extras) +" Last Change: 2016 May 23 +" Maintainer: Sergey Khorev +" Original author: Dirk van Deun + +" This script incorrectly recognizes some junk input as numerals: +" parsing the complete system of Scheme numerals using the pattern +" language is practically impossible: I did a lax approximation. + +" MzScheme extensions can be activated with setting is_mzscheme variable + +" Suggestions and bug reports are solicited by the author. + +" Initializing: + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case ignore + +" Fascist highlighting: everything that doesn't fit the rules is an error... + +syn match schemeError ![^ \t()\[\]";]*! +syn match schemeError ")" + +" Quoted and backquoted stuff + +syn region schemeQuoted matchgroup=Delimiter start="['`]" end=![ \t()\[\]";]!me=e-1 contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc + +syn region schemeQuoted matchgroup=Delimiter start="['`](" matchgroup=Delimiter end=")" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc +syn region schemeQuoted matchgroup=Delimiter start="['`]#(" matchgroup=Delimiter end=")" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc + +syn region schemeStrucRestricted matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc +syn region schemeStrucRestricted matchgroup=Delimiter start="#(" matchgroup=Delimiter end=")" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc + +" Popular Scheme extension: +" using [] as well as () +syn region schemeStrucRestricted matchgroup=Delimiter start="\[" matchgroup=Delimiter end="\]" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc +syn region schemeStrucRestricted matchgroup=Delimiter start="#\[" matchgroup=Delimiter end="\]" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc + +syn region schemeUnquote matchgroup=Delimiter start="," end=![ \t\[\]()";]!me=e-1 contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc +syn region schemeUnquote matchgroup=Delimiter start=",@" end=![ \t\[\]()";]!me=e-1 contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc + +syn region schemeUnquote matchgroup=Delimiter start=",(" end=")" contains=ALL +syn region schemeUnquote matchgroup=Delimiter start=",@(" end=")" contains=ALL + +syn region schemeUnquote matchgroup=Delimiter start=",#(" end=")" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc +syn region schemeUnquote matchgroup=Delimiter start=",@#(" end=")" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc + +syn region schemeUnquote matchgroup=Delimiter start=",\[" end="\]" contains=ALL +syn region schemeUnquote matchgroup=Delimiter start=",@\[" end="\]" contains=ALL + +syn region schemeUnquote matchgroup=Delimiter start=",#\[" end="\]" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc +syn region schemeUnquote matchgroup=Delimiter start=",@#\[" end="\]" contains=ALLBUT,schemeStruc,schemeSyntax,schemeFunc + +" R5RS Scheme Functions and Syntax: + +setlocal iskeyword=33,35-39,42-58,60-90,94,95,97-122,126,_ + +syn keyword schemeSyntax lambda and or if cond case define let let* letrec +syn keyword schemeSyntax begin do delay set! else => +syn keyword schemeSyntax quote quasiquote unquote unquote-splicing +syn keyword schemeSyntax define-syntax let-syntax letrec-syntax syntax-rules +" R6RS +syn keyword schemeSyntax define-record-type fields protocol + +syn keyword schemeFunc not boolean? eq? eqv? equal? pair? cons car cdr set-car! +syn keyword schemeFunc set-cdr! caar cadr cdar cddr caaar caadr cadar caddr +syn keyword schemeFunc cdaar cdadr cddar cdddr caaaar caaadr caadar caaddr +syn keyword schemeFunc cadaar cadadr caddar cadddr cdaaar cdaadr cdadar cdaddr +syn keyword schemeFunc cddaar cddadr cdddar cddddr null? list? list length +syn keyword schemeFunc append reverse list-ref memq memv member assq assv assoc +syn keyword schemeFunc symbol? symbol->string string->symbol number? complex? +syn keyword schemeFunc real? rational? integer? exact? inexact? = < > <= >= +syn keyword schemeFunc zero? positive? negative? odd? even? max min + * - / abs +syn keyword schemeFunc quotient remainder modulo gcd lcm numerator denominator +syn keyword schemeFunc floor ceiling truncate round rationalize exp log sin cos +syn keyword schemeFunc tan asin acos atan sqrt expt make-rectangular make-polar +syn keyword schemeFunc real-part imag-part magnitude angle exact->inexact +syn keyword schemeFunc inexact->exact number->string string->number char=? +syn keyword schemeFunc char-ci=? char? char-ci>? char<=? +syn keyword schemeFunc char-ci<=? char>=? char-ci>=? char-alphabetic? char? +syn keyword schemeFunc char-numeric? char-whitespace? char-upper-case? +syn keyword schemeFunc char-lower-case? +syn keyword schemeFunc char->integer integer->char char-upcase char-downcase +syn keyword schemeFunc string? make-string string string-length string-ref +syn keyword schemeFunc string-set! string=? string-ci=? string? string-ci>? string<=? string-ci<=? string>=? +syn keyword schemeFunc string-ci>=? substring string-append vector? make-vector +syn keyword schemeFunc vector vector-length vector-ref vector-set! procedure? +syn keyword schemeFunc apply map for-each call-with-current-continuation +syn keyword schemeFunc call-with-input-file call-with-output-file input-port? +syn keyword schemeFunc output-port? current-input-port current-output-port +syn keyword schemeFunc open-input-file open-output-file close-input-port +syn keyword schemeFunc close-output-port eof-object? read read-char peek-char +syn keyword schemeFunc write display newline write-char call/cc +syn keyword schemeFunc list-tail string->list list->string string-copy +syn keyword schemeFunc string-fill! vector->list list->vector vector-fill! +syn keyword schemeFunc force with-input-from-file with-output-to-file +syn keyword schemeFunc char-ready? load transcript-on transcript-off eval +syn keyword schemeFunc dynamic-wind port? values call-with-values +syn keyword schemeFunc scheme-report-environment null-environment +syn keyword schemeFunc interaction-environment +" R6RS +syn keyword schemeFunc make-eq-hashtable make-eqv-hashtable make-hashtable +syn keyword schemeFunc hashtable? hashtable-size hashtable-ref hashtable-set! +syn keyword schemeFunc hashtable-delete! hashtable-contains? hashtable-update! +syn keyword schemeFunc hashtable-copy hashtable-clear! hashtable-keys +syn keyword schemeFunc hashtable-entries hashtable-equivalence-function hashtable-hash-function +syn keyword schemeFunc hashtable-mutable? equal-hash string-hash string-ci-hash symbol-hash +syn keyword schemeFunc find for-all exists filter partition fold-left fold-right +syn keyword schemeFunc remp remove remv remq memp assp cons* + +" ... so that a single + or -, inside a quoted context, would not be +" interpreted as a number (outside such contexts, it's a schemeFunc) + +syn match schemeDelimiter !\.[ \t\[\]()";]!me=e-1 +syn match schemeDelimiter !\.$! +" ... and a single dot is not a number but a delimiter + +" This keeps all other stuff unhighlighted, except *stuff* and : + +syn match schemeOther ,[a-z!$%&*/:<=>?^_~+@#%-][-a-z!$%&*/:<=>?^_~0-9+.@#%]*, +syn match schemeError ,[a-z!$%&*/:<=>?^_~+@#%-][-a-z!$%&*/:<=>?^_~0-9+.@#%]*[^-a-z!$%&*/:<=>?^_~0-9+.@ \t\[\]()";]\+[^ \t\[\]()";]*, + +syn match schemeOther "\.\.\." +syn match schemeError !\.\.\.[^ \t\[\]()";]\+! +" ... a special identifier + +syn match schemeConstant ,\*[-a-z!$%&*/:<=>?^_~0-9+.@]\+\*[ \t\[\]()";],me=e-1 +syn match schemeConstant ,\*[-a-z!$%&*/:<=>?^_~0-9+.@]\+\*$, +syn match schemeError ,\*[-a-z!$%&*/:<=>?^_~0-9+.@]*\*[^-a-z!$%&*/:<=>?^_~0-9+.@ \t\[\]()";]\+[^ \t\[\]()";]*, + +syn match schemeConstant ,<[-a-z!$%&*/:<=>?^_~0-9+.@]*>[ \t\[\]()";],me=e-1 +syn match schemeConstant ,<[-a-z!$%&*/:<=>?^_~0-9+.@]*>$, +syn match schemeError ,<[-a-z!$%&*/:<=>?^_~0-9+.@]*>[^-a-z!$%&*/:<=>?^_~0-9+.@ \t\[\]()";]\+[^ \t\[\]()";]*, + +" Non-quoted lists, and strings: + +syn region schemeStruc matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" contains=ALL +syn region schemeStruc matchgroup=Delimiter start="#(" matchgroup=Delimiter end=")" contains=ALL + +syn region schemeStruc matchgroup=Delimiter start="\[" matchgroup=Delimiter end="\]" contains=ALL +syn region schemeStruc matchgroup=Delimiter start="#\[" matchgroup=Delimiter end="\]" contains=ALL + +" Simple literals: +syn region schemeString start=+\%(\\\)\@?^_~0-9+.@#%]\+" + " anything limited by |'s is identifier + syn match schemeOther "|[^|]\+|" + + syn match schemeCharacter "#\\\%(return\|tab\)" + + " Modules require stmt + syn keyword schemeExtSyntax module require dynamic-require lib prefix all-except prefix-all-except rename + " modules provide stmt + syn keyword schemeExtSyntax provide struct all-from all-from-except all-defined all-defined-except + " Other from MzScheme + syn keyword schemeExtSyntax with-handlers when unless instantiate define-struct case-lambda syntax-case + syn keyword schemeExtSyntax free-identifier=? bound-identifier=? module-identifier=? syntax-object->datum + syn keyword schemeExtSyntax datum->syntax-object + syn keyword schemeExtSyntax let-values let*-values letrec-values set!-values fluid-let parameterize begin0 + syn keyword schemeExtSyntax error raise opt-lambda define-values unit unit/sig define-signature + syn keyword schemeExtSyntax invoke-unit/sig define-values/invoke-unit/sig compound-unit/sig import export + syn keyword schemeExtSyntax link syntax quasisyntax unsyntax with-syntax + + syn keyword schemeExtFunc format system-type current-extension-compiler current-extension-linker + syn keyword schemeExtFunc use-standard-linker use-standard-compiler + syn keyword schemeExtFunc find-executable-path append-object-suffix append-extension-suffix + syn keyword schemeExtFunc current-library-collection-paths current-extension-compiler-flags make-parameter + syn keyword schemeExtFunc current-directory build-path normalize-path current-extension-linker-flags + syn keyword schemeExtFunc file-exists? directory-exists? delete-directory/files delete-directory delete-file + syn keyword schemeExtFunc system compile-file system-library-subpath getenv putenv current-standard-link-libraries + syn keyword schemeExtFunc remove* file-size find-files fold-files directory-list shell-execute split-path + syn keyword schemeExtFunc current-error-port process/ports process printf fprintf open-input-string open-output-string + syn keyword schemeExtFunc get-output-string + " exceptions + syn keyword schemeExtFunc exn exn:application:arity exn:application:continuation exn:application:fprintf:mismatch + syn keyword schemeExtFunc exn:application:mismatch exn:application:type exn:application:mismatch exn:break exn:i/o:filesystem exn:i/o:port + syn keyword schemeExtFunc exn:i/o:port:closed exn:i/o:tcp exn:i/o:udp exn:misc exn:misc:application exn:misc:unsupported exn:module exn:read + syn keyword schemeExtFunc exn:read:non-char exn:special-comment exn:syntax exn:thread exn:user exn:variable exn:application:mismatch + syn keyword schemeExtFunc exn? exn:application:arity? exn:application:continuation? exn:application:fprintf:mismatch? exn:application:mismatch? + syn keyword schemeExtFunc exn:application:type? exn:application:mismatch? exn:break? exn:i/o:filesystem? exn:i/o:port? exn:i/o:port:closed? + syn keyword schemeExtFunc exn:i/o:tcp? exn:i/o:udp? exn:misc? exn:misc:application? exn:misc:unsupported? exn:module? exn:read? exn:read:non-char? + syn keyword schemeExtFunc exn:special-comment? exn:syntax? exn:thread? exn:user? exn:variable? exn:application:mismatch? + " Command-line parsing + syn keyword schemeExtFunc command-line current-command-line-arguments once-any help-labels multi once-each + + " syntax quoting, unquoting and quasiquotation + syn region schemeUnquote matchgroup=Delimiter start="#," end=![ \t\[\]()";]!me=e-1 contains=ALL + syn region schemeUnquote matchgroup=Delimiter start="#,@" end=![ \t\[\]()";]!me=e-1 contains=ALL + syn region schemeUnquote matchgroup=Delimiter start="#,(" end=")" contains=ALL + syn region schemeUnquote matchgroup=Delimiter start="#,@(" end=")" contains=ALL + syn region schemeUnquote matchgroup=Delimiter start="#,\[" end="\]" contains=ALL + syn region schemeUnquote matchgroup=Delimiter start="#,@\[" end="\]" contains=ALL + syn region schemeQuoted matchgroup=Delimiter start="#['`]" end=![ \t()\[\]";]!me=e-1 contains=ALL + syn region schemeQuoted matchgroup=Delimiter start="#['`](" matchgroup=Delimiter end=")" contains=ALL + + " Identifiers are very liberal in MzScheme/Racket + syn match schemeOther ![^()[\]{}",'`;#|\\ ]\+! + + " Language setting + syn match schemeLang "#lang [-+_/A-Za-z0-9]\+\>" + + " Various number forms + syn match schemeNumber "[-+]\=[0-9]\+\(\.[0-9]*\)\=\(e[-+]\=[0-9]\+\)\=\>" + syn match schemeNumber "[-+]\=\.[0-9]\+\(e[-+]\=[0-9]\+\)\=\>" + syn match schemeNumber "[-+]\=[0-9]\+/[0-9]\+\>" + syn match schemeNumber "\([-+]\=\([0-9]\+\(\.[0-9]*\)\=\(e[-+]\=[0-9]\+\)\=\|\.[0-9]\+\(e[-+]\=[0-9]\+\)\=\|[0-9]\+/[0-9]\+\)\)\=[-+]\([0-9]\+\(\.[0-9]*\)\=\(e[-+]\=[0-9]\+\)\=\|\.[0-9]\+\(e[-+]\=[0-9]\+\)\=\|[0-9]\+/[0-9]\+\)\=i\>" +endif + + +if exists("b:is_chicken") || exists("is_chicken") + " multiline comment + syntax region schemeMultilineComment start=/#|/ end=/|#/ contains=@Spell,schemeMultilineComment + + syn match schemeOther "##[-a-z!$%&*/:<=>?^_~0-9+.@#%]\+" + syn match schemeExtSyntax "#:[-a-z!$%&*/:<=>?^_~0-9+.@#%]\+" + + syn keyword schemeExtSyntax unit uses declare hide foreign-declare foreign-parse foreign-parse/spec + syn keyword schemeExtSyntax foreign-lambda foreign-lambda* define-external define-macro load-library + syn keyword schemeExtSyntax let-values let*-values letrec-values ->string require-extension + syn keyword schemeExtSyntax let-optionals let-optionals* define-foreign-variable define-record + syn keyword schemeExtSyntax pointer tag-pointer tagged-pointer? define-foreign-type + syn keyword schemeExtSyntax require require-for-syntax cond-expand and-let* receive argc+argv + syn keyword schemeExtSyntax fixnum? fx= fx> fx< fx>= fx<= fxmin fxmax + syn keyword schemeExtFunc ##core#inline ##sys#error ##sys#update-errno + + " here-string + syn region schemeString start=+#<<\s*\z(.*\)+ end=+^\z1$+ contains=@Spell + + if filereadable(expand(":p:h")."/cpp.vim") + unlet! b:current_syntax + syn include @ChickenC :p:h/cpp.vim + syn region ChickenC matchgroup=schemeOther start=+(\@<=foreign-declare "+ end=+")\@=+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+foreign-declare\s*#<<\z(.*\)$+hs=s+15 end=+^\z1$+ contains=@ChickenC + syn region ChickenC matchgroup=schemeOther start=+(\@<=foreign-parse "+ end=+")\@=+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+foreign-parse\s*#<<\z(.*\)$+hs=s+13 end=+^\z1$+ contains=@ChickenC + syn region ChickenC matchgroup=schemeOther start=+(\@<=foreign-parse/spec "+ end=+")\@=+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+foreign-parse/spec\s*#<<\z(.*\)$+hs=s+18 end=+^\z1$+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+#>+ end=+<#+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+#>?+ end=+<#+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+#>!+ end=+<#+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+#>\$+ end=+<#+ contains=@ChickenC + syn region ChickenC matchgroup=schemeComment start=+#>%+ end=+<#+ contains=@ChickenC + endif + + " suggested by Alex Queiroz + syn match schemeExtSyntax "#![-a-z!$%&*/:<=>?^_~0-9+.@#%]\+" + syn region schemeString start=+#<#\s*\z(.*\)+ end=+^\z1$+ contains=@Spell +endif + +" Synchronization and the wrapping up... + +syn sync match matchPlace grouphere NONE "^[^ \t]" +" ... i.e. synchronize on a line that starts at the left margin + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link schemeSyntax Statement +hi def link schemeFunc Function + +hi def link schemeString String +hi def link schemeCharacter Character +hi def link schemeNumber Number +hi def link schemeBoolean Boolean + +hi def link schemeDelimiter Delimiter +hi def link schemeConstant Constant + +hi def link schemeComment Comment +hi def link schemeMultilineComment Comment +hi def link schemeError Error + +hi def link schemeExtSyntax Type +hi def link schemeExtFunc PreProc + +hi def link schemeLang PreProc + + +let b:current_syntax = "scheme" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/scilab.vim b/syntax/scilab.vim new file mode 100644 index 0000000..a4f3b6c --- /dev/null +++ b/syntax/scilab.vim @@ -0,0 +1,106 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" +" Vim syntax file +" Language : Scilab +" Maintainer : Benoit Hamelin +" File type : *.sci (see :help filetype) +" History +" 28jan2002 benoith 0.1 Creation. Adapted from matlab.vim. +" 04feb2002 benoith 0.5 Fixed bugs with constant highlighting. +" + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +" Reserved words. +syn keyword scilabStatement abort clear clearglobal end exit global mode predef quit resume +syn keyword scilabStatement return +syn keyword scilabFunction function endfunction funptr +syn keyword scilabPredicate null iserror isglobal +syn keyword scilabKeyword typename +syn keyword scilabDebug debug pause what where whereami whereis who whos +syn keyword scilabRepeat for while break +syn keyword scilabConditional if then else elseif +syn keyword scilabMultiplex select case + +" Reserved constants. +syn match scilabConstant "\(%\)[0-9A-Za-z?!#$]\+" +syn match scilabBoolean "\(%\)[FTft]\>" + +" Delimiters and operators. +syn match scilabDelimiter "[][;,()]" +syn match scilabComparison "[=~]=" +syn match scilabComparison "[<>]=\=" +syn match scilabComparison "<>" +syn match scilabLogical "[&|~]" +syn match scilabAssignment "=" +syn match scilabArithmetic "[+-]" +syn match scilabArithmetic "\.\=[*/\\]\.\=" +syn match scilabArithmetic "\.\=^" +syn match scilabRange ":" +syn match scilabMlistAccess "\." + +syn match scilabLineContinuation "\.\{2,}" + +syn match scilabTransposition "[])a-zA-Z0-9?!_#$.]'"lc=1 + +" Comments and tools. +syn keyword scilabTodo TODO todo FIXME fixme TBD tbd contained +syn match scilabComment "//.*$" contains=scilabTodo + +" Constants. +syn match scilabNumber "[0-9]\+\(\.[0-9]*\)\=\([DEde][+-]\=[0-9]\+\)\=" +syn match scilabNumber "\.[0-9]\+\([DEde][+-]\=[0-9]\+\)\=" +syn region scilabString start=+'+ skip=+''+ end=+'+ oneline +syn region scilabString start=+"+ end=+"+ oneline + +" Identifiers. +syn match scilabIdentifier "\<[A-Za-z?!_#$][A-Za-z0-9?!_#$]*\>" +syn match scilabOverload "%[A-Za-z0-9?!_#$]\+_[A-Za-z0-9?!_#$]\+" + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link scilabStatement Statement +hi def link scilabFunction Keyword +hi def link scilabPredicate Keyword +hi def link scilabKeyword Keyword +hi def link scilabDebug Debug +hi def link scilabRepeat Repeat +hi def link scilabConditional Conditional +hi def link scilabMultiplex Conditional + +hi def link scilabConstant Constant +hi def link scilabBoolean Boolean + +hi def link scilabDelimiter Delimiter +hi def link scilabMlistAccess Delimiter +hi def link scilabComparison Operator +hi def link scilabLogical Operator +hi def link scilabAssignment Operator +hi def link scilabArithmetic Operator +hi def link scilabRange Operator +hi def link scilabLineContinuation Underlined +hi def link scilabTransposition Operator + +hi def link scilabTodo Todo +hi def link scilabComment Comment + +hi def link scilabNumber Number +hi def link scilabString String + +hi def link scilabIdentifier Identifier +hi def link scilabOverload Special + + +let b:current_syntax = "scilab" + +"EOF vim: ts=4 noet tw=100 sw=4 sts=0 + +endif diff --git a/syntax/screen.vim b/syntax/screen.vim new file mode 100644 index 0000000..a7213e9 --- /dev/null +++ b/syntax/screen.vim @@ -0,0 +1,264 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: screen(1) configuration file +" Maintainer: Dmitri Vereshchagin +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2015-09-24 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match screenEscape '\\.' + +syn keyword screenTodo contained TODO FIXME XXX NOTE + +syn region screenComment display oneline start='#' end='$' + \ contains=screenTodo,@Spell + +syn region screenString display oneline start=+"+ skip=+\\"+ end=+"+ + \ contains=screenVariable,screenSpecial + +syn region screenLiteral display oneline start=+'+ skip=+\\'+ end=+'+ + +syn match screenVariable contained display '$\%(\h\w*\|{\h\w*}\)' + +syn keyword screenBoolean on off + +syn match screenNumbers display '\<\d\+\>' + +syn match screenSpecials contained + \ '%\%([%aAdDhlmMstuwWyY?:{]\|[0-9]*n\|0?cC\)' + +syn keyword screenCommands + \ acladd + \ aclchg + \ acldel + \ aclgrp + \ aclumask + \ activity + \ addacl + \ allpartial + \ altscreen + \ at + \ attrcolor + \ autodetach + \ autonuke + \ backtick + \ bce + \ bd_bc_down + \ bd_bc_left + \ bd_bc_right + \ bd_bc_up + \ bd_bell + \ bd_braille_table + \ bd_eightdot + \ bd_info + \ bd_link + \ bd_lower_left + \ bd_lower_right + \ bd_ncrc + \ bd_port + \ bd_scroll + \ bd_skip + \ bd_start_braille + \ bd_type + \ bd_upper_left + \ bd_upper_right + \ bd_width + \ bell + \ bell_msg + \ bind + \ bindkey + \ blanker + \ blankerprg + \ break + \ breaktype + \ bufferfile + \ bumpleft + \ bumpright + \ c1 + \ caption + \ chacl + \ charset + \ chdir + \ cjkwidth + \ clear + \ collapse + \ colon + \ command + \ compacthist + \ console + \ copy + \ crlf + \ debug + \ defautonuke + \ defbce + \ defbreaktype + \ defc1 + \ defcharset + \ defencoding + \ defescape + \ defflow + \ defgr + \ defhstatus + \ defkanji + \ deflog + \ deflogin + \ defmode + \ defmonitor + \ defmousetrack + \ defnonblock + \ defobuflimit + \ defscrollback + \ defshell + \ defsilence + \ defslowpaste + \ defutf8 + \ defwrap + \ defwritelock + \ defzombie + \ detach + \ digraph + \ dinfo + \ displays + \ dumptermcap + \ echo + \ encoding + \ escape + \ eval + \ exec + \ fit + \ flow + \ focus + \ focusminsize + \ gr + \ group + \ hardcopy + \ hardcopy_append + \ hardcopydir + \ hardstatus + \ height + \ help + \ history + \ hstatus + \ idle + \ ignorecase + \ info + \ kanji + \ kill + \ lastmsg + \ layout + \ license + \ lockscreen + \ log + \ logfile + \ login + \ logtstamp + \ mapdefault + \ mapnotnext + \ maptimeout + \ markkeys + \ maxwin + \ meta + \ monitor + \ mousetrack + \ msgminwait + \ msgwait + \ multiuser + \ nethack + \ next + \ nonblock + \ number + \ obuflimit + \ only + \ other + \ partial + \ password + \ paste + \ pastefont + \ pow_break + \ pow_detach + \ pow_detach_msg + \ prev + \ printcmd + \ process + \ quit + \ readbuf + \ readreg + \ redisplay + \ register + \ remove + \ removebuf + \ rendition + \ reset + \ resize + \ screen + \ scrollback + \ select + \ sessionname + \ setenv + \ setsid + \ shell + \ shelltitle + \ silence + \ silencewait + \ sleep + \ slowpaste + \ sorendition + \ sort + \ source + \ split + \ startup_message + \ stuff + \ su + \ suspend + \ term + \ termcap + \ termcapinfo + \ terminfo + \ time + \ title + \ umask + \ unbindall + \ unsetenv + \ utf8 + \ vbell + \ vbell_msg + \ vbellwait + \ verbose + \ version + \ wall + \ width + \ windowlist + \ windows + \ wrap + \ writebuf + \ writelock + \ xoff + \ xon + \ zmodem + \ zombie + \ zombie_timeout + +hi def link screenEscape Special +hi def link screenComment Comment +hi def link screenTodo Todo +hi def link screenString String +hi def link screenLiteral String +hi def link screenVariable Identifier +hi def link screenBoolean Boolean +hi def link screenNumbers Number +hi def link screenSpecials Special +hi def link screenCommands Keyword + +let b:current_syntax = "screen" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/scss.vim b/syntax/scss.vim index 15b8359..fa697a5 100644 --- a/syntax/scss.vim +++ b/syntax/scss.vim @@ -1,3 +1,27 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SCSS +" Maintainer: Tim Pope +" Filenames: *.scss +" Last Change: 2010 Jul 26 + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/sass.vim + +syn match scssComment "//.*" contains=sassTodo,@Spell +syn region scssComment start="/\*" end="\*/" contains=sassTodo,@Spell + +hi def link scssComment sassComment + +let b:current_syntax = "scss" + +" vim:set sw=2: + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'scss') == -1 " Vim syntax file diff --git a/syntax/sd.vim b/syntax/sd.vim new file mode 100644 index 0000000..0899655 --- /dev/null +++ b/syntax/sd.vim @@ -0,0 +1,75 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: streaming descriptor file +" Maintainer: Puria Nafisi Azizi (pna) +" License: This file can be redistribued and/or modified under the same terms +" as Vim itself. +" URL: http://netstudent.polito.it/vim_syntax/ +" Last Change: 2012 Feb 03 by Thilo Six + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Always ignore case +syn case ignore + +" Comments +syn match sdComment /\s*[#;].*$/ + +" IP Adresses +syn cluster sdIPCluster contains=sdIPError,sdIPSpecial +syn match sdIPError /\%(\d\{4,}\|25[6-9]\|2[6-9]\d\|[3-9]\d\{2}\)[\.0-9]*/ contained +syn match sdIPSpecial /\%(127\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}\)/ contained +syn match sdIP contained /\%(\d\{1,4}\.\)\{3}\d\{1,4}/ contains=@sdIPCluster + +" Statements +syn keyword sdStatement AGGREGATE AUDIO_CHANNELS +syn keyword sdStatement BYTE_PER_PCKT BIT_PER_SAMPLE BITRATE +syn keyword sdStatement CLOCK_RATE CODING_TYPE CREATOR +syn match sdStatement /^\s*CODING_TYPE\>/ nextgroup=sdCoding skipwhite +syn match sdStatement /^\s*ENCODING_NAME\>/ nextgroup=sdEncoding skipwhite +syn keyword sdStatement FILE_NAME FRAME_LEN FRAME_RATE FORCE_FRAME_RATE +syn keyword sdStatement LICENSE +syn match sdStatement /^\s*MEDIA_SOURCE\>/ nextgroup=sdSource skipwhite +syn match sdStatement /^\s*MULTICAST\>/ nextgroup=sdIP skipwhite +syn keyword sdStatement PAYLOAD_TYPE PKT_LEN PRIORITY +syn keyword sdStatement SAMPLE_RATE +syn keyword sdStatement TITLE TWIN +syn keyword sdStatement VERIFY + +" Known Options +syn keyword sdEncoding H26L MPV MP2T MP4V-ES +syn keyword sdCoding FRAME SAMPLE +syn keyword sdSource STORED LIVE + +"Specials +syn keyword sdSpecial TRUE FALSE NULL +syn keyword sdDelimiter STREAM STREAM_END +syn match sdError /^search .\{257,}/ + + +hi def link sdIP Number +hi def link sdHostname Type +hi def link sdEncoding Identifier +hi def link sdCoding Identifier +hi def link sdSource Identifier +hi def link sdComment Comment +hi def link sdIPError Error +hi def link sdError Error +hi def link sdStatement Statement +hi def link sdIPSpecial Special +hi def link sdSpecial Special +hi def link sdDelimiter Delimiter + + +let b:current_syntax = "sd" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/sdc.vim b/syntax/sdc.vim new file mode 100644 index 0000000..fb8a956 --- /dev/null +++ b/syntax/sdc.vim @@ -0,0 +1,45 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SDC - Synopsys Design Constraints +" Maintainer: Maurizio Tranchero - maurizio.tranchero@gmail.com +" Last Change: Thu Mar 25 17:35:16 CET 2009 +" Credits: based on TCL Vim syntax file +" Version: 0.3 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read the TCL syntax to start with +runtime! syntax/tcl.vim + +" SDC-specific keywords +syn keyword sdcCollections foreach_in_collection +syn keyword sdcObjectsQuery get_clocks get_ports +syn keyword sdcObjectsInfo get_point_info get_node_info get_path_info +syn keyword sdcObjectsInfo get_timing_paths set_attribute +syn keyword sdcConstraints set_false_path +syn keyword sdcNonIdealities set_min_delay set_max_delay +syn keyword sdcNonIdealities set_input_delay set_output_delay +syn keyword sdcNonIdealities set_load set_min_capacitance set_max_capacitance +syn keyword sdcCreateOperations create_clock create_timing_netlist update_timing_netlist + +" command flags highlighting +syn match sdcFlags "[[:space:]]-[[:alpha:]]*\>" + +" Define the default highlighting. +hi def link sdcCollections Repeat +hi def link sdcObjectsInfo Operator +hi def link sdcCreateOperations Operator +hi def link sdcObjectsQuery Operator +hi def link sdcConstraints Operator +hi def link sdcNonIdealities Operator +hi def link sdcFlags Special + +let b:current_syntax = "sdc" + +" vim: ts=8 + +endif diff --git a/syntax/sdl.vim b/syntax/sdl.vim new file mode 100644 index 0000000..6984f47 --- /dev/null +++ b/syntax/sdl.vim @@ -0,0 +1,157 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SDL +" Maintainer: Michael Piefel +" Last Change: 2 May 2001 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("sdl_2000") + syntax case ignore +endif + +" A bunch of useful SDL keywords +syn keyword sdlStatement task else nextstate +syn keyword sdlStatement in out with from interface +syn keyword sdlStatement to via env and use +syn keyword sdlStatement process procedure block system service type +syn keyword sdlStatement endprocess endprocedure endblock endsystem +syn keyword sdlStatement package endpackage connection endconnection +syn keyword sdlStatement channel endchannel connect +syn keyword sdlStatement synonym dcl signal gate timer signallist signalset +syn keyword sdlStatement create output set reset call +syn keyword sdlStatement operators literals +syn keyword sdlStatement active alternative any as atleast constants +syn keyword sdlStatement default endalternative endmacro endoperator +syn keyword sdlStatement endselect endsubstructure external +syn keyword sdlStatement if then fi for import macro macrodefinition +syn keyword sdlStatement macroid mod nameclass nodelay not operator or +syn keyword sdlStatement parent provided referenced rem +syn keyword sdlStatement select spelling substructure xor +syn keyword sdlNewState state endstate +syn keyword sdlInput input start stop return none save priority +syn keyword sdlConditional decision enddecision join +syn keyword sdlVirtual virtual redefined finalized adding inherits +syn keyword sdlExported remote exported export + +if !exists("sdl_no_96") + syn keyword sdlStatement all axioms constant endgenerator endrefinement endservice + syn keyword sdlStatement error fpar generator literal map noequality ordering + syn keyword sdlStatement refinement returns revealed reverse service signalroute + syn keyword sdlStatement view viewed + syn keyword sdlExported imported +endif + +if exists("sdl_2000") + syn keyword sdlStatement abstract aggregation association break choice composition + syn keyword sdlStatement continue endmethod handle method + syn keyword sdlStatement ordered private protected public + syn keyword sdlException exceptionhandler endexceptionhandler onexception + syn keyword sdlException catch new raise + " The same in uppercase + syn keyword sdlStatement TASK ELSE NEXTSTATE + syn keyword sdlStatement IN OUT WITH FROM INTERFACE + syn keyword sdlStatement TO VIA ENV AND USE + syn keyword sdlStatement PROCESS PROCEDURE BLOCK SYSTEM SERVICE TYPE + syn keyword sdlStatement ENDPROCESS ENDPROCEDURE ENDBLOCK ENDSYSTEM + syn keyword sdlStatement PACKAGE ENDPACKAGE CONNECTION ENDCONNECTION + syn keyword sdlStatement CHANNEL ENDCHANNEL CONNECT + syn keyword sdlStatement SYNONYM DCL SIGNAL GATE TIMER SIGNALLIST SIGNALSET + syn keyword sdlStatement CREATE OUTPUT SET RESET CALL + syn keyword sdlStatement OPERATORS LITERALS + syn keyword sdlStatement ACTIVE ALTERNATIVE ANY AS ATLEAST CONSTANTS + syn keyword sdlStatement DEFAULT ENDALTERNATIVE ENDMACRO ENDOPERATOR + syn keyword sdlStatement ENDSELECT ENDSUBSTRUCTURE EXTERNAL + syn keyword sdlStatement IF THEN FI FOR IMPORT MACRO MACRODEFINITION + syn keyword sdlStatement MACROID MOD NAMECLASS NODELAY NOT OPERATOR OR + syn keyword sdlStatement PARENT PROVIDED REFERENCED REM + syn keyword sdlStatement SELECT SPELLING SUBSTRUCTURE XOR + syn keyword sdlNewState STATE ENDSTATE + syn keyword sdlInput INPUT START STOP RETURN NONE SAVE PRIORITY + syn keyword sdlConditional DECISION ENDDECISION JOIN + syn keyword sdlVirtual VIRTUAL REDEFINED FINALIZED ADDING INHERITS + syn keyword sdlExported REMOTE EXPORTED EXPORT + + syn keyword sdlStatement ABSTRACT AGGREGATION ASSOCIATION BREAK CHOICE COMPOSITION + syn keyword sdlStatement CONTINUE ENDMETHOD ENDOBJECT ENDVALUE HANDLE METHOD OBJECT + syn keyword sdlStatement ORDERED PRIVATE PROTECTED PUBLIC + syn keyword sdlException EXCEPTIONHANDLER ENDEXCEPTIONHANDLER ONEXCEPTION + syn keyword sdlException CATCH NEW RAISE +endif + +" String and Character contstants +" Highlight special characters (those which have a backslash) differently +syn match sdlSpecial contained "\\\d\d\d\|\\." +syn region sdlString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=cSpecial +syn region sdlString start=+'+ skip=+''+ end=+'+ + +" No, this doesn't happen, I just wanted to scare you. SDL really allows all +" these characters for identifiers; fortunately, keywords manage without them. +" set iskeyword=@,48-57,_,192-214,216-246,248-255,- + +syn region sdlComment start="/\*" end="\*/" +syn region sdlComment start="comment" end=";" +syn region sdlComment start="--" end="--\|$" +syn match sdlCommentError "\*/" + +syn keyword sdlOperator present +syn keyword sdlType integer real natural duration pid boolean time +syn keyword sdlType character charstring ia5string +syn keyword sdlType self now sender offspring +syn keyword sdlStructure asntype endasntype syntype endsyntype struct + +if !exists("sdl_no_96") + syn keyword sdlStructure newtype endnewtype +endif + +if exists("sdl_2000") + syn keyword sdlStructure object endobject value endvalue + " The same in uppercase + syn keyword sdlStructure OBJECT ENDOBJECT VALUE ENDVALUE + syn keyword sdlOperator PRESENT + syn keyword sdlType INTEGER NATURAL DURATION PID BOOLEAN TIME + syn keyword sdlType CHARSTRING IA5STRING + syn keyword sdlType SELF NOW SENDER OFFSPRING + syn keyword sdlStructure ASNTYPE ENDASNTYPE SYNTYPE ENDSYNTYPE STRUCT +endif + +" ASN.1 in SDL +syn case match +syn keyword sdlType SET OF BOOLEAN INTEGER REAL BIT OCTET +syn keyword sdlType SEQUENCE CHOICE +syn keyword sdlType STRING OBJECT IDENTIFIER NULL + +syn sync ccomment sdlComment + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +command -nargs=+ Hi hi def + +hi def link sdlException Label +hi def link sdlConditional sdlStatement +hi def link sdlVirtual sdlStatement +hi def link sdlExported sdlFlag +hi def link sdlCommentError sdlError +hi def link sdlOperator Operator +hi def link sdlStructure sdlType +Hi sdlStatement term=bold ctermfg=4 guifg=Blue +Hi sdlFlag term=bold ctermfg=4 guifg=Blue gui=italic +Hi sdlNewState term=italic ctermfg=2 guifg=Magenta gui=underline +Hi sdlInput term=bold guifg=Red +hi def link sdlType Type +hi def link sdlString String +hi def link sdlComment Comment +hi def link sdlSpecial Special +hi def link sdlError Error + +delcommand Hi + +let b:current_syntax = "sdl" + +" vim: ts=8 + +endif diff --git a/syntax/sed.vim b/syntax/sed.vim new file mode 100644 index 0000000..b1a88e8 --- /dev/null +++ b/syntax/sed.vim @@ -0,0 +1,114 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sed +" Maintainer: Haakon Riiser +" URL: http://folk.uio.no/hakonrk/vim/syntax/sed.vim +" Last Change: 2010 May 29 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match sedError "\S" + +syn match sedWhitespace "\s\+" contained +syn match sedSemicolon ";" +syn match sedAddress "[[:digit:]$]" +syn match sedAddress "\d\+\~\d\+" +syn region sedAddress matchgroup=Special start="[{,;]\s*/\(\\/\)\="lc=1 skip="[^\\]\(\\\\\)*\\/" end="/I\=" contains=sedTab,sedRegexpMeta +syn region sedAddress matchgroup=Special start="^\s*/\(\\/\)\=" skip="[^\\]\(\\\\\)*\\/" end="/I\=" contains=sedTab,sedRegexpMeta +syn match sedComment "^\s*#.*$" +syn match sedFunction "[dDgGhHlnNpPqQx=]\s*\($\|;\)" contains=sedSemicolon,sedWhitespace +syn match sedLabel ":[^;]*" +syn match sedLineCont "^\(\\\\\)*\\$" contained +syn match sedLineCont "[^\\]\(\\\\\)*\\$"ms=e contained +syn match sedSpecial "[{},!]" +if exists("highlight_sedtabs") + syn match sedTab "\t" contained +endif + +" Append/Change/Insert +syn region sedACI matchgroup=sedFunction start="[aci]\\$" matchgroup=NONE end="^.*$" contains=sedLineCont,sedTab + +syn region sedBranch matchgroup=sedFunction start="[bt]" matchgroup=sedSemicolon end=";\|$" contains=sedWhitespace +syn region sedRW matchgroup=sedFunction start="[rw]" matchgroup=sedSemicolon end=";\|$" contains=sedWhitespace + +" Substitution/transform with various delimiters +syn region sedFlagwrite matchgroup=sedFlag start="w" matchgroup=sedSemicolon end=";\|$" contains=sedWhitespace contained +syn match sedFlag "[[:digit:]gpI]*w\=" contains=sedFlagwrite contained +syn match sedRegexpMeta "[.*^$]" contained +syn match sedRegexpMeta "\\." contains=sedTab contained +syn match sedRegexpMeta "\[.\{-}\]" contains=sedTab contained +syn match sedRegexpMeta "\\{\d\*,\d*\\}" contained +syn match sedRegexpMeta "\\(.\{-}\\)" contains=sedTab contained +syn match sedReplaceMeta "&\|\\\($\|.\)" contains=sedTab contained + +" Metacharacters: $ * . \ ^ [ ~ +" @ is used as delimiter and treated on its own below +let __at = char2nr("@") +let __sed_i = char2nr(" ") " ASCII: 32, EBCDIC: 64 +if has("ebcdic") + let __sed_last = 255 +else + let __sed_last = 126 +endif +let __sed_metacharacters = '$*.\^[~' +while __sed_i <= __sed_last + let __sed_delimiter = escape(nr2char(__sed_i), __sed_metacharacters) + if __sed_i != __at + exe 'syn region sedAddress matchgroup=Special start=@\\'.__sed_delimiter.'\(\\'.__sed_delimiter.'\)\=@ skip=@[^\\]\(\\\\\)*\\'.__sed_delimiter.'@ end=@'.__sed_delimiter.'I\=@ contains=sedTab' + exe 'syn region sedRegexp'.__sed_i 'matchgroup=Special start=@'.__sed_delimiter.'\(\\\\\|\\'.__sed_delimiter.'\)*@ skip=@[^\\'.__sed_delimiter.']\(\\\\\)*\\'.__sed_delimiter.'@ end=@'.__sed_delimiter.'@me=e-1 contains=sedTab,sedRegexpMeta keepend contained nextgroup=sedReplacement'.__sed_i + exe 'syn region sedReplacement'.__sed_i 'matchgroup=Special start=@'.__sed_delimiter.'\(\\\\\|\\'.__sed_delimiter.'\)*@ skip=@[^\\'.__sed_delimiter.']\(\\\\\)*\\'.__sed_delimiter.'@ end=@'.__sed_delimiter.'@ contains=sedTab,sedReplaceMeta keepend contained nextgroup=sedFlag' + endif + let __sed_i = __sed_i + 1 +endwhile +syn region sedAddress matchgroup=Special start=+\\@\(\\@\)\=+ skip=+[^\\]\(\\\\\)*\\@+ end=+@I\=+ contains=sedTab,sedRegexpMeta +syn region sedRegexp64 matchgroup=Special start=+@\(\\\\\|\\@\)*+ skip=+[^\\@]\(\\\\\)*\\@+ end=+@+me=e-1 contains=sedTab,sedRegexpMeta keepend contained nextgroup=sedReplacement64 +syn region sedReplacement64 matchgroup=Special start=+@\(\\\\\|\\@\)*+ skip=+[^\\@]\(\\\\\)*\\@+ end=+@+ contains=sedTab,sedReplaceMeta keepend contained nextgroup=sedFlag + +" Since the syntax for the substituion command is very similar to the +" syntax for the transform command, I use the same pattern matching +" for both commands. There is one problem -- the transform command +" (y) does not allow any flags. To save memory, I ignore this problem. +syn match sedST "[sy]" nextgroup=sedRegexp\d\+ + + +hi def link sedAddress Macro +hi def link sedACI NONE +hi def link sedBranch Label +hi def link sedComment Comment +hi def link sedDelete Function +hi def link sedError Error +hi def link sedFlag Type +hi def link sedFlagwrite Constant +hi def link sedFunction Function +hi def link sedLabel Label +hi def link sedLineCont Special +hi def link sedPutHoldspc Function +hi def link sedReplaceMeta Special +hi def link sedRegexpMeta Special +hi def link sedRW Constant +hi def link sedSemicolon Special +hi def link sedST Function +hi def link sedSpecial Special +hi def link sedWhitespace NONE +if exists("highlight_sedtabs") +hi def link sedTab Todo +endif +let __sed_i = char2nr(" ") " ASCII: 32, EBCDIC: 64 +while __sed_i <= __sed_last +exe "hi def link sedRegexp".__sed_i "Macro" +exe "hi def link sedReplacement".__sed_i "NONE" +let __sed_i = __sed_i + 1 +endwhile + + +unlet __sed_i __sed_last __sed_delimiter __sed_metacharacters + +let b:current_syntax = "sed" + +" vim: sts=4 sw=4 ts=8 + +endif diff --git a/syntax/sendpr.vim b/syntax/sendpr.vim new file mode 100644 index 0000000..ce5863b --- /dev/null +++ b/syntax/sendpr.vim @@ -0,0 +1,39 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: FreeBSD send-pr file +" Maintainer: Hendrik Scholz +" Last Change: 2012 Feb 03 +" +" http://raisdorf.net/files/misc/send-pr.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match sendprComment /^SEND-PR:/ +" email address +syn match sendprType /<[a-zA-Z0-9\-\_\.]*@[a-zA-Z0-9\-\_\.]*>/ +" ^> lines +syn match sendprString /^>[a-zA-Z\-]*:/ +syn region sendprLabel start="\[" end="\]" +syn match sendprString /^To:/ +syn match sendprString /^From:/ +syn match sendprString /^Reply-To:/ +syn match sendprString /^Cc:/ +syn match sendprString /^X-send-pr-version:/ +syn match sendprString /^X-GNATS-Notify:/ + +hi def link sendprComment Comment +hi def link sendprType Type +hi def link sendprString String +hi def link sendprLabel Label + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/sensors.vim b/syntax/sensors.vim new file mode 100644 index 0000000..f1c255a --- /dev/null +++ b/syntax/sensors.vim @@ -0,0 +1,56 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sensors.conf(5) - libsensors configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword sensorsTodo contained TODO FIXME XXX NOTE + +syn region sensorsComment display oneline start='#' end='$' + \ contains=sensorsTodo,@Spell + + +syn keyword sensorsKeyword bus chip label compute ignore set + +syn region sensorsName display oneline + \ start=+"+ skip=+\\\\\|\\"+ end=+"+ + \ contains=sensorsNameSpecial +syn match sensorsName display '\w\+' + +syn match sensorsNameSpecial display '\\["\\rnt]' + +syn match sensorsLineContinue '\\$' + +syn match sensorsNumber display '\d*.\d\+\>' + +syn match sensorsRealWorld display '@' + +syn match sensorsOperator display '[+*/-]' + +syn match sensorsDelimiter display '[()]' + +hi def link sensorsTodo Todo +hi def link sensorsComment Comment +hi def link sensorsKeyword Keyword +hi def link sensorsName String +hi def link sensorsNameSpecial SpecialChar +hi def link sensorsLineContinue Special +hi def link sensorsNumber Number +hi def link sensorsRealWorld Identifier +hi def link sensorsOperator Normal +hi def link sensorsDelimiter Normal + +let b:current_syntax = "sensors" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/services.vim b/syntax/services.vim new file mode 100644 index 0000000..0efa722 --- /dev/null +++ b/syntax/services.vim @@ -0,0 +1,58 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: services(5) - Internet network services list +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match servicesBegin display '^' + \ nextgroup=servicesName,servicesComment + +syn match servicesName contained display '[[:graph:]]\+' + \ nextgroup=servicesPort skipwhite + +syn match servicesPort contained display '\d\+' + \ nextgroup=servicesPPDiv,servicesPPDivDepr + \ skipwhite + +syn match servicesPPDiv contained display '/' + \ nextgroup=servicesProtocol skipwhite + +syn match servicesPPDivDepr contained display ',' + \ nextgroup=servicesProtocol skipwhite + +syn match servicesProtocol contained display '\S\+' + \ nextgroup=servicesAliases,servicesComment + \ skipwhite + +syn match servicesAliases contained display '\S\+' + \ nextgroup=servicesAliases,servicesComment + \ skipwhite + +syn keyword servicesTodo contained TODO FIXME XXX NOTE + +syn region servicesComment display oneline start='#' end='$' + \ contains=servicesTodo,@Spell + +hi def link servicesTodo Todo +hi def link servicesComment Comment +hi def link servicesName Identifier +hi def link servicesPort Number +hi def link servicesPPDiv Delimiter +hi def link servicesPPDivDepr Error +hi def link servicesProtocol Type +hi def link servicesAliases Macro + +let b:current_syntax = "services" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/setserial.vim b/syntax/setserial.vim new file mode 100644 index 0000000..1e7503f --- /dev/null +++ b/syntax/setserial.vim @@ -0,0 +1,124 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: setserial(8) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match setserialBegin display '^' + \ nextgroup=setserialDevice,setserialComment + \ skipwhite + +syn match setserialDevice contained display '\%(/[^ \t/]*\)\+' + \ nextgroup=setserialParameter skipwhite + +syn keyword setserialParameter contained port irq baud_base divisor + \ close_delay closing_wait rx_trigger + \ tx_trigger flow_off flow_on rx_timeout + \ nextgroup=setserialNumber skipwhite + +syn keyword setserialParameter contained uart + \ nextgroup=setserialUARTType skipwhite + +syn keyword setserialParameter contained autoconfig auto_irq skip_test + \ spd_hi spd_vhi spd_shi spd_warp spd_cust + \ spd_normal sak fourport session_lockout + \ pgrp_lockout hup_notify split_termios + \ callout_nohup low_latency + \ nextgroup=setserialParameter skipwhite + +syn match setserialParameter contained display + \ '\^\%(auto_irq\|skip_test\|sak\|fourport\)' + \ contains=setserialNegation + \ nextgroup=setserialParameter skipwhite + +syn match setserialParameter contained display + \ '\^\%(session_lockout\|pgrp_lockout\)' + \ contains=setserialNegation + \ nextgroup=setserialParameter skipwhite + +syn match setserialParameter contained display + \ '\^\%(hup_notify\|split_termios\)' + \ contains=setserialNegation + \ nextgroup=setserialParameter skipwhite + +syn match setserialParameter contained display + \ '\^\%(callout_nohup\|low_latency\)' + \ contains=setserialNegation + \ nextgroup=setserialParameter skipwhite + +syn keyword setserialParameter contained set_multiport + \ nextgroup=setserialMultiport skipwhite + +syn match setserialNumber contained display '\<\d\+\>' + \ nextgroup=setserialParameter skipwhite +syn match setserialNumber contained display '0x\x\+' + \ nextgroup=setserialParameter skipwhite + +syn keyword setserialUARTType contained none + +syn match setserialUARTType contained display + \ '8250\|16[4789]50\|16550A\=\|16650\%(V2\)\=' + \ nextgroup=setserialParameter skipwhite + +syn match setserialUARTType contained display '166[59]4' + \ nextgroup=setserialParameter skipwhite + +syn match setserialNegation contained display '\^' + +syn match setserialMultiport contained '\' + \ nextgroup=setserialPort skipwhite + +syn match setserialPort contained display '\<\d\+\>' + \ nextgroup=setserialMask skipwhite +syn match setserialPort contained display '0x\x\+' + \ nextgroup=setserialMask skipwhite + +syn match setserialMask contained '\' + \ nextgroup=setserialBitMask skipwhite + +syn match setserialBitMask contained display '\<\d\+\>' + \ nextgroup=setserialMatch skipwhite +syn match setserialBitMask contained display '0x\x\+' + \ nextgroup=setserialMatch skipwhite + +syn match setserialMatch contained '\' + \ nextgroup=setserialMatchBits skipwhite + +syn match setserialMatchBits contained display '\<\d\+\>' + \ nextgroup=setserialMultiport skipwhite +syn match setserialMatchBits contained display '0x\x\+' + \ nextgroup=setserialMultiport skipwhite + +syn keyword setserialTodo contained TODO FIXME XXX NOTE + +syn region setserialComment display oneline start='^\s*#' end='$' + \ contains=setserialTodo,@Spell + +hi def link setserialTodo Todo +hi def link setserialComment Comment +hi def link setserialDevice Normal +hi def link setserialParameter Identifier +hi def link setserialNumber Number +hi def link setserialUARTType Type +hi def link setserialNegation Operator +hi def link setserialMultiport Type +hi def link setserialPort setserialNumber +hi def link setserialMask Type +hi def link setserialBitMask setserialNumber +hi def link setserialMatch Type +hi def link setserialMatchBits setserialNumber + +let b:current_syntax = "setserial" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/sgml.vim b/syntax/sgml.vim new file mode 100644 index 0000000..3e66a9a --- /dev/null +++ b/syntax/sgml.vim @@ -0,0 +1,338 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SGML +" Maintainer: Johannes Zellner +" Last Change: Tue, 27 Apr 2004 15:05:21 CEST +" Filenames: *.sgml,*.sgm +" $Id: sgml.vim,v 1.1 2004/06/13 17:52:57 vimboss Exp $ + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:sgml_cpo_save = &cpo +set cpo&vim + +syn case match + +" mark illegal characters +syn match sgmlError "[<&]" + + +" unicode numbers: +" provide different highlithing for unicode characters +" inside strings and in plain text (character data). +" +" EXAMPLE: +" +" \u4e88 +" +syn match sgmlUnicodeNumberAttr +\\u\x\{4}+ contained contains=sgmlUnicodeSpecifierAttr +syn match sgmlUnicodeSpecifierAttr +\\u+ contained +syn match sgmlUnicodeNumberData +\\u\x\{4}+ contained contains=sgmlUnicodeSpecifierData +syn match sgmlUnicodeSpecifierData +\\u+ contained + + +" strings inside character data or comments +" +syn region sgmlString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=sgmlEntity,sgmlUnicodeNumberAttr display +syn region sgmlString contained start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=sgmlEntity,sgmlUnicodeNumberAttr display + +" punctuation (within attributes) e.g. +" ^ ^ +syn match sgmlAttribPunct +[:.]+ contained display + + +" no highlighting for sgmlEqual (sgmlEqual has no highlighting group) +syn match sgmlEqual +=+ + + +" attribute, everything before the '=' +" +" PROVIDES: @sgmlAttribHook +" +" EXAMPLE: +" +" +" ^^^^^^^^^^^^^ +" +syn match sgmlAttrib + \ +[^-'"<]\@<=\<[a-zA-Z0-9.:]\+\>\([^'">]\@=\|$\)+ + \ contained + \ contains=sgmlAttribPunct,@sgmlAttribHook + \ display + + +" UNQUOTED value (not including the '=' -- sgmlEqual) +" +" PROVIDES: @sgmlValueHook +" +" EXAMPLE: +" +" +" ^^^^^ +" +syn match sgmlValue + \ +[^"' =/!?<>][^ =/!?<>]*+ + \ contained + \ contains=sgmlEntity,sgmlUnicodeNumberAttr,@sgmlValueHook + \ display + + +" QUOTED value (not including the '=' -- sgmlEqual) +" +" PROVIDES: @sgmlValueHook +" +" EXAMPLE: +" +" +" ^^^^^^^ +" +" ^^^^^^^ +" +syn region sgmlValue contained start=+"+ skip=+\\\\\|\\"+ end=+"+ + \ contains=sgmlEntity,sgmlUnicodeNumberAttr,@sgmlValueHook +syn region sgmlValue contained start=+'+ skip=+\\\\\|\\'+ end=+'+ + \ contains=sgmlEntity,sgmlUnicodeNumberAttr,@sgmlValueHook + + +" value, everything after (and including) the '=' +" no highlighting! +" +" EXAMPLE: +" +" +" ^^^^^^^^^ +" +" ^^^^^^^ +" +syn match sgmlEqualValue + \ +=\s*[^ =/!?<>]\++ + \ contained + \ contains=sgmlEqual,sgmlString,sgmlValue + \ display + + +" start tag +" use matchgroup=sgmlTag to skip over the leading '<' +" see also sgmlEmptyTag below. +" +" PROVIDES: @sgmlTagHook +" +syn region sgmlTag + \ matchgroup=sgmlTag start=+<[^ /!?"']\@=+ + \ matchgroup=sgmlTag end=+>+ + \ contained + \ contains=sgmlError,sgmlAttrib,sgmlEqualValue,@sgmlTagHook + + +" tag content for empty tags. This is the same as sgmlTag +" above, except the `matchgroup=sgmlEndTag for highlighting +" the end '/>' differently. +" +" PROVIDES: @sgmlTagHook +" +syn region sgmlEmptyTag + \ matchgroup=sgmlTag start=+<[^ /!?"']\@=+ + \ matchgroup=sgmlEndTag end=+/>+ + \ contained + \ contains=sgmlError,sgmlAttrib,sgmlEqualValue,@sgmlTagHook + + +" end tag +" highlight everything but not the trailing '>' which +" was already highlighted by the containing sgmlRegion. +" +" PROVIDES: @sgmlTagHook +" (should we provide a separate @sgmlEndTagHook ?) +" +syn match sgmlEndTag + \ +"']\+>+ + \ contained + \ contains=@sgmlTagHook + + +" [-- SGML SPECIFIC --] + +" SGML specific +" tag content for abbreviated regions +" +" PROVIDES: @sgmlTagHook +" +syn region sgmlAbbrTag + \ matchgroup=sgmlTag start=+<[^ /!?"']\@=+ + \ matchgroup=sgmlTag end=+/+ + \ contained + \ contains=sgmlError,sgmlAttrib,sgmlEqualValue,@sgmlTagHook + + +" SGML specific +" just highlight the trailing '/' +syn match sgmlAbbrEndTag +/+ + + +" SGML specific +" abbreviated regions +" +" No highlighing, highlighing is done by contained elements. +" +" PROVIDES: @sgmlRegionHook +" +" EXAMPLE: +" +" "']\+/\_[^/]\+/+ + \ contains=sgmlAbbrTag,sgmlAbbrEndTag,sgmlCdata,sgmlComment,sgmlEntity,sgmlUnicodeNumberData,@sgmlRegionHook + +" [-- END OF SGML SPECIFIC --] + + +" real (non-empty) elements. We cannot do syntax folding +" as in xml, because end tags may be optional in sgml depending +" on the dtd. +" No highlighing, highlighing is done by contained elements. +" +" PROVIDES: @sgmlRegionHook +" +" EXAMPLE: +" +" +" +" +" +" some data +" +" +" SGML specific: +" compared to xmlRegion: +" - removed folding +" - added a single '/'in the start pattern +" +syn region sgmlRegion + \ start=+<\z([^ /!?>"']\+\)\(\(\_[^/>]*[^/!?]>\)\|>\)+ + \ end=++ + \ contains=sgmlTag,sgmlEndTag,sgmlCdata,@sgmlRegionCluster,sgmlComment,sgmlEntity,sgmlUnicodeNumberData,@sgmlRegionHook + \ keepend + \ extend + + +" empty tags. Just a container, no highlighting. +" Compare this with sgmlTag. +" +" EXAMPLE: +" +" +" +" TODO use sgmlEmptyTag intead of sgmlTag +syn match sgmlEmptyRegion + \ +<[^ /!?>"']\(\_[^"'<>]\|"\_[^"]*"\|'\_[^']*'\)*/>+ + \ contains=sgmlEmptyTag + + +" cluster which contains the above two elements +syn cluster sgmlRegionCluster contains=sgmlRegion,sgmlEmptyRegion,sgmlAbbrRegion + + +" &entities; compare with dtd +syn match sgmlEntity "&[^; \t]*;" contains=sgmlEntityPunct +syn match sgmlEntityPunct contained "[&.;]" + + +" The real comments (this implements the comments as defined by sgml, +" but not all sgml pages actually conform to it. Errors are flagged. +syn region sgmlComment start=++ contains=sgmlCommentPart,sgmlString,sgmlCommentError,sgmlTodo +syn keyword sgmlTodo contained TODO FIXME XXX display +syn match sgmlCommentError contained "[^>+ + \ contains=sgmlCdataStart,sgmlCdataEnd,@sgmlCdataHook + \ keepend + \ extend +" using the following line instead leads to corrupt folding at CDATA regions +" syn match sgmlCdata ++ contains=sgmlCdataStart,sgmlCdataEnd,@sgmlCdataHook +syn match sgmlCdataStart ++ contained + + +" Processing instructions +" This allows "?>" inside strings -- good idea? +syn region sgmlProcessing matchgroup=sgmlProcessingDelim start="" contains=sgmlAttrib,sgmlEqualValue + + +" DTD -- we use dtd.vim here +syn region sgmlDocType matchgroup=sgmlDocTypeDecl start="\c" contains=sgmlDocTypeKeyword,sgmlInlineDTD,sgmlString +syn keyword sgmlDocTypeKeyword contained DOCTYPE PUBLIC SYSTEM +syn region sgmlInlineDTD contained start="\[" end="]" contains=@sgmlDTD +syn include @sgmlDTD :p:h/dtd.vim + + +" synchronizing +" TODO !!! to be improved !!! + +syn sync match sgmlSyncDT grouphere sgmlDocType +\_.\(+ + +syn sync match sgmlSync grouphere sgmlRegion +\_.\(<[^ /!?>"']\+\)\@=+ +" syn sync match sgmlSync grouphere sgmlRegion "<[^ /!?>"']*>" +syn sync match sgmlSync groupthere sgmlRegion +"']\+>+ + +syn sync minlines=100 + + +" The default highlighting. +hi def link sgmlTodo Todo +hi def link sgmlTag Function +hi def link sgmlEndTag Identifier +" SGML specifig +hi def link sgmlAbbrEndTag Identifier +hi def link sgmlEmptyTag Function +hi def link sgmlEntity Statement +hi def link sgmlEntityPunct Type + +hi def link sgmlAttribPunct Comment +hi def link sgmlAttrib Type + +hi def link sgmlValue String +hi def link sgmlString String +hi def link sgmlComment Comment +hi def link sgmlCommentPart Comment +hi def link sgmlCommentError Error +hi def link sgmlError Error + +hi def link sgmlProcessingDelim Comment +hi def link sgmlProcessing Type + +hi def link sgmlCdata String +hi def link sgmlCdataCdata Statement +hi def link sgmlCdataStart Type +hi def link sgmlCdataEnd Type + +hi def link sgmlDocTypeDecl Function +hi def link sgmlDocTypeKeyword Statement +hi def link sgmlInlineDTD Function +hi def link sgmlUnicodeNumberAttr Number +hi def link sgmlUnicodeSpecifierAttr SpecialChar +hi def link sgmlUnicodeNumberData Number +hi def link sgmlUnicodeSpecifierData SpecialChar + +let b:current_syntax = "sgml" + +let &cpo = s:sgml_cpo_save +unlet s:sgml_cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/sgmldecl.vim b/syntax/sgmldecl.vim new file mode 100644 index 0000000..9957d56 --- /dev/null +++ b/syntax/sgmldecl.vim @@ -0,0 +1,76 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SGML (SGML Declaration ) +" Last Change: jueves, 28 de diciembre de 2000, 13:51:44 CLST +" Maintainer: "Daniel A. Molina W." +" You can modify and maintain this file, in other case send comments +" the maintainer email address. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +syn case ignore + +syn region sgmldeclDeclBlock transparent start=++ +syn region sgmldeclTagBlock transparent start=+<+ end=+>+ + \ contains=ALLBUT, + \ @sgmlTagError,@sgmlErrInTag +syn region sgmldeclComment contained start=+--+ end=+--+ + +syn keyword sgmldeclDeclKeys SGML CHARSET CAPACITY SCOPE SYNTAX + \ FEATURES + +syn keyword sgmldeclTypes BASESET DESCSET DOCUMENT NAMING DELIM + \ NAMES QUANTITY SHUNCHAR DOCTYPE + \ ELEMENT ENTITY ATTLIST NOTATION + \ TYPE + +syn keyword sgmldeclStatem CONTROLS FUNCTION NAMECASE MINIMIZE + \ LINK OTHER APPINFO REF ENTITIES + +syn keyword sgmldeclVariables TOTALCAP GRPCAP ENTCAP DATATAG OMITTAG RANK + \ SIMPLE IMPLICIT EXPLICIT CONCUR SUBDOC FORMAL ATTCAP + \ ATTCHCAP AVGRPCAP ELEMCAP ENTCHCAP IDCAP IDREFCAP + \ SHORTTAG + +syn match sgmldeclNConst contained +[0-9]\++ + +syn region sgmldeclString contained start=+"+ end=+"+ + +syn keyword sgmldeclBool YES NO + +syn keyword sgmldeclSpecial SHORTREF SGMLREF UNUSED NONE GENERAL + \ SEEALSO ANY + +syn sync lines=250 + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link sgmldeclDeclKeys Keyword +hi def link sgmldeclTypes Type +hi def link sgmldeclConst Constant +hi def link sgmldeclNConst Constant +hi def link sgmldeclString String +hi def link sgmldeclDeclBlock Normal +hi def link sgmldeclBool Boolean +hi def link sgmldeclSpecial Special +hi def link sgmldeclComment Comment +hi def link sgmldeclStatem Statement +hi def link sgmldeclVariables Type + + +let b:current_syntax = "sgmldecl" + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim:set tw=78 ts=4: + +endif diff --git a/syntax/sgmllnx.vim b/syntax/sgmllnx.vim new file mode 100644 index 0000000..d8c6f10 --- /dev/null +++ b/syntax/sgmllnx.vim @@ -0,0 +1,58 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SGML-linuxdoc (supported by old sgmltools-1.x) +" Maintainer: SungHyun Nam +" Last Change: 2013 May 13 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" tags +syn region sgmllnxEndTag start=++ contains=sgmllnxTagN,sgmllnxTagError +syn region sgmllnxTag start=+<[^/]+ end=+>+ contains=sgmllnxTagN,sgmllnxTagError +syn match sgmllnxTagN contained +<\s*[-a-zA-Z0-9]\++ms=s+1 contains=sgmllnxTagName +syn match sgmllnxTagN contained ++ +syn region sgmllnxDocType start=++ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link sgmllnxTag2 Function +hi def link sgmllnxTagN2 Function +hi def link sgmllnxTag Special +hi def link sgmllnxEndTag Special +hi def link sgmllnxParen Special +hi def link sgmllnxEntity Type +hi def link sgmllnxDocEnt Type +hi def link sgmllnxTagName Statement +hi def link sgmllnxComment Comment +hi def link sgmllnxSpecial Special +hi def link sgmllnxDocType PreProc +hi def link sgmllnxTagError Error + + +let b:current_syntax = "sgmllnx" + +" vim:set tw=78 ts=8 sts=2 sw=2 noet: + +endif diff --git a/syntax/sh.vim b/syntax/sh.vim new file mode 100644 index 0000000..ca91640 --- /dev/null +++ b/syntax/sh.vim @@ -0,0 +1,729 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: shell (sh) Korn shell (ksh) bash (sh) +" Maintainer: Charles E. Campbell +" Previous Maintainer: Lennart Schultz +" Last Change: Jan 30, 2017 +" Version: 168 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_SH +" For options and settings, please use: :help ft-sh-syntax +" This file includes many ideas from Eric Brunet (eric.brunet@ens.fr) + +" quit when a syntax file was already loaded {{{1 +if exists("b:current_syntax") + finish +endif + +" trying to answer the question: which shell is /bin/sh, really? +" If the user has not specified any of g:is_kornshell, g:is_bash, g:is_posix, g:is_sh, then guess. +if getline(1) =~ '\ fold +else + com! -nargs=* ShFoldFunctions +endif +if s:sh_fold_heredoc + com! -nargs=* ShFoldHereDoc fold +else + com! -nargs=* ShFoldHereDoc +endif +if s:sh_fold_ifdofor + com! -nargs=* ShFoldIfDoFor fold +else + com! -nargs=* ShFoldIfDoFor +endif + +" sh syntax is case sensitive {{{1 +syn case match + +" Clusters: contains=@... clusters {{{1 +"================================== +syn cluster shErrorList contains=shDoError,shIfError,shInError,shCaseError,shEsacError,shCurlyError,shParenError,shTestError,shOK +if exists("b:is_kornshell") + syn cluster ErrorList add=shDTestError +endif +syn cluster shArithParenList contains=shArithmetic,shCaseEsac,shComment,shDeref,shDo,shDerefSimple,shEcho,shEscape,shNumber,shOperator,shPosnParm,shExSingleQuote,shExDoubleQuote,shHereString,shRedir,shSingleQuote,shDoubleQuote,shStatement,shVariable,shAlias,shTest,shCtrlSeq,shSpecial,shParen,bashSpecialVariables,bashStatement,shIf,shFor +syn cluster shArithList contains=@shArithParenList,shParenError +syn cluster shCaseEsacList contains=shCaseStart,shCase,shCaseBar,shCaseIn,shComment,shDeref,shDerefSimple,shCaseCommandSub,shCaseExSingleQuote,shCaseSingleQuote,shCaseDoubleQuote,shCtrlSeq,@shErrorList,shStringSpecial,shCaseRange +syn cluster shCaseList contains=@shCommandSubList,shCaseEsac,shColon,shCommandSub,shComment,shDo,shEcho,shExpr,shFor,shHereDoc,shIf,shHereString,shRedir,shSetList,shSource,shStatement,shVariable,shCtrlSeq +syn cluster shCommandSubList contains=shAlias,shArithmetic,shComment,shCmdParenRegion,shCtrlSeq,shDeref,shDerefSimple,shDoubleQuote,shEcho,shEscape,shExDoubleQuote,shExpr,shExSingleQuote,shHereDoc,shNumber,shOperator,shOption,shPosnParm,shHereString,shRedir,shSingleQuote,shSpecial,shStatement,shSubSh,shTest,shVariable +syn cluster shCurlyList contains=shNumber,shComma,shDeref,shDerefSimple,shDerefSpecial +syn cluster shDblQuoteList contains=shCommandSub,shDeref,shDerefSimple,shEscape,shPosnParm,shCtrlSeq,shSpecial +syn cluster shDerefList contains=shDeref,shDerefSimple,shDerefVar,shDerefSpecial,shDerefWordError,shDerefPSR,shDerefPPS +syn cluster shDerefVarList contains=shDerefOff,shDerefOp,shDerefVarArray,shDerefOpError +syn cluster shEchoList contains=shArithmetic,shCommandSub,shDeref,shDerefSimple,shEscape,shExpr,shExSingleQuote,shExDoubleQuote,shSingleQuote,shDoubleQuote,shCtrlSeq,shEchoQuote +syn cluster shExprList1 contains=shCharClass,shNumber,shOperator,shExSingleQuote,shExDoubleQuote,shSingleQuote,shDoubleQuote,shExpr,shDblBrace,shDeref,shDerefSimple,shCtrlSeq +syn cluster shExprList2 contains=@shExprList1,@shCaseList,shTest +syn cluster shFunctionList contains=@shCommandSubList,shCaseEsac,shColon,shCommandSub,shComment,shDo,shEcho,shExpr,shFor,shHereDoc,shIf,shOption,shHereString,shRedir,shSetList,shSource,shStatement,shVariable,shOperator,shCtrlSeq +if exists("b:is_kornshell") || exists("b:is_bash") + syn cluster shFunctionList add=shRepeat + syn cluster shFunctionList add=shDblBrace,shDblParen +endif +syn cluster shHereBeginList contains=@shCommandSubList +syn cluster shHereList contains=shBeginHere,shHerePayload +syn cluster shHereListDQ contains=shBeginHere,@shDblQuoteList,shHerePayload +syn cluster shIdList contains=shCommandSub,shWrapLineOperator,shSetOption,shDeref,shDerefSimple,shHereString,shRedir,shExSingleQuote,shExDoubleQuote,shSingleQuote,shDoubleQuote,shExpr,shCtrlSeq,shStringSpecial,shAtExpr +syn cluster shIfList contains=@shLoopList,shDblBrace,shDblParen,shFunctionKey,shFunctionOne,shFunctionTwo +syn cluster shLoopList contains=@shCaseList,@shErrorList,shCaseEsac,shConditional,shDblBrace,shExpr,shFor,shForPP,shIf,shOption,shSet,shTest,shTestOpr,shTouch +syn cluster shPPSRightList contains=shComment,shDeref,shDerefSimple,shEscape,shPosnParm +syn cluster shSubShList contains=@shCommandSubList,shCaseEsac,shColon,shCommandSub,shComment,shDo,shEcho,shExpr,shFor,shIf,shHereString,shRedir,shSetList,shSource,shStatement,shVariable,shCtrlSeq,shOperator +syn cluster shTestList contains=shCharClass,shCommandSub,shCtrlSeq,shDeref,shDerefSimple,shDoubleQuote,shExDoubleQuote,shExpr,shExSingleQuote,shNumber,shOperator,shSingleQuote,shTest,shTestOpr + +" Echo: {{{1 +" ==== +" This one is needed INSIDE a CommandSub, so that `echo bla` be correct +syn region shEcho matchgroup=shStatement start="\" skip="\\$" matchgroup=shEchoDelim end="$" matchgroup=NONE end="[<>;&|()`]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=@shEchoList skipwhite nextgroup=shQuickComment +syn region shEcho matchgroup=shStatement start="\" skip="\\$" matchgroup=shEchoDelim end="$" matchgroup=NONE end="[<>;&|()`]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=@shEchoList skipwhite nextgroup=shQuickComment +syn match shEchoQuote contained '\%(\\\\\)*\\["`'()]' + +" This must be after the strings, so that ... \" will be correct +syn region shEmbeddedEcho contained matchgroup=shStatement start="\" skip="\\$" matchgroup=shEchoDelim end="$" matchgroup=NONE end="[<>;&|`)]"me=e-1 end="\d[<>]"me=e-2 end="\s#"me=e-2 contains=shNumber,shExSingleQuote,shSingleQuote,shDeref,shDerefSimple,shSpecialVar,shOperator,shExDoubleQuote,shDoubleQuote,shCharClass,shCtrlSeq + +" Alias: {{{1 +" ===== +if exists("b:is_kornshell") || exists("b:is_bash") + syn match shStatement "\" + syn region shAlias matchgroup=shStatement start="\\s\+\(\h[-._[:alnum:]]\+\)\@=" skip="\\$" end="\>\|`" + syn region shAlias matchgroup=shStatement start="\\s\+\(\h[-._[:alnum:]]\+=\)\@=" skip="\\$" end="=" + + " Touch: {{{1 + " ===== + syn match shTouch '\[^;#]*' skipwhite nextgroup=shComment contains=shTouchCmd,shDoubleQuote,shSingleQuote,shDeref,shDerefSimple + syn match shTouchCmd '\' contained +endif + +" Error Codes: {{{1 +" ============ +if !exists("g:sh_no_error") + syn match shDoError "\" + syn match shIfError "\" + syn match shInError "\" + syn match shCaseError ";;" + syn match shEsacError "\" + syn match shCurlyError "}" + syn match shParenError ")" + syn match shOK '\.\(done\|fi\|in\|esac\)' + if exists("b:is_kornshell") + syn match shDTestError "]]" + endif + syn match shTestError "]" +endif + +" Options: {{{1 +" ==================== +syn match shOption "\s\zs[-+][-_a-zA-Z#@]\+" +syn match shOption "\s\zs--[^ \t$`'"|);]\+" + +" File Redirection Highlighted As Operators: {{{1 +"=========================================== +syn match shRedir "\d\=>\(&[-0-9]\)\=" +syn match shRedir "\d\=>>-\=" +syn match shRedir "\d\=<\(&[-0-9]\)\=" +syn match shRedir "\d<<-\=" + +" Operators: {{{1 +" ========== +syn match shOperator "<<\|>>" contained +syn match shOperator "[!&;|]" contained +syn match shOperator "\[[[^:]\|\]]" contained +syn match shOperator "[-=/*+%]\==" skipwhite nextgroup=shPattern +syn match shPattern "\<\S\+\())\)\@=" contained contains=shExSingleQuote,shSingleQuote,shExDoubleQuote,shDoubleQuote,shDeref + +" Subshells: {{{1 +" ========== +syn region shExpr transparent matchgroup=shExprRegion start="{" end="}" contains=@shExprList2 nextgroup=shSpecialNxt +syn region shSubSh transparent matchgroup=shSubShRegion start="[^(]\zs(" end=")" contains=@shSubShList nextgroup=shSpecialNxt + +" Tests: {{{1 +"======= +syn region shExpr matchgroup=shRange start="\[" skip=+\\\\\|\\$\|\[+ end="\]" contains=@shTestList,shSpecial +syn region shTest transparent matchgroup=shStatement start="\+ end="\<;\_s*then\>" end="\" contains=@shIfList +ShFoldIfDoFor syn region shFor matchgroup=shLoop start="\#\=" +syn match shNumber "\<-\=\.\=\d\+\>#\=" +syn match shCtrlSeq "\\\d\d\d\|\\[abcfnrtv0]" contained +if exists("b:is_bash") + syn match shSpecial "[^\\]\(\\\\\)*\zs\\\o\o\o\|\\x\x\x\|\\c[^"]\|\\[abefnrtv]" contained + syn match shSpecial "^\(\\\\\)*\zs\\\o\o\o\|\\x\x\x\|\\c[^"]\|\\[abefnrtv]" contained +endif +if exists("b:is_bash") + syn region shExSingleQuote matchgroup=shQuote start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial,shSpecial nextgroup=shSpecialNxt + syn region shExDoubleQuote matchgroup=shQuote start=+\$"+ skip=+\\\\\|\\.\|\\"+ end=+"+ contains=@shDblQuoteList,shStringSpecial,shSpecial nextgroup=shSpecialNxt +elseif !exists("g:sh_no_error") + syn region shExSingleQuote matchGroup=Error start=+\$'+ skip=+\\\\\|\\.+ end=+'+ contains=shStringSpecial + syn region shExDoubleQuote matchGroup=Error start=+\$"+ skip=+\\\\\|\\.+ end=+"+ contains=shStringSpecial +endif +syn region shSingleQuote matchgroup=shQuote start=+'+ end=+'+ contains=@Spell +syn region shDoubleQuote matchgroup=shQuote start=+\%(\%(\\\\\)*\\\)\@" +else + syn keyword shTodo contained COMBAK FIXME TODO XXX +endif +syn match shComment "^\s*\zs#.*$" contains=@shCommentGroup +syn match shComment "\s\zs#.*$" contains=@shCommentGroup +syn match shComment contained "#.*$" contains=@shCommentGroup +syn match shQuickComment contained "#.*$" + +" Here Documents: {{{1 +" ========================================= +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc01 start="<<\s*\\\=\z([^ \t|>]\+\)" matchgroup=shHereDoc01 end="^\z1\s*$" contains=@shDblQuoteList +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc02 start="<<\s*\"\z([^ \t|>]\+\)\"" matchgroup=shHereDoc02 end="^\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc03 start="<<-\s*\z([^ \t|>]\+\)" matchgroup=shHereDoc03 end="^\s*\z1\s*$" contains=@shDblQuoteList +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc04 start="<<-\s*'\z([^ \t|>]\+\)'" matchgroup=shHereDoc04 end="^\s*\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc05 start="<<\s*'\z([^ \t|>]\+\)'" matchgroup=shHereDoc05 end="^\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc06 start="<<-\s*\"\z([^ \t|>]\+\)\"" matchgroup=shHereDoc06 end="^\s*\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc07 start="<<\s*\\\_$\_s*\z([^ \t|>]\+\)" matchgroup=shHereDoc07 end="^\z1\s*$" contains=@shDblQuoteList +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc08 start="<<\s*\\\_$\_s*'\z([^ \t|>]\+\)'" matchgroup=shHereDoc08 end="^\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc09 start="<<\s*\\\_$\_s*\"\z([^ \t|>]\+\)\"" matchgroup=shHereDoc09 end="^\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc10 start="<<-\s*\\\_$\_s*\z([^ \t|>]\+\)" matchgroup=shHereDoc10 end="^\s*\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc11 start="<<-\s*\\\_$\_s*\\\z([^ \t|>]\+\)" matchgroup=shHereDoc11 end="^\s*\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc12 start="<<-\s*\\\_$\_s*'\z([^ \t|>]\+\)'" matchgroup=shHereDoc12 end="^\s*\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc13 start="<<-\s*\\\_$\_s*\"\z([^ \t|>]\+\)\"" matchgroup=shHereDoc13 end="^\s*\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc14 start="<<\\\z([^ \t|>]\+\)" matchgroup=shHereDoc14 end="^\z1\s*$" +ShFoldHereDoc syn region shHereDoc matchgroup=shHereDoc15 start="<<-\s*\\\z([^ \t|>]\+\)" matchgroup=shHereDoc15 end="^\s*\z1\s*$" + +" Here Strings: {{{1 +" ============= +" available for: bash; ksh (really should be ksh93 only) but not if its a posix +if exists("b:is_bash") || (exists("b:is_kornshell") && !exists("b:is_posix")) + syn match shHereString "<<<" skipwhite nextgroup=shCmdParenRegion +endif + +" Identifiers: {{{1 +"============= +syn match shSetOption "\s\zs[-+][a-zA-Z0-9]\+\>" contained +syn match shVariable "\<\([bwglsav]:\)\=[a-zA-Z0-9.!@_%+,]*\ze=" nextgroup=shVarAssign +syn match shVarAssign "=" contained nextgroup=shCmdParenRegion,shPattern,shDeref,shDerefSimple,shDoubleQuote,shExDoubleQuote,shSingleQuote,shExSingleQuote +syn region shAtExpr contained start="@(" end=")" contains=@shIdList +if exists("b:is_bash") + syn region shSetList oneline matchgroup=shSet start="\<\(declare\|typeset\|local\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+#\|=" contains=@shIdList + syn region shSetList oneline matchgroup=shSet start="\\ze[^/]" end="\ze[;|)]\|$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+=" contains=@shIdList +elseif exists("b:is_kornshell") + syn region shSetList oneline matchgroup=shSet start="\<\(typeset\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList + syn region shSetList oneline matchgroup=shSet start="\\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList +else + syn region shSetList oneline matchgroup=shSet start="\<\(set\|export\|unset\)\>\ze[^/]" end="$" matchgroup=shSetListDelim end="\ze[}|);&]" matchgroup=NONE end="\ze\s\+[#=]" contains=@shIdList +endif + +" Functions: {{{1 +if !exists("b:is_posix") + syn keyword shFunctionKey function skipwhite skipnl nextgroup=shFunctionTwo +endif + +if exists("b:is_bash") + ShFoldFunctions syn region shFunctionOne matchgroup=shFunction start="^\s*[A-Za-z_0-9:][-a-zA-Z_0-9:]*\s*()\_s*{" end="}" contains=@shFunctionList skipwhite skipnl nextgroup=shFunctionStart,shQuickComment + ShFoldFunctions syn region shFunctionTwo matchgroup=shFunction start="\%(do\)\@!\&\<[A-Za-z_0-9:][-a-zA-Z_0-9:]*\>\s*\%(()\)\=\_s*{" end="}" contains=shFunctionKey,@shFunctionList contained skipwhite skipnl nextgroup=shFunctionStart,shQuickComment + ShFoldFunctions syn region shFunctionThree matchgroup=shFunction start="^\s*[A-Za-z_0-9:][-a-zA-Z_0-9:]*\s*()\_s*(" end=")" contains=@shFunctionList skipwhite skipnl nextgroup=shFunctionStart,shQuickComment + ShFoldFunctions syn region shFunctionFour matchgroup=shFunction start="\%(do\)\@!\&\<[A-Za-z_0-9:][-a-zA-Z_0-9:]*\>\s*\%(()\)\=\_s*)" end=")" contains=shFunctionKey,@shFunctionList contained skipwhite skipnl nextgroup=shFunctionStart,shQuickComment +else + ShFoldFunctions syn region shFunctionOne matchgroup=shFunction start="^\s*\h\w*\s*()\_s*{" end="}" contains=@shFunctionList skipwhite skipnl nextgroup=shFunctionStart,shQuickComment + ShFoldFunctions syn region shFunctionTwo matchgroup=shFunction start="\%(do\)\@!\&\<\h\w*\>\s*\%(()\)\=\_s*{" end="}" contains=shFunctionKey,@shFunctionList contained skipwhite skipnl nextgroup=shFunctionStart,shQuickComment + ShFoldFunctions syn region shFunctionThree matchgroup=shFunction start="^\s*\h\w*\s*()\_s*(" end=")" contains=@shFunctionList skipwhite skipnl nextgroup=shFunctionStart,shQuickComment + ShFoldFunctions syn region shFunctionFour matchgroup=shFunction start="\%(do\)\@!\&\<\h\w*\>\s*\%(()\)\=\_s*(" end=")" contains=shFunctionKey,@shFunctionList contained skipwhite skipnl nextgroup=shFunctionStart,shQuickComment +endif + +" Parameter Dereferencing: {{{1 +" ======================== +if !exists("g:sh_no_error") + syn match shDerefWordError "[^}$[~]" contained +endif +syn match shDerefSimple "\$\%(\h\w*\|\d\)" +syn region shDeref matchgroup=PreProc start="\${" end="}" contains=@shDerefList,shDerefVarArray +syn match shDerefSimple "\$[-#*@!?]" +syn match shDerefSimple "\$\$" +syn match shDerefSimple "\${\d}" +if exists("b:is_bash") || exists("b:is_kornshell") + syn region shDeref matchgroup=PreProc start="\${##\=" end="}" contains=@shDerefList + syn region shDeref matchgroup=PreProc start="\${\$\$" end="}" contains=@shDerefList +endif + +" ksh: ${!var[*]} array index list syntax: {{{1 +" ======================================== +if exists("b:is_kornshell") + syn region shDeref matchgroup=PreProc start="\${!" end="}" contains=@shDerefVarArray +endif + +" bash: ${!prefix*} and ${#parameter}: {{{1 +" ==================================== +if exists("b:is_bash") + syn region shDeref matchgroup=PreProc start="\${!" end="\*\=}" contains=@shDerefList,shDerefOff + syn match shDerefVar contained "{\@<=!\h\w*" nextgroup=@shDerefVarList +endif +if exists("b:is_kornshell") + syn match shDerefVar contained "{\@<=!\h\w*[[:alnum:]_.]*" nextgroup=@shDerefVarList +endif + +syn match shDerefSpecial contained "{\@<=[-*@?0]" nextgroup=shDerefOp,shDerefOpError +syn match shDerefSpecial contained "\({[#!]\)\@<=[[:alnum:]*@_]\+" nextgroup=@shDerefVarList,shDerefOp +syn match shDerefVar contained "{\@<=\h\w*" nextgroup=@shDerefVarList +syn match shDerefVar contained '\d' nextgroup=@shDerefVarList +if exists("b:is_kornshell") + syn match shDerefVar contained "{\@<=\h\w*[[:alnum:]_.]*" nextgroup=@shDerefVarList +endif + +" sh ksh bash : ${var[... ]...} array reference: {{{1 +syn region shDerefVarArray contained matchgroup=shDeref start="\[" end="]" contains=@shCommandSubList nextgroup=shDerefOp,shDerefOpError + +" Special ${parameter OPERATOR word} handling: {{{1 +" sh ksh bash : ${parameter:-word} word is default value +" sh ksh bash : ${parameter:=word} assign word as default value +" sh ksh bash : ${parameter:?word} display word if parameter is null +" sh ksh bash : ${parameter:+word} use word if parameter is not null, otherwise nothing +" ksh bash : ${parameter#pattern} remove small left pattern +" ksh bash : ${parameter##pattern} remove large left pattern +" ksh bash : ${parameter%pattern} remove small right pattern +" ksh bash : ${parameter%%pattern} remove large right pattern +" bash : ${parameter^pattern} Case modification +" bash : ${parameter^^pattern} Case modification +" bash : ${parameter,pattern} Case modification +" bash : ${parameter,,pattern} Case modification +syn cluster shDerefPatternList contains=shDerefPattern,shDerefString +if !exists("g:sh_no_error") + syn match shDerefOpError contained ":[[:punct:]]" +endif +syn match shDerefOp contained ":\=[-=?]" nextgroup=@shDerefPatternList +syn match shDerefOp contained ":\=+" nextgroup=@shDerefPatternList +if exists("b:is_bash") || exists("b:is_kornshell") + syn match shDerefOp contained "#\{1,2}" nextgroup=@shDerefPatternList + syn match shDerefOp contained "%\{1,2}" nextgroup=@shDerefPatternList + syn match shDerefPattern contained "[^{}]\+" contains=shDeref,shDerefSimple,shDerefPattern,shDerefString,shCommandSub,shDerefEscape nextgroup=shDerefPattern + syn region shDerefPattern contained start="{" end="}" contains=shDeref,shDerefSimple,shDerefString,shCommandSub nextgroup=shDerefPattern + syn match shDerefEscape contained '\%(\\\\\)*\\.' +endif +if exists("b:is_bash") + syn match shDerefOp contained "[,^]\{1,2}" nextgroup=@shDerefPatternList +endif +syn region shDerefString contained matchgroup=shDerefDelim start=+\%(\\\)\@" +syn sync match shCaseEsacSync groupthere shCaseEsac "\" +syn sync match shDoSync grouphere shDo "\" +syn sync match shDoSync groupthere shDo "\" +syn sync match shForSync grouphere shFor "\" +syn sync match shForSync groupthere shFor "\" +syn sync match shIfSync grouphere shIf "\" +syn sync match shIfSync groupthere shIf "\" +syn sync match shUntilSync grouphere shRepeat "\" +syn sync match shWhileSync grouphere shRepeat "\" + +" Default Highlighting: {{{1 +" ===================== +if !exists("skip_sh_syntax_inits") + hi def link shArithRegion shShellVariables + hi def link shAstQuote shDoubleQuote + hi def link shAtExpr shSetList + hi def link shBeginHere shRedir + hi def link shCaseBar shConditional + hi def link shCaseCommandSub shCommandSub + hi def link shCaseDoubleQuote shDoubleQuote + hi def link shCaseIn shConditional + hi def link shQuote shOperator + hi def link shCaseSingleQuote shSingleQuote + hi def link shCaseStart shConditional + hi def link shCmdSubRegion shShellVariables + hi def link shColon shComment + hi def link shDerefOp shOperator + hi def link shDerefPOL shDerefOp + hi def link shDerefPPS shDerefOp + hi def link shDerefPSR shDerefOp + hi def link shDeref shShellVariables + hi def link shDerefDelim shOperator + hi def link shDerefSimple shDeref + hi def link shDerefSpecial shDeref + hi def link shDerefString shDoubleQuote + hi def link shDerefVar shDeref + hi def link shDoubleQuote shString + hi def link shEcho shString + hi def link shEchoDelim shOperator + hi def link shEchoQuote shString + hi def link shForPP shLoop + hi def link shFunction Function + hi def link shEmbeddedEcho shString + hi def link shEscape shCommandSub + hi def link shExDoubleQuote shDoubleQuote + hi def link shExSingleQuote shSingleQuote + hi def link shHereDoc shString + hi def link shHereString shRedir + hi def link shHerePayload shHereDoc + hi def link shLoop shStatement + hi def link shSpecialNxt shSpecial + hi def link shNoQuote shDoubleQuote + hi def link shOption shCommandSub + hi def link shPattern shString + hi def link shParen shArithmetic + hi def link shPosnParm shShellVariables + hi def link shQuickComment shComment + hi def link shRange shOperator + hi def link shRedir shOperator + hi def link shSetListDelim shOperator + hi def link shSetOption shOption + hi def link shSingleQuote shString + hi def link shSource shOperator + hi def link shStringSpecial shSpecial + hi def link shSubShRegion shOperator + hi def link shTestOpr shConditional + hi def link shTestPattern shString + hi def link shTestDoubleQuote shString + hi def link shTestSingleQuote shString + hi def link shTouchCmd shStatement + hi def link shVariable shSetList + hi def link shWrapLineOperator shOperator + + if exists("b:is_bash") + hi def link bashAdminStatement shStatement + hi def link bashSpecialVariables shShellVariables + hi def link bashStatement shStatement + hi def link shCharClass shSpecial + hi def link shDerefOff shDerefOp + hi def link shDerefLen shDerefOff + endif + if exists("b:is_kornshell") + hi def link kshSpecialVariables shShellVariables + hi def link kshStatement shStatement + endif + + if !exists("g:sh_no_error") + hi def link shCaseError Error + hi def link shCondError Error + hi def link shCurlyError Error + hi def link shDerefOpError Error + hi def link shDerefWordError Error + hi def link shDoError Error + hi def link shEsacError Error + hi def link shIfError Error + hi def link shInError Error + hi def link shParenError Error + hi def link shTestError Error + if exists("b:is_kornshell") + hi def link shDTestError Error + endif + endif + + hi def link shArithmetic Special + hi def link shCharClass Identifier + hi def link shSnglCase Statement + hi def link shCommandSub Special + hi def link shComment Comment + hi def link shConditional Conditional + hi def link shCtrlSeq Special + hi def link shExprRegion Delimiter + hi def link shFunctionKey Function + hi def link shFunctionName Function + hi def link shNumber Number + hi def link shOperator Operator + hi def link shRepeat Repeat + hi def link shSet Statement + hi def link shSetList Identifier + hi def link shShellVariables PreProc + hi def link shSpecial Special + hi def link shStatement Statement + hi def link shString String + hi def link shTodo Todo + hi def link shAlias Identifier + hi def link shHereDoc01 shRedir + hi def link shHereDoc02 shRedir + hi def link shHereDoc03 shRedir + hi def link shHereDoc04 shRedir + hi def link shHereDoc05 shRedir + hi def link shHereDoc06 shRedir + hi def link shHereDoc07 shRedir + hi def link shHereDoc08 shRedir + hi def link shHereDoc09 shRedir + hi def link shHereDoc10 shRedir + hi def link shHereDoc11 shRedir + hi def link shHereDoc12 shRedir + hi def link shHereDoc13 shRedir + hi def link shHereDoc14 shRedir + hi def link shHereDoc15 shRedir +endif + +" Delete shell folding commands {{{1 +" ============================= +delc ShFoldFunctions +delc ShFoldHereDoc +delc ShFoldIfDoFor + +" Set Current Syntax: {{{1 +" =================== +if exists("b:is_bash") + let b:current_syntax = "bash" +elseif exists("b:is_kornshell") + let b:current_syntax = "ksh" +else + let b:current_syntax = "sh" +endif + +" vim: ts=16 fdm=marker + +endif diff --git a/syntax/sicad.vim b/syntax/sicad.vim new file mode 100644 index 0000000..e8e4344 --- /dev/null +++ b/syntax/sicad.vim @@ -0,0 +1,394 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SiCAD (procedure language) +" Maintainer: Zsolt Branyiczky +" Last Change: 2003 May 11 +" URL: http://lmark.mgx.hu:81/download/vim/sicad.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" use SQL highlighting after 'sql' command +syn include @SQL syntax/sql.vim +unlet b:current_syntax + +" spaces are used in (auto)indents since sicad hates tabulator characters +setlocal expandtab + +" ignore case +syn case ignore + +" most important commands - not listed by ausku +syn keyword sicadStatement define +syn keyword sicadStatement dialog +syn keyword sicadStatement do +syn keyword sicadStatement dop contained +syn keyword sicadStatement end +syn keyword sicadStatement enddo +syn keyword sicadStatement endp +syn keyword sicadStatement erroff +syn keyword sicadStatement erron +syn keyword sicadStatement exitp +syn keyword sicadGoto goto contained +syn keyword sicadStatement hh +syn keyword sicadStatement if +syn keyword sicadStatement in +syn keyword sicadStatement msgsup +syn keyword sicadStatement out +syn keyword sicadStatement padd +syn keyword sicadStatement parbeg +syn keyword sicadStatement parend +syn keyword sicadStatement pdoc +syn keyword sicadStatement pprot +syn keyword sicadStatement procd +syn keyword sicadStatement procn +syn keyword sicadStatement psav +syn keyword sicadStatement psel +syn keyword sicadStatement psymb +syn keyword sicadStatement ptrace +syn keyword sicadStatement ptstat +syn keyword sicadStatement set +syn keyword sicadStatement sql contained +syn keyword sicadStatement step +syn keyword sicadStatement sys +syn keyword sicadStatement ww + +" functions +syn match sicadStatement "\"me=s+1 +syn match sicadStatement "\"me=s+1 + +" logical operators +syn match sicadOperator "\.and\." +syn match sicadOperator "\.ne\." +syn match sicadOperator "\.not\." +syn match sicadOperator "\.eq\." +syn match sicadOperator "\.ge\." +syn match sicadOperator "\.gt\." +syn match sicadOperator "\.le\." +syn match sicadOperator "\.lt\." +syn match sicadOperator "\.or\." +syn match sicadOperator "\.eqv\." +syn match sicadOperator "\.neqv\." + +" variable name +syn match sicadIdentifier "%g\=[irpt][0-9]\{1,2}\>" +syn match sicadIdentifier "%g\=l[0-9]\>" +syn match sicadIdentifier "%g\=[irptl]("me=e-1 +syn match sicadIdentifier "%error\>" +syn match sicadIdentifier "%nsel\>" +syn match sicadIdentifier "%nvar\>" +syn match sicadIdentifier "%scl\>" +syn match sicadIdentifier "%wd\>" +syn match sicadIdentifier "\$[irt][0-9]\{1,2}\>" contained + +" label +syn match sicadLabel1 "^ *\.[a-z][a-z0-9]\{0,7} \+[^ ]"me=e-1 +syn match sicadLabel1 "^ *\.[a-z][a-z0-9]\{0,7}\*"me=e-1 +syn match sicadLabel2 "\" contains=sicadGoto +syn match sicadLabel2 "\" contains=sicadGoto + +" boolean +syn match sicadBoolean "\.[ft]\." +" integer without sign +syn match sicadNumber "\<[0-9]\+\>" +" floating point number, with dot, optional exponent +syn match sicadFloat "\<[0-9]\+\.[0-9]*\(e[-+]\=[0-9]\+\)\=\>" +" floating point number, starting with a dot, optional exponent +syn match sicadFloat "\.[0-9]\+\(e[-+]\=[0-9]\+\)\=\>" +" floating point number, without dot, with exponent +syn match sicadFloat "\<[0-9]\+e[-+]\=[0-9]\+\>" + +" without this extraString definition a ' ; ' could stop the comment +syn region sicadString_ transparent start=+'+ end=+'+ oneline contained +" string +syn region sicadString start=+'+ end=+'+ oneline + +" comments - nasty ones in sicad + +" - ' * blabla' or ' * blabla;' +syn region sicadComment start="^ *\*" skip='\\ *$' end=";"me=e-1 end="$" contains=sicadString_ +" - ' .LABEL03 * blabla' or ' .LABEL03 * blabla;' +syn region sicadComment start="^ *\.[a-z][a-z0-9]\{0,7} *\*" skip='\\ *$' end=";"me=e-1 end="$" contains=sicadLabel1,sicadString_ +" - '; * blabla' or '; * blabla;' +syn region sicadComment start="; *\*"ms=s+1 skip='\\ *$' end=";"me=e-1 end="$" contains=sicadString_ +" - comments between docbeg and docend +syn region sicadComment matchgroup=sicadStatement start="\" end="\" + +" catch \ at the end of line +syn match sicadLineCont "\\ *$" + +" parameters in dop block - for the time being it is not used +"syn match sicadParameter " [a-z][a-z0-9]*[=:]"me=e-1 contained +" dop block - for the time being it is not used +syn region sicadDopBlock transparent matchgroup=sicadStatement start='\' skip='\\ *$' end=';'me=e-1 end='$' contains=ALL + +" sql block - new highlighting mode is used (see syn include) +syn region sicadSqlBlock transparent matchgroup=sicadStatement start='\' skip='\\ *$' end=';'me=e-1 end='$' contains=@SQL,sicadIdentifier,sicadLineCont + +" synchronizing +syn sync clear " clear sync used in sql.vim +syn sync match sicadSyncComment groupthere NONE "\" +syn sync match sicadSyncComment grouphere sicadComment "\" +" next line must be examined too +syn sync linecont "\\ *$" + +" catch error caused by tabulator key +syn match sicadError "\t" +" catch errors caused by wrong parenthesis +"syn region sicadParen transparent start='(' end=')' contains=ALLBUT,sicadParenError +syn region sicadParen transparent start='(' skip='\\ *$' end=')' end='$' contains=ALLBUT,sicadParenError +syn match sicadParenError ')' +"syn region sicadApostrophe transparent start=+'+ end=+'+ contains=ALLBUT,sicadApostropheError +"syn match sicadApostropheError +'+ +" not closed apostrophe +"syn region sicadError start=+'+ end=+$+ contains=ALLBUT,sicadApostropheError +"syn match sicadApostropheError +'[^']*$+me=s+1 contained + +" SICAD keywords +syn keyword sicadStatement abst add addsim adrin aib +syn keyword sicadStatement aibzsn aidump aifgeo aisbrk alknam +syn keyword sicadStatement alknr alksav alksel alktrc alopen +syn keyword sicadStatement ansbo aractiv ararea arareao ararsfs +syn keyword sicadStatement arbuffer archeck arcomv arcont arconv +syn keyword sicadStatement arcopy arcopyo arcorr arcreate arerror +syn keyword sicadStatement areval arflfm arflop arfrast argbkey +syn keyword sicadStatement argenf argraph argrapho arinters arkompfl +syn keyword sicadStatement arlasso arlcopy arlgraph arline arlining +syn keyword sicadStatement arlisly armakea armemo arnext aroverl +syn keyword sicadStatement arovers arparkmd arpars arrefp arselect +syn keyword sicadStatement arset arstruct arunify arupdate arvector +syn keyword sicadStatement arveinfl arvflfl arvoroni ausku basis +syn keyword sicadStatement basisaus basisdar basisnr bebos befl +syn keyword sicadStatement befla befli befls beo beorta +syn keyword sicadStatement beortn bep bepan bepap bepola +syn keyword sicadStatement bepoln bepsn bepsp ber berili +syn keyword sicadStatement berk bewz bkl bli bma +syn keyword sicadStatement bmakt bmakts bmbm bmerk bmerw +syn keyword sicadStatement bmerws bminit bmk bmorth bmos +syn keyword sicadStatement bmoss bmpar bmsl bmsum bmsums +syn keyword sicadStatement bmver bmvero bmw bo bta +syn keyword sicadStatement buffer bvl bw bza bzap +syn keyword sicadStatement bzd bzgera bzorth cat catel +syn keyword sicadStatement cdbdiff ce cgmparam close closesim +syn keyword sicadStatement comgener comp comp conclose conclose coninfo +syn keyword sicadStatement conopen conread contour conwrite cop +syn keyword sicadStatement copar coparp coparp2 copel cr +syn keyword sicadStatement cs cstat cursor d da +syn keyword sicadStatement dal dasp dasps dataout dcol +syn keyword sicadStatement dd defsr del delel deskrdef +syn keyword sicadStatement df dfn dfns dfpos dfr +syn keyword sicadStatement dgd dgm dgp dgr dh +syn keyword sicadStatement diag diaus dir disbsd dkl +syn keyword sicadStatement dktx dkur dlgfix dlgfre dma +syn keyword sicadStatement dprio dr druse dsel dskinfo +syn keyword sicadStatement dsr dv dve eba ebd +syn keyword sicadStatement ebdmod ebs edbsdbin edbssnin edbsvtin +syn keyword sicadStatement edt egaus egdef egdefs eglist +syn keyword sicadStatement egloe egloenp egloes egxx eib +syn keyword sicadStatement ekur ekuradd elel elpos epg +syn keyword sicadStatement esau esauadd esek eta etap +syn keyword sicadStatement etav feparam ficonv filse fl +syn keyword sicadStatement fli flin flini flinit flins +syn keyword sicadStatement flkor fln flnli flop flout +syn keyword sicadStatement flowert flparam flraster flsy flsyd +syn keyword sicadStatement flsym flsyms flsymt fmtatt fmtdia +syn keyword sicadStatement fmtlib fpg gbadddb gbaim gbanrs +syn keyword sicadStatement gbatw gbau gbaudit gbclosp gbcredic +syn keyword sicadStatement gbcreem gbcreld gbcresdb gbcretd gbde +syn keyword sicadStatement gbdeldb gbdeldic gbdelem gbdelld gbdelref +syn keyword sicadStatement gbdeltd gbdisdb gbdisem gbdisld gbdistd +syn keyword sicadStatement gbebn gbemau gbepsv gbgetdet gbgetes +syn keyword sicadStatement gbgetmas gbgqel gbgqelr gbgqsa gbgrant +syn keyword sicadStatement gbimpdic gbler gblerb gblerf gbles +syn keyword sicadStatement gblocdic gbmgmg gbmntdb gbmoddb gbnam +syn keyword sicadStatement gbneu gbopenp gbpoly gbpos gbpruef +syn keyword sicadStatement gbpruefg gbps gbqgel gbqgsa gbrefdic +syn keyword sicadStatement gbreftab gbreldic gbresem gbrevoke gbsav +syn keyword sicadStatement gbsbef gbsddk gbsicu gbsrt gbss +syn keyword sicadStatement gbstat gbsysp gbszau gbubp gbueb +syn keyword sicadStatement gbunmdb gbuseem gbw gbweg gbwieh +syn keyword sicadStatement gbzt gelp gera getvar hgw +syn keyword sicadStatement hpg hr0 hra hrar icclchan +syn keyword sicadStatement iccrecon icdescon icfree icgetcon icgtresp +syn keyword sicadStatement icopchan icputcon icreacon icreqd icreqnw +syn keyword sicadStatement icreqw icrespd icresrve icwricon imsget +syn keyword sicadStatement imsgqel imsmget imsplot imsprint inchk +syn keyword sicadStatement inf infd inst kbml kbmls +syn keyword sicadStatement kbmm kbmms kbmt kbmtdps kbmts +syn keyword sicadStatement khboe khbol khdob khe khetap +syn keyword sicadStatement khfrw khktk khlang khld khmfrp +syn keyword sicadStatement khmks khms khpd khpfeil khpl +syn keyword sicadStatement khprofil khrand khsa khsabs khsaph +syn keyword sicadStatement khsd khsdl khse khskbz khsna +syn keyword sicadStatement khsnum khsob khspos khsvph khtrn +syn keyword sicadStatement khver khzpe khzpl kib kldat +syn keyword sicadStatement klleg klsch klsym klvert kmpg +syn keyword sicadStatement kmtlage kmtp kmtps kodef kodefp +syn keyword sicadStatement kodefs kok kokp kolae kom +syn keyword sicadStatement kontly kopar koparp kopg kosy +syn keyword sicadStatement kp kr krsek krtclose krtopen +syn keyword sicadStatement ktk lad lae laesel language +syn keyword sicadStatement lasso lbdes lcs ldesk ldesks +syn keyword sicadStatement le leak leattdes leba lebas +syn keyword sicadStatement lebaznp lebd lebm lebv lebvaus +syn keyword sicadStatement lebvlist lede ledel ledepo ledepol +syn keyword sicadStatement ledepos leder ledist ledm lee +syn keyword sicadStatement leeins lees lege lekr lekrend +syn keyword sicadStatement lekwa lekwas lel lelh lell +syn keyword sicadStatement lelp lem lena lend lenm +syn keyword sicadStatement lep lepe lepee lepko lepl +syn keyword sicadStatement lepmko lepmkop lepos leposm leqs +syn keyword sicadStatement leqsl leqssp leqsv leqsvov les +syn keyword sicadStatement lesch lesr less lestd let +syn keyword sicadStatement letaum letl lev levm levtm +syn keyword sicadStatement levtp levtr lew lewm lexx +syn keyword sicadStatement lfs li lining lldes lmode +syn keyword sicadStatement loedk loepkt lop lose loses +syn keyword sicadStatement lp lppg lppruef lr ls +syn keyword sicadStatement lsop lsta lstat ly lyaus +syn keyword sicadStatement lz lza lzae lzbz lze +syn keyword sicadStatement lznr lzo lzpos ma ma0 +syn keyword sicadStatement ma1 mad map mapoly mcarp +syn keyword sicadStatement mccfr mccgr mcclr mccrf mcdf +syn keyword sicadStatement mcdma mcdr mcdrp mcdve mcebd +syn keyword sicadStatement mcgse mcinfo mcldrp md me +syn keyword sicadStatement mefd mefds minmax mipg ml +syn keyword sicadStatement mmcmdme mmdbf mmdellb mmdir mmdome +syn keyword sicadStatement mmfsb mminfolb mmlapp mmlbf mmlistlb +syn keyword sicadStatement mmloadcm mmmsg mmreadlb mmsetlb mmshowcm +syn keyword sicadStatement mmstatme mnp mpo mr mra +syn keyword sicadStatement ms msav msgout msgsnd msp +syn keyword sicadStatement mspf mtd nasel ncomp new +syn keyword sicadStatement nlist nlistlt nlistly nlistnp nlistpo +syn keyword sicadStatement np npa npdes npe npem +syn keyword sicadStatement npinfa npruef npsat npss npssa +syn keyword sicadStatement ntz oa oan odel odf +syn keyword sicadStatement odfx oj oja ojaddsk ojaed +syn keyword sicadStatement ojaeds ojaef ojaefs ojaen ojak +syn keyword sicadStatement ojaks ojakt ojakz ojalm ojatkis +syn keyword sicadStatement ojatt ojatw ojbsel ojcasel ojckon +syn keyword sicadStatement ojde ojdtl ojeb ojebd ojel +syn keyword sicadStatement ojelpas ojesb ojesbd ojex ojezge +syn keyword sicadStatement ojko ojlb ojloe ojlsb ojmerk +syn keyword sicadStatement ojmos ojnam ojpda ojpoly ojprae +syn keyword sicadStatement ojs ojsak ojsort ojstrukt ojsub +syn keyword sicadStatement ojtdef ojvek ojx old oldd +syn keyword sicadStatement op opa opa1 open opensim +syn keyword sicadStatement opnbsd orth osanz ot otp +syn keyword sicadStatement otrefp param paranf pas passw +syn keyword sicadStatement pcatchf pda pdadd pg pg0 +syn keyword sicadStatement pgauf pgaufsel pgb pgko pgm +syn keyword sicadStatement pgr pgvs pily pkpg plot +syn keyword sicadStatement plotf plotfr pmap pmdata pmdi +syn keyword sicadStatement pmdp pmeb pmep pminfo pmlb +syn keyword sicadStatement pmli pmlp pmmod pnrver poa +syn keyword sicadStatement pos posa posaus post printfr +syn keyword sicadStatement protect prs prssy prsym ps +syn keyword sicadStatement psadd psclose psopen psparam psprw +syn keyword sicadStatement psres psstat psw pswr qualif +syn keyword sicadStatement rahmen raster rasterd rbbackup rbchang2 +syn keyword sicadStatement rbchange rbcmd rbcoldst rbcolor rbcopy +syn keyword sicadStatement rbcut rbcut2 rbdbcl rbdbload rbdbop +syn keyword sicadStatement rbdbwin rbdefs rbedit rbfdel rbfill +syn keyword sicadStatement rbfill2 rbfload rbfload2 rbfnew rbfnew2 +syn keyword sicadStatement rbfpar rbfree rbg rbgetcol rbgetdst +syn keyword sicadStatement rbinfo rbpaste rbpixel rbrstore rbsnap +syn keyword sicadStatement rbsta rbtile rbtrpix rbvtor rcol +syn keyword sicadStatement rd rdchange re reb rebmod +syn keyword sicadStatement refunc ren renel rk rkpos +syn keyword sicadStatement rohr rohrpos rpr rr rr0 +syn keyword sicadStatement rra rrar rs samtosdb sav +syn keyword sicadStatement savd savesim savx scol scopy +syn keyword sicadStatement scopye sdbtosam sddk sdwr se +syn keyword sicadStatement selaus selpos seman semi sesch +syn keyword sicadStatement setscl setvar sfclntpf sfconn sffetchf +syn keyword sicadStatement sffpropi sfftypi sfqugeoc sfquwhcl sfself +syn keyword sicadStatement sfstat sftest sge sid sie +syn keyword sicadStatement sig sigp skk skks sn +syn keyword sicadStatement sn21 snpa snpar snparp snparps +syn keyword sicadStatement snpars snpas snpd snpi snpkor +syn keyword sicadStatement snpl snpm sob sob0 sobloe +syn keyword sicadStatement sobs sof sop split spr +syn keyword sicadStatement sqdadd sqdlad sqdold sqdsav +syn keyword sicadStatement sr sres srt sset stat +syn keyword sicadStatement stdtxt string strukt strupru suinfl +syn keyword sicadStatement suinflk suinfls supo supo1 sva +syn keyword sicadStatement svr sy sya syly sysout +syn keyword sicadStatement syu syux taa tabeg tabl +syn keyword sicadStatement tabm tam tanr tapg tapos +syn keyword sicadStatement tarkd tas tase tb tbadd +syn keyword sicadStatement tbd tbext tbget tbint tbout +syn keyword sicadStatement tbput tbsat tbsel tbstr tcaux +syn keyword sicadStatement tccable tcchkrep tccomm tccond tcdbg +syn keyword sicadStatement tcgbnr tcgrpos tcinit tclconv tcmodel +syn keyword sicadStatement tcnwe tcpairs tcpath tcrect tcrmdli +syn keyword sicadStatement tcscheme tcschmap tcse tcselc tcstar +syn keyword sicadStatement tcstrman tcsubnet tcsymbol tctable tcthrcab +syn keyword sicadStatement tctrans tctst tdb tdbdel tdbget +syn keyword sicadStatement tdblist tdbput tgmod titel tmoff +syn keyword sicadStatement tmon tp tpa tps tpta +syn keyword sicadStatement tra trans transkdo transopt transpro +syn keyword sicadStatement triangle trm trpg trrkd trs +syn keyword sicadStatement ts tsa tx txa txchk +syn keyword sicadStatement txcng txju txl txp txpv +syn keyword sicadStatement txtcmp txv txz uckon uiinfo +syn keyword sicadStatement uistatus umdk umdk1 umdka umge +syn keyword sicadStatement umges umr verbo verflli verif +syn keyword sicadStatement verly versinfo vfg vpactive vpcenter +syn keyword sicadStatement vpcreate vpdelete vpinfo vpmodify vpscroll +syn keyword sicadStatement vpsta wabsym wzmerk zdrhf zdrhfn +syn keyword sicadStatement zdrhfw zdrhfwn zefp zfl zflaus +syn keyword sicadStatement zka zlel zlels zortf zortfn +syn keyword sicadStatement zortfw zortfwn zortp zortpn zparb +syn keyword sicadStatement zparbn zparf zparfn zparfw zparfwn +syn keyword sicadStatement zparp zparpn zwinkp zwinkpn + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link sicadLabel PreProc +hi def link sicadLabel1 sicadLabel +hi def link sicadLabel2 sicadLabel +hi def link sicadConditional Conditional +hi def link sicadBoolean Boolean +hi def link sicadNumber Number +hi def link sicadFloat Float +hi def link sicadOperator Operator +hi def link sicadStatement Statement +hi def link sicadParameter sicadStatement +hi def link sicadGoto sicadStatement +hi def link sicadLineCont sicadStatement +hi def link sicadString String +hi def link sicadComment Comment +hi def link sicadSpecial Special +hi def link sicadIdentifier Type +" hi def link sicadIdentifier Identifier +hi def link sicadError Error +hi def link sicadParenError sicadError +hi def link sicadApostropheError sicadError +hi def link sicadStringError sicadError +hi def link sicadCommentError sicadError +" hi def link sqlStatement Special " modified highlight group in sql.vim + + +let b:current_syntax = "sicad" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/sieve.vim b/syntax/sieve.vim new file mode 100644 index 0000000..3189859 --- /dev/null +++ b/syntax/sieve.vim @@ -0,0 +1,59 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Sieve filtering language input file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2007-10-25 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword sieveTodo contained TODO FIXME XXX NOTE + +syn region sieveComment start='/\*' end='\*/' contains=sieveTodo,@Spell +syn region sieveComment display oneline start='#' end='$' + \ contains=sieveTodo,@Spell + +syn case ignore + +syn match sieveTag display ':\h\w*' + +syn match sieveNumber display '\<\d\+[KMG]\=\>' + +syn match sieveSpecial display '\\["\\]' + +syn region sieveString start=+"+ skip=+\\\\\|\\"+ end=+"+ + \ contains=sieveSpecial +syn region sieveString start='text:' end='\n.\n' + +syn keyword sieveConditional if elsif else +syn keyword sieveTest address allof anyof envelope exists false header + \ not size true +syn keyword sievePreProc require stop +syn keyword sieveAction reject fileinto redirect keep discard +syn keyword sieveKeyword vacation + +syn case match + +hi def link sieveTodo Todo +hi def link sieveComment Comment +hi def link sieveTag Type +hi def link sieveNumber Number +hi def link sieveSpecial Special +hi def link sieveString String +hi def link sieveConditional Conditional +hi def link sieveTest Keyword +hi def link sievePreProc PreProc +hi def link sieveAction Function +hi def link sieveKeyword Keyword + +let b:current_syntax = "sieve" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/simula.vim b/syntax/simula.vim new file mode 100644 index 0000000..2554fbd --- /dev/null +++ b/syntax/simula.vim @@ -0,0 +1,91 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Simula +" Maintainer: Haakon Riiser +" URL: http://folk.uio.no/hakonrk/vim/syntax/simula.vim +" Last Change: 2001 May 15 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" No case sensitivity in Simula +syn case ignore + +syn match simulaComment "^%.*$" contains=simulaTodo +syn region simulaComment start="!\|\" end=";" contains=simulaTodo + +" Text between the keyword 'end' and either a semicolon or one of the +" keywords 'end', 'else', 'when' or 'otherwise' is also a comment +syn region simulaComment start="\"lc=3 matchgroup=Statement end=";\|\<\(end\|else\|when\|otherwise\)\>" + +syn match simulaCharError "'.\{-2,}'" +syn match simulaCharacter "'.'" +syn match simulaCharacter "'!\d\{-}!'" contains=simulaSpecialChar +syn match simulaString '".\{-}"' contains=simulaSpecialChar,simulaTodo + +syn keyword simulaBoolean true false +syn keyword simulaCompound begin end +syn keyword simulaConditional else if otherwise then until when +syn keyword simulaConstant none notext +syn keyword simulaFunction procedure +syn keyword simulaOperator eq eqv ge gt imp in is le lt ne new not qua +syn keyword simulaRepeat while for +syn keyword simulaReserved activate after at before delay go goto label prior reactivate switch to +syn keyword simulaStatement do inner inspect step this +syn keyword simulaStorageClass external hidden name protected value +syn keyword simulaStructure class +syn keyword simulaType array boolean character integer long real short text virtual +syn match simulaAssigned "\<\h\w*\s*\((.*)\)\=\s*:\(=\|-\)"me=e-2 +syn match simulaOperator "[&:=<>+\-*/]" +syn match simulaOperator "\" +syn match simulaOperator "\" +syn match simulaReferenceType "\" +" Real with optional exponent +syn match simulaReal "-\=\<\d\+\(\.\d\+\)\=\(&&\=[+-]\=\d\+\)\=\>" +" Real starting with a `.', optional exponent +syn match simulaReal "-\=\.\d\+\(&&\=[+-]\=\d\+\)\=\>" + + +hi def link simulaAssigned Identifier +hi def link simulaBoolean Boolean +hi def link simulaCharacter Character +hi def link simulaCharError Error +hi def link simulaComment Comment +hi def link simulaCompound Statement +hi def link simulaConditional Conditional +hi def link simulaConstant Constant +hi def link simulaFunction Function +hi def link simulaNumber Number +hi def link simulaOperator Operator +hi def link simulaReal Float +hi def link simulaReferenceType Type +hi def link simulaRepeat Repeat +hi def link simulaReserved Error +hi def link simulaSemicolon Statement +hi def link simulaSpecial Special +hi def link simulaSpecialChar SpecialChar +hi def link simulaSpecialCharErr Error +hi def link simulaStatement Statement +hi def link simulaStorageClass StorageClass +hi def link simulaString String +hi def link simulaStructure Structure +hi def link simulaTodo Todo +hi def link simulaType Type + + +let b:current_syntax = "simula" +" vim: sts=4 sw=4 ts=8 + +endif diff --git a/syntax/sinda.vim b/syntax/sinda.vim new file mode 100644 index 0000000..fb7e04c --- /dev/null +++ b/syntax/sinda.vim @@ -0,0 +1,133 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sinda85, sinda/fluint input file +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.sin +" URL: http://www.naglenet.org/vim/syntax/sinda.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case ignore + + + +" +" +" Begin syntax definitions for sinda input and output files. +" + +" Force free-form fortran format +let fortran_free_source=1 + +" Load FORTRAN syntax file +runtime! syntax/fortran.vim +unlet b:current_syntax + + + +" Define keywords for SINDA +syn keyword sindaMacro BUILD BUILDF DEBON DEBOFF DEFMOD FSTART FSTOP + +syn keyword sindaOptions TITLE PPSAVE RSI RSO OUTPUT SAVE QMAP USER1 USER2 +syn keyword sindaOptions MODEL PPOUT NOLIST MLINE NODEBUG DIRECTORIES +syn keyword sindaOptions DOUBLEPR + +syn keyword sindaRoutine FORWRD FWDBCK STDSTL FASTIC + +syn keyword sindaControl ABSZRO ACCELX ACCELY ACCELZ ARLXCA ATMPCA +syn keyword sindaControl BACKUP CSGFAC DRLXCA DTIMEH DTIMEI DTIMEL +syn keyword sindaControl DTIMES DTMPCA EBALNA EBALSA EXTLIM ITEROT +syn keyword sindaControl ITERXT ITHOLD NLOOPS NLOOPT OUTPUT OPEITR +syn keyword sindaControl PATMOS SIGMA TIMEO TIMEND UID + +syn keyword sindaSubRoutine ASKERS ADARIN ADDARY ADDMOD ARINDV +syn keyword sindaSubRoutine RYINV ARYMPY ARYSUB ARYTRN BAROC +syn keyword sindaSubRoutine BELACC BNDDRV BNDGET CHENNB CHGFLD +syn keyword sindaSubRoutine CHGLMP CHGSUC CHGVOL CHKCHL CHKCHP +syn keyword sindaSubRoutine CNSTAB COMBAL COMPLQ COMPRS CONTRN +syn keyword sindaSubRoutine CPRINT CRASH CRVINT CRYTRN CSIFLX +syn keyword sindaSubRoutine CVTEMP D11CYL C11DAI D11DIM D11MCY +syn keyword sindaSubRoutine D11MDA D11MDI D11MDT D12CYL D12MCY +syn keyword sindaSubRoutine D12MDA D1D1DA D1D1IM D1D1WM D1D2DA +syn keyword sindaSubRoutine D1D2WM D1DEG1 D1DEG2 D1DG1I D1IMD1 +syn keyword sindaSubRoutine D1IMIM D1IMWM D1M1DA D1M2MD D1M2WM +syn keyword sindaSubRoutine D1MDG1 D1MDG2 D2D1WM D1DEG1 D2DEG2 +syn keyword sindaSubRoutine D2D2 + +syn keyword sindaIdentifier BIV CAL DIM DIV DPM DPV DTV GEN PER PIV PIM +syn keyword sindaIdentifier SIM SIV SPM SPV TVS TVD + + + +" Define matches for SINDA +syn match sindaFortran "^F[0-9 ]"me=e-1 +syn match sindaMotran "^M[0-9 ]"me=e-1 + +syn match sindaComment "^C.*$" +syn match sindaComment "^R.*$" +syn match sindaComment "\$.*$" + +syn match sindaHeader "^header[^,]*" + +syn match sindaIncludeFile "include \+[^ ]\+"hs=s+8 contains=fortranInclude + +syn match sindaMacro "^PSTART" +syn match sindaMacro "^PSTOP" +syn match sindaMacro "^FAC" + +syn match sindaInteger "-\=\<[0-9]*\>" +syn match sindaFloat "-\=\<[0-9]*\.[0-9]*" +syn match sindaScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>" + +syn match sindaEndData "^END OF DATA" + +if exists("thermal_todo") + execute 'syn match sindaTodo ' . '"^'.thermal_todo.'.*$"' +else + syn match sindaTodo "^?.*$" +endif + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link sindaMacro Macro +hi def link sindaOptions Special +hi def link sindaRoutine Type +hi def link sindaControl Special +hi def link sindaSubRoutine Function +hi def link sindaIdentifier Identifier + +hi def link sindaFortran PreProc +hi def link sindaMotran PreProc + +hi def link sindaComment Comment +hi def link sindaHeader Typedef +hi def link sindaIncludeFile Type +hi def link sindaInteger Number +hi def link sindaFloat Float +hi def link sindaScientific Float + +hi def link sindaEndData Macro + +hi def link sindaTodo Todo + + + +let b:current_syntax = "sinda" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/sindacmp.vim b/syntax/sindacmp.vim new file mode 100644 index 0000000..9ce35cc --- /dev/null +++ b/syntax/sindacmp.vim @@ -0,0 +1,65 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sinda85, sinda/fluint compare file +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.cmp +" URL: http://www.naglenet.org/vim/syntax/sindacmp.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case ignore + + + +" +" Begin syntax definitions for compare files. +" + +" Define keywords for sinda compare (sincomp) +syn keyword sindacmpUnit celsius fahrenheit + + + +" Define matches for sinda compare (sincomp) +syn match sindacmpTitle "Steady State Temperature Comparison" + +syn match sindacmpLabel "File [1-6] is" + +syn match sindacmpHeader "^ *Node\( *File \d\)* *Node Description" + +syn match sindacmpInteger "^ *-\=\<[0-9]*\>" +syn match sindacmpFloat "-\=\<[0-9]*\.[0-9]*" + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link sindacmpTitle Type +hi def link sindacmpUnit PreProc + +hi def link sindacmpLabel Statement + +hi def link sindacmpHeader sindaHeader + +hi def link sindacmpInteger Number +hi def link sindacmpFloat Special + + + +let b:current_syntax = "sindacmp" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/sindaout.vim b/syntax/sindaout.vim new file mode 100644 index 0000000..588edf1 --- /dev/null +++ b/syntax/sindaout.vim @@ -0,0 +1,87 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sinda85, sinda/fluint output file +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.out +" URL: http://www.naglenet.org/vim/syntax/sindaout.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case match + + + +" Load SINDA syntax file +runtime! syntax/sinda.vim +unlet b:current_syntax + + + +" +" +" Begin syntax definitions for sinda output files. +" + +" Define keywords for sinda output +syn case match + +syn keyword sindaoutPos ON SI +syn keyword sindaoutNeg OFF ENG + + + +" Define matches for sinda output +syn match sindaoutFile ": \w*\.TAK"hs=s+2 + +syn match sindaoutInteger "T\=[0-9]*\>"ms=s+1 + +syn match sindaoutSectionDelim "[-<>]\{4,}" contains=sindaoutSectionTitle +syn match sindaoutSectionDelim ":\=\.\{4,}:\=" contains=sindaoutSectionTitle +syn match sindaoutSectionTitle "[-<:] \w[0-9A-Za-z_() ]\+ [->:]"hs=s+1,me=e-1 + +syn match sindaoutHeaderDelim "=\{5,}" +syn match sindaoutHeaderDelim "|\{5,}" +syn match sindaoutHeaderDelim "+\{5,}" + +syn match sindaoutLabel "Input File:" contains=sindaoutFile +syn match sindaoutLabel "Begin Solution: Routine" + +syn match sindaoutError "<<< Error >>>" + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi sindaHeaderDelim ctermfg=Black ctermbg=Green guifg=Black guibg=Green + +hi def link sindaoutPos Statement +hi def link sindaoutNeg PreProc +hi def link sindaoutTitle Type +hi def link sindaoutFile sindaIncludeFile +hi def link sindaoutInteger sindaInteger + +hi def link sindaoutSectionDelim Delimiter +hi def link sindaoutSectionTitle Exception +hi def link sindaoutHeaderDelim SpecialComment +hi def link sindaoutLabel Identifier + +hi def link sindaoutError Error + + + +let b:current_syntax = "sindaout" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/sisu.vim b/syntax/sisu.vim new file mode 100644 index 0000000..7a83926 --- /dev/null +++ b/syntax/sisu.vim @@ -0,0 +1,279 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" SiSU Vim syntax file +" SiSU Maintainer: Ralph Amissah +" SiSU Markup: SiSU (sisu-5.6.7) +" Last Change: 2017 Jun 22 +" URL: +" +"(originally looked at Ruby Vim by Mirko Nasato) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +let s:cpo_save = &cpo +set cpo&vim + +"% "Errors: +syn match sisu_error contains=sisu_link,sisu_error_wspace "" + +"% "Markers Identifiers: +if !exists("sisu_no_identifiers") + syn match sisu_mark_endnote "\~^" + syn match sisu_break contains=@NoSpell " \\\\\( \|$\)\|
\|
" + syn match sisu_control contains=@NoSpell "^\(-\\\\-\|=\\\\=\|-\.\.-\|<:p[bn]>\)\s*$" + syn match sisu_control contains=@NoSpell "^<:\(bo\|---\)>\s*$" + syn match sisu_marktail contains=@NoSpell "^--[+~-]#\s*$" + syn match sisu_marktail "[~-]#" + syn match sisu_control "\"" + syn match sisu_underline "\(^\| \)_[a-zA-Z0-9]\+_\([ .,]\|$\)" + syn match sisu_number contains=@NoSpell "[0-9a-f]\{32\}\|[0-9a-f]\{64\}" + syn match sisu_link contains=@NoSpell "\(_\?https\?://\|\.\.\/\)\S\+" + syn match sisu_link " \*\~\S\+" + syn match sisu_require contains=@NoSpell "^<<\s*[a-zA-Z0-9^./_-]\+\.ss[it]$" + syn match sisu_structure "^:A\~$" + +"% "Document Sub Headers: + syn match sisu_sub_header_title "^\s\+:\(subtitle\|short\|edition\|language\|lang_char\|note\):\s" "group=sisu_header_content + syn match sisu_sub_header_creator "^\s\+:\(author\|editor\|contributor\|illustrator\|photographer\|translator\|digitized_by\|prepared_by\|audio\|video\):\s" " &hon &institution + syn match sisu_sub_header_rights "^\s\+:\(copyright\|text\|translation\|illustrations\|photographs\|preparation\|digitization\|audio\|video\|license\|all\):\s" " access_rights license + syn match sisu_sub_header_classify "^\s\+:\(topic_register\|keywords\|subject\|dewey\|loc\):\s" + syn match sisu_sub_header_identifier "^\s\+:\(oclc\|isbn\):\s" + syn match sisu_sub_header_date "^\s\+:\(added_to_site\|available\|created\|issued\|modified\|published\|valid\|translated\|original_publication\):\s" + syn match sisu_sub_header_original "^\s\+:\(publisher\|date\|language\|lang_char\|institution\|nationality\|source\):\s" + syn match sisu_sub_header_make "^\s\+:\(headings\|num_top\|breaks\|language\|italics\|bold\|emphasis\|substitute\|omit\|plaintext_wrap\|texpdf_font_mono\|texpdf_font\|stamp\|promo\|ad\|manpage\|home_button_text\|home_button_image\|cover_image\|footer\):\s" + syn match sisu_sub_header_notes "^\s\+:\(description\|abstract\|comment\|coverage\|relation\|source\|history\|type\|format\|prefix\|prefix_[ab]\|suffix\):\s" + syn match sisu_within_index_ignore "\S\+[:;]\(\s\+\|$\)" + syn match sisu_within_index "[:|;]\|+\d\+" + +"% "semantic markers: (ignore) + syn match sisu_sem_marker ";{\|};[a-z._]*[a-z]" + syn match sisu_sem_marker_block "\([a-z][a-z._]*\|\):{\|}:[a-z._]*[a-z]" + syn match sisu_sem_ex_marker ";\[\|\];[a-z._]*[a-z]" + syn match sisu_sem_ex_marker_block "\([a-z][a-z._]*\|\):\[\|\]:[a-z._]*[a-z]" + syn match sisu_sem_block contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_mark_endnote,sisu_content_endnote "\([a-z]*\):{[^}].\{-}}:\1" + syn match sisu_sem_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker ";{[^}].\{-}};[a-z]\+" + syn match sisu_sem_ex_block contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_mark_endnote,sisu_content_endnote "\([a-z]*\):\[[^}].\{-}\]:\1" + syn match sisu_sem_ex_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker ";\[[^}].\{-}\];[a-z]\+" +endif + +"% "URLs Numbers And ASCII Codes: +syn match sisu_number "\<\(0x\x\+\|0b[01]\+\|0\o\+\|0\.\d\+\|0\|[1-9][\.0-9_]*\)\>" +syn match sisu_number "?\(\\M-\\C-\|\\c\|\\C-\|\\M-\)\=\(\\\o\{3}\|\\x\x\{2}\|\\\=\w\)" + +"% "Tuned Error: (is error if not already matched) +syn match sisu_error contains=sisu_error "[\~/\*!_]{\|}[\~/\*!_]" +syn match sisu_error contains=sisu_error "]" + +"% "Simple Paired Enclosed Markup: +"url/link +syn region sisu_link contains=sisu_error,sisu_error_wspace matchgroup=sisu_action start="^<<\s*|[a-zA-Z0-9^._-]\+|@|[a-zA-Z0-9^._-]\+|"rs=s+2 end="$" + +"% "Document Header: +" title +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_title matchgroup=sisu_header start="^[@]title:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" creator +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_creator matchgroup=sisu_header start="^[@]creator:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" dates +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_date matchgroup=sisu_header start="^[@]date:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" publisher +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_publisher matchgroup=sisu_header start="^[@]publisher:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" rights +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_rights matchgroup=sisu_header start="^[@]rights:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" classify document +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_classify matchgroup=sisu_header start="^[@]classify:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" identifier document +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_identifier matchgroup=sisu_header start="^[@]identifier:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" original language (depreciated) +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_original matchgroup=sisu_header start="^[@]original:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" notes +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_notes matchgroup=sisu_header start="^[@]notes:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" links of interest +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_linked,sisu_sub_header_links matchgroup=sisu_header start="^[@]links:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" +" make, processing instructions +syn region sisu_header_content contains=sisu_error,sisu_comment,sisu_break,sisu_link,sisu_sub_header_make matchgroup=sisu_header start="^[@]make:[+-]\?\(\s\|\n\)"rs=e-1 end="\n$" + +"% "Headings: +syn region sisu_heading contains=sisu_mark_endnote,sisu_content_endnote,sisu_marktail,sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_ocn,sisu_error,sisu_error_wspace matchgroup=sisu_structure start="^\([1-4]\|:\?[A-D]\)\~\(\S\+\|[^-]\)" end="$" + +"% "Block Group Text: +" table +syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^table{.\+" end="}table" +" table +syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^```\s\+table" end="^```\(\s\|$\)" +syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^{\(t\|table\)\(\~h\)\?\(\sc[0-9]\+;\)\?[0-9; ]*}" end="\n$" +" block, group, poem, alt +syn region sisu_content_alt contains=sisu_mark_endnote,sisu_content_endnote,sisu_link,sisu_mark,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^\z(block\|group\|poem\|alt\){" end="^}\z1" +syn region sisu_content_alt contains=sisu_mark_endnote,sisu_content_endnote,sisu_link,sisu_mark,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^```\s\+\(block\|group\|poem\|alt\)" end="^```\(\s\|$\)" +" box +syn region sisu_content_alt contains=sisu_mark_endnote,sisu_content_endnote,sisu_link,sisu_mark,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^box\(\.[a-z]\+\)\?{" end="^}box" +syn region sisu_content_alt contains=sisu_mark_endnote,sisu_content_endnote,sisu_link,sisu_mark,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^```\s\+\box\(\.[a-z]\+\)\?" end="^```\(\s\|$\)" +" code +syn region sisu_content_alt contains=sisu_error,@NoSpell matchgroup=sisu_contain start="^code\(\.[a-z][0-9a-z_]\+\)\?{" end="^}code" +syn region sisu_content_alt contains=sisu_error,@NoSpell matchgroup=sisu_contain start="^```\s\+code\(\.[a-z][0-9a-z_]\+\)\?" end="^```\(\s\|$\)" +" quote +syn region sisu_normal contains=sisu_fontface,sisu_bold,sisu_control,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_contain start="^```\s\+quote" end="^```\(\s\|$\)" + +"% "Endnotes: +" regular endnote or asterisk or plus sign endnote +syn region sisu_content_endnote contains=sisu_link,sisu_strikeout,sisu_underline,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker matchgroup=sisu_mark_endnote start="\~{[*+]*" end="}\~" skip="\n" +" numbered asterisk or plus sign endnote +syn region sisu_content_endnote contains=sisu_link,sisu_strikeout,sisu_underline,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker matchgroup=sisu_mark_endnote start="\~\[[*+]*" end="\]\~" skip="\n" +" endnote content marker (for binary content marking) +syn region sisu_content_endnote contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_link,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break matchgroup=sisu_mark_endnote start="\^\~" end="\n$" + +"% "Links And Images: +" image with url link (and possibly footnote of url) +syn region sisu_linked contains=sisu_fontface,sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_sem_block,sisu_error matchgroup=sisu_link start="{\(\~^\s\)\?" end="}\(https\?:/\/\|:\|\.\.\/\|#\)\S\+" oneline +" sisu outputs, short notation +syn region sisu_linked contains=sisu_fontface,sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_sem_block,sisu_error matchgroup=sisu_link start="{\(\~^\s\)\?" end="\[[1-5][sS]*\]}\S\+\.ss[tm]" oneline +" image +syn region sisu_linked contains=sisu_fontface,sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_link start="{" end="}image" oneline + +"% "Some Line Operations: +" bold line +syn region sisu_bold contains=sisu_strikeout,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^!_ " end=" \\\\\|$" +" indent and bullet paragraph +syn region sisu_normal contains=sisu_fontface,sisu_bold,sisu_control,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^_\([1-9*]\|[1-9]\*\) " end="$" +" indent and bullet (bold start) paragraph +syn region sisu_bold contains=sisu_fontface,sisu_bold,sisu_control,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^_\([1-9*]\|[1-9]\*\)!_\? " end=" \\\\\|$" +" hanging indent paragraph [proposed] +syn region sisu_normal contains=sisu_fontface,sisu_bold,sisu_control,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^_[0-9]\?_[0-9] " end="$" +" hanging indent (bold start/ definition) paragraph [proposed] +syn region sisu_bold contains=sisu_fontface,sisu_bold,sisu_control,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^_[0-9]\?_[0-9]!_\? " end=" \\\\\|$" +" list numbering +syn region sisu_normal contains=sisu_strikeout,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^\(#[ 1]\|_# \)" end="$" + +"% "Font Face Curly Brackets: +"syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_sem start="\S\+:{" end="}:[^<>,.!?:; ]\+" oneline +" book index: +syn region sisu_index contains=sisu_within_index_ignore,sisu_within_index matchgroup=sisu_index_block start="^={" end="}" +" emphasis: +syn region sisu_bold contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="\*{" end="}\*" +" bold: +syn region sisu_bold contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="!{" end="}!" +" underscore: +syn region sisu_underline contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="_{" end="}_" +" italics: +syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="/{" end="}/" +" added: +syn region sisu_underline contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="+{" end="}+" +" superscript: +syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="\^{" end="}\^" +" subscript: +syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start=",{" end="}," +" monospace: +syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_bold,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="#{" end="}#" +" strikethrough: +syn region sisu_strikeout contains=sisu_error matchgroup=sisu_fontface start="-{" end="}-" + +"% "Single Words Bold Italicise Etc: (depreciated) +syn region sisu_bold contains=sisu_error matchgroup=sisu_bold start="\([ (]\|^\)\*[^\|{\n\~\\]"hs=e-1 end="\*"he=e-0 skip="[a-zA-Z0-9']" oneline +syn region sisu_identifier contains=sisu_error matchgroup=sisu_content_alt start="\([ ]\|^\)/[^{ \|\n\\]"hs=e-1 end="/\[ \.\]" skip="[a-zA-Z0-9']" oneline +"misc +syn region sisu_identifier contains=sisu_error matchgroup=sisu_fontface start="\^[^ {\|\n\\]"rs=s+1 end="\^[ ,.;:'})\\\n]" skip="[a-zA-Z0-9']" oneline + +"% "Expensive Mode: +if !exists("sisu_no_expensive") +else " not Expensive + syn region sisu_content_alt matchgroup=sisu_control start="^\s*def\s" matchgroup=NONE end="[?!]\|\>" skip="\.\|\(::\)" oneline +endif " Expensive? + +"% "Headers And Headings: (Document Instructions) +syn match sisu_control contains=sisu_error,sisu_error_wspace "4\~! \S\+" +syn region sisu_markpara contains=sisu_error,sisu_error_wspace start="^=begin" end="^=end.*$" + +"% "Errors: +syn match sisu_error_wspace contains=sisu_error_wspace "^\s\+[^:]" +syn match sisu_error_wspace contains=sisu_error_wspace "\s\s\+" +syn match sisu_error_wspace contains=sisu_error_wspace "\s\+$" +syn match sisu_error contains=sisu_error_wspace "\t\+" +syn match sisu_error contains=sisu_error,sisu_error_wspace "\([^ (][_\\]\||[^ (}]\)https\?:\S\+" +syn match sisu_error contains=sisu_error "_\?https\?:\S\+[}><]" +syn match sisu_error contains=sisu_error "\([!*/_\+,^]\){\([^(\}\1)]\)\{-}\n$" +syn match sisu_error contains=sisu_error "^[\~]{[^{]\{-}\n$" +syn match sisu_error contains=sisu_error "\s\+.{{" +syn match sisu_error contains=sisu_error "^\~\s*$" +syn match sisu_error contains=sisu_error "^0\~.*" +syn match sisu_error contains=sisu_error "^[1-9]\~\s*$" +syn match sisu_error contains=sisu_error "^[1-9]\~\S\+\s*$" +syn match sisu_error contains=sisu_error "[^{]\~\^[^ \)]" +syn match sisu_error contains=sisu_error "\~\^\s\+\.\s*" +syn match sisu_error contains=sisu_error "{\~^\S\+" +syn match sisu_error contains=sisu_error "[_/\*!^]{[ .,:;?><]*}[_/\*!^]" +syn match sisu_error contains=sisu_error "[^ (\"'(\[][_/\*!]{\|}[_/\*!][a-zA-Z0-9)\]\"']" +syn match sisu_error contains=sisu_error "" +"errors for filetype sisu, though not error in 'metaverse': +syn match sisu_error contains=sisu_error,sisu_match,sisu_strikeout,sisu_contain,sisu_content_alt,sisu_mark,sisu_break,sisu_number "<[a-zA-Z\/]\+>" +syn match sisu_error "/\?<\([biu]\)>[^()]\{-}\n$" + +"% "Error Exceptions: +syn match sisu_control "\n$" "contains=ALL +"syn match sisu_control " //" +syn match sisu_error "%{" +syn match sisu_error "
_\?https\?:\S\+\|_\?https\?:\S\+
" +syn match sisu_error "[><]_\?https\?:\S\+\|_\?https\?:\S\+[><]" +syn match sisu_comment "^%\{1,2\}.\+" + +"% "Definitions Default Highlighting: +hi def link sisu_normal Normal +hi def link sisu_bold Statement +hi def link sisu_header PreProc +hi def link sisu_header_content Normal +hi def link sisu_sub_header_title Statement +hi def link sisu_sub_header_creator Statement +hi def link sisu_sub_header_date Statement +hi def link sisu_sub_header_publisher Statement +hi def link sisu_sub_header_rights Statement +hi def link sisu_sub_header_classify Statement +hi def link sisu_sub_header_identifier Statement +hi def link sisu_sub_header_original Statement +hi def link sisu_sub_header_links Statement +hi def link sisu_sub_header_notes Statement +hi def link sisu_sub_header_make Statement +hi def link sisu_heading Title +hi def link sisu_structure Operator +hi def link sisu_contain Include +hi def link sisu_mark_endnote Delimiter +hi def link sisu_require NonText +hi def link sisu_link NonText +hi def link sisu_linked String +hi def link sisu_fontface Delimiter +hi def link sisu_strikeout DiffDelete +hi def link sisu_content_alt Special +hi def link sisu_sem_content SpecialKey +hi def link sisu_sem_block Special +hi def link sisu_sem_marker Visual +"hi def link sisu_sem_marker Structure +hi def link sisu_sem_marker_block MatchParen +hi def link sisu_sem_ex_marker FoldColumn +hi def link sisu_sem_ex_marker_block Folded +hi def link sisu_sem_ex_content Comment +"hi def link sisu_sem_ex_content SpecialKey +hi def link sisu_sem_ex_block Comment +hi def link sisu_index SpecialKey +hi def link sisu_index_block Visual +hi def link sisu_content_endnote Special +hi def link sisu_control Delimiter +hi def link sisu_within_index Delimiter +hi def link sisu_within_index_ignore SpecialKey +hi def link sisu_ocn Include +hi def link sisu_number Number +hi def link sisu_identifier Function +hi def link sisu_underline Underlined +hi def link sisu_markpara Include +hi def link sisu_marktail Include +hi def link sisu_mark Identifier +hi def link sisu_break Structure +hi def link sisu_html Type +hi def link sisu_action Identifier +hi def link sisu_comment Comment +hi def link sisu_error_sem_marker Error +hi def link sisu_error_wspace Error +hi def link sisu_error Error +let b:current_syntax = "sisu" +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/skill.vim b/syntax/skill.vim new file mode 100644 index 0000000..dc1949b --- /dev/null +++ b/syntax/skill.vim @@ -0,0 +1,553 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SKILL +" Maintainer: Toby Schaffer +" Last Change: 2003 May 11 +" Comments: SKILL is a Lisp-like programming language for use in EDA +" tools from Cadence Design Systems. It allows you to have +" a programming environment within the Cadence environment +" that gives you access to the complete tool set and design +" database. This file also defines syntax highlighting for +" certain Design Framework II interface functions. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword skillConstants t nil unbound + +" enumerate all the SKILL reserved words/functions +syn match skillFunction "(abs\>"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillConditional "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillConditional "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillRepeat "\"hs=s+1 +syn match skillFunction "\<[fs]\=printf("he=e-1 +syn match skillFunction "(f\=scanf\>"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillRepeat "\"hs=s+1 +syn match skillConditional "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\<[mn]\=procedure("he=e-1 +syn match skillFunction "(ncon[cs]\>"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillKeywords "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillConditional "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillConditional "\"hs=s+1 +syn match skillRepeat "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillFunction "\"hs=s+1 +syn match skillcdfFunctions "\"hs=s+1 +syn match skillgeFunctions "\"hs=s+1 +syn match skillhiFunctions "\"hs=s+1 +syn match skillleFunctions "\"hs=s+1 +syn match skilldbefFunctions "\"hs=s+1 +syn match skillddFunctions "\"hs=s+1 +syn match skillpcFunctions "\"hs=s+1 +syn match skilltechFunctions "\<\(tech\|tc\)\u\a\+("he=e-1 + +" strings +syn region skillString start=+"+ skip=+\\"+ end=+"+ + +syn keyword skillTodo contained TODO FIXME XXX +syn keyword skillNote contained NOTE IMPORTANT + +" comments are either C-style or begin with a semicolon +syn region skillComment start="/\*" end="\*/" contains=skillTodo,skillNote +syn match skillComment ";.*" contains=skillTodo,skillNote +syn match skillCommentError "\*/" + +syn sync ccomment skillComment minlines=10 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link skillcdfFunctions Function +hi def link skillgeFunctions Function +hi def link skillhiFunctions Function +hi def link skillleFunctions Function +hi def link skilldbefFunctions Function +hi def link skillddFunctions Function +hi def link skillpcFunctions Function +hi def link skilltechFunctions Function +hi def link skillConstants Constant +hi def link skillFunction Function +hi def link skillKeywords Statement +hi def link skillConditional Conditional +hi def link skillRepeat Repeat +hi def link skillString String +hi def link skillTodo Todo +hi def link skillNote Todo +hi def link skillComment Comment +hi def link skillCommentError Error + + +let b:current_syntax = "skill" + +" vim: ts=4 + +endif diff --git a/syntax/sl.vim b/syntax/sl.vim new file mode 100644 index 0000000..453d34a --- /dev/null +++ b/syntax/sl.vim @@ -0,0 +1,111 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Renderman shader language +" Maintainer: Dan Piponi +" Last Change: 2001 May 09 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful Renderman keywords including special +" RenderMan control structures +syn keyword slStatement break return continue +syn keyword slConditional if else +syn keyword slRepeat while for +syn keyword slRepeat illuminance illuminate solar + +syn keyword slTodo contained TODO FIXME XXX + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match slSpecial contained "\\[0-9][0-9][0-9]\|\\." +syn region slString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=slSpecial +syn match slCharacter "'[^\\]'" +syn match slSpecialCharacter "'\\.'" +syn match slSpecialCharacter "'\\[0-9][0-9]'" +syn match slSpecialCharacter "'\\[0-9][0-9][0-9]'" + +"catch errors caused by wrong parenthesis +syn region slParen transparent start='(' end=')' contains=ALLBUT,slParenError,slIncluded,slSpecial,slTodo,slUserLabel +syn match slParenError ")" +syn match slInParen contained "[{}]" + +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match slNumber "\<[0-9]\+\(u\=l\=\|lu\|f\)\>" +"floating point number, with dot, optional exponent +syn match slFloat "\<[0-9]\+\.[0-9]*\(e[-+]\=[0-9]\+\)\=[fl]\=\>" +"floating point number, starting with a dot, optional exponent +syn match slFloat "\.[0-9]\+\(e[-+]\=[0-9]\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match slFloat "\<[0-9]\+e[-+]\=[0-9]\+[fl]\=\>" +"hex number +syn match slNumber "\<0x[0-9a-f]\+\(u\=l\=\|lu\)\>" +"syn match slIdentifier "\<[a-z_][a-z0-9_]*\>" +syn case match + +if exists("sl_comment_strings") + " A comment can contain slString, slCharacter and slNumber. + " But a "*/" inside a slString in a slComment DOES end the comment! So we + " need to use a special type of slString: slCommentString, which also ends on + " "*/", and sees a "*" at the start of the line as comment again. + " Unfortunately this doesn't very well work for // type of comments :-( + syntax match slCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region slCommentString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end=+\*/+me=s-1 contains=slSpecial,slCommentSkip + syntax region slComment2String contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end="$" contains=slSpecial + syntax region slComment start="/\*" end="\*/" contains=slTodo,slCommentString,slCharacter,slNumber +else + syn region slComment start="/\*" end="\*/" contains=slTodo +endif +syntax match slCommentError "\*/" + +syn keyword slOperator sizeof +syn keyword slType float point color string vector normal matrix void +syn keyword slStorageClass varying uniform extern +syn keyword slStorageClass light surface volume displacement transformation imager +syn keyword slVariable Cs Os P dPdu dPdv N Ng u v du dv s t +syn keyword slVariable L Cl Ol E I ncomps time Ci Oi +syn keyword slVariable Ps alpha +syn keyword slVariable dtime dPdtime + +syn sync ccomment slComment minlines=10 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link slLabel Label +hi def link slUserLabel Label +hi def link slConditional Conditional +hi def link slRepeat Repeat +hi def link slCharacter Character +hi def link slSpecialCharacter slSpecial +hi def link slNumber Number +hi def link slFloat Float +hi def link slParenError slError +hi def link slInParen slError +hi def link slCommentError slError +hi def link slOperator Operator +hi def link slStorageClass StorageClass +hi def link slError Error +hi def link slStatement Statement +hi def link slType Type +hi def link slCommentError slError +hi def link slCommentString slString +hi def link slComment2String slString +hi def link slCommentSkip slComment +hi def link slString String +hi def link slComment Comment +hi def link slSpecial SpecialChar +hi def link slTodo Todo +hi def link slVariable Identifier +"hi def link slIdentifier Identifier + + +let b:current_syntax = "sl" + +" vim: ts=8 + +endif diff --git a/syntax/slang.vim b/syntax/slang.vim new file mode 100644 index 0000000..7bb48a7 --- /dev/null +++ b/syntax/slang.vim @@ -0,0 +1,93 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: S-Lang +" Maintainer: Jan Hlavacek +" Last Change: 980216 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword slangStatement break return continue EXECUTE_ERROR_BLOCK +syn match slangStatement "\" +syn keyword slangLabel case +syn keyword slangConditional !if if else switch +syn keyword slangRepeat while for _for loop do forever +syn keyword slangDefinition define typedef variable struct +syn keyword slangOperator or and andelse orelse shr shl xor not +syn keyword slangBlock EXIT_BLOCK ERROR_BLOCK +syn match slangBlock "\" +syn keyword slangConstant NULL +syn keyword slangType Integer_Type Double_Type Complex_Type String_Type Struct_Type Ref_Type Null_Type Array_Type DataType_Type + +syn match slangOctal "\<0\d\+\>" contains=slangOctalError +syn match slangOctalError "[89]\+" contained +syn match slangHex "\<0[xX][0-9A-Fa-f]*\>" +syn match slangDecimal "\<[1-9]\d*\>" +syn match slangFloat "\<\d\+\." +syn match slangFloat "\<\d\+\.\d\+\([Ee][-+]\=\d\+\)\=\>" +syn match slangFloat "\<\d\+\.[Ee][-+]\=\d\+\>" +syn match slangFloat "\<\d\+[Ee][-+]\=\d\+\>" +syn match slangFloat "\.\d\+\([Ee][-+]\=\d\+\)\=\>" +syn match slangImaginary "\.\d\+\([Ee][-+]\=\d*\)\=[ij]\>" +syn match slangImaginary "\<\d\+\(\.\d*\)\=\([Ee][-+]\=\d\+\)\=[ij]\>" + +syn region slangString oneline start='"' end='"' skip='\\"' +syn match slangCharacter "'[^\\]'" +syn match slangCharacter "'\\.'" +syn match slangCharacter "'\\[0-7]\{1,3}'" +syn match slangCharacter "'\\d\d\{1,3}'" +syn match slangCharacter "'\\x[0-7a-fA-F]\{1,2}'" + +syn match slangDelim "[][{};:,]" +syn match slangOperator "[-%+/&*=<>|!~^@]" + +"catch errors caused by wrong parenthesis +syn region slangParen matchgroup=slangDelim transparent start='(' end=')' contains=ALLBUT,slangParenError +syn match slangParenError ")" + +syn match slangComment "%.*$" +syn keyword slangOperator sizeof + +syn region slangPreCondit start="^\s*#\s*\(ifdef\>\|ifndef\>\|iftrue\>\|ifnfalse\>\|iffalse\>\|ifntrue\>\|if\$\|ifn\$\|\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=cComment,slangString,slangCharacter,slangNumber + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link slangDefinition Type +hi def link slangBlock slangDefinition +hi def link slangLabel Label +hi def link slangConditional Conditional +hi def link slangRepeat Repeat +hi def link slangCharacter Character +hi def link slangFloat Float +hi def link slangImaginary Float +hi def link slangDecimal slangNumber +hi def link slangOctal slangNumber +hi def link slangHex slangNumber +hi def link slangNumber Number +hi def link slangParenError Error +hi def link slangOctalError Error +hi def link slangOperator Operator +hi def link slangStructure Structure +hi def link slangInclude Include +hi def link slangPreCondit PreCondit +hi def link slangError Error +hi def link slangStatement Statement +hi def link slangType Type +hi def link slangString String +hi def link slangConstant Constant +hi def link slangRangeArray slangConstant +hi def link slangComment Comment +hi def link slangSpecial SpecialChar +hi def link slangTodo Todo +hi def link slangDelim Delimiter + + +let b:current_syntax = "slang" + +" vim: ts=8 + +endif diff --git a/syntax/slice.vim b/syntax/slice.vim new file mode 100644 index 0000000..74f0e73 --- /dev/null +++ b/syntax/slice.vim @@ -0,0 +1,82 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Slice (ZeroC's Specification Language for Ice) +" Maintainer: Morel Bodin +" Last Change: 2005 Dec 03 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" The Slice keywords + +syn keyword sliceType bool byte double float int long short string void +syn keyword sliceQualifier const extends idempotent implements local nonmutating out throws +syn keyword sliceConstruct class enum exception dictionary interface module LocalObject Object sequence struct +syn keyword sliceQualifier const extends idempotent implements local nonmutating out throws +syn keyword sliceBoolean false true + +" Include directives +syn region sliceIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match sliceIncluded display contained "<[^>]*>" +syn match sliceInclude display "^\s*#\s*include\>\s*["<]" contains=sliceIncluded + +" Double-include guards +syn region sliceGuard start="^#\(define\|ifndef\|endif\)" end="$" + +" Strings and characters +syn region sliceString start=+"+ end=+"+ + +" Numbers (shamelessly ripped from c.vim, only slightly modified) +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match sliceNumbers display transparent "\<\d\|\.\d" contains=sliceNumber,sliceFloat,sliceOctal +syn match sliceNumber display contained "\d\+" +"hex number +syn match sliceNumber display contained "0x\x\+\(u\=l\{0,2}\|ll\=u\)\>" +" Flag the first zero of an octal number as something special +syn match sliceOctal display contained "0\o\+\(u\=l\{0,2}\|ll\=u\)\>" contains=sliceOctalZero +syn match sliceOctalZero display contained "\<0" +syn match sliceFloat display contained "\d\+f" +"floating point number, with dot, optional exponent +syn match sliceFloat display contained "\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=" +"floating point number, starting with a dot, optional exponent +syn match sliceFloat display contained "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match sliceFloat display contained "\d\+e[-+]\=\d\+[fl]\=\>" +" flag an octal number with wrong digits +syn case match + + +" Comments +syn region sliceComment start="/\*" end="\*/" +syn match sliceComment "//.*" + +syn sync ccomment sliceComment + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link sliceComment Comment +hi def link sliceConstruct Keyword +hi def link sliceType Type +hi def link sliceString String +hi def link sliceIncluded String +hi def link sliceQualifier Keyword +hi def link sliceInclude Include +hi def link sliceGuard PreProc +hi def link sliceBoolean Boolean +hi def link sliceFloat Number +hi def link sliceNumber Number +hi def link sliceOctal Number +hi def link sliceOctalZero Special +hi def link sliceNumberError Special + + +let b:current_syntax = "slice" + +" vim: ts=8 + +endif diff --git a/syntax/slpconf.vim b/syntax/slpconf.vim new file mode 100644 index 0000000..5ca4b41 --- /dev/null +++ b/syntax/slpconf.vim @@ -0,0 +1,277 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: RFC 2614 - An API for Service Location configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword slpconfTodo contained TODO FIXME XXX NOTE + +syn region slpconfComment display oneline start='^[#;]' end='$' + \ contains=slpconfTodo,@Spell + +syn match slpconfBegin display '^' + \ nextgroup=slpconfTag, + \ slpconfComment skipwhite + +syn keyword slpconfTag contained net + \ nextgroup=slpconfNetTagDot + +syn match slpconfNetTagDot contained display '.' + \ nextgroup=slpconfNetTag + +syn keyword slpconfNetTag contained slp + \ nextgroup=slpconfNetSlpTagdot + +syn match slpconfNetSlpTagDot contained display '.' + \ nextgroup=slpconfNetSlpTag + +syn keyword slpconfNetSlpTag contained isDA traceDATraffic traceMsg + \ traceDrop traceReg isBroadcastOnly + \ passiveDADetection securityEnabled + \ nextgroup=slpconfBooleanEq,slpconfBooleanHome + \ skipwhite + +syn match slpconfBooleanHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfBooleanEq skipwhite + +syn match slpconfBooleanEq contained display '=' + \ nextgroup=slpconfBoolean skipwhite + +syn keyword slpconfBoolean contained true false TRUE FALSE + +syn keyword slpconfNetSlpTag contained DAHeartBeat multicastTTL + \ DAActiveDiscoveryInterval + \ multicastMaximumWait multicastTimeouts + \ randomWaitBound MTU maxResults + \ nextgroup=slpconfIntegerEq,slpconfIntegerHome + \ skipwhite + +syn match slpconfIntegerHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfIntegerEq skipwhite + +syn match slpconfIntegerEq contained display '=' + \ nextgroup=slpconfInteger skipwhite + +syn match slpconfInteger contained display '\<\d\+\>' + +syn keyword slpconfNetSlpTag contained DAAttributes SAAttributes + \ nextgroup=slpconfAttrEq,slpconfAttrHome + \ skipwhite + +syn match slpconfAttrHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfAttrEq skipwhite + +syn match slpconfAttrEq contained display '=' + \ nextgroup=slpconfAttrBegin skipwhite + +syn match slpconfAttrBegin contained display '(' + \ nextgroup=slpconfAttrTag skipwhite + +syn match slpconfAttrTag contained display + \ '[^* \t_(),\\!<=>~[:cntrl:]]\+' + \ nextgroup=slpconfAttrTagEq skipwhite + +syn match slpconfAttrTagEq contained display '=' + \ nextgroup=@slpconfAttrValue skipwhite + +syn cluster slpconfAttrValueCon contains=slpconfAttrValueSep,slpconfAttrEnd + +syn cluster slpconfAttrValue contains=slpconfAttrIValue,slpconfAttrSValue, + \ slpconfAttrBValue,slpconfAttrSSValue + +syn match slpconfAttrSValue contained display '[^ (),\\!<=>~[:cntrl:]]\+' + \ nextgroup=@slpconfAttrValueCon skipwhite + +syn match slpconfAttrSSValue contained display '\\FF\%(\\\x\x\)\+' + \ nextgroup=@slpconfAttrValueCon skipwhite + +syn match slpconfAttrIValue contained display '[-]\=\d\+\>' + \ nextgroup=@slpconfAttrValueCon skipwhite + +syn keyword slpconfAttrBValue contained true false + \ nextgroup=@slpconfAttrValueCon skipwhite + +syn match slpconfAttrValueSep contained display ',' + \ nextgroup=@slpconfAttrValue skipwhite + +syn match slpconfAttrEnd contained display ')' + \ nextgroup=slpconfAttrSep skipwhite + +syn match slpconfAttrSep contained display ',' + \ nextgroup=slpconfAttrBegin skipwhite + +syn keyword slpconfNetSlpTag contained useScopes typeHint + \ nextgroup=slpconfStringsEq,slpconfStringsHome + \ skipwhite + +syn match slpconfStringsHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfStringsEq skipwhite + +syn match slpconfStringsEq contained display '=' + \ nextgroup=slpconfStrings skipwhite + +syn match slpconfStrings contained display + \ '\%([[:digit:][:alpha:]]\|[!-+./:-@[-`{-~-]\|\\\x\x\)\+' + \ nextgroup=slpconfStringsSep skipwhite + +syn match slpconfStringsSep contained display ',' + \ nextgroup=slpconfStrings skipwhite + +syn keyword slpconfNetSlpTag contained DAAddresses + \ nextgroup=slpconfAddressesEq,slpconfAddrsHome + \ skipwhite + +syn match slpconfAddrsHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfAddressesEq skipwhite + +syn match slpconfAddressesEq contained display '=' + \ nextgroup=@slpconfAddresses skipwhite + +syn cluster slpconfAddresses contains=slpconfFQDNs,slpconfHostnumbers + +syn match slpconfFQDNs contained display + \ '\a[[:alnum:]-]*[[:alnum:]]\|\a' + \ nextgroup=slpconfAddressesSep skipwhite + +syn match slpconfHostnumbers contained display + \ '\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfAddressesSep skipwhite + +syn match slpconfAddressesSep contained display ',' + \ nextgroup=@slpconfAddresses skipwhite + +syn keyword slpconfNetSlpTag contained serializedRegURL + \ nextgroup=slpconfStringEq,slpconfStringHome + \ skipwhite + +syn match slpconfStringHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfStringEq skipwhite + +syn match slpconfStringEq contained display '=' + \ nextgroup=slpconfString skipwhite + +syn match slpconfString contained display + \ '\%([!-+./:-@[-`{-~-]\|\\\x\x\)\+\|[[:digit:][:alpha:]]' + +syn keyword slpconfNetSlpTag contained multicastTimeouts DADiscoveryTimeouts + \ datagramTimeouts + \ nextgroup=slpconfIntegersEq, + \ slpconfIntegersHome skipwhite + +syn match slpconfIntegersHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfIntegersEq skipwhite + +syn match slpconfIntegersEq contained display '=' + \ nextgroup=slpconfIntegers skipwhite + +syn match slpconfIntegers contained display '\<\d\+\>' + \ nextgroup=slpconfIntegersSep skipwhite + +syn match slpconfIntegersSep contained display ',' + \ nextgroup=slpconfIntegers skipwhite + +syn keyword slpconfNetSlpTag contained interfaces + \ nextgroup=slpconfHostnumsEq, + \ slpconfHostnumsHome skipwhite + +syn match slpconfHostnumsHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfHostnumsEq skipwhite + +syn match slpconfHostnumsEq contained display '=' + \ nextgroup=slpconfOHostnumbers skipwhite + +syn match slpconfOHostnumbers contained display + \ '\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfHostnumsSep skipwhite + +syn match slpconfHostnumsSep contained display ',' + \ nextgroup=slpconfOHostnumbers skipwhite + +syn keyword slpconfNetSlpTag contained locale + \ nextgroup=slpconfLocaleEq,slpconfLocaleHome + \ skipwhite + +syn match slpconfLocaleHome contained display + \ '\.\d\{1,3}\%(\.\d\{1,3}\)\{3}' + \ nextgroup=slpconfLocaleEq skipwhite + +syn match slpconfLocaleEq contained display '=' + \ nextgroup=slpconfLocale skipwhite + +syn match slpconfLocale contained display '\a\{1,8}\%(-\a\{1,8}\)\=' + +hi def link slpconfTodo Todo +hi def link slpconfComment Comment +hi def link slpconfTag Identifier +hi def link slpconfDelimiter Delimiter +hi def link slpconfNetTagDot slpconfDelimiter +hi def link slpconfNetTag slpconfTag +hi def link slpconfNetSlpTagDot slpconfNetTagDot +hi def link slpconfNetSlpTag slpconfTag +hi def link slpconfHome Special +hi def link slpconfBooleanHome slpconfHome +hi def link slpconfEq Operator +hi def link slpconfBooleanEq slpconfEq +hi def link slpconfBoolean Boolean +hi def link slpconfIntegerHome slpconfHome +hi def link slpconfIntegerEq slpconfEq +hi def link slpconfInteger Number +hi def link slpconfAttrHome slpconfHome +hi def link slpconfAttrEq slpconfEq +hi def link slpconfAttrBegin slpconfDelimiter +hi def link slpconfAttrTag slpconfTag +hi def link slpconfAttrTagEq slpconfEq +hi def link slpconfAttrIValue slpconfInteger +hi def link slpconfAttrSValue slpconfString +hi def link slpconfAttrBValue slpconfBoolean +hi def link slpconfAttrSSValue slpconfString +hi def link slpconfSeparator slpconfDelimiter +hi def link slpconfAttrValueSep slpconfSeparator +hi def link slpconfAttrEnd slpconfAttrBegin +hi def link slpconfAttrSep slpconfSeparator +hi def link slpconfStringsHome slpconfHome +hi def link slpconfStringsEq slpconfEq +hi def link slpconfStrings slpconfString +hi def link slpconfStringsSep slpconfSeparator +hi def link slpconfAddrsHome slpconfHome +hi def link slpconfAddressesEq slpconfEq +hi def link slpconfFQDNs String +hi def link slpconfHostnumbers Number +hi def link slpconfAddressesSep slpconfSeparator +hi def link slpconfStringHome slpconfHome +hi def link slpconfStringEq slpconfEq +hi def link slpconfString String +hi def link slpconfIntegersHome slpconfHome +hi def link slpconfIntegersEq slpconfEq +hi def link slpconfIntegers slpconfInteger +hi def link slpconfIntegersSep slpconfSeparator +hi def link slpconfHostnumsHome slpconfHome +hi def link slpconfHostnumsEq slpconfEq +hi def link slpconfOHostnumbers slpconfHostnumbers +hi def link slpconfHostnumsSep slpconfSeparator +hi def link slpconfLocaleHome slpconfHome +hi def link slpconfLocaleEq slpconfEq +hi def link slpconfLocale slpconfString + +let b:current_syntax = "slpconf" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/slpreg.vim b/syntax/slpreg.vim new file mode 100644 index 0000000..14fdb00 --- /dev/null +++ b/syntax/slpreg.vim @@ -0,0 +1,126 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: RFC 2614 - An API for Service Location registration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword slpregTodo contained TODO FIXME XXX NOTE + +syn region slpregComment display oneline start='^[#;]' end='$' + \ contains=slpregTodo,@Spell + +syn match slpregBegin display '^' + \ nextgroup=slpregServiceURL, + \ slpregComment + +syn match slpregServiceURL contained display 'service:' + \ nextgroup=slpregServiceType + +syn match slpregServiceType contained display '\a[[:alpha:][:digit:]+-]*\%(\.\a[[:alpha:][:digit:]+-]*\)\=\%(:\a[[:alpha:][:digit:]+-]*\)\=' + \ nextgroup=slpregServiceSAPCol + +syn match slpregServiceSAPCol contained display ':' + \ nextgroup=slpregSAP + +syn match slpregSAP contained '[^,]\+' + \ nextgroup=slpregLangSep +"syn match slpregSAP contained display '\%(//\%(\%([[:alpha:][:digit:]$-_.~!*\'(),+;&=]*@\)\=\%([[:alnum:]][[:alnum:]-]*[[:alnum:]]\|[[:alnum:]]\.\)*\%(\a[[:alnum:]-]*[[:alnum:]]\|\a\)\%(:\d\+\)\=\)\=\|/at/\%([[:alpha:][:digit:]$-_.~]\|\\\x\x\)\{1,31}:\%([[:alpha:][:digit:]$-_.~]\|\\\x\x\)\{1,31}\%([[:alpha:][:digit:]$-_.~]\|\\\x\x\)\{1,31}\|/ipx/\x\{8}:\x\{12}:\x\{4}\)\%(/\%([[:alpha:][:digit:]$-_.~!*\'()+;?:@&=+]\|\\\x\x\)*\)*\%(;[^()\\!<=>~[:cntrl:]* \t_]\+\%(=[^()\\!<=>~[:cntrl:] ]\+\)\=\)*' + +syn match slpregLangSep contained display ',' + \ nextgroup=slpregLang + +syn match slpregLang contained display '\a\{1,8}\%(-\a\{1,8\}\)\=' + \ nextgroup=slpregLTimeSep + +syn match slpregLTimeSep contained display ',' + \ nextgroup=slpregLTime + +syn match slpregLTime contained display '\d\{1,5}' + \ nextgroup=slpregType,slpregUNewline + +syn match slpregType contained display '\a[[:alpha:][:digit:]+-]*' + \ nextgroup=slpregUNewLine + +syn match slpregUNewLine contained '\s*\n' + \ nextgroup=slpregScopes,slpregAttrList skipnl + +syn keyword slpregScopes contained scopes + \ nextgroup=slpregScopesEq + +syn match slpregScopesEq contained '=' nextgroup=slpregScopeName + +syn match slpregScopeName contained '[^(),\\!<=>[:cntrl:];*+ ]\+' + \ nextgroup=slpregScopeNameSep, + \ slpregScopeNewline + +syn match slpregScopeNameSep contained ',' + \ nextgroup=slpregScopeName + +syn match slpregScopeNewline contained '\s*\n' + \ nextgroup=slpregAttribute skipnl + +syn match slpregAttribute contained '[^(),\\!<=>[:cntrl:]* \t_]\+' + \ nextgroup=slpregAttributeEq, + \ slpregScopeNewline + +syn match slpregAttributeEq contained '=' + \ nextgroup=@slpregAttrValue + +syn cluster slpregAttrValueCon contains=slpregAttribute,slpregAttrValueSep + +syn cluster slpregAttrValue contains=slpregAttrIValue,slpregAttrSValue, + \ slpregAttrBValue,slpregAttrSSValue + +syn match slpregAttrSValue contained display '[^(),\\!<=>~[:cntrl:]]\+' + \ nextgroup=@slpregAttrValueCon skipwhite skipnl + +syn match slpregAttrSSValue contained display '\\FF\%(\\\x\x\)\+' + \ nextgroup=@slpregAttrValueCon skipwhite skipnl + +syn match slpregAttrIValue contained display '[-]\=\d\+\>' + \ nextgroup=@slpregAttrValueCon skipwhite skipnl + +syn keyword slpregAttrBValue contained true false + \ nextgroup=@slpregAttrValueCon skipwhite skipnl + +syn match slpregAttrValueSep contained display ',' + \ nextgroup=@slpregAttrValue skipwhite skipnl + +hi def link slpregTodo Todo +hi def link slpregComment Comment +hi def link slpregServiceURL Type +hi def link slpregServiceType slpregServiceURL +hi def link slpregServiceSAPCol slpregServiceURL +hi def link slpregSAP slpregServiceURL +hi def link slpregDelimiter Delimiter +hi def link slpregLangSep slpregDelimiter +hi def link slpregLang String +hi def link slpregLTimeSep slpregDelimiter +hi def link slpregLTime Number +hi def link slpregType Type +hi def link slpregScopes Identifier +hi def link slpregScopesEq Operator +hi def link slpregScopeName String +hi def link slpregScopeNameSep slpregDelimiter +hi def link slpregAttribute Identifier +hi def link slpregAttributeEq Operator +hi def link slpregAttrSValue String +hi def link slpregAttrSSValue slpregAttrSValue +hi def link slpregAttrIValue Number +hi def link slpregAttrBValue Boolean +hi def link slpregAttrValueSep slpregDelimiter + +let b:current_syntax = "slpreg" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/slpspi.vim b/syntax/slpspi.vim new file mode 100644 index 0000000..6873323 --- /dev/null +++ b/syntax/slpspi.vim @@ -0,0 +1,43 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: RFC 2614 - An API for Service Location SPI file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword slpspiTodo contained TODO FIXME XXX NOTE + +syn region slpspiComment display oneline start='^[#;]' end='$' + \ contains=slpspiTodo,@Spell + +syn match slpspiBegin display '^' + \ nextgroup=slpspiKeyType, + \ slpspiComment skipwhite + +syn keyword slpspiKeyType contained PRIVATE PUBLIC + \ nextgroup=slpspiString skipwhite + +syn match slpspiString contained '\S\+' + \ nextgroup=slpspiKeyFile skipwhite + +syn match slpspiKeyFile contained '\S\+' + +hi def link slpspiTodo Todo +hi def link slpspiComment Comment +hi def link slpspiKeyType Type +hi def link slpspiString Identifier +hi def link slpspiKeyFile String + +let b:current_syntax = "slpspi" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/slrnrc.vim b/syntax/slrnrc.vim new file mode 100644 index 0000000..7d195fe --- /dev/null +++ b/syntax/slrnrc.vim @@ -0,0 +1,185 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Slrn setup file (based on slrn 0.9.8.1) +" Maintainer: Preben 'Peppe' Guldberg +" Last Change: 23 April 2006 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword slrnrcTodo contained Todo + +" In some places whitespace is illegal +syn match slrnrcSpaceError contained "\s" + +syn match slrnrcNumber contained "-\=\<\d\+\>" +syn match slrnrcNumber contained +'[^']\+'+ + +syn match slrnrcSpecKey contained +\(\\[er"']\|\^[^'"]\|\\\o\o\o\)+ + +syn match slrnrcKey contained "\S\+" contains=slrnrcSpecKey +syn region slrnrcKey contained start=+"+ skip=+\\"+ end=+"+ oneline contains=slrnrcSpecKey +syn region slrnrcKey contained start=+'+ skip=+\\'+ end=+'+ oneline contains=slrnrcSpecKey + +syn match slrnrcSpecChar contained +'+ +syn match slrnrcSpecChar contained +\\[n"]+ +syn match slrnrcSpecChar contained "%[dfmnrs%]" + +syn match slrnrcString contained /[^ \t%"']\+/ contains=slrnrcSpecChar +syn region slrnrcString contained start=+"+ skip=+\\"+ end=+"+ oneline contains=slrnrcSpecChar + +syn match slrnSlangPreCondit "^#\s*ifn\=\(def\>\|false\>\|true\>\|\$\)" +syn match slrnSlangPreCondit "^#\s*e\(lif\|lse\|ndif\)\>" + +syn match slrnrcComment "%.*$" contains=slrnrcTodo + +syn keyword slrnrcVarInt contained abort_unmodified_edits article_window_page_overlap auto_mark_article_as_read beep broken_xref broken_xref cc_followup check_new_groups +syn keyword slrnrcVarInt contained color_by_score confirm_actions custom_sort_by_threads display_cursor_bar drop_bogus_groups editor_uses_mime_charset emphasized_text_mask +syn keyword slrnrcVarInt contained emphasized_text_mode fold_headers fold_headers followup_strip_signature force_authentication force_authentication generate_date_header +syn keyword slrnrcVarInt contained generate_email_from generate_email_from generate_message_id grouplens_port hide_pgpsignature hide_quotes hide_signature +syn keyword slrnrcVarInt contained hide_verbatim_marks hide_verbatim_text highlight_unread_subjects highlight_urls ignore_signature kill_score lines_per_update +syn keyword slrnrcVarInt contained mail_editor_is_mua max_low_score max_queued_groups min_high_score mouse netiquette_warnings new_subject_breaks_threads no_autosave +syn keyword slrnrcVarInt contained no_backups prefer_head process_verbatim_marks query_next_article query_next_group query_read_group_cutoff read_active reject_long_lines +syn keyword slrnrcVarInt contained scroll_by_page show_article show_thread_subject simulate_graphic_chars smart_quote sorting_method spoiler_char spoiler_char +syn keyword slrnrcVarInt contained spoiler_display_mode spoiler_display_mode spool_check_up_on_nov spool_check_up_on_nov uncollapse_threads unsubscribe_new_groups use_blink +syn keyword slrnrcVarInt contained use_color use_flow_control use_grouplens use_grouplens use_header_numbers use_inews use_inews use_localtime use_metamail use_mime use_mime +syn keyword slrnrcVarInt contained use_recommended_msg_id use_slrnpull use_slrnpull use_tilde use_tmpdir use_uudeview use_uudeview warn_followup_to wrap_flags wrap_method +syn keyword slrnrcVarInt contained write_newsrc_flags + +" Listed for removal +syn keyword slrnrcVarInt contained author_display display_author_realname display_score group_dsc_start_column process_verbatum_marks prompt_next_group query_reconnect +syn keyword slrnrcVarInt contained show_descriptions use_xgtitle + +" Match as a "string" too +syn region slrnrcVarIntStr contained matchgroup=slrnrcVarInt start=+"+ end=+"+ oneline contains=slrnrcVarInt,slrnrcSpaceError + +syn keyword slrnrcVarStr contained Xbrowser art_help_line art_status_line cansecret_file cc_post_string charset custom_headers custom_sort_order decode_directory +syn keyword slrnrcVarStr contained editor_command failed_posts_file followup_custom_headers followup_date_format followup_string followupto_string group_help_line +syn keyword slrnrcVarStr contained group_status_line grouplens_host grouplens_pseudoname header_help_line header_status_line hostname inews_program macro_directory +syn keyword slrnrcVarStr contained mail_editor_command metamail_command mime_charset non_Xbrowser organization overview_date_format post_editor_command post_object +syn keyword slrnrcVarStr contained postpone_directory printer_name quote_string realname reply_custom_headers reply_string replyto save_directory save_posts save_replies +syn keyword slrnrcVarStr contained score_editor_command scorefile sendmail_command server_object signature signoff_string spool_active_file spool_activetimes_file +syn keyword slrnrcVarStr contained spool_inn_root spool_newsgroups_file spool_nov_file spool_nov_root spool_overviewfmt_file spool_root supersedes_custom_headers +syn keyword slrnrcVarStr contained top_status_line username + +" Listed for removal +syn keyword slrnrcVarStr contained followup cc_followup_string + +" Match as a "string" too +syn region slrnrcVarStrStr contained matchgroup=slrnrcVarStr start=+"+ end=+"+ oneline contains=slrnrcVarStr,slrnrcSpaceError + +" Various commands +syn region slrnrcCmdLine matchgroup=slrnrcCmd start="\<\(autobaud\|color\|compatible_charsets\|group_display_format\|grouplens_add\|header_display_format\|ignore_quotes\|include\|interpret\|mono\|nnrpaccess\|posting_host\|server\|set\|setkey\|strip_re_regexp\|strip_sig_regexp\|strip_was_regexp\|unsetkey\|visible_headers\)\>" end="$" oneline contains=slrnrc\(String\|Comment\) + +" Listed for removal +syn region slrnrcCmdLine matchgroup=slrnrcCmd start="\<\(cc_followup_string\|decode_directory\|editor_command\|followup\|hostname\|organization\|quote_string\|realname\|replyto\|scorefile\|signature\|username\)\>" end="$" oneline contains=slrnrc\(String\|Comment\) + +" Setting variables +syn keyword slrnrcSet contained set +syn match slrnrcSetStr "^\s*set\s\+\S\+" skipwhite nextgroup=slrnrcString contains=slrnrcSet,slrnrcVarStr\(Str\)\= +syn match slrnrcSetInt contained "^\s*set\s\+\S\+" contains=slrnrcSet,slrnrcVarInt\(Str\)\= +syn match slrnrcSetIntLine "^\s*set\s\+\S\+\s\+\(-\=\d\+\>\|'[^']\+'\)" contains=slrnrcSetInt,slrnrcNumber,slrnrcVarInt + +" Color definitions +syn match slrnrcColorObj contained "\" +syn keyword slrnrcColorObj contained article author boldtext box cursor date description error frame from_myself group grouplens_display header_name header_number headers +syn keyword slrnrcColorObj contained high_score italicstext menu menu_press message neg_score normal pgpsignature pos_score quotes response_char selection signature status +syn keyword slrnrcColorObj contained subject thread_number tilde tree underlinetext unread_subject url verbatim + +" Listed for removal +syn keyword slrnrcColorObj contained verbatum + +syn region slrnrcColorObjStr contained matchgroup=slrnrcColorObj start=+"+ end=+"+ oneline contains=slrnrcColorObj,slrnrcSpaceError +syn keyword slrnrcColorVal contained default +syn keyword slrnrcColorVal contained black blue brightblue brightcyan brightgreen brightmagenta brightred brown cyan gray green lightgray magenta red white yellow +syn region slrnrcColorValStr contained matchgroup=slrnrcColorVal start=+"+ end=+"+ oneline contains=slrnrcColorVal,slrnrcSpaceError +" Mathcing a function with three arguments +syn keyword slrnrcColor contained color +syn match slrnrcColorInit contained "^\s*color\s\+\S\+" skipwhite nextgroup=slrnrcColorVal\(Str\)\= contains=slrnrcColor\(Obj\|ObjStr\)\= +syn match slrnrcColorLine "^\s*color\s\+\S\+\s\+\S\+" skipwhite nextgroup=slrnrcColorVal\(Str\)\= contains=slrnrcColor\(Init\|Val\|ValStr\) + +" Mono settings +syn keyword slrnrcMonoVal contained blink bold none reverse underline +syn region slrnrcMonoValStr contained matchgroup=slrnrcMonoVal start=+"+ end=+"+ oneline contains=slrnrcMonoVal,slrnrcSpaceError +" Color object is inherited +" Mono needs at least one argument +syn keyword slrnrcMono contained mono +syn match slrnrcMonoInit contained "^\s*mono\s\+\S\+" contains=slrnrcMono,slrnrcColorObj\(Str\)\= +syn match slrnrcMonoLine "^\s*mono\s\+\S\+\s\+\S.*" contains=slrnrcMono\(Init\|Val\|ValStr\),slrnrcComment + +" Functions in article mode +syn keyword slrnrcFunArt contained article_bob article_eob article_left article_line_down article_line_up article_page_down article_page_up article_right article_search +syn keyword slrnrcFunArt contained author_search_backward author_search_forward browse_url cancel catchup catchup_all create_score decode delete delete_thread digit_arg +syn keyword slrnrcFunArt contained enlarge_article_window evaluate_cmd exchange_mark expunge fast_quit followup forward forward_digest get_children_headers get_parent_header +syn keyword slrnrcFunArt contained goto_article goto_last_read grouplens_rate_article header_bob header_eob header_line_down header_line_up header_page_down header_page_up +syn keyword slrnrcFunArt contained help hide_article locate_article mark_spot next next_high_score next_same_subject pipe post post_postponed previous print quit redraw +syn keyword slrnrcFunArt contained repeat_last_key reply request save show_spoilers shrink_article_window skip_quotes skip_to_next_group skip_to_previous_group +syn keyword slrnrcFunArt contained subject_search_backward subject_search_forward supersede suspend tag_header toggle_collapse_threads toggle_header_formats +syn keyword slrnrcFunArt contained toggle_header_tag toggle_headers toggle_pgpsignature toggle_quotes toggle_rot13 toggle_signature toggle_sort toggle_verbatim_marks +syn keyword slrnrcFunArt contained toggle_verbatim_text uncatchup uncatchup_all undelete untag_headers view_scores wrap_article zoom_article_window + +" Listed for removal +syn keyword slrnrcFunArt contained art_bob art_eob art_xpunge article_linedn article_lineup article_pagedn article_pageup down enlarge_window goto_beginning goto_end left +syn keyword slrnrcFunArt contained locate_header_by_msgid pagedn pageup pipe_article prev print_article right scroll_dn scroll_up shrink_window skip_to_prev_group +syn keyword slrnrcFunArt contained toggle_show_author up + +" Functions in group mode +syn keyword slrnrcFunGroup contained add_group bob catchup digit_arg eob evaluate_cmd group_search group_search_backward group_search_forward help line_down line_up move_group +syn keyword slrnrcFunGroup contained page_down page_up post post_postponed quit redraw refresh_groups repeat_last_key save_newsrc select_group subscribe suspend +syn keyword slrnrcFunGroup contained toggle_group_formats toggle_hidden toggle_list_all toggle_scoring transpose_groups uncatchup unsubscribe + +" Listed for removal +syn keyword slrnrcFunGroup contained down group_bob group_eob pagedown pageup toggle_group_display uncatch_up up + +" Functions in readline mode (actually from slang's slrline.c) +syn keyword slrnrcFunRead contained bdel bol complete cycle del delbol delbow deleol down enter eol left quoted_insert right self_insert trim up + +" Binding keys +syn keyword slrnrcSetkeyObj contained article group readline +syn region slrnrcSetkeyObjStr contained matchgroup=slrnrcSetkeyObj start=+"+ end=+"+ oneline contains=slrnrcSetkeyObj +syn match slrnrcSetkeyArt contained '\("\=\)\\1\s\+\S\+' skipwhite nextgroup=slrnrcKey contains=slrnrcSetKeyObj\(Str\)\=,slrnrcFunArt +syn match slrnrcSetkeyGroup contained '\("\=\)\\1\s\+\S\+' skipwhite nextgroup=slrnrcKey contains=slrnrcSetKeyObj\(Str\)\=,slrnrcFunGroup +syn match slrnrcSetkeyRead contained '\("\=\)\\1\s\+\S\+' skipwhite nextgroup=slrnrcKey contains=slrnrcSetKeyObj\(Str\)\=,slrnrcFunRead +syn match slrnrcSetkey "^\s*setkey\>" skipwhite nextgroup=slrnrcSetkeyArt,slrnrcSetkeyGroup,slrnrcSetkeyRead + +" Unbinding keys +syn match slrnrcUnsetkey '^\s*unsetkey\s\+\("\)\=\(article\|group\|readline\)\>\1' skipwhite nextgroup=slrnrcKey contains=slrnrcSetkeyObj\(Str\)\= + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link slrnrcTodo Todo +hi def link slrnrcSpaceError Error +hi def link slrnrcNumber Number +hi def link slrnrcSpecKey SpecialChar +hi def link slrnrcKey String +hi def link slrnrcSpecChar SpecialChar +hi def link slrnrcString String +hi def link slrnSlangPreCondit Special +hi def link slrnrcComment Comment +hi def link slrnrcVarInt Identifier +hi def link slrnrcVarStr Identifier +hi def link slrnrcCmd slrnrcSet +hi def link slrnrcSet Operator +hi def link slrnrcColor Keyword +hi def link slrnrcColorObj Identifier +hi def link slrnrcColorVal String +hi def link slrnrcMono Keyword +hi def link slrnrcMonoObj Identifier +hi def link slrnrcMonoVal String +hi def link slrnrcFunArt Macro +hi def link slrnrcFunGroup Macro +hi def link slrnrcFunRead Macro +hi def link slrnrcSetkeyObj Identifier +hi def link slrnrcSetkey Keyword +hi def link slrnrcUnsetkey slrnrcSetkey + + +let b:current_syntax = "slrnrc" + +"EOF vim: ts=8 noet tw=120 sw=8 sts=0 + +endif diff --git a/syntax/slrnsc.vim b/syntax/slrnsc.vim new file mode 100644 index 0000000..deb03b6 --- /dev/null +++ b/syntax/slrnsc.vim @@ -0,0 +1,72 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Slrn score file (based on slrn 0.9.8.0) +" Maintainer: Preben 'Peppe' Guldberg +" Last Change: 8 Oct 2004 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" characters in newsgroup names +setlocal isk=@,48-57,.,-,_,+ + +syn match slrnscComment "%.*$" +syn match slrnscSectionCom ".].*"lc=2 + +syn match slrnscGroup contained "\(\k\|\*\)\+" +syn match slrnscNumber contained "\d\+" +syn match slrnscDate contained "\(\d\{1,2}[-/]\)\{2}\d\{4}" +syn match slrnscDelim contained ":" +syn match slrnscComma contained "," +syn match slrnscOper contained "\~" +syn match slrnscEsc contained "\\[ecC<>.]" +syn match slrnscEsc contained "[?^]" +syn match slrnscEsc contained "[^\\]$\s*$"lc=1 + +syn keyword slrnscInclude contained include +syn match slrnscIncludeLine "^\s*Include\s\+\S.*$" + +syn region slrnscSection matchgroup=slrnscSectionStd start="^\s*\[" end='\]' contains=slrnscGroup,slrnscComma,slrnscSectionCom +syn region slrnscSection matchgroup=slrnscSectionNot start="^\s*\[\~" end='\]' contains=slrnscGroup,slrnscCommas,slrnscSectionCom + +syn keyword slrnscItem contained Age Bytes Date Expires From Has-Body Lines Message-Id Newsgroup References Subject Xref + +syn match slrnscScoreItem contained "%.*$" skipempty nextgroup=slrnscScoreItem contains=slrnscComment +syn match slrnscScoreItem contained "^\s*Expires:\s*\(\d\{1,2}[-/]\)\{2}\d\{4}\s*$" skipempty nextgroup=slrnscScoreItem contains=slrnscItem,slrnscDelim,slrnscDate +syn match slrnscScoreItem contained "^\s*\~\=\(Age\|Bytes\|Has-Body\|Lines\):\s*\d\+\s*$" skipempty nextgroup=slrnscScoreItem contains=slrnscOper,slrnscItem,slrnscDelim,slrnscNumber +syn match slrnscScoreItemFill contained ".*$" skipempty nextgroup=slrnscScoreItem contains=slrnscEsc +syn match slrnscScoreItem contained "^\s*\~\=\(Date\|From\|Message-Id\|Newsgroup\|References\|Subject\|Xref\):" nextgroup=slrnscScoreItemFill contains=slrnscOper,slrnscItem,slrnscDelim +syn region slrnscScoreItem contained matchgroup=Special start="^\s*\~\={::\=" end="^\s*}" skipempty nextgroup=slrnscScoreItem contains=slrnscScoreItem + +syn keyword slrnscScore contained Score +syn match slrnscScoreIdent contained "%.*" +syn match slrnScoreLine "^\s*Score::\=\s\+=\=[-+]\=\d\+\s*\(%.*\)\=$" skipempty nextgroup=slrnscScoreItem contains=slrnscScore,slrnscDelim,slrnscOper,slrnscNumber,slrnscScoreIdent + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link slrnscComment Comment +hi def link slrnscSectionCom slrnscComment +hi def link slrnscGroup String +hi def link slrnscNumber Number +hi def link slrnscDate Special +hi def link slrnscDelim Delimiter +hi def link slrnscComma SpecialChar +hi def link slrnscOper SpecialChar +hi def link slrnscEsc String +hi def link slrnscSectionStd Type +hi def link slrnscSectionNot Delimiter +hi def link slrnscItem Statement +hi def link slrnscScore Keyword +hi def link slrnscScoreIdent Identifier +hi def link slrnscInclude Keyword + + +let b:current_syntax = "slrnsc" + +"EOF vim: ts=8 noet tw=200 sw=8 sts=0 + +endif diff --git a/syntax/sm.vim b/syntax/sm.vim new file mode 100644 index 0000000..f047bc5 --- /dev/null +++ b/syntax/sm.vim @@ -0,0 +1,84 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sendmail +" Maintainer: Charles E. Campbell +" Last Change: Oct 25, 2016 +" Version: 8 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_SM +if exists("b:current_syntax") + finish +endif + +" Comments +syn match smComment "^#.*$" contains=@Spell + +" Definitions, Classes, Files, Options, Precedence, Trusted Users, Mailers +syn match smDefine "^[CDF]." +syn match smDefine "^O[AaBcdDeFfgHiLmNoQqrSsTtuvxXyYzZ]" +syn match smDefine "^O\s"he=e-1 +syn match smDefine "^M[a-zA-Z0-9]\+,"he=e-1 +syn match smDefine "^T" nextgroup=smTrusted +syn match smDefine "^P" nextgroup=smMesg +syn match smTrusted "\S\+$" contained +syn match smMesg "\S*="he=e-1 contained nextgroup=smPrecedence +syn match smPrecedence "-\=[0-9]\+" contained + +" Header Format H?list-of-mailer-flags?name: format +syn match smHeaderSep contained "[?:]" +syn match smHeader "^H\(?[a-zA-Z]\+?\)\=[-a-zA-Z_]\+:" contains=smHeaderSep + +" Variables +syn match smVar "\$[a-z\.\|]" + +" Rulesets +syn match smRuleset "^S\d*" + +" Rewriting Rules +syn match smRewrite "^R" skipwhite nextgroup=smRewriteLhsToken,smRewriteLhsUser + +syn match smRewriteLhsUser contained "[^\t$]\+" skipwhite nextgroup=smRewriteLhsToken,smRewriteLhsSep +syn match smRewriteLhsToken contained "\(\$[-*+]\|\$[-=][A-Za-z]\|\$Y\)\+" skipwhite nextgroup=smRewriteLhsUser,smRewriteLhsSep + +syn match smRewriteLhsSep contained "\t\+" skipwhite nextgroup=smRewriteRhsToken,smRewriteRhsUser + +syn match smRewriteRhsUser contained "[^\t$]\+" skipwhite nextgroup=smRewriteRhsToken,smRewriteRhsSep +syn match smRewriteRhsToken contained "\(\$\d\|\$>\d\|\$#\|\$@\|\$:[-_a-zA-Z]\+\|\$[[\]]\|\$@\|\$:\|\$[A-Za-z]\)\+" skipwhite nextgroup=smRewriteRhsUser,smRewriteRhsSep + +syn match smRewriteRhsSep contained "\t\+" skipwhite nextgroup=smRewriteComment,smRewriteRhsSep +syn match smRewriteRhsSep contained "$" + +syn match smRewriteComment contained "[^\t$]*$" + +" Clauses +syn match smClauseError "\$\." +syn match smElse contained "\$|" +syn match smClauseCont contained "^\t" +syn region smClause matchgroup=Delimiter start="\$?." matchgroup=Delimiter end="\$\." contains=smElse,smClause,smVar,smClauseCont + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link smClause Special +hi def link smClauseError Error +hi def link smComment Comment +hi def link smDefine Statement +hi def link smElse Delimiter +hi def link smHeader Statement +hi def link smHeaderSep String +hi def link smMesg Special +hi def link smPrecedence Number +hi def link smRewrite Statement +hi def link smRewriteComment Comment +hi def link smRewriteLhsToken String +hi def link smRewriteLhsUser Statement +hi def link smRewriteRhsToken String +hi def link smRuleset Preproc +hi def link smTrusted Special +hi def link smVar String + +let b:current_syntax = "sm" + +" vim: ts=18 + +endif diff --git a/syntax/smarty.vim b/syntax/smarty.vim new file mode 100644 index 0000000..f0e44f7 --- /dev/null +++ b/syntax/smarty.vim @@ -0,0 +1,80 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Smarty Templates +" Maintainer: Manfred Stienstra manfred.stienstra@dwerg.net +" Last Change: Mon Nov 4 11:42:23 CET 2002 +" Filenames: *.tpl +" URL: http://www.dwerg.net/projects/vim/smarty.vim + +" For version 5.x: Clear all syntax items +" For version 6.x: Quit when a syntax file was already loaded +if !exists("main_syntax") + " quit when a syntax file was already loaded + if exists("b:current_syntax") + finish + endif + let main_syntax = 'smarty' +endif + +syn case ignore + +runtime! syntax/html.vim +"syn cluster htmlPreproc add=smartyUnZone + +syn match smartyBlock contained "[\[\]]" + +syn keyword smartyTagName capture config_load include include_php +syn keyword smartyTagName insert if elseif else ldelim rdelim literal +syn keyword smartyTagName php section sectionelse foreach foreachelse +syn keyword smartyTagName strip assign counter cycle debug eval fetch +syn keyword smartyTagName html_options html_select_date html_select_time +syn keyword smartyTagName math popup_init popup html_checkboxes html_image +syn keyword smartyTagName html_radios html_table mailto textformat + +syn keyword smartyModifier cat capitalize count_characters count_paragraphs +syn keyword smartyModifier count_sentences count_words date_format default +syn keyword smartyModifier escape indent lower nl2br regex_replace replace +syn keyword smartyModifier spacify string_format strip strip_tags truncate +syn keyword smartyModifier upper wordwrap + +syn keyword smartyInFunc neq eq + +syn keyword smartyProperty contained "file=" +syn keyword smartyProperty contained "loop=" +syn keyword smartyProperty contained "name=" +syn keyword smartyProperty contained "include=" +syn keyword smartyProperty contained "skip=" +syn keyword smartyProperty contained "section=" + +syn keyword smartyConstant "\$smarty" + +syn keyword smartyDot . + +syn region smartyZone matchgroup=Delimiter start="{" end="}" contains=smartyProperty, smartyString, smartyBlock, smartyTagName, smartyConstant, smartyInFunc, smartyModifier + +syn region htmlString contained start=+"+ end=+"+ contains=htmlSpecialChar,javaScriptExpression,@htmlPreproc,smartyZone +syn region htmlString contained start=+'+ end=+'+ contains=htmlSpecialChar,javaScriptExpression,@htmlPreproc,smartyZone + syn region htmlLink start="\_[^>]*\" end="
"me=e-4 contains=@Spell,htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,javaScript,@htmlPreproc,smartyZone + + + +hi def link smartyTagName Identifier +hi def link smartyProperty Constant +" if you want the text inside the braces to be colored, then +" remove the comment in from of the next statement +"hi def link smartyZone Include +hi def link smartyInFunc Function +hi def link smartyBlock Constant +hi def link smartyDot SpecialChar +hi def link smartyModifier Function + +let b:current_syntax = "smarty" + +if main_syntax == 'smarty' + unlet main_syntax +endif + +" vim: ts=8 + +endif diff --git a/syntax/smcl.vim b/syntax/smcl.vim new file mode 100644 index 0000000..c1472e2 --- /dev/null +++ b/syntax/smcl.vim @@ -0,0 +1,311 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" smcl.vim -- Vim syntax file for smcl files. +" Language: SMCL -- Stata Markup and Control Language +" Maintainer: Jeff Pitblado +" Last Change: 26apr2006 +" Version: 1.1.2 + +" Log: +" 20mar2003 updated the match definition for cmdab +" 14apr2006 'syntax clear' only under version control +" check for 'b:current_syntax', removed 'did_smcl_syntax_inits' +" 26apr2006 changed 'stata_smcl' to 'smcl' + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syntax case match + +syn keyword smclCCLword current_date contained +syn keyword smclCCLword current_time contained +syn keyword smclCCLword rmsg_time contained +syn keyword smclCCLword stata_version contained +syn keyword smclCCLword version contained +syn keyword smclCCLword born_date contained +syn keyword smclCCLword flavor contained +syn keyword smclCCLword SE contained +syn keyword smclCCLword mode contained +syn keyword smclCCLword console contained +syn keyword smclCCLword os contained +syn keyword smclCCLword osdtl contained +syn keyword smclCCLword machine_type contained +syn keyword smclCCLword byteorder contained +syn keyword smclCCLword sysdir_stata contained +syn keyword smclCCLword sysdir_updates contained +syn keyword smclCCLword sysdir_base contained +syn keyword smclCCLword sysdir_site contained +syn keyword smclCCLword sysdir_plus contained +syn keyword smclCCLword sysdir_personal contained +syn keyword smclCCLword sysdir_oldplace contained +syn keyword smclCCLword adopath contained +syn keyword smclCCLword pwd contained +syn keyword smclCCLword dirsep contained +syn keyword smclCCLword max_N_theory contained +syn keyword smclCCLword max_N_current contained +syn keyword smclCCLword max_k_theory contained +syn keyword smclCCLword max_k_current contained +syn keyword smclCCLword max_width_theory contained +syn keyword smclCCLword max_width_current contained +syn keyword smclCCLword max_matsize contained +syn keyword smclCCLword min_matsize contained +syn keyword smclCCLword max_macrolen contained +syn keyword smclCCLword macrolen contained +syn keyword smclCCLword max_cmdlen contained +syn keyword smclCCLword cmdlen contained +syn keyword smclCCLword namelen contained +syn keyword smclCCLword mindouble contained +syn keyword smclCCLword maxdouble contained +syn keyword smclCCLword epsdouble contained +syn keyword smclCCLword minfloat contained +syn keyword smclCCLword maxfloat contained +syn keyword smclCCLword epsfloat contained +syn keyword smclCCLword minlong contained +syn keyword smclCCLword maxlong contained +syn keyword smclCCLword minint contained +syn keyword smclCCLword maxint contained +syn keyword smclCCLword minbyte contained +syn keyword smclCCLword maxbyte contained +syn keyword smclCCLword maxstrvarlen contained +syn keyword smclCCLword memory contained +syn keyword smclCCLword maxvar contained +syn keyword smclCCLword matsize contained +syn keyword smclCCLword N contained +syn keyword smclCCLword k contained +syn keyword smclCCLword width contained +syn keyword smclCCLword changed contained +syn keyword smclCCLword filename contained +syn keyword smclCCLword filedate contained +syn keyword smclCCLword more contained +syn keyword smclCCLword rmsg contained +syn keyword smclCCLword dp contained +syn keyword smclCCLword linesize contained +syn keyword smclCCLword pagesize contained +syn keyword smclCCLword logtype contained +syn keyword smclCCLword linegap contained +syn keyword smclCCLword scrollbufsize contained +syn keyword smclCCLword varlabelpos contained +syn keyword smclCCLword reventries contained +syn keyword smclCCLword graphics contained +syn keyword smclCCLword scheme contained +syn keyword smclCCLword printcolor contained +syn keyword smclCCLword adosize contained +syn keyword smclCCLword maxdb contained +syn keyword smclCCLword virtual contained +syn keyword smclCCLword checksum contained +syn keyword smclCCLword timeout1 contained +syn keyword smclCCLword timeout2 contained +syn keyword smclCCLword httpproxy contained +syn keyword smclCCLword h_current contained +syn keyword smclCCLword max_matsize contained +syn keyword smclCCLword min_matsize contained +syn keyword smclCCLword max_macrolen contained +syn keyword smclCCLword macrolen contained +syn keyword smclCCLword max_cmdlen contained +syn keyword smclCCLword cmdlen contained +syn keyword smclCCLword namelen contained +syn keyword smclCCLword mindouble contained +syn keyword smclCCLword maxdouble contained +syn keyword smclCCLword epsdouble contained +syn keyword smclCCLword minfloat contained +syn keyword smclCCLword maxfloat contained +syn keyword smclCCLword epsfloat contained +syn keyword smclCCLword minlong contained +syn keyword smclCCLword maxlong contained +syn keyword smclCCLword minint contained +syn keyword smclCCLword maxint contained +syn keyword smclCCLword minbyte contained +syn keyword smclCCLword maxbyte contained +syn keyword smclCCLword maxstrvarlen contained +syn keyword smclCCLword memory contained +syn keyword smclCCLword maxvar contained +syn keyword smclCCLword matsize contained +syn keyword smclCCLword N contained +syn keyword smclCCLword k contained +syn keyword smclCCLword width contained +syn keyword smclCCLword changed contained +syn keyword smclCCLword filename contained +syn keyword smclCCLword filedate contained +syn keyword smclCCLword more contained +syn keyword smclCCLword rmsg contained +syn keyword smclCCLword dp contained +syn keyword smclCCLword linesize contained +syn keyword smclCCLword pagesize contained +syn keyword smclCCLword logtype contained +syn keyword smclCCLword linegap contained +syn keyword smclCCLword scrollbufsize contained +syn keyword smclCCLword varlabelpos contained +syn keyword smclCCLword reventries contained +syn keyword smclCCLword graphics contained +syn keyword smclCCLword scheme contained +syn keyword smclCCLword printcolor contained +syn keyword smclCCLword adosize contained +syn keyword smclCCLword maxdb contained +syn keyword smclCCLword virtual contained +syn keyword smclCCLword checksum contained +syn keyword smclCCLword timeout1 contained +syn keyword smclCCLword timeout2 contained +syn keyword smclCCLword httpproxy contained +syn keyword smclCCLword httpproxyhost contained +syn keyword smclCCLword httpproxyport contained +syn keyword smclCCLword httpproxyauth contained +syn keyword smclCCLword httpproxyuser contained +syn keyword smclCCLword httpproxypw contained +syn keyword smclCCLword trace contained +syn keyword smclCCLword tracedepth contained +syn keyword smclCCLword tracesep contained +syn keyword smclCCLword traceindent contained +syn keyword smclCCLword traceexapnd contained +syn keyword smclCCLword tracenumber contained +syn keyword smclCCLword type contained +syn keyword smclCCLword level contained +syn keyword smclCCLword seed contained +syn keyword smclCCLword searchdefault contained +syn keyword smclCCLword pi contained +syn keyword smclCCLword rc contained + +" Directive for the contant and current-value class +syn region smclCCL start=/{ccl / end=/}/ oneline contains=smclCCLword + +" The order of the following syntax definitions is roughly that of the on-line +" documentation for smcl in Stata, from within Stata see help smcl. + +" Format directives for line and paragraph modes +syn match smclFormat /{smcl}/ +syn match smclFormat /{sf\(\|:[^}]\+\)}/ +syn match smclFormat /{it\(\|:[^}]\+\)}/ +syn match smclFormat /{bf\(\|:[^}]\+\)}/ +syn match smclFormat /{inp\(\|:[^}]\+\)}/ +syn match smclFormat /{input\(\|:[^}]\+\)}/ +syn match smclFormat /{err\(\|:[^}]\+\)}/ +syn match smclFormat /{error\(\|:[^}]\+\)}/ +syn match smclFormat /{res\(\|:[^}]\+\)}/ +syn match smclFormat /{result\(\|:[^}]\+\)}/ +syn match smclFormat /{txt\(\|:[^}]\+\)}/ +syn match smclFormat /{text\(\|:[^}]\+\)}/ +syn match smclFormat /{com\(\|:[^}]\+\)}/ +syn match smclFormat /{cmd\(\|:[^}]\+\)}/ +syn match smclFormat /{cmdab:[^:}]\+:[^:}()]*\(\|:\|:(\|:()\)}/ +syn match smclFormat /{hi\(\|:[^}]\+\)}/ +syn match smclFormat /{hilite\(\|:[^}]\+\)}/ +syn match smclFormat /{ul \(on\|off\)}/ +syn match smclFormat /{ul:[^}]\+}/ +syn match smclFormat /{hline\(\| \d\+\| -\d\+\|:[^}]\+\)}/ +syn match smclFormat /{dup \d\+:[^}]\+}/ +syn match smclFormat /{c [^}]\+}/ +syn match smclFormat /{char [^}]\+}/ +syn match smclFormat /{reset}/ + +" Formatting directives for line mode +syn match smclFormat /{title:[^}]\+}/ +syn match smclFormat /{center:[^}]\+}/ +syn match smclFormat /{centre:[^}]\+}/ +syn match smclFormat /{center \d\+:[^}]\+}/ +syn match smclFormat /{centre \d\+:[^}]\+}/ +syn match smclFormat /{right:[^}]\+}/ +syn match smclFormat /{lalign \d\+:[^}]\+}/ +syn match smclFormat /{ralign \d\+:[^}]\+}/ +syn match smclFormat /{\.\.\.}/ +syn match smclFormat /{col \d\+}/ +syn match smclFormat /{space \d\+}/ +syn match smclFormat /{tab}/ + +" Formatting directives for paragraph mode +syn match smclFormat /{bind:[^}]\+}/ +syn match smclFormat /{break}/ + +syn match smclFormat /{p}/ +syn match smclFormat /{p \d\+}/ +syn match smclFormat /{p \d\+ \d\+}/ +syn match smclFormat /{p \d\+ \d\+ \d\+}/ +syn match smclFormat /{pstd}/ +syn match smclFormat /{psee}/ +syn match smclFormat /{phang\(\|2\|3\)}/ +syn match smclFormat /{pmore\(\|2\|3\)}/ +syn match smclFormat /{pin\(\|2\|3\)}/ +syn match smclFormat /{p_end}/ + +syn match smclFormat /{opt \w\+\(\|:\w\+\)\(\|([^)}]*)\)}/ + +syn match smclFormat /{opth \w*\(\|:\w\+\)(\w*)}/ +syn match smclFormat /{opth "\w\+\((\w\+:[^)}]\+)\)"}/ +syn match smclFormat /{opth \w\+:\w\+(\w\+:[^)}]\+)}/ + +syn match smclFormat /{dlgtab\s*\(\|\d\+\|\d\+\s\+\d\+\):[^}]\+}/ + +syn match smclFormat /{p2colset\s\+\d\+\s\+\d\+\s\+\d\+\s\+\d\+}/ +syn match smclFormat /{p2col\s\+:[^{}]*}.*{p_end}/ +syn match smclFormat /{p2col\s\+:{[^{}]*}}.*{p_end}/ +syn match smclFormat /{p2coldent\s*:[^{}]*}.*{p_end}/ +syn match smclFormat /{p2coldent\s*:{[^{}]*}}.*{p_end}/ +syn match smclFormat /{p2line\s*\(\|\d\+\s\+\d\+\)}/ +syn match smclFormat /{p2colreset}/ + +syn match smclFormat /{synoptset\s\+\d\+\s\+\w\+}/ +syn match smclFormat /{synopt\s*:[^{}]*}.*{p_end}/ +syn match smclFormat /{synopt\s*:{[^{}]*}}.*{p_end}/ +syn match smclFormat /{syntab\s*:[^{}]*}/ +syn match smclFormat /{synopthdr}/ +syn match smclFormat /{synoptline}/ + +" Link directive for line and paragraph modes +syn match smclLink /{help [^}]\+}/ +syn match smclLink /{helpb [^}]\+}/ +syn match smclLink /{help_d:[^}]\+}/ +syn match smclLink /{search [^}]\+}/ +syn match smclLink /{search_d:[^}]\+}/ +syn match smclLink /{browse [^}]\+}/ +syn match smclLink /{view [^}]\+}/ +syn match smclLink /{view_d:[^}]\+}/ +syn match smclLink /{news:[^}]\+}/ +syn match smclLink /{net [^}]\+}/ +syn match smclLink /{net_d:[^}]\+}/ +syn match smclLink /{netfrom_d:[^}]\+}/ +syn match smclLink /{ado [^}]\+}/ +syn match smclLink /{ado_d:[^}]\+}/ +syn match smclLink /{update [^}]\+}/ +syn match smclLink /{update_d:[^}]\+}/ +syn match smclLink /{dialog [^}]\+}/ +syn match smclLink /{back:[^}]\+}/ +syn match smclLink /{clearmore:[^}]\+}/ +syn match smclLink /{stata [^}]\+}/ + +syn match smclLink /{newvar\(\|:[^}]\+\)}/ +syn match smclLink /{var\(\|:[^}]\+\)}/ +syn match smclLink /{varname\(\|:[^}]\+\)}/ +syn match smclLink /{vars\(\|:[^}]\+\)}/ +syn match smclLink /{varlist\(\|:[^}]\+\)}/ +syn match smclLink /{depvar\(\|:[^}]\+\)}/ +syn match smclLink /{depvars\(\|:[^}]\+\)}/ +syn match smclLink /{depvarlist\(\|:[^}]\+\)}/ +syn match smclLink /{indepvars\(\|:[^}]\+\)}/ + +syn match smclLink /{dtype}/ +syn match smclLink /{ifin}/ +syn match smclLink /{weight}/ + +" Comment +syn region smclComment start=/{\*/ end=/}/ oneline + +" Strings +syn region smclString matchgroup=Nothing start=/"/ end=/"/ oneline +syn region smclEString matchgroup=Nothing start=/`"/ end=/"'/ oneline contains=smclEString + +" assign highlight groups + +hi def link smclEString smclString + +hi def link smclCCLword Statement +hi def link smclCCL Type +hi def link smclFormat Statement +hi def link smclLink Underlined +hi def link smclComment Comment +hi def link smclString String + +let b:current_syntax = "smcl" + +" vim: ts=8 + +endif diff --git a/syntax/smil.vim b/syntax/smil.vim new file mode 100644 index 0000000..3439a6c --- /dev/null +++ b/syntax/smil.vim @@ -0,0 +1,150 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SMIL (Synchronized Multimedia Integration Language) +" Maintainer: Herve Foucher +" URL: http://www.helio.org/vim/syntax/smil.vim +" Last Change: 2012 Feb 03 by Thilo Six + +" To learn more about SMIL, please refer to http://www.w3.org/AudioVideo/ +" and to http://www.helio.org/products/smil/tutorial/ + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" SMIL is case sensitive +syn case match + +" illegal characters +syn match smilError "[<>&]" +syn match smilError "[()&]" + +if !exists("main_syntax") + let main_syntax = 'smil' +endif + +" tags +syn match smilSpecial contained "\\\d\d\d\|\\." +syn match smilSpecial contained "(" +syn match smilSpecial contained "id(" +syn match smilSpecial contained ")" +syn keyword smilSpecial contained remove freeze true false on off overdub caption new pause replace +syn keyword smilSpecial contained first last +syn keyword smilSpecial contained fill meet slice scroll hidden +syn region smilString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=smilSpecial +syn region smilString contained start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=smilSpecial +syn match smilValue contained "=[\t ]*[^'" \t>][^ \t>]*"hs=s+1 +syn region smilEndTag start=++ contains=smilTagN,smilTagError +syn region smilTag start=+<[^/]+ end=+>+ contains=smilTagN,smilString,smilArg,smilValue,smilTagError,smilEvent,smilCssDefinition +syn match smilTagN contained +<\s*[-a-zA-Z0-9]\++ms=s+1 contains=smilTagName,smilSpecialTagName +syn match smilTagN contained +]<"ms=s+1 + +" tag names +syn keyword smilTagName contained smil head body anchor a switch region layout meta +syn match smilTagName contained "root-layout" +syn keyword smilTagName contained par seq +syn keyword smilTagName contained animation video img audio ref text textstream +syn match smilTagName contained "\<\(head\|body\)\>" + + +" legal arg names +syn keyword smilArg contained dur begin end href target id coords show title abstract author copyright alt +syn keyword smilArg contained left top width height fit src name content fill longdesc repeat type +syn match smilArg contained "z-index" +syn match smilArg contained " end-sync" +syn match smilArg contained " region" +syn match smilArg contained "background-color" +syn match smilArg contained "system-bitrate" +syn match smilArg contained "system-captions" +syn match smilArg contained "system-overdub-or-caption" +syn match smilArg contained "system-language" +syn match smilArg contained "system-required" +syn match smilArg contained "system-screen-depth" +syn match smilArg contained "system-screen-size" +syn match smilArg contained "clip-begin" +syn match smilArg contained "clip-end" +syn match smilArg contained "skip-content" + + +" SMIL Boston ext. +" This are new SMIL functionnalities seen on www.w3.org on August 3rd 1999 + +" Animation +syn keyword smilTagName contained animate set move +syn keyword smilArg contained calcMode from to by additive values origin path +syn keyword smilArg contained accumulate hold attribute +syn match smilArg contained "xml:link" +syn keyword smilSpecial contained discrete linear spline parent layout +syn keyword smilSpecial contained top left simple + +" Linking +syn keyword smilTagName contained area +syn keyword smilArg contained actuate behavior inline sourceVolume +syn keyword smilArg contained destinationVolume destinationPlaystate tabindex +syn keyword smilArg contained class style lang dir onclick ondblclick onmousedown onmouseup onmouseover onmousemove onmouseout onkeypress onkeydown onkeyup shape nohref accesskey onfocus onblur +syn keyword smilSpecial contained play pause stop rect circ poly child par seq + +" Media Object +syn keyword smilTagName contained rtpmap +syn keyword smilArg contained port transport encoding payload clipBegin clipEnd +syn match smilArg contained "fmt-list" + +" Timing and Synchronization +syn keyword smilTagName contained excl +syn keyword smilArg contained beginEvent endEvent eventRestart endSync repeatCount repeatDur +syn keyword smilArg contained syncBehavior syncTolerance +syn keyword smilSpecial contained canSlip locked + +" special characters +syn match smilSpecialChar "&[^;]*;" + +if exists("smil_wrong_comments") + syn region smilComment start=++ +else + syn region smilComment start=++ contains=smilCommentPart,smilCommentError + syn match smilCommentError contained "[^>+ + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link smilTag Function +hi def link smilEndTag Identifier +hi def link smilArg Type +hi def link smilTagName smilStatement +hi def link smilSpecialTagName Exception +hi def link smilValue Value +hi def link smilSpecialChar Special + +hi def link smilSpecial Special +hi def link smilSpecialChar Special +hi def link smilString String +hi def link smilStatement Statement +hi def link smilComment Comment +hi def link smilCommentPart Comment +hi def link smilPreProc PreProc +hi def link smilValue String +hi def link smilCommentError smilError +hi def link smilTagError smilError +hi def link smilError Error + + +let b:current_syntax = "smil" + +if main_syntax == 'smil' + unlet main_syntax +endif + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 + +endif diff --git a/syntax/smith.vim b/syntax/smith.vim new file mode 100644 index 0000000..af46530 --- /dev/null +++ b/syntax/smith.vim @@ -0,0 +1,43 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SMITH +" Maintainer: Rafal M. Sulejman +" Last Change: 21.07.2000 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + + +syn match smithComment ";.*$" + +syn match smithNumber "\<[+-]*[0-9]\d*\>" + +syn match smithRegister "R[\[]*[0-9]*[\]]*" + +syn match smithKeyword "COR\|MOV\|MUL\|NOT\|STOP\|SUB\|NOP\|BLA\|REP" + +syn region smithString start=+"+ skip=+\\\\\|\\"+ end=+"+ + + +syn case match + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link smithRegister Identifier +hi def link smithKeyword Keyword +hi def link smithComment Comment +hi def link smithString String +hi def link smithNumber Number + + +let b:current_syntax = "smith" + +" vim: ts=2 + +endif diff --git a/syntax/sml.vim b/syntax/sml.vim new file mode 100644 index 0000000..e77876c --- /dev/null +++ b/syntax/sml.vim @@ -0,0 +1,221 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SML +" Filenames: *.sml *.sig +" Maintainers: Markus Mottl +" Fabrizio Zeno Cornelli +" URL: http://www.ocaml.info/vim/syntax/sml.vim +" Last Change: 2006 Oct 23 - Fixed character highlighting bug (MM) +" 2002 Jun 02 - Fixed small typo (MM) +" 2001 Nov 20 - Fixed small highlighting bug with modules (MM) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" SML is case sensitive. +syn case match + +" lowercase identifier - the standard way to match +syn match smlLCIdentifier /\<\(\l\|_\)\(\w\|'\)*\>/ + +syn match smlKeyChar "|" + +" Errors +syn match smlBraceErr "}" +syn match smlBrackErr "\]" +syn match smlParenErr ")" +syn match smlCommentErr "\*)" +syn match smlThenErr "\" + +" Error-highlighting of "end" without synchronization: +" as keyword or as error (default) +if exists("sml_noend_error") + syn match smlKeyword "\" +else + syn match smlEndErr "\" +endif + +" Some convenient clusters +syn cluster smlAllErrs contains=smlBraceErr,smlBrackErr,smlParenErr,smlCommentErr,smlEndErr,smlThenErr + +syn cluster smlAENoParen contains=smlBraceErr,smlBrackErr,smlCommentErr,smlEndErr,smlThenErr + +syn cluster smlContained contains=smlTodo,smlPreDef,smlModParam,smlModParam1,smlPreMPRestr,smlMPRestr,smlMPRestr1,smlMPRestr2,smlMPRestr3,smlModRHS,smlFuncWith,smlFuncStruct,smlModTypeRestr,smlModTRWith,smlWith,smlWithRest,smlModType,smlFullMod + + +" Enclosing delimiters +syn region smlEncl transparent matchgroup=smlKeyword start="(" matchgroup=smlKeyword end=")" contains=ALLBUT,@smlContained,smlParenErr +syn region smlEncl transparent matchgroup=smlKeyword start="{" matchgroup=smlKeyword end="}" contains=ALLBUT,@smlContained,smlBraceErr +syn region smlEncl transparent matchgroup=smlKeyword start="\[" matchgroup=smlKeyword end="\]" contains=ALLBUT,@smlContained,smlBrackErr +syn region smlEncl transparent matchgroup=smlKeyword start="#\[" matchgroup=smlKeyword end="\]" contains=ALLBUT,@smlContained,smlBrackErr + + +" Comments +syn region smlComment start="(\*" end="\*)" contains=smlComment,smlTodo +syn keyword smlTodo contained TODO FIXME XXX + + +" let +syn region smlEnd matchgroup=smlKeyword start="\" matchgroup=smlKeyword end="\" contains=ALLBUT,@smlContained,smlEndErr + +" local +syn region smlEnd matchgroup=smlKeyword start="\" matchgroup=smlKeyword end="\" contains=ALLBUT,@smlContained,smlEndErr + +" abstype +syn region smlNone matchgroup=smlKeyword start="\" matchgroup=smlKeyword end="\" contains=ALLBUT,@smlContained,smlEndErr + +" begin +syn region smlEnd matchgroup=smlKeyword start="\" matchgroup=smlKeyword end="\" contains=ALLBUT,@smlContained,smlEndErr + +" if +syn region smlNone matchgroup=smlKeyword start="\" matchgroup=smlKeyword end="\" contains=ALLBUT,@smlContained,smlThenErr + + +"" Modules + +" "struct" +syn region smlStruct matchgroup=smlModule start="\" matchgroup=smlModule end="\" contains=ALLBUT,@smlContained,smlEndErr + +" "sig" +syn region smlSig matchgroup=smlModule start="\" matchgroup=smlModule end="\" contains=ALLBUT,@smlContained,smlEndErr,smlModule +syn region smlModSpec matchgroup=smlKeyword start="\" matchgroup=smlModule end="\<\u\(\w\|'\)*\>" contained contains=@smlAllErrs,smlComment skipwhite skipempty nextgroup=smlModTRWith,smlMPRestr + +" "open" +syn region smlNone matchgroup=smlKeyword start="\" matchgroup=smlModule end="\<\u\(\w\|'\)*\(\.\u\(\w\|'\)*\)*\>" contains=@smlAllErrs,smlComment + +" "structure" - somewhat complicated stuff ;-) +syn region smlModule matchgroup=smlKeyword start="\<\(structure\|functor\)\>" matchgroup=smlModule end="\<\u\(\w\|'\)*\>" contains=@smlAllErrs,smlComment skipwhite skipempty nextgroup=smlPreDef +syn region smlPreDef start="."me=e-1 matchgroup=smlKeyword end="\l\|="me=e-1 contained contains=@smlAllErrs,smlComment,smlModParam,smlModTypeRestr,smlModTRWith nextgroup=smlModPreRHS +syn region smlModParam start="([^*]" end=")" contained contains=@smlAENoParen,smlModParam1 +syn match smlModParam1 "\<\u\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=smlPreMPRestr + +syn region smlPreMPRestr start="."me=e-1 end=")"me=e-1 contained contains=@smlAllErrs,smlComment,smlMPRestr,smlModTypeRestr + +syn region smlMPRestr start=":" end="."me=e-1 contained contains=@smlComment skipwhite skipempty nextgroup=smlMPRestr1,smlMPRestr2,smlMPRestr3 +syn region smlMPRestr1 matchgroup=smlModule start="\ssig\s\=" matchgroup=smlModule end="\" contained contains=ALLBUT,@smlContained,smlEndErr,smlModule +syn region smlMPRestr2 start="\sfunctor\(\s\|(\)\="me=e-1 matchgroup=smlKeyword end="->" contained contains=@smlAllErrs,smlComment,smlModParam skipwhite skipempty nextgroup=smlFuncWith +syn match smlMPRestr3 "\w\(\w\|'\)*\(\.\w\(\w\|'\)*\)*" contained +syn match smlModPreRHS "=" contained skipwhite skipempty nextgroup=smlModParam,smlFullMod +syn region smlModRHS start="." end=".\w\|([^*]"me=e-2 contained contains=smlComment skipwhite skipempty nextgroup=smlModParam,smlFullMod +syn match smlFullMod "\<\u\(\w\|'\)*\(\.\u\(\w\|'\)*\)*" contained skipwhite skipempty nextgroup=smlFuncWith + +syn region smlFuncWith start="([^*]"me=e-1 end=")" contained contains=smlComment,smlWith,smlFuncStruct +syn region smlFuncStruct matchgroup=smlModule start="[^a-zA-Z]struct\>"hs=s+1 matchgroup=smlModule end="\" contains=ALLBUT,@smlContained,smlEndErr + +syn match smlModTypeRestr "\<\w\(\w\|'\)*\(\.\w\(\w\|'\)*\)*\>" contained +syn region smlModTRWith start=":\s*("hs=s+1 end=")" contained contains=@smlAENoParen,smlWith +syn match smlWith "\<\(\u\(\w\|'\)*\.\)*\w\(\w\|'\)*\>" contained skipwhite skipempty nextgroup=smlWithRest +syn region smlWithRest start="[^)]" end=")"me=e-1 contained contains=ALLBUT,@smlContained + +" "signature" +syn region smlKeyword start="\" matchgroup=smlModule end="\<\w\(\w\|'\)*\>" contains=smlComment skipwhite skipempty nextgroup=smlMTDef +syn match smlMTDef "=\s*\w\(\w\|'\)*\>"hs=s+1,me=s + +syn keyword smlKeyword and andalso case +syn keyword smlKeyword datatype else eqtype +syn keyword smlKeyword exception fn fun handle +syn keyword smlKeyword in infix infixl infixr +syn keyword smlKeyword match nonfix of orelse +syn keyword smlKeyword raise handle type +syn keyword smlKeyword val where while with withtype + +syn keyword smlType bool char exn int list option +syn keyword smlType real string unit + +syn keyword smlOperator div mod not or quot rem + +syn keyword smlBoolean true false +syn match smlConstructor "(\s*)" +syn match smlConstructor "\[\s*\]" +syn match smlConstructor "#\[\s*\]" +syn match smlConstructor "\u\(\w\|'\)*\>" + +" Module prefix +syn match smlModPath "\u\(\w\|'\)*\."he=e-1 + +syn match smlCharacter +#"\\""\|#"."\|#"\\\d\d\d"+ +syn match smlCharErr +#"\\\d\d"\|#"\\\d"+ +syn region smlString start=+"+ skip=+\\\\\|\\"+ end=+"+ + +syn match smlFunDef "=>" +syn match smlRefAssign ":=" +syn match smlTopStop ";;" +syn match smlOperator "\^" +syn match smlOperator "::" +syn match smlAnyVar "\<_\>" +syn match smlKeyChar "!" +syn match smlKeyChar ";" +syn match smlKeyChar "\*" +syn match smlKeyChar "=" + +syn match smlNumber "\<-\=\d\+\>" +syn match smlNumber "\<-\=0[x|X]\x\+\>" +syn match smlReal "\<-\=\d\+\.\d*\([eE][-+]\=\d\+\)\=[fl]\=\>" + +" Synchronization +syn sync minlines=20 +syn sync maxlines=500 + +syn sync match smlEndSync grouphere smlEnd "\" +syn sync match smlEndSync groupthere smlEnd "\" +syn sync match smlStructSync grouphere smlStruct "\" +syn sync match smlStructSync groupthere smlStruct "\" +syn sync match smlSigSync grouphere smlSig "\" +syn sync match smlSigSync groupthere smlSig "\" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link smlBraceErr Error +hi def link smlBrackErr Error +hi def link smlParenErr Error + +hi def link smlCommentErr Error + +hi def link smlEndErr Error +hi def link smlThenErr Error + +hi def link smlCharErr Error + +hi def link smlComment Comment + +hi def link smlModPath Include +hi def link smlModule Include +hi def link smlModParam1 Include +hi def link smlModType Include +hi def link smlMPRestr3 Include +hi def link smlFullMod Include +hi def link smlModTypeRestr Include +hi def link smlWith Include +hi def link smlMTDef Include + +hi def link smlConstructor Constant + +hi def link smlModPreRHS Keyword +hi def link smlMPRestr2 Keyword +hi def link smlKeyword Keyword +hi def link smlFunDef Keyword +hi def link smlRefAssign Keyword +hi def link smlKeyChar Keyword +hi def link smlAnyVar Keyword +hi def link smlTopStop Keyword +hi def link smlOperator Keyword + +hi def link smlBoolean Boolean +hi def link smlCharacter Character +hi def link smlNumber Number +hi def link smlReal Float +hi def link smlString String +hi def link smlType Type +hi def link smlTodo Todo +hi def link smlEncl Keyword + + +let b:current_syntax = "sml" + +" vim: ts=8 + +endif diff --git a/syntax/snnsnet.vim b/syntax/snnsnet.vim new file mode 100644 index 0000000..a22ae93 --- /dev/null +++ b/syntax/snnsnet.vim @@ -0,0 +1,71 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SNNS network file +" Maintainer: Davide Alberani +" Last Change: 28 Apr 2001 +" Version: 0.2 +" URL: http://digilander.iol.it/alberanid/vim/syntax/snnsnet.vim +" +" SNNS http://www-ra.informatik.uni-tuebingen.de/SNNS/ +" is a simulator for neural networks. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match snnsnetTitle "no\." +syn match snnsnetTitle "type name" +syn match snnsnetTitle "unit name" +syn match snnsnetTitle "act\( func\)\=" +syn match snnsnetTitle "out func" +syn match snnsnetTitle "site\( name\)\=" +syn match snnsnetTitle "site function" +syn match snnsnetTitle "source:weight" +syn match snnsnetTitle "unitNo\." +syn match snnsnetTitle "delta x" +syn match snnsnetTitle "delta y" +syn keyword snnsnetTitle typeName unitName bias st position subnet layer sites name target z LLN LUN Toff Soff Ctype + +syn match snnsnetType "SNNS network definition file [Vv]\d.\d.*" contains=snnsnetNumbers +syn match snnsnetType "generated at.*" contains=snnsnetNumbers +syn match snnsnetType "network name\s*:" +syn match snnsnetType "source files\s*:" +syn match snnsnetType "no\. of units\s*:.*" contains=snnsnetNumbers +syn match snnsnetType "no\. of connections\s*:.*" contains=snnsnetNumbers +syn match snnsnetType "no\. of unit types\s*:.*" contains=snnsnetNumbers +syn match snnsnetType "no\. of site types\s*:.*" contains=snnsnetNumbers +syn match snnsnetType "learning function\s*:" +syn match snnsnetType "pruning function\s*:" +syn match snnsnetType "subordinate learning function\s*:" +syn match snnsnetType "update function\s*:" + +syn match snnsnetSection "unit definition section" +syn match snnsnetSection "unit default section" +syn match snnsnetSection "site definition section" +syn match snnsnetSection "type definition section" +syn match snnsnetSection "connection definition section" +syn match snnsnetSection "layer definition section" +syn match snnsnetSection "subnet definition section" +syn match snnsnetSection "3D translation section" +syn match snnsnetSection "time delay section" + +syn match snnsnetNumbers "\d" contained +syn match snnsnetComment "#.*$" contains=snnsnetTodo +syn keyword snnsnetTodo TODO XXX FIXME contained + + +hi def link snnsnetType Type +hi def link snnsnetComment Comment +hi def link snnsnetNumbers Number +hi def link snnsnetSection Statement +hi def link snnsnetTitle Label +hi def link snnsnetTodo Todo + + +let b:current_syntax = "snnsnet" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/snnspat.vim b/syntax/snnspat.vim new file mode 100644 index 0000000..ddd3cdf --- /dev/null +++ b/syntax/snnspat.vim @@ -0,0 +1,66 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SNNS pattern file +" Maintainer: Davide Alberani +" Last Change: 2012 Feb 03 by Thilo Six +" Version: 0.2 +" URL: http://digilander.iol.it/alberanid/vim/syntax/snnspat.vim +" +" SNNS http://www-ra.informatik.uni-tuebingen.de/SNNS/ +" is a simulator for neural networks. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" anything that isn't part of the header, a comment or a number +" is wrong +syn match snnspatError ".*" +" hoping that matches any kind of notation... +syn match snnspatAccepted "\([-+]\=\(\d\+\.\|\.\)\=\d\+\([Ee][-+]\=\d\+\)\=\)" +syn match snnspatAccepted "\s" +syn match snnspatBrac "\[\s*\d\+\(\s\|\d\)*\]" contains=snnspatNumbers + +" the accepted fields in the header +syn match snnspatNoHeader "No\. of patterns\s*:\s*" contained +syn match snnspatNoHeader "No\. of input units\s*:\s*" contained +syn match snnspatNoHeader "No\. of output units\s*:\s*" contained +syn match snnspatNoHeader "No\. of variable input dimensions\s*:\s*" contained +syn match snnspatNoHeader "No\. of variable output dimensions\s*:\s*" contained +syn match snnspatNoHeader "Maximum input dimensions\s*:\s*" contained +syn match snnspatNoHeader "Maximum output dimensions\s*:\s*" contained +syn match snnspatGen "generated at.*" contained contains=snnspatNumbers +syn match snnspatGen "SNNS pattern definition file [Vv]\d\.\d" contained contains=snnspatNumbers + +" the header, what is not an accepted field, is an error +syn region snnspatHeader start="^SNNS" end="^\s*[-+\.]\=[0-9#]"me=e-2 contains=snnspatNoHeader,snnspatNumbers,snnspatGen,snnspatBrac + +" numbers inside the header +syn match snnspatNumbers "\d" contained +syn match snnspatComment "#.*$" contains=snnspatTodo +syn keyword snnspatTodo TODO XXX FIXME contained + + +hi def link snnspatGen Statement +hi def link snnspatHeader Error +hi def link snnspatNoHeader Define +hi def link snnspatNumbers Number +hi def link snnspatComment Comment +hi def link snnspatError Error +hi def link snnspatTodo Todo +hi def link snnspatAccepted NONE +hi def link snnspatBrac NONE + + +let b:current_syntax = "snnspat" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 sw=2 + +endif diff --git a/syntax/snnsres.vim b/syntax/snnsres.vim new file mode 100644 index 0000000..1cdf379 --- /dev/null +++ b/syntax/snnsres.vim @@ -0,0 +1,54 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SNNS result file +" Maintainer: Davide Alberani +" Last Change: 28 Apr 2001 +" Version: 0.2 +" URL: http://digilander.iol.it/alberanid/vim/syntax/snnsres.vim +" +" SNNS http://www-ra.informatik.uni-tuebingen.de/SNNS/ +" is a simulator for neural networks. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" the accepted fields in the header +syn match snnsresNoHeader "No\. of patterns\s*:\s*" contained +syn match snnsresNoHeader "No\. of input units\s*:\s*" contained +syn match snnsresNoHeader "No\. of output units\s*:\s*" contained +syn match snnsresNoHeader "No\. of variable input dimensions\s*:\s*" contained +syn match snnsresNoHeader "No\. of variable output dimensions\s*:\s*" contained +syn match snnsresNoHeader "Maximum input dimensions\s*:\s*" contained +syn match snnsresNoHeader "Maximum output dimensions\s*:\s*" contained +syn match snnsresNoHeader "startpattern\s*:\s*" contained +syn match snnsresNoHeader "endpattern\s*:\s*" contained +syn match snnsresNoHeader "input patterns included" contained +syn match snnsresNoHeader "teaching output included" contained +syn match snnsresGen "generated at.*" contained contains=snnsresNumbers +syn match snnsresGen "SNNS result file [Vv]\d\.\d" contained contains=snnsresNumbers + +" the header, what is not an accepted field, is an error +syn region snnsresHeader start="^SNNS" end="^\s*[-+\.]\=[0-9#]"me=e-2 contains=snnsresNoHeader,snnsresNumbers,snnsresGen + +" numbers inside the header +syn match snnsresNumbers "\d" contained +syn match snnsresComment "#.*$" contains=snnsresTodo +syn keyword snnsresTodo TODO XXX FIXME contained + + +hi def link snnsresGen Statement +hi def link snnsresHeader Statement +hi def link snnsresNoHeader Define +hi def link snnsresNumbers Number +hi def link snnsresComment Comment +hi def link snnsresTodo Todo + + +let b:current_syntax = "snnsres" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/snobol4.vim b/syntax/snobol4.vim new file mode 100644 index 0000000..550bb20 --- /dev/null +++ b/syntax/snobol4.vim @@ -0,0 +1,116 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SNOBOL4 +" Maintainer: Rafal Sulejman +" Site: http://rms.republika.pl/vim/syntax/snobol4.vim +" Last change: 2006 may 10 +" Changes: +" - strict snobol4 mode (set snobol4_strict_mode to activate) +" - incorrect HL of dots in strings corrected +" - incorrect HL of dot-variables in parens corrected +" - one character labels weren't displayed correctly. +" - nonexistent Snobol4 keywords displayed as errors. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syntax case ignore + +" Snobol4 keywords +syn keyword snobol4Keyword any apply arb arbno arg array +syn keyword snobol4Keyword break +syn keyword snobol4Keyword char clear code collect convert copy +syn keyword snobol4Keyword data datatype date define detach differ dump dupl +syn keyword snobol4Keyword endfile eq eval +syn keyword snobol4Keyword field +syn keyword snobol4Keyword ge gt ident +syn keyword snobol4Keyword input integer item +syn keyword snobol4Keyword le len lgt local lpad lt +syn keyword snobol4Keyword ne notany +syn keyword snobol4Keyword opsyn output +syn keyword snobol4Keyword pos prototype +syn keyword snobol4Keyword remdr replace rpad rpos rtab rewind +syn keyword snobol4Keyword size span stoptr +syn keyword snobol4Keyword tab table time trace trim terminal +syn keyword snobol4Keyword unload +syn keyword snobol4Keyword value + +" CSNOBOL keywords +syn keyword snobol4ExtKeyword breakx +syn keyword snobol4ExtKeyword char chop +syn keyword snobol4ExtKeyword date delete +syn keyword snobol4ExtKeyword exp +syn keyword snobol4ExtKeyword freeze function +syn keyword snobol4ExtKeyword host +syn keyword snobol4ExtKeyword io_findunit +syn keyword snobol4ExtKeyword label lpad leq lge lle llt lne log +syn keyword snobol4ExtKeyword ord +syn keyword snobol4ExtKeyword reverse rpad rsort rename +syn keyword snobol4ExtKeyword serv_listen sset set sort sqrt substr +syn keyword snobol4ExtKeyword thaw +syn keyword snobol4ExtKeyword vdiffer + +syn region snobol4String matchgroup=Quote start=+"+ end=+"+ +syn region snobol4String matchgroup=Quote start=+'+ end=+'+ +syn match snobol4BogusStatement "^-[^ ][^ ]*" +syn match snobol4Statement "^-\(include\|copy\|module\|line\|plusopts\|case\|error\|noerrors\|list\|unlist\|execute\|noexecute\|copy\)" +syn match snobol4Constant /"[^a-z"']\.[a-z][a-z0-9\-]*"/hs=s+1 +syn region snobol4Goto start=":[sf]\{0,1}(" end=")\|$\|;" contains=ALLBUT,snobol4ParenError +syn match snobol4Number "\<\d*\(\.\d\d*\)*\>" +syn match snobol4BogusSysVar "&\w\{1,}" +syn match snobol4SysVar "&\(abort\|alphabet\|anchor\|arb\|bal\|case\|code\|dump\|errlimit\|errtext\|errtype\|fail\|fence\|fnclevel\|ftrace\|fullscan\|input\|lastno\|lcase\|maxlngth\|output\|parm\|rem\|rtntype\|stcount\|stfcount\|stlimit\|stno\|succeed\|trace\|trim\|ucase\)" +syn match snobol4ExtSysVar "&\(gtrace\|line\|file\|lastline\|lastfile\)" +syn match snobol4Label "\(^\|;\)[^-\.\+ \t\*\.]\{1,}[^ \t\*\;]*" +syn match snobol4Comment "\(^\|;\)\([\*\|!;#].*$\)" + +" Parens matching +syn cluster snobol4ParenGroup contains=snobol4ParenError +syn region snobol4Paren transparent start='(' end=')' contains=ALLBUT,@snobol4ParenGroup,snobol4ErrInBracket +syn match snobol4ParenError display "[\])]" +syn match snobol4ErrInParen display contained "[\]{}]\|<%\|%>" +syn region snobol4Bracket transparent start='\[\|<:' end=']\|:>' contains=ALLBUT,@snobol4ParenGroup,snobol4ErrInParen +syn match snobol4ErrInBracket display contained "[){}]\|<%\|%>" + +" optional shell shebang line +" syn match snobol4Comment "^\#\!.*$" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link snobol4Constant Constant +hi def link snobol4Label Label +hi def link snobol4Goto Repeat +hi def link snobol4Conditional Conditional +hi def link snobol4Repeat Repeat +hi def link snobol4Number Number +hi def link snobol4Error Error +hi def link snobol4Statement PreProc +hi def link snobol4BogusStatement snobol4Error +hi def link snobol4String String +hi def link snobol4Comment Comment +hi def link snobol4Special Special +hi def link snobol4Todo Todo +hi def link snobol4Keyword Keyword +hi def link snobol4Function Function +hi def link snobol4MathsOperator Operator +hi def link snobol4ParenError snobol4Error +hi def link snobol4ErrInParen snobol4Error +hi def link snobol4ErrInBracket snobol4Error +hi def link snobol4SysVar Keyword +hi def link snobol4BogusSysVar snobol4Error +if exists("snobol4_strict_mode") +hi def link snobol4ExtSysVar WarningMsg +hi def link snobol4ExtKeyword WarningMsg +else +hi def link snobol4ExtSysVar snobol4SysVar +hi def link snobol4ExtKeyword snobol4Keyword +endif + + +let b:current_syntax = "snobol4" +" vim: ts=8 + +endif diff --git a/syntax/spec.vim b/syntax/spec.vim new file mode 100644 index 0000000..5c4a1d8 --- /dev/null +++ b/syntax/spec.vim @@ -0,0 +1,227 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Filename: spec.vim +" Purpose: Vim syntax file +" Language: SPEC: Build/install scripts for Linux RPM packages +" Maintainer: Igor Gnatenko i.gnatenko.brain@gmail.com +" Former Maintainer: Donovan Rebbechi elflord@panix.com (until March 2014) +" Last Change: Sat Apr 9 15:30 2016 Filip SzymaÅ„ski + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn sync minlines=1000 + +syn match specSpecialChar contained '[][!$()\\|>^;:{}]' +syn match specColon contained ':' +syn match specPercent contained '%' + +syn match specVariables contained '\$\h\w*' contains=specSpecialVariablesNames,specSpecialChar +syn match specVariables contained '\${\w*}' contains=specSpecialVariablesNames,specSpecialChar + +syn match specMacroIdentifier contained '%\h\w*' contains=specMacroNameLocal,specMacroNameOther,specPercent +syn match specMacroIdentifier contained '%{\w*}' contains=specMacroNameLocal,specMacroNameOther,specPercent,specSpecialChar + +syn match specSpecialVariables contained '\$[0-9]\|\${[0-9]}' +syn match specCommandOpts contained '\s\(-\w\+\|--\w[a-zA-Z_-]\+\)'ms=s+1 +syn match specComment '^\s*#.*$' + + +syn case match + + +"matches with no highlight +syn match specNoNumberHilite 'X11\|X11R6\|[a-zA-Z]*\.\d\|[a-zA-Z][-/]\d' +syn match specManpageFile '[a-zA-Z]\.1' + +"Day, Month and most used license acronyms +syn keyword specLicense contained GPL LGPL BSD MIT GNU +syn keyword specWeekday contained Mon Tue Wed Thu Fri Sat Sun +syn keyword specMonth contained Jan Feb Mar Apr Jun Jul Aug Sep Oct Nov Dec +syn keyword specMonth contained January February March April May June July August September October November December + +"#, @, www +syn match specNumber '\(^-\=\|[ \t]-\=\|-\)[0-9.-]*[0-9]' +syn match specEmail contained "<\=\<[A-Za-z0-9_.-]\+@\([A-Za-z0-9_-]\+\.\)\+[A-Za-z]\+\>>\=" +syn match specURL contained '\<\(\(https\{0,1}\|ftp\)://\|\(www[23]\{0,1}\.\|ftp\.\)\)[A-Za-z0-9._/~:,#-]\+\>' +syn match specURLMacro contained '\<\(\(https\{0,1}\|ftp\)://\|\(www[23]\{0,1}\.\|ftp\.\)\)[A-Za-z0-9._/~:,#%{}-]\+\>' contains=specMacroIdentifier + +"TODO take specSpecialVariables out of the cluster for the sh* contains (ALLBUT) +"Special system directories +syn match specListedFilesPrefix contained '/\(usr\|local\|opt\|X11R6\|X11\)/'me=e-1 +syn match specListedFilesBin contained '/s\=bin/'me=e-1 +syn match specListedFilesLib contained '/\(lib\|include\)/'me=e-1 +syn match specListedFilesDoc contained '/\(man\d*\|doc\|info\)\>' +syn match specListedFilesEtc contained '/etc/'me=e-1 +syn match specListedFilesShare contained '/share/'me=e-1 +syn cluster specListedFiles contains=specListedFilesBin,specListedFilesLib,specListedFilesDoc,specListedFilesEtc,specListedFilesShare,specListedFilesPrefix,specVariables,specSpecialChar + +"specComands +syn match specConfigure contained '\./configure' +syn match specTarCommand contained '\' + +"valid _macro names from /usr/lib/rpm/macros +syn keyword specMacroNameLocal contained _arch _binary_payload _bindir _build _build_alias _build_cpu _builddir _build_os _buildshell _buildsubdir _build_vendor _bzip2bin _datadir _dbpath _dbpath_rebuild _defaultdocdir _docdir _excludedocs _exec_prefix _fixgroup _fixowner _fixperms _ftpport _ftpproxy _gpg_path _gzipbin _host _host_alias _host_cpu _host_os _host_vendor _httpport _httpproxy _includedir _infodir _install_langs _install_script_path _instchangelog _langpatt _lib _libdir _libexecdir _localstatedir _mandir _netsharedpath _oldincludedir _os _pgpbin _pgp_path _prefix _preScriptEnvironment _provides _rpmdir _rpmfilename _sbindir _sharedstatedir _signature _sourcedir _source_payload _specdir _srcrpmdir _sysconfdir _target _target_alias _target_cpu _target_os _target_platform _target_vendor _timecheck _tmppath _topdir _usr _usrsrc _var _vendor + + +"------------------------------------------------------------------------------ +" here's is all the spec sections definitions: PreAmble, Description, Package, +" Scripts, Files and Changelog + +"One line macros - valid in all ScriptAreas +"tip: remember do include new items on specScriptArea's skip section +syn region specSectionMacroArea oneline matchgroup=specSectionMacro start='^%\(define\|global\|patch\d*\|setup\|autosetup\|autopatch\|configure\|GNUconfigure\|find_lang\|make_build\|makeinstall\|make_install\|include\)\>' end='$' contains=specCommandOpts,specMacroIdentifier +syn region specSectionMacroBracketArea oneline matchgroup=specSectionMacro start='^%{\(configure\|GNUconfigure\|find_lang\|make_build\|makeinstall\|make_install\)}' end='$' contains=specCommandOpts,specMacroIdentifier + +"%% Files Section %% +"TODO %config valid parameters: missingok\|noreplace +"TODO %verify valid parameters: \(not\)\= \(md5\|atime\|...\) +syn region specFilesArea matchgroup=specSection start='^%[Ff][Ii][Ll][Ee][Ss]\>' skip='%\(attrib\|defattr\|attr\|dir\|config\|docdir\|doc\|lang\|verify\|ghost\)\>' end='^%[a-zA-Z]'me=e-2 contains=specFilesOpts,specFilesDirective,@specListedFiles,specComment,specCommandSpecial,specMacroIdentifier +"tip: remember to include new itens in specFilesArea above +syn match specFilesDirective contained '%\(attrib\|defattr\|attr\|dir\|config\|docdir\|doc\|lang\|verify\|ghost\)\>' + +"valid options for certain section headers +syn match specDescriptionOpts contained '\s-[ln]\s*\a'ms=s+1,me=e-1 +syn match specPackageOpts contained '\s-n\s*\w'ms=s+1,me=e-1 +syn match specFilesOpts contained '\s-f\s*\w'ms=s+1,me=e-1 + + +syn case ignore + + +"%% PreAmble Section %% +"Copyright and Serial were deprecated by License and Epoch +syn region specPreAmbleDeprecated oneline matchgroup=specError start='^\(Copyright\|Serial\)' end='$' contains=specEmail,specURL,specURLMacro,specLicense,specColon,specVariables,specSpecialChar,specMacroIdentifier +syn region specPreAmble oneline matchgroup=specCommand start='^\(Prereq\|Summary\|Name\|Version\|Packager\|Requires\|Recommends\|Suggests\|Supplements\|Enhances\|Icon\|URL\|Source\d*\|Patch\d*\|Prefix\|Packager\|Group\|License\|Release\|BuildRoot\|Distribution\|Vendor\|Provides\|ExclusiveArch\|ExcludeArch\|ExclusiveOS\|Obsoletes\|BuildArch\|BuildArchitectures\|BuildRequires\|BuildConflicts\|BuildPreReq\|Conflicts\|AutoRequires\|AutoReq\|AutoReqProv\|AutoProv\|Epoch\)' end='$' contains=specEmail,specURL,specURLMacro,specLicense,specColon,specVariables,specSpecialChar,specMacroIdentifier + +"%% Description Section %% +syn region specDescriptionArea matchgroup=specSection start='^%description' end='^%'me=e-1 contains=specDescriptionOpts,specEmail,specURL,specNumber,specMacroIdentifier,specComment + +"%% Package Section %% +syn region specPackageArea matchgroup=specSection start='^%package' end='^%'me=e-1 contains=specPackageOpts,specPreAmble,specComment + +"%% Scripts Section %% +syn region specScriptArea matchgroup=specSection start='^%\(prep\|build\|install\|clean\|pre\|postun\|preun\|post\|posttrans\)\>' skip='^%{\|^%\(define\|patch\d*\|configure\|GNUconfigure\|setup\|autosetup\|autopatch\|find_lang\|make_build\|makeinstall\|make_install\)\>' end='^%'me=e-1 contains=specSpecialVariables,specVariables,@specCommands,specVariables,shDo,shFor,shCaseEsac,specNoNumberHilite,specCommandOpts,shComment,shIf,specSpecialChar,specMacroIdentifier,specSectionMacroArea,specSectionMacroBracketArea,shOperator,shQuote1,shQuote2 + +"%% Changelog Section %% +syn region specChangelogArea matchgroup=specSection start='^%changelog' end='^%'me=e-1 contains=specEmail,specURL,specWeekday,specMonth,specNumber,specComment,specLicense + + + +"------------------------------------------------------------------------------ +"here's the shell syntax for all the Script Sections + + +syn case match + + +"sh-like comment stile, only valid in script part +syn match shComment contained '#.*$' + +syn region shQuote1 contained matchgroup=shQuoteDelim start=+'+ skip=+\\'+ end=+'+ contains=specMacroIdentifier +syn region shQuote2 contained matchgroup=shQuoteDelim start=+"+ skip=+\\"+ end=+"+ contains=specVariables,specMacroIdentifier + +syn match shOperator contained '[><|!&;]\|[!=]=' +syn region shDo transparent matchgroup=specBlock start="\" end="\" contains=ALLBUT,shFunction,shDoError,shCase,specPreAmble,@specListedFiles + +syn region specIf matchgroup=specBlock start="%ifosf\|%ifos\|%ifnos\|%ifarch\|%ifnarch\|%else" end='%endif' contains=ALLBUT, specIfError, shCase + +syn region shIf transparent matchgroup=specBlock start="\" end="\" contains=ALLBUT,shFunction,shIfError,shCase,@specListedFiles + +syn region shFor matchgroup=specBlock start="\" end="\" contains=ALLBUT,shFunction,shInError,shCase,@specListedFiles + +syn region shCaseEsac transparent matchgroup=specBlock start="\" matchgroup=NONE end="\"me=s-1 contains=ALLBUT,shFunction,shCaseError,@specListedFiles nextgroup=shCaseEsac +syn region shCaseEsac matchgroup=specBlock start="\" end="\" contains=ALLBUT,shFunction,shCaseError,@specListedFilesBin +syn region shCase matchgroup=specBlock contained start=")" end=";;" contains=ALLBUT,shFunction,shCaseError,shCase,@specListedFiles + +syn sync match shDoSync grouphere shDo "\" +syn sync match shDoSync groupthere shDo "\" +syn sync match shIfSync grouphere shIf "\" +syn sync match shIfSync groupthere shIf "\" +syn sync match specIfSync grouphere specIf "%ifarch\|%ifos\|%ifnos" +syn sync match specIfSync groupthere specIf "%endIf" +syn sync match shForSync grouphere shFor "\" +syn sync match shForSync groupthere shFor "\" +syn sync match shCaseEsacSync grouphere shCaseEsac "\" +syn sync match shCaseEsacSync groupthere shCaseEsac "\" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +"main types color definitions +hi def link specSection Structure +hi def link specSectionMacro Macro +hi def link specWWWlink PreProc +hi def link specOpts Operator + +"yes, it's ugly, but white is sooo cool +if &background == "dark" +hi def specGlobalMacro ctermfg=white +else +hi def link specGlobalMacro Identifier +endif + +"sh colors +hi def link shComment Comment +hi def link shIf Statement +hi def link shOperator Special +hi def link shQuote1 String +hi def link shQuote2 String +hi def link shQuoteDelim Statement + +"spec colors +hi def link specBlock Function +hi def link specColon Special +hi def link specCommand Statement +hi def link specCommandOpts specOpts +hi def link specCommandSpecial Special +hi def link specComment Comment +hi def link specConfigure specCommand +hi def link specDate String +hi def link specDescriptionOpts specOpts +hi def link specEmail specWWWlink +hi def link specError Error +hi def link specFilesDirective specSectionMacro +hi def link specFilesOpts specOpts +hi def link specLicense String +hi def link specMacroNameLocal specGlobalMacro +hi def link specMacroNameOther specGlobalMacro +hi def link specManpageFile NONE +hi def link specMonth specDate +hi def link specNoNumberHilite NONE +hi def link specNumber Number +hi def link specPackageOpts specOpts +hi def link specPercent Special +hi def link specSpecialChar Special +hi def link specSpecialVariables specGlobalMacro +hi def link specSpecialVariablesNames specGlobalMacro +hi def link specTarCommand specCommand +hi def link specURL specWWWlink +hi def link specURLMacro specWWWlink +hi def link specVariables Identifier +hi def link specWeekday specDate +hi def link specListedFilesBin Statement +hi def link specListedFilesDoc Statement +hi def link specListedFilesEtc Statement +hi def link specListedFilesLib Statement +hi def link specListedFilesPrefix Statement +hi def link specListedFilesShare Statement + + +let b:current_syntax = "spec" + +" vim: ts=8 + +endif diff --git a/syntax/specman.vim b/syntax/specman.vim new file mode 100644 index 0000000..be653b3 --- /dev/null +++ b/syntax/specman.vim @@ -0,0 +1,173 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SPECMAN E-LANGUAGE +" Maintainer: Or Freund +" Last Update: Wed Oct 24 2001 + +"--------------------------------------------------------- +"| If anyone found an error or fix the parenthesis part | +"| I will be happy to hear about it | +"| Thanks Or. | +"--------------------------------------------------------- + +" Remove any old syntax stuff hanging around +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword specmanTodo contained TODO todo ToDo FIXME XXX + +syn keyword specmanStatement var instance on compute start event expect check that routine +syn keyword specmanStatement specman is also first only with like +syn keyword specmanStatement list of all radix hex dec bin ignore illegal +syn keyword specmanStatement traceable untraceable +syn keyword specmanStatement cover using count_only trace_only at_least transition item ranges +syn keyword specmanStatement cross text call task within + +syn keyword specmanMethod initialize non_terminal testgroup delayed exit finish +syn keyword specmanMethod out append print outf appendf +syn keyword specmanMethod post_generate pre_generate setup_test finalize_test extract_test +syn keyword specmanMethod init run copy as_a set_config dut_error add clear lock quit +syn keyword specmanMethod lock unlock release swap quit to_string value stop_run +syn keyword specmanMethod crc_8 crc_32 crc_32_flip get_config add0 all_indices and_all +syn keyword specmanMethod apply average count delete exists first_index get_indices +syn keyword specmanMethod has insert is_a_permutation is_empty key key_exists key_index +syn keyword specmanMethod last last_index max max_index max_value min min_index +syn keyword specmanMethod min_value or_all pop pop0 push push0 product resize reverse +syn keyword specmanMethod sort split sum top top0 unique clear is_all_iterations +syn keyword specmanMethod get_enclosing_unit hdl_path exec deep_compare deep_compare_physical +syn keyword specmanMethod pack unpack warning error fatal +syn match specmanMethod "size()" +syn keyword specmanPacking packing low high +syn keyword specmanType locker address +syn keyword specmanType body code vec chars +syn keyword specmanType integer real bool int long uint byte bits bit time string +syn keyword specmanType byte_array external_pointer +syn keyword specmanBoolean TRUE FALSE +syn keyword specmanPreCondit #ifdef #ifndef #else + +syn keyword specmanConditional choose matches +syn keyword specmanConditional if then else when try + + + +syn keyword specmanLabel case casex casez default + +syn keyword specmanLogical and or not xor + +syn keyword specmanRepeat until repeat while for from to step each do break continue +syn keyword specmanRepeat before next sequence always -kind network +syn keyword specmanRepeat index it me in new return result select + +syn keyword specmanTemporal cycle sample events forever +syn keyword specmanTemporal wait change negedge rise fall delay sync sim true detach eventually emit + +syn keyword specmanConstant MAX_INT MIN_INT NULL UNDEF + +syn keyword specmanDefine define as computed type extend +syn keyword specmanDefine verilog vhdl variable global sys +syn keyword specmanStructure struct unit +syn keyword specmanInclude import +syn keyword specmanConstraint gen keep keeping soft before + +syn keyword specmanSpecial untyped symtab ECHO DOECHO +syn keyword specmanFile files load module ntv source_ref script read write +syn keyword specmanFSM initial idle others posedge clock cycles + + +syn match specmanOperator "[&|~>"hs=s+2 end="^<'"he=e-2 + +syn match specmanHDL "'[`.a-zA-Z0-9_@\[\]]\+\>'" + + +syn match specmanCompare "==" +syn match specmanCompare "!===" +syn match specmanCompare "===" +syn match specmanCompare "!=" +syn match specmanCompare ">=" +syn match specmanCompare "<=" +syn match specmanNumber "[0-9]:[0-9]" +syn match specmanNumber "\(\<\d\+\|\)'[bB]\s*[0-1_xXzZ?]\+\>" +syn match specmanNumber "0[bB]\s*[0-1_xXzZ?]\+\>" +syn match specmanNumber "\(\<\d\+\|\)'[oO]\s*[0-7_xXzZ?]\+\>" +syn match specmanNumber "0[oO]\s*[0-9a-fA-F_xXzZ?]\+\>" +syn match specmanNumber "\(\<\d\+\|\)'[dD]\s*[0-9_xXzZ?]\+\>" +syn match specmanNumber "\(\<\d\+\|\)'[hH]\s*[0-9a-fA-F_xXzZ?]\+\>" +syn match specmanNumber "0[xX]\s*[0-9a-fA-F_xXzZ?]\+\>" +syn match specmanNumber "\<[+-]\=[0-9_]\+\(\.[0-9_]*\|\)\(e[0-9_]*\|\)\>" + +syn region specmanString start=+"+ end=+"+ + + + +"********************************************************************** +" I took this section from c.vim but I didnt succeded to make it work +" ANY one who dare jumping to this deep watter is more than welocome! +"********************************************************************** +""catch errors caused by wrong parenthesis and brackets + +"syn cluster specmanParenGroup contains=specmanParenError +"" ,specmanNumbera,specmanComment +"if exists("specman_no_bracket_error") +"syn region specmanParen transparent start='(' end=')' contains=ALLBUT,@specmanParenGroup +"syn match specmanParenError ")" +"syn match specmanErrInParen contained "[{}]" +"else +"syn region specmanParen transparent start='(' end=')' contains=ALLBUT,@specmanParenGroup,specmanErrInBracket +"syn match specmanParenError "[\])]" +"syn match specmanErrInParen contained "[\]{}]" +"syn region specmanBracket transparent start='\[' end=']' contains=ALLBUT,@specmanParenGroup,specmanErrInParen +"syn match specmanErrInBracket contained "[);{}]" +"endif +" + +"Modify the following as needed. The trade-off is performance versus +"functionality. + +syn sync lines=50 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +" The default methods for highlighting. Can be overridden later +hi def link specmanConditional Conditional +hi def link specmanConstraint Conditional +hi def link specmanRepeat Repeat +hi def link specmanString String +hi def link specmanComment Comment +hi def link specmanConstant Macro +hi def link specmanNumber Number +hi def link specmanCompare Operator +hi def link specmanOperator Operator +hi def link specmanLogical Operator +hi def link specmanStatement Statement +hi def link specmanHDL SpecialChar +hi def link specmanMethod Function +hi def link specmanInclude Include +hi def link specmanStructure Structure +hi def link specmanBoolean Boolean +hi def link specmanFSM Label +hi def link specmanSpecial Special +hi def link specmanType Type +hi def link specmanTemporal Type +hi def link specmanFile Include +hi def link specmanPreCondit Include +hi def link specmanDefine Typedef +hi def link specmanLabel Label +hi def link specmanPacking keyword +hi def link specmanTodo Todo +hi def link specmanParenError Error +hi def link specmanErrInParen Error +hi def link specmanErrInBracket Error + +let b:current_syntax = "specman" + +endif diff --git a/syntax/spice.vim b/syntax/spice.vim new file mode 100644 index 0000000..3970306 --- /dev/null +++ b/syntax/spice.vim @@ -0,0 +1,79 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Spice circuit simulator input netlist +" Maintainer: Noam Halevy +" Last Change: 2012 Jun 01 +" (Dominique Pelle added @Spell) +" +" This is based on sh.vim by Lennart Schultz +" but greatly simplified + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" spice syntax is case INsensitive +syn case ignore + +syn keyword spiceTodo contained TODO + +syn match spiceComment "^ \=\*.*$" contains=@Spell +syn match spiceComment "\$.*$" contains=@Spell + +" Numbers, all with engineering suffixes and optional units +"========================================================== +"floating point number, with dot, optional exponent +syn match spiceNumber "\<[0-9]\+\.[0-9]*\(e[-+]\=[0-9]\+\)\=\(meg\=\|[afpnumkg]\)\=" +"floating point number, starting with a dot, optional exponent +syn match spiceNumber "\.[0-9]\+\(e[-+]\=[0-9]\+\)\=\(meg\=\|[afpnumkg]\)\=" +"integer number with optional exponent +syn match spiceNumber "\<[0-9]\+\(e[-+]\=[0-9]\+\)\=\(meg\=\|[afpnumkg]\)\=" + +" Misc +"===== +syn match spiceWrapLineOperator "\\$" +syn match spiceWrapLineOperator "^+" + +syn match spiceStatement "^ \=\.\I\+" + +" Matching pairs of parentheses +"========================================== +syn region spiceParen transparent matchgroup=spiceOperator start="(" end=")" contains=ALLBUT,spiceParenError +syn region spiceSinglequote matchgroup=spiceOperator start=+'+ end=+'+ + +" Errors +"======= +syn match spiceParenError ")" + +" Syncs +" ===== +syn sync minlines=50 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link spiceTodo Todo +hi def link spiceWrapLineOperator spiceOperator +hi def link spiceSinglequote spiceExpr +hi def link spiceExpr Function +hi def link spiceParenError Error +hi def link spiceStatement Statement +hi def link spiceNumber Number +hi def link spiceComment Comment +hi def link spiceOperator Operator + + +let b:current_syntax = "spice" + +" insert the following to $VIM/syntax/scripts.vim +" to autodetect HSpice netlists and text listing output: +" +" " Spice netlists and text listings +" elseif getline(1) =~ 'spice\>' || getline("$") =~ '^\.end' +" so :p:h/spice.vim + +" vim: ts=8 + +endif diff --git a/syntax/splint.vim b/syntax/splint.vim new file mode 100644 index 0000000..a3656b1 --- /dev/null +++ b/syntax/splint.vim @@ -0,0 +1,247 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: splint (C with lclint/splint Annotations) +" Maintainer: Ralf Wildenhues +" Splint Home: http://www.splint.org/ +" Last Change: $Date: 2004/06/13 20:08:47 $ +" $Revision: 1.1 $ + +" Note: Splint annotated files are not detected by default. +" If you want to use this file for highlighting C code, +" please make sure splint.vim is sourced instead of c.vim, +" for example by putting +" /* vim: set filetype=splint : */ +" at the end of your code or something like +" au! BufRead,BufNewFile *.c setfiletype splint +" in your vimrc file or filetype.vim + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read the C syntax to start with +runtime! syntax/c.vim + + +" FIXME: uses and changes several clusters defined in c.vim +" so watch for changes there + +" TODO: make a little more grammar explicit +" match flags with hyphen and underscore notation +" match flag expanded forms +" accept other comment char than @ + +syn case match +" splint annotations (taken from 'splint -help annotations') +syn match splintStateAnnot contained "\(pre\|post\):\(only\|shared\|owned\|dependent\|observer\|exposed\|isnull\|notnull\)" +syn keyword splintSpecialAnnot contained special +syn keyword splintSpecTag contained uses sets defines allocated releases +syn keyword splintModifies contained modifies +syn keyword splintRequires contained requires ensures +syn keyword splintGlobals contained globals +syn keyword splintGlobitem contained internalState fileSystem +syn keyword splintGlobannot contained undef killed +syn keyword splintWarning contained warn + +syn keyword splintModitem contained internalState fileSystem nothing +syn keyword splintReqitem contained MaxSet MaxRead result +syn keyword splintIter contained iter yield +syn keyword splintConst contained constant +syn keyword splintAlt contained alt + +syn keyword splintType contained abstract concrete mutable immutable refcounted numabstract +syn keyword splintGlobalType contained unchecked checkmod checked checkedstrict +syn keyword splintMemMgm contained dependent keep killref only owned shared temp +syn keyword splintAlias contained unique returned +syn keyword splintExposure contained observer exposed +syn keyword splintDefState contained out in partial reldef +syn keyword splintGlobState contained undef killed +syn keyword splintNullState contained null notnull relnull +syn keyword splintNullPred contained truenull falsenull nullwhentrue falsewhennull +syn keyword splintExit contained exits mayexit trueexit falseexit neverexit +syn keyword splintExec contained noreturn maynotreturn noreturnwhentrue noreturnwhenfalse alwaysreturns +syn keyword splintSef contained sef +syn keyword splintDecl contained unused external +syn keyword splintCase contained fallthrough +syn keyword splintBreak contained innerbreak loopbreak switchbreak innercontinue +syn keyword splintUnreach contained notreached +syn keyword splintSpecFunc contained printflike scanflike messagelike + +" TODO: make these region or match +syn keyword splintErrSupp contained i ignore end t +syn match splintErrSupp contained "[it]\d\+\>" +syn keyword splintTypeAcc contained access noaccess + +syn keyword splintMacro contained notfunction +syn match splintSpecType contained "\(\|unsigned\|signed\)integraltype" + +" Flags taken from 'splint -help flags full' divided in local and global flags +" Local Flags: +syn keyword splintFlag contained abstract abstractcompare accessall accessczech accessczechoslovak +syn keyword splintFlag contained accessfile accessmodule accessslovak aliasunique allblock +syn keyword splintFlag contained allempty allglobs allimponly allmacros alwaysexits +syn keyword splintFlag contained annotationerror ansi89limits assignexpose badflag bitwisesigned +syn keyword splintFlag contained boolcompare boolfalse boolint boolops booltrue +syn keyword splintFlag contained booltype bounds boundscompacterrormessages boundsread boundswrite +syn keyword splintFlag contained branchstate bufferoverflow bufferoverflowhigh bugslimit casebreak +syn keyword splintFlag contained caseinsensitivefilenames castexpose castfcnptr charindex charint +syn keyword splintFlag contained charintliteral charunsignedchar checkedglobalias checkmodglobalias checkpost +syn keyword splintFlag contained checkstrictglobalias checkstrictglobs codeimponly commentchar commenterror +syn keyword splintFlag contained compdef compdestroy compmempass constmacros constprefix +syn keyword splintFlag contained constprefixexclude constuse continuecomment controlnestdepth cppnames +syn keyword splintFlag contained csvoverwrite czech czechconsts czechfcns czechmacros +syn keyword splintFlag contained czechoslovak czechoslovakconsts czechoslovakfcns czechoslovakmacros czechoslovaktypes +syn keyword splintFlag contained czechoslovakvars czechtypes czechvars debugfcnconstraint declundef +syn keyword splintFlag contained deepbreak deparrays dependenttrans distinctexternalnames distinctinternalnames +syn keyword splintFlag contained duplicatecases duplicatequals elseifcomplete emptyret enumindex +syn keyword splintFlag contained enumint enummembers enummemuse enumprefix enumprefixexclude +syn keyword splintFlag contained evalorder evalorderuncon exitarg exportany exportconst +syn keyword splintFlag contained exportfcn exportheader exportheadervar exportiter exportlocal +syn keyword splintFlag contained exportmacro exporttype exportvar exposetrans externalnamecaseinsensitive +syn keyword splintFlag contained externalnamelen externalprefix externalprefixexclude fcnderef fcnmacros +syn keyword splintFlag contained fcnpost fcnuse fielduse fileextensions filestaticprefix +syn keyword splintFlag contained filestaticprefixexclude firstcase fixedformalarray floatdouble forblock +syn keyword splintFlag contained forcehints forempty forloopexec formalarray formatcode +syn keyword splintFlag contained formatconst formattype forwarddecl freshtrans fullinitblock +syn keyword splintFlag contained globalias globalprefix globalprefixexclude globimponly globnoglobs +syn keyword splintFlag contained globs globsimpmodsnothing globstate globuse gnuextensions +syn keyword splintFlag contained grammar hasyield hints htmlfileformat ifblock +syn keyword splintFlag contained ifempty ignorequals ignoresigns immediatetrans impabstract +syn keyword splintFlag contained impcheckedglobs impcheckedspecglobs impcheckedstatics impcheckedstrictglobs impcheckedstrictspecglobs +syn keyword splintFlag contained impcheckedstrictstatics impcheckmodglobs impcheckmodinternals impcheckmodspecglobs impcheckmodstatics +syn keyword splintFlag contained impconj implementationoptional implictconstraint impouts imptype +syn keyword splintFlag contained includenest incompletetype incondefs incondefslib indentspaces +syn keyword splintFlag contained infloops infloopsuncon initallelements initsize internalglobs +syn keyword splintFlag contained internalglobsnoglobs internalnamecaseinsensitive internalnamelen internalnamelookalike iso99limits +syn keyword splintFlag contained isoreserved isoreservedinternal iterbalance iterloopexec iterprefix +syn keyword splintFlag contained iterprefixexclude iteryield its4low its4moderate its4mostrisky +syn keyword splintFlag contained its4risky its4veryrisky keep keeptrans kepttrans +syn keyword splintFlag contained legacy libmacros likelyboundsread likelyboundswrite likelybool +syn keyword splintFlag contained likelybounds limit linelen lintcomments localprefix +syn keyword splintFlag contained localprefixexclude locindentspaces longint longintegral longsignedintegral +syn keyword splintFlag contained longunsignedintegral longunsignedunsignedintegral loopexec looploopbreak looploopcontinue +syn keyword splintFlag contained loopswitchbreak macroassign macroconstdecl macrodecl macroempty +syn keyword splintFlag contained macrofcndecl macromatchname macroparams macroparens macroredef +syn keyword splintFlag contained macroreturn macrostmt macrounrecog macrovarprefix macrovarprefixexclude +syn keyword splintFlag contained maintype matchanyintegral matchfields mayaliasunique memchecks +syn keyword splintFlag contained memimp memtrans misplacedsharequal misscase modfilesys +syn keyword splintFlag contained modglobs modglobsnomods modglobsunchecked modinternalstrict modnomods +syn keyword splintFlag contained modobserver modobserveruncon mods modsimpnoglobs modstrictglobsnomods +syn keyword splintFlag contained moduncon modunconnomods modunspec multithreaded mustdefine +syn keyword splintFlag contained mustfree mustfreefresh mustfreeonly mustmod mustnotalias +syn keyword splintFlag contained mutrep namechecks needspec nestcomment nestedextern +syn keyword splintFlag contained newdecl newreftrans nextlinemacros noaccess nocomments +syn keyword splintFlag contained noeffect noeffectuncon noparams nopp noret +syn keyword splintFlag contained null nullassign nullderef nullinit nullpass +syn keyword splintFlag contained nullptrarith nullret nullstate nullterminated +syn keyword splintFlag contained numabstract numabstractcast numabstractindex numabstractlit numabstractprint +syn keyword splintFlag contained numenummembers numliteral numstructfields observertrans obviousloopexec +syn keyword splintFlag contained oldstyle onlytrans onlyunqglobaltrans orconstraint overload +syn keyword splintFlag contained ownedtrans paramimptemp paramuse parenfileformat partial +syn keyword splintFlag contained passunknown portability predassign predbool predboolint +syn keyword splintFlag contained predboolothers predboolptr preproc protoparammatch protoparamname +syn keyword splintFlag contained protoparamprefix protoparamprefixexclude ptrarith ptrcompare ptrnegate +syn keyword splintFlag contained quiet readonlystrings readonlytrans realcompare redecl +syn keyword splintFlag contained redef redundantconstraints redundantsharequal refcounttrans relaxquals +syn keyword splintFlag contained relaxtypes repeatunrecog repexpose retalias retexpose +syn keyword splintFlag contained retimponly retval retvalbool retvalint retvalother +syn keyword splintFlag contained sefparams sefuncon shadow sharedtrans shiftimplementation +syn keyword splintFlag contained shiftnegative shortint showallconjs showcolumn showconstraintlocation +syn keyword splintFlag contained showconstraintparens showdeephistory showfunc showloadloc showscan +syn keyword splintFlag contained showsourceloc showsummary sizeofformalarray sizeoftype skipisoheaders +syn keyword splintFlag contained skipposixheaders slashslashcomment slovak slovakconsts slovakfcns +syn keyword splintFlag contained slovakmacros slovaktypes slovakvars specglobimponly specimponly +syn keyword splintFlag contained specmacros specretimponly specstructimponly specundecl specundef +syn keyword splintFlag contained stackref statemerge statetransfer staticinittrans statictrans +syn keyword splintFlag contained strictbranchstate strictdestroy strictops strictusereleased stringliterallen +syn keyword splintFlag contained stringliteralnoroom stringliteralnoroomfinalnull stringliteralsmaller stringliteraltoolong structimponly +syn keyword splintFlag contained superuser switchloopbreak switchswitchbreak syntax sysdirerrors +syn keyword splintFlag contained sysdirexpandmacros sysunrecog tagprefix tagprefixexclude temptrans +syn keyword splintFlag contained tmpcomments toctou topuse trytorecover type +syn keyword splintFlag contained typeprefix typeprefixexclude typeuse uncheckedglobalias uncheckedmacroprefix +syn keyword splintFlag contained uncheckedmacroprefixexclude uniondef unixstandard unqualifiedinittrans unqualifiedtrans +syn keyword splintFlag contained unreachable unrecog unrecogcomments unrecogdirective unrecogflagcomments +syn keyword splintFlag contained unsignedcompare unusedspecial usedef usereleased usevarargs +syn keyword splintFlag contained varuse voidabstract warnflags warnlintcomments warnmissingglobs +syn keyword splintFlag contained warnmissingglobsnoglobs warnposixheaders warnrc warnsysfiles warnunixlib +syn keyword splintFlag contained warnuse whileblock whileempty whileloopexec zerobool +syn keyword splintFlag contained zeroptr +" Global Flags: +syn keyword splintGlobalFlag contained csv dump errorstream errorstreamstderr errorstreamstdout +syn keyword splintGlobalFlag contained expect f help i isolib +syn keyword splintGlobalFlag contained larchpath lclexpect lclimportdir lcs lh +syn keyword splintGlobalFlag contained load messagestream messagestreamstderr messagestreamstdout mts +syn keyword splintGlobalFlag contained neverinclude nof nolib posixlib posixstrictlib +syn keyword splintGlobalFlag contained showalluses singleinclude skipsysheaders stats streamoverwrite +syn keyword splintGlobalFlag contained strictlib supcounts sysdirs timedist tmpdir +syn keyword splintGlobalFlag contained unixlib unixstrictlib warningstream warningstreamstderr warningstreamstdout +syn keyword splintGlobalFlag contained whichlib +syn match splintFlagExpr contained "[\+\-\=]" nextgroup=splintFlag,splintGlobalFlag + +" detect missing /*@ and wrong */ +syn match splintAnnError "@\*/" +syn cluster cCommentGroup add=splintAnnError +syn match splintAnnError2 "[^@]\*/"hs=s+1 contained +syn region splintAnnotation start="/\*@" end="@\*/" contains=@splintAnnotElem,cType keepend +syn match splintShortAnn "/\*@\*/" +syn cluster splintAnnotElem contains=splintStateAnnot,splintSpecialAnnot,splintSpecTag,splintModifies,splintRequires,splintGlobals,splintGlobitem,splintGlobannot,splintWarning,splintModitem,splintIter,splintConst,splintAlt,splintType,splintGlobalType,splintMemMgm,splintAlias,splintExposure,splintDefState,splintGlobState,splintNullState,splintNullPred,splintExit,splintExec,splintSef,splintDecl,splintCase,splintBreak,splintUnreach,splintSpecFunc,splintErrSupp,splintTypeAcc,splintMacro,splintSpecType,splintAnnError2,splintFlagExpr +syn cluster splintAllStuff contains=@splintAnnotElem,splintFlag,splintGlobalFlag +syn cluster cParenGroup add=@splintAllStuff +syn cluster cPreProcGroup add=@splintAllStuff +syn cluster cMultiGroup add=@splintAllStuff + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link splintShortAnn splintAnnotation +hi def link splintAnnotation Comment +hi def link splintAnnError splintError +hi def link splintAnnError2 splintError +hi def link splintFlag SpecialComment +hi def link splintGlobalFlag splintError +hi def link splintSpecialAnnot splintAnnKey +hi def link splintStateAnnot splintAnnKey +hi def link splintSpecTag splintAnnKey +hi def link splintModifies splintAnnKey +hi def link splintRequires splintAnnKey +hi def link splintGlobals splintAnnKey +hi def link splintGlobitem Constant +hi def link splintGlobannot splintAnnKey +hi def link splintWarning splintAnnKey +hi def link splintModitem Constant +hi def link splintIter splintAnnKey +hi def link splintConst splintAnnKey +hi def link splintAlt splintAnnKey +hi def link splintType splintAnnKey +hi def link splintGlobalType splintAnnKey +hi def link splintMemMgm splintAnnKey +hi def link splintAlias splintAnnKey +hi def link splintExposure splintAnnKey +hi def link splintDefState splintAnnKey +hi def link splintGlobState splintAnnKey +hi def link splintNullState splintAnnKey +hi def link splintNullPred splintAnnKey +hi def link splintExit splintAnnKey +hi def link splintExec splintAnnKey +hi def link splintSef splintAnnKey +hi def link splintDecl splintAnnKey +hi def link splintCase splintAnnKey +hi def link splintBreak splintAnnKey +hi def link splintUnreach splintAnnKey +hi def link splintSpecFunc splintAnnKey +hi def link splintErrSupp splintAnnKey +hi def link splintTypeAcc splintAnnKey +hi def link splintMacro splintAnnKey +hi def link splintSpecType splintAnnKey +hi def link splintAnnKey Type +hi def link splintError Error + + +let b:current_syntax = "splint" + +" vim: ts=8 + +endif diff --git a/syntax/spup.vim b/syntax/spup.vim new file mode 100644 index 0000000..ecef399 --- /dev/null +++ b/syntax/spup.vim @@ -0,0 +1,273 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Speedup, plant simulator from AspenTech +" Maintainer: Stefan.Schwarzer +" URL: http://www.ndh.net/home/sschwarzer/download/spup.vim +" Last Change: 2012 Feb 03 by Thilo Six +" Filename: spup.vim + +" Bugs +" - in the appropriate sections keywords are always highlighted +" even if they are not used with the appropriate meaning; +" example: in +" MODEL demonstration +" TYPE +" *area AS area +" both "area" are highlighted as spupType. +" +" If you encounter problems or have questions or suggestions, mail me + +" Remove old syntax stuff +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" don't hightlight several keywords like subsections +"let strict_subsections = 1 + +" highlight types usually found in DECLARE section +if !exists("hightlight_types") + let highlight_types = 1 +endif + +" one line comment syntax (# comments) +" 1. allow appended code after comment, do not complain +" 2. show code beginnig with the second # as an error +" 3. show whole lines with more than one # as an error +if !exists("oneline_comments") + let oneline_comments = 2 +endif + +" Speedup SECTION regions +syn case ignore +syn region spupCdi matchgroup=spupSection start="^CDI" end="^\*\*\*\*" contains=spupCdiSubs,@spupOrdinary +syn region spupConditions matchgroup=spupSection start="^CONDITIONS" end="^\*\*\*\*" contains=spupConditionsSubs,@spupOrdinary,spupConditional,spupOperator,spupCode +syn region spupDeclare matchgroup=spupSection start="^DECLARE" end="^\*\*\*\*" contains=spupDeclareSubs,@spupOrdinary,spupTypes,spupCode +syn region spupEstimation matchgroup=spupSection start="^ESTIMATION" end="^\*\*\*\*" contains=spupEstimationSubs,@spupOrdinary +syn region spupExternal matchgroup=spupSection start="^EXTERNAL" end="^\*\*\*\*" contains=spupExternalSubs,@spupOrdinary +syn region spupFlowsheet matchgroup=spupSection start="^FLOWSHEET" end="^\*\*\*\*" contains=spupFlowsheetSubs,@spupOrdinary,spupStreams,@spupTextproc +syn region spupFunction matchgroup=spupSection start="^FUNCTION" end="^\*\*\*\*" contains=spupFunctionSubs,@spupOrdinary,spupHelp,spupCode,spupTypes +syn region spupGlobal matchgroup=spupSection start="^GLOBAL" end="^\*\*\*\*" contains=spupGlobalSubs,@spupOrdinary +syn region spupHomotopy matchgroup=spupSection start="^HOMOTOPY" end="^\*\*\*\*" contains=spupHomotopySubs,@spupOrdinary +syn region spupMacro matchgroup=spupSection start="^MACRO" end="^\*\*\*\*" contains=spupMacroSubs,@spupOrdinary,@spupTextproc,spupTypes,spupStreams,spupOperator +syn region spupModel matchgroup=spupSection start="^MODEL" end="^\*\*\*\*" contains=spupModelSubs,@spupOrdinary,spupConditional,spupOperator,spupTypes,spupStreams,@spupTextproc,spupHelp +syn region spupOperation matchgroup=spupSection start="^OPERATION" end="^\*\*\*\*" contains=spupOperationSubs,@spupOrdinary,@spupTextproc +syn region spupOptions matchgroup=spupSection start="^OPTIONS" end="^\*\*\*\*" contains=spupOptionsSubs,@spupOrdinary +syn region spupProcedure matchgroup=spupSection start="^PROCEDURE" end="^\*\*\*\*" contains=spupProcedureSubs,@spupOrdinary,spupHelp,spupCode,spupTypes +syn region spupProfiles matchgroup=spupSection start="^PROFILES" end="^\*\*\*\*" contains=@spupOrdinary,@spupTextproc +syn region spupReport matchgroup=spupSection start="^REPORT" end="^\*\*\*\*" contains=spupReportSubs,@spupOrdinary,spupHelp,@spupTextproc +syn region spupTitle matchgroup=spupSection start="^TITLE" end="^\*\*\*\*" contains=spupTitleSubs,spupComment,spupConstant,spupError +syn region spupUnit matchgroup=spupSection start="^UNIT" end="^\*\*\*\*" contains=spupUnitSubs,@spupOrdinary + +" Subsections +syn keyword spupCdiSubs INPUT FREE OUTPUT LINEARTIME MINNONZERO CALCULATE FILES SCALING contained +syn keyword spupDeclareSubs TYPE STREAM contained +syn keyword spupEstimationSubs ESTIMATE SSEXP DYNEXP RESULT contained +syn keyword spupExternalSubs TRANSMIT RECEIVE contained +syn keyword spupFlowsheetSubs STREAM contained +syn keyword spupFunctionSubs INPUT OUTPUT contained +syn keyword spupGlobalSubs VARIABLES MAXIMIZE MINIMIZE CONSTRAINT contained +syn keyword spupHomotopySubs VARY OPTIONS contained +syn keyword spupMacroSubs MODEL FLOWSHEET contained +syn keyword spupModelSubs CATEGORY SET TYPE STREAM EQUATION PROCEDURE contained +syn keyword spupOperationSubs SET PRESET INITIAL SSTATE FREE contained +syn keyword spupOptionsSubs ROUTINES TRANSLATE EXECUTION contained +syn keyword spupProcedureSubs INPUT OUTPUT SPACE PRECALL POSTCALL DERIVATIVE STREAM contained +" no subsections for Profiles +syn keyword spupReportSubs SET INITIAL FIELDS FIELDMARK DISPLAY WITHIN contained +syn keyword spupUnitSubs ROUTINES SET contained + +" additional keywords for subsections +if !exists( "strict_subsections" ) + syn keyword spupConditionsSubs STOP PRINT contained + syn keyword spupDeclareSubs UNIT SET COMPONENTS THERMO OPTIONS contained + syn keyword spupEstimationSubs VARY MEASURE INITIAL contained + syn keyword spupFlowsheetSubs TYPE FEED PRODUCT INPUT OUTPUT CONNECTION OF IS contained + syn keyword spupMacroSubs CONNECTION STREAM SET INPUT OUTPUT OF IS FEED PRODUCT TYPE contained + syn keyword spupModelSubs AS ARRAY OF INPUT OUTPUT CONNECTION contained + syn keyword spupOperationSubs WITHIN contained + syn keyword spupReportSubs LEFT RIGHT CENTER CENTRE UOM TIME DATE VERSION RELDATE contained + syn keyword spupUnitSubs IS A contained +endif + +" Speedup data types +if exists( "highlight_types" ) + syn keyword spupTypes act_coeff_liq area coefficient concentration contained + syn keyword spupTypes control_signal cond_liq cond_vap cp_mass_liq contained + syn keyword spupTypes cp_mol_liq cp_mol_vap cv_mol_liq cv_mol_vap contained + syn keyword spupTypes diffus_liq diffus_vap delta_p dens_mass contained + syn keyword spupTypes dens_mass_sol dens_mass_liq dens_mass_vap dens_mol contained + syn keyword spupTypes dens_mol_sol dens_mol_liq dens_mol_vap enthflow contained + syn keyword spupTypes enth_mass enth_mass_liq enth_mass_vap enth_mol contained + syn keyword spupTypes enth_mol_sol enth_mol_liq enth_mol_vap entr_mol contained + syn keyword spupTypes entr_mol_sol entr_mol_liq entr_mol_vap fraction contained + syn keyword spupTypes flow_mass flow_mass_liq flow_mass_vap flow_mol contained + syn keyword spupTypes flow_mol_vap flow_mol_liq flow_vol flow_vol_vap contained + syn keyword spupTypes flow_vol_liq fuga_vap fuga_liq fuga_sol contained + syn keyword spupTypes gibb_mol_sol heat_react heat_trans_coeff contained + syn keyword spupTypes holdup_heat holdup_heat_liq holdup_heat_vap contained + syn keyword spupTypes holdup_mass holdup_mass_liq holdup_mass_vap contained + syn keyword spupTypes holdup_mol holdup_mol_liq holdup_mol_vap k_value contained + syn keyword spupTypes length length_delta length_short liqfraction contained + syn keyword spupTypes liqmassfraction mass massfraction molefraction contained + syn keyword spupTypes molweight moment_inertia negative notype percent contained + syn keyword spupTypes positive pressure press_diff press_drop press_rise contained + syn keyword spupTypes ratio reaction reaction_mass rotation surf_tens contained + syn keyword spupTypes temperature temperature_abs temp_diff temp_drop contained + syn keyword spupTypes temp_rise time vapfraction vapmassfraction contained + syn keyword spupTypes velocity visc_liq visc_vap volume zmom_rate contained + syn keyword spupTypes seg_rate smom_rate tmom_rate zmom_mass seg_mass contained + syn keyword spupTypes smom_mass tmom_mass zmom_holdup seg_holdup contained + syn keyword spupTypes smom_holdup tmom_holdup contained +endif + +" stream types +syn keyword spupStreams mainstream vapour liquid contained + +" "conditional" keywords +syn keyword spupConditional IF THEN ELSE ENDIF contained +" Operators, symbols etc. +syn keyword spupOperator AND OR NOT contained +syn match spupSymbol "[,\-+=:;*/\"<>@%()]" contained +syn match spupSpecial "[&\$?]" contained +" Surprisingly, Speedup allows no unary + instead of the - +syn match spupError "[(=+\-*/]\s*+\d\+\([ed][+-]\=\d\+\)\=\>"lc=1 contained +syn match spupError "[(=+\-*/]\s*+\d\+\.\([ed][+-]\=\d\+\)\=\>"lc=1 contained +syn match spupError "[(=+\-*/]\s*+\d*\.\d\+\([ed][+-]\=\d\+\)\=\>"lc=1 contained +" String +syn region spupString start=+"+ end=+"+ oneline contained +syn region spupString start=+'+ end=+'+ oneline contained +" Identifier +syn match spupIdentifier "\<[a-z][a-z0-9_]*\>" contained +" Textprocessor directives +syn match spupTextprocGeneric "?[a-z][a-z0-9_]*\>" contained +syn region spupTextprocError matchgroup=spupTextprocGeneric start="?ERROR" end="?END"he=s-1 contained +" Number, without decimal point +syn match spupNumber "-\=\d\+\([ed][+-]\=\d\+\)\=" contained +" Number, allows 1. before exponent +syn match spupNumber "-\=\d\+\.\([ed][+-]\=\d\+\)\=" contained +" Number allows .1 before exponent +syn match spupNumber "-\=\d*\.\d\+\([ed][+-]\=\d\+\)\=" contained +" Help subsections +syn region spupHelp start="^HELP"hs=e+1 end="^\$ENDHELP"he=s-1 contained +" Fortran code +syn region spupCode start="^CODE"hs=e+1 end="^\$ENDCODE"he=s-1 contained +" oneline comments +if oneline_comments > 3 + oneline_comments = 2 " default +endif +if oneline_comments == 1 + syn match spupComment "#[^#]*#\=" +elseif oneline_comments == 2 + syn match spupError "#.*$" + syn match spupComment "#[^#]*" nextgroup=spupError +elseif oneline_comments == 3 + syn match spupComment "#[^#]*" + syn match spupError "#[^#]*#.*" +endif +" multiline comments +syn match spupOpenBrace "{" contained +syn match spupError "}" +syn region spupComment matchgroup=spupComment2 start="{" end="}" keepend contains=spupOpenBrace + +syn cluster spupOrdinary contains=spupNumber,spupIdentifier,spupSymbol +syn cluster spupOrdinary add=spupError,spupString,spupComment +syn cluster spupTextproc contains=spupTextprocGeneric,spupTextprocError + +" define syncronizing; especially OPERATION sections can become very large +syn sync clear +syn sync minlines=100 +syn sync maxlines=500 + +syn sync match spupSyncOperation grouphere spupOperation "^OPERATION" +syn sync match spupSyncCdi grouphere spupCdi "^CDI" +syn sync match spupSyncConditions grouphere spupConditions "^CONDITIONS" +syn sync match spupSyncDeclare grouphere spupDeclare "^DECLARE" +syn sync match spupSyncEstimation grouphere spupEstimation "^ESTIMATION" +syn sync match spupSyncExternal grouphere spupExternal "^EXTERNAL" +syn sync match spupSyncFlowsheet grouphere spupFlowsheet "^FLOWSHEET" +syn sync match spupSyncFunction grouphere spupFunction "^FUNCTION" +syn sync match spupSyncGlobal grouphere spupGlobal "^GLOBAL" +syn sync match spupSyncHomotopy grouphere spupHomotopy "^HOMOTOPY" +syn sync match spupSyncMacro grouphere spupMacro "^MACRO" +syn sync match spupSyncModel grouphere spupModel "^MODEL" +syn sync match spupSyncOperation grouphere spupOperation "^OPERATION" +syn sync match spupSyncOptions grouphere spupOptions "^OPTIONS" +syn sync match spupSyncProcedure grouphere spupProcedure "^PROCEDURE" +syn sync match spupSyncProfiles grouphere spupProfiles "^PROFILES" +syn sync match spupSyncReport grouphere spupReport "^REPORT" +syn sync match spupSyncTitle grouphere spupTitle "^TITLE" +syn sync match spupSyncUnit grouphere spupUnit "^UNIT" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link spupCdi spupSection +hi def link spupConditions spupSection +hi def link spupDeclare spupSection +hi def link spupEstimation spupSection +hi def link spupExternal spupSection +hi def link spupFlowsheet spupSection +hi def link spupFunction spupSection +hi def link spupGlobal spupSection +hi def link spupHomotopy spupSection +hi def link spupMacro spupSection +hi def link spupModel spupSection +hi def link spupOperation spupSection +hi def link spupOptions spupSection +hi def link spupProcedure spupSection +hi def link spupProfiles spupSection +hi def link spupReport spupSection +hi def link spupTitle spupConstant " this is correct, truly ;) +hi def link spupUnit spupSection + +hi def link spupCdiSubs spupSubs +hi def link spupConditionsSubs spupSubs +hi def link spupDeclareSubs spupSubs +hi def link spupEstimationSubs spupSubs +hi def link spupExternalSubs spupSubs +hi def link spupFlowsheetSubs spupSubs +hi def link spupFunctionSubs spupSubs +hi def link spupHomotopySubs spupSubs +hi def link spupMacroSubs spupSubs +hi def link spupModelSubs spupSubs +hi def link spupOperationSubs spupSubs +hi def link spupOptionsSubs spupSubs +hi def link spupProcedureSubs spupSubs +hi def link spupReportSubs spupSubs +hi def link spupUnitSubs spupSubs + +hi def link spupCode Normal +hi def link spupComment Comment +hi def link spupComment2 spupComment +hi def link spupConditional Statement +hi def link spupConstant Constant +hi def link spupError Error +hi def link spupHelp Normal +hi def link spupIdentifier Identifier +hi def link spupNumber Constant +hi def link spupOperator Special +hi def link spupOpenBrace spupError +hi def link spupSection Statement +hi def link spupSpecial spupTextprocGeneric +hi def link spupStreams Type +hi def link spupString Constant +hi def link spupSubs Statement +hi def link spupSymbol Special +hi def link spupTextprocError Normal +hi def link spupTextprocGeneric PreProc +hi def link spupTypes Type + + +let b:current_syntax = "spup" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim:ts=8 + +endif diff --git a/syntax/spyce.vim b/syntax/spyce.vim new file mode 100644 index 0000000..e6e1d4f --- /dev/null +++ b/syntax/spyce.vim @@ -0,0 +1,108 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SPYCE +" Maintainer: Rimon Barr +" URL: http://spyce.sourceforge.net +" Last Change: 2009 Nov 11 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" we define it here so that included files can test for it +if !exists("main_syntax") + let main_syntax='spyce' +endif + +" Read the HTML syntax to start with +let b:did_indent = 1 " don't perform HTML indentation! +let html_no_rendering = 1 " do not render ,, etc... +runtime! syntax/html.vim +unlet b:current_syntax +syntax spell default " added by Bram + +" include python +syn include @Python :p:h/python.vim +syn include @Html :p:h/html.vim + +" spyce definitions +syn keyword spyceDirectiveKeyword include compact module import contained +syn keyword spyceDirectiveArg name names file contained +syn region spyceDirectiveString start=+"+ end=+"+ contained +syn match spyceDirectiveValue "=[\t ]*[^'", \t>][^, \t>]*"hs=s+1 contained + +syn match spyceBeginErrorS ,\[\[, +syn match spyceBeginErrorA ,<%, +syn cluster spyceBeginError contains=spyceBeginErrorS,spyceBeginErrorA +syn match spyceEndErrorS ,\]\], +syn match spyceEndErrorA ,%>, +syn cluster spyceEndError contains=spyceEndErrorS,spyceEndErrorA + +syn match spyceEscBeginS ,\\\[\[, +syn match spyceEscBeginA ,\\<%, +syn cluster spyceEscBegin contains=spyceEscBeginS,spyceEscBeginA +syn match spyceEscEndS ,\\\]\], +syn match spyceEscEndA ,\\%>, +syn cluster spyceEscEnd contains=spyceEscEndS,spyceEscEndA +syn match spyceEscEndCommentS ,--\\\]\], +syn match spyceEscEndCommentA ,--\\%>, +syn cluster spyceEscEndComment contains=spyceEscEndCommentS,spyceEscEndCommentA + +syn region spyceStmtS matchgroup=spyceStmtDelim start=,\[\[, end=,\]\], contains=@Python,spyceLambdaS,spyceLambdaA,spyceBeginError keepend +syn region spyceStmtA matchgroup=spyceStmtDelim start=,<%, end=,%>, contains=@Python,spyceLambdaS,spyceLambdaA,spyceBeginError keepend +syn region spyceChunkS matchgroup=spyceChunkDelim start=,\[\[\\, end=,\]\], contains=@Python,spyceLambdaS,spyceLambdaA,spyceBeginError keepend +syn region spyceChunkA matchgroup=spyceChunkDelim start=,<%\\, end=,%>, contains=@Python,spyceLambdaS,spyceLambdaA,spyceBeginError keepend +syn region spyceEvalS matchgroup=spyceEvalDelim start=,\[\[=, end=,\]\], contains=@Python,spyceLambdaS,spyceLambdaA,spyceBeginError keepend +syn region spyceEvalA matchgroup=spyceEvalDelim start=,<%=, end=,%>, contains=@Python,spyceLambdaS,spyceLambdaA,spyceBeginError keepend +syn region spyceDirectiveS matchgroup=spyceDelim start=,\[\[\., end=,\]\], contains=spyceBeginError,spyceDirectiveKeyword,spyceDirectiveArg,spyceDirectiveValue,spyceDirectiveString keepend +syn region spyceDirectiveA matchgroup=spyceDelim start=,<%@, end=,%>, contains=spyceBeginError,spyceDirectiveKeyword,spyceDirectiveArg,spyceDirectiveValue,spyceDirectiveString keepend +syn region spyceCommentS matchgroup=spyceCommentDelim start=,\[\[--, end=,--\]\], +syn region spyceCommentA matchgroup=spyceCommentDelim start=,<%--, end=,--%>, +syn region spyceLambdaS matchgroup=spyceLambdaDelim start=,\[\[spy!\?, end=,\]\], contains=@Html,@spyce extend +syn region spyceLambdaA matchgroup=spyceLambdaDelim start=,<%spy!\?, end=,%>, contains=@Html,@spyce extend + +syn cluster spyce contains=spyceStmtS,spyceStmtA,spyceChunkS,spyceChunkA,spyceEvalS,spyceEvalA,spyceCommentS,spyceCommentA,spyceDirectiveS,spyceDirectiveA + +syn cluster htmlPreproc contains=@spyce + +hi link spyceDirectiveKeyword Special +hi link spyceDirectiveArg Type +hi link spyceDirectiveString String +hi link spyceDirectiveValue String + +hi link spyceDelim Special +hi link spyceStmtDelim spyceDelim +hi link spyceChunkDelim spyceDelim +hi link spyceEvalDelim spyceDelim +hi link spyceLambdaDelim spyceDelim +hi link spyceCommentDelim Comment + +hi link spyceBeginErrorS Error +hi link spyceBeginErrorA Error +hi link spyceEndErrorS Error +hi link spyceEndErrorA Error + +hi link spyceStmtS spyce +hi link spyceStmtA spyce +hi link spyceChunkS spyce +hi link spyceChunkA spyce +hi link spyceEvalS spyce +hi link spyceEvalA spyce +hi link spyceDirectiveS spyce +hi link spyceDirectiveA spyce +hi link spyceCommentS Comment +hi link spyceCommentA Comment +hi link spyceLambdaS Normal +hi link spyceLambdaA Normal + +hi link spyce Statement + +let b:current_syntax = "spyce" +if main_syntax == 'spyce' + unlet main_syntax +endif + + +endif diff --git a/syntax/sql.vim b/syntax/sql.vim new file mode 100644 index 0000000..0977084 --- /dev/null +++ b/syntax/sql.vim @@ -0,0 +1,40 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file loader +" Language: SQL +" Maintainer: David Fishburn +" Last Change: Thu Sep 15 2005 10:30:02 AM +" Version: 1.0 + +" Description: Checks for a: +" buffer local variable, +" global variable, +" If the above exist, it will source the type specified. +" If none exist, it will source the default sql.vim file. +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Default to the standard Vim distribution file +let filename = 'sqloracle' + +" Check for overrides. Buffer variables have the highest priority. +if exists("b:sql_type_override") + " Check the runtimepath to see if the file exists + if globpath(&runtimepath, 'syntax/'.b:sql_type_override.'.vim') != '' + let filename = b:sql_type_override + endif +elseif exists("g:sql_type_default") + if globpath(&runtimepath, 'syntax/'.g:sql_type_default.'.vim') != '' + let filename = g:sql_type_default + endif +endif + +" Source the appropriate file +exec 'runtime syntax/'.filename.'.vim' + +" vim:sw=4: + +endif diff --git a/syntax/sqlanywhere.vim b/syntax/sqlanywhere.vim new file mode 100644 index 0000000..f380906 --- /dev/null +++ b/syntax/sqlanywhere.vim @@ -0,0 +1,909 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SQL, Adaptive Server Anywhere +" Maintainer: David Fishburn +" Last Change: 2013 May 13 +" Version: 16.0.0 + +" Description: Updated to Adaptive Server Anywhere 16.0.0 +" Updated to Adaptive Server Anywhere 12.0.1 (including spatial data) +" Updated to Adaptive Server Anywhere 11.0.1 +" Updated to Adaptive Server Anywhere 10.0.1 +" Updated to Adaptive Server Anywhere 9.0.2 +" Updated to Adaptive Server Anywhere 9.0.1 +" Updated to Adaptive Server Anywhere 9.0.0 +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" The SQL reserved words, defined as keywords. + +syn keyword sqlSpecial false null true + +" common functions +syn keyword sqlFunction abs argn avg bintohex bintostr +syn keyword sqlFunction byte_length byte_substr char_length +syn keyword sqlFunction compare count count_big datalength date +syn keyword sqlFunction date_format dateadd datediff datename +syn keyword sqlFunction datepart day dayname days debug_eng +syn keyword sqlFunction dense_rank density dialect difference +syn keyword sqlFunction dow estimate estimate_source evaluate +syn keyword sqlFunction experience_estimate explanation +syn keyword sqlFunction get_identity graphical_plan +syn keyword sqlFunction graphical_ulplan greater grouping +syn keyword sqlFunction hextobin hextoint hour hours identity +syn keyword sqlFunction ifnull index_estimate inttohex isdate +syn keyword sqlFunction isencrypted isnull isnumeric +syn keyword sqlFunction lang_message length lesser like_end +syn keyword sqlFunction like_start list long_ulplan lookup max +syn keyword sqlFunction min minute minutes month monthname +syn keyword sqlFunction months newid now nullif number +syn keyword sqlFunction percent_rank plan quarter rand rank +syn keyword sqlFunction regexp_compile regexp_compile_patindex +syn keyword sqlFunction remainder rewrite rowid second seconds +syn keyword sqlFunction short_ulplan similar sortkey soundex +syn keyword sqlFunction stddev stack_trace str string strtobin strtouuid stuff +syn keyword sqlFunction subpartition substr substring sum switchoffset sysdatetimeoffset +syn keyword sqlFunction textptr todate todatetimeoffset today totimestamp traceback transactsql +syn keyword sqlFunction ts_index_statistics ts_table_statistics +syn keyword sqlFunction tsequal ulplan user_id user_name utc_now +syn keyword sqlFunction uuidtostr varexists variance watcomsql +syn keyword sqlFunction weeks wsql_state year years ymd + +" 9.0.1 functions +syn keyword sqlFunction acos asin atan atn2 cast ceiling convert cos cot +syn keyword sqlFunction char_length coalesce dateformat datetime degrees exp +syn keyword sqlFunction floor getdate insertstr +syn keyword sqlFunction log log10 lower mod pi power +syn keyword sqlFunction property radians replicate round sign sin +syn keyword sqlFunction sqldialect tan truncate truncnum +syn keyword sqlFunction base64_encode base64_decode +syn keyword sqlFunction hash compress decompress encrypt decrypt + +" 11.0.1 functions +syn keyword sqlFunction connection_extended_property text_handle_vector_match +syn keyword sqlFunction read_client_file write_client_file + +" 12.0.1 functions +syn keyword sqlFunction http_response_header + +" string functions +syn keyword sqlFunction ascii char left ltrim repeat +syn keyword sqlFunction space right rtrim trim lcase ucase +syn keyword sqlFunction locate charindex patindex replace +syn keyword sqlFunction errormsg csconvert + +" property functions +syn keyword sqlFunction db_id db_name property_name +syn keyword sqlFunction property_description property_number +syn keyword sqlFunction next_connection next_database property +syn keyword sqlFunction connection_property db_property db_extended_property +syn keyword sqlFunction event_parmeter event_condition event_condition_name + +" sa_ procedures +syn keyword sqlFunction sa_add_index_consultant_analysis +syn keyword sqlFunction sa_add_workload_query +syn keyword sqlFunction sa_app_deregister +syn keyword sqlFunction sa_app_get_infoStr +syn keyword sqlFunction sa_app_get_status +syn keyword sqlFunction sa_app_register +syn keyword sqlFunction sa_app_registration_unlock +syn keyword sqlFunction sa_app_set_infoStr +syn keyword sqlFunction sa_audit_string +syn keyword sqlFunction sa_check_commit +syn keyword sqlFunction sa_checkpoint_execute +syn keyword sqlFunction sa_conn_activity +syn keyword sqlFunction sa_conn_compression_info +syn keyword sqlFunction sa_conn_deregister +syn keyword sqlFunction sa_conn_info +syn keyword sqlFunction sa_conn_properties +syn keyword sqlFunction sa_conn_properties_by_conn +syn keyword sqlFunction sa_conn_properties_by_name +syn keyword sqlFunction sa_conn_register +syn keyword sqlFunction sa_conn_set_status +syn keyword sqlFunction sa_create_analysis_from_query +syn keyword sqlFunction sa_db_info +syn keyword sqlFunction sa_db_properties +syn keyword sqlFunction sa_disable_auditing_type +syn keyword sqlFunction sa_disable_index +syn keyword sqlFunction sa_disk_free_space +syn keyword sqlFunction sa_enable_auditing_type +syn keyword sqlFunction sa_enable_index +syn keyword sqlFunction sa_end_forward_to +syn keyword sqlFunction sa_eng_properties +syn keyword sqlFunction sa_event_schedules +syn keyword sqlFunction sa_exec_script +syn keyword sqlFunction sa_flush_cache +syn keyword sqlFunction sa_flush_statistics +syn keyword sqlFunction sa_forward_to +syn keyword sqlFunction sa_get_dtt +syn keyword sqlFunction sa_get_histogram +syn keyword sqlFunction sa_get_request_profile +syn keyword sqlFunction sa_get_request_profile_sub +syn keyword sqlFunction sa_get_request_times +syn keyword sqlFunction sa_get_server_messages +syn keyword sqlFunction sa_get_simulated_scale_factors +syn keyword sqlFunction sa_get_workload_capture_status +syn keyword sqlFunction sa_index_density +syn keyword sqlFunction sa_index_levels +syn keyword sqlFunction sa_index_statistics +syn keyword sqlFunction sa_internal_alter_index_ability +syn keyword sqlFunction sa_internal_create_analysis_from_query +syn keyword sqlFunction sa_internal_disk_free_space +syn keyword sqlFunction sa_internal_get_dtt +syn keyword sqlFunction sa_internal_get_histogram +syn keyword sqlFunction sa_internal_get_request_times +syn keyword sqlFunction sa_internal_get_simulated_scale_factors +syn keyword sqlFunction sa_internal_get_workload_capture_status +syn keyword sqlFunction sa_internal_index_density +syn keyword sqlFunction sa_internal_index_levels +syn keyword sqlFunction sa_internal_index_statistics +syn keyword sqlFunction sa_internal_java_loaded_classes +syn keyword sqlFunction sa_internal_locks +syn keyword sqlFunction sa_internal_pause_workload_capture +syn keyword sqlFunction sa_internal_procedure_profile +syn keyword sqlFunction sa_internal_procedure_profile_summary +syn keyword sqlFunction sa_internal_read_backup_history +syn keyword sqlFunction sa_internal_recommend_indexes +syn keyword sqlFunction sa_internal_reset_identity +syn keyword sqlFunction sa_internal_resume_workload_capture +syn keyword sqlFunction sa_internal_start_workload_capture +syn keyword sqlFunction sa_internal_stop_index_consultant +syn keyword sqlFunction sa_internal_stop_workload_capture +syn keyword sqlFunction sa_internal_table_fragmentation +syn keyword sqlFunction sa_internal_table_page_usage +syn keyword sqlFunction sa_internal_table_stats +syn keyword sqlFunction sa_internal_virtual_sysindex +syn keyword sqlFunction sa_internal_virtual_sysixcol +syn keyword sqlFunction sa_java_loaded_classes +syn keyword sqlFunction sa_jdk_version +syn keyword sqlFunction sa_locks +syn keyword sqlFunction sa_make_object +syn keyword sqlFunction sa_pause_workload_capture +syn keyword sqlFunction sa_proc_debug_attach_to_connection +syn keyword sqlFunction sa_proc_debug_connect +syn keyword sqlFunction sa_proc_debug_detach_from_connection +syn keyword sqlFunction sa_proc_debug_disconnect +syn keyword sqlFunction sa_proc_debug_get_connection_name +syn keyword sqlFunction sa_proc_debug_release_connection +syn keyword sqlFunction sa_proc_debug_request +syn keyword sqlFunction sa_proc_debug_version +syn keyword sqlFunction sa_proc_debug_wait_for_connection +syn keyword sqlFunction sa_procedure_profile +syn keyword sqlFunction sa_procedure_profile_summary +syn keyword sqlFunction sa_read_backup_history +syn keyword sqlFunction sa_recommend_indexes +syn keyword sqlFunction sa_recompile_views +syn keyword sqlFunction sa_remove_index_consultant_analysis +syn keyword sqlFunction sa_remove_index_consultant_workload +syn keyword sqlFunction sa_reset_identity +syn keyword sqlFunction sa_resume_workload_capture +syn keyword sqlFunction sa_server_option +syn keyword sqlFunction sa_set_simulated_scale_factor +syn keyword sqlFunction sa_setremoteuser +syn keyword sqlFunction sa_setsubscription +syn keyword sqlFunction sa_start_recording_commits +syn keyword sqlFunction sa_start_workload_capture +syn keyword sqlFunction sa_statement_text +syn keyword sqlFunction sa_stop_index_consultant +syn keyword sqlFunction sa_stop_recording_commits +syn keyword sqlFunction sa_stop_workload_capture +syn keyword sqlFunction sa_sync +syn keyword sqlFunction sa_sync_sub +syn keyword sqlFunction sa_table_fragmentation +syn keyword sqlFunction sa_table_page_usage +syn keyword sqlFunction sa_table_stats +syn keyword sqlFunction sa_update_index_consultant_workload +syn keyword sqlFunction sa_validate +syn keyword sqlFunction sa_virtual_sysindex +syn keyword sqlFunction sa_virtual_sysixcol + +" sp_ procedures +syn keyword sqlFunction sp_addalias +syn keyword sqlFunction sp_addauditrecord +syn keyword sqlFunction sp_adddumpdevice +syn keyword sqlFunction sp_addgroup +syn keyword sqlFunction sp_addlanguage +syn keyword sqlFunction sp_addlogin +syn keyword sqlFunction sp_addmessage +syn keyword sqlFunction sp_addremotelogin +syn keyword sqlFunction sp_addsegment +syn keyword sqlFunction sp_addserver +syn keyword sqlFunction sp_addthreshold +syn keyword sqlFunction sp_addtype +syn keyword sqlFunction sp_adduser +syn keyword sqlFunction sp_auditdatabase +syn keyword sqlFunction sp_auditlogin +syn keyword sqlFunction sp_auditobject +syn keyword sqlFunction sp_auditoption +syn keyword sqlFunction sp_auditsproc +syn keyword sqlFunction sp_bindefault +syn keyword sqlFunction sp_bindmsg +syn keyword sqlFunction sp_bindrule +syn keyword sqlFunction sp_changedbowner +syn keyword sqlFunction sp_changegroup +syn keyword sqlFunction sp_checknames +syn keyword sqlFunction sp_checkperms +syn keyword sqlFunction sp_checkreswords +syn keyword sqlFunction sp_clearstats +syn keyword sqlFunction sp_column_privileges +syn keyword sqlFunction sp_columns +syn keyword sqlFunction sp_commonkey +syn keyword sqlFunction sp_configure +syn keyword sqlFunction sp_cursorinfo +syn keyword sqlFunction sp_databases +syn keyword sqlFunction sp_datatype_info +syn keyword sqlFunction sp_dboption +syn keyword sqlFunction sp_dbremap +syn keyword sqlFunction sp_depends +syn keyword sqlFunction sp_diskdefault +syn keyword sqlFunction sp_displaylogin +syn keyword sqlFunction sp_dropalias +syn keyword sqlFunction sp_dropdevice +syn keyword sqlFunction sp_dropgroup +syn keyword sqlFunction sp_dropkey +syn keyword sqlFunction sp_droplanguage +syn keyword sqlFunction sp_droplogin +syn keyword sqlFunction sp_dropmessage +syn keyword sqlFunction sp_dropremotelogin +syn keyword sqlFunction sp_dropsegment +syn keyword sqlFunction sp_dropserver +syn keyword sqlFunction sp_dropthreshold +syn keyword sqlFunction sp_droptype +syn keyword sqlFunction sp_dropuser +syn keyword sqlFunction sp_estspace +syn keyword sqlFunction sp_extendsegment +syn keyword sqlFunction sp_fkeys +syn keyword sqlFunction sp_foreignkey +syn keyword sqlFunction sp_getmessage +syn keyword sqlFunction sp_help +syn keyword sqlFunction sp_helpconstraint +syn keyword sqlFunction sp_helpdb +syn keyword sqlFunction sp_helpdevice +syn keyword sqlFunction sp_helpgroup +syn keyword sqlFunction sp_helpindex +syn keyword sqlFunction sp_helpjoins +syn keyword sqlFunction sp_helpkey +syn keyword sqlFunction sp_helplanguage +syn keyword sqlFunction sp_helplog +syn keyword sqlFunction sp_helpprotect +syn keyword sqlFunction sp_helpremotelogin +syn keyword sqlFunction sp_helpsegment +syn keyword sqlFunction sp_helpserver +syn keyword sqlFunction sp_helpsort +syn keyword sqlFunction sp_helptext +syn keyword sqlFunction sp_helpthreshold +syn keyword sqlFunction sp_helpuser +syn keyword sqlFunction sp_indsuspect +syn keyword sqlFunction sp_lock +syn keyword sqlFunction sp_locklogin +syn keyword sqlFunction sp_logdevice +syn keyword sqlFunction sp_login_environment +syn keyword sqlFunction sp_modifylogin +syn keyword sqlFunction sp_modifythreshold +syn keyword sqlFunction sp_monitor +syn keyword sqlFunction sp_password +syn keyword sqlFunction sp_pkeys +syn keyword sqlFunction sp_placeobject +syn keyword sqlFunction sp_primarykey +syn keyword sqlFunction sp_procxmode +syn keyword sqlFunction sp_recompile +syn keyword sqlFunction sp_remap +syn keyword sqlFunction sp_remote_columns +syn keyword sqlFunction sp_remote_exported_keys +syn keyword sqlFunction sp_remote_imported_keys +syn keyword sqlFunction sp_remote_pcols +syn keyword sqlFunction sp_remote_primary_keys +syn keyword sqlFunction sp_remote_procedures +syn keyword sqlFunction sp_remote_tables +syn keyword sqlFunction sp_remoteoption +syn keyword sqlFunction sp_rename +syn keyword sqlFunction sp_renamedb +syn keyword sqlFunction sp_reportstats +syn keyword sqlFunction sp_reset_tsql_environment +syn keyword sqlFunction sp_role +syn keyword sqlFunction sp_server_info +syn keyword sqlFunction sp_servercaps +syn keyword sqlFunction sp_serverinfo +syn keyword sqlFunction sp_serveroption +syn keyword sqlFunction sp_setlangalias +syn keyword sqlFunction sp_setreplicate +syn keyword sqlFunction sp_setrepproc +syn keyword sqlFunction sp_setreptable +syn keyword sqlFunction sp_spaceused +syn keyword sqlFunction sp_special_columns +syn keyword sqlFunction sp_sproc_columns +syn keyword sqlFunction sp_statistics +syn keyword sqlFunction sp_stored_procedures +syn keyword sqlFunction sp_syntax +syn keyword sqlFunction sp_table_privileges +syn keyword sqlFunction sp_tables +syn keyword sqlFunction sp_tsql_environment +syn keyword sqlFunction sp_tsql_feature_not_supported +syn keyword sqlFunction sp_unbindefault +syn keyword sqlFunction sp_unbindmsg +syn keyword sqlFunction sp_unbindrule +syn keyword sqlFunction sp_volchanged +syn keyword sqlFunction sp_who +syn keyword sqlFunction xp_scanf +syn keyword sqlFunction xp_sprintf + +" server functions +syn keyword sqlFunction col_length +syn keyword sqlFunction col_name +syn keyword sqlFunction index_col +syn keyword sqlFunction object_id +syn keyword sqlFunction object_name +syn keyword sqlFunction proc_role +syn keyword sqlFunction show_role +syn keyword sqlFunction xp_cmdshell +syn keyword sqlFunction xp_msver +syn keyword sqlFunction xp_read_file +syn keyword sqlFunction xp_real_cmdshell +syn keyword sqlFunction xp_real_read_file +syn keyword sqlFunction xp_real_sendmail +syn keyword sqlFunction xp_real_startmail +syn keyword sqlFunction xp_real_startsmtp +syn keyword sqlFunction xp_real_stopmail +syn keyword sqlFunction xp_real_stopsmtp +syn keyword sqlFunction xp_real_write_file +syn keyword sqlFunction xp_scanf +syn keyword sqlFunction xp_sendmail +syn keyword sqlFunction xp_sprintf +syn keyword sqlFunction xp_startmail +syn keyword sqlFunction xp_startsmtp +syn keyword sqlFunction xp_stopmail +syn keyword sqlFunction xp_stopsmtp +syn keyword sqlFunction xp_write_file + +" http functions +syn keyword sqlFunction http_header http_variable +syn keyword sqlFunction next_http_header next_http_response_header next_http_variable +syn keyword sqlFunction sa_set_http_header sa_set_http_option +syn keyword sqlFunction sa_http_variable_info sa_http_header_info + +" http functions 9.0.1 +syn keyword sqlFunction http_encode http_decode +syn keyword sqlFunction html_encode html_decode + +" XML function support +syn keyword sqlFunction openxml xmlelement xmlforest xmlgen xmlconcat xmlagg +syn keyword sqlFunction xmlattributes + +" Spatial Compatibility Functions +syn keyword sqlFunction ST_BdMPolyFromText +syn keyword sqlFunction ST_BdMPolyFromWKB +syn keyword sqlFunction ST_BdPolyFromText +syn keyword sqlFunction ST_BdPolyFromWKB +syn keyword sqlFunction ST_CPolyFromText +syn keyword sqlFunction ST_CPolyFromWKB +syn keyword sqlFunction ST_CircularFromTxt +syn keyword sqlFunction ST_CircularFromWKB +syn keyword sqlFunction ST_CompoundFromTxt +syn keyword sqlFunction ST_CompoundFromWKB +syn keyword sqlFunction ST_GeomCollFromTxt +syn keyword sqlFunction ST_GeomCollFromWKB +syn keyword sqlFunction ST_GeomFromText +syn keyword sqlFunction ST_GeomFromWKB +syn keyword sqlFunction ST_LineFromText +syn keyword sqlFunction ST_LineFromWKB +syn keyword sqlFunction ST_MCurveFromText +syn keyword sqlFunction ST_MCurveFromWKB +syn keyword sqlFunction ST_MLineFromText +syn keyword sqlFunction ST_MLineFromWKB +syn keyword sqlFunction ST_MPointFromText +syn keyword sqlFunction ST_MPointFromWKB +syn keyword sqlFunction ST_MPolyFromText +syn keyword sqlFunction ST_MPolyFromWKB +syn keyword sqlFunction ST_MSurfaceFromTxt +syn keyword sqlFunction ST_MSurfaceFromWKB +syn keyword sqlFunction ST_OrderingEquals +syn keyword sqlFunction ST_PointFromText +syn keyword sqlFunction ST_PointFromWKB +syn keyword sqlFunction ST_PolyFromText +syn keyword sqlFunction ST_PolyFromWKB +" Spatial Structural Methods +syn keyword sqlFunction ST_CoordDim +syn keyword sqlFunction ST_CurveN +syn keyword sqlFunction ST_Dimension +syn keyword sqlFunction ST_EndPoint +syn keyword sqlFunction ST_ExteriorRing +syn keyword sqlFunction ST_GeometryN +syn keyword sqlFunction ST_GeometryType +syn keyword sqlFunction ST_InteriorRingN +syn keyword sqlFunction ST_Is3D +syn keyword sqlFunction ST_IsClosed +syn keyword sqlFunction ST_IsEmpty +syn keyword sqlFunction ST_IsMeasured +syn keyword sqlFunction ST_IsRing +syn keyword sqlFunction ST_IsSimple +syn keyword sqlFunction ST_IsValid +syn keyword sqlFunction ST_NumCurves +syn keyword sqlFunction ST_NumGeometries +syn keyword sqlFunction ST_NumInteriorRing +syn keyword sqlFunction ST_NumPoints +syn keyword sqlFunction ST_PointN +syn keyword sqlFunction ST_StartPoint +"Spatial Computation +syn keyword sqlFunction ST_Length +syn keyword sqlFunction ST_Area +syn keyword sqlFunction ST_Centroid +syn keyword sqlFunction ST_Area +syn keyword sqlFunction ST_Centroid +syn keyword sqlFunction ST_IsWorld +syn keyword sqlFunction ST_Perimeter +syn keyword sqlFunction ST_PointOnSurface +syn keyword sqlFunction ST_Distance +" Spatial Input/Output +syn keyword sqlFunction ST_AsBinary +syn keyword sqlFunction ST_AsGML +syn keyword sqlFunction ST_AsGeoJSON +syn keyword sqlFunction ST_AsSVG +syn keyword sqlFunction ST_AsSVGAggr +syn keyword sqlFunction ST_AsText +syn keyword sqlFunction ST_AsWKB +syn keyword sqlFunction ST_AsWKT +syn keyword sqlFunction ST_AsXML +syn keyword sqlFunction ST_GeomFromBinary +syn keyword sqlFunction ST_GeomFromShape +syn keyword sqlFunction ST_GeomFromText +syn keyword sqlFunction ST_GeomFromWKB +syn keyword sqlFunction ST_GeomFromWKT +syn keyword sqlFunction ST_GeomFromXML +" Spatial Cast Methods +syn keyword sqlFunction ST_CurvePolyToPoly +syn keyword sqlFunction ST_CurveToLine +syn keyword sqlFunction ST_ToCircular +syn keyword sqlFunction ST_ToCompound +syn keyword sqlFunction ST_ToCurve +syn keyword sqlFunction ST_ToCurvePoly +syn keyword sqlFunction ST_ToGeomColl +syn keyword sqlFunction ST_ToLineString +syn keyword sqlFunction ST_ToMultiCurve +syn keyword sqlFunction ST_ToMultiLine +syn keyword sqlFunction ST_ToMultiPoint +syn keyword sqlFunction ST_ToMultiPolygon +syn keyword sqlFunction ST_ToMultiSurface +syn keyword sqlFunction ST_ToPoint +syn keyword sqlFunction ST_ToPolygon +syn keyword sqlFunction ST_ToSurface + +" Array functions 16.x +syn keyword sqlFunction array array_agg array_max_cardinality trim_array +syn keyword sqlFunction error_line error_message error_procedure +syn keyword sqlFunction error_sqlcode error_sqlstate error_stack_trace + + +" keywords +syn keyword sqlKeyword absolute accent access account action active activate add address admin +syn keyword sqlKeyword aes_decrypt after aggregate algorithm allow_dup_row allow allowed alter +syn keyword sqlKeyword always and angular ansi_substring any as append apply +syn keyword sqlKeyword arbiter array asc ascii ase +syn keyword sqlKeyword assign at atan2 atomic attended +syn keyword sqlKeyword audit auditing authentication authorization axis +syn keyword sqlKeyword autoincrement autostop batch bcp before +syn keyword sqlKeyword between bit_and bit_length bit_or bit_substr bit_xor +syn keyword sqlKeyword blank blanks block +syn keyword sqlKeyword both bottom unbounded breaker bufferpool +syn keyword sqlKeyword build bulk by byte bytes cache calibrate calibration +syn keyword sqlKeyword cancel capability cardinality cascade cast +syn keyword sqlKeyword catalog catch ceil change changes char char_convert +syn keyword sqlKeyword check checkpointlog checksum class classes client cmp +syn keyword sqlKeyword cluster clustered collation +syn keyword sqlKeyword column columns +syn keyword sqlKeyword command comments committed commitid comparisons +syn keyword sqlKeyword compatible component compressed compute computes +syn keyword sqlKeyword concat configuration confirm conflict connection +syn keyword sqlKeyword console consolidate consolidated +syn keyword sqlKeyword constraint constraints content +syn keyword sqlKeyword convert coordinate coordinator copy count count_set_bits +syn keyword sqlKeyword crc createtime critical cross cube cume_dist +syn keyword sqlKeyword current cursor data data database +syn keyword sqlKeyword current_timestamp current_user cycle +syn keyword sqlKeyword databases datatype dba dbfile +syn keyword sqlKeyword dbspace dbspaces dbspacename debug decoupled +syn keyword sqlKeyword decrypted default defaults default_dbspace deferred +syn keyword sqlKeyword definer definition +syn keyword sqlKeyword delay deleting delimited dependencies desc +syn keyword sqlKeyword description deterministic directory +syn keyword sqlKeyword disable disabled disallow distinct disksandbox disk_sandbox +syn keyword sqlKeyword dn do domain download duplicate +syn keyword sqlKeyword dsetpass dttm dynamic each earth editproc effective ejb +syn keyword sqlKeyword elimination ellipsoid else elseif +syn keyword sqlKeyword email empty enable encapsulated encrypted encryption end +syn keyword sqlKeyword encoding endif engine environment erase error errors escape escapes event +syn keyword sqlKeyword event_parameter every exception exclude excluded exclusive exec +syn keyword sqlKeyword existing exists expanded expiry express exprtype extended_property +syn keyword sqlKeyword external externlogin factor failover false +syn keyword sqlKeyword fastfirstrow feature fieldproc file files filler +syn keyword sqlKeyword fillfactor final finish first first_keyword first_value +syn keyword sqlKeyword flattening +syn keyword sqlKeyword following force foreign format forjson forxml forxml_sep fp frame +syn keyword sqlKeyword free freepage french fresh full function +syn keyword sqlKeyword gb generic get_bit go global grid +syn keyword sqlKeyword group handler hash having header hexadecimal +syn keyword sqlKeyword hidden high history hg hng hold holdlock host +syn keyword sqlKeyword hours http_body http_session_timeout id identified identity ignore +syn keyword sqlKeyword ignore_dup_key ignore_dup_row immediate +syn keyword sqlKeyword in inactiv inactive inactivity included increment incremental +syn keyword sqlKeyword index index_enabled index_lparen indexonly info information +syn keyword sqlKeyword inheritance inline inner inout insensitive inserting +syn keyword sqlKeyword instead +syn keyword sqlKeyword internal intersection into introduced inverse invoker +syn keyword sqlKeyword iq is isolation +syn keyword sqlKeyword jar java java_location java_main_userid java_vm_options +syn keyword sqlKeyword jconnect jdk join json kb key keys keep language last +syn keyword sqlKeyword last_keyword last_value lateral latitude +syn keyword sqlKeyword ld ldap left len linear lf ln level like +syn keyword sqlKeyword limit local location log +syn keyword sqlKeyword logging logical login logscan long longitude low lru ls +syn keyword sqlKeyword main major manage manual mark master +syn keyword sqlKeyword match matched materialized max maxvalue maximum mb measure median membership +syn keyword sqlKeyword merge metadata methods migrate minimum minor minutes minvalue mirror +syn keyword sqlKeyword mode modify monitor move mru multiplex +syn keyword sqlKeyword name named namespaces national native natural new next nextval +syn keyword sqlKeyword ngram no noholdlock nolock nonclustered none normal not +syn keyword sqlKeyword notify null nullable_constant nulls +syn keyword sqlKeyword object objects oem_string of off offline offset olap +syn keyword sqlKeyword old on online only openstring operator +syn keyword sqlKeyword optimization optimizer option +syn keyword sqlKeyword or order ordinality organization others out outer over owner +syn keyword sqlKeyword package packetsize padding page pages +syn keyword sqlKeyword paglock parallel parameter parent part partial +syn keyword sqlKeyword partition partitions partner password path pctfree +syn keyword sqlKeyword permissions perms plan planar policy polygon populate port postfilter preceding +syn keyword sqlKeyword precisionprefetch prefilter prefix preserve preview previous +syn keyword sqlKeyword primary prior priority priqty private privilege privileges procedure profile profiling +syn keyword sqlKeyword property_is_cumulative property_is_numeric public publication publish publisher +syn keyword sqlKeyword quiesce quote quotes range readclientfile readcommitted reader readfile readonly +syn keyword sqlKeyword readpast readuncommitted readwrite rebuild +syn keyword sqlKeyword received recompile recover recursive references +syn keyword sqlKeyword referencing regex regexp regexp_substr relative relocate +syn keyword sqlKeyword rename repeatable repeatableread replicate replication +syn keyword sqlKeyword requests request_timeout required rereceive resend reserve reset +syn keyword sqlKeyword resizing resolve resource respect restart +syn keyword sqlKeyword restrict result retain retries +syn keyword sqlKeyword returns reverse right role roles +syn keyword sqlKeyword rollup root row row_number rowlock rows rowtype +syn keyword sqlKeyword sa_index_hash sa_internal_fk_verify sa_internal_termbreak +syn keyword sqlKeyword sa_order_preserving_hash sa_order_preserving_hash_big sa_order_preserving_hash_prefix +syn keyword sqlKeyword sa_file_free_pages sa_internal_type_from_catalog sa_internal_valid_hash +syn keyword sqlKeyword sa_internal_validate_value sa_json_element +syn keyword sqlKeyword scale schedule schema scope script scripted scroll search seconds secqty security +syn keyword sqlKeyword semi send sensitive sent sequence serializable +syn keyword sqlKeyword server severity session set_bit set_bits sets +syn keyword sqlKeyword shapefile share side simple since site size skip +syn keyword sqlKeyword snap snapshot soapheader soap_header +syn keyword sqlKeyword spatial split some sorted_data +syn keyword sqlKeyword sql sqlcode sqlid sqlflagger sqlstate sqrt square +syn keyword sqlKeyword stacker stale state statement statistics status stddev_pop stddev_samp +syn keyword sqlKeyword stemmer stogroup stoplist storage store +syn keyword sqlKeyword strip stripesizekb striping subpages subscribe subscription +syn keyword sqlKeyword subtransaction suser_id suser_name suspend synchronization +syn keyword sqlKeyword syntax_error table tables tablock +syn keyword sqlKeyword tablockx target tb temp template temporary term then ties +syn keyword sqlKeyword timezone timeout tls to to_char to_nchar tolerance top +syn keyword sqlKeyword trace traced_plan tracing +syn keyword sqlKeyword transfer transform transaction transactional treat tries +syn keyword sqlKeyword true try tsequal type tune uncommitted unconditionally +syn keyword sqlKeyword unenforced unicode unique unistr unit unknown unlimited unload +syn keyword sqlKeyword unpartition unquiesce updatetime updating updlock upgrade upload +syn keyword sqlKeyword upper usage use user +syn keyword sqlKeyword using utc utilities validproc +syn keyword sqlKeyword value values varchar variable +syn keyword sqlKeyword varying var_pop var_samp vcat verbosity +syn keyword sqlKeyword verify versions view virtual wait +syn keyword sqlKeyword warning wd web when where with with_auto +syn keyword sqlKeyword with_auto with_cube with_rollup without +syn keyword sqlKeyword with_lparen within word work workload write writefile +syn keyword sqlKeyword writeclientfile writer writers writeserver xlock +syn keyword sqlKeyword war xml zeros zone +" XML +syn keyword sqlKeyword raw auto elements explicit +" HTTP support +syn keyword sqlKeyword authorization secure url service next_soap_header +" HTTP 9.0.2 new procedure keywords +syn keyword sqlKeyword namespace certificate certificates clientport proxy trusted_certificates_file +" OLAP support 9.0.0 +syn keyword sqlKeyword covar_pop covar_samp corr regr_slope regr_intercept +syn keyword sqlKeyword regr_count regr_r2 regr_avgx regr_avgy +syn keyword sqlKeyword regr_sxx regr_syy regr_sxy + +" Alternate keywords +syn keyword sqlKeyword character dec options proc reference +syn keyword sqlKeyword subtrans tran syn keyword + +" Login Mode Options +syn keyword sqlKeywordLogin standard integrated kerberos LDAPUA +syn keyword sqlKeywordLogin cloudadmin mixed + +" Spatial Predicates +syn keyword sqlKeyword ST_Contains +syn keyword sqlKeyword ST_ContainsFilter +syn keyword sqlKeyword ST_CoveredBy +syn keyword sqlKeyword ST_CoveredByFilter +syn keyword sqlKeyword ST_Covers +syn keyword sqlKeyword ST_CoversFilter +syn keyword sqlKeyword ST_Crosses +syn keyword sqlKeyword ST_Disjoint +syn keyword sqlKeyword ST_Equals +syn keyword sqlKeyword ST_EqualsFilter +syn keyword sqlKeyword ST_Intersects +syn keyword sqlKeyword ST_IntersectsFilter +syn keyword sqlKeyword ST_IntersectsRect +syn keyword sqlKeyword ST_OrderingEquals +syn keyword sqlKeyword ST_Overlaps +syn keyword sqlKeyword ST_Relate +syn keyword sqlKeyword ST_Touches +syn keyword sqlKeyword ST_Within +syn keyword sqlKeyword ST_WithinFilter +" Spatial Set operations +syn keyword sqlKeyword ST_Affine +syn keyword sqlKeyword ST_Boundary +syn keyword sqlKeyword ST_Buffer +syn keyword sqlKeyword ST_ConvexHull +syn keyword sqlKeyword ST_ConvexHullAggr +syn keyword sqlKeyword ST_Difference +syn keyword sqlKeyword ST_Intersection +syn keyword sqlKeyword ST_IntersectionAggr +syn keyword sqlKeyword ST_SymDifference +syn keyword sqlKeyword ST_Union +syn keyword sqlKeyword ST_UnionAggr +" Spatial Bounds +syn keyword sqlKeyword ST_Envelope +syn keyword sqlKeyword ST_EnvelopeAggr +syn keyword sqlKeyword ST_Lat +syn keyword sqlKeyword ST_LatMax +syn keyword sqlKeyword ST_LatMin +syn keyword sqlKeyword ST_Long +syn keyword sqlKeyword ST_LongMax +syn keyword sqlKeyword ST_LongMin +syn keyword sqlKeyword ST_M +syn keyword sqlKeyword ST_MMax +syn keyword sqlKeyword ST_MMin +syn keyword sqlKeyword ST_Point +syn keyword sqlKeyword ST_X +syn keyword sqlKeyword ST_XMax +syn keyword sqlKeyword ST_XMin +syn keyword sqlKeyword ST_Y +syn keyword sqlKeyword ST_YMax +syn keyword sqlKeyword ST_YMin +syn keyword sqlKeyword ST_Z +syn keyword sqlKeyword ST_ZMax +syn keyword sqlKeyword ST_ZMin +" Spatial Collection Aggregates +syn keyword sqlKeyword ST_GeomCollectionAggr +syn keyword sqlKeyword ST_LineStringAggr +syn keyword sqlKeyword ST_MultiCurveAggr +syn keyword sqlKeyword ST_MultiLineStringAggr +syn keyword sqlKeyword ST_MultiPointAggr +syn keyword sqlKeyword ST_MultiPolygonAggr +syn keyword sqlKeyword ST_MultiSurfaceAggr +syn keyword sqlKeyword ST_Perimeter +syn keyword sqlKeyword ST_PointOnSurface +" Spatial SRS +syn keyword sqlKeyword ST_CompareWKT +syn keyword sqlKeyword ST_FormatWKT +syn keyword sqlKeyword ST_ParseWKT +syn keyword sqlKeyword ST_TransformGeom +syn keyword sqlKeyword ST_GeometryTypeFromBaseType +syn keyword sqlKeyword ST_SnapToGrid +syn keyword sqlKeyword ST_Transform +syn keyword sqlKeyword ST_SRID +syn keyword sqlKeyword ST_SRIDFromBaseType +syn keyword sqlKeyword ST_LoadConfigurationData +" Spatial Indexes +syn keyword sqlKeyword ST_LinearHash +syn keyword sqlKeyword ST_LinearUnHash + +syn keyword sqlOperator in any some all between exists +syn keyword sqlOperator like escape not is and or +syn keyword sqlOperator minus +syn keyword sqlOperator prior distinct unnest + +syn keyword sqlStatement allocate alter attach backup begin break call case catch +syn keyword sqlStatement checkpoint clear close comment commit configure connect +syn keyword sqlStatement continue create deallocate declare delete describe +syn keyword sqlStatement detach disconnect drop except execute exit explain fetch +syn keyword sqlStatement for forward from get goto grant help if include +syn keyword sqlStatement input insert install intersect leave load lock loop +syn keyword sqlStatement message open output parameters passthrough +syn keyword sqlStatement prepare print put raiserror read readtext refresh release +syn keyword sqlStatement remote remove reorganize resignal restore resume +syn keyword sqlStatement return revoke rollback save savepoint select +syn keyword sqlStatement set setuser signal start stop synchronize +syn keyword sqlStatement system trigger truncate try union unload update +syn keyword sqlStatement validate waitfor whenever while window writetext + + +syn keyword sqlType char nchar long varchar nvarchar text ntext uniqueidentifierstr xml +syn keyword sqlType bigint bit decimal double varbit +syn keyword sqlType float int integer numeric +syn keyword sqlType smallint tinyint real +syn keyword sqlType money smallmoney +syn keyword sqlType date datetime datetimeoffset smalldatetime time timestamp +syn keyword sqlType binary image varray varbinary uniqueidentifier +syn keyword sqlType unsigned +" Spatial types +syn keyword sqlType st_geometry st_point st_curve st_surface st_geomcollection +syn keyword sqlType st_linestring st_circularstring st_compoundcurve +syn keyword sqlType st_curvepolygon st_polygon +syn keyword sqlType st_multipoint st_multicurve st_multisurface +syn keyword sqlType st_multilinestring st_multipolygon + +syn keyword sqlOption Allow_nulls_by_default +syn keyword sqlOption Allow_read_client_file +syn keyword sqlOption Allow_snapshot_isolation +syn keyword sqlOption Allow_write_client_file +syn keyword sqlOption Ansi_blanks +syn keyword sqlOption Ansi_close_cursors_on_rollback +syn keyword sqlOption Ansi_permissions +syn keyword sqlOption Ansi_substring +syn keyword sqlOption Ansi_update_constraints +syn keyword sqlOption Ansinull +syn keyword sqlOption Auditing +syn keyword sqlOption Auditing_options +syn keyword sqlOption Auto_commit_on_create_local_temp_index +syn keyword sqlOption Background_priority +syn keyword sqlOption Blocking +syn keyword sqlOption Blocking_others_timeout +syn keyword sqlOption Blocking_timeout +syn keyword sqlOption Chained +syn keyword sqlOption Checkpoint_time +syn keyword sqlOption Cis_option +syn keyword sqlOption Cis_rowset_size +syn keyword sqlOption Close_on_endtrans +syn keyword sqlOption Collect_statistics_on_dml_updates +syn keyword sqlOption Conn_auditing +syn keyword sqlOption Connection_authentication +syn keyword sqlOption Continue_after_raiserror +syn keyword sqlOption Conversion_error +syn keyword sqlOption Cooperative_commit_timeout +syn keyword sqlOption Cooperative_commits +syn keyword sqlOption Database_authentication +syn keyword sqlOption Date_format +syn keyword sqlOption Date_order +syn keyword sqlOption db_publisher +syn keyword sqlOption Debug_messages +syn keyword sqlOption Dedicated_task +syn keyword sqlOption Default_dbspace +syn keyword sqlOption Default_timestamp_increment +syn keyword sqlOption Delayed_commit_timeout +syn keyword sqlOption Delayed_commits +syn keyword sqlOption Divide_by_zero_error +syn keyword sqlOption Escape_character +syn keyword sqlOption Exclude_operators +syn keyword sqlOption Extended_join_syntax +syn keyword sqlOption Extern_login_credentials +syn keyword sqlOption Fire_triggers +syn keyword sqlOption First_day_of_week +syn keyword sqlOption For_xml_null_treatment +syn keyword sqlOption Force_view_creation +syn keyword sqlOption Global_database_id +syn keyword sqlOption Http_session_timeout +syn keyword sqlOption Http_connection_pool_basesize +syn keyword sqlOption Http_connection_pool_timeout +syn keyword sqlOption Integrated_server_name +syn keyword sqlOption Isolation_level +syn keyword sqlOption Java_class_path +syn keyword sqlOption Java_location +syn keyword sqlOption Java_main_userid +syn keyword sqlOption Java_vm_options +syn keyword sqlOption Lock_rejected_rows +syn keyword sqlOption Log_deadlocks +syn keyword sqlOption Login_mode +syn keyword sqlOption Login_procedure +syn keyword sqlOption Materialized_view_optimization +syn keyword sqlOption Max_client_statements_cached +syn keyword sqlOption Max_cursor_count +syn keyword sqlOption Max_hash_size +syn keyword sqlOption Max_plans_cached +syn keyword sqlOption Max_priority +syn keyword sqlOption Max_query_tasks +syn keyword sqlOption Max_recursive_iterations +syn keyword sqlOption Max_statement_count +syn keyword sqlOption Max_temp_space +syn keyword sqlOption Min_password_length +syn keyword sqlOption Min_role_admins +syn keyword sqlOption Nearest_century +syn keyword sqlOption Non_keywords +syn keyword sqlOption Odbc_describe_binary_as_varbinary +syn keyword sqlOption Odbc_distinguish_char_and_varchar +syn keyword sqlOption Oem_string +syn keyword sqlOption On_charset_conversion_failure +syn keyword sqlOption On_tsql_error +syn keyword sqlOption Optimization_goal +syn keyword sqlOption Optimization_level +syn keyword sqlOption Optimization_workload +syn keyword sqlOption Pinned_cursor_percent_of_cache +syn keyword sqlOption Post_login_procedure +syn keyword sqlOption Precision +syn keyword sqlOption Prefetch +syn keyword sqlOption Preserve_source_format +syn keyword sqlOption Prevent_article_pkey_update +syn keyword sqlOption Priority +syn keyword sqlOption Progress_messages +syn keyword sqlOption Query_mem_timeout +syn keyword sqlOption Quoted_identifier +syn keyword sqlOption Read_past_deleted +syn keyword sqlOption Recovery_time +syn keyword sqlOption Remote_idle_timeout +syn keyword sqlOption Replicate_all +syn keyword sqlOption Request_timeout +syn keyword sqlOption Reserved_keywords +syn keyword sqlOption Return_date_time_as_string +syn keyword sqlOption Rollback_on_deadlock +syn keyword sqlOption Row_counts +syn keyword sqlOption Scale +syn keyword sqlOption Secure_feature_key +syn keyword sqlOption Sort_collation +syn keyword sqlOption Sql_flagger_error_level +syn keyword sqlOption Sql_flagger_warning_level +syn keyword sqlOption String_rtruncation +syn keyword sqlOption st_geometry_asbinary_format +syn keyword sqlOption st_geometry_astext_format +syn keyword sqlOption st_geometry_asxml_format +syn keyword sqlOption st_geometry_describe_type +syn keyword sqlOption st_geometry_interpolation +syn keyword sqlOption st_geometry_on_invalid +syn keyword sqlOption Subsume_row_locks +syn keyword sqlOption Suppress_tds_debugging +syn keyword sqlOption Synchronize_mirror_on_commit +syn keyword sqlOption Tds_empty_string_is_null +syn keyword sqlOption Temp_space_limit_check +syn keyword sqlOption Time_format +syn keyword sqlOption Time_zone_adjustment +syn keyword sqlOption Timestamp_format +syn keyword sqlOption Timestamp_with_time_zone_format +syn keyword sqlOption Truncate_timestamp_values +syn keyword sqlOption Tsql_outer_joins +syn keyword sqlOption Tsql_variables +syn keyword sqlOption Updatable_statement_isolation +syn keyword sqlOption Update_statistics +syn keyword sqlOption Upgrade_database_capability +syn keyword sqlOption User_estimates +syn keyword sqlOption Uuid_has_hyphens +syn keyword sqlOption Verify_password_function +syn keyword sqlOption Wait_for_commit +syn keyword sqlOption Webservice_namespace_host +syn keyword sqlOption Webservice_sessionid_name + +" Strings and characters: +syn region sqlString start=+"+ end=+"+ contains=@Spell +syn region sqlString start=+'+ end=+'+ contains=@Spell + +" Numbers: +syn match sqlNumber "-\=\<\d*\.\=[0-9_]\>" + +" Comments: +syn region sqlDashComment start=/--/ end=/$/ contains=@Spell +syn region sqlSlashComment start=/\/\// end=/$/ contains=@Spell +syn region sqlMultiComment start="/\*" end="\*/" contains=sqlMultiComment,@Spell +syn cluster sqlComment contains=sqlDashComment,sqlSlashComment,sqlMultiComment,@Spell +syn sync ccomment sqlComment +syn sync ccomment sqlDashComment +syn sync ccomment sqlSlashComment + +hi def link sqlDashComment Comment +hi def link sqlSlashComment Comment +hi def link sqlMultiComment Comment +hi def link sqlNumber Number +hi def link sqlOperator Operator +hi def link sqlSpecial Special +hi def link sqlKeyword Keyword +hi def link sqlStatement Statement +hi def link sqlString String +hi def link sqlType Type +hi def link sqlFunction Function +hi def link sqlOption PreProc + +let b:current_syntax = "sqlanywhere" + +" vim:sw=4: + +endif diff --git a/syntax/sqlforms.vim b/syntax/sqlforms.vim new file mode 100644 index 0000000..df3e632 --- /dev/null +++ b/syntax/sqlforms.vim @@ -0,0 +1,156 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SQL*Forms (Oracle 7), based on sql.vim (vim5.0) +" Maintainer: Austin Ziegler (austin@halostatue.ca) +" Last Change: 2003 May 11 +" Prev Change: 19980710 +" URL: http://www.halostatue.ca/vim/syntax/proc.vim +" +" TODO Find a new maintainer who knows SQL*Forms. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syntax case ignore + +setlocal iskeyword=a-z,A-Z,48-57,_,.,-,> + + + " The SQL reserved words, defined as keywords. +syntax match sqlTriggers /on-.*$/ +syntax match sqlTriggers /key-.*$/ +syntax match sqlTriggers /post-.*$/ +syntax match sqlTriggers /pre-.*$/ +syntax match sqlTriggers /user-.*$/ + +syntax keyword sqlSpecial null false true + +syntax keyword sqlProcedure abort_query anchor_view bell block_menu break call +syntax keyword sqlProcedure call_input call_query clear_block clear_eol +syntax keyword sqlProcedure clear_field clear_form clear_record commit_form +syntax keyword sqlProcedure copy count_query create_record default_value +syntax keyword sqlProcedure delete_record display_error display_field down +syntax keyword sqlProcedure duplicate_field duplicate_record edit_field +syntax keyword sqlProcedure enter enter_query erase execute_query +syntax keyword sqlProcedure execute_trigger exit_form first_Record go_block +syntax keyword sqlProcedure go_field go_record help hide_menu hide_page host +syntax keyword sqlProcedure last_record list_values lock_record message +syntax keyword sqlProcedure move_view new_form next_block next_field next_key +syntax keyword sqlProcedure next_record next_set pause post previous_block +syntax keyword sqlProcedure previous_field previous_record print redisplay +syntax keyword sqlProcedure replace_menu resize_view scroll_down scroll_up +syntax keyword sqlProcedure set_field show_keys show_menu show_page +syntax keyword sqlProcedure synchronize up user_exit + +syntax keyword sqlFunction block_characteristic error_code error_text +syntax keyword sqlFunction error_type field_characteristic form_failure +syntax keyword sqlFunction form_fatal form_success name_in + +syntax keyword sqlParameters hide no_hide replace no_replace ask_commit +syntax keyword sqlParameters do_commit no_commit no_validate all_records +syntax keyword sqlParameters for_update no_restrict restrict no_screen +syntax keyword sqlParameters bar full_screen pull_down auto_help auto_skip +syntax keyword sqlParameters fixed_length enterable required echo queryable +syntax keyword sqlParameters updateable update_null upper_case attr_on +syntax keyword sqlParameters attr_off base_table first_field last_field +syntax keyword sqlParameters datatype displayed display_length field_length +syntax keyword sqlParameters list page primary_key query_length x_pos y_pos + +syntax match sqlSystem /system\.block_status/ +syntax match sqlSystem /system\.current_block/ +syntax match sqlSystem /system\.current_field/ +syntax match sqlSystem /system\.current_form/ +syntax match sqlSystem /system\.current_value/ +syntax match sqlSystem /system\.cursor_block/ +syntax match sqlSystem /system\.cursor_field/ +syntax match sqlSystem /system\.cursor_record/ +syntax match sqlSystem /system\.cursor_value/ +syntax match sqlSystem /system\.form_status/ +syntax match sqlSystem /system\.last_query/ +syntax match sqlSystem /system\.last_record/ +syntax match sqlSystem /system\.message_level/ +syntax match sqlSystem /system\.record_status/ +syntax match sqlSystem /system\.trigger_block/ +syntax match sqlSystem /system\.trigger_field/ +syntax match sqlSystem /system\.trigger_record/ +syntax match sqlSystem /\$\$date\$\$/ +syntax match sqlSystem /\$\$time\$\$/ + +syntax keyword sqlKeyword accept access add as asc by check cluster column +syntax keyword sqlKeyword compress connect current decimal default +syntax keyword sqlKeyword desc exclusive file for from group +syntax keyword sqlKeyword having identified immediate increment index +syntax keyword sqlKeyword initial into is level maxextents mode modify +syntax keyword sqlKeyword nocompress nowait of offline on online start +syntax keyword sqlKeyword successful synonym table to trigger uid +syntax keyword sqlKeyword unique user validate values view whenever +syntax keyword sqlKeyword where with option order pctfree privileges +syntax keyword sqlKeyword public resource row rowlabel rownum rows +syntax keyword sqlKeyword session share size smallint sql\*forms_version +syntax keyword sqlKeyword terse define form name title procedure begin +syntax keyword sqlKeyword default_menu_application trigger block field +syntax keyword sqlKeyword enddefine declare exception raise when cursor +syntax keyword sqlKeyword definition base_table pragma +syntax keyword sqlKeyword column_name global trigger_type text description +syntax match sqlKeyword "<<<" +syntax match sqlKeyword ">>>" + +syntax keyword sqlOperator not and or out to_number to_date message erase +syntax keyword sqlOperator in any some all between exists substr nvl +syntax keyword sqlOperator exception_init +syntax keyword sqlOperator like escape trunc lpad rpad sum +syntax keyword sqlOperator union intersect minus to_char greatest +syntax keyword sqlOperator prior distinct decode least avg +syntax keyword sqlOperator sysdate true false field_characteristic +syntax keyword sqlOperator display_field call host + +syntax keyword sqlStatement alter analyze audit comment commit create +syntax keyword sqlStatement delete drop explain grant insert lock noaudit +syntax keyword sqlStatement rename revoke rollback savepoint select set +syntax keyword sqlStatement truncate update if elsif loop then +syntax keyword sqlStatement open fetch close else end + +syntax keyword sqlType char character date long raw mlslabel number rowid +syntax keyword sqlType varchar varchar2 float integer boolean global + +syntax keyword sqlCodes sqlcode no_data_found too_many_rows others +syntax keyword sqlCodes form_trigger_failure notfound found +syntax keyword sqlCodes validate no_commit + + " Comments: +syntax region sqlComment start="/\*" end="\*/" +syntax match sqlComment "--.*" + + " Strings and characters: +syntax region sqlString start=+"+ skip=+\\\\\|\\"+ end=+"+ +syntax region sqlString start=+'+ skip=+\\\\\|\\"+ end=+'+ + + " Numbers: +syntax match sqlNumber "-\=\<[0-9]*\.\=[0-9_]\>" + +syntax sync ccomment sqlComment + + +hi def link sqlComment Comment +hi def link sqlKeyword Statement +hi def link sqlNumber Number +hi def link sqlOperator Statement +hi def link sqlProcedure Statement +hi def link sqlFunction Statement +hi def link sqlSystem Identifier +hi def link sqlSpecial Special +hi def link sqlStatement Statement +hi def link sqlString String +hi def link sqlType Type +hi def link sqlCodes Identifier +hi def link sqlTriggers PreProc + + +let b:current_syntax = "sqlforms" + +" vim: ts=8 sw=4 + +endif diff --git a/syntax/sqlhana.vim b/syntax/sqlhana.vim new file mode 100644 index 0000000..97e2fe9 --- /dev/null +++ b/syntax/sqlhana.vim @@ -0,0 +1,294 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SQL, SAP HANA In Memory Database +" Maintainer: David Fishburn +" Last Change: 2012 Oct 23 +" Version: SP4 b (Q2 2012) +" Homepage: http://www.vim.org/scripts/script.php?script_id=4275 + +" Description: Updated to SAP HANA SP4 +" +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" The SQL reserved words, defined as keywords. +" These were pulled from the following SQL reference: +" http://help.sap.com/hana/hana_sql_en.pdf +" An easy approach is to copy all text from the PDF +" into a Vim buffer. The keywords are in UPPER case, +" so you can run the following commands to be left with +" mainly the UPPER case words: +" 1. Delete all words that do not begin with a Capital +" %s/\(\<[^A-Z]\w*\>\)//g +" 2. Remove all words where the 2nd letter is not a Capital +" %s/\(\<[A-Z][^A-Z]\w*\>\)//g +" 3. Remove all non-word (or space) characters +" %s/[^0-9A-Za-z_ ]*//g +" 4. Remove some known words +" %s/\<\(SAP\|HANA\|OK\|AG\|IBM\|DB2\|AIX\|POWER\d\+\|UNIX\)\>//g +" 5. Remove blank lines and trailing spaces +" %s/\s\+$//g +" %s/^\s\+//g +" %s/^$\n//g +" 6. Convert spaces to newlines remove single character +" %s/[ ]\+/\r/g +" %g/^\w$/d +" 7. Sort and remove duplicates +" :sort +" :Uniq +" 8. Use the WhatsMissing plugin against the sqlhana.vim file. +" 9. Generated a file of all UPPER cased words which should not +" be in the syntax file. These items should be removed +" from the list in step 7. You can use WhatsNotMissing +" between step 7 and this new file to weed out the words +" we know are not syntax related. +" 10. Use the WhatsMissingRemoveMatches to remove the words +" from step 9. + +syn keyword sqlSpecial false null true + +" Supported Functions for Date/Time types +syn keyword sqlFunction ADD_DAYS ADD_MONTHS ADD_SECONDS ADD_YEARS COALESCE +syn keyword sqlFunction CURRENT_DATE CURRENT_TIME CURRENT_TIMESTAMP CURRENT_UTCDATE +syn keyword sqlFunction CURRENT_UTCTIME CURRENT_UTCTIMESTAMP +syn keyword sqlFunction DAYNAME DAYOFMONTH DAYOFYEAR DAYS_BETWEEN EXTRACT +syn keyword sqlFunction GREATEST HOUR IFNULL ISOWEEK LAST_DAY LEAST LOCALTOUTC +syn keyword sqlFunction MINUTE MONTH MONTHNAME NEXT_DAY NOW QUARTER SECOND +syn keyword sqlFunction SECONDS_BETWEEN UTCTOLOCAL WEEK WEEKDAY YEAR + +syn keyword sqlFunction TO_CHAR TO_DATE TO_DATS TO_NCHAR TO_TIME TO_TIMESTAMP UTCTOLOCAL + +" Aggregate +syn keyword sqlFunction COUNT MIN MAX SUM AVG STDDEV VAR + +" Datatype conversion +syn keyword sqlFunction CAST TO_ALPHANUM TO_BIGINT TO_BINARY TO_BLOB TO_CHAR TO_CLOB +syn keyword sqlFunction TO_DATE TO_DATS TO_DECIMAL TO_DOUBLE TO_INT TO_INTEGER TO_NCHAR +syn keyword sqlFunction TO_NCLOB TO_NVARCHAR TO_REAL TO_SECONDDATE TO_SMALLDECIMAL +syn keyword sqlFunction TO_SMALLINT TO_TIME TO_TIMESTAMP TO_TINYINT TO_VARCHAR TO_VARBINARY + +" Number functions +syn keyword sqlFunction ABS ACOS ASIN ATAN ATAN2 BINTOHEX BITAND CEIL COS COSH COT +syn keyword sqlFunction EXP FLOOR GREATEST HEXTOBIN LEAST LN LOG MOD POWER ROUND +syn keyword sqlFunction SIGN SIN SINH SQRT TAN TANH UMINUS + +" String functions +syn keyword sqlFunction ASCII CHAR CONCAT LCASE LENGTH LOCATE LOWER LPAD LTRIM +syn keyword sqlFunction NCHAR REPLACE RPAD RTRIM SUBSTR_AFTER SUBSTR_BEFORE +syn keyword sqlFunction SUBSTRING TRIM UCASE UNICODE UPPER + +" Miscellaneous functions +syn keyword sqlFunction COALESCE CURRENT_CONNECTION CURRENT_SCHEMA CURRENT_USER +syn keyword sqlFunction GROUPING_ID IFNULL MAP NULLIF SESSION_CONTEXT SESSION_USER SYSUUIDSQL +syn keyword sqlFunction GET_NUM_SERVERS + + +" sp_ procedures +" syn keyword sqlFunction sp_addalias + + +" Reserved keywords +syn keyword sqlkeyword ALL AS AT BEFORE +syn keyword sqlkeyword BEGIN BOTH BY +syn keyword sqlkeyword CONDITION +syn keyword sqlkeyword CURRVAL CURSOR DECLARE +syn keyword sqlkeyword DISTINCT DO ELSE ELSEIF ELSIF +syn keyword sqlkeyword END EXCEPTION EXEC +syn keyword sqlkeyword FOR FROM GROUP +syn keyword sqlkeyword HAVING IN +syn keyword sqlkeyword INOUT INTO IS +syn keyword sqlkeyword LEADING +syn keyword sqlkeyword LOOP MINUS NATURAL NEXTVAL +syn keyword sqlkeyword OF ON ORDER OUT +syn keyword sqlkeyword PRIOR RETURN RETURNS REVERSE +syn keyword sqlkeyword ROWID SELECT +syn keyword sqlkeyword SQL START STOP SYSDATE +syn keyword sqlkeyword SYSTIME SYSTIMESTAMP SYSUUID +syn keyword sqlkeyword TRAILING USING UTCDATE +syn keyword sqlkeyword UTCTIME UTCTIMESTAMP VALUES +syn keyword sqlkeyword WHILE +syn keyword sqlkeyword ANY SOME EXISTS ESCAPE + +" IF keywords +syn keyword sqlkeyword IF + +" CASE keywords +syn keyword sqlKeyword WHEN THEN + +" Syntax rules common to TEXT and SHORTTEXT keywords +syn keyword sqlKeyword LANGUAGE DETECTION LINGUISTIC +syn keyword sqlkeyword MIME TYPE +syn keyword sqlkeyword EXACT WEIGHT FUZZY FUZZINESSTHRESHOLD SEARCH +syn keyword sqlkeyword PHRASE INDEX RATIO REBUILD +syn keyword sqlkeyword CONFIGURATION +syn keyword sqlkeyword SEARCH ONLY +syn keyword sqlkeyword FAST PREPROCESS +syn keyword sqlkeyword SYNC SYNCHRONOUS ASYNC ASYNCHRONOUS FLUSH QUEUE +syn keyword sqlkeyword EVERY AFTER MINUTES DOCUMENTS SUSPEND + +" Statement keywords (i.e. after ALTER or CREATE) +syn keyword sqlkeyword AUDIT POLICY +syn keyword sqlkeyword FULLTEXT +syn keyword sqlkeyword SEQUENCE RESTART +syn keyword sqlkeyword TABLE +syn keyword sqlkeyword PROCEDURE STATISTICS +syn keyword sqlkeyword SCHEMA +syn keyword sqlkeyword SYNONYM +syn keyword sqlkeyword VIEW +syn keyword sqlkeyword COLUMN +syn keyword sqlkeyword SYSTEM LICENSE +syn keyword sqlkeyword SESSION +syn keyword sqlkeyword CANCEL WORK +syn keyword sqlkeyword PLAN CACHE +syn keyword sqlkeyword LOGGING NOLOGGING RETENTION +syn keyword sqlkeyword RECONFIGURE SERVICE +syn keyword sqlkeyword RESET MONITORING +syn keyword sqlkeyword SAVE DURATION PERFTRACE FUNCTION_PROFILER +syn keyword sqlkeyword SAVEPOINT +syn keyword sqlkeyword USER +syn keyword sqlkeyword ROLE +syn keyword sqlkeyword ASC DESC +syn keyword sqlkeyword OWNED +syn keyword sqlkeyword DEPENDENCIES SCRAMBLE + +" Create sequence +syn keyword sqlkeyword INCREMENT MAXVALUE MINVALUE CYCLE + +" Create table +syn keyword sqlkeyword HISTORY GLOBAL LOCAL TEMPORARY + +" Create trigger +syn keyword sqlkeyword TRIGGER REFERENCING EACH DEFAULT +syn keyword sqlkeyword SIGNAL RESIGNAL MESSAGE_TEXT OLD NEW +syn keyword sqlkeyword EXIT HANDLER SQL_ERROR_CODE +syn keyword sqlkeyword TARGET CONDITION SIGNAL + +" Alter table +syn keyword sqlkeyword ADD DROP MODIFY GENERATED ALWAYS +syn keyword sqlkeyword UNIQUE BTREE CPBTREE PRIMARY KEY +syn keyword sqlkeyword CONSTRAINT PRELOAD NONE +syn keyword sqlkeyword ROW THREADS BATCH +syn keyword sqlkeyword MOVE PARTITION TO LOCATION PHYSICAL OTHERS +syn keyword sqlkeyword ROUNDROBIN PARTITIONS HASH RANGE VALUE +syn keyword sqlkeyword PERSISTENT DELTA AUTO AUTOMERGE + +" Create audit policy +syn keyword sqlkeyword AUDITING SUCCESSFUL UNSUCCESSFUL +syn keyword sqlkeyword PRIVILEGE STRUCTURED CHANGE LEVEL +syn keyword sqlkeyword EMERGENCY ALERT CRITICAL WARNING INFO + +" Privileges +syn keyword sqlkeyword DEBUG EXECUTE + +" Schema +syn keyword sqlkeyword CASCADE RESTRICT PARAMETERS SCAN + +" Traces +syn keyword sqlkeyword CLIENT CRASHDUMP EMERGENCYDUMP +syn keyword sqlkeyword INDEXSERVER NAMESERVER DAEMON +syn keyword sqlkeyword CLEAR REMOVE TRACES + +" Reclaim +syn keyword sqlkeyword RECLAIM DATA VOLUME VERSION SPACE DEFRAGMENT SPARSIFY + +" Join +syn keyword sqlkeyword INNER OUTER LEFT RIGHT FULL CROSS JOIN +syn keyword sqlkeyword GROUPING SETS ROLLUP CUBE +syn keyword sqlkeyword BEST LIMIT OFFSET +syn keyword sqlkeyword WITH SUBTOTAL BALANCE TOTAL +syn keyword sqlkeyword TEXT_FILTER FILL UP SORT MATCHES TOP +syn keyword sqlkeyword RESULT OVERVIEW PREFIX MULTIPLE RESULTSETS + +" Lock +syn keyword sqlkeyword EXCLUSIVE MODE NOWAIT + +" Transaction +syn keyword sqlkeyword TRANSACTION ISOLATION READ COMMITTED +syn keyword sqlkeyword REPEATABLE SERIALIZABLE WRITE + +" Saml +syn keyword sqlkeyword SAML ASSERTION PROVIDER SUBJECT ISSUER + +" User +syn keyword sqlkeyword PASSWORD IDENTIFIED EXTERNALLY ATTEMPTS ATTEMPTS +syn keyword sqlkeyword ENABLE DISABLE OFF LIFETIME FORCE DEACTIVATE +syn keyword sqlkeyword ACTIVATE IDENTITY KERBEROS + +" Grant +syn keyword sqlkeyword ADMIN BACKUP CATALOG SCENARIO INIFILE MONITOR +syn keyword sqlkeyword OPTIMIZER OPTION +syn keyword sqlkeyword RESOURCE STRUCTUREDPRIVILEGE TRACE + +" Import +syn keyword sqlkeyword CSV FILE CONTROL NO CHECK SKIP FIRST LIST +syn keyword sqlkeyword RECORD DELIMITED FIELD OPTIONALLY ENCLOSED FORMAT + +" Roles +syn keyword sqlkeyword PUBLIC CONTENT_ADMIN MODELING MONITORING + +" Miscellaneous +syn keyword sqlkeyword APPLICATION BINARY IMMEDIATE COREFILE SECURITY DEFINER +syn keyword sqlkeyword DUMMY INVOKER MATERIALIZED MESSEGE_TEXT PARAMETER PARAMETERS +syn keyword sqlkeyword PART +syn keyword sqlkeyword CONSTANT SQLEXCEPTION SQLWARNING + +syn keyword sqlOperator WHERE BETWEEN LIKE NULL CONTAINS +syn keyword sqlOperator AND OR NOT CASE +syn keyword sqlOperator UNION INTERSECT EXCEPT + +syn keyword sqlStatement ALTER CALL CALLS CREATE DROP RENAME TRUNCATE +syn keyword sqlStatement DELETE INSERT UPDATE EXPLAIN +syn keyword sqlStatement MERGE REPLACE UPSERT SELECT +syn keyword sqlStatement SET UNSET LOAD UNLOAD +syn keyword sqlStatement CONNECT DISCONNECT COMMIT LOCK ROLLBACK +syn keyword sqlStatement GRANT REVOKE +syn keyword sqlStatement EXPORT IMPORT + + +syn keyword sqlType DATE TIME SECONDDATE TIMESTAMP TINYINT SMALLINT +syn keyword sqlType INT INTEGER BIGINT SMALLDECIMAL DECIMAL +syn keyword sqlType REAL DOUBLE FLOAT +syn keyword sqlType VARCHAR NVARCHAR ALPHANUM SHORTTEXT VARBINARY +syn keyword sqlType BLOB CLOB NCLOB TEXT DAYDATE + +syn keyword sqlOption Webservice_namespace_host + +" Strings and characters: +syn region sqlString start=+"+ end=+"+ contains=@Spell +syn region sqlString start=+'+ end=+'+ contains=@Spell + +" Numbers: +syn match sqlNumber "-\=\<\d*\.\=[0-9_]\>" + +" Comments: +syn region sqlDashComment start=/--/ end=/$/ contains=@Spell +syn region sqlSlashComment start=/\/\// end=/$/ contains=@Spell +syn region sqlMultiComment start="/\*" end="\*/" contains=sqlMultiComment,@Spell +syn cluster sqlComment contains=sqlDashComment,sqlSlashComment,sqlMultiComment,@Spell +syn sync ccomment sqlComment +syn sync ccomment sqlDashComment +syn sync ccomment sqlSlashComment + +hi def link sqlDashComment Comment +hi def link sqlSlashComment Comment +hi def link sqlMultiComment Comment +hi def link sqlNumber Number +hi def link sqlOperator Operator +hi def link sqlSpecial Special +hi def link sqlKeyword Keyword +hi def link sqlStatement Statement +hi def link sqlString String +hi def link sqlType Type +hi def link sqlFunction Function +hi def link sqlOption PreProc + +let b:current_syntax = "sqlhana" + +" vim:sw=4: + +endif diff --git a/syntax/sqlinformix.vim b/syntax/sqlinformix.vim new file mode 100644 index 0000000..11c0538 --- /dev/null +++ b/syntax/sqlinformix.vim @@ -0,0 +1,187 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Informix Structured Query Language (SQL) and Stored Procedure Language (SPL) +" Language: SQL, SPL (Informix Dynamic Server 2000 v9.2) +" Maintainer: Dean Hill +" Last Change: 2004 Aug 30 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + + + +" === Comment syntax group === +syn region sqlComment start="{" end="}" contains=sqlTodo +syn match sqlComment "--.*$" contains=sqlTodo +syn sync ccomment sqlComment + + + +" === Constant syntax group === +" = Boolean subgroup = +syn keyword sqlBoolean true false +syn keyword sqlBoolean null +syn keyword sqlBoolean public user +syn keyword sqlBoolean current today +syn keyword sqlBoolean year month day hour minute second fraction + +" = String subgroup = +syn region sqlString start=+"+ end=+"+ +syn region sqlString start=+'+ end=+'+ + +" = Numbers subgroup = +syn match sqlNumber "-\=\<\d*\.\=[0-9_]\>" + + + +" === Statement syntax group === +" SQL +syn keyword sqlStatement allocate alter +syn keyword sqlStatement begin +syn keyword sqlStatement close commit connect create +syn keyword sqlStatement database deallocate declare delete describe disconnect drop +syn keyword sqlStatement execute fetch flush free get grant info insert +syn keyword sqlStatement load lock open output +syn keyword sqlStatement prepare put +syn keyword sqlStatement rename revoke rollback select set start stop +syn keyword sqlStatement truncate unload unlock update +syn keyword sqlStatement whenever +" SPL +syn keyword sqlStatement call continue define +syn keyword sqlStatement exit +syn keyword sqlStatement let +syn keyword sqlStatement return system trace + +" = Conditional subgroup = +" SPL +syn keyword sqlConditional elif else if then +syn keyword sqlConditional case +" Highlight "end if" with one or more separating spaces +syn match sqlConditional "end \+if" + +" = Repeat subgroup = +" SQL/SPL +" Handle SQL triggers' "for each row" clause and SPL "for" loop +syn match sqlRepeat "for\( \+each \+row\)\=" +" SPL +syn keyword sqlRepeat foreach while +" Highlight "end for", etc. with one or more separating spaces +syn match sqlRepeat "end \+for" +syn match sqlRepeat "end \+foreach" +syn match sqlRepeat "end \+while" + +" = Exception subgroup = +" SPL +syn match sqlException "on \+exception" +syn match sqlException "end \+exception" +syn match sqlException "end \+exception \+with \+resume" +syn match sqlException "raise \+exception" + +" = Keyword subgroup = +" SQL +syn keyword sqlKeyword aggregate add as authorization autofree by +syn keyword sqlKeyword cache cascade check cluster collation +syn keyword sqlKeyword column connection constraint cross +syn keyword sqlKeyword dataskip debug default deferred_prepare +syn keyword sqlKeyword descriptor diagnostics +syn keyword sqlKeyword each escape explain external +syn keyword sqlKeyword file foreign fragment from function +syn keyword sqlKeyword group having +syn keyword sqlKeyword immediate index inner into isolation +syn keyword sqlKeyword join key +syn keyword sqlKeyword left level log +syn keyword sqlKeyword mode modify mounting new no +syn keyword sqlKeyword object of old optical option +syn keyword sqlKeyword optimization order outer +syn keyword sqlKeyword pdqpriority pload primary procedure +syn keyword sqlKeyword references referencing release reserve +syn keyword sqlKeyword residency right role routine row +syn keyword sqlKeyword schedule schema scratch session set +syn keyword sqlKeyword statement statistics synonym +syn keyword sqlKeyword table temp temporary timeout to transaction trigger +syn keyword sqlKeyword using values view violations +syn keyword sqlKeyword where with work +" Highlight "on" (if it's not followed by some words we've already handled) +syn match sqlKeyword "on \+\(exception\)\@!" +" SPL +" Highlight "end" (if it's not followed by some words we've already handled) +syn match sqlKeyword "end \+\(if\|for\|foreach\|while\|exception\)\@!" +syn keyword sqlKeyword resume returning + +" = Operator subgroup = +" SQL +syn keyword sqlOperator not and or +syn keyword sqlOperator in is any some all between exists +syn keyword sqlOperator like matches +syn keyword sqlOperator union intersect +syn keyword sqlOperator distinct unique + + + +" === Identifier syntax group === +" = Function subgroup = +" SQL +syn keyword sqlFunction abs acos asin atan atan2 avg +syn keyword sqlFunction cardinality cast char_length character_length cos count +syn keyword sqlFunction exp filetoblob filetoclob hex +syn keyword sqlFunction initcap length logn log10 lower lpad +syn keyword sqlFunction min max mod octet_length pow range replace root round rpad +syn keyword sqlFunction sin sqrt stdev substr substring sum +syn keyword sqlFunction to_char tan to_date trim trunc upper variance + + + +" === Type syntax group === +" SQL +syn keyword sqlType blob boolean byte char character clob +syn keyword sqlType date datetime dec decimal double +syn keyword sqlType float int int8 integer interval list lvarchar +syn keyword sqlType money multiset nchar numeric nvarchar +syn keyword sqlType real serial serial8 smallfloat smallint +syn keyword sqlType text varchar varying + + + +" === Todo syntax group === +syn keyword sqlTodo TODO FIXME XXX DEBUG NOTE + + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + + +" === Comment syntax group === +hi def link sqlComment Comment + +" === Constant syntax group === +hi def link sqlNumber Number +hi def link sqlBoolean Boolean +hi def link sqlString String + +" === Statment syntax group === +hi def link sqlStatement Statement +hi def link sqlConditional Conditional +hi def link sqlRepeat Repeat +hi def link sqlKeyword Keyword +hi def link sqlOperator Operator +hi def link sqlException Exception + +" === Identifier syntax group === +hi def link sqlFunction Function + +" === Type syntax group === +hi def link sqlType Type + +" === Todo syntax group === +hi def link sqlTodo Todo + + +let b:current_syntax = "sqlinformix" + +endif diff --git a/syntax/sqlj.vim b/syntax/sqlj.vim new file mode 100644 index 0000000..7ffbfe8 --- /dev/null +++ b/syntax/sqlj.vim @@ -0,0 +1,95 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sqlj +" Maintainer: Andreas Fischbach +" This file is based on sql.vim && java.vim (thanx) +" with a handful of additional sql words and still +" a subset of whatever standard +" Last change: 31th Dec 2001 + +" au BufNewFile,BufRead *.sqlj so $VIM/syntax/sqlj.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read the Java syntax to start with +source :p:h/java.vim + +" SQLJ extentions +" The SQL reserved words, defined as keywords. + +syn case ignore +syn keyword sqljSpecial null + +syn keyword sqljKeyword access add as asc by check cluster column +syn keyword sqljKeyword compress connect current decimal default +syn keyword sqljKeyword desc else exclusive file for from group +syn keyword sqljKeyword having identified immediate increment index +syn keyword sqljKeyword initial into is level maxextents mode modify +syn keyword sqljKeyword nocompress nowait of offline on online start +syn keyword sqljKeyword successful synonym table then to trigger uid +syn keyword sqljKeyword unique user validate values view whenever +syn keyword sqljKeyword where with option order pctfree privileges +syn keyword sqljKeyword public resource row rowlabel rownum rows +syn keyword sqljKeyword session share size smallint + +syn keyword sqljKeyword fetch database context iterator field join +syn keyword sqljKeyword foreign outer inner isolation left right +syn keyword sqljKeyword match primary key + +syn keyword sqljOperator not and or +syn keyword sqljOperator in any some all between exists +syn keyword sqljOperator like escape +syn keyword sqljOperator union intersect minus +syn keyword sqljOperator prior distinct +syn keyword sqljOperator sysdate + +syn keyword sqljOperator max min avg sum count hex + +syn keyword sqljStatement alter analyze audit comment commit create +syn keyword sqljStatement delete drop explain grant insert lock noaudit +syn keyword sqljStatement rename revoke rollback savepoint select set +syn keyword sqljStatement truncate update begin work + +syn keyword sqljType char character date long raw mlslabel number +syn keyword sqljType rowid varchar varchar2 float integer + +syn keyword sqljType byte text serial + + +" Strings and characters: +syn region sqljString start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn region sqljString start=+'+ skip=+\\\\\|\\"+ end=+'+ + +" Numbers: +syn match sqljNumber "-\=\<\d*\.\=[0-9_]\>" + +" PreProc +syn match sqljPre "#sql" + +" Comments: +syn region sqljComment start="/\*" end="\*/" +syn match sqlComment "--.*" + +syn sync ccomment sqljComment + + +" The default methods for highlighting. Can be overridden later. +hi def link sqljComment Comment +hi def link sqljKeyword sqljSpecial +hi def link sqljNumber Number +hi def link sqljOperator sqljStatement +hi def link sqljSpecial Special +hi def link sqljStatement Statement +hi def link sqljString String +hi def link sqljType Type +hi def link sqljPre PreProc + + +let b:current_syntax = "sqlj" + + +endif diff --git a/syntax/sqloracle.vim b/syntax/sqloracle.vim new file mode 100644 index 0000000..47dd926 --- /dev/null +++ b/syntax/sqloracle.vim @@ -0,0 +1,148 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SQL, PL/SQL (Oracle 11g) +" Maintainer: Christian Brabandt +" Repository: https://github.com/chrisbra/vim-sqloracle-syntax +" License: Vim +" Previous Maintainer: Paul Moore +" Last Change: 2016 Jul 22 + +" Changes: +" 02.04.2016: Support for when keyword +" 03.04.2016: Support for join related keywords +" 22.07.2016: Support Oracle Q-Quote-Syntax + +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" The SQL reserved words, defined as keywords. + +syn keyword sqlSpecial false null true + +syn keyword sqlKeyword access add as asc begin by case check cluster column +syn keyword sqlKeyword cache compress connect current cursor decimal default desc +syn keyword sqlKeyword else elsif end exception exclusive file for from +syn keyword sqlKeyword function group having identified if immediate increment +syn keyword sqlKeyword index initial initrans into is level link logging loop +syn keyword sqlKeyword maxextents maxtrans mode modify monitoring +syn keyword sqlKeyword nocache nocompress nologging noparallel nowait of offline on online start +syn keyword sqlKeyword parallel successful synonym table tablespace then to trigger uid +syn keyword sqlKeyword unique user validate values view when whenever +syn keyword sqlKeyword where with option order pctfree pctused privileges procedure +syn keyword sqlKeyword public resource return row rowlabel rownum rows +syn keyword sqlKeyword session share size smallint type using +syn keyword sqlKeyword join cross inner outer left right + +syn keyword sqlOperator not and or +syn keyword sqlOperator in any some all between exists +syn keyword sqlOperator like escape +syn keyword sqlOperator union intersect minus +syn keyword sqlOperator prior distinct +syn keyword sqlOperator sysdate out + +syn keyword sqlStatement analyze audit comment commit +syn keyword sqlStatement delete drop execute explain grant lock noaudit +syn keyword sqlStatement rename revoke rollback savepoint set +syn keyword sqlStatement truncate +" next ones are contained, so folding works. +syn keyword sqlStatement create update alter select insert contained + +syn keyword sqlType boolean char character date float integer long +syn keyword sqlType mlslabel number raw rowid varchar varchar2 varray + +" Strings: +syn region sqlString matchgroup=Quote start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn region sqlString matchgroup=Quote start=+'+ skip=+\\\\\|\\'+ end=+'+ +syn region sqlString matchgroup=Quote start=+n\?q'\z([^[(<{]\)+ end=+\z1'+ +syn region sqlString matchgroup=Quote start=+n\?q'<+ end=+>'+ +syn region sqlString matchgroup=Quote start=+n\?q'{+ end=+}'+ +syn region sqlString matchgroup=Quote start=+n\?q'(+ end=+)'+ +syn region sqlString matchgroup=Quote start=+n\?q'\[+ end=+]'+ + +" Numbers: +syn match sqlNumber "-\=\<\d*\.\=[0-9_]\>" + +" Comments: +syn region sqlComment start="/\*" end="\*/" contains=sqlTodo,@Spell fold +syn match sqlComment "--.*$" contains=sqlTodo,@Spell + +" Setup Folding: +" this is a hack, to get certain statements folded. +" the keywords create/update/alter/select/insert need to +" have contained option. +syn region sqlFold start='^\s*\zs\c\(Create\|Update\|Alter\|Select\|Insert\)' end=';$\|^$' transparent fold contains=ALL + +syn sync ccomment sqlComment + +" Functions: +" (Oracle 11g) +" Aggregate Functions +syn keyword sqlFunction avg collect corr corr_s corr_k count covar_pop covar_samp cume_dist dense_rank first +syn keyword sqlFunction group_id grouping grouping_id last max median min percentile_cont percentile_disc percent_rank rank +syn keyword sqlFunction regr_slope regr_intercept regr_count regr_r2 regr_avgx regr_avgy regr_sxx regr_syy regr_sxy +syn keyword sqlFunction stats_binomial_test stats_crosstab stats_f_test stats_ks_test stats_mode stats_mw_test +syn keyword sqlFunction stats_one_way_anova stats_t_test_one stats_t_test_paired stats_t_test_indep stats_t_test_indepu +syn keyword sqlFunction stats_wsr_test stddev stddev_pop stddev_samp sum +syn keyword sqlFunction sys_xmlagg var_pop var_samp variance xmlagg +" Char Functions +syn keyword sqlFunction ascii chr concat initcap instr length lower lpad ltrim +syn keyword sqlFunction nls_initcap nls_lower nlssort nls_upper regexp_instr regexp_replace +syn keyword sqlFunction regexp_substr replace rpad rtrim soundex substr translate treat trim upper +" Comparison Functions +syn keyword sqlFunction greatest least +" Conversion Functions +syn keyword sqlFunction asciistr bin_to_num cast chartorowid compose convert +syn keyword sqlFunction decompose hextoraw numtodsinterval numtoyminterval rawtohex rawtonhex rowidtochar +syn keyword sqlFunction rowidtonchar scn_to_timestamp timestamp_to_scn to_binary_double to_binary_float +syn keyword sqlFunction to_char to_char to_char to_clob to_date to_dsinterval to_lob to_multi_byte +syn keyword sqlFunction to_nchar to_nchar to_nchar to_nclob to_number to_dsinterval to_single_byte +syn keyword sqlFunction to_timestamp to_timestamp_tz to_yminterval to_yminterval translate unistr +" DataMining Functions +syn keyword sqlFunction cluster_id cluster_probability cluster_set feature_id feature_set +syn keyword sqlFunction feature_value prediction prediction_bounds prediction_cost +syn keyword sqlFunction prediction_details prediction_probability prediction_set +" Datetime Functions +syn keyword sqlFunction add_months current_date current_timestamp dbtimezone extract +syn keyword sqlFunction from_tz last_day localtimestamp months_between new_time +syn keyword sqlFunction next_day numtodsinterval numtoyminterval round sessiontimezone +syn keyword sqlFunction sys_extract_utc sysdate systimestamp to_char to_timestamp +syn keyword sqlFunction to_timestamp_tz to_dsinterval to_yminterval trunc tz_offset +" Numeric Functions +syn keyword sqlFunction abs acos asin atan atan2 bitand ceil cos cosh exp +syn keyword sqlFunction floor ln log mod nanvl power remainder round sign +syn keyword sqlFunction sin sinh sqrt tan tanh trunc width_bucket +" NLS Functions +syn keyword sqlFunction ls_charset_decl_len nls_charset_id nls_charset_name +" Various Functions +syn keyword sqlFunction bfilename cardin coalesce collect decode dump empty_blob empty_clob +syn keyword sqlFunction lnnvl nullif nvl nvl2 ora_hash powermultiset powermultiset_by_cardinality +syn keyword sqlFunction sys_connect_by_path sys_context sys_guid sys_typeid uid user userenv vsizeality +" XML Functions +syn keyword sqlFunction appendchildxml deletexml depth extract existsnode extractvalue insertchildxml +syn keyword sqlFunction insertxmlbefore path sys_dburigen sys_xmlagg sys_xmlgen updatexml xmlagg xmlcast +syn keyword sqlFunction xmlcdata xmlcolattval xmlcomment xmlconcat xmldiff xmlelement xmlexists xmlforest +syn keyword sqlFunction xmlparse xmlpatch xmlpi xmlquery xmlroot xmlsequence xmlserialize xmltable xmltransform +" Todo: +syn keyword sqlTodo TODO FIXME XXX DEBUG NOTE contained + +" Define the default highlighting. +hi def link Quote Special +hi def link sqlComment Comment +hi def link sqlFunction Function +hi def link sqlKeyword sqlSpecial +hi def link sqlNumber Number +hi def link sqlOperator sqlStatement +hi def link sqlSpecial Special +hi def link sqlStatement Statement +hi def link sqlString String +hi def link sqlType Type +hi def link sqlTodo Todo + +let b:current_syntax = "sql" +" vim: ts=8 + +endif diff --git a/syntax/sqr.vim b/syntax/sqr.vim new file mode 100644 index 0000000..70964ab --- /dev/null +++ b/syntax/sqr.vim @@ -0,0 +1,266 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Structured Query Report Writer (SQR) +" Maintainer: Nathan Stratton Treadway (nathanst at ontko dot com) +" URL: http://www.ontko.com/sqr/#editor_config_files +" +" Modification History: +" 2002-Apr-12: Updated for SQR v6.x +" 2002-Jul-30: Added { and } to iskeyword definition +" 2003-Oct-15: Allow "." in variable names +" highlight entire open '... literal when it contains +" "''" inside it (e.g. "'I can''t say" is treated +" as one open string, not one terminated and one open) +" {} variables can occur inside of '...' literals +" +" Thanks to the previous maintainer of this file, Jeff Lanzarotta: +" http://lanzarotta.tripod.com/vim.html +" jefflanzarotta at yahoo dot com + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=@,48-57,_,-,#,$,{,} + +syn case ignore + +" BEGIN GENERATED SECTION ============================================ + +" Generated by generate_vim_syntax.sqr at 2002/04/11 13:04 +" (based on the UltraEdit syntax file for SQR 6.1.4 +" found at http://www.ontko.com/sqr/#editor_config_files ) + +syn keyword sqrSection begin-footing begin-heading begin-procedure +syn keyword sqrSection begin-program begin-report begin-setup +syn keyword sqrSection end-footing end-heading end-procedure +syn keyword sqrSection end-program end-report end-setup + +syn keyword sqrParagraph alter-color-map alter-connection +syn keyword sqrParagraph alter-locale alter-printer alter-report +syn keyword sqrParagraph begin-document begin-execute begin-select +syn keyword sqrParagraph begin-sql declare-chart declare-image +syn keyword sqrParagraph declare-color-map declare-connection +syn keyword sqrParagraph declare-layout declare-printer +syn keyword sqrParagraph declare-report declare-procedure +syn keyword sqrParagraph declare-toc declare-variable end-declare +syn keyword sqrParagraph end-document end-select exit-select end-sql +syn keyword sqrParagraph load-lookup + +syn keyword sqrReserved #current-column #current-date #current-line +syn keyword sqrReserved #end-file #page-count #return-status +syn keyword sqrReserved #sql-count #sql-status #sqr-max-columns +syn keyword sqrReserved #sqr-max-lines #sqr-pid #sqr-toc-level +syn keyword sqrReserved #sqr-toc-page $sqr-database {sqr-database} +syn keyword sqrReserved $sqr-dbcs {sqr-dbcs} $sqr-encoding +syn keyword sqrReserved {sqr-encoding} $sqr-encoding-console +syn keyword sqrReserved {sqr-encoding-console} +syn keyword sqrReserved $sqr-encoding-database +syn keyword sqrReserved {sqr-encoding-database} +syn keyword sqrReserved $sqr-encoding-file-input +syn keyword sqrReserved {sqr-encoding-file-input} +syn keyword sqrReserved $sqr-encoding-file-output +syn keyword sqrReserved {sqr-encoding-file-output} +syn keyword sqrReserved $sqr-encoding-report-input +syn keyword sqrReserved {sqr-encoding-report-input} +syn keyword sqrReserved $sqr-encoding-report-output +syn keyword sqrReserved {sqr-encoding-report-output} +syn keyword sqrReserved $sqr-encoding-source {sqr-encoding-source} +syn keyword sqrReserved $sql-error $sqr-hostname {sqr-hostname} +syn keyword sqrReserved $sqr-locale $sqr-platform {sqr-platform} +syn keyword sqrReserved $sqr-program $sqr-report $sqr-toc-text +syn keyword sqrReserved $sqr-ver $username + +syn keyword sqrPreProc #define #else #end-if #endif #if #ifdef +syn keyword sqrPreProc #ifndef #include + +syn keyword sqrCommand add array-add array-divide array-multiply +syn keyword sqrCommand array-subtract ask break call clear-array +syn keyword sqrCommand close columns commit concat connect +syn keyword sqrCommand create-array create-color-palette date-time +syn keyword sqrCommand display divide do dollar-symbol else encode +syn keyword sqrCommand end-evaluate end-if end-while evaluate +syn keyword sqrCommand execute extract find get get-color goto +syn keyword sqrCommand graphic if input last-page let lookup +syn keyword sqrCommand lowercase mbtosbs money-symbol move +syn keyword sqrCommand multiply new-page new-report next-column +syn keyword sqrCommand next-listing no-formfeed open page-number +syn keyword sqrCommand page-size position print print-bar-code +syn keyword sqrCommand print-chart print-direct print-image +syn keyword sqrCommand printer-deinit printer-init put read +syn keyword sqrCommand rollback security set-color set-delay-print +syn keyword sqrCommand set-generations set-levels set-members +syn keyword sqrCommand sbtombs show stop string subtract toc-entry +syn keyword sqrCommand unstring uppercase use use-column +syn keyword sqrCommand use-printer-type use-procedure use-report +syn keyword sqrCommand while write + +syn keyword sqrParam 3d-effects after after-bold after-page +syn keyword sqrParam after-report after-toc and as at-end before +syn keyword sqrParam background batch-mode beep before-bold +syn keyword sqrParam before-page before-report before-toc blink +syn keyword sqrParam bold border bottom-margin box break by +syn keyword sqrParam caption center char char-size char-width +syn keyword sqrParam chars-inch chart-size checksum cl +syn keyword sqrParam clear-line clear-screen color color-palette +syn keyword sqrParam cs color_ data-array +syn keyword sqrParam data-array-column-count +syn keyword sqrParam data-array-column-labels +syn keyword sqrParam data-array-row-count data-labels date +syn keyword sqrParam date-edit-mask date-seperator +syn keyword sqrParam day-of-week-case day-of-week-full +syn keyword sqrParam day-of-week-short decimal decimal-seperator +syn keyword sqrParam default-numeric delay distinct dot-leader +syn keyword sqrParam edit-option-ad edit-option-am +syn keyword sqrParam edit-option-bc edit-option-na +syn keyword sqrParam edit-option-pm encoding entry erase-page +syn keyword sqrParam extent field fill fixed fixed_nolf float +syn keyword sqrParam font font-style font-type footing +syn keyword sqrParam footing-size foreground for-append +syn keyword sqrParam for-reading for-reports for-tocs +syn keyword sqrParam for-writing format formfeed from goto-top +syn keyword sqrParam group having heading heading-size height +syn keyword sqrParam horz-line image-size in indentation +syn keyword sqrParam init-string input-date-edit-mask insert +syn keyword sqrParam integer into item-color item-size key +syn keyword sqrParam layout left-margin legend legend-placement +syn keyword sqrParam legend-presentation legend-title level +syn keyword sqrParam line-height line-size line-width lines-inch +syn keyword sqrParam local locale loops max-columns max-lines +syn keyword sqrParam maxlen money money-edit-mask money-sign +syn keyword sqrParam money-sign-location months-case months-full +syn keyword sqrParam months-short name need newline newpage +syn keyword sqrParam no-advance nolf noline noprompt normal not +syn keyword sqrParam nowait number number-edit-mask on-break +syn keyword sqrParam on-error or order orientation page-depth +syn keyword sqrParam paper-size pie-segment-explode +syn keyword sqrParam pie-segment-percent-display +syn keyword sqrParam pie-segment-quantity-display pitch +syn keyword sqrParam point-markers point-size printer +syn keyword sqrParam printer-type quiet record reset-string +syn keyword sqrParam return_value reverse right-margin rows save +syn keyword sqrParam select size skip skiplines sort source +syn keyword sqrParam sqr-database sqr-platform startup-file +syn keyword sqrParam status stop sub-title symbol-set system +syn keyword sqrParam table text thousand-seperator +syn keyword sqrParam time-seperator times title to toc +syn keyword sqrParam top-margin type underline update using +syn keyword sqrParam value vary vert-line wait warn when +syn keyword sqrParam when-other where with x-axis-grid +syn keyword sqrParam x-axis-label x-axis-major-increment +syn keyword sqrParam x-axis-major-tick-marks x-axis-max-value +syn keyword sqrParam x-axis-min-value x-axis-minor-increment +syn keyword sqrParam x-axis-minor-tick-marks x-axis-rotate +syn keyword sqrParam x-axis-scale x-axis-tick-mark-placement xor +syn keyword sqrParam y-axis-grid y-axis-label +syn keyword sqrParam y-axis-major-increment +syn keyword sqrParam y-axis-major-tick-marks y-axis-max-value +syn keyword sqrParam y-axis-min-value y-axis-minor-increment +syn keyword sqrParam y-axis-minor-tick-marks y-axis-scale +syn keyword sqrParam y-axis-tick-mark-placement y2-type +syn keyword sqrParam y2-data-array y2-data-array-row-count +syn keyword sqrParam y2-data-array-column-count +syn keyword sqrParam y2-data-array-column-labels +syn keyword sqrParam y2-axis-color-palette y2-axis-label +syn keyword sqrParam y2-axis-major-increment +syn keyword sqrParam y2-axis-major-tick-marks y2-axis-max-value +syn keyword sqrParam y2-axis-min-value y2-axis-minor-increment +syn keyword sqrParam y2-axis-minor-tick-marks y2-axis-scale + +syn keyword sqrFunction abs acos asin atan array ascii asciic ceil +syn keyword sqrFunction cos cosh chr cond deg delete dateadd +syn keyword sqrFunction datediff datenow datetostr e10 exp edit +syn keyword sqrFunction exists floor getenv instr instrb isblank +syn keyword sqrFunction isnull log log10 length lengthb lengthp +syn keyword sqrFunction lengtht lower lpad ltrim mod nvl power rad +syn keyword sqrFunction round range replace roman rpad rtrim rename +syn keyword sqrFunction sign sin sinh sqrt substr substrb substrp +syn keyword sqrFunction substrt strtodate tan tanh trunc to_char +syn keyword sqrFunction to_multi_byte to_number to_single_byte +syn keyword sqrFunction transform translate unicode upper wrapdepth + +" END GENERATED SECTION ============================================== + +" Variables +syn match sqrVariable /\(\$\|#\|&\)\(\k\|\.\)*/ + + +" Debug compiler directives +syn match sqrPreProc /\s*#debug\a\=\(\s\|$\)/ +syn match sqrSubstVar /{\k*}/ + + +" Strings +" Note: if an undoubled ! is found, this is not a valid string +" (SQR will treat the end of the line as a comment) +syn match sqrString /'\(!!\|[^!']\)*'/ contains=sqrSubstVar +syn match sqrStrOpen /'\(!!\|''\|[^!']\)*$/ +" If we find a ' followed by an unmatched ! before a matching ', +" flag the error. +syn match sqrError /'\(!!\|[^'!]\)*![^!]/me=e-1 +syn match sqrError /'\(!!\|[^'!]\)*!$/ + +" Numbers: +syn match sqrNumber /-\=\<\d*\.\=[0-9_]\>/ + + + +" Comments: +" Handle comments that start with "!=" specially; they are only valid +" in the first column of the source line. Also, "!!" is only treated +" as a start-comment if there is only whitespace ahead of it on the line. + +syn keyword sqrTodo TODO FIXME XXX DEBUG NOTE ### +syn match sqrTodo /???/ + +" See also the sqrString section above for handling of ! characters +" inside of strings. (Those patterns override the ones below.) +syn match sqrComment /!\@ +" Last Change: 2005 Jun 12 +" URL: http://www.hampft.de/vim/syntax/squid.vim +" ThanksTo: Ilya Sher , +" Michael Dotzler + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" squid.conf syntax seems to be case insensitive +syn case ignore + +syn keyword squidTodo contained TODO +syn match squidComment "#.*$" contains=squidTodo,squidTag +syn match squidTag contained "TAG: .*$" + +" Lots & lots of Keywords! +syn keyword squidConf acl always_direct announce_host announce_period +syn keyword squidConf announce_port announce_to anonymize_headers +syn keyword squidConf append_domain as_whois_server auth_param_basic +syn keyword squidConf authenticate_children authenticate_program +syn keyword squidConf authenticate_ttl broken_posts buffered_logs +syn keyword squidConf cache_access_log cache_announce cache_dir +syn keyword squidConf cache_dns_program cache_effective_group +syn keyword squidConf cache_effective_user cache_host cache_host_acl +syn keyword squidConf cache_host_domain cache_log cache_mem +syn keyword squidConf cache_mem_high cache_mem_low cache_mgr +syn keyword squidConf cachemgr_passwd cache_peer cache_peer_access +syn keyword squidConf cahce_replacement_policy cache_stoplist +syn keyword squidConf cache_stoplist_pattern cache_store_log cache_swap +syn keyword squidConf cache_swap_high cache_swap_log cache_swap_low +syn keyword squidConf client_db client_lifetime client_netmask +syn keyword squidConf connect_timeout coredump_dir dead_peer_timeout +syn keyword squidConf debug_options delay_access delay_class +syn keyword squidConf delay_initial_bucket_level delay_parameters +syn keyword squidConf delay_pools deny_info dns_children dns_defnames +syn keyword squidConf dns_nameservers dns_testnames emulate_httpd_log +syn keyword squidConf err_html_text fake_user_agent firewall_ip +syn keyword squidConf forwarded_for forward_snmpd_port fqdncache_size +syn keyword squidConf ftpget_options ftpget_program ftp_list_width +syn keyword squidConf ftp_passive ftp_user half_closed_clients +syn keyword squidConf header_access header_replace hierarchy_stoplist +syn keyword squidConf high_response_time_warning high_page_fault_warning +syn keyword squidConf htcp_port http_access http_anonymizer httpd_accel +syn keyword squidConf httpd_accel_host httpd_accel_port +syn keyword squidConf httpd_accel_uses_host_header +syn keyword squidConf httpd_accel_with_proxy http_port http_reply_access +syn keyword squidConf icp_access icp_hit_stale icp_port +syn keyword squidConf icp_query_timeout ident_lookup ident_lookup_access +syn keyword squidConf ident_timeout incoming_http_average +syn keyword squidConf incoming_icp_average inside_firewall ipcache_high +syn keyword squidConf ipcache_low ipcache_size local_domain local_ip +syn keyword squidConf logfile_rotate log_fqdn log_icp_queries +syn keyword squidConf log_mime_hdrs maximum_object_size +syn keyword squidConf maximum_single_addr_tries mcast_groups +syn keyword squidConf mcast_icp_query_timeout mcast_miss_addr +syn keyword squidConf mcast_miss_encode_key mcast_miss_port memory_pools +syn keyword squidConf memory_pools_limit memory_replacement_policy +syn keyword squidConf mime_table min_http_poll_cnt min_icp_poll_cnt +syn keyword squidConf minimum_direct_hops minimum_object_size +syn keyword squidConf minimum_retry_timeout miss_access negative_dns_ttl +syn keyword squidConf negative_ttl neighbor_timeout neighbor_type_domain +syn keyword squidConf netdb_high netdb_low netdb_ping_period +syn keyword squidConf netdb_ping_rate never_direct no_cache +syn keyword squidConf passthrough_proxy pconn_timeout pid_filename +syn keyword squidConf pinger_program positive_dns_ttl prefer_direct +syn keyword squidConf proxy_auth proxy_auth_realm query_icmp quick_abort +syn keyword squidConf quick_abort quick_abort_max quick_abort_min +syn keyword squidConf quick_abort_pct range_offset_limit read_timeout +syn keyword squidConf redirect_children redirect_program +syn keyword squidConf redirect_rewrites_host_header reference_age +syn keyword squidConf reference_age refresh_pattern reload_into_ims +syn keyword squidConf request_body_max_size request_size request_timeout +syn keyword squidConf shutdown_lifetime single_parent_bypass +syn keyword squidConf siteselect_timeout snmp_access +syn keyword squidConf snmp_incoming_address snmp_port source_ping +syn keyword squidConf ssl_proxy store_avg_object_size +syn keyword squidConf store_objects_per_bucket strip_query_terms +syn keyword squidConf swap_level1_dirs swap_level2_dirs +syn keyword squidConf tcp_incoming_address tcp_outgoing_address +syn keyword squidConf tcp_recv_bufsize test_reachability udp_hit_obj +syn keyword squidConf udp_hit_obj_size udp_incoming_address +syn keyword squidConf udp_outgoing_address unique_hostname +syn keyword squidConf unlinkd_program uri_whitespace useragent_log +syn keyword squidConf visible_hostname wais_relay wais_relay_host +syn keyword squidConf wais_relay_port + +syn keyword squidOpt proxy-only weight ttl no-query default +syn keyword squidOpt round-robin multicast-responder +syn keyword squidOpt on off all deny allow +syn keyword squidopt via parent no-digest heap lru realm +syn keyword squidopt children credentialsttl none disable +syn keyword squidopt offline_toggle diskd q1 q2 + +" Security Actions for cachemgr_passwd +syn keyword squidAction shutdown info parameter server_list +syn keyword squidAction client_list +syn match squidAction "stats/\(objects\|vm_objects\|utilization\|ipcache\|fqdncache\|dns\|redirector\|io\|reply_headers\|filedescriptors\|netdb\)" +syn match squidAction "log\(/\(status\|enable\|disable\|clear\)\)\=" +syn match squidAction "squid\.conf" + +" Keywords for the acl-config +syn keyword squidAcl url_regex urlpath_regex referer_regex port proto +syn keyword squidAcl req_mime_type rep_mime_type +syn keyword squidAcl method browser user src dst +syn keyword squidAcl time dstdomain ident snmp_community + +syn match squidNumber "\<\d\+\>" +syn match squidIP "\<\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}\>" +syn match squidStr "\(^\s*acl\s\+\S\+\s\+\(\S*_regex\|re[pq]_mime_type\|browser\|_domain\|user\)\+\s\+\)\@<=.*" contains=squidRegexOpt +syn match squidRegexOpt contained "\(^\s*acl\s\+\S\+\s\+\S\+\(_regex\|_mime_type\)\s\+\)\@<=[-+]i\s\+" + +" All config is in one line, so this has to be sufficient +" Make it fast like hell :) +syn sync minlines=3 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link squidTodo Todo +hi def link squidComment Comment +hi def link squidTag Special +hi def link squidConf Keyword +hi def link squidOpt Constant +hi def link squidAction String +hi def link squidNumber Number +hi def link squidIP Number +hi def link squidAcl Keyword +hi def link squidStr String +hi def link squidRegexOpt Special + + +let b:current_syntax = "squid" + +" vim: ts=8 + +endif diff --git a/syntax/srec.vim b/syntax/srec.vim new file mode 100644 index 0000000..b320b8e --- /dev/null +++ b/syntax/srec.vim @@ -0,0 +1,87 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Motorola S-Record +" Maintainer: Markus Heidelberg +" Last Change: 2015 Feb 24 + +" Each record (line) is built as follows: +" +" field digits states +" +" +----------+ +" | start | 1 ('S') srecRecStart +" +----------+ +" | type | 1 srecRecType, (srecRecTypeUnknown) +" +----------+ +" | count | 2 srecByteCount +" +----------+ +" | address | 4/6/8 srecNoAddress, srecDataAddress, srecRecCount, srecStartAddress, (srecAddressFieldUnknown) +" +----------+ +" | data | 0..504/502/500 srecDataOdd, srecDataEven, (srecDataUnexpected) +" +----------+ +" | checksum | 2 srecChecksum +" +----------+ +" +" States in parentheses in the upper format description indicate that they +" should not appear in a valid file. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match srecRecStart "^S" + +syn match srecRecTypeUnknown "^S." contains=srecRecStart +syn match srecRecType "^S[0-35-9]" contains=srecRecStart + +syn match srecByteCount "^S.[0-9a-fA-F]\{2}" contains=srecRecTypeUnknown nextgroup=srecAddressFieldUnknown,srecChecksum +syn match srecByteCount "^S[0-35-9][0-9a-fA-F]\{2}" contains=srecRecType + +syn match srecAddressFieldUnknown "[0-9a-fA-F]\{2}" contained nextgroup=srecAddressFieldUnknown,srecChecksum + +syn match srecNoAddress "^S0[0-9a-fA-F]\{6}" contains=srecByteCount nextgroup=srecDataOdd,srecChecksum +syn match srecDataAddress "^S1[0-9a-fA-F]\{6}" contains=srecByteCount nextgroup=srecDataOdd,srecChecksum +syn match srecDataAddress "^S2[0-9a-fA-F]\{8}" contains=srecByteCount nextgroup=srecDataOdd,srecChecksum +syn match srecDataAddress "^S3[0-9a-fA-F]\{10}" contains=srecByteCount nextgroup=srecDataOdd,srecChecksum +syn match srecRecCount "^S5[0-9a-fA-F]\{6}" contains=srecByteCount nextgroup=srecDataUnexpected,srecChecksum +syn match srecRecCount "^S6[0-9a-fA-F]\{8}" contains=srecByteCount nextgroup=srecDataUnexpected,srecChecksum +syn match srecStartAddress "^S7[0-9a-fA-F]\{10}" contains=srecByteCount nextgroup=srecDataUnexpected,srecChecksum +syn match srecStartAddress "^S8[0-9a-fA-F]\{8}" contains=srecByteCount nextgroup=srecDataUnexpected,srecChecksum +syn match srecStartAddress "^S9[0-9a-fA-F]\{6}" contains=srecByteCount nextgroup=srecDataUnexpected,srecChecksum + +" alternating highlight per byte for easier reading +syn match srecDataOdd "[0-9a-fA-F]\{2}" contained nextgroup=srecDataEven,srecChecksum +syn match srecDataEven "[0-9a-fA-F]\{2}" contained nextgroup=srecDataOdd,srecChecksum +" data bytes which should not exist +syn match srecDataUnexpected "[0-9a-fA-F]\{2}" contained nextgroup=srecDataUnexpected,srecChecksum +" Data digit pair regex usage also results in only highlighting the checksum +" if the number of data characters is even. + +syn match srecChecksum "[0-9a-fA-F]\{2}$" contained + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link srecRecStart srecRecType +hi def link srecRecTypeUnknown srecRecType +hi def link srecRecType WarningMsg +hi def link srecByteCount Constant +hi def srecAddressFieldUnknown term=italic cterm=italic gui=italic +hi def link srecNoAddress DiffAdd +hi def link srecDataAddress Comment +hi def link srecRecCount srecNoAddress +hi def link srecStartAddress srecDataAddress +hi def srecDataOdd term=bold cterm=bold gui=bold +hi def srecDataEven term=NONE cterm=NONE gui=NONE +hi def link srecDataUnexpected Error +hi def link srecChecksum DiffChange + + +let b:current_syntax = "srec" + +" vim: ts=8 + +endif diff --git a/syntax/sshconfig.vim b/syntax/sshconfig.vim new file mode 100644 index 0000000..d0fedfe --- /dev/null +++ b/syntax/sshconfig.vim @@ -0,0 +1,262 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: OpenSSH client configuration file (ssh_config) +" Author: David Necas (Yeti) +" Maintainer: Dominik Fischer +" Contributor: Leonard Ehrenfried +" Contributor: Karsten Hopp +" Contributor: Dean, Adam Kenneth +" Last Change: 2016 Dec 28 +" SSH Version: 7.4p1 +" + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=_,-,a-z,A-Z,48-57 + + +" case on +syn case match + + +" Comments +syn match sshconfigComment "^#.*$" contains=sshconfigTodo +syn match sshconfigComment "\s#.*$" contains=sshconfigTodo + +syn keyword sshconfigTodo TODO FIXME NOTE contained + + +" Constants +syn keyword sshconfigYesNo yes no ask confirm +syn keyword sshconfigYesNo any auto +syn keyword sshconfigYesNo force autoask none + +syn keyword sshconfigCipher 3des blowfish + +syn keyword sshconfigCiphers 3des-cbc +syn keyword sshconfigCiphers blowfish-cbc +syn keyword sshconfigCiphers cast128-cbc +syn keyword sshconfigCiphers arcfour +syn keyword sshconfigCiphers arcfour128 +syn keyword sshconfigCiphers arcfour256 +syn keyword sshconfigCiphers aes128-cbc +syn keyword sshconfigCiphers aes192-cbc +syn keyword sshconfigCiphers aes256-cbc +syn match sshconfigCiphers "\" +syn keyword sshconfigCiphers aes128-ctr +syn keyword sshconfigCiphers aes192-ctr +syn keyword sshconfigCiphers aes256-ctr +syn match sshconfigCiphers "\" +syn match sshconfigCiphers "\" +syn match sshconfigCiphers "\" + +syn keyword sshconfigMAC hmac-sha1 +syn keyword sshconfigMAC mac-sha1-96 +syn keyword sshconfigMAC mac-sha2-256 +syn keyword sshconfigMAC mac-sha2-512 +syn keyword sshconfigMAC mac-md5 +syn keyword sshconfigMAC mac-md5-96 +syn keyword sshconfigMAC mac-ripemd160 +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" +syn match sshconfigMAC "\" + +syn keyword sshconfigHostKeyAlgo ssh-ed25519 +syn match sshconfigHostKeyAlgo "\" +syn keyword sshconfigHostKeyAlgo ssh-rsa +syn keyword sshconfigHostKeyAlgo ssh-dss +syn keyword sshconfigHostKeyAlgo ecdsa-sha2-nistp256 +syn keyword sshconfigHostKeyAlgo ecdsa-sha2-nistp384 +syn keyword sshconfigHostKeyAlgo ecdsa-sha2-nistp521 +syn match sshconfigHostKeyAlgo "\" +syn match sshconfigHostKeyAlgo "\" +syn match sshconfigHostKeyAlgo "\" +syn match sshconfigHostKeyAlgo "\" +syn match sshconfigHostKeyAlgo "\" + +syn keyword sshconfigPreferredAuth hostbased publickey password gssapi-with-mic +syn keyword sshconfigPreferredAuth keyboard-interactive + +syn keyword sshconfigLogLevel QUIET FATAL ERROR INFO VERBOSE +syn keyword sshconfigLogLevel DEBUG DEBUG1 DEBUG2 DEBUG3 +syn keyword sshconfigSysLogFacility DAEMON USER AUTH AUTHPRIV LOCAL0 LOCAL1 +syn keyword sshconfigSysLogFacility LOCAL2 LOCAL3 LOCAL4 LOCAL5 LOCAL6 LOCAL7 +syn keyword sshconfigAddressFamily inet inet6 + +syn match sshconfigIPQoS "af1[123]" +syn match sshconfigIPQoS "af2[123]" +syn match sshconfigIPQoS "af3[123]" +syn match sshconfigIPQoS "af4[123]" +syn match sshconfigIPQoS "cs[0-7]" +syn keyword sshconfigIPQoS ef lowdelay throughput reliability +syn keyword sshconfigKbdInteractive bsdauth pam skey + +syn keyword sshconfigKexAlgo diffie-hellman-group1-sha1 +syn keyword sshconfigKexAlgo diffie-hellman-group14-sha1 +syn keyword sshconfigKexAlgo diffie-hellman-group-exchange-sha1 +syn keyword sshconfigKexAlgo diffie-hellman-group-exchange-sha256 +syn keyword sshconfigKexAlgo ecdh-sha2-nistp256 +syn keyword sshconfigKexAlgo ecdh-sha2-nistp384 +syn keyword sshconfigKexAlgo ecdh-sha2-nistp521 +syn match sshconfigKexAlgo "\" + +syn keyword sshconfigTunnel point-to-point ethernet + +syn match sshconfigVar "%[rhplLdun]\>" +syn match sshconfigSpecial "[*?]" +syn match sshconfigNumber "\d\+" +syn match sshconfigHostPort "\<\(\d\{1,3}\.\)\{3}\d\{1,3}\(:\d\+\)\?\>" +syn match sshconfigHostPort "\<\([-a-zA-Z0-9]\+\.\)\+[-a-zA-Z0-9]\{2,}\(:\d\+\)\?\>" +syn match sshconfigHostPort "\<\(\x\{,4}:\)\+\x\{,4}[:/]\d\+\>" +syn match sshconfigHostPort "\(Host \)\@<=.\+" +syn match sshconfigHostPort "\(HostName \)\@<=.\+" + +" case off +syn case ignore + + +" Keywords +syn keyword sshconfigHostSect Host + +syn keyword sshconfigMatch canonical exec host originalhost user localuser all + +syn keyword sshconfigKeyword AddressFamily +syn keyword sshconfigKeyword AddKeysToAgent +syn keyword sshconfigKeyword BatchMode +syn keyword sshconfigKeyword BindAddress +syn keyword sshconfigKeyword CanonicalDomains +syn keyword sshconfigKeyword CanonicalizeFallbackLocal +syn keyword sshconfigKeyword CanonicalizeHostname +syn keyword sshconfigKeyword CanonicalizeMaxDots +syn keyword sshconfigKeyword CertificateFile +syn keyword sshconfigKeyword ChallengeResponseAuthentication +syn keyword sshconfigKeyword CheckHostIP +syn keyword sshconfigKeyword Cipher +syn keyword sshconfigKeyword Ciphers +syn keyword sshconfigKeyword ClearAllForwardings +syn keyword sshconfigKeyword Compression +syn keyword sshconfigKeyword CompressionLevel +syn keyword sshconfigKeyword ConnectTimeout +syn keyword sshconfigKeyword ConnectionAttempts +syn keyword sshconfigKeyword ControlMaster +syn keyword sshconfigKeyword ControlPath +syn keyword sshconfigKeyword ControlPersist +syn keyword sshconfigKeyword DynamicForward +syn keyword sshconfigKeyword EnableSSHKeysign +syn keyword sshconfigKeyword EscapeChar +syn keyword sshconfigKeyword ExitOnForwardFailure +syn keyword sshconfigKeyword ForwardAgent +syn keyword sshconfigKeyword ForwardX11 +syn keyword sshconfigKeyword ForwardX11Timeout +syn keyword sshconfigKeyword ForwardX11Trusted +syn keyword sshconfigKeyword GSSAPIAuthentication +syn keyword sshconfigKeyword GSSAPIClientIdentity +syn keyword sshconfigKeyword GSSAPIDelegateCredentials +syn keyword sshconfigKeyword GSSAPIKeyExchange +syn keyword sshconfigKeyword GSSAPIRenewalForcesRekey +syn keyword sshconfigKeyword GSSAPIServerIdentity +syn keyword sshconfigKeyword GSSAPITrustDNS +syn keyword sshconfigKeyword GSSAPITrustDns +syn keyword sshconfigKeyword GatewayPorts +syn keyword sshconfigKeyword GlobalKnownHostsFile +syn keyword sshconfigKeyword HashKnownHosts +syn keyword sshconfigKeyword HostKeyAlgorithms +syn keyword sshconfigKeyword HostKeyAlias +syn keyword sshconfigKeyword HostName +syn keyword sshconfigKeyword HostbasedAuthentication +syn keyword sshconfigKeyword HostbasedKeyTypes +syn keyword sshconfigKeyword IPQoS +syn keyword sshconfigKeyword IdentitiesOnly +syn keyword sshconfigKeyword IdentityFile +syn keyword sshconfigKeyword IgnoreUnknown +syn keyword sshconfigKeyword Include +syn keyword sshconfigKeyword IPQoS +syn keyword sshconfigKeyword KbdInteractiveAuthentication +syn keyword sshconfigKeyword KbdInteractiveDevices +syn keyword sshconfigKeyword KexAlgorithms +syn keyword sshconfigKeyword LocalCommand +syn keyword sshconfigKeyword LocalForward +syn keyword sshconfigKeyword LogLevel +syn keyword sshconfigKeyword MACs +syn keyword sshconfigKeyword Match +syn keyword sshconfigKeyword NoHostAuthenticationForLocalhost +syn keyword sshconfigKeyword NumberOfPasswordPrompts +syn keyword sshconfigKeyword PKCS11Provider +syn keyword sshconfigKeyword PasswordAuthentication +syn keyword sshconfigKeyword PermitLocalCommand +syn keyword sshconfigKeyword Port +syn keyword sshconfigKeyword PreferredAuthentications +syn keyword sshconfigKeyword Protocol +syn keyword sshconfigKeyword ProxyCommand +syn keyword sshconfigKeyword ProxyJump +syn keyword sshconfigKeyword ProxyUseFDPass +syn keyword sshconfigKeyword PubkeyAcceptedKeyTypes +syn keyword sshconfigKeyword PubkeyAuthentication +syn keyword sshconfigKeyword RSAAuthentication +syn keyword sshconfigKeyword RekeyLimit +syn keyword sshconfigKeyword RemoteForward +syn keyword sshconfigKeyword RequestTTY +syn keyword sshconfigKeyword RhostsRSAAuthentication +syn keyword sshconfigKeyword SendEnv +syn keyword sshconfigKeyword ServerAliveCountMax +syn keyword sshconfigKeyword ServerAliveInterval +syn keyword sshconfigKeyword SmartcardDevice +syn keyword sshconfigKeyword StrictHostKeyChecking +syn keyword sshconfigKeyword TCPKeepAlive +syn keyword sshconfigKeyword Tunnel +syn keyword sshconfigKeyword TunnelDevice +syn keyword sshconfigKeyword UseBlacklistedKeys +syn keyword sshconfigKeyword UsePrivilegedPort +syn keyword sshconfigKeyword User +syn keyword sshconfigKeyword UserKnownHostsFile +syn keyword sshconfigKeyword UseRoaming +syn keyword sshconfigKeyword VerifyHostKeyDNS +syn keyword sshconfigKeyword VisualHostKey +syn keyword sshconfigKeyword XAuthLocation + +" Define the default highlighting + +hi def link sshconfigComment Comment +hi def link sshconfigTodo Todo +hi def link sshconfigHostPort sshconfigConstant +hi def link sshconfigNumber sshconfigConstant +hi def link sshconfigConstant Constant +hi def link sshconfigYesNo sshconfigEnum +hi def link sshconfigCipher sshconfigEnum +hi def link sshconfigCiphers sshconfigEnum +hi def link sshconfigMAC sshconfigEnum +hi def link sshconfigHostKeyAlgo sshconfigEnum +hi def link sshconfigLogLevel sshconfigEnum +hi def link sshconfigSysLogFacility sshconfigEnum +hi def link sshconfigAddressFamily sshconfigEnum +hi def link sshconfigIPQoS sshconfigEnum +hi def link sshconfigKbdInteractive sshconfigEnum +hi def link sshconfigKexAlgo sshconfigEnum +hi def link sshconfigTunnel sshconfigEnum +hi def link sshconfigPreferredAuth sshconfigEnum +hi def link sshconfigVar sshconfigEnum +hi def link sshconfigEnum Identifier +hi def link sshconfigSpecial Special +hi def link sshconfigKeyword Keyword +hi def link sshconfigHostSect Type +hi def link sshconfigMatch Type + +let b:current_syntax = "sshconfig" + +" vim:set ts=8 sw=2 sts=2: + +endif diff --git a/syntax/sshdconfig.vim b/syntax/sshdconfig.vim new file mode 100644 index 0000000..5ab1791 --- /dev/null +++ b/syntax/sshdconfig.vim @@ -0,0 +1,271 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: OpenSSH server configuration file (sshd_config) +" Author: David Necas (Yeti) +" Maintainer: Dominik Fischer +" Contributor: Thilo Six +" Contributor: Leonard Ehrenfried +" Contributor: Karsten Hopp +" Originally: 2009-07-09 +" Last Change: 2016 Dec 28 +" SSH Version: 7.4p1 +" + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal iskeyword=_,-,a-z,A-Z,48-57 + + +" case on +syn case match + + +" Comments +syn match sshdconfigComment "^#.*$" contains=sshdconfigTodo +syn match sshdconfigComment "\s#.*$" contains=sshdconfigTodo + +syn keyword sshdconfigTodo TODO FIXME NOTE contained + +" Constants +syn keyword sshdconfigYesNo yes no none + +syn keyword sshdconfigAddressFamily any inet inet6 + +syn keyword sshdconfigPrivilegeSeparation sandbox + +syn keyword sshdconfigTcpForwarding local remote + +syn keyword sshdconfigRootLogin prohibit-password without-password forced-commands-only + +syn keyword sshdconfigCiphers 3des-cbc +syn keyword sshdconfigCiphers blowfish-cbc +syn keyword sshdconfigCiphers cast128-cbc +syn keyword sshdconfigCiphers arcfour +syn keyword sshdconfigCiphers arcfour128 +syn keyword sshdconfigCiphers arcfour256 +syn keyword sshdconfigCiphers aes128-cbc +syn keyword sshdconfigCiphers aes192-cbc +syn keyword sshdconfigCiphers aes256-cbc +syn match sshdconfigCiphers "\" +syn keyword sshdconfigCiphers aes128-ctr +syn keyword sshdconfigCiphers aes192-ctr +syn keyword sshdconfigCiphers aes256-ctr +syn match sshdconfigCiphers "\" +syn match sshdconfigCiphers "\" +syn match sshdconfigCiphers "\" + +syn keyword sshdconfigMAC hmac-sha1 +syn keyword sshdconfigMAC mac-sha1-96 +syn keyword sshdconfigMAC mac-sha2-256 +syn keyword sshdconfigMAC mac-sha2-512 +syn keyword sshdconfigMAC mac-md5 +syn keyword sshdconfigMAC mac-md5-96 +syn keyword sshdconfigMAC mac-ripemd160 +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" +syn match sshdconfigMAC "\" + +syn keyword sshdconfigHostKeyAlgo ssh-ed25519 +syn match sshdconfigHostKeyAlgo "\" +syn keyword sshdconfigHostKeyAlgo ssh-rsa +syn keyword sshdconfigHostKeyAlgo ssh-dss +syn keyword sshdconfigHostKeyAlgo ecdsa-sha2-nistp256 +syn keyword sshdconfigHostKeyAlgo ecdsa-sha2-nistp384 +syn keyword sshdconfigHostKeyAlgo ecdsa-sha2-nistp521 +syn match sshdconfigHostKeyAlgo "\" +syn match sshdconfigHostKeyAlgo "\" +syn match sshdconfigHostKeyAlgo "\" +syn match sshdconfigHostKeyAlgo "\" +syn match sshdconfigHostKeyAlgo "\" + +syn keyword sshdconfigRootLogin prohibit-password without-password forced-commands-only + +syn keyword sshdconfigLogLevel QUIET FATAL ERROR INFO VERBOSE +syn keyword sshdconfigLogLevel DEBUG DEBUG1 DEBUG2 DEBUG3 +syn keyword sshdconfigSysLogFacility DAEMON USER AUTH AUTHPRIV LOCAL0 LOCAL1 +syn keyword sshdconfigSysLogFacility LOCAL2 LOCAL3 LOCAL4 LOCAL5 LOCAL6 LOCAL7 + +syn keyword sshdconfigCompression delayed + +syn match sshdconfigIPQoS "af1[123]" +syn match sshdconfigIPQoS "af2[123]" +syn match sshdconfigIPQoS "af3[123]" +syn match sshdconfigIPQoS "af4[123]" +syn match sshdconfigIPQoS "cs[0-7]" +syn keyword sshdconfigIPQoS ef lowdelay throughput reliability + +syn keyword sshdconfigKexAlgo diffie-hellman-group1-sha1 +syn keyword sshdconfigKexAlgo diffie-hellman-group14-sha1 +syn keyword sshdconfigKexAlgo diffie-hellman-group-exchange-sha1 +syn keyword sshdconfigKexAlgo diffie-hellman-group-exchange-sha256 +syn keyword sshdconfigKexAlgo ecdh-sha2-nistp256 +syn keyword sshdconfigKexAlgo ecdh-sha2-nistp384 +syn keyword sshdconfigKexAlgo ecdh-sha2-nistp521 +syn match sshdconfigKexAlgo "\" + +syn keyword sshdconfigTunnel point-to-point ethernet + +syn keyword sshdconfigSubsystem internal-sftp + +syn match sshdconfigVar "%[hu]\>" +syn match sshdconfigVar "%%" + +syn match sshdconfigSpecial "[*?]" + +syn match sshdconfigNumber "\d\+" +syn match sshdconfigHostPort "\<\(\d\{1,3}\.\)\{3}\d\{1,3}\(:\d\+\)\?\>" +syn match sshdconfigHostPort "\<\([-a-zA-Z0-9]\+\.\)\+[-a-zA-Z0-9]\{2,}\(:\d\+\)\?\>" +" FIXME: this matches quite a few things which are NOT valid IPv6 addresses +syn match sshdconfigHostPort "\<\(\x\{,4}:\)\+\x\{,4}:\d\+\>" +syn match sshdconfigTime "\<\(\d\+[sSmMhHdDwW]\)\+\>" + + +" case off +syn case ignore + + +" Keywords +syn keyword sshdconfigMatch Host User Group Address + +syn keyword sshdconfigKeyword AcceptEnv +syn keyword sshdconfigKeyword AddressFamily +syn keyword sshdconfigKeyword AllowAgentForwarding +syn keyword sshdconfigKeyword AllowGroups +syn keyword sshdconfigKeyword AllowStreamLocalForwarding +syn keyword sshdconfigKeyword AllowTcpForwarding +syn keyword sshdconfigKeyword AllowUsers +syn keyword sshdconfigKeyword AuthenticationMethods +syn keyword sshdconfigKeyword AuthorizedKeysFile +syn keyword sshdconfigKeyword AuthorizedKeysCommand +syn keyword sshdconfigKeyword AuthorizedKeysCommandUser +syn keyword sshdconfigKeyword AuthorizedPrincipalsFile +syn keyword sshdconfigKeyword Banner +syn keyword sshdconfigKeyword ChallengeResponseAuthentication +syn keyword sshdconfigKeyword ChrootDirectory +syn keyword sshdconfigKeyword Ciphers +syn keyword sshdconfigKeyword ClientAliveCountMax +syn keyword sshdconfigKeyword ClientAliveInterval +syn keyword sshdconfigKeyword Compression +syn keyword sshdconfigKeyword DebianBanner +syn keyword sshdconfigKeyword DenyGroups +syn keyword sshdconfigKeyword DenyUsers +syn keyword sshdconfigKeyword DisableForwarding +syn keyword sshdconfigKeyword ForceCommand +syn keyword sshdconfigKeyword GSSAPIAuthentication +syn keyword sshdconfigKeyword GSSAPICleanupCredentials +syn keyword sshdconfigKeyword GSSAPIKeyExchange +syn keyword sshdconfigKeyword GSSAPIStoreCredentialsOnRekey +syn keyword sshdconfigKeyword GSSAPIStrictAcceptorCheck +syn keyword sshdconfigKeyword GatewayPorts +syn keyword sshdconfigKeyword HostCertificate +syn keyword sshdconfigKeyword HostKey +syn keyword sshdconfigKeyword HostKeyAgent +syn keyword sshdconfigKeyword HostKeyAlgorithms +syn keyword sshdconfigKeyword HostbasedAcceptedKeyTypes +syn keyword sshdconfigKeyword HostbasedAuthentication +syn keyword sshdconfigKeyword HostbasedUsesNameFromPacketOnly +syn keyword sshdconfigKeyword IPQoS +syn keyword sshdconfigKeyword IgnoreRhosts +syn keyword sshdconfigKeyword IgnoreUserKnownHosts +syn keyword sshdconfigKeyword KbdInteractiveAuthentication +syn keyword sshdconfigKeyword KerberosAuthentication +syn keyword sshdconfigKeyword KerberosGetAFSToken +syn keyword sshdconfigKeyword KerberosOrLocalPasswd +syn keyword sshdconfigKeyword KerberosTicketCleanup +syn keyword sshdconfigKeyword KexAlgorithms +syn keyword sshdconfigKeyword KeyRegenerationInterval +syn keyword sshdconfigKeyword ListenAddress +syn keyword sshdconfigKeyword LogLevel +syn keyword sshdconfigKeyword LoginGraceTime +syn keyword sshdconfigKeyword MACs +syn keyword sshdconfigKeyword Match +syn keyword sshdconfigKeyword MaxAuthTries +syn keyword sshdconfigKeyword MaxSessions +syn keyword sshdconfigKeyword MaxStartups +syn keyword sshdconfigKeyword PasswordAuthentication +syn keyword sshdconfigKeyword PermitBlacklistedKeys +syn keyword sshdconfigKeyword PermitEmptyPasswords +syn keyword sshdconfigKeyword PermitOpen +syn keyword sshdconfigKeyword PermitRootLogin +syn keyword sshdconfigKeyword PermitTTY +syn keyword sshdconfigKeyword PermitTunnel +syn keyword sshdconfigKeyword PermitUserEnvironment +syn keyword sshdconfigKeyword PermitUserRC +syn keyword sshdconfigKeyword PidFile +syn keyword sshdconfigKeyword Port +syn keyword sshdconfigKeyword PrintLastLog +syn keyword sshdconfigKeyword PrintMotd +syn keyword sshdconfigKeyword Protocol +syn keyword sshdconfigKeyword PubkeyAcceptedKeyTypes +syn keyword sshdconfigKeyword PubkeyAuthentication +syn keyword sshdconfigKeyword RSAAuthentication +syn keyword sshdconfigKeyword RekeyLimit +syn keyword sshdconfigKeyword RevokedKeys +syn keyword sshdconfigKeyword RhostsRSAAuthentication +syn keyword sshdconfigKeyword ServerKeyBits +syn keyword sshdconfigKeyword ShowPatchLevel +syn keyword sshdconfigKeyword StrictModes +syn keyword sshdconfigKeyword Subsystem +syn keyword sshdconfigKeyword SyslogFacility +syn keyword sshdconfigKeyword TCPKeepAlive +syn keyword sshdconfigKeyword TrustedUserCAKeys +syn keyword sshdconfigKeyword UseDNS +syn keyword sshdconfigKeyword UseLogin +syn keyword sshdconfigKeyword UsePAM +syn keyword sshdconfigKeyword UsePrivilegeSeparation +syn keyword sshdconfigKeyword VersionAddendum +syn keyword sshdconfigKeyword X11DisplayOffset +syn keyword sshdconfigKeyword X11Forwarding +syn keyword sshdconfigKeyword X11UseLocalhost +syn keyword sshdconfigKeyword XAuthLocation + + +" Define the default highlighting + +hi def link sshdconfigComment Comment +hi def link sshdconfigTodo Todo +hi def link sshdconfigHostPort sshdconfigConstant +hi def link sshdconfigTime sshdconfigConstant +hi def link sshdconfigNumber sshdconfigConstant +hi def link sshdconfigConstant Constant +hi def link sshdconfigYesNo sshdconfigEnum +hi def link sshdconfigAddressFamily sshdconfigEnum +hi def link sshdconfigPrivilegeSeparation sshdconfigEnum +hi def link sshdconfigTcpForwarding sshdconfigEnum +hi def link sshdconfigRootLogin sshdconfigEnum +hi def link sshdconfigCiphers sshdconfigEnum +hi def link sshdconfigMAC sshdconfigEnum +hi def link sshdconfigHostKeyAlgo sshdconfigEnum +hi def link sshdconfigRootLogin sshdconfigEnum +hi def link sshdconfigLogLevel sshdconfigEnum +hi def link sshdconfigSysLogFacility sshdconfigEnum +hi def link sshdconfigVar sshdconfigEnum +hi def link sshdconfigCompression sshdconfigEnum +hi def link sshdconfigIPQoS sshdconfigEnum +hi def link sshdconfigKexAlgo sshdconfigEnum +hi def link sshdconfigTunnel sshdconfigEnum +hi def link sshdconfigSubsystem sshdconfigEnum +hi def link sshdconfigEnum Function +hi def link sshdconfigSpecial Special +hi def link sshdconfigKeyword Keyword +hi def link sshdconfigMatch Type + +let b:current_syntax = "sshdconfig" + +" vim:set ts=8 sw=2 sts=2: + +endif diff --git a/syntax/st.vim b/syntax/st.vim new file mode 100644 index 0000000..9e0a2d2 --- /dev/null +++ b/syntax/st.vim @@ -0,0 +1,99 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Smalltalk +" Maintainer: Arndt Hesse +" Last Change: 2012 Feb 12 by Thilo Six + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" some Smalltalk keywords and standard methods +syn keyword stKeyword super self class true false new not +syn keyword stKeyword notNil isNil inspect out nil +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" +syn match stMethod "\:" + +" the block of local variables of a method +syn region stLocalVariables start="^[ \t]*|" end="|" + +" the Smalltalk comment +syn region stComment start="\"" end="\"" + +" the Smalltalk strings and single characters +syn region stString start='\'' skip="''" end='\'' +syn match stCharacter "$." + +syn case ignore + +" the symols prefixed by a '#' +syn match stSymbol "\(#\<[a-z_][a-z0-9_]*\>\)" +syn match stSymbol "\(#'[^']*'\)" + +" the variables in a statement block for loops +syn match stBlockVariable "\(:[ \t]*\<[a-z_][a-z0-9_]*\>[ \t]*\)\+|" contained + +" some representations of numbers +syn match stNumber "\<\d\+\(u\=l\=\|lu\|f\)\>" +syn match stFloat "\<\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=\>" +syn match stFloat "\<\d\+e[-+]\=\d\+[fl]\=\>" + +syn case match + +" a try to higlight paren mismatches +syn region stParen transparent start='(' end=')' contains=ALLBUT,stParenError +syn match stParenError ")" +syn region stBlock transparent start='\[' end='\]' contains=ALLBUT,stBlockError +syn match stBlockError "\]" +syn region stSet transparent start='{' end='}' contains=ALLBUT,stSetError +syn match stSetError "}" + +hi link stParenError stError +hi link stSetError stError +hi link stBlockError stError + +" synchronization for syntax analysis +syn sync minlines=50 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link stKeyword Statement +hi def link stMethod Statement +hi def link stComment Comment +hi def link stCharacter Constant +hi def link stString Constant +hi def link stSymbol Special +hi def link stNumber Type +hi def link stFloat Type +hi def link stError Error +hi def link stLocalVariables Identifier +hi def link stBlockVariable Identifier + + +let b:current_syntax = "st" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/stata.vim b/syntax/stata.vim new file mode 100644 index 0000000..9adf28f --- /dev/null +++ b/syntax/stata.vim @@ -0,0 +1,454 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" stata.vim -- Vim syntax file for Stata do, ado, and class files. +" Language: Stata and/or Mata +" Maintainer: Jeff Pitblado +" Last Change: 26apr2006 +" Version: 1.1.4 + +" Log: +" 14apr2006 renamed syntax groups st* to stata* +" 'syntax clear' only under version control +" check for 'b:current_syntax', removed 'did_stata_syntax_inits' +" 17apr2006 fixed start expression for stataFunc +" 26apr2006 fixed brace confusion in stataErrInParen and stataErrInBracket +" fixed paren/bracket confusion in stataFuncGroup + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syntax case match + +" comments - single line +" note that the triple slash continuing line comment comes free +syn region stataStarComment start=/^\s*\*/ end=/$/ contains=stataComment oneline +syn region stataSlashComment start="\s//" end=/$/ contains=stataComment oneline +syn region stataSlashComment start="^//" end=/$/ contains=stataComment oneline +" comments - multiple line +syn region stataComment start="/\*" end="\*/" contains=stataComment + +" global macros - simple case +syn match stataGlobal /\$\a\w*/ +" global macros - general case +syn region stataGlobal start=/\${/ end=/}/ oneline contains=@stataMacroGroup +" local macros - general case +syn region stataLocal start=/`/ end=/'/ oneline contains=@stataMacroGroup + +" numeric formats +syn match stataFormat /%-\=\d\+\.\d\+[efg]c\=/ +" numeric hex format +syn match stataFormat /%-\=21x/ +" string format +syn match stataFormat /%\(\|-\|\~\)\d\+s/ + +" Statements +syn keyword stataConditional else if +syn keyword stataRepeat foreach +syn keyword stataRepeat forv[alues] +syn keyword stataRepeat while + +" Common programming commands +syn keyword stataCommand about +syn keyword stataCommand adopath +syn keyword stataCommand adoupdate +syn keyword stataCommand assert +syn keyword stataCommand break +syn keyword stataCommand by +syn keyword stataCommand cap[ture] +syn keyword stataCommand cd +syn keyword stataCommand chdir +syn keyword stataCommand checksum +syn keyword stataCommand class +syn keyword stataCommand classutil +syn keyword stataCommand compress +syn keyword stataCommand conf[irm] +syn keyword stataCommand conren +syn keyword stataCommand continue +syn keyword stataCommand cou[nt] +syn keyword stataCommand cscript +syn keyword stataCommand cscript_log +syn keyword stataCommand #delimit +syn keyword stataCommand d[escribe] +syn keyword stataCommand dir +syn keyword stataCommand discard +syn keyword stataCommand di[splay] +syn keyword stataCommand do +syn keyword stataCommand doedit +syn keyword stataCommand drop +syn keyword stataCommand edit +syn keyword stataCommand end +syn keyword stataCommand erase +syn keyword stataCommand eret[urn] +syn keyword stataCommand err[or] +syn keyword stataCommand e[xit] +syn keyword stataCommand expand +syn keyword stataCommand expandcl +syn keyword stataCommand file +syn keyword stataCommand findfile +syn keyword stataCommand format +syn keyword stataCommand g[enerate] +syn keyword stataCommand gettoken +syn keyword stataCommand gl[obal] +syn keyword stataCommand help +syn keyword stataCommand hexdump +syn keyword stataCommand include +syn keyword stataCommand infile +syn keyword stataCommand infix +syn keyword stataCommand input +syn keyword stataCommand insheet +syn keyword stataCommand joinby +syn keyword stataCommand la[bel] +syn keyword stataCommand levelsof +syn keyword stataCommand list +syn keyword stataCommand loc[al] +syn keyword stataCommand log +syn keyword stataCommand ma[cro] +syn keyword stataCommand mark +syn keyword stataCommand markout +syn keyword stataCommand marksample +syn keyword stataCommand mata +syn keyword stataCommand matrix +syn keyword stataCommand memory +syn keyword stataCommand merge +syn keyword stataCommand mkdir +syn keyword stataCommand more +syn keyword stataCommand net +syn keyword stataCommand nobreak +syn keyword stataCommand n[oisily] +syn keyword stataCommand note[s] +syn keyword stataCommand numlist +syn keyword stataCommand outfile +syn keyword stataCommand outsheet +syn keyword stataCommand _parse +syn keyword stataCommand pause +syn keyword stataCommand plugin +syn keyword stataCommand post +syn keyword stataCommand postclose +syn keyword stataCommand postfile +syn keyword stataCommand preserve +syn keyword stataCommand print +syn keyword stataCommand printer +syn keyword stataCommand profiler +syn keyword stataCommand pr[ogram] +syn keyword stataCommand q[uery] +syn keyword stataCommand qui[etly] +syn keyword stataCommand rcof +syn keyword stataCommand reg[ress] +syn keyword stataCommand rename +syn keyword stataCommand repeat +syn keyword stataCommand replace +syn keyword stataCommand reshape +syn keyword stataCommand ret[urn] +syn keyword stataCommand _rmcoll +syn keyword stataCommand _rmcoll +syn keyword stataCommand _rmcollright +syn keyword stataCommand rmdir +syn keyword stataCommand _robust +syn keyword stataCommand save +syn keyword stataCommand sca[lar] +syn keyword stataCommand search +syn keyword stataCommand serset +syn keyword stataCommand set +syn keyword stataCommand shell +syn keyword stataCommand sleep +syn keyword stataCommand sort +syn keyword stataCommand split +syn keyword stataCommand sret[urn] +syn keyword stataCommand ssc +syn keyword stataCommand su[mmarize] +syn keyword stataCommand syntax +syn keyword stataCommand sysdescribe +syn keyword stataCommand sysdir +syn keyword stataCommand sysuse +syn keyword stataCommand token[ize] +syn keyword stataCommand translate +syn keyword stataCommand type +syn keyword stataCommand unab +syn keyword stataCommand unabcmd +syn keyword stataCommand update +syn keyword stataCommand use +syn keyword stataCommand vers[ion] +syn keyword stataCommand view +syn keyword stataCommand viewsource +syn keyword stataCommand webdescribe +syn keyword stataCommand webseek +syn keyword stataCommand webuse +syn keyword stataCommand which +syn keyword stataCommand who +syn keyword stataCommand window + +" Literals +syn match stataQuote /"/ +syn region stataEString matchgroup=Nothing start=/`"/ end=/"'/ oneline contains=@stataMacroGroup,stataQuote,stataString,stataEString +syn region stataString matchgroup=Nothing start=/"/ end=/"/ oneline contains=@stataMacroGroup + +" define clusters +syn cluster stataFuncGroup contains=@stataMacroGroup,stataFunc,stataString,stataEstring,stataParen,stataBracket +syn cluster stataMacroGroup contains=stataGlobal,stataLocal +syn cluster stataParenGroup contains=stataParenError,stataBracketError,stataBraceError,stataSpecial,stataFormat + +" Stata functions +" Math +syn region stataFunc matchgroup=Function start=/\" + +" Conditional. +syn keyword stpConditional if else elseif then +syn match stpConditional "\" + +" Repeats. +syn keyword stpRepeat for while loop +syn match stpRepeat "\" + +" Operators. +syn keyword stpOperator asc not and or desc group having in is any some all +syn keyword stpOperator between exists like escape with union intersect minus +syn keyword stpOperator out prior distinct sysdate + +" Statements. +syn keyword stpStatement alter analyze as audit avg by close clustered comment +syn keyword stpStatement commit continue count create cursor declare delete +syn keyword stpStatement drop exec execute explain fetch from index insert +syn keyword stpStatement into lock max min next noaudit nonclustered open +syn keyword stpStatement order output print raiserror recompile rename revoke +syn keyword stpStatement rollback savepoint select set sum transaction +syn keyword stpStatement truncate unique update values where + +" Functions. +syn keyword stpFunction abs acos ascii asin atan atn2 avg ceiling charindex +syn keyword stpFunction charlength convert col_name col_length cos cot count +syn keyword stpFunction curunreservedpgs datapgs datalength dateadd datediff +syn keyword stpFunction datename datepart db_id db_name degree difference +syn keyword stpFunction exp floor getdate hextoint host_id host_name index_col +syn keyword stpFunction inttohex isnull lct_admin log log10 lower ltrim max +syn keyword stpFunction min now object_id object_name patindex pi pos power +syn keyword stpFunction proc_role radians rand replace replicate reserved_pgs +syn keyword stpFunction reverse right rtrim rowcnt round show_role sign sin +syn keyword stpFunction soundex space sqrt str stuff substr substring sum +syn keyword stpFunction suser_id suser_name tan tsequal upper used_pgs user +syn keyword stpFunction user_id user_name valid_name valid_user message + +" Types. +syn keyword stpType binary bit char datetime decimal double float image +syn keyword stpType int integer long money nchar numeric precision real +syn keyword stpType smalldatetime smallint smallmoney text time tinyint +syn keyword stpType timestamp varbinary varchar + +" Globals. +syn match stpGlobals '@@char_convert' +syn match stpGlobals '@@cient_csname' +syn match stpGlobals '@@client_csid' +syn match stpGlobals '@@connections' +syn match stpGlobals '@@cpu_busy' +syn match stpGlobals '@@error' +syn match stpGlobals '@@identity' +syn match stpGlobals '@@idle' +syn match stpGlobals '@@io_busy' +syn match stpGlobals '@@isolation' +syn match stpGlobals '@@langid' +syn match stpGlobals '@@language' +syn match stpGlobals '@@max_connections' +syn match stpGlobals '@@maxcharlen' +syn match stpGlobals '@@ncharsize' +syn match stpGlobals '@@nestlevel' +syn match stpGlobals '@@pack_received' +syn match stpGlobals '@@pack_sent' +syn match stpGlobals '@@packet_errors' +syn match stpGlobals '@@procid' +syn match stpGlobals '@@rowcount' +syn match stpGlobals '@@servername' +syn match stpGlobals '@@spid' +syn match stpGlobals '@@sqlstatus' +syn match stpGlobals '@@testts' +syn match stpGlobals '@@textcolid' +syn match stpGlobals '@@textdbid' +syn match stpGlobals '@@textobjid' +syn match stpGlobals '@@textptr' +syn match stpGlobals '@@textsize' +syn match stpGlobals '@@thresh_hysteresis' +syn match stpGlobals '@@timeticks' +syn match stpGlobals '@@total_error' +syn match stpGlobals '@@total_read' +syn match stpGlobals '@@total_write' +syn match stpGlobals '@@tranchained' +syn match stpGlobals '@@trancount' +syn match stpGlobals '@@transtate' +syn match stpGlobals '@@version' + +" Todos. +syn keyword stpTodo TODO FIXME XXX DEBUG NOTE + +" Strings and characters. +syn match stpStringError "'.*$" +syn match stpString "'\([^']\|''\)*'" + +" Numbers. +syn match stpNumber "-\=\<\d*\.\=[0-9_]\>" + +" Comments. +syn region stpComment start="/\*" end="\*/" contains=stpTodo +syn match stpComment "--.*" contains=stpTodo +syn sync ccomment stpComment + +" Parens. +syn region stpParen transparent start='(' end=')' contains=ALLBUT,stpParenError +syn match stpParenError ")" + +" Syntax Synchronizing. +syn sync minlines=10 maxlines=100 + +" Define the default highlighting. +" Only when and item doesn't have highlighting yet. + +hi def link stpConditional Conditional +hi def link stpComment Comment +hi def link stpKeyword Keyword +hi def link stpNumber Number +hi def link stpOperator Operator +hi def link stpSpecial Special +hi def link stpStatement Statement +hi def link stpString String +hi def link stpStringError Error +hi def link stpType Type +hi def link stpTodo Todo +hi def link stpFunction Function +hi def link stpGlobals Macro +hi def link stpParen Normal +hi def link stpParenError Error +hi def link stpSQLKeyword Function +hi def link stpRepeat Repeat + + +let b:current_syntax = "stp" + +" vim ts=8 sw=2 + +endif diff --git a/syntax/strace.vim b/syntax/strace.vim new file mode 100644 index 0000000..450cb47 --- /dev/null +++ b/syntax/strace.vim @@ -0,0 +1,57 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" This is a GENERATED FILE. Please always refer to source file at the URI below. +" Language: strace output +" Maintainer: David Necas (Yeti) +" Last Change: 2015-01-16 + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +" Parse the line +syn match straceSpecialChar "\\\o\{1,3}\|\\." contained +syn region straceString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=straceSpecialChar oneline +syn match straceNumber "\W[+-]\=\(\d\+\)\=\.\=\d\+\([eE][+-]\=\d\+\)\="lc=1 +syn match straceNumber "\W0x\x\+"lc=1 +syn match straceNumberRHS "\W\(0x\x\+\|-\=\d\+\)"lc=1 contained +syn match straceOtherRHS "?" contained +syn match straceConstant "[A-Z_]\{2,}" +syn region straceVerbosed start="(" end=")" matchgroup=Normal contained oneline +syn region straceReturned start="\s=\s" end="$" contains=StraceEquals,straceNumberRHS,straceOtherRHS,straceConstant,straceVerbosed oneline transparent +syn match straceEquals "\s=\s"ms=s+1,me=e-1 +syn match straceParenthesis "[][(){}]" +syn match straceSysCall "^\w\+" +syn match straceOtherPID "^\[[^]]*\]" contains=stracePID,straceNumber nextgroup=straceSysCallEmbed skipwhite +syn match straceSysCallEmbed "\w\+" contained +syn keyword stracePID pid contained +syn match straceOperator "[-+=*/!%&|:,]" +syn region straceComment start="/\*" end="\*/" oneline + +" Define the default highlighting + +hi def link straceComment Comment +hi def link straceVerbosed Comment +hi def link stracePID PreProc +hi def link straceNumber Number +hi def link straceNumberRHS Type +hi def link straceOtherRHS Type +hi def link straceString String +hi def link straceConstant Function +hi def link straceEquals Type +hi def link straceSysCallEmbed straceSysCall +hi def link straceSysCall Statement +hi def link straceParenthesis Statement +hi def link straceOperator Normal +hi def link straceSpecialChar Special +hi def link straceOtherPID PreProc + + +let b:current_syntax = "strace" + +endif diff --git a/syntax/sudoers.vim b/syntax/sudoers.vim new file mode 100644 index 0000000..c62b940 --- /dev/null +++ b/syntax/sudoers.vim @@ -0,0 +1,346 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sudoers(5) configuration files +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2011-02-24 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" TODO: instead of 'skipnl', we would like to match a specific group that would +" match \\$ and then continue with the nextgroup, actually, the skipnl doesn't +" work... +" TODO: treat 'ALL' like a special (yay, a bundle of new rules!!!) + +syn match sudoersUserSpec '^' nextgroup=@sudoersUserInSpec skipwhite + +syn match sudoersSpecEquals contained '=' nextgroup=@sudoersCmndSpecList skipwhite + +syn cluster sudoersCmndSpecList contains=sudoersUserRunasBegin,sudoersPASSWD,@sudoersCmndInSpec + +syn keyword sudoersTodo contained TODO FIXME XXX NOTE + +syn region sudoersComment display oneline start='#' end='$' contains=sudoersTodo + +syn keyword sudoersAlias User_Alias Runas_Alias nextgroup=sudoersUserAlias skipwhite skipnl +syn keyword sudoersAlias Host_Alias nextgroup=sudoersHostAlias skipwhite skipnl +syn keyword sudoersAlias Cmnd_Alias nextgroup=sudoersCmndAlias skipwhite skipnl + +syn match sudoersUserAlias contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersUserAliasEquals skipwhite skipnl +syn match sudoersUserNameInList contained '\<\l\+\>' nextgroup=@sudoersUserList skipwhite skipnl +syn match sudoersUIDInList contained '#\d\+\>' nextgroup=@sudoersUserList skipwhite skipnl +syn match sudoersGroupInList contained '%\l\+\>' nextgroup=@sudoersUserList skipwhite skipnl +syn match sudoersUserNetgroupInList contained '+\l\+\>' nextgroup=@sudoersUserList skipwhite skipnl +syn match sudoersUserAliasInList contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersUserList skipwhite skipnl + +syn match sudoersUserName contained '\<\l\+\>' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersUID contained '#\d\+\>' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersGroup contained '%\l\+\>' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersUserNetgroup contained '+\l\+\>' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersUserAliasRef contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersParameter skipwhite skipnl + +syn match sudoersUserNameInSpec contained '\<\l\+\>' nextgroup=@sudoersUserSpec skipwhite skipnl +syn match sudoersUIDInSpec contained '#\d\+\>' nextgroup=@sudoersUserSpec skipwhite skipnl +syn match sudoersGroupInSpec contained '%\l\+\>' nextgroup=@sudoersUserSpec skipwhite skipnl +syn match sudoersUserNetgroupInSpec contained '+\l\+\>' nextgroup=@sudoersUserSpec skipwhite skipnl +syn match sudoersUserAliasInSpec contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersUserSpec skipwhite skipnl + +syn match sudoersUserNameInRunas contained '\<\l\+\>' nextgroup=@sudoersUserRunas skipwhite skipnl +syn match sudoersUIDInRunas contained '#\d\+\>' nextgroup=@sudoersUserRunas skipwhite skipnl +syn match sudoersGroupInRunas contained '%\l\+\>' nextgroup=@sudoersUserRunas skipwhite skipnl +syn match sudoersUserNetgroupInRunas contained '+\l\+\>' nextgroup=@sudoersUserRunas skipwhite skipnl +syn match sudoersUserAliasInRunas contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersUserRunas skipwhite skipnl + +syn match sudoersHostAlias contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersHostAliasEquals skipwhite skipnl +syn match sudoersHostNameInList contained '\<\l\+\>' nextgroup=@sudoersHostList skipwhite skipnl +syn match sudoersIPAddrInList contained '\%(\d\{1,3}\.\)\{3}\d\{1,3}' nextgroup=@sudoersHostList skipwhite skipnl +syn match sudoersNetworkInList contained '\%(\d\{1,3}\.\)\{3}\d\{1,3}\%(/\%(\%(\d\{1,3}\.\)\{3}\d\{1,3}\|\d\+\)\)\=' nextgroup=@sudoersHostList skipwhite skipnl +syn match sudoersHostNetgroupInList contained '+\l\+\>' nextgroup=@sudoersHostList skipwhite skipnl +syn match sudoersHostAliasInList contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersHostList skipwhite skipnl + +syn match sudoersHostName contained '\<\l\+\>' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersIPAddr contained '\%(\d\{1,3}\.\)\{3}\d\{1,3}' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersNetwork contained '\%(\d\{1,3}\.\)\{3}\d\{1,3}\%(/\%(\%(\d\{1,3}\.\)\{3}\d\{1,3}\|\d\+\)\)\=' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersHostNetgroup contained '+\l\+\>' nextgroup=@sudoersParameter skipwhite skipnl +syn match sudoersHostAliasRef contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersParameter skipwhite skipnl + +syn match sudoersHostNameInSpec contained '\<\l\+\>' nextgroup=@sudoersHostSpec skipwhite skipnl +syn match sudoersIPAddrInSpec contained '\%(\d\{1,3}\.\)\{3}\d\{1,3}' nextgroup=@sudoersHostSpec skipwhite skipnl +syn match sudoersNetworkInSpec contained '\%(\d\{1,3}\.\)\{3}\d\{1,3}\%(/\%(\%(\d\{1,3}\.\)\{3}\d\{1,3}\|\d\+\)\)\=' nextgroup=@sudoersHostSpec skipwhite skipnl +syn match sudoersHostNetgroupInSpec contained '+\l\+\>' nextgroup=@sudoersHostSpec skipwhite skipnl +syn match sudoersHostAliasInSpec contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersHostSpec skipwhite skipnl + +syn match sudoersCmndAlias contained '\<\u[A-Z0-9_]*\>' nextgroup=sudoersCmndAliasEquals skipwhite skipnl +syn match sudoersCmndNameInList contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=@sudoersCmndList,sudoersCommandEmpty,sudoersCommandArgs skipwhite +syn match sudoersCmndAliasInList contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersCmndList skipwhite skipnl + +syn match sudoersCmndNameInSpec contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=@sudoersCmndSpec,sudoersCommandEmptyInSpec,sudoersCommandArgsInSpec skipwhite +syn match sudoersCmndAliasInSpec contained '\<\u[A-Z0-9_]*\>' nextgroup=@sudoersCmndSpec skipwhite skipnl + +syn match sudoersUserAliasEquals contained '=' nextgroup=@sudoersUserInList skipwhite skipnl +syn match sudoersUserListComma contained ',' nextgroup=@sudoersUserInList skipwhite skipnl +syn match sudoersUserListColon contained ':' nextgroup=sudoersUserAlias skipwhite skipnl +syn cluster sudoersUserList contains=sudoersUserListComma,sudoersUserListColon + +syn match sudoersUserSpecComma contained ',' nextgroup=@sudoersUserInSpec skipwhite skipnl +syn cluster sudoersUserSpec contains=sudoersUserSpecComma,@sudoersHostInSpec + +syn match sudoersUserRunasBegin contained '(' nextgroup=@sudoersUserInRunas skipwhite skipnl +syn match sudoersUserRunasComma contained ',' nextgroup=@sudoersUserInRunas skipwhite skipnl +syn match sudoersUserRunasEnd contained ')' nextgroup=sudoersPASSWD,@sudoersCmndInSpec skipwhite skipnl +syn cluster sudoersUserRunas contains=sudoersUserRunasComma,@sudoersUserInRunas,sudoersUserRunasEnd + + +syn match sudoersHostAliasEquals contained '=' nextgroup=@sudoersHostInList skipwhite skipnl +syn match sudoersHostListComma contained ',' nextgroup=@sudoersHostInList skipwhite skipnl +syn match sudoersHostListColon contained ':' nextgroup=sudoersHostAlias skipwhite skipnl +syn cluster sudoersHostList contains=sudoersHostListComma,sudoersHostListColon + +syn match sudoersHostSpecComma contained ',' nextgroup=@sudoersHostInSpec skipwhite skipnl +syn cluster sudoersHostSpec contains=sudoersHostSpecComma,sudoersSpecEquals + + +syn match sudoersCmndAliasEquals contained '=' nextgroup=@sudoersCmndInList skipwhite skipnl +syn match sudoersCmndListComma contained ',' nextgroup=@sudoersCmndInList skipwhite skipnl +syn match sudoersCmndListColon contained ':' nextgroup=sudoersCmndAlias skipwhite skipnl +syn cluster sudoersCmndList contains=sudoersCmndListComma,sudoersCmndListColon + +syn match sudoersCmndSpecComma contained ',' nextgroup=@sudoersCmndSpecList skipwhite skipnl +syn match sudoersCmndSpecColon contained ':' nextgroup=@sudoersUserInSpec skipwhite skipnl +syn cluster sudoersCmndSpec contains=sudoersCmndSpecComma,sudoersCmndSpecColon + +syn cluster sudoersUserInList contains=sudoersUserNegationInList,sudoersUserNameInList,sudoersUIDInList,sudoersGroupInList,sudoersUserNetgroupInList,sudoersUserAliasInList +syn cluster sudoersHostInList contains=sudoersHostNegationInList,sudoersHostNameInList,sudoersIPAddrInList,sudoersNetworkInList,sudoersHostNetgroupInList,sudoersHostAliasInList +syn cluster sudoersCmndInList contains=sudoersCmndNegationInList,sudoersCmndNameInList,sudoersCmndAliasInList + +syn cluster sudoersUser contains=sudoersUserNegation,sudoersUserName,sudoersUID,sudoersGroup,sudoersUserNetgroup,sudoersUserAliasRef +syn cluster sudoersHost contains=sudoersHostNegation,sudoersHostName,sudoersIPAddr,sudoersNetwork,sudoersHostNetgroup,sudoersHostAliasRef + +syn cluster sudoersUserInSpec contains=sudoersUserNegationInSpec,sudoersUserNameInSpec,sudoersUIDInSpec,sudoersGroupInSpec,sudoersUserNetgroupInSpec,sudoersUserAliasInSpec +syn cluster sudoersHostInSpec contains=sudoersHostNegationInSpec,sudoersHostNameInSpec,sudoersIPAddrInSpec,sudoersNetworkInSpec,sudoersHostNetgroupInSpec,sudoersHostAliasInSpec +syn cluster sudoersUserInRunas contains=sudoersUserNegationInRunas,sudoersUserNameInRunas,sudoersUIDInRunas,sudoersGroupInRunas,sudoersUserNetgroupInRunas,sudoersUserAliasInRunas +syn cluster sudoersCmndInSpec contains=sudoersCmndNegationInSpec,sudoersCmndNameInSpec,sudoersCmndAliasInSpec + +syn match sudoersUserNegationInList contained '!\+' nextgroup=@sudoersUserInList skipwhite skipnl +syn match sudoersHostNegationInList contained '!\+' nextgroup=@sudoersHostInList skipwhite skipnl +syn match sudoersCmndNegationInList contained '!\+' nextgroup=@sudoersCmndInList skipwhite skipnl + +syn match sudoersUserNegation contained '!\+' nextgroup=@sudoersUser skipwhite skipnl +syn match sudoersHostNegation contained '!\+' nextgroup=@sudoersHost skipwhite skipnl + +syn match sudoersUserNegationInSpec contained '!\+' nextgroup=@sudoersUserInSpec skipwhite skipnl +syn match sudoersHostNegationInSpec contained '!\+' nextgroup=@sudoersHostInSpec skipwhite skipnl +syn match sudoersUserNegationInRunas contained '!\+' nextgroup=@sudoersUserInRunas skipwhite skipnl +syn match sudoersCmndNegationInSpec contained '!\+' nextgroup=@sudoersCmndInSpec skipwhite skipnl + +syn match sudoersCommandArgs contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersCommandArgs,@sudoersCmndList skipwhite +syn match sudoersCommandEmpty contained '""' nextgroup=@sudoersCmndList skipwhite skipnl + +syn match sudoersCommandArgsInSpec contained '[^[:space:],:=\\]\+\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersCommandArgsInSpec,@sudoersCmndSpec skipwhite +syn match sudoersCommandEmptyInSpec contained '""' nextgroup=@sudoersCmndSpec skipwhite skipnl + +syn keyword sudoersDefaultEntry Defaults nextgroup=sudoersDefaultTypeAt,sudoersDefaultTypeColon,sudoersDefaultTypeGreaterThan,@sudoersParameter skipwhite skipnl +syn match sudoersDefaultTypeAt contained '@' nextgroup=@sudoersHost skipwhite skipnl +syn match sudoersDefaultTypeColon contained ':' nextgroup=@sudoersUser skipwhite skipnl +syn match sudoersDefaultTypeGreaterThan contained '>' nextgroup=@sudoersUser skipwhite skipnl + +" TODO: could also deal with special characters here +syn match sudoersBooleanParameter contained '!' nextgroup=sudoersBooleanParameter skipwhite skipnl +syn keyword sudoersBooleanParameter contained skipwhite skipnl + \ always_set_home + \ authenticate + \ closefrom_override + \ env_editor + \ env_reset + \ fqdn + \ ignore_dot + \ ignore_local_sudoers + \ insults + \ log_host + \ log_year + \ long_otp_prompt + \ mail_always + \ mail_badpass + \ mail_no_host + \ mail_no_perms + \ mail_no_user + \ noexec + \ path_info + \ passprompt_override + \ preserve_groups + \ requiretty + \ root_sudo + \ rootpw + \ runaspw + \ set_home + \ set_logname + \ setenv + \ shell_noargs + \ stay_setuid + \ targetpw + \ tty_tickets + \ visiblepw + +syn keyword sudoersIntegerParameter contained + \ nextgroup=sudoersIntegerParameterEquals + \ skipwhite skipnl + \ closefrom + \ passwd_tries + \ loglinelen + \ passwd_timeout + \ timestamp_timeout + \ umask + +syn keyword sudoersStringParameter contained + \ nextgroup=sudoersStringParameterEquals + \ skipwhite skipnl + \ badpass_message + \ editor + \ mailsub + \ noexec_file + \ passprompt + \ runas_default + \ syslog_badpri + \ syslog_goodpri + \ sudoers_locale + \ timestampdir + \ timestampowner + \ askpass + \ env_file + \ exempt_group + \ lecture + \ lecture_file + \ listpw + \ logfile + \ mailerflags + \ mailerpath + \ mailfrom + \ mailto + \ secure_path + \ syslog + \ verifypw + +syn keyword sudoersListParameter contained + \ nextgroup=sudoersListParameterEquals + \ skipwhite skipnl + \ env_check + \ env_delete + \ env_keep + +syn match sudoersParameterListComma contained ',' nextgroup=@sudoersParameter skipwhite skipnl + +syn cluster sudoersParameter contains=sudoersBooleanParameter,sudoersIntegerParameter,sudoersStringParameter,sudoersListParameter + +syn match sudoersIntegerParameterEquals contained '[+-]\==' nextgroup=sudoersIntegerValue skipwhite skipnl +syn match sudoersStringParameterEquals contained '[+-]\==' nextgroup=sudoersStringValue skipwhite skipnl +syn match sudoersListParameterEquals contained '[+-]\==' nextgroup=sudoersListValue skipwhite skipnl + +syn match sudoersIntegerValue contained '\d\+' nextgroup=sudoersParameterListComma skipwhite skipnl +syn match sudoersStringValue contained '[^[:space:],:=\\]*\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersParameterListComma skipwhite skipnl +syn region sudoersStringValue contained start=+"+ skip=+\\"+ end=+"+ nextgroup=sudoersParameterListComma skipwhite skipnl +syn match sudoersListValue contained '[^[:space:],:=\\]*\%(\\[[:space:],:=\\][^[:space:],:=\\]*\)*' nextgroup=sudoersParameterListComma skipwhite skipnl +syn region sudoersListValue contained start=+"+ skip=+\\"+ end=+"+ nextgroup=sudoersParameterListComma skipwhite skipnl + +syn match sudoersPASSWD contained '\%(NO\)\=PASSWD:' nextgroup=@sudoersCmndInSpec skipwhite + +hi def link sudoersSpecEquals Operator +hi def link sudoersTodo Todo +hi def link sudoersComment Comment +hi def link sudoersAlias Keyword +hi def link sudoersUserAlias Identifier +hi def link sudoersUserNameInList String +hi def link sudoersUIDInList Number +hi def link sudoersGroupInList PreProc +hi def link sudoersUserNetgroupInList PreProc +hi def link sudoersUserAliasInList PreProc +hi def link sudoersUserName String +hi def link sudoersUID Number +hi def link sudoersGroup PreProc +hi def link sudoersUserNetgroup PreProc +hi def link sudoersUserAliasRef PreProc +hi def link sudoersUserNameInSpec String +hi def link sudoersUIDInSpec Number +hi def link sudoersGroupInSpec PreProc +hi def link sudoersUserNetgroupInSpec PreProc +hi def link sudoersUserAliasInSpec PreProc +hi def link sudoersUserNameInRunas String +hi def link sudoersUIDInRunas Number +hi def link sudoersGroupInRunas PreProc +hi def link sudoersUserNetgroupInRunas PreProc +hi def link sudoersUserAliasInRunas PreProc +hi def link sudoersHostAlias Identifier +hi def link sudoersHostNameInList String +hi def link sudoersIPAddrInList Number +hi def link sudoersNetworkInList Number +hi def link sudoersHostNetgroupInList PreProc +hi def link sudoersHostAliasInList PreProc +hi def link sudoersHostName String +hi def link sudoersIPAddr Number +hi def link sudoersNetwork Number +hi def link sudoersHostNetgroup PreProc +hi def link sudoersHostAliasRef PreProc +hi def link sudoersHostNameInSpec String +hi def link sudoersIPAddrInSpec Number +hi def link sudoersNetworkInSpec Number +hi def link sudoersHostNetgroupInSpec PreProc +hi def link sudoersHostAliasInSpec PreProc +hi def link sudoersCmndAlias Identifier +hi def link sudoersCmndNameInList String +hi def link sudoersCmndAliasInList PreProc +hi def link sudoersCmndNameInSpec String +hi def link sudoersCmndAliasInSpec PreProc +hi def link sudoersUserAliasEquals Operator +hi def link sudoersUserListComma Delimiter +hi def link sudoersUserListColon Delimiter +hi def link sudoersUserSpecComma Delimiter +hi def link sudoersUserRunasBegin Delimiter +hi def link sudoersUserRunasComma Delimiter +hi def link sudoersUserRunasEnd Delimiter +hi def link sudoersHostAliasEquals Operator +hi def link sudoersHostListComma Delimiter +hi def link sudoersHostListColon Delimiter +hi def link sudoersHostSpecComma Delimiter +hi def link sudoersCmndAliasEquals Operator +hi def link sudoersCmndListComma Delimiter +hi def link sudoersCmndListColon Delimiter +hi def link sudoersCmndSpecComma Delimiter +hi def link sudoersCmndSpecColon Delimiter +hi def link sudoersUserNegationInList Operator +hi def link sudoersHostNegationInList Operator +hi def link sudoersCmndNegationInList Operator +hi def link sudoersUserNegation Operator +hi def link sudoersHostNegation Operator +hi def link sudoersUserNegationInSpec Operator +hi def link sudoersHostNegationInSpec Operator +hi def link sudoersUserNegationInRunas Operator +hi def link sudoersCmndNegationInSpec Operator +hi def link sudoersCommandArgs String +hi def link sudoersCommandEmpty Special +hi def link sudoersDefaultEntry Keyword +hi def link sudoersDefaultTypeAt Special +hi def link sudoersDefaultTypeColon Special +hi def link sudoersDefaultTypeGreaterThan Special +hi def link sudoersBooleanParameter Identifier +hi def link sudoersIntegerParameter Identifier +hi def link sudoersStringParameter Identifier +hi def link sudoersListParameter Identifier +hi def link sudoersParameterListComma Delimiter +hi def link sudoersIntegerParameterEquals Operator +hi def link sudoersStringParameterEquals Operator +hi def link sudoersListParameterEquals Operator +hi def link sudoersIntegerValue Number +hi def link sudoersStringValue String +hi def link sudoersListValue String +hi def link sudoersPASSWD Special + +let b:current_syntax = "sudoers" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/svg.vim b/syntax/svg.vim new file mode 100644 index 0000000..5d7ff74 --- /dev/null +++ b/syntax/svg.vim @@ -0,0 +1,19 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SVG (Scalable Vector Graphics) +" Maintainer: Vincent Berthoux +" File Types: .svg (used in Web and vector programs) +" +" Directly call the xml syntax, because SVG is an XML +" dialect. But as some plugins base their effect on filetype, +" providing a distinct filetype from xml is better. + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/xml.vim +let b:current_syntax = "svg" + +endif diff --git a/syntax/svn.vim b/syntax/svn.vim new file mode 100644 index 0000000..53142c6 --- /dev/null +++ b/syntax/svn.vim @@ -0,0 +1,60 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Subversion (svn) commit file +" Maintainer: Dmitry Vasiliev +" URL: https://github.com/hdima/vim-scripts/blob/master/syntax/svn.vim +" Last Change: 2013-11-08 +" Filenames: svn-commit*.tmp +" Version: 1.10 + +" Contributors: +" +" List of the contributors in alphabetical order: +" +" A. S. Budden +" Ingo Karkat +" Myk Taylor +" Stefano Zacchiroli + +" quit when a syntax file was already loaded. +if exists("b:current_syntax") + finish +endif + +syn spell toplevel + +syn match svnFirstLine "\%^.*" nextgroup=svnRegion,svnBlank skipnl +syn match svnSummary "^.\{0,50\}" contained containedin=svnFirstLine nextgroup=svnOverflow contains=@Spell +syn match svnOverflow ".*" contained contains=@Spell +syn match svnBlank "^.*" contained contains=@Spell + +syn region svnRegion end="\%$" matchgroup=svnDelimiter start="^--.*--$" contains=svnRemoved,svnRenamed,svnAdded,svnModified,svnProperty,@NoSpell +syn match svnRemoved "^D .*$" contained contains=@NoSpell +syn match svnRenamed "^R[ M][ U][ +] .*$" contained contains=@NoSpell +syn match svnAdded "^A[ M][ U][ +] .*$" contained contains=@NoSpell +syn match svnModified "^M[ M][ U] .*$" contained contains=@NoSpell +syn match svnProperty "^_M[ U] .*$" contained contains=@NoSpell + +" Synchronization. +syn sync clear +syn sync match svnSync grouphere svnRegion "^--.*--$"me=s-1 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet. + +hi def link svnSummary Keyword +hi def link svnBlank Error + +hi def link svnRegion Comment +hi def link svnDelimiter NonText +hi def link svnRemoved Constant +hi def link svnAdded Identifier +hi def link svnModified Special +hi def link svnProperty Special +hi def link svnRenamed Special + + +let b:current_syntax = "svn" + +endif diff --git a/syntax/syncolor.vim b/syntax/syncolor.vim new file mode 100644 index 0000000..d0b4198 --- /dev/null +++ b/syntax/syncolor.vim @@ -0,0 +1,89 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax support file +" Maintainer: Bram Moolenaar +" Last Change: 2001 Sep 12 + +" This file sets up the default methods for highlighting. +" It is loaded from "synload.vim" and from Vim for ":syntax reset". +" Also used from init_highlight(). + +if !exists("syntax_cmd") || syntax_cmd == "on" + " ":syntax on" works like in Vim 5.7: set colors but keep links + command -nargs=* SynColor hi + command -nargs=* SynLink hi link +else + if syntax_cmd == "enable" + " ":syntax enable" keeps any existing colors + command -nargs=* SynColor hi def + command -nargs=* SynLink hi def link + elseif syntax_cmd == "reset" + " ":syntax reset" resets all colors to the default + command -nargs=* SynColor hi + command -nargs=* SynLink hi! link + else + " User defined syncolor file has already set the colors. + finish + endif +endif + +" Many terminals can only use six different colors (plus black and white). +" Therefore the number of colors used is kept low. It doesn't look nice with +" too many colors anyway. +" Careful with "cterm=bold", it changes the color to bright for some terminals. +" There are two sets of defaults: for a dark and a light background. +if &background == "dark" + SynColor Comment term=bold cterm=NONE ctermfg=Cyan ctermbg=NONE gui=NONE guifg=#80a0ff guibg=NONE + SynColor Constant term=underline cterm=NONE ctermfg=Magenta ctermbg=NONE gui=NONE guifg=#ffa0a0 guibg=NONE + SynColor Special term=bold cterm=NONE ctermfg=LightRed ctermbg=NONE gui=NONE guifg=Orange guibg=NONE + SynColor Identifier term=underline cterm=bold ctermfg=Cyan ctermbg=NONE gui=NONE guifg=#40ffff guibg=NONE + SynColor Statement term=bold cterm=NONE ctermfg=Yellow ctermbg=NONE gui=bold guifg=#ffff60 guibg=NONE + SynColor PreProc term=underline cterm=NONE ctermfg=LightBlue ctermbg=NONE gui=NONE guifg=#ff80ff guibg=NONE + SynColor Type term=underline cterm=NONE ctermfg=LightGreen ctermbg=NONE gui=bold guifg=#60ff60 guibg=NONE + SynColor Underlined term=underline cterm=underline ctermfg=LightBlue gui=underline guifg=#80a0ff + SynColor Ignore term=NONE cterm=NONE ctermfg=black ctermbg=NONE gui=NONE guifg=bg guibg=NONE +else + SynColor Comment term=bold cterm=NONE ctermfg=DarkBlue ctermbg=NONE gui=NONE guifg=Blue guibg=NONE + SynColor Constant term=underline cterm=NONE ctermfg=DarkRed ctermbg=NONE gui=NONE guifg=Magenta guibg=NONE + SynColor Special term=bold cterm=NONE ctermfg=DarkMagenta ctermbg=NONE gui=NONE guifg=SlateBlue guibg=NONE + SynColor Identifier term=underline cterm=NONE ctermfg=DarkCyan ctermbg=NONE gui=NONE guifg=DarkCyan guibg=NONE + SynColor Statement term=bold cterm=NONE ctermfg=Brown ctermbg=NONE gui=bold guifg=Brown guibg=NONE + SynColor PreProc term=underline cterm=NONE ctermfg=DarkMagenta ctermbg=NONE gui=NONE guifg=Purple guibg=NONE + SynColor Type term=underline cterm=NONE ctermfg=DarkGreen ctermbg=NONE gui=bold guifg=SeaGreen guibg=NONE + SynColor Underlined term=underline cterm=underline ctermfg=DarkMagenta gui=underline guifg=SlateBlue + SynColor Ignore term=NONE cterm=NONE ctermfg=white ctermbg=NONE gui=NONE guifg=bg guibg=NONE +endif +SynColor Error term=reverse cterm=NONE ctermfg=White ctermbg=Red gui=NONE guifg=White guibg=Red +SynColor Todo term=standout cterm=NONE ctermfg=Black ctermbg=Yellow gui=NONE guifg=Blue guibg=Yellow + +" Common groups that link to default highlighting. +" You can specify other highlighting easily. +SynLink String Constant +SynLink Character Constant +SynLink Number Constant +SynLink Boolean Constant +SynLink Float Number +SynLink Function Identifier +SynLink Conditional Statement +SynLink Repeat Statement +SynLink Label Statement +SynLink Operator Statement +SynLink Keyword Statement +SynLink Exception Statement +SynLink Include PreProc +SynLink Define PreProc +SynLink Macro PreProc +SynLink PreCondit PreProc +SynLink StorageClass Type +SynLink Structure Type +SynLink Typedef Type +SynLink Tag Special +SynLink SpecialChar Special +SynLink Delimiter Special +SynLink SpecialComment Special +SynLink Debug Special + +delcommand SynColor +delcommand SynLink + +endif diff --git a/syntax/synload.vim b/syntax/synload.vim new file mode 100644 index 0000000..48ad46a --- /dev/null +++ b/syntax/synload.vim @@ -0,0 +1,85 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax support file +" Maintainer: Bram Moolenaar +" Last Change: 2016 Nov 04 + +" This file sets up for syntax highlighting. +" It is loaded from "syntax.vim" and "manual.vim". +" 1. Set the default highlight groups. +" 2. Install Syntax autocommands for all the available syntax files. + +if !has("syntax") + finish +endif + +" let others know that syntax has been switched on +let syntax_on = 1 + +" Set the default highlighting colors. Use a color scheme if specified. +if exists("colors_name") + exe "colors " . colors_name +else + runtime! syntax/syncolor.vim +endif + +" Line continuation is used here, remove 'C' from 'cpoptions' +let s:cpo_save = &cpo +set cpo&vim + +" First remove all old syntax autocommands. +au! Syntax + +au Syntax * call s:SynSet() + +fun! s:SynSet() + " clear syntax for :set syntax=OFF and any syntax name that doesn't exist + syn clear + if exists("b:current_syntax") + unlet b:current_syntax + endif + + let s = expand("") + if s == "ON" + " :set syntax=ON + if &filetype == "" + echohl ErrorMsg + echo "filetype unknown" + echohl None + endif + let s = &filetype + elseif s == "OFF" + let s = "" + endif + + if s != "" + " Load the syntax file(s). When there are several, separated by dots, + " load each in sequence. + for name in split(s, '\.') + exe "runtime! syntax/" . name . ".vim syntax/" . name . "/*.vim" + endfor + endif +endfun + + +" Handle adding doxygen to other languages (C, C++, C#, IDL, java, php, DataScript) +au Syntax c,cpp,cs,idl,java,php,datascript + \ if (exists('b:load_doxygen_syntax') && b:load_doxygen_syntax) + \ || (exists('g:load_doxygen_syntax') && g:load_doxygen_syntax) + \ | runtime! syntax/doxygen.vim + \ | endif + + +" Source the user-specified syntax highlighting file +if exists("mysyntaxfile") + let s:fname = expand(mysyntaxfile) + if filereadable(s:fname) + execute "source " . fnameescape(s:fname) + endif +endif + +" Restore 'cpoptions' +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/syntax.vim b/syntax/syntax.vim new file mode 100644 index 0000000..ce6ce1d --- /dev/null +++ b/syntax/syntax.vim @@ -0,0 +1,47 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax support file +" Maintainer: Bram Moolenaar +" Last Change: 2001 Sep 04 + +" This file is used for ":syntax on". +" It installs the autocommands and starts highlighting for all buffers. + +if !has("syntax") + finish +endif + +" If Syntax highlighting appears to be on already, turn it off first, so that +" any leftovers are cleared. +if exists("syntax_on") || exists("syntax_manual") + so :p:h/nosyntax.vim +endif + +" Load the Syntax autocommands and set the default methods for highlighting. +runtime syntax/synload.vim + +" Load the FileType autocommands if not done yet. +if exists("did_load_filetypes") + let s:did_ft = 1 +else + filetype on + let s:did_ft = 0 +endif + +" Set up the connection between FileType and Syntax autocommands. +" This makes the syntax automatically set when the file type is detected. +augroup syntaxset + au! FileType * exe "set syntax=" . expand("") +augroup END + + +" Execute the syntax autocommands for the each buffer. +" If the filetype wasn't detected yet, do that now. +" Always do the syntaxset autocommands, for buffers where the 'filetype' +" already was set manually (e.g., help buffers). +doautoall syntaxset FileType +if !s:did_ft + doautoall filetypedetect BufRead +endif + +endif diff --git a/syntax/sysctl.vim b/syntax/sysctl.vim new file mode 100644 index 0000000..539f637 --- /dev/null +++ b/syntax/sysctl.vim @@ -0,0 +1,43 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: sysctl.conf(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2011-05-02 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match sysctlBegin display '^' + \ nextgroup=sysctlToken,sysctlComment skipwhite + +syn match sysctlToken contained display '[^=]\+' + \ nextgroup=sysctlTokenEq skipwhite + +syn match sysctlTokenEq contained display '=' nextgroup=sysctlValue skipwhite + +syn region sysctlValue contained display oneline + \ matchgroup=sysctlValue start='\S' + \ matchgroup=Normal end='\s*$' + +syn keyword sysctlTodo contained TODO FIXME XXX NOTE + +syn region sysctlComment display oneline start='^\s*[#;]' end='$' + \ contains=sysctlTodo,@Spell + +hi def link sysctlTodo Todo +hi def link sysctlComment Comment +hi def link sysctlToken Identifier +hi def link sysctlTokenEq Operator +hi def link sysctlValue String + +let b:current_syntax = "sysctl" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/systemd.vim b/syntax/systemd.vim index a656e05..796c10d 100644 --- a/syntax/systemd.vim +++ b/syntax/systemd.vim @@ -1,3 +1,15 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: systemd.unit(5) + +if !exists('b:current_syntax') + " Looks a lot like dosini files. + runtime! syntax/dosini.vim + let b:current_syntax = 'systemd' +endif + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'systemd') == -1 " Filename: systemd.vim diff --git a/syntax/systemverilog.vim b/syntax/systemverilog.vim new file mode 100644 index 0000000..a74ca64 --- /dev/null +++ b/syntax/systemverilog.vim @@ -0,0 +1,89 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: SystemVerilog +" Maintainer: kocha +" Last Change: 12-Aug-2013. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Read in Verilog syntax files +runtime! syntax/verilog.vim +unlet b:current_syntax + +" IEEE1800-2005 +syn keyword systemverilogStatement always_comb always_ff always_latch +syn keyword systemverilogStatement class endclass new +syn keyword systemverilogStatement virtual local const protected +syn keyword systemverilogStatement package endpackage +syn keyword systemverilogStatement rand randc constraint randomize +syn keyword systemverilogStatement with inside dist +syn keyword systemverilogStatement sequence endsequence randsequence +syn keyword systemverilogStatement srandom +syn keyword systemverilogStatement logic bit byte +syn keyword systemverilogStatement int longint shortint +syn keyword systemverilogStatement struct packed +syn keyword systemverilogStatement final +syn keyword systemverilogStatement import export +syn keyword systemverilogStatement context pure +syn keyword systemverilogStatement void shortreal chandle string +syn keyword systemverilogStatement clocking endclocking iff +syn keyword systemverilogStatement interface endinterface modport +syn keyword systemverilogStatement cover covergroup coverpoint endgroup +syn keyword systemverilogStatement property endproperty +syn keyword systemverilogStatement program endprogram +syn keyword systemverilogStatement bins binsof illegal_bins ignore_bins +syn keyword systemverilogStatement alias matches solve static assert +syn keyword systemverilogStatement assume super before expect bind +syn keyword systemverilogStatement extends null tagged extern this +syn keyword systemverilogStatement first_match throughout timeprecision +syn keyword systemverilogStatement timeunit type union +syn keyword systemverilogStatement uwire var cross ref wait_order intersect +syn keyword systemverilogStatement wildcard within + +syn keyword systemverilogTypeDef typedef enum + +syn keyword systemverilogConditional randcase +syn keyword systemverilogConditional unique priority + +syn keyword systemverilogRepeat return break continue +syn keyword systemverilogRepeat do foreach + +syn keyword systemverilogLabel join_any join_none forkjoin + +" IEEE1800-2009 add +syn keyword systemverilogStatement checker endchecker +syn keyword systemverilogStatement accept_on reject_on +syn keyword systemverilogStatement sync_accept_on sync_reject_on +syn keyword systemverilogStatement eventually nexttime until until_with +syn keyword systemverilogStatement s_always s_eventually s_nexttime s_until s_until_with +syn keyword systemverilogStatement let untyped +syn keyword systemverilogStatement strong weak +syn keyword systemverilogStatement restrict global implies + +syn keyword systemverilogConditional unique0 + +" IEEE1800-2012 add +syn keyword systemverilogStatement implements +syn keyword systemverilogStatement interconnect soft nettype + +" Define the default highlighting. + +" The default highlighting. +hi def link systemverilogStatement Statement +hi def link systemverilogTypeDef TypeDef +hi def link systemverilogConditional Conditional +hi def link systemverilogRepeat Repeat +hi def link systemverilogLabel Label +hi def link systemverilogGlobal Define +hi def link systemverilogNumber Number + + +let b:current_syntax = "systemverilog" + +" vim: ts=8 + +endif diff --git a/syntax/tads.vim b/syntax/tads.vim new file mode 100644 index 0000000..4dc4e98 --- /dev/null +++ b/syntax/tads.vim @@ -0,0 +1,175 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TADS +" Maintainer: Amir Karger +" $Date: 2004/06/13 19:28:45 $ +" $Revision: 1.1 $ +" Stolen from: Bram Moolenaar's C language file +" Newest version at: http://www.hec.utah.edu/~karger/vim/syntax/tads.vim +" History info at the bottom of the file + +" TODO lots more keywords +" global, self, etc. are special *objects*, not functions. They should +" probably be a different color than the special functions +" Actually, should cvtstr etc. be functions?! (change tadsFunction) +" Make global etc. into Identifiers, since we don't have regular variables? + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful keywords +syn keyword tadsStatement goto break return continue pass +syn keyword tadsLabel case default +syn keyword tadsConditional if else switch +syn keyword tadsRepeat while for do +syn keyword tadsStorageClass local compoundWord formatstring specialWords +syn keyword tadsBoolean nil true + +" TADS keywords +syn keyword tadsKeyword replace modify +syn keyword tadsKeyword global self inherited +" builtin functions +syn keyword tadsKeyword cvtstr cvtnum caps lower upper substr +syn keyword tadsKeyword say length +syn keyword tadsKeyword setit setscore +syn keyword tadsKeyword datatype proptype +syn keyword tadsKeyword car cdr +syn keyword tadsKeyword defined isclass +syn keyword tadsKeyword find firstobj nextobj +syn keyword tadsKeyword getarg argcount +syn keyword tadsKeyword input yorn askfile +syn keyword tadsKeyword rand randomize +syn keyword tadsKeyword restart restore quit save undo +syn keyword tadsException abort exit exitobj + +syn keyword tadsTodo contained TODO FIXME XXX + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match tadsSpecial contained "\\." +syn region tadsDoubleString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=tadsSpecial,tadsEmbedded +syn region tadsSingleString start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=tadsSpecial +" Embedded expressions in strings +syn region tadsEmbedded contained start="<<" end=">>" contains=tadsKeyword + +" TADS doesn't have \xxx, right? +"syn match cSpecial contained "\\[0-7][0-7][0-7]\=\|\\." +"syn match cSpecialCharacter "'\\[0-7][0-7]'" +"syn match cSpecialCharacter "'\\[0-7][0-7][0-7]'" + +"catch errors caused by wrong parenthesis +"syn region cParen transparent start='(' end=')' contains=ALLBUT,cParenError,cIncluded,cSpecial,cTodo,cUserCont,cUserLabel +"syn match cParenError ")" +"syn match cInParen contained "[{}]" +syn region tadsBrace transparent start='{' end='}' contains=ALLBUT,tadsBraceError,tadsIncluded,tadsSpecial,tadsTodo +syn match tadsBraceError "}" + +"integer number (TADS has no floating point numbers) +syn case ignore +syn match tadsNumber "\<[0-9]\+\>" +"hex number +syn match tadsNumber "\<0x[0-9a-f]\+\>" +syn match tadsIdentifier "\<[a-z][a-z0-9_$]*\>" +syn case match +" flag an octal number with wrong digits +syn match tadsOctalError "\<0[0-7]*[89]" + +" Removed complicated c_comment_strings +syn region tadsComment start="/\*" end="\*/" contains=tadsTodo +syn match tadsComment "//.*" contains=tadsTodo +syntax match tadsCommentError "\*/" + +syn region tadsPreCondit start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=tadsComment,tadsString,tadsNumber,tadsCommentError +syn region tadsIncluded contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match tadsIncluded contained "<[^>]*>" +syn match tadsInclude "^\s*#\s*include\>\s*["<]" contains=tadsIncluded +syn region tadsDefine start="^\s*#\s*\(define\>\|undef\>\)" skip="\\$" end="$" contains=ALLBUT,tadsPreCondit,tadsIncluded,tadsInclude,tadsDefine,tadsInBrace,tadsIdentifier + +syn region tadsPreProc start="^\s*#\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" contains=ALLBUT,tadsPreCondit,tadsIncluded,tadsInclude,tadsDefine,tadsInParen,tadsIdentifier + +" Highlight User Labels +" TODO labels for gotos? +"syn region cMulti transparent start='?' end=':' contains=ALLBUT,cIncluded,cSpecial,cTodo,cUserCont,cUserLabel,cBitField +" Avoid matching foo::bar() in C++ by requiring that the next char is not ':' +"syn match cUserCont "^\s*\I\i*\s*:$" contains=cUserLabel +"syn match cUserCont ";\s*\I\i*\s*:$" contains=cUserLabel +"syn match cUserCont "^\s*\I\i*\s*:[^:]" contains=cUserLabel +"syn match cUserCont ";\s*\I\i*\s*:[^:]" contains=cUserLabel + +"syn match cUserLabel "\I\i*" contained + +" identifier: class-name [, class-name [...]] [property-list] ; +" Don't highlight comment in class def +syn match tadsClassDef "\[^/]*" contains=tadsObjectDef,tadsClass +syn match tadsClass contained "\" +syn match tadsObjectDef "\<[a-zA-Z][a-zA-Z0-9_$]*\s*:\s*[a-zA-Z0-9_$]\+\(\s*,\s*[a-zA-Z][a-zA-Z0-9_$]*\)*\(\s*;\)\=" +syn keyword tadsFunction contained function +syn match tadsFunctionDef "\<[a-zA-Z][a-zA-Z0-9_$]*\s*:\s*function[^{]*" contains=tadsFunction +"syn region tadsObject transparent start = '[a-zA-Z][\i$]\s*:\s*' end=";" contains=tadsBrace,tadsObjectDef + +" How far back do we go to find matching groups +if !exists("tads_minlines") + let tads_minlines = 15 +endif +exec "syn sync ccomment tadsComment minlines=" . tads_minlines +if !exists("tads_sync_dist") + let tads_sync_dist = 100 +endif +execute "syn sync maxlines=" . tads_sync_dist + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +hi def link tadsFunctionDef Function +hi def link tadsFunction Structure +hi def link tadsClass Structure +hi def link tadsClassDef Identifier +hi def link tadsObjectDef Identifier +" no highlight for tadsEmbedded, so it prints as normal text w/in the string + +hi def link tadsOperator Operator +hi def link tadsStructure Structure +hi def link tadsTodo Todo +hi def link tadsLabel Label +hi def link tadsConditional Conditional +hi def link tadsRepeat Repeat +hi def link tadsException Exception +hi def link tadsStatement Statement +hi def link tadsStorageClass StorageClass +hi def link tadsKeyWord Keyword +hi def link tadsSpecial SpecialChar +hi def link tadsNumber Number +hi def link tadsBoolean Boolean +hi def link tadsDoubleString tadsString +hi def link tadsSingleString tadsString + +hi def link tadsOctalError tadsError +hi def link tadsCommentError tadsError +hi def link tadsBraceError tadsError +hi def link tadsInBrace tadsError +hi def link tadsError Error + +hi def link tadsInclude Include +hi def link tadsPreProc PreProc +hi def link tadsDefine Macro +hi def link tadsIncluded tadsString +hi def link tadsPreCondit PreCondit + +hi def link tadsString String +hi def link tadsComment Comment + + + +let b:current_syntax = "tads" + +" Changes: +" 11/18/99 Added a bunch of TADS functions, tadsException +" 10/22/99 Misspelled Moolenaar (sorry!), c_minlines to tads_minlines +" +" vim: ts=8 + +endif diff --git a/syntax/tags.vim b/syntax/tags.vim new file mode 100644 index 0000000..11b7c32 --- /dev/null +++ b/syntax/tags.vim @@ -0,0 +1,35 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: tags +" Maintainer: Charles E. Campbell +" Last Change: Oct 26, 2016 +" Version: 7 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_TAGS + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match tagName "^[^\t]\+" skipwhite nextgroup=tagPath +syn match tagPath "[^\t]\+" contained skipwhite nextgroup=tagAddr contains=tagBaseFile +syn match tagBaseFile "[a-zA-Z_]\+[\.a-zA-Z_0-9]*\t"me=e-1 contained +syn match tagAddr "\d*" contained skipwhite nextgroup=tagComment +syn region tagAddr matchgroup=tagDelim start="/" skip="\(\\\\\)*\\/" matchgroup=tagDelim end="$\|/" oneline contained skipwhite nextgroup=tagComment +syn match tagComment ";.*$" contained contains=tagField +syn match tagComment "^!_TAG_.*$" +syn match tagField contained "[a-z]*:" + +" Define the default highlighting. +if !exists("skip_drchip_tags_inits") + hi def link tagBaseFile PreProc + hi def link tagComment Comment + hi def link tagDelim Delimiter + hi def link tagField Number + hi def link tagName Identifier + hi def link tagPath PreProc +endif + +let b:current_syntax = "tags" + +endif diff --git a/syntax/tak.vim b/syntax/tak.vim new file mode 100644 index 0000000..7536c5b --- /dev/null +++ b/syntax/tak.vim @@ -0,0 +1,123 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TAK2, TAK3, TAK2000 thermal modeling input file +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.tak +" URL: http://www.naglenet.org/vim/syntax/tak.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case ignore + + + +" +" +" Begin syntax definitions for tak input file. +" + +" Force free-form fortran format +let fortran_free_source=1 + +" Load FORTRAN syntax file +runtime! syntax/fortran.vim +unlet b:current_syntax + + + +" Define keywords for TAK and TAKOUT +syn keyword takOptions AUTODAMP CPRINT CSGDUMP GPRINT HPRINT LODTMP +syn keyword takOptions LOGIC LPRINT NCVPRINT PLOTQ QPRINT QDUMP +syn keyword takOptions SUMMARY SOLRTN UID DICTIONARIES + +syn keyword takRoutine SSITER FWDWRD FWDBCK BCKWRD + +syn keyword takControl ABSZRO BACKUP DAMP DTIMEI DTIMEL DTIMEH IFC +syn keyword takControl MAXTEMP NLOOPS NLOOPT NODELIST OUTPUT PLOT +syn keyword takControl SCALE SIGMA SSCRIT TIMEND TIMEN TIMEO TRCRIT +syn keyword takControl PLOT + +syn keyword takSolids PLATE CYL +syn keyword takSolidsArg ID MATNAM NTYPE TEMP XL YL ZL ISTRN ISTRG NNX +syn keyword takSolidsArg NNY NNZ INCX INCY INCZ IAK IAC DIFF ARITH BOUN +syn keyword takSolidsArg RMIN RMAX AXMAX NNR NNTHETA INCR INCTHETA END + +syn case ignore + +syn keyword takMacro fac pstart pstop +syn keyword takMacro takcommon fstart fstop + +syn keyword takIdentifier flq flx gen ncv per sim siv stf stv tvd tvs +syn keyword takIdentifier tvt pro thm + + + +" Define matches for TAK +syn match takFortran "^F[0-9 ]"me=e-1 +syn match takMotran "^M[0-9 ]"me=e-1 + +syn match takComment "^C.*$" +syn match takComment "^R.*$" +syn match takComment "\$.*$" + +syn match takHeader "^header[^,]*" + +syn match takIncludeFile "include \+[^ ]\+"hs=s+8 contains=fortranInclude + +syn match takInteger "-\=\<[0-9]*\>" +syn match takFloat "-\=\<[0-9]*\.[0-9]*" +syn match takScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>" + +syn match takEndData "END OF DATA" + +if exists("thermal_todo") + execute 'syn match takTodo ' . '"^'.thermal_todo.'.*$"' +else + syn match takTodo "^?.*$" +endif + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link takMacro Macro +hi def link takOptions Special +hi def link takRoutine Type +hi def link takControl Special +hi def link takSolids Special +hi def link takSolidsArg Statement +hi def link takIdentifier Identifier + +hi def link takFortran PreProc +hi def link takMotran PreProc + +hi def link takComment Comment +hi def link takHeader Typedef +hi def link takIncludeFile Type +hi def link takInteger Number +hi def link takFloat Float +hi def link takScientific Float + +hi def link takEndData Macro + +hi def link takTodo Todo + + + +let b:current_syntax = "tak" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/takcmp.vim b/syntax/takcmp.vim new file mode 100644 index 0000000..8e26644 --- /dev/null +++ b/syntax/takcmp.vim @@ -0,0 +1,73 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TAK2, TAK3, TAK2000 thermal modeling compare file +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.cmp +" URL: http://www.naglenet.org/vim/syntax/takcmp.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case ignore + + + +" +" +" Begin syntax definitions for compare files. +" +" Define keywords for TAK compare + syn keyword takcmpUnit celsius fahrenheit + + + +" Define matches for TAK compare + syn match takcmpTitle "Steady State Temperature Comparison" + + syn match takcmpLabel "Run Date:" + syn match takcmpLabel "Run Time:" + syn match takcmpLabel "Temp. File \d Units:" + syn match takcmpLabel "Filename:" + syn match takcmpLabel "Output Units:" + + syn match takcmpHeader "^ *Node\( *File \d\)* *Node Description" + + syn match takcmpDate "\d\d\/\d\d\/\d\d" + syn match takcmpTime "\d\d:\d\d:\d\d" + syn match takcmpInteger "^ *-\=\<[0-9]*\>" + syn match takcmpFloat "-\=\<[0-9]*\.[0-9]*" + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link takcmpTitle Type +hi def link takcmpUnit PreProc + +hi def link takcmpLabel Statement + +hi def link takcmpHeader takHeader + +hi def link takcmpDate Identifier +hi def link takcmpTime Identifier +hi def link takcmpInteger Number +hi def link takcmpFloat Special + + + +let b:current_syntax = "takcmp" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/takout.vim b/syntax/takout.vim new file mode 100644 index 0000000..570e6cc --- /dev/null +++ b/syntax/takout.vim @@ -0,0 +1,89 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TAK2, TAK3, TAK2000 thermal modeling output file +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.out +" URL: http://www.naglenet.org/vim/syntax/takout.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case match + + + +" Load TAK syntax file +runtime! syntax/tak.vim +unlet b:current_syntax + + + +" +" +" Begin syntax definitions for tak output files. +" + +" Define keywords for TAK output +syn case match + +syn keyword takoutPos ON SI +syn keyword takoutNeg OFF ENG + + + +" Define matches for TAK output +syn match takoutTitle "TAK III" +syn match takoutTitle "Release \d.\d\d" +syn match takoutTitle " K & K Associates *Thermal Analysis Kit III *Serial Number \d\d-\d\d\d" + +syn match takoutFile ": \w*\.TAK"hs=s+2 + +syn match takoutInteger "T\=[0-9]*\>"ms=s+1 + +syn match takoutSectionDelim "[-<>]\{4,}" contains=takoutSectionTitle +syn match takoutSectionDelim ":\=\.\{4,}:\=" contains=takoutSectionTitle +syn match takoutSectionTitle "[-<:] \w[0-9A-Za-z_() ]\+ [->:]"hs=s+1,me=e-1 + +syn match takoutHeaderDelim "=\{5,}" +syn match takoutHeaderDelim "|\{5,}" +syn match takoutHeaderDelim "+\{5,}" + +syn match takoutLabel "Input File:" contains=takoutFile +syn match takoutLabel "Begin Solution: Routine" + +syn match takoutError "<<< Error >>>" + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link takoutPos Statement +hi def link takoutNeg PreProc +hi def link takoutTitle Type +hi def link takoutFile takIncludeFile +hi def link takoutInteger takInteger + +hi def link takoutSectionDelim Delimiter +hi def link takoutSectionTitle Exception +hi def link takoutHeaderDelim SpecialComment +hi def link takoutLabel Identifier + +hi def link takoutError Error + + + +let b:current_syntax = "takout" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/tap.vim b/syntax/tap.vim index ab42a32..1cdcde1 100644 --- a/syntax/tap.vim +++ b/syntax/tap.vim @@ -1,3 +1,104 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Verbose TAP Output +" Maintainer: Rufus Cable +" Remark: Simple syntax highlighting for TAP output +" License: +" Copyright: (c) 2008-2013 Rufus Cable +" Last Change: 2014-12-13 + +if exists("b:current_syntax") + finish +endif + +syn match tapTestDiag /^ *#.*/ contains=tapTestTodo +syn match tapTestTime /^ *\[\d\d:\d\d:\d\d\].*/ contains=tapTestFile +syn match tapTestFile /\w\+\/[^. ]*/ contained +syn match tapTestFileWithDot /\w\+\/[^ ]*/ contained + +syn match tapTestPlan /^ *\d\+\.\.\d\+$/ + +" tapTest is a line like 'ok 1', 'not ok 2', 'ok 3 - xxxx' +syn match tapTest /^ *\(not \)\?ok \d\+.*/ contains=tapTestStatusOK,tapTestStatusNotOK,tapTestLine + +" tapTestLine is the line without the ok/not ok status - i.e. number and +" optional message +syn match tapTestLine /\d\+\( .*\|$\)/ contains=tapTestNumber,tapTestLoadMessage,tapTestTodo,tapTestSkip contained + +" turn ok/not ok messages green/red respectively +syn match tapTestStatusOK /ok/ contained +syn match tapTestStatusNotOK /not ok/ contained + +" highlight todo tests +syn match tapTestTodo /\(# TODO\|Failed (TODO)\) .*$/ contained contains=tapTestTodoRev +syn match tapTestTodoRev /\/ contained + +" highlight skipped tests +syn match tapTestSkip /# skip .*$/ contained contains=tapTestSkipTag +syn match tapTestSkipTag /\(# \)\@<=skip\>/ contained + +" look behind so "ok 123" and "not ok 124" match test number +syn match tapTestNumber /\(ok \)\@<=\d\d*/ contained +syn match tapTestLoadMessage /\*\*\*.*\*\*\*/ contained contains=tapTestThreeStars,tapTestFileWithDot +syn match tapTestThreeStars /\*\*\*/ contained + +syn region tapTestRegion start=/^ *\(not \)\?ok.*$/me=e+1 end=/^\(\(not \)\?ok\|# Looks like you planned \|All tests successful\|Bailout called\)/me=s-1 fold transparent excludenl +syn region tapTestResultsOKRegion start=/^\(All tests successful\|Result: PASS\)/ end=/$/ +syn region tapTestResultsNotOKRegion start=/^\(# Looks like you planned \|Bailout called\|# Looks like you failed \|Result: FAIL\)/ end=/$/ +syn region tapTestResultsSummaryRegion start=/^Test Summary Report/ end=/^Files=.*$/ contains=tapTestResultsSummaryHeading,tapTestResultsSummaryNotOK + +syn region tapTestResultsSummaryHeading start=/^Test Summary Report/ end=/^-\+$/ contained +syn region tapTestResultsSummaryNotOK start=/TODO passed:/ end=/$/ contained + +syn region tapTestInstructionsRegion start=/\%1l/ end=/^$/ + +set foldtext=TAPTestLine_foldtext() +function! TAPTestLine_foldtext() + let line = getline(v:foldstart) + let sub = substitute(line, '/\*\|\*/\|{{{\d\=', '', 'g') + return sub +endfunction + +set foldminlines=5 +set foldcolumn=2 +set foldenable +set foldmethod=syntax +syn sync fromstart + +if !exists("did_tapverboseoutput_syntax_inits") + let did_tapverboseoutput_syntax_inits = 1 + + hi tapTestStatusOK term=bold ctermfg=green guifg=Green + hi tapTestStatusNotOK term=reverse ctermfg=black ctermbg=red guifg=Black guibg=Red + hi tapTestTodo term=bold ctermfg=yellow ctermbg=black guifg=Yellow guibg=Black + hi tapTestTodoRev term=reverse ctermfg=black ctermbg=yellow guifg=Black guibg=Yellow + hi tapTestSkip term=bold ctermfg=lightblue guifg=LightBlue + hi tapTestSkipTag term=reverse ctermfg=black ctermbg=lightblue guifg=Black guibg=LightBlue + hi tapTestTime term=bold ctermfg=blue guifg=Blue + hi tapTestFile term=reverse ctermfg=black ctermbg=yellow guibg=Black guifg=Yellow + hi tapTestLoadedFile term=bold ctermfg=black ctermbg=cyan guibg=Cyan guifg=Black + hi tapTestThreeStars term=reverse ctermfg=blue guifg=Blue + hi tapTestPlan term=bold ctermfg=yellow guifg=Yellow + + hi link tapTestFileWithDot tapTestLoadedFile + hi link tapTestNumber Number + hi link tapTestDiag Comment + + hi tapTestRegion ctermbg=green + + hi tapTestResultsOKRegion ctermbg=green ctermfg=black + hi tapTestResultsNotOKRegion ctermbg=red ctermfg=black + + hi tapTestResultsSummaryHeading ctermbg=blue ctermfg=white + hi tapTestResultsSummaryNotOK ctermbg=red ctermfg=black + + hi tapTestInstructionsRegion ctermbg=lightmagenta ctermfg=black +endif + +let b:current_syntax="tapVerboseOutput" + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Vim syntax file diff --git a/syntax/tar.vim b/syntax/tar.vim new file mode 100644 index 0000000..8ab3d29 --- /dev/null +++ b/syntax/tar.vim @@ -0,0 +1,21 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language : Tar Listing Syntax +" Maintainer : Bram Moolenaar +" Last change: Sep 08, 2004 + +if exists("b:current_syntax") + finish +endif + +syn match tarComment '^".*' contains=tarFilename +syn match tarFilename 'tarfile \zs.*' contained +syn match tarDirectory '.*/$' + +hi def link tarComment Comment +hi def link tarFilename Constant +hi def link tarDirectory Type + +" vim: ts=8 + +endif diff --git a/syntax/taskdata.vim b/syntax/taskdata.vim new file mode 100644 index 0000000..d60bd52 --- /dev/null +++ b/syntax/taskdata.vim @@ -0,0 +1,49 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: task data +" Maintainer: John Florian +" Updated: Wed Jul 8 19:46:20 EDT 2009 + + +" quit when a syntax file was already loaded. +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +" Key Names for values. +syn keyword taskdataKey description due end entry imask mask parent +syn keyword taskdataKey priority project recur start status tags uuid +syn match taskdataKey "annotation_\d\+" +syn match taskdataUndo "^time.*$" +syn match taskdataUndo "^\(old \|new \|---\)" + +" Values associated with key names. +" +" Strings +syn region taskdataString matchgroup=Normal start=+"+ end=+"+ + \ contains=taskdataEncoded,taskdataUUID,@Spell +" +" Special Embedded Characters (e.g., ",") +syn match taskdataEncoded "&\a\+;" contained +" UUIDs +syn match taskdataUUID "\x\{8}-\(\x\{4}-\)\{3}\x\{12}" contained + + +" The default methods for highlighting. Can be overridden later. +hi def link taskdataEncoded Function +hi def link taskdataKey Statement +hi def link taskdataString String +hi def link taskdataUUID Special +hi def link taskdataUndo Type + +let b:current_syntax = "taskdata" + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim:noexpandtab + +endif diff --git a/syntax/taskedit.vim b/syntax/taskedit.vim new file mode 100644 index 0000000..661f33a --- /dev/null +++ b/syntax/taskedit.vim @@ -0,0 +1,41 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: support for 'task 42 edit' +" Maintainer: John Florian +" Updated: Wed Jul 8 19:46:32 EDT 2009 + + +" quit when a syntax file was already loaded. +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +syn match taskeditHeading "^\s*#\s*Name\s\+Editable details\s*$" contained +syn match taskeditHeading "^\s*#\s*-\+\s\+-\+\s*$" contained +syn match taskeditReadOnly "^\s*#\s*\(UU\)\?ID:.*$" contained +syn match taskeditReadOnly "^\s*#\s*Status:.*$" contained +syn match taskeditReadOnly "^\s*#\s*i\?Mask:.*$" contained +syn match taskeditKey "^ *.\{-}:" nextgroup=taskeditString +syn match taskeditComment "^\s*#.*$" + \ contains=taskeditReadOnly,taskeditHeading +syn match taskeditString ".*$" contained contains=@Spell + + +" The default methods for highlighting. Can be overridden later. +hi def link taskeditComment Comment +hi def link taskeditHeading Function +hi def link taskeditKey Statement +hi def link taskeditReadOnly Special +hi def link taskeditString String + +let b:current_syntax = "taskedit" + +let &cpo = s:keepcpo +unlet s:keepcpo + +" vim:noexpandtab + +endif diff --git a/syntax/tasm.vim b/syntax/tasm.vim new file mode 100644 index 0000000..e6408e8 --- /dev/null +++ b/syntax/tasm.vim @@ -0,0 +1,119 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TASM: turbo assembler by Borland +" Maintaner: FooLman of United Force +" Last Change: 2012 Feb 03 by Thilo Six + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case ignore +syn match tasmLabel "^[\ \t]*[@a-z_$][a-z0-9_$@]*\ *:" +syn keyword tasmDirective ALIAS ALIGN ARG ASSUME %BIN CATSRT CODESEG +syn match tasmDirective "\<\(byte\|word\|dword\|qword\)\ ptr\>" +" CALL extended syntax +syn keyword tasmDirective COMM %CONDS CONST %CREF %CREFALL %CREFREF +syn keyword tasmDirective %CREFUREF %CTLS DATASEG DB DD %DEPTH DF DISPLAY +syn keyword tasmDirective DOSSEG DP DQ DT DW ELSE EMUL END ENDIF +" IF XXXX +syn keyword tasmDirective ENDM ENDP ENDS ENUM EQU ERR EVEN EVENDATA EXITCODE +syn keyword tasmDirective EXITM EXTRN FARDATA FASTIMUL FLIPFLAG GETFIELD GLOBAL +syn keyword tasmDirective GOTO GROUP IDEAL %INCL INCLUDE INCLUDELIB INSTR IRP +"JMP +syn keyword tasmDirective IRPC JUMPS LABEL LARGESTACK %LINUM %LIST LOCAL +syn keyword tasmDirective LOCALS MACRO %MACS MASKFLAG MASM MASM51 MODEL +syn keyword tasmDirective MULTERRS NAME %NEWPAGE %NOCONDS %NOCREF %NOCTLS +syn keyword tasmDirective NOEMUL %NOINCL NOJUMPS %NOLIST NOLOCALS %NOMACS +syn keyword tasmDirective NOMASM51 NOMULTERRS NOSMART %NOSYMS %NOTRUNC NOWARN +syn keyword tasmDirective %PAGESIZE %PCNT PNO87 %POPLCTL POPSTATE PROC PROCDESC +syn keyword tasmDirective PROCTYPE PUBLIC PUBLICDLL PURGE %PUSHCTL PUSHSTATE +"rept, ret +syn keyword tasmDirective QUIRKS RADIX RECORD RETCODE SEGMENT SETFIELD +syn keyword tasmDirective SETFLAG SIZESTR SMALLSTACK SMART STACK STARTUPCODE +syn keyword tasmDirective STRUC SUBSTR %SUBTTL %SYMS TABLE %TABSIZE TBLINIT +syn keyword tasmDirective TBLINST TBLPTR TESTFLAG %TEXT %TITLE %TRUNC TYPEDEF +syn keyword tasmDirective UDATASEG UFARDATA UNION USES VERSION WAR WHILE ?DEBUG + +syn keyword tasmInstruction AAA AAD AAM AAS ADC ADD AND ARPL BOUND BSF BSR +syn keyword tasmInstruction BSWAP BT BTC BTR BTS CALL CBW CLC CLD CLI CLTS +syn keyword tasmInstruction CMC CMP CMPXCHG CMPXCHG8B CPUID CWD CDQ CWDE +syn keyword tasmInstruction DAA DAS DEC DIV ENTER RETN RETF F2XM1 +syn keyword tasmCoprocInstr FABS FADD FADDP FBLD FBSTP FCHG FCOM FCOM2 FCOMI +syn keyword tasmCoprocInstr FCOMIP FCOMP FCOMP3 FCOMP5 FCOMPP FCOS FDECSTP +syn keyword tasmCoprocInstr FDISI FDIV FDIVP FDIVR FENI FFREE FFREEP FIADD +syn keyword tasmCoprocInstr FICOM FICOMP FIDIV FIDIVR FILD FIMUL FINIT FINCSTP +syn keyword tasmCoprocInstr FIST FISTP FISUB FISUBR FLD FLD1 FLDCW FLDENV +syn keyword tasmCoprocInstr FLDL2E FLDL2T FLDLG2 FLDLN2 FLDPI FLDZ FMUL FMULP +syn keyword tasmCoprocInstr FNCLEX FNINIT FNOP FNSAVE FNSTCW FNSTENV FNSTSW +syn keyword tasmCoprocInstr FPATAN FPREM FPREM1 FPTAN FRNDINT FRSTOR FSCALE +syn keyword tasmCoprocInstr FSETPM FSIN FSINCOM FSQRT FST FSTP FSTP1 FSTP8 +syn keyword tasmCoprocInstr FSTP9 FSUB FSUBP FSUBR FSUBRP FTST FUCOM FUCOMI +syn keyword tasmCoprocInstr FUCOMPP FWAIT FXAM FXCH FXCH4 FXCH7 FXTRACT FYL2X +syn keyword tasmCoprocInstr FYL2XP1 FSTCW FCHS FSINCOS +syn keyword tasmInstruction IDIV IMUL IN INC INT INTO INVD INVLPG IRET JMP +syn keyword tasmInstruction LAHF LAR LDS LEA LEAVE LES LFS LGDT LGS LIDT LLDT +syn keyword tasmInstruction LMSW LOCK LODSB LSL LSS LTR MOV MOVSX MOVZX MUL +syn keyword tasmInstruction NEG NOP NOT OR OUT POP POPA POPAD POPF POPFD PUSH +syn keyword tasmInstruction PUSHA PUSHAD PUSHF PUSHFD RCL RCR RDMSR RDPMC RDTSC +syn keyword tasmInstruction REP RET ROL ROR RSM SAHF SAR SBB SGDT SHL SAL SHLD +syn keyword tasmInstruction SHR SHRD SIDT SMSW STC STD STI STR SUB TEST VERR +syn keyword tasmInstruction VERW WBINVD WRMSR XADD XCHG XLAT XOR +syn keyword tasmMMXinst EMMS MOVD MOVQ PACKSSDW PACKSSWB PACKUSWB PADDB +syn keyword tasmMMXinst PADDD PADDSB PADDSB PADDSW PADDUSB PADDUSW PADDW +syn keyword tasmMMXinst PAND PANDN PCMPEQB PCMPEQD PCMPEQW PCMPGTB PCMPGTD +syn keyword tasmMMXinst PCMPGTW PMADDWD PMULHW PMULLW POR PSLLD PSLLQ +syn keyword tasmMMXinst PSLLW PSRAD PSRAW PSRLD PSRLQ PSRLW PSUBB PSUBD +syn keyword tasmMMXinst PSUBSB PSUBSW PSUBUSB PSUBUSW PSUBW PUNPCKHBW +syn keyword tasmMMXinst PUNPCKHBQ PUNPCKHWD PUNPCKLBW PUNPCKLDQ PUNPCKLWD +syn keyword tasmMMXinst PXOR +"FCMOV +syn match tasmInstruction "\<\(CMPS\|MOVS\|OUTS\|SCAS\|STOS\|LODS\|INS\)[BWD]" +syn match tasmInstruction "\<\(CMOV\|SET\|J\)N\=[ABCGLESXZ]\>" +syn match tasmInstruction "\<\(CMOV\|SET\|J\)N\=[ABGL]E\>" +syn match tasmInstruction "\<\(LOOP\|REP\)N\=[EZ]\=\>" +syn match tasmRegister "\<[A-D][LH]\>" +syn match tasmRegister "\" +syn match tasmRegister "\<[C-GS]S\>" +syn region tasmComment start=";" end="$" +"HACK! comment ? ... selection +syn region tasmComment start="comment \+\$" end="\$" +syn region tasmComment start="comment \+\~" end="\~" +syn region tasmComment start="comment \+#" end="#" +syn region tasmString start="'" end="'" +syn region tasmString start='"' end='"' + +syn match tasmDec "\<-\=[0-9]\+\.\=[0-9]*\>" +syn match tasmHex "\<[0-9][0-9A-F]*H\>" +syn match tasmOct "\<[0-7]\+O\>" +syn match tasmBin "\<[01]\+B\>" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link tasmString String +hi def link tasmDec Number +hi def link tasmHex Number +hi def link tasmOct Number +hi def link tasmBin Number +hi def link tasmInstruction Keyword +hi def link tasmCoprocInstr Keyword +hi def link tasmMMXInst Keyword +hi def link tasmDirective PreProc +hi def link tasmRegister Identifier +hi def link tasmProctype PreProc +hi def link tasmComment Comment +hi def link tasmLabel Label + + +let b:curret_syntax = "tasm" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/tcl.vim b/syntax/tcl.vim new file mode 100644 index 0000000..e76e7b3 --- /dev/null +++ b/syntax/tcl.vim @@ -0,0 +1,278 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Tcl/Tk +" Maintainer: Taylor Venable +" (previously Brett Cannon ) +" (previously Dean Copsey ) +" (previously Matt Neumann ) +" (previously Allan Kelly ) +" Original: Robin Becker +" Last Change: 2014-02-12 +" Version: 1.14 +" URL: http://bitbucket.org/taylor_venable/metasyntax/src/tip/Config/vim/syntax/tcl.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Basic Tcl commands: http://www.tcl.tk/man/tcl8.6/TclCmd/contents.htm +syn keyword tclCommand after append array bgerror binary cd chan clock close concat +syn keyword tclCommand dde dict encoding eof error eval exec exit expr fblocked +syn keyword tclCommand fconfigure fcopy file fileevent flush format gets glob +syn keyword tclCommand global history http incr info interp join lappend lassign +syn keyword tclCommand lindex linsert list llength lmap load lrange lrepeat +syn keyword tclCommand lreplace lreverse lsearch lset lsort memory my namespace +syn keyword tclCommand next nextto open package pid puts pwd read refchan regexp +syn keyword tclCommand registry regsub rename scan seek self set socket source +syn keyword tclCommand split string subst tell time trace unknown unload unset +syn keyword tclCommand update uplevel upvar variable vwait + +" The 'Tcl Standard Library' commands: http://www.tcl.tk/man/tcl8.6/TclCmd/library.htm +syn keyword tclCommand auto_execok auto_import auto_load auto_mkindex auto_reset +syn keyword tclCommand auto_qualify tcl_findLibrary parray tcl_endOfWord +syn keyword tclCommand tcl_startOfNextWord tcl_startOfPreviousWord +syn keyword tclCommand tcl_wordBreakAfter tcl_wordBreakBefore + +" Global variables used by Tcl: http://www.tcl.tk/man/tcl8.6/TclCmd/tclvars.htm +syn keyword tclVars auto_path env errorCode errorInfo tcl_library tcl_patchLevel +syn keyword tclVars tcl_pkgPath tcl_platform tcl_precision tcl_rcFileName +syn keyword tclVars tcl_traceCompile tcl_traceExec tcl_wordchars +syn keyword tclVars tcl_nonwordchars tcl_version argc argv argv0 tcl_interactive + +" Strings which expr accepts as boolean values, aside from zero / non-zero. +syn keyword tclBoolean true false on off yes no + +syn keyword tclProcCommand apply coroutine proc return tailcall yield yieldto +syn keyword tclConditional if then else elseif switch +syn keyword tclConditional catch try throw finally +syn keyword tclLabel default +syn keyword tclRepeat while for foreach break continue + +syn keyword tcltkSwitch contained insert create polygon fill outline tag + +" WIDGETS +" commands associated with widgets +syn keyword tcltkWidgetSwitch contained background highlightbackground insertontime cget +syn keyword tcltkWidgetSwitch contained selectborderwidth borderwidth highlightcolor insertwidth +syn keyword tcltkWidgetSwitch contained selectforeground cursor highlightthickness padx setgrid +syn keyword tcltkWidgetSwitch contained exportselection insertbackground pady takefocus +syn keyword tcltkWidgetSwitch contained font insertborderwidth relief xscrollcommand +syn keyword tcltkWidgetSwitch contained foreground insertofftime selectbackground yscrollcommand +syn keyword tcltkWidgetSwitch contained height spacing1 spacing2 spacing3 +syn keyword tcltkWidgetSwitch contained state tabs width wrap +" button +syn keyword tcltkWidgetSwitch contained command default +" canvas +syn keyword tcltkWidgetSwitch contained closeenough confine scrollregion xscrollincrement yscrollincrement orient +" checkbutton, radiobutton +syn keyword tcltkWidgetSwitch contained indicatoron offvalue onvalue selectcolor selectimage state variable +" entry, frame +syn keyword tcltkWidgetSwitch contained show class colormap container visual +" listbox, menu +syn keyword tcltkWidgetSwitch contained selectmode postcommand selectcolor tearoff tearoffcommand title type +" menubutton, message +syn keyword tcltkWidgetSwitch contained direction aspect justify +" scale +syn keyword tcltkWidgetSwitch contained bigincrement digits from length resolution showvalue sliderlength sliderrelief tickinterval to +" scrollbar +syn keyword tcltkWidgetSwitch contained activerelief elementborderwidth +" image +syn keyword tcltkWidgetSwitch contained delete names types create +" variable reference + " ::optional::namespaces +syn match tclVarRef "$\(\(::\)\?\([[:alnum:]_]*::\)*\)\a[[:alnum:]_]*" + " ${...} may contain any character except '}' +syn match tclVarRef "${[^}]*}" + +" Used to facilitate hack to utilize string background for certain color +" schemes, e.g. inkpot and lettuce. +syn cluster tclVarRefC add=tclVarRef +syn cluster tclSpecialC add=tclSpecial + +" The syntactic unquote-splicing replacement for [expand]. +syn match tclExpand '\s{\*}' +syn match tclExpand '^{\*}' + +" menu, mane add +syn keyword tcltkWidgetSwitch contained active end last none cascade checkbutton command radiobutton separator +syn keyword tcltkWidgetSwitch contained activebackground actveforeground accelerator background bitmap columnbreak +syn keyword tcltkWidgetSwitch contained font foreground hidemargin image indicatoron label menu offvalue onvalue +syn keyword tcltkWidgetSwitch contained selectcolor selectimage state underline value variable +syn keyword tcltkWidgetSwitch contained add clone configure delete entrycget entryconfigure index insert invoke +syn keyword tcltkWidgetSwitch contained post postcascade type unpost yposition activate +"syn keyword tcltkWidgetSwitch contained +"syn match tcltkWidgetSwitch contained +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef + +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +" These words are dual purpose. +" match switches +"syn match tcltkWidgetSwitch contained "-text"hs=s+1 +syn match tcltkWidgetSwitch contained "-text\(var\)\?"hs=s+1 +syn match tcltkWidgetSwitch contained "-menu"hs=s+1 +syn match tcltkWidgetSwitch contained "-label"hs=s+1 +" match commands - 2 lines for pretty match. +"variable +" Special case - If a number follows a variable region, it must be at the end of +" the pattern, by definition. Therefore, (1) either include a number as the region +" end and exclude tclNumber from the contains list, or (2) make variable +" keepend. As (1) would put variable out of step with everything else, use (2). +syn region tcltkCommand matchgroup=tcltkCommandColor start="^\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tclString,tclNumber,tclVarRef,tcltkCommand +syn region tcltkCommand matchgroup=tcltkCommandColor start="\s\\|\[\"hs=s+1 matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tclString,tclNumber,tclVarRef,tcltkCommand +" menu +syn region tcltkWidget matchgroup=tcltkWidgetColor start="^\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\s\\|\[\"hs=s+1 matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +" label +syn region tcltkWidget matchgroup=tcltkWidgetColor start="^\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\s\\|\[\"hs=s+1 matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef +" text +syn region tcltkWidget matchgroup=tcltkWidgetColor start="^\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidget,tcltkWidgetSwitch,tcltkSwitch,tclNumber,tclVarRef,tclString +syn region tcltkWidget matchgroup=tcltkWidgetColor start="\s\\|\[\"hs=s+1 matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidget,tcltkWidgetSwitch,tclString,tcltkSwitch,tclNumber,tclVarRef + +" This isn't contained (I don't think) so it's OK to just associate with the Color group. +" TODO: This could be wrong. +syn keyword tcltkWidgetColor toplevel + + +syn region tcltkPackConf matchgroup=tcltkPackConfColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tcltkPackConfSwitch,tclNumber,tclVarRef keepend +syn region tcltkPackConf matchgroup=tcltkPackConfColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"me=e-1 contains=tclLineContinue,tcltkWidgetSwitch,tclString,tcltkSwitch,tcltkPackConfSwitch,tclNumber,tclVarRef + + +" NAMESPACE +" commands associated with namespace +syn keyword tcltkNamespaceSwitch contained children code current delete eval +syn keyword tcltkNamespaceSwitch contained export forget import inscope origin +syn keyword tcltkNamespaceSwitch contained parent qualifiers tail which command variable +syn region tcltkCommand matchgroup=tcltkCommandColor start="\" matchgroup=NONE skip="^\s*$" end="{\|}\|]\|\"\|[^\\]*\s*$"me=e-1 contains=tclLineContinue,tcltkNamespaceSwitch + +" EXPR +" commands associated with expr +syn keyword tcltkMaths contained abs acos asin atan atan2 bool ceil cos cosh double entier +syn keyword tcltkMaths contained exp floor fmod hypot int isqrt log log10 max min pow rand +syn keyword tcltkMaths contained round sin sinh sqrt srand tan tanh wide + +syn region tcltkCommand matchgroup=tcltkCommandColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"me=e-1 contains=tclLineContinue,tcltkMaths,tclNumber,tclVarRef,tclString,tcltlWidgetSwitch,tcltkCommand,tcltkPackConf + +" format +syn region tcltkCommand matchgroup=tcltkCommandColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"me=e-1 contains=tclLineContinue,tcltkMaths,tclNumber,tclVarRef,tclString,tcltlWidgetSwitch,tcltkCommand,tcltkPackConf + +" PACK +" commands associated with pack +syn keyword tcltkPackSwitch contained forget info propogate slaves +syn keyword tcltkPackConfSwitch contained after anchor before expand fill in ipadx ipady padx pady side +syn region tcltkCommand matchgroup=tcltkCommandColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkPackSwitch,tcltkPackConf,tcltkPackConfSwitch,tclNumber,tclVarRef,tclString,tcltkCommand keepend + +" STRING +" commands associated with string +syn keyword tcltkStringSwitch contained compare first index last length match range tolower toupper trim trimleft trimright wordstart wordend +syn region tcltkCommand matchgroup=tcltkCommandColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkStringSwitch,tclNumber,tclVarRef,tclString,tcltkCommand + +" ARRAY +" commands associated with array +syn keyword tcltkArraySwitch contained anymore donesearch exists get names nextelement size startsearch set +" match from command name to ] or EOL +syn region tcltkCommand matchgroup=tcltkCommandColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkArraySwitch,tclNumber,tclVarRef,tclString,tcltkCommand + +" LSORT +" switches for lsort +syn keyword tcltkLsortSwitch contained ascii dictionary integer real command increasing decreasing index +" match from command name to ] or EOL +syn region tcltkCommand matchgroup=tcltkCommandColor start="\" matchgroup=NONE skip="^\s*$" end="]\|[^\\]*\s*$"he=e-1 contains=tclLineContinue,tcltkLsortSwitch,tclNumber,tclVarRef,tclString,tcltkCommand + +syn keyword tclTodo contained TODO + +" Sequences which are backslash-escaped: http://www.tcl.tk/man/tcl8.5/TclCmd/Tcl.htm#M16 +" Octal, hexadecimal, unicode codepoints, and the classics. +" Tcl takes as many valid characters in a row as it can, so \xAZ in a string is newline followed by 'Z'. +syn match tclSpecial contained '\\\([0-7]\{1,3}\|x\x\{1,2}\|u\x\{1,4}\|[abfnrtv]\)' +syn match tclSpecial contained '\\[\[\]\{\}\"\$]' + +" Command appearing inside another command or inside a string. +syn region tclEmbeddedStatement start='\[' end='\]' contained contains=tclCommand,tclNumber,tclLineContinue,tclString,tclVarRef,tclEmbeddedStatement +" A string needs the skip argument as it may legitimately contain \". +" Match at start of line +syn region tclString start=+^"+ end=+"+ contains=@tclSpecialC skip=+\\\\\|\\"+ +"Match all other legal strings. +syn region tclString start=+[^\\]"+ms=s+1 end=+"+ contains=@tclSpecialC,@tclVarRefC,tclEmbeddedStatement skip=+\\\\\|\\"+ + +" Line continuation is backslash immediately followed by newline. +syn match tclLineContinue '\\$' + +if exists('g:tcl_warn_continuation') + syn match tclNotLineContinue '\\\s\+$' +endif + +"integer number, or floating point number without a dot and with "f". +syn case ignore +syn match tclNumber "\<\d\+\(u\=l\=\|lu\|f\)\>" +"floating point number, with dot, optional exponent +syn match tclNumber "\<\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, starting with a dot, optional exponent +syn match tclNumber "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match tclNumber "\<\d\+e[-+]\=\d\+[fl]\=\>" +"hex number +syn match tclNumber "0x[0-9a-f]\+\(u\=l\=\|lu\)\>" +"syn match tclIdentifier "\<[a-z_][a-z0-9_]*\>" +syn case match + +syn region tclComment start="^\s*\#" skip="\\$" end="$" contains=tclTodo +syn region tclComment start=/;\s*\#/hs=s+1 skip="\\$" end="$" contains=tclTodo + +"syn match tclComment /^\s*\#.*$/ +"syn match tclComment /;\s*\#.*$/hs=s+1 + +"syn sync ccomment tclComment + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link tcltkSwitch Special +hi def link tclExpand Special +hi def link tclLabel Label +hi def link tclConditional Conditional +hi def link tclRepeat Repeat +hi def link tclNumber Number +hi def link tclError Error +hi def link tclCommand Statement +hi def link tclProcCommand Type +hi def link tclString String +hi def link tclComment Comment +hi def link tclSpecial Special +hi def link tclTodo Todo +" Below here are the commands and their options. +hi def link tcltkCommandColor Statement +hi def link tcltkWidgetColor Structure +hi def link tclLineContinue WarningMsg +if exists('g:tcl_warn_continuation') +hi def link tclNotLineContinue ErrorMsg +endif +hi def link tcltkStringSwitch Special +hi def link tcltkArraySwitch Special +hi def link tcltkLsortSwitch Special +hi def link tcltkPackSwitch Special +hi def link tcltkPackConfSwitch Special +hi def link tcltkMaths Special +hi def link tcltkNamespaceSwitch Special +hi def link tcltkWidgetSwitch Special +hi def link tcltkPackConfColor Identifier +hi def link tclVarRef Identifier + + +let b:current_syntax = "tcl" + +" vim: ts=8 noet nolist + +endif diff --git a/syntax/tcsh.vim b/syntax/tcsh.vim new file mode 100644 index 0000000..cd0dce2 --- /dev/null +++ b/syntax/tcsh.vim @@ -0,0 +1,252 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" tcsh.vim: Vim syntax file for tcsh scripts +" Maintainer: Gautam Iyer +" Modified: Thu 17 Dec 2009 06:05:07 PM EST +" +" Description: We break up each statement into a "command" and an "end" part. +" All groups are either a "command" or part of the "end" of a statement (ie +" everything after the "command"). This is because blindly highlighting tcsh +" statements as keywords caused way too many false positives. Eg: +" +" set history=200 +" +" causes history to come up as a keyword, which we want to avoid. + +" Quit when a syntax file was already loaded +if exists('b:current_syntax') + finish +endif + +let s:oldcpo = &cpo +set cpo&vim " Line continuation is used + +setlocal iskeyword+=- + +syn case match + +" ----- Clusters ----- +syn cluster tcshModifiers contains=tcshModifier,tcshModifierError +syn cluster tcshQuoteList contains=tcshDQuote,tcshSQuote,tcshBQuote +syn cluster tcshStatementEnds contains=@tcshQuoteList,tcshComment,@tcshVarList,tcshRedir,tcshMeta,tcshHereDoc,tcshSpecial,tcshArguement +syn cluster tcshStatements contains=tcshBuiltin,tcshCommands,tcshIf,tcshWhile +syn cluster tcshVarList contains=tcshUsrVar,tcshArgv,tcshSubst +syn cluster tcshConditions contains=tcshCmdSubst,tcshParenExpr,tcshOperator,tcshNumber,@tcshVarList + +" ----- Errors ----- +" Define first, so can be easily overridden. +syn match tcshError contained '\v\S.+' + +" ----- Statements ----- +" Tcsh commands: Any filename / modifiable variable (must be first!) +syn match tcshCommands '\v[a-zA-Z0-9\\./_$:-]+' contains=tcshSpecial,tcshUsrVar,tcshArgv,tcshVarError nextgroup=tcshStatementEnd + +" Builtin commands except those treated specially. Currently (un)set(env), +" (un)alias, if, while, else, bindkey +syn keyword tcshBuiltin nextgroup=tcshStatementEnd alloc bg break breaksw builtins bye case cd chdir complete continue default dirs echo echotc end endif endsw eval exec exit fg filetest foreach getspath getxvers glob goto hashstat history hup inlib jobs kill limit log login logout ls ls-F migrate newgrp nice nohup notify onintr popd printenv pushd rehash repeat rootnode sched setpath setspath settc setty setxvers shift source stop suspend switch telltc time umask uncomplete unhash universe unlimit ver wait warp watchlog where which + +" StatementEnd is anything after a built-in / command till the lexical end of a +" statement (;, |, ||, |&, && or end of line) +syn region tcshStatementEnd transparent contained matchgroup=tcshBuiltin start='' end='\v\\@|$' contains=@tcshConditions,tcshSpecial,@tcshStatementEnds +syn region tcshIfEnd contained matchgroup=tcshBuiltin contains=@tcshConditions,tcshSpecial start='(' end='\v\)%(\s+then>)?' skipwhite nextgroup=@tcshStatementEnds +syn region tcshIfEnd contained matchgroup=tcshBuiltin contains=tcshCommands,tcshSpecial start='\v\{\s+' end='\v\s+\}%(\s+then>)?' skipwhite nextgroup=@tcshStatementEnds keepend + +" else statements +syn keyword tcshBuiltin nextgroup=tcshIf skipwhite else + +" while statements (contains expressions / operators) +syn keyword tcshBuiltin nextgroup=@tcshConditions,tcshSpecial skipwhite while + +" Conditions (for if and while) +syn region tcshParenExpr contained contains=@tcshConditions,tcshSpecial matchgroup=tcshBuiltin start='(' end=')' +syn region tcshCmdSubst contained contains=tcshCommands matchgroup=tcshBuiltin start='\v\{\s+' end='\v\s+\}' keepend + +" Bindkey. Internal editor functions +syn keyword tcshBindkeyFuncs contained backward-char backward-delete-char + \ backward-delete-word backward-kill-line backward-word + \ beginning-of-line capitalize-word change-case + \ change-till-end-of-line clear-screen complete-word + \ complete-word-fwd complete-word-back complete-word-raw + \ copy-prev-word copy-region-as-kill dabbrev-expand delete-char + \ delete-char-or-eof delete-char-or-list + \ delete-char-or-list-or-eof delete-word digit digit-argument + \ down-history downcase-word end-of-file end-of-line + \ exchange-point-and-mark expand-glob expand-history expand-line + \ expand-variables forward-char forward-word + \ gosmacs-transpose-chars history-search-backward + \ history-search-forward insert-last-word i-search-fwd + \ i-search-back keyboard-quit kill-line kill-region + \ kill-whole-line list-choices list-choices-raw list-glob + \ list-or-eof load-average magic-space newline normalize-path + \ normalize-command overwrite-mode prefix-meta quoted-insert + \ redisplay run-fg-editor run-help self-insert-command + \ sequence-lead-in set-mark-command spell-word spell-line + \ stuff-char toggle-literal-history transpose-chars + \ transpose-gosling tty-dsusp tty-flush-output tty-sigintr + \ tty-sigquit tty-sigtsusp tty-start-output tty-stop-output + \ undefined-key universal-argument up-history upcase-word + \ vi-beginning-of-next-word vi-add vi-add-at-eol vi-chg-case + \ vi-chg-meta vi-chg-to-eol vi-cmd-mode vi-cmd-mode-complete + \ vi-delprev vi-delmeta vi-endword vi-eword vi-char-back + \ vi-char-fwd vi-charto-back vi-charto-fwd vi-insert + \ vi-insert-at-bol vi-repeat-char-fwd vi-repeat-char-back + \ vi-repeat-search-fwd vi-repeat-search-back vi-replace-char + \ vi-replace-mode vi-search-back vi-search-fwd vi-substitute-char + \ vi-substitute-line vi-word-back vi-word-fwd vi-undo vi-zero + \ which-command yank yank-pop e_copy_to_clipboard + \ e_paste_from_clipboard e_dosify_next e_dosify_prev e_page_up + \ e_page_down +syn keyword tcshBuiltin nextgroup=tcshBindkeyEnd bindkey +syn region tcshBindkeyEnd contained transparent matchgroup=tcshBuiltin start='' skip='\\$' end='$' contains=@tcshQuoteList,tcshComment,@tcshVarList,tcshMeta,tcshSpecial,tcshArguement,tcshBindkeyFuncs + +" Expressions start with @. +syn match tcshExprStart '\v\@\s+' nextgroup=tcshExprVar +syn match tcshExprVar contained '\v\h\w*%(\[\d+\])?' contains=tcshShellVar,tcshEnvVar nextgroup=tcshExprOp +syn match tcshExprOp contained '++\|--' +syn match tcshExprOp contained '\v\s*\=' nextgroup=tcshExprEnd +syn match tcshExprEnd contained '\v.*$'hs=e+1 contains=@tcshConditions +syn match tcshExprEnd contained '\v.{-};'hs=e contains=@tcshConditions + +" ----- Comments: ----- +syn match tcshComment '#\s.*' contains=tcshTodo,tcshCommentTi,@Spell +syn match tcshComment '\v#($|\S.*)' contains=tcshTodo,tcshCommentTi +syn match tcshSharpBang '^#! .*$' +syn match tcshCommentTi contained '\v#\s*\u\w*(\s+\u\w*)*:'hs=s+1 contains=tcshTodo +syn match tcshTodo contained '\v\c' + +" ----- Strings ----- +" Tcsh does not allow \" in strings unless the "backslash_quote" shell +" variable is set. Set the vim variable "tcsh_backslash_quote" to 0 if you +" want VIM to assume that no backslash quote constructs exist. + +" Backquotes are treated as commands, and are not contained in anything +if(exists('tcsh_backslash_quote') && tcsh_backslash_quote == 0) + syn region tcshSQuote keepend contained start="\v\\@, >>, >>&, >>!, >>&!] +syn match tcshRedir contained '\v\<|\>\>?\&?!?' + +" Meta-chars +syn match tcshMeta contained '\v[]{}*?[]' + +" Here documents (<<) +syn region tcshHereDoc contained matchgroup=tcshShellVar start='\v\<\<\s*\z(\h\w*)' end='^\z1$' contains=@tcshVarList,tcshSpecial +syn region tcshHereDoc contained matchgroup=tcshShellVar start="\v\<\<\s*'\z(\h\w*)'" start='\v\<\<\s*"\z(\h\w*)"$' start='\v\<\<\s*\\\z(\h\w*)$' end='^\z1$' + +" Operators +syn match tcshOperator contained '&&\|!\~\|!=\|<<\|<=\|==\|=\~\|>=\|>>\|\*\|\^\|\~\|||\|!\|%\|&\|+\|-\|/\|<\|>\||' +"syn match tcshOperator contained '[(){}]' + +" Numbers +syn match tcshNumber contained '\v<-?\d+>' + +" Arguments +syn match tcshArguement contained '\v\s@<=-(\w|-)*' + +" Special characters. \xxx, or backslashed characters. +"syn match tcshSpecial contained '\v\\@" +syn match ttlNumber "\%(\<\d\+\|\$\x\+\)\>" +syn match ttlString "'[^']*'" contains=@Spell +syn match ttlString '"[^"]*"' contains=@Spell +syn cluster ttlConstant contains=ttlCharacter,ttlNumber,ttlString + +syn match ttlLabel ":\s*\w\{1,32}\>" + +syn keyword ttlOperator and or xor not + +syn match ttlVar "\" +syn match ttlVar "\" +syn keyword ttlVar inputstr matchstr paramcnt params result timeout mtimeout + + +syn match ttlLine nextgroup=ttlStatement "^" +syn match ttlStatement contained "\s*" + \ nextgroup=ttlIf,ttlElseIf,ttlConditional,ttlRepeat, + \ ttlFirstComment,ttlComment,ttlLabel,@ttlCommand + +syn cluster ttlCommand contains=ttlControlCommand,ttlCommunicationCommand, + \ ttlStringCommand,ttlFileCommand,ttlPasswordCommand, + \ ttlMiscCommand + + +syn keyword ttlIf contained nextgroup=ttlIfExpression if +syn keyword ttlElseIf contained nextgroup=ttlElseIfExpression elseif + +syn match ttlIfExpression contained "\s.*" + \ contains=@ttlConstant,ttlVar,ttlOperator,ttlComment,ttlThen, + \ @ttlCommand +syn match ttlElseIfExpression contained "\s.*" + \ contains=@ttlConstant,ttlVar,ttlOperator,ttlComment,ttlThen + +syn keyword ttlThen contained then +syn keyword ttlConditional contained else endif + +syn keyword ttlRepeat contained for next until enduntil while endwhile +syn match ttlRepeat contained + \ "\<\%(do\|loop\)\%(\s\+\%(while\|until\)\)\?\>" +syn keyword ttlControlCommand contained + \ break call continue end execcmnd exit goto include + \ mpause pause return + + +syn keyword ttlCommunicationCommand contained + \ bplusrecv bplussend callmenu changedir clearscreen + \ closett connect cygconnect disconnect dispstr + \ enablekeyb flushrecv gethostname getmodemstatus + \ gettitle kmtfinish kmtget kmtrecv kmtsend loadkeymap + \ logautoclosemode logclose loginfo logopen logpause + \ logrotate logstart logwrite quickvanrecv + \ quickvansend recvln restoresetup scprecv scpsend + \ send sendbreak sendbroadcast sendfile sendkcode + \ sendln sendlnbroadcast sendmulticast setbaud + \ setdebug setdtr setecho setmulticastname setrts + \ setsync settitle showtt testlink unlink wait + \ wait4all waitevent waitln waitn waitrecv waitregex + \ xmodemrecv xmodemsend ymodemrecv ymodemsend + \ zmodemrecv zmodemsend +syn keyword ttlStringCommand contained + \ code2str expandenv int2str regexoption sprintf + \ sprintf2 str2code str2int strcompare strconcat + \ strcopy strinsert strjoin strlen strmatch strremove + \ strreplace strscan strspecial strsplit strtrim + \ tolower toupper +syn keyword ttlFileCommand contained + \ basename dirname fileclose fileconcat filecopy + \ filecreate filedelete filelock filemarkptr fileopen + \ filereadln fileread filerename filesearch fileseek + \ fileseekback filestat filestrseek filestrseek2 + \ filetruncate fileunlock filewrite filewriteln + \ findfirst findnext findclose foldercreate + \ folderdelete foldersearch getdir getfileattr makepath + \ setdir setfileattr +syn keyword ttlPasswordCommand contained + \ delpassword getpassword ispassword passwordbox + \ setpassword +syn keyword ttlMiscCommand contained + \ beep bringupbox checksum8 checksum8file checksum16 + \ checksum16file checksum32 checksum32file closesbox + \ clipb2var crc16 crc16file crc32 crc32file exec + \ dirnamebox filenamebox getdate getenv getipv4addr + \ getipv6addr getspecialfolder gettime getttdir getver + \ ifdefined inputbox intdim listbox messagebox random + \ rotateleft rotateright setdate setdlgpos setenv + \ setexitcode settime show statusbox strdim uptime + \ var2clipb yesnobox + + +hi def link ttlCharacter Character +hi def link ttlNumber Number +hi def link ttlComment Comment +hi def link ttlFirstComment Comment +hi def link ttlString String +hi def link ttlLabel Label +hi def link ttlIf Conditional +hi def link ttlElseIf Conditional +hi def link ttlThen Conditional +hi def link ttlConditional Conditional +hi def link ttlRepeat Repeat +hi def link ttlControlCommand Keyword +hi def link ttlVar Identifier +hi def link ttlOperator Operator +hi def link ttlCommunicationCommand Keyword +hi def link ttlStringCommand Keyword +hi def link ttlFileCommand Keyword +hi def link ttlPasswordCommand Keyword +hi def link ttlMiscCommand Keyword + +let b:current_syntax = "teraterm" + +let &cpo = s:save_cpo +unlet s:save_cpo + +" vim: ts=8 sw=2 sts=2 + +endif diff --git a/syntax/terminfo.vim b/syntax/terminfo.vim new file mode 100644 index 0000000..cb71f9f --- /dev/null +++ b/syntax/terminfo.vim @@ -0,0 +1,97 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: terminfo(5) definition +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match terminfoKeywords '[,=#|]' + +syn keyword terminfoTodo contained TODO FIXME XXX NOTE + +syn region terminfoComment display oneline start='^#' end='$' + \ contains=terminfoTodo,@Spell + +syn match terminfoNumbers '\<[0-9]\+\>' + +syn match terminfoSpecialChar '\\\(\o\{3}\|[Eenlrtbfs^\,:0]\)' +syn match terminfoSpecialChar '\^\a' + +syn match terminfoDelay '$<[0-9]\+>' + +syn keyword terminfoBooleans bw am bce ccc xhp xhpa cpix crxw xt xenl eo gn + \ hc chts km daisy hs hls in lpix da db mir + \ msgr nxon xsb npc ndscr nrrmc os mc5i xcpa + \ sam eslok hz ul xon + +syn keyword terminfoNumerics cols it lh lw lines lm xmc ma colors pairs wnum + \ ncv nlab pb vt wsl bitwin bitype bufsz btns + \ spinh spinv maddr mjump mcs npins orc orhi + \ orl orvi cps widcs + +syn keyword terminfoStrings acsc cbt bel cr cpi lpi chr cvr csr rmp tbc mgc + \ clear el1 el ed hpa cmdch cwin cup cud1 home + \ civis cub1 mrcup cnorm cuf1 ll cuu1 cvvis + \ defc dch1 dl1 dial dsl dclk hd enacs smacs + \ smam blink bold smcup smdc dim swidm sdrfq + \ smir sitm slm smicm snlq snrmq prot rev + \ invis sshm smso ssubm ssupm smul sum smxon + \ ech rmacs rmam sgr0 rmcup rmdc rwidm rmir + \ ritm rlm rmicm rshm rmso rsubm rsupm rmul + \ rum rmxon pause hook flash ff fsl wingo hup + \ is1 is2 is3 if iprog initc initp ich1 il1 ip + \ ka1 ka3 kb2 kbs kbeg kcbt kc1 kc3 kcan ktbc + \ kclr kclo kcmd kcpy kcrt kctab kdch1 kdl1 + \ kcud1 krmir kend kent kel ked kext kfnd khlp + \ khome kich1 kil1 kcub1 kll kmrk kmsg kmov + \ knxt knp kopn kopt kpp kprv kprt krdo kref + \ krfr krpl krst kres kcuf1 ksav kBEG kCAN + \ kCMD kCPY kCRT kDC kDL kslt kEND kEOL kEXT + \ kind kFND kHLP kHOM kIC kLFT kMSG kMOV kNXT + \ kOPT kPRV kPRT kri kRDO kRPL kRIT kRES kSAV + \ kSPD khts kUND kspd kund kcuu1 rmkx smkx + \ lf0 lf1 lf10 lf2 lf3 lf4 lf5 lf6 lf7 lf8 lf9 + \ fln rmln smln rmm smm mhpa mcud1 mcub1 mcuf1 + \ mvpa mcuu1 nel porder oc op pad dch dl cud + \ mcud ich indn il cub mcub cuf mcuf rin cuu + \ mccu pfkey pfloc pfx pln mc0 mc5p mc4 mc5 + \ pulse qdial rmclk rep rfi rs1 rs2 rs3 rf rc + \ vpa sc ind ri scs sgr setbsmgb smgbp sclk + \ scp setb setf smgl smglp smgr smgrp hts smgt + \ smgtp wind sbim scsd rbim rcsd subcs supcs + \ ht docr tsl tone uc hu u0 u1 u2 u3 u4 u5 u6 + \ u7 u8 u9 wait xoffc xonc zerom scesa bicr + \ binel birep csnm csin colornm defbi devt + \ dispc endbi smpch smsc rmpch rmsc getm kmous + \ minfo pctrm pfxl reqmp scesc s0ds s1ds s2ds + \ s3ds setab setaf setcolor smglr slines smgtb + \ ehhlm elhlm erhlm ethlm evhlm sgr1 slengthsL +syn match terminfoStrings display '\' + +syn match terminfoParameters '%[%dcspl+*/mAO&|^=<>!~i?te;-]' +syn match terminfoParameters "%\('[A-Z]'\|{[0-9]\{1,2}}\|p[1-9]\|P[a-z]\|g[A-Z]\)" + +hi def link terminfoComment Comment +hi def link terminfoTodo Todo +hi def link terminfoNumbers Number +hi def link terminfoSpecialChar SpecialChar +hi def link terminfoDelay Special +hi def link terminfoBooleans Type +hi def link terminfoNumerics Type +hi def link terminfoStrings Type +hi def link terminfoParameters Keyword +hi def link terminfoKeywords Keyword + +let b:current_syntax = "terminfo" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/tex.vim b/syntax/tex.vim new file mode 100644 index 0000000..2fb5107 --- /dev/null +++ b/syntax/tex.vim @@ -0,0 +1,1382 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TeX +" Maintainer: Charles E. Campbell +" Last Change: Jan 31, 2017 +" Version: 103 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_TEX +" +" Notes: {{{1 +" +" 1. If you have a \begin{verbatim} that appears to overrun its boundaries, +" use %stopzone. +" +" 2. Run-on equations ($..$ and $$..$$, particularly) can also be stopped +" by suitable use of %stopzone. +" +" 3. If you have a slow computer, you may wish to modify +" +" syn sync maxlines=200 +" syn sync minlines=50 +" +" to values that are more to your liking. +" +" 4. There is no match-syncing for $...$ and $$...$$; hence large +" equation blocks constructed that way may exhibit syncing problems. +" (there's no difference between begin/end patterns) +" +" 5. If you have the variable "g:tex_no_error" defined then none of the +" lexical error-checking will be done. +" +" ie. let g:tex_no_error=1 +" +" 6. Please see :help latex-syntax for information on +" syntax folding :help tex-folding +" spell checking :help tex-nospell +" commands and mathzones :help tex-runon +" new command highlighting :help tex-morecommands +" error highlighting :help tex-error +" new math groups :help tex-math +" new styles :help tex-style +" using conceal mode :help tex-conceal + +" Version Clears: {{{1 +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim +scriptencoding utf-8 + +" by default, enable all region-based highlighting +let s:tex_fast= "bcmMprsSvV" +if exists("g:tex_fast") + if type(g:tex_fast) != 1 + " g:tex_fast exists and is not a string, so + " turn off all optional region-based highighting + let s:tex_fast= "" + else + let s:tex_fast= g:tex_fast + endif +endif + +" let user determine which classes of concealment will be supported +" a=accents/ligatures d=delimiters m=math symbols g=Greek s=superscripts/subscripts +if !exists("g:tex_conceal") + let s:tex_conceal= 'abdmgsS' +else + let s:tex_conceal= g:tex_conceal +endif +if !exists("g:tex_superscripts") + let s:tex_superscripts= '[0-9a-zA-W.,:;+-<>/()=]' +else + let s:tex_superscripts= g:tex_superscripts +endif +if !exists("g:tex_subscripts") + let s:tex_subscripts= '[0-9aehijklmnoprstuvx,+-/().]' +else + let s:tex_subscripts= g:tex_subscripts +endif + +" Determine whether or not to use "*.sty" mode {{{1 +" The user may override the normal determination by setting +" g:tex_stylish to 1 (for "*.sty" mode) +" or to 0 else (normal "*.tex" mode) +" or on a buffer-by-buffer basis with b:tex_stylish +let s:extfname=expand("%:e") +if exists("g:tex_stylish") + let b:tex_stylish= g:tex_stylish +elseif !exists("b:tex_stylish") + if s:extfname == "sty" || s:extfname == "cls" || s:extfname == "clo" || s:extfname == "dtx" || s:extfname == "ltx" + let b:tex_stylish= 1 + else + let b:tex_stylish= 0 + endif +endif + +" handle folding {{{1 +if !exists("g:tex_fold_enabled") + let s:tex_fold_enabled= 0 +elseif g:tex_fold_enabled && !has("folding") + let s:tex_fold_enabled= 0 + echomsg "Ignoring g:tex_fold_enabled=".g:tex_fold_enabled."; need to re-compile vim for +fold support" +else + let s:tex_fold_enabled= 1 +endif +if s:tex_fold_enabled && &fdm == "manual" + setl fdm=syntax +endif +if s:tex_fold_enabled && has("folding") + com! -nargs=* TexFold fold +else + com! -nargs=* TexFold +endif + +" (La)TeX keywords: uses the characters 0-9,a-z,A-Z,192-255 only... {{{1 +" but _ is the only one that causes problems. +" One may override this iskeyword setting by providing +" g:tex_isk +if exists("g:tex_isk") + if b:tex_stylish && g:tex_isk !~ '@' + let b:tex_isk= '@,'.g:tex_isk + else + let b:tex_isk= g:tex_isk + endif +elseif b:tex_stylish + let b:tex_isk="@,48-57,a-z,A-Z,192-255" +else + let b:tex_isk="48-57,a-z,A-Z,192-255" +endif +if v:version > 704 || (v:version == 704 && has("patch-7.4.1142")) + exe "syn iskeyword ".b:tex_isk +else + exe "setl isk=".b:tex_isk +endif +if exists("g:tex_no_error") && g:tex_no_error + let s:tex_no_error= 1 +else + let s:tex_no_error= 0 +endif +if exists("g:tex_comment_nospell") && g:tex_comment_nospell + let s:tex_comment_nospell= 1 +else + let s:tex_comment_nospell= 0 +endif +if exists("g:tex_nospell") && g:tex_nospell + let s:tex_nospell = 1 +else + let s:tex_nospell = 0 +endif + +" Clusters: {{{1 +" -------- +syn cluster texCmdGroup contains=texCmdBody,texComment,texDefParm,texDelimiter,texDocType,texInput,texLength,texLigature,texMathDelim,texMathOper,texNewCmd,texNewEnv,texRefZone,texSection,texBeginEnd,texBeginEndName,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,@texMathZones +if !s:tex_no_error + syn cluster texCmdGroup add=texMathError +endif +syn cluster texEnvGroup contains=texMatcher,texMathDelim,texSpecialChar,texStatement +syn cluster texFoldGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texBoldStyle,texItalStyle,texNoSpell +syn cluster texBoldGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texBoldStyle,texBoldItalStyle,texNoSpell +syn cluster texItalGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texItalStyle,texItalBoldStyle,texNoSpell +if !s:tex_nospell + syn cluster texMatchGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcher,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,texInputFile,texOption,@Spell + syn cluster texMatchNMGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcherNM,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,texInputFile,texOption,@Spell + syn cluster texStyleGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,texInputFile,texOption,texStyleStatement,@Spell,texStyleMatcher +else + syn cluster texMatchGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcher,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,texInputFile,texOption + syn cluster texMatchNMGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcherNM,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,texInputFile,texOption + syn cluster texStyleGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,texInputFile,texOption,texStyleStatement,texStyleMatcher +endif +syn cluster texPreambleMatchGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcherNM,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTitle,texTypeSize,texTypeStyle,texZone,texInputFile,texOption,texMathZoneZ +syn cluster texRefGroup contains=texMatcher,texComment,texDelimiter +if !exists("g:tex_no_math") + syn cluster texPreambleMatchGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcherNM,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTitle,texTypeSize,texTypeStyle,texZone,texInputFile,texOption,texMathZoneZ + syn cluster texMathZones contains=texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ + syn cluster texMatchGroup add=@texMathZones + syn cluster texMathDelimGroup contains=texMathDelimBad,texMathDelimKey,texMathDelimSet1,texMathDelimSet2 + syn cluster texMathMatchGroup contains=@texMathZones,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMathDelim,texMathMatcher,texMathOper,texNewCmd,texNewEnv,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone + syn cluster texMathZoneGroup contains=texComment,texDelimiter,texLength,texMathDelim,texMathMatcher,texMathOper,texMathSymbol,texMathText,texRefZone,texSpecialChar,texStatement,texTypeSize,texTypeStyle + if !s:tex_no_error + syn cluster texMathMatchGroup add=texMathError + syn cluster texMathZoneGroup add=texMathError + endif + syn cluster texMathZoneGroup add=@NoSpell + " following used in the \part \chapter \section \subsection \subsubsection + " \paragraph \subparagraph \author \title highlighting + syn cluster texDocGroup contains=texPartZone,@texPartGroup + syn cluster texPartGroup contains=texChapterZone,texSectionZone,texParaZone + syn cluster texChapterGroup contains=texSectionZone,texParaZone + syn cluster texSectionGroup contains=texSubSectionZone,texParaZone + syn cluster texSubSectionGroup contains=texSubSubSectionZone,texParaZone + syn cluster texSubSubSectionGroup contains=texParaZone + syn cluster texParaGroup contains=texSubParaZone + if has("conceal") && &enc == 'utf-8' + syn cluster texMathZoneGroup add=texGreek,texSuperscript,texSubscript,texMathSymbol + syn cluster texMathMatchGroup add=texGreek,texSuperscript,texSubscript,texMathSymbol + endif +endif + +" Try to flag {} and () mismatches: {{{1 +if s:tex_fast =~# 'm' + if !s:tex_no_error + syn region texMatcher matchgroup=Delimiter start="{" skip="\\\\\|\\[{}]" end="}" transparent contains=@texMatchGroup,texError + syn region texMatcher matchgroup=Delimiter start="\[" end="]" transparent contains=@texMatchGroup,texError,@NoSpell + syn region texMatcherNM matchgroup=Delimiter start="{" skip="\\\\\|\\[{}]" end="}" transparent contains=@texMatchNMGroup,texError + syn region texMatcherNM matchgroup=Delimiter start="\[" end="]" transparent contains=@texMatchNMGroup,texError,@NoSpell + else + syn region texMatcher matchgroup=Delimiter start="{" skip="\\\\\|\\[{}]" end="}" transparent contains=@texMatchGroup + syn region texMatcher matchgroup=Delimiter start="\[" end="]" transparent contains=@texMatchGroup + syn region texMatcherNM matchgroup=Delimiter start="{" skip="\\\\\|\\[{}]" end="}" transparent contains=@texMatchNMGroup + syn region texMatcherNM matchgroup=Delimiter start="\[" end="]" transparent contains=@texMatchNMGroup + endif + if !s:tex_nospell + syn region texParen start="(" end=")" transparent contains=@texMatchGroup,@Spell + else + syn region texParen start="(" end=")" transparent contains=@texMatchGroup + endif +endif +if !s:tex_no_error + syn match texError "[}\])]" +endif +if s:tex_fast =~# 'M' + if !exists("g:tex_no_math") + if !s:tex_no_error + syn match texMathError "}" contained + endif + syn region texMathMatcher matchgroup=Delimiter start="{" skip="\%(\\\\\)*\\}" end="}" end="%stopzone\>" contained contains=@texMathMatchGroup + endif +endif + +" TeX/LaTeX keywords: {{{1 +" Instead of trying to be All Knowing, I just match \..alphameric.. +" Note that *.tex files may not have "@" in their \commands +if exists("g:tex_tex") || b:tex_stylish + syn match texStatement "\\[a-zA-Z@]\+" +else + syn match texStatement "\\\a\+" + if !s:tex_no_error + syn match texError "\\\a*@[a-zA-Z@]*" + endif +endif + +" TeX/LaTeX delimiters: {{{1 +syn match texDelimiter "&" +syn match texDelimiter "\\\\" + +" Tex/Latex Options: {{{1 +syn match texOption "[^\\]\zs#\d\+\|^#\d\+" + +" texAccent (tnx to Karim Belabas) avoids annoying highlighting for accents: {{{1 +if b:tex_stylish + syn match texAccent "\\[bcdvuH][^a-zA-Z@]"me=e-1 + syn match texLigature "\\\([ijolL]\|ae\|oe\|ss\|AA\|AE\|OE\)[^a-zA-Z@]"me=e-1 +else + syn match texAccent "\\[bcdvuH]\A"me=e-1 + syn match texLigature "\\\([ijolL]\|ae\|oe\|ss\|AA\|AE\|OE\)\A"me=e-1 +endif +syn match texAccent "\\[bcdvuH]$" +syn match texAccent +\\[=^.\~"`']+ +syn match texAccent +\\['=t'.c^ud"vb~Hr]{\a}+ +syn match texLigature "\\\([ijolL]\|ae\|oe\|ss\|AA\|AE\|OE\)$" + +" \begin{}/\end{} section markers: {{{1 +syn match texBeginEnd "\\begin\>\|\\end\>" nextgroup=texBeginEndName +if s:tex_fast =~# 'm' + syn region texBeginEndName matchgroup=Delimiter start="{" end="}" contained nextgroup=texBeginEndModifier contains=texComment + syn region texBeginEndModifier matchgroup=Delimiter start="\[" end="]" contained contains=texComment,@texMathZones,@NoSpell +endif + +" \documentclass, \documentstyle, \usepackage: {{{1 +syn match texDocType "\\documentclass\>\|\\documentstyle\>\|\\usepackage\>" nextgroup=texBeginEndName,texDocTypeArgs +if s:tex_fast =~# 'm' + syn region texDocTypeArgs matchgroup=Delimiter start="\[" end="]" contained nextgroup=texBeginEndName contains=texComment,@NoSpell +endif + +" Preamble syntax-based folding support: {{{1 +if s:tex_fold_enabled && has("folding") + syn region texPreamble transparent fold start='\zs\\documentclass\>' end='\ze\\begin{document}' contains=texStyle,@texPreambleMatchGroup +endif + +" TeX input: {{{1 +syn match texInput "\\input\s\+[a-zA-Z/.0-9_^]\+"hs=s+7 contains=texStatement +syn match texInputFile "\\include\(graphics\|list\)\=\(\[.\{-}\]\)\=\s*{.\{-}}" contains=texStatement,texInputCurlies,texInputFileOpt +syn match texInputFile "\\\(epsfig\|input\|usepackage\)\s*\(\[.*\]\)\={.\{-}}" contains=texStatement,texInputCurlies,texInputFileOpt +syn match texInputCurlies "[{}]" contained +if s:tex_fast =~# 'm' + syn region texInputFileOpt matchgroup=Delimiter start="\[" end="\]" contained contains=texComment +endif + +" Type Styles (LaTeX 2.09): {{{1 +syn match texTypeStyle "\\rm\>" +syn match texTypeStyle "\\em\>" +syn match texTypeStyle "\\bf\>" +syn match texTypeStyle "\\it\>" +syn match texTypeStyle "\\sl\>" +syn match texTypeStyle "\\sf\>" +syn match texTypeStyle "\\sc\>" +syn match texTypeStyle "\\tt\>" + +" Type Styles: attributes, commands, families, etc (LaTeX2E): {{{1 +if s:tex_conceal !~# 'b' + syn match texTypeStyle "\\textbf\>" + syn match texTypeStyle "\\textit\>" +endif +syn match texTypeStyle "\\textmd\>" +syn match texTypeStyle "\\textrm\>" +syn match texTypeStyle "\\textsc\>" +syn match texTypeStyle "\\textsf\>" +syn match texTypeStyle "\\textsl\>" +syn match texTypeStyle "\\texttt\>" +syn match texTypeStyle "\\textup\>" +syn match texTypeStyle "\\emph\>" + +syn match texTypeStyle "\\mathbb\>" +syn match texTypeStyle "\\mathbf\>" +syn match texTypeStyle "\\mathcal\>" +syn match texTypeStyle "\\mathfrak\>" +syn match texTypeStyle "\\mathit\>" +syn match texTypeStyle "\\mathnormal\>" +syn match texTypeStyle "\\mathrm\>" +syn match texTypeStyle "\\mathsf\>" +syn match texTypeStyle "\\mathtt\>" + +syn match texTypeStyle "\\rmfamily\>" +syn match texTypeStyle "\\sffamily\>" +syn match texTypeStyle "\\ttfamily\>" + +syn match texTypeStyle "\\itshape\>" +syn match texTypeStyle "\\scshape\>" +syn match texTypeStyle "\\slshape\>" +syn match texTypeStyle "\\upshape\>" + +syn match texTypeStyle "\\bfseries\>" +syn match texTypeStyle "\\mdseries\>" + +" Some type sizes: {{{1 +syn match texTypeSize "\\tiny\>" +syn match texTypeSize "\\scriptsize\>" +syn match texTypeSize "\\footnotesize\>" +syn match texTypeSize "\\small\>" +syn match texTypeSize "\\normalsize\>" +syn match texTypeSize "\\large\>" +syn match texTypeSize "\\Large\>" +syn match texTypeSize "\\LARGE\>" +syn match texTypeSize "\\huge\>" +syn match texTypeSize "\\Huge\>" + +" Spacecodes (TeX'isms): {{{1 +" \mathcode`\^^@="2201 \delcode`\(="028300 \sfcode`\)=0 \uccode`X=`X \lccode`x=`x +syn match texSpaceCode "\\\(math\|cat\|del\|lc\|sf\|uc\)code`"me=e-1 nextgroup=texSpaceCodeChar +syn match texSpaceCodeChar "`\\\=.\(\^.\)\==\(\d\|\"\x\{1,6}\|`.\)" contained + +" Sections, subsections, etc: {{{1 +if s:tex_fast =~# 'p' + if !s:tex_nospell + TexFold syn region texDocZone matchgroup=texSection start='\\begin\s*{\s*document\s*}' end='\\end\s*{\s*document\s*}' contains=@texFoldGroup,@texDocGroup,@Spell + TexFold syn region texPartZone matchgroup=texSection start='\\part\>' end='\ze\s*\\\%(part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texPartGroup,@Spell + TexFold syn region texChapterZone matchgroup=texSection start='\\chapter\>' end='\ze\s*\\\%(chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texChapterGroup,@Spell + TexFold syn region texSectionZone matchgroup=texSection start='\\section\>' end='\ze\s*\\\%(section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texSectionGroup,@Spell + TexFold syn region texSubSectionZone matchgroup=texSection start='\\subsection\>' end='\ze\s*\\\%(\%(sub\)\=section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texSubSectionGroup,@Spell + TexFold syn region texSubSubSectionZone matchgroup=texSection start='\\subsubsection\>' end='\ze\s*\\\%(\%(sub\)\{,2}section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texSubSubSectionGroup,@Spell + TexFold syn region texParaZone matchgroup=texSection start='\\paragraph\>' end='\ze\s*\\\%(paragraph\>\|\%(sub\)*section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texParaGroup,@Spell + TexFold syn region texSubParaZone matchgroup=texSection start='\\subparagraph\>' end='\ze\s*\\\%(\%(sub\)\=paragraph\>\|\%(sub\)*section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@Spell + TexFold syn region texTitle matchgroup=texSection start='\\\%(author\|title\)\>\s*{' end='}' contains=@texFoldGroup,@Spell + TexFold syn region texAbstract matchgroup=texSection start='\\begin\s*{\s*abstract\s*}' end='\\end\s*{\s*abstract\s*}' contains=@texFoldGroup,@Spell + else + TexFold syn region texDocZone matchgroup=texSection start='\\begin\s*{\s*document\s*}' end='\\end\s*{\s*document\s*}' contains=@texFoldGroup,@texDocGroup + TexFold syn region texPartZone matchgroup=texSection start='\\part\>' end='\ze\s*\\\%(part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texPartGroup + TexFold syn region texChapterZone matchgroup=texSection start='\\chapter\>' end='\ze\s*\\\%(chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texChapterGroup + TexFold syn region texSectionZone matchgroup=texSection start='\\section\>' end='\ze\s*\\\%(section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texSectionGroup + TexFold syn region texSubSectionZone matchgroup=texSection start='\\subsection\>' end='\ze\s*\\\%(\%(sub\)\=section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texSubSectionGroup + TexFold syn region texSubSubSectionZone matchgroup=texSection start='\\subsubsection\>' end='\ze\s*\\\%(\%(sub\)\{,2}section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texSubSubSectionGroup + TexFold syn region texParaZone matchgroup=texSection start='\\paragraph\>' end='\ze\s*\\\%(paragraph\>\|\%(sub\)*section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup,@texParaGroup + TexFold syn region texSubParaZone matchgroup=texSection start='\\subparagraph\>' end='\ze\s*\\\%(\%(sub\)\=paragraph\>\|\%(sub\)*section\>\|chapter\>\|part\>\|end\s*{\s*document\s*}\)' contains=@texFoldGroup + TexFold syn region texTitle matchgroup=texSection start='\\\%(author\|title\)\>\s*{' end='}' contains=@texFoldGroup + TexFold syn region texAbstract matchgroup=texSection start='\\begin\s*{\s*abstract\s*}' end='\\end\s*{\s*abstract\s*}' contains=@texFoldGroup + endif +endif + +" particular support for bold and italic {{{1 +if s:tex_fast =~# 'b' + if s:tex_conceal =~# 'b' + if !exists("g:tex_nospell") || !g:tex_nospell + syn region texBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texBoldGroup,@Spell + syn region texBoldItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup,@Spell + syn region texItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup,@Spell + syn region texItalBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texBoldGroup,@Spell + else + syn region texBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texBoldGroup + syn region texBoldItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup + syn region texItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup + syn region texItalBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texBoldGroup + endif + endif +endif + +" Bad Math (mismatched): {{{1 +if !exists("g:tex_no_math") && !s:tex_no_error + syn match texBadMath "\\end\s*{\s*\(array\|gathered\|bBpvV]matrix\|split\|subequations\|smallmatrix\|xxalignat\)\s*}" + syn match texBadMath "\\end\s*{\s*\(align\|alignat\|displaymath\|displaymath\|eqnarray\|equation\|flalign\|gather\|math\|multline\|xalignat\)\*\=\s*}" + syn match texBadMath "\\[\])]" +endif + +" Math Zones: {{{1 +if !exists("g:tex_no_math") + " TexNewMathZone: function creates a mathzone with the given suffix and mathzone name. {{{2 + " Starred forms are created if starform is true. Starred + " forms have syntax group and synchronization groups with a + " "S" appended. Handles: cluster, syntax, sync, and highlighting. + fun! TexNewMathZone(sfx,mathzone,starform) + let grpname = "texMathZone".a:sfx + let syncname = "texSyncMathZone".a:sfx + if s:tex_fold_enabled + let foldcmd= " fold" + else + let foldcmd= "" + endif + exe "syn cluster texMathZones add=".grpname + if s:tex_fast =~# 'M' + exe 'syn region '.grpname.' start='."'".'\\begin\s*{\s*'.a:mathzone.'\s*}'."'".' end='."'".'\\end\s*{\s*'.a:mathzone.'\s*}'."'".' keepend contains=@texMathZoneGroup'.foldcmd + exe 'syn sync match '.syncname.' grouphere '.grpname.' "\\begin\s*{\s*'.a:mathzone.'\*\s*}"' + exe 'syn sync match '.syncname.' grouphere '.grpname.' "\\begin\s*{\s*'.a:mathzone.'\*\s*}"' + endif + exe 'hi def link '.grpname.' texMath' + if a:starform + let grpname = "texMathZone".a:sfx.'S' + let syncname = "texSyncMathZone".a:sfx.'S' + exe "syn cluster texMathZones add=".grpname + if s:tex_fast =~# 'M' + exe 'syn region '.grpname.' start='."'".'\\begin\s*{\s*'.a:mathzone.'\*\s*}'."'".' end='."'".'\\end\s*{\s*'.a:mathzone.'\*\s*}'."'".' keepend contains=@texMathZoneGroup'.foldcmd + exe 'syn sync match '.syncname.' grouphere '.grpname.' "\\begin\s*{\s*'.a:mathzone.'\*\s*}"' + exe 'syn sync match '.syncname.' grouphere '.grpname.' "\\begin\s*{\s*'.a:mathzone.'\*\s*}"' + endif + exe 'hi def link '.grpname.' texMath' + endif + endfun + + " Standard Math Zones: {{{2 + call TexNewMathZone("A","align",1) + call TexNewMathZone("B","alignat",1) + call TexNewMathZone("C","displaymath",1) + call TexNewMathZone("D","eqnarray",1) + call TexNewMathZone("E","equation",1) + call TexNewMathZone("F","flalign",1) + call TexNewMathZone("G","gather",1) + call TexNewMathZone("H","math",1) + call TexNewMathZone("I","multline",1) + call TexNewMathZone("J","xalignat",1) + call TexNewMathZone("K","xxalignat",0) + + " Inline Math Zones: {{{2 + if s:tex_fast =~# 'M' + if has("conceal") && &enc == 'utf-8' && s:tex_conceal =~# 'd' + syn region texMathZoneV matchgroup=Delimiter start="\\(" matchgroup=Delimiter end="\\)\|%stopzone\>" keepend concealends contains=@texMathZoneGroup + syn region texMathZoneW matchgroup=Delimiter start="\\\[" matchgroup=Delimiter end="\\]\|%stopzone\>" keepend concealends contains=@texMathZoneGroup + syn region texMathZoneX matchgroup=Delimiter start="\$" skip="\\\\\|\\\$" matchgroup=Delimiter end="\$" end="%stopzone\>" concealends contains=@texMathZoneGroup + syn region texMathZoneY matchgroup=Delimiter start="\$\$" matchgroup=Delimiter end="\$\$" end="%stopzone\>" keepend concealends contains=@texMathZoneGroup + else + syn region texMathZoneV matchgroup=Delimiter start="\\(" matchgroup=Delimiter end="\\)\|%stopzone\>" keepend contains=@texMathZoneGroup + syn region texMathZoneW matchgroup=Delimiter start="\\\[" matchgroup=Delimiter end="\\]\|%stopzone\>" keepend contains=@texMathZoneGroup + syn region texMathZoneX matchgroup=Delimiter start="\$" skip="\%(\\\\\)*\\\$" matchgroup=Delimiter end="\$" end="%stopzone\>" contains=@texMathZoneGroup + syn region texMathZoneY matchgroup=Delimiter start="\$\$" matchgroup=Delimiter end="\$\$" end="%stopzone\>" keepend contains=@texMathZoneGroup + endif + syn region texMathZoneZ matchgroup=texStatement start="\\ensuremath\s*{" matchgroup=texStatement end="}" end="%stopzone\>" contains=@texMathZoneGroup + endif + + syn match texMathOper "[_^=]" contained + + " Text Inside Math Zones: {{{2 + if s:tex_fast =~# 'M' + if !exists("g:tex_nospell") || !g:tex_nospell + syn region texMathText matchgroup=texStatement start='\\\(\(inter\)\=text\|mbox\)\s*{' end='}' contains=@texFoldGroup,@Spell + else + syn region texMathText matchgroup=texStatement start='\\\(\(inter\)\=text\|mbox\)\s*{' end='}' contains=@texFoldGroup + endif + endif + + " \left..something.. and \right..something.. support: {{{2 + syn match texMathDelimBad contained "\S" + if has("conceal") && &enc == 'utf-8' && s:tex_conceal =~# 'm' + syn match texMathDelim contained "\\left\[" + syn match texMathDelim contained "\\left\\{" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad contains=texMathSymbol cchar={ + syn match texMathDelim contained "\\right\\}" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad contains=texMathSymbol cchar=} + let s:texMathDelimList=[ + \ ['<' , '<'] , + \ ['>' , '>'] , + \ ['(' , '('] , + \ [')' , ')'] , + \ ['\[' , '['] , + \ [']' , ']'] , + \ ['\\{' , '{'] , + \ ['\\}' , '}'] , + \ ['|' , '|'] , + \ ['\\|' , '‖'] , + \ ['\\backslash' , '\'] , + \ ['\\downarrow' , '↓'] , + \ ['\\Downarrow' , '⇓'] , + \ ['\\lbrace' , '['] , + \ ['\\lceil' , '⌈'] , + \ ['\\lfloor' , '⌊'] , + \ ['\\lgroup' , '⌊'] , + \ ['\\lmoustache' , '⎛'] , + \ ['\\rbrace' , ']'] , + \ ['\\rceil' , '⌉'] , + \ ['\\rfloor' , '⌋'] , + \ ['\\rgroup' , '⌋'] , + \ ['\\rmoustache' , '⎞'] , + \ ['\\uparrow' , '↑'] , + \ ['\\Uparrow' , '↑'] , + \ ['\\updownarrow', '↕'] , + \ ['\\Updownarrow', '⇕']] + if &ambw == "double" || exists("g:tex_usedblwidth") + let s:texMathDelimList= s:texMathDelimList + [ + \ ['\\langle' , '〈'] , + \ ['\\rangle' , '〉']] + else + let s:texMathDelimList= s:texMathDelimList + [ + \ ['\\langle' , '<'] , + \ ['\\rangle' , '>']] + endif + syn match texMathDelim '\\[bB]igg\=[lr]' contained nextgroup=texMathDelimBad + for texmath in s:texMathDelimList + exe "syn match texMathDelim '\\\\[bB]igg\\=[lr]\\=".texmath[0]."' contained conceal cchar=".texmath[1] + endfor + + else + syn match texMathDelim contained "\\\(left\|right\)\>" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad + syn match texMathDelim contained "\\[bB]igg\=[lr]\=\>" skipwhite nextgroup=texMathDelimSet1,texMathDelimSet2,texMathDelimBad + syn match texMathDelimSet2 contained "\\" nextgroup=texMathDelimKey,texMathDelimBad + syn match texMathDelimSet1 contained "[<>()[\]|/.]\|\\[{}|]" + syn keyword texMathDelimKey contained backslash lceil lVert rgroup uparrow + syn keyword texMathDelimKey contained downarrow lfloor rangle rmoustache Uparrow + syn keyword texMathDelimKey contained Downarrow lgroup rbrace rvert updownarrow + syn keyword texMathDelimKey contained langle lmoustache rceil rVert Updownarrow + syn keyword texMathDelimKey contained lbrace lvert rfloor + endif + syn match texMathDelim contained "\\\(left\|right\)arrow\>\|\<\([aA]rrow\|brace\)\=vert\>" + syn match texMathDelim contained "\\lefteqn\>" +endif + +" Special TeX characters ( \$ \& \% \# \{ \} \_ \S \P ) : {{{1 +syn match texSpecialChar "\\[$&%#{}_]" +if b:tex_stylish + syn match texSpecialChar "\\[SP@][^a-zA-Z@]"me=e-1 +else + syn match texSpecialChar "\\[SP@]\A"me=e-1 +endif +syn match texSpecialChar "\\\\" +if !exists("g:tex_no_math") + syn match texOnlyMath "[_^]" +endif +syn match texSpecialChar "\^\^[0-9a-f]\{2}\|\^\^\S" +if s:tex_conceal !~# 'S' + syn match texSpecialChar '\\glq\>' contained conceal cchar=‚ + syn match texSpecialChar '\\grq\>' contained conceal cchar=‘ + syn match texSpecialChar '\\glqq\>' contained conceal cchar=„ + syn match texSpecialChar '\\grqq\>' contained conceal cchar=“ + syn match texSpecialChar '\\hyp\>' contained conceal cchar=- +endif + +" Comments: {{{1 +" Normal TeX LaTeX : %.... +" Documented TeX Format: ^^A... -and- leading %s (only) +if !s:tex_comment_nospell + syn cluster texCommentGroup contains=texTodo,@Spell +else + syn cluster texCommentGroup contains=texTodo,@NoSpell +endif +syn case ignore +syn keyword texTodo contained combak fixme todo xxx +syn case match +if s:extfname == "dtx" + syn match texComment "\^\^A.*$" contains=@texCommentGroup + syn match texComment "^%\+" contains=@texCommentGroup +else + if s:tex_fold_enabled + " allows syntax-folding of 2 or more contiguous comment lines + " single-line comments are not folded + syn match texComment "%.*$" contains=@texCommentGroup + if s:tex_fast =~# 'c' + TexFold syn region texComment start="^\zs\s*%.*\_s*%" skip="^\s*%" end='^\ze\s*[^%]' contains=@texCommentGroup + TexFold syn region texNoSpell contained matchgroup=texComment start="%\s*nospell\s*{" end="%\s*nospell\s*}" contains=@texFoldGroup,@NoSpell + endif + else + syn match texComment "%.*$" contains=@texCommentGroup + if s:tex_fast =~# 'c' + syn region texNoSpell contained matchgroup=texComment start="%\s*nospell\s*{" end="%\s*nospell\s*}" contains=@texFoldGroup,@NoSpell + endif + endif +endif + +" Separate lines used for verb` and verb# so that the end conditions {{{1 +" will appropriately terminate. +" If g:tex_verbspell exists, then verbatim texZones will permit spellchecking there. +if s:tex_fast =~# 'v' + if exists("g:tex_verbspell") && g:tex_verbspell + syn region texZone start="\\begin{[vV]erbatim}" end="\\end{[vV]erbatim}\|%stopzone\>" contains=@Spell + if b:tex_stylish + syn region texZone start="\\verb\*\=\z([^\ta-zA-Z@]\)" end="\z1\|%stopzone\>" contains=@Spell + else + syn region texZone start="\\verb\*\=\z([^\ta-zA-Z]\)" end="\z1\|%stopzone\>" contains=@Spell + endif + else + syn region texZone start="\\begin{[vV]erbatim}" end="\\end{[vV]erbatim}\|%stopzone\>" + if b:tex_stylish + syn region texZone start="\\verb\*\=\z([^\ta-zA-Z@]\)" end="\z1\|%stopzone\>" + else + syn region texZone start="\\verb\*\=\z([^\ta-zA-Z]\)" end="\z1\|%stopzone\>" + endif + endif +endif + +" Tex Reference Zones: {{{1 +if s:tex_fast =~# 'r' + syn region texZone matchgroup=texStatement start="@samp{" end="}\|%stopzone\>" contains=@texRefGroup + syn region texRefZone matchgroup=texStatement start="\\nocite{" end="}\|%stopzone\>" contains=@texRefGroup + syn region texRefZone matchgroup=texStatement start="\\bibliography{" end="}\|%stopzone\>" contains=@texRefGroup + syn region texRefZone matchgroup=texStatement start="\\label{" end="}\|%stopzone\>" contains=@texRefGroup + syn region texRefZone matchgroup=texStatement start="\\\(page\|eq\)ref{" end="}\|%stopzone\>" contains=@texRefGroup + syn region texRefZone matchgroup=texStatement start="\\v\=ref{" end="}\|%stopzone\>" contains=@texRefGroup + syn region texRefOption contained matchgroup=Delimiter start='\[' end=']' contains=@texRefGroup,texRefZone nextgroup=texRefOption,texCite + syn region texCite contained matchgroup=Delimiter start='{' end='}' contains=@texRefGroup,texRefZone,texCite +endif +syn match texRefZone '\\cite\%([tp]\*\=\)\=' nextgroup=texRefOption,texCite + +" Handle newcommand, newenvironment : {{{1 +syn match texNewCmd "\\newcommand\>" nextgroup=texCmdName skipwhite skipnl +if s:tex_fast =~# 'V' + syn region texCmdName contained matchgroup=Delimiter start="{"rs=s+1 end="}" nextgroup=texCmdArgs,texCmdBody skipwhite skipnl + syn region texCmdArgs contained matchgroup=Delimiter start="\["rs=s+1 end="]" nextgroup=texCmdBody skipwhite skipnl + syn region texCmdBody contained matchgroup=Delimiter start="{"rs=s+1 skip="\\\\\|\\[{}]" matchgroup=Delimiter end="}" contains=@texCmdGroup +endif +syn match texNewEnv "\\newenvironment\>" nextgroup=texEnvName skipwhite skipnl +if s:tex_fast =~# 'V' + syn region texEnvName contained matchgroup=Delimiter start="{"rs=s+1 end="}" nextgroup=texEnvBgn skipwhite skipnl + syn region texEnvBgn contained matchgroup=Delimiter start="{"rs=s+1 end="}" nextgroup=texEnvEnd skipwhite skipnl contains=@texEnvGroup + syn region texEnvEnd contained matchgroup=Delimiter start="{"rs=s+1 end="}" skipwhite skipnl contains=@texEnvGroup +endif + +" Definitions/Commands: {{{1 +syn match texDefCmd "\\def\>" nextgroup=texDefName skipwhite skipnl +if b:tex_stylish + syn match texDefName contained "\\[a-zA-Z@]\+" nextgroup=texDefParms,texCmdBody skipwhite skipnl + syn match texDefName contained "\\[^a-zA-Z@]" nextgroup=texDefParms,texCmdBody skipwhite skipnl +else + syn match texDefName contained "\\\a\+" nextgroup=texDefParms,texCmdBody skipwhite skipnl + syn match texDefName contained "\\\A" nextgroup=texDefParms,texCmdBody skipwhite skipnl +endif +syn match texDefParms contained "#[^{]*" contains=texDefParm nextgroup=texCmdBody skipwhite skipnl +syn match texDefParm contained "#\d\+" + +" TeX Lengths: {{{1 +syn match texLength "\<\d\+\([.,]\d\+\)\=\s*\(true\)\=\s*\(bp\|cc\|cm\|dd\|em\|ex\|in\|mm\|pc\|pt\|sp\)\>" + +" TeX String Delimiters: {{{1 +syn match texString "\(``\|''\|,,\)" + +" makeatletter -- makeatother sections +if !s:tex_no_error + if s:tex_fast =~# 'S' + syn region texStyle matchgroup=texStatement start='\\makeatletter' end='\\makeatother' contains=@texStyleGroup contained + endif + syn match texStyleStatement "\\[a-zA-Z@]\+" contained + if s:tex_fast =~# 'S' + syn region texStyleMatcher matchgroup=Delimiter start="{" skip="\\\\\|\\[{}]" end="}" contains=@texStyleGroup,texError contained + syn region texStyleMatcher matchgroup=Delimiter start="\[" end="]" contains=@texStyleGroup,texError contained + endif +endif + +" Conceal mode support (supports set cole=2) {{{1 +if has("conceal") && &enc == 'utf-8' + + " Math Symbols {{{2 + " (many of these symbols were contributed by Björn Winckler) + if s:tex_conceal =~# 'm' + let s:texMathList=[ + \ ['|' , '‖'], + \ ['aleph' , 'ℵ'], + \ ['amalg' , 'âˆ'], + \ ['angle' , '∠'], + \ ['approx' , '≈'], + \ ['ast' , '∗'], + \ ['asymp' , 'â‰'], + \ ['backepsilon' , 'âˆ'], + \ ['backsimeq' , '≃'], + \ ['backslash' , '∖'], + \ ['barwedge' , '⊼'], + \ ['because' , '∵'], + \ ['beth' , 'Ü’'], + \ ['between' , '≬'], + \ ['bigcap' , '∩'], + \ ['bigcirc' , 'â—‹'], + \ ['bigcup' , '∪'], + \ ['bigodot' , '⊙'], + \ ['bigoplus' , '⊕'], + \ ['bigotimes' , '⊗'], + \ ['bigsqcup' , '⊔'], + \ ['bigtriangledown', '∇'], + \ ['bigtriangleup' , '∆'], + \ ['bigvee' , 'â‹'], + \ ['bigwedge' , 'â‹€'], + \ ['blacksquare' , '∎'], + \ ['bot' , '⊥'], + \ ['bowtie' , '⋈'], + \ ['boxdot' , '⊡'], + \ ['boxminus' , '⊟'], + \ ['boxplus' , '⊞'], + \ ['boxtimes' , '⊠'], + \ ['Box' , 'â˜'], + \ ['bullet' , '•'], + \ ['bumpeq' , 'â‰'], + \ ['Bumpeq' , '≎'], + \ ['cap' , '∩'], + \ ['Cap' , 'â‹’'], + \ ['cdot' , '·'], + \ ['cdots' , '⋯'], + \ ['circ' , '∘'], + \ ['circeq' , '≗'], + \ ['circlearrowleft', '↺'], + \ ['circlearrowright', '↻'], + \ ['circledast' , '⊛'], + \ ['circledcirc' , '⊚'], + \ ['clubsuit' , '♣'], + \ ['complement' , 'âˆ'], + \ ['cong' , '≅'], + \ ['coprod' , 'âˆ'], + \ ['copyright' , '©'], + \ ['cup' , '∪'], + \ ['Cup' , 'â‹“'], + \ ['curlyeqprec' , 'â‹ž'], + \ ['curlyeqsucc' , 'â‹Ÿ'], + \ ['curlyvee' , 'â‹Ž'], + \ ['curlywedge' , 'â‹'], + \ ['dagger' , '†'], + \ ['dashv' , '⊣'], + \ ['ddagger' , '‡'], + \ ['ddots' , '⋱'], + \ ['diamond' , 'â‹„'], + \ ['diamondsuit' , '♢'], + \ ['div' , '÷'], + \ ['doteq' , 'â‰'], + \ ['doteqdot' , '≑'], + \ ['dotplus' , '∔'], + \ ['dots' , '…'], + \ ['dotsb' , '⋯'], + \ ['dotsc' , '…'], + \ ['dotsi' , '⋯'], + \ ['dotso' , '…'], + \ ['doublebarwedge' , 'â©ž'], + \ ['downarrow' , '↓'], + \ ['Downarrow' , '⇓'], + \ ['ell' , 'â„“'], + \ ['emptyset' , '∅'], + \ ['eqcirc' , '≖'], + \ ['eqsim' , '≂'], + \ ['eqslantgtr' , '⪖'], + \ ['eqslantless' , '⪕'], + \ ['equiv' , '≡'], + \ ['eth' , 'ð'], + \ ['exists' , '∃'], + \ ['fallingdotseq' , '≒'], + \ ['flat' , 'â™­'], + \ ['forall' , '∀'], + \ ['frown' , 'â”'], + \ ['ge' , '≥'], + \ ['geq' , '≥'], + \ ['geqq' , '≧'], + \ ['gets' , 'â†'], + \ ['gimel' , 'â„·'], + \ ['gg' , '⟫'], + \ ['gneqq' , '≩'], + \ ['gtrdot' , 'â‹—'], + \ ['gtreqless' , 'â‹›'], + \ ['gtrless' , '≷'], + \ ['gtrsim' , '≳'], + \ ['hbar' , 'â„'], + \ ['heartsuit' , '♡'], + \ ['hookleftarrow' , '↩'], + \ ['hookrightarrow' , '↪'], + \ ['iff' , '⇔'], + \ ['iiint' , '∭'], + \ ['iint' , '∬'], + \ ['Im' , 'â„‘'], + \ ['imath' , 'É©'], + \ ['implies' , '⇒'], + \ ['in' , '∈'], + \ ['infty' , '∞'], + \ ['int' , '∫'], + \ ['jmath' , 'ðš¥'], + \ ['land' , '∧'], + \ ['lceil' , '⌈'], + \ ['ldots' , '…'], + \ ['le' , '≤'], + \ ['leadsto' , 'â†'], + \ ['left(' , '('], + \ ['left\[' , '['], + \ ['left\\{' , '{'], + \ ['leftarrow' , 'â†'], + \ ['Leftarrow' , 'â‡'], + \ ['leftarrowtail' , '↢'], + \ ['leftharpoondown', '↽'], + \ ['leftharpoonup' , '↼'], + \ ['leftrightarrow' , '↔'], + \ ['Leftrightarrow' , '⇔'], + \ ['leftrightsquigarrow', '↭'], + \ ['leftthreetimes' , 'â‹‹'], + \ ['leq' , '≤'], + \ ['leq' , '≤'], + \ ['leqq' , '≦'], + \ ['lessdot' , 'â‹–'], + \ ['lesseqgtr' , 'â‹š'], + \ ['lesssim' , '≲'], + \ ['lfloor' , '⌊'], + \ ['ll' , '≪'], + \ ['lmoustache' , 'â•­'], + \ ['lneqq' , '≨'], + \ ['lor' , '∨'], + \ ['ltimes' , '⋉'], + \ ['mapsto' , '↦'], + \ ['measuredangle' , '∡'], + \ ['mid' , '∣'], + \ ['models' , 'â•ž'], + \ ['mp' , '∓'], + \ ['nabla' , '∇'], + \ ['natural' , 'â™®'], + \ ['ncong' , '≇'], + \ ['ne' , '≠'], + \ ['nearrow' , '↗'], + \ ['neg' , '¬'], + \ ['neq' , '≠'], + \ ['nexists' , '∄'], + \ ['ngeq' , '≱'], + \ ['ngeqq' , '≱'], + \ ['ngtr' , '≯'], + \ ['ni' , '∋'], + \ ['nleftarrow' , '↚'], + \ ['nLeftarrow' , 'â‡'], + \ ['nLeftrightarrow', '⇎'], + \ ['nleq' , '≰'], + \ ['nleqq' , '≰'], + \ ['nless' , '≮'], + \ ['nmid' , '∤'], + \ ['notin' , '∉'], + \ ['nparallel' , '∦'], + \ ['nprec' , '⊀'], + \ ['nrightarrow' , '↛'], + \ ['nRightarrow' , 'â‡'], + \ ['nsim' , 'â‰'], + \ ['nsucc' , 'âŠ'], + \ ['ntriangleleft' , '⋪'], + \ ['ntrianglelefteq', '⋬'], + \ ['ntriangleright' , 'â‹«'], + \ ['ntrianglerighteq', 'â‹­'], + \ ['nvdash' , '⊬'], + \ ['nvDash' , '⊭'], + \ ['nVdash' , '⊮'], + \ ['nwarrow' , '↖'], + \ ['odot' , '⊙'], + \ ['oint' , '∮'], + \ ['ominus' , '⊖'], + \ ['oplus' , '⊕'], + \ ['oslash' , '⊘'], + \ ['otimes' , '⊗'], + \ ['owns' , '∋'], + \ ['P' , '¶'], + \ ['parallel' , 'â•‘'], + \ ['partial' , '∂'], + \ ['perp' , '⊥'], + \ ['pitchfork' , 'â‹”'], + \ ['pm' , '±'], + \ ['prec' , '≺'], + \ ['precapprox' , '⪷'], + \ ['preccurlyeq' , '≼'], + \ ['preceq' , '⪯'], + \ ['precnapprox' , '⪹'], + \ ['precneqq' , '⪵'], + \ ['precsim' , '≾'], + \ ['prime' , '′'], + \ ['prod' , 'âˆ'], + \ ['propto' , 'âˆ'], + \ ['rceil' , '⌉'], + \ ['Re' , 'â„œ'], + \ ['rfloor' , '⌋'], + \ ['right)' , ')'], + \ ['right]' , ']'], + \ ['right\\}' , '}'], + \ ['rightarrow' , '→'], + \ ['Rightarrow' , '⇒'], + \ ['rightarrowtail' , '↣'], + \ ['rightleftharpoons', '⇌'], + \ ['rightsquigarrow', 'â†'], + \ ['rightthreetimes', 'â‹Œ'], + \ ['risingdotseq' , '≓'], + \ ['rmoustache' , 'â•®'], + \ ['rtimes' , 'â‹Š'], + \ ['S' , '§'], + \ ['searrow' , '↘'], + \ ['setminus' , '∖'], + \ ['sharp' , '♯'], + \ ['sim' , '∼'], + \ ['simeq' , 'â‹'], + \ ['smile' , '‿'], + \ ['spadesuit' , 'â™ '], + \ ['sphericalangle' , '∢'], + \ ['sqcap' , '⊓'], + \ ['sqcup' , '⊔'], + \ ['sqsubset' , 'âŠ'], + \ ['sqsubseteq' , '⊑'], + \ ['sqsupset' , 'âŠ'], + \ ['sqsupseteq' , '⊒'], + \ ['star' , '✫'], + \ ['subset' , '⊂'], + \ ['Subset' , 'â‹'], + \ ['subseteq' , '⊆'], + \ ['subseteqq' , 'â«…'], + \ ['subsetneq' , '⊊'], + \ ['subsetneqq' , 'â«‹'], + \ ['succ' , '≻'], + \ ['succapprox' , '⪸'], + \ ['succcurlyeq' , '≽'], + \ ['succeq' , '⪰'], + \ ['succnapprox' , '⪺'], + \ ['succneqq' , '⪶'], + \ ['succsim' , '≿'], + \ ['sum' , '∑'], + \ ['supset' , '⊃'], + \ ['Supset' , 'â‹‘'], + \ ['supseteq' , '⊇'], + \ ['supseteqq' , '⫆'], + \ ['supsetneq' , '⊋'], + \ ['supsetneqq' , 'â«Œ'], + \ ['surd' , '√'], + \ ['swarrow' , '↙'], + \ ['therefore' , '∴'], + \ ['times' , '×'], + \ ['to' , '→'], + \ ['top' , '⊤'], + \ ['triangle' , '∆'], + \ ['triangleleft' , '⊲'], + \ ['trianglelefteq' , '⊴'], + \ ['triangleq' , '≜'], + \ ['triangleright' , '⊳'], + \ ['trianglerighteq', '⊵'], + \ ['twoheadleftarrow', '↞'], + \ ['twoheadrightarrow', '↠'], + \ ['ulcorner' , '⌜'], + \ ['uparrow' , '↑'], + \ ['Uparrow' , '⇑'], + \ ['updownarrow' , '↕'], + \ ['Updownarrow' , '⇕'], + \ ['urcorner' , 'âŒ'], + \ ['varnothing' , '∅'], + \ ['vartriangle' , '∆'], + \ ['vdash' , '⊢'], + \ ['vDash' , '⊨'], + \ ['Vdash' , '⊩'], + \ ['vdots' , 'â‹®'], + \ ['vee' , '∨'], + \ ['veebar' , '⊻'], + \ ['Vvdash' , '⊪'], + \ ['wedge' , '∧'], + \ ['wp' , '℘'], + \ ['wr' , '≀']] +" \ ['jmath' , 'X'] +" \ ['uminus' , 'X'] +" \ ['uplus' , 'X'] + if &ambw == "double" || exists("g:tex_usedblwidth") + let s:texMathList= s:texMathList + [ + \ ['right\\rangle' , '〉'], + \ ['left\\langle' , '〈']] + else + let s:texMathList= s:texMathList + [ + \ ['right\\rangle' , '>'], + \ ['left\\langle' , '<']] + endif + for texmath in s:texMathList + if texmath[0] =~# '\w$' + exe "syn match texMathSymbol '\\\\".texmath[0]."\\>' contained conceal cchar=".texmath[1] + else + exe "syn match texMathSymbol '\\\\".texmath[0]."' contained conceal cchar=".texmath[1] + endif + endfor + + if &ambw == "double" + syn match texMathSymbol '\\gg\>' contained conceal cchar=≫ + syn match texMathSymbol '\\ll\>' contained conceal cchar=≪ + else + syn match texMathSymbol '\\gg\>' contained conceal cchar=⟫ + syn match texMathSymbol '\\ll\>' contained conceal cchar=⟪ + endif + + syn match texMathSymbol '\\hat{a}' contained conceal cchar=â + syn match texMathSymbol '\\hat{A}' contained conceal cchar= + syn match texMathSymbol '\\hat{c}' contained conceal cchar=ĉ + syn match texMathSymbol '\\hat{C}' contained conceal cchar=Ĉ + syn match texMathSymbol '\\hat{e}' contained conceal cchar=ê + syn match texMathSymbol '\\hat{E}' contained conceal cchar=Ê + syn match texMathSymbol '\\hat{g}' contained conceal cchar=Ä + syn match texMathSymbol '\\hat{G}' contained conceal cchar=Äœ + syn match texMathSymbol '\\hat{i}' contained conceal cchar=î + syn match texMathSymbol '\\hat{I}' contained conceal cchar=ÃŽ + syn match texMathSymbol '\\hat{o}' contained conceal cchar=ô + syn match texMathSymbol '\\hat{O}' contained conceal cchar=Ô + syn match texMathSymbol '\\hat{s}' contained conceal cchar=Å + syn match texMathSymbol '\\hat{S}' contained conceal cchar=Åœ + syn match texMathSymbol '\\hat{u}' contained conceal cchar=û + syn match texMathSymbol '\\hat{U}' contained conceal cchar=Û + syn match texMathSymbol '\\hat{w}' contained conceal cchar=ŵ + syn match texMathSymbol '\\hat{W}' contained conceal cchar=Å´ + syn match texMathSymbol '\\hat{y}' contained conceal cchar=Å· + syn match texMathSymbol '\\hat{Y}' contained conceal cchar=Ŷ +" syn match texMathSymbol '\\bar{a}' contained conceal cchar=aÌ… + endif + + " Greek {{{2 + if s:tex_conceal =~# 'g' + fun! s:Greek(group,pat,cchar) + exe 'syn match '.a:group." '".a:pat."' contained conceal cchar=".a:cchar + endfun + call s:Greek('texGreek','\\alpha\>' ,'α') + call s:Greek('texGreek','\\beta\>' ,'β') + call s:Greek('texGreek','\\gamma\>' ,'γ') + call s:Greek('texGreek','\\delta\>' ,'δ') + call s:Greek('texGreek','\\epsilon\>' ,'ϵ') + call s:Greek('texGreek','\\varepsilon\>' ,'ε') + call s:Greek('texGreek','\\zeta\>' ,'ζ') + call s:Greek('texGreek','\\eta\>' ,'η') + call s:Greek('texGreek','\\theta\>' ,'θ') + call s:Greek('texGreek','\\vartheta\>' ,'Ï‘') + call s:Greek('texGreek','\\kappa\>' ,'κ') + call s:Greek('texGreek','\\lambda\>' ,'λ') + call s:Greek('texGreek','\\mu\>' ,'μ') + call s:Greek('texGreek','\\nu\>' ,'ν') + call s:Greek('texGreek','\\xi\>' ,'ξ') + call s:Greek('texGreek','\\pi\>' ,'Ï€') + call s:Greek('texGreek','\\varpi\>' ,'Ï–') + call s:Greek('texGreek','\\rho\>' ,'Ï') + call s:Greek('texGreek','\\varrho\>' ,'ϱ') + call s:Greek('texGreek','\\sigma\>' ,'σ') + call s:Greek('texGreek','\\varsigma\>' ,'Ï‚') + call s:Greek('texGreek','\\tau\>' ,'Ï„') + call s:Greek('texGreek','\\upsilon\>' ,'Ï…') + call s:Greek('texGreek','\\phi\>' ,'Ï•') + call s:Greek('texGreek','\\varphi\>' ,'φ') + call s:Greek('texGreek','\\chi\>' ,'χ') + call s:Greek('texGreek','\\psi\>' ,'ψ') + call s:Greek('texGreek','\\omega\>' ,'ω') + call s:Greek('texGreek','\\Gamma\>' ,'Γ') + call s:Greek('texGreek','\\Delta\>' ,'Δ') + call s:Greek('texGreek','\\Theta\>' ,'Θ') + call s:Greek('texGreek','\\Lambda\>' ,'Λ') + call s:Greek('texGreek','\\Xi\>' ,'Χ') + call s:Greek('texGreek','\\Pi\>' ,'Π') + call s:Greek('texGreek','\\Sigma\>' ,'Σ') + call s:Greek('texGreek','\\Upsilon\>' ,'Î¥') + call s:Greek('texGreek','\\Phi\>' ,'Φ') + call s:Greek('texGreek','\\Psi\>' ,'Ψ') + call s:Greek('texGreek','\\Omega\>' ,'Ω') + delfun s:Greek + endif + + " Superscripts/Subscripts {{{2 + if s:tex_conceal =~# 's' + if s:tex_fast =~# 's' + syn region texSuperscript matchgroup=Delimiter start='\^{' skip="\\\\\|\\[{}]" end='}' contained concealends contains=texSpecialChar,texSuperscripts,texStatement,texSubscript,texSuperscript,texMathMatcher + syn region texSubscript matchgroup=Delimiter start='_{' skip="\\\\\|\\[{}]" end='}' contained concealends contains=texSpecialChar,texSubscripts,texStatement,texSubscript,texSuperscript,texMathMatcher + endif + " s:SuperSub: + fun! s:SuperSub(group,leader,pat,cchar) + if a:pat =~# '^\\' || (a:leader == '\^' && a:pat =~# s:tex_superscripts) || (a:leader == '_' && a:pat =~# s:tex_subscripts) +" call Decho("SuperSub: group<".a:group."> leader<".a:leader."> pat<".a:pat."> cchar<".a:cchar.">") + exe 'syn match '.a:group." '".a:leader.a:pat."' contained conceal cchar=".a:cchar + exe 'syn match '.a:group."s '".a:pat ."' contained conceal cchar=".a:cchar.' nextgroup='.a:group.'s' + endif + endfun + call s:SuperSub('texSuperscript','\^','0','â°') + call s:SuperSub('texSuperscript','\^','1','¹') + call s:SuperSub('texSuperscript','\^','2','²') + call s:SuperSub('texSuperscript','\^','3','³') + call s:SuperSub('texSuperscript','\^','4','â´') + call s:SuperSub('texSuperscript','\^','5','âµ') + call s:SuperSub('texSuperscript','\^','6','â¶') + call s:SuperSub('texSuperscript','\^','7','â·') + call s:SuperSub('texSuperscript','\^','8','â¸') + call s:SuperSub('texSuperscript','\^','9','â¹') + call s:SuperSub('texSuperscript','\^','a','ᵃ') + call s:SuperSub('texSuperscript','\^','b','ᵇ') + call s:SuperSub('texSuperscript','\^','c','ᶜ') + call s:SuperSub('texSuperscript','\^','d','ᵈ') + call s:SuperSub('texSuperscript','\^','e','ᵉ') + call s:SuperSub('texSuperscript','\^','f','ᶠ') + call s:SuperSub('texSuperscript','\^','g','áµ') + call s:SuperSub('texSuperscript','\^','h','Ê°') + call s:SuperSub('texSuperscript','\^','i','â±') + call s:SuperSub('texSuperscript','\^','j','ʲ') + call s:SuperSub('texSuperscript','\^','k','áµ') + call s:SuperSub('texSuperscript','\^','l','Ë¡') + call s:SuperSub('texSuperscript','\^','m','áµ') + call s:SuperSub('texSuperscript','\^','n','â¿') + call s:SuperSub('texSuperscript','\^','o','áµ’') + call s:SuperSub('texSuperscript','\^','p','áµ–') + call s:SuperSub('texSuperscript','\^','r','ʳ') + call s:SuperSub('texSuperscript','\^','s','Ë¢') + call s:SuperSub('texSuperscript','\^','t','áµ—') + call s:SuperSub('texSuperscript','\^','u','ᵘ') + call s:SuperSub('texSuperscript','\^','v','áµ›') + call s:SuperSub('texSuperscript','\^','w','Ê·') + call s:SuperSub('texSuperscript','\^','x','Ë£') + call s:SuperSub('texSuperscript','\^','y','ʸ') + call s:SuperSub('texSuperscript','\^','z','ᶻ') + call s:SuperSub('texSuperscript','\^','A','á´¬') + call s:SuperSub('texSuperscript','\^','B','á´®') + call s:SuperSub('texSuperscript','\^','D','á´°') + call s:SuperSub('texSuperscript','\^','E','á´±') + call s:SuperSub('texSuperscript','\^','G','á´³') + call s:SuperSub('texSuperscript','\^','H','á´´') + call s:SuperSub('texSuperscript','\^','I','á´µ') + call s:SuperSub('texSuperscript','\^','J','á´¶') + call s:SuperSub('texSuperscript','\^','K','á´·') + call s:SuperSub('texSuperscript','\^','L','á´¸') + call s:SuperSub('texSuperscript','\^','M','á´¹') + call s:SuperSub('texSuperscript','\^','N','á´º') + call s:SuperSub('texSuperscript','\^','O','á´¼') + call s:SuperSub('texSuperscript','\^','P','á´¾') + call s:SuperSub('texSuperscript','\^','R','á´¿') + call s:SuperSub('texSuperscript','\^','T','áµ€') + call s:SuperSub('texSuperscript','\^','U','áµ') + call s:SuperSub('texSuperscript','\^','W','ᵂ') + call s:SuperSub('texSuperscript','\^',',','ï¸') + call s:SuperSub('texSuperscript','\^',':','︓') + call s:SuperSub('texSuperscript','\^',';','︔') + call s:SuperSub('texSuperscript','\^','+','âº') + call s:SuperSub('texSuperscript','\^','-','â»') + call s:SuperSub('texSuperscript','\^','<','Ë‚') + call s:SuperSub('texSuperscript','\^','>','˃') + call s:SuperSub('texSuperscript','\^','/','ËŠ') + call s:SuperSub('texSuperscript','\^','(','â½') + call s:SuperSub('texSuperscript','\^',')','â¾') + call s:SuperSub('texSuperscript','\^','\.','Ë™') + call s:SuperSub('texSuperscript','\^','=','Ë­') + call s:SuperSub('texSubscript','_','0','â‚€') + call s:SuperSub('texSubscript','_','1','â‚') + call s:SuperSub('texSubscript','_','2','â‚‚') + call s:SuperSub('texSubscript','_','3','₃') + call s:SuperSub('texSubscript','_','4','â‚„') + call s:SuperSub('texSubscript','_','5','â‚…') + call s:SuperSub('texSubscript','_','6','₆') + call s:SuperSub('texSubscript','_','7','₇') + call s:SuperSub('texSubscript','_','8','₈') + call s:SuperSub('texSubscript','_','9','₉') + call s:SuperSub('texSubscript','_','a','â‚') + call s:SuperSub('texSubscript','_','e','â‚‘') + call s:SuperSub('texSubscript','_','h','â‚•') + call s:SuperSub('texSubscript','_','i','áµ¢') + call s:SuperSub('texSubscript','_','j','â±¼') + call s:SuperSub('texSubscript','_','k','â‚–') + call s:SuperSub('texSubscript','_','l','â‚—') + call s:SuperSub('texSubscript','_','m','ₘ') + call s:SuperSub('texSubscript','_','n','â‚™') + call s:SuperSub('texSubscript','_','o','â‚’') + call s:SuperSub('texSubscript','_','p','â‚š') + call s:SuperSub('texSubscript','_','r','áµ£') + call s:SuperSub('texSubscript','_','s','â‚›') + call s:SuperSub('texSubscript','_','t','â‚œ') + call s:SuperSub('texSubscript','_','u','ᵤ') + call s:SuperSub('texSubscript','_','v','áµ¥') + call s:SuperSub('texSubscript','_','x','â‚“') + call s:SuperSub('texSubscript','_',',','ï¸') + call s:SuperSub('texSubscript','_','+','â‚Š') + call s:SuperSub('texSubscript','_','-','â‚‹') + call s:SuperSub('texSubscript','_','/','Ë') + call s:SuperSub('texSubscript','_','(','â‚') + call s:SuperSub('texSubscript','_',')','â‚Ž') + call s:SuperSub('texSubscript','_','\.','‸') + call s:SuperSub('texSubscript','_','r','áµ£') + call s:SuperSub('texSubscript','_','v','áµ¥') + call s:SuperSub('texSubscript','_','x','â‚“') + call s:SuperSub('texSubscript','_','\\beta\>' ,'ᵦ') + call s:SuperSub('texSubscript','_','\\delta\>','ᵨ') + call s:SuperSub('texSubscript','_','\\phi\>' ,'ᵩ') + call s:SuperSub('texSubscript','_','\\gamma\>','ᵧ') + call s:SuperSub('texSubscript','_','\\chi\>' ,'ᵪ') + + delfun s:SuperSub + endif + + " Accented characters: {{{2 + if s:tex_conceal =~# 'a' + if b:tex_stylish + syn match texAccent "\\[bcdvuH][^a-zA-Z@]"me=e-1 + syn match texLigature "\\\([ijolL]\|ae\|oe\|ss\|AA\|AE\|OE\)[^a-zA-Z@]"me=e-1 + else + fun! s:Accents(chr,...) + let i= 1 + for accent in ["`","\\'","^",'"','\~','\.','=',"c","H","k","r","u","v"] + if i > a:0 + break + endif + if strlen(a:{i}) == 0 || a:{i} == ' ' || a:{i} == '?' + let i= i + 1 + continue + endif + if accent =~# '\a' + exe "syn match texAccent '".'\\'.accent.'\(\s*{'.a:chr.'}\|\s\+'.a:chr.'\)'."' conceal cchar=".a:{i} + else + exe "syn match texAccent '".'\\'.accent.'\s*\({'.a:chr.'}\|'.a:chr.'\)'."' conceal cchar=".a:{i} + endif + let i= i + 1 + endfor + endfun + " \` \' \^ \" \~ \. \= \c \H \k \r \u \v + call s:Accents('a','à','á','â','ä','ã','ȧ','Ä',' ',' ','Ä…','Ã¥','ă','ÇŽ') + call s:Accents('A','À','Ã','Â','Ä','Ã','Ȧ','Ä€',' ',' ','Ä„','Ã…','Ä‚','Ç') + call s:Accents('c',' ','ć','ĉ',' ',' ','Ä‹',' ','ç',' ',' ',' ',' ','Ä') + call s:Accents('C',' ','Ć','Ĉ',' ',' ','ÄŠ',' ','Ç',' ',' ',' ',' ','ÄŒ') + call s:Accents('d',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ','Ä') + call s:Accents('D',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ','ÄŽ') + call s:Accents('e','è','é','ê','ë','ẽ','Ä—','Ä“','È©',' ','Ä™',' ','Ä•','Ä›') + call s:Accents('E','È','É','Ê','Ë','Ẽ','Ä–','Ä’','Ȩ',' ','Ę',' ','Ä”','Äš') + call s:Accents('g',' ','ǵ','Ä',' ',' ','Ä¡',' ','Ä£',' ',' ',' ','ÄŸ','ǧ') + call s:Accents('G',' ','Ç´','Äœ',' ',' ','Ä ',' ','Ä¢',' ',' ',' ','Äž','Ǧ') + call s:Accents('h',' ',' ','Ä¥',' ',' ',' ',' ',' ',' ',' ',' ',' ','ÈŸ') + call s:Accents('H',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ','Èž') + call s:Accents('i','ì','í','î','ï','Ä©','į','Ä«',' ',' ','į',' ','Ä­','Ç') + call s:Accents('I','ÃŒ','Ã','ÃŽ','Ã','Ĩ','Ä°','Ī',' ',' ','Ä®',' ','Ĭ','Ç') + call s:Accents('J',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ','Ç°') + call s:Accents('k',' ',' ',' ',' ',' ',' ',' ','Ä·',' ',' ',' ',' ','Ç©') + call s:Accents('K',' ',' ',' ',' ',' ',' ',' ','Ķ',' ',' ',' ',' ','Ǩ') + call s:Accents('l',' ','ĺ','ľ',' ',' ',' ',' ','ļ',' ',' ',' ',' ','ľ') + call s:Accents('L',' ','Ĺ','Ľ',' ',' ',' ',' ','Ä»',' ',' ',' ',' ','Ľ') + call s:Accents('n',' ','Å„',' ',' ','ñ',' ',' ','ņ',' ',' ',' ',' ','ň') + call s:Accents('N',' ','Ń',' ',' ','Ñ',' ',' ','Å…',' ',' ',' ',' ','Ň') + call s:Accents('o','ò','ó','ô','ö','õ','ȯ','Å',' ','Å‘','Ç«',' ','Å','Ç’') + call s:Accents('O','Ã’','Ó','Ô','Ö','Õ','È®','ÅŒ',' ','Å','Ǫ',' ','ÅŽ','Ç‘') + call s:Accents('r',' ','Å•',' ',' ',' ',' ',' ','Å—',' ',' ',' ',' ','Å™') + call s:Accents('R',' ','Å”',' ',' ',' ',' ',' ','Å–',' ',' ',' ',' ','Ř') + call s:Accents('s',' ','Å›','Å',' ',' ',' ',' ','ÅŸ',' ','È¿',' ',' ','Å¡') + call s:Accents('S',' ','Åš','Åœ',' ',' ',' ',' ','Åž',' ',' ',' ',' ','Å ') + call s:Accents('t',' ',' ',' ',' ',' ',' ',' ','Å£',' ',' ',' ',' ','Å¥') + call s:Accents('T',' ',' ',' ',' ',' ',' ',' ','Å¢',' ',' ',' ',' ','Ť') + call s:Accents('u','ù','ú','û','ü','Å©',' ','Å«',' ','ű','ų','ů','Å­','Ç”') + call s:Accents('U','Ù','Ú','Û','Ãœ','Ũ',' ','Ū',' ','Å°','Ų','Å®','Ŭ','Ç“') + call s:Accents('w',' ',' ','ŵ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ') + call s:Accents('W',' ',' ','Å´',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ') + call s:Accents('y','ỳ','ý','Å·','ÿ','ỹ',' ',' ',' ',' ',' ',' ',' ',' ') + call s:Accents('Y','Ỳ','Ã','Ŷ','Ÿ','Ỹ',' ',' ',' ',' ',' ',' ',' ',' ') + call s:Accents('z',' ','ź',' ',' ',' ','ż',' ',' ',' ',' ',' ',' ','ž') + call s:Accents('Z',' ','Ź',' ',' ',' ','Å»',' ',' ',' ',' ',' ',' ','Ž') + call s:Accents('\\i','ì','í','î','ï','Ä©','į',' ',' ',' ',' ',' ','Ä­',' ') + " \` \' \^ \" \~ \. \= \c \H \k \r \u \v + delfun s:Accents + syn match texAccent '\\aa\>' conceal cchar=Ã¥ + syn match texAccent '\\AA\>' conceal cchar=Ã… + syn match texAccent '\\o\>' conceal cchar=ø + syn match texAccent '\\O\>' conceal cchar=Ø + syn match texLigature '\\AE\>' conceal cchar=Æ + syn match texLigature '\\ae\>' conceal cchar=æ + syn match texLigature '\\oe\>' conceal cchar=Å“ + syn match texLigature '\\OE\>' conceal cchar=Å’ + syn match texLigature '\\ss\>' conceal cchar=ß + endif + endif +endif + +" --------------------------------------------------------------------- +" LaTeX synchronization: {{{1 +syn sync maxlines=200 +syn sync minlines=50 + +syn sync match texSyncStop groupthere NONE "%stopzone\>" + +" Synchronization: {{{1 +" The $..$ and $$..$$ make for impossible sync patterns +" (one can't tell if a "$$" starts or stops a math zone by itself) +" The following grouptheres coupled with minlines above +" help improve the odds of good syncing. +if !exists("g:tex_no_math") + syn sync match texSyncMathZoneA groupthere NONE "\\end{abstract}" + syn sync match texSyncMathZoneA groupthere NONE "\\end{center}" + syn sync match texSyncMathZoneA groupthere NONE "\\end{description}" + syn sync match texSyncMathZoneA groupthere NONE "\\end{enumerate}" + syn sync match texSyncMathZoneA groupthere NONE "\\end{itemize}" + syn sync match texSyncMathZoneA groupthere NONE "\\end{table}" + syn sync match texSyncMathZoneA groupthere NONE "\\end{tabular}" + syn sync match texSyncMathZoneA groupthere NONE "\\\(sub\)*section\>" +endif + +" --------------------------------------------------------------------- +" Highlighting: {{{1 + +" Define the default highlighting. {{{1 +if !exists("skip_tex_syntax_inits") + + " TeX highlighting groups which should share similar highlighting + if !exists("g:tex_no_error") + if !exists("g:tex_no_math") + hi def link texBadMath texError + hi def link texMathDelimBad texError + hi def link texMathError texError + if !b:tex_stylish + hi def link texOnlyMath texError + endif + endif + hi def link texError Error + endif + + hi texBoldStyle gui=bold cterm=bold + hi texItalStyle gui=italic cterm=italic + hi texBoldItalStyle gui=bold,italic cterm=bold,italic + hi texItalBoldStyle gui=bold,italic cterm=bold,italic + hi def link texCite texRefZone + hi def link texDefCmd texDef + hi def link texDefName texDef + hi def link texDocType texCmdName + hi def link texDocTypeArgs texCmdArgs + hi def link texInputFileOpt texCmdArgs + hi def link texInputCurlies texDelimiter + hi def link texLigature texSpecialChar + if !exists("g:tex_no_math") + hi def link texMathDelimSet1 texMathDelim + hi def link texMathDelimSet2 texMathDelim + hi def link texMathDelimKey texMathDelim + hi def link texMathMatcher texMath + hi def link texAccent texStatement + hi def link texGreek texStatement + hi def link texSuperscript texStatement + hi def link texSubscript texStatement + hi def link texSuperscripts texSuperscript + hi def link texSubscripts texSubscript + hi def link texMathSymbol texStatement + hi def link texMathZoneV texMath + hi def link texMathZoneW texMath + hi def link texMathZoneX texMath + hi def link texMathZoneY texMath + hi def link texMathZoneV texMath + hi def link texMathZoneZ texMath + endif + hi def link texBeginEnd texCmdName + hi def link texBeginEndName texSection + hi def link texSpaceCode texStatement + hi def link texStyleStatement texStatement + hi def link texTypeSize texType + hi def link texTypeStyle texType + + " Basic TeX highlighting groups + hi def link texCmdArgs Number + hi def link texCmdName Statement + hi def link texComment Comment + hi def link texDef Statement + hi def link texDefParm Special + hi def link texDelimiter Delimiter + hi def link texInput Special + hi def link texInputFile Special + hi def link texLength Number + hi def link texMath Special + hi def link texMathDelim Statement + hi def link texMathOper Operator + hi def link texNewCmd Statement + hi def link texNewEnv Statement + hi def link texOption Number + hi def link texRefZone Special + hi def link texSection PreCondit + hi def link texSpaceCodeChar Special + hi def link texSpecialChar SpecialChar + hi def link texStatement Statement + hi def link texString String + hi def link texTodo Todo + hi def link texType Type + hi def link texZone PreCondit + +endif + +" Cleanup: {{{1 +delc TexFold +unlet s:extfname +let b:current_syntax = "tex" +let &cpo = s:keepcpo +unlet s:keepcpo +" vim: ts=8 fdm=marker + +endif diff --git a/syntax/texinfo.vim b/syntax/texinfo.vim new file mode 100644 index 0000000..f6d67ea --- /dev/null +++ b/syntax/texinfo.vim @@ -0,0 +1,400 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Texinfo (macro package for TeX) +" Maintainer: Sandor Kopanyi +" URL: <-> +" Last Change: 2004 Jun 23 +" +" the file follows the Texinfo manual structure; this file is based +" on manual for Texinfo version 4.0, 28 September 1999 +" since @ can have special meanings, everything is 'match'-ed and 'region'-ed +" (including @ in 'iskeyword' option has unexpected effects) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'texinfo' +endif + +"in Texinfo can be real big things, like tables; sync for that +syn sync lines=200 + +"some general stuff +"syn match texinfoError "\S" contained TODO +syn match texinfoIdent "\k\+" contained "IDENTifier +syn match texinfoAssignment "\k\+\s*=\s*\k\+\s*$" contained "assigment statement ( var = val ) +syn match texinfoSinglePar "\k\+\s*$" contained "single parameter (used for several @-commands) +syn match texinfoIndexPar "\k\k\s*$" contained "param. used for different *index commands (+ @documentlanguage command) + + +"marking words and phrases (chap. 9 in Texinfo manual) +"(almost) everything appears as 'contained' too; is for tables (@table) + +"this chapter is at the beginning of this file to avoid overwritings + +syn match texinfoSpecialChar "@acronym" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@acronym{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@b" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@b{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@cite" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@cite{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@code" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@code{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@command" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@command{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@dfn" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@dfn{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@email" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@email{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@emph" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@emph{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@env" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@env{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@file" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@file{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@i" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@i{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@kbd" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@kbd{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@key" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@key{" end="}" contains=texinfoSpecialChar +syn match texinfoSpecialChar "@option" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@option{" end="}" contains=texinfoSpecialChar +syn match texinfoSpecialChar "@r" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@r{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@samp" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@samp{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@sc" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@sc{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@strong" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@strong{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@t" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@t{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@url" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@url{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoSpecialChar "@var" contained +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@var{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn match texinfoAtCmd "^@kbdinputstyle" nextgroup=texinfoSinglePar skipwhite + + +"overview of Texinfo (chap. 1 in Texinfo manual) +syn match texinfoComment "@c .*" +syn match texinfoComment "@c$" +syn match texinfoComment "@comment .*" +syn region texinfoMltlnAtCmd matchgroup=texinfoComment start="^@ignore\s*$" end="^@end ignore\s*$" contains=ALL + + +"beginning a Texinfo file (chap. 3 in Texinfo manual) +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="@center " skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd oneline +syn region texinfoMltlnDMAtCmd matchgroup=texinfoAtCmd start="^@detailmenu\s*$" end="^@end detailmenu\s*$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@setfilename " skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@settitle " skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@shorttitlepage " skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@title " skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@titlefont{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@titlepage\s*$" end="^@end titlepage\s*$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoMltlnDMAtCmd,texinfoAtCmd,texinfoPrmAtCmd,texinfoMltlnAtCmd +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@vskip " skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn match texinfoAtCmd "^@exampleindent" nextgroup=texinfoSinglePar skipwhite +syn match texinfoAtCmd "^@headings" nextgroup=texinfoSinglePar skipwhite +syn match texinfoAtCmd "^\\input" nextgroup=texinfoSinglePar skipwhite +syn match texinfoAtCmd "^@paragraphindent" nextgroup=texinfoSinglePar skipwhite +syn match texinfoAtCmd "^@setchapternewpage" nextgroup=texinfoSinglePar skipwhite + + +"ending a Texinfo file (chap. 4 in Texinfo manual) +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="@author " skip="\\$" end="$" contains=texinfoSpecialChar oneline +"all below @bye should be comment TODO +syn match texinfoAtCmd "^@bye\s*$" +syn match texinfoAtCmd "^@contents\s*$" +syn match texinfoAtCmd "^@printindex" nextgroup=texinfoIndexPar skipwhite +syn match texinfoAtCmd "^@setcontentsaftertitlepage\s*$" +syn match texinfoAtCmd "^@setshortcontentsaftertitlepage\s*$" +syn match texinfoAtCmd "^@shortcontents\s*$" +syn match texinfoAtCmd "^@summarycontents\s*$" + + +"chapter structuring (chap. 5 in Texinfo manual) +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@appendix" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@appendixsec" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@appendixsection" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@appendixsubsec" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@appendixsubsubsec" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@centerchap" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@chapheading" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@chapter" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@heading" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@majorheading" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@section" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@subheading " skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@subsection" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@subsubheading" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@subsubsection" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@subtitle" skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@unnumbered" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@unnumberedsec" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@unnumberedsubsec" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@unnumberedsubsubsec" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn match texinfoAtCmd "^@lowersections\s*$" +syn match texinfoAtCmd "^@raisesections\s*$" + + +"nodes (chap. 6 in Texinfo manual) +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@anchor{" end="}" +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@top" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@node" skip="\\$" end="$" contains=texinfoSpecialChar oneline + + +"menus (chap. 7 in Texinfo manual) +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@menu\s*$" end="^@end menu\s*$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoMltlnDMAtCmd + + +"cross references (chap. 8 in Texinfo manual) +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@inforef{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@pxref{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@ref{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@uref{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@xref{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd + + +"marking words and phrases (chap. 9 in Texinfo manual) +"(almost) everything appears as 'contained' too; is for tables (@table) + +"this chapter is at the beginning of this file to avoid overwritings + + +"quotations and examples (chap. 10 in Texinfo manual) +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@cartouche\s*$" end="^@end cartouche\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@display\s*$" end="^@end display\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@example\s*$" end="^@end example\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@flushleft\s*$" end="^@end flushleft\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@flushright\s*$" end="^@end flushright\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@format\s*$" end="^@end format\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@lisp\s*$" end="^@end lisp\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@quotation\s*$" end="^@end quotation\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@smalldisplay\s*$" end="^@end smalldisplay\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@smallexample\s*$" end="^@end smallexample\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@smallformat\s*$" end="^@end smallformat\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@smalllisp\s*$" end="^@end smalllisp\s*$" contains=ALL +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@exdent" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn match texinfoAtCmd "^@noindent\s*$" +syn match texinfoAtCmd "^@smallbook\s*$" + + +"lists and tables (chap. 11 in Texinfo manual) +syn match texinfoAtCmd "@asis" contained +syn match texinfoAtCmd "@columnfractions" contained +syn match texinfoAtCmd "@item" contained +syn match texinfoAtCmd "@itemx" contained +syn match texinfoAtCmd "@tab" contained +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@enumerate" end="^@end enumerate\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ftable" end="^@end ftable\s*$" contains=ALL +syn region texinfoMltlnNAtCmd matchgroup=texinfoAtCmd start="^@itemize" end="^@end itemize\s*$" contains=ALL +syn region texinfoMltlnNAtCmd matchgroup=texinfoAtCmd start="^@multitable" end="^@end multitable\s*$" contains=ALL +syn region texinfoMltlnNAtCmd matchgroup=texinfoAtCmd start="^@table" end="^@end table\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@vtable" end="^@end vtable\s*$" contains=ALL + + +"indices (chap. 12 in Texinfo manual) +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@\(c\|f\|k\|p\|t\|v\)index" skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@..index" skip="\\$" end="$" contains=texinfoSpecialChar oneline +"@defcodeindex and @defindex is defined after chap. 15's @def* commands (otherwise those ones will overwrite these ones) +syn match texinfoSIPar "\k\k\s*\k\k\s*$" contained +syn match texinfoAtCmd "^@syncodeindex" nextgroup=texinfoSIPar skipwhite +syn match texinfoAtCmd "^@synindex" nextgroup=texinfoSIPar skipwhite + +"special insertions (chap. 13 in Texinfo manual) +syn match texinfoSpecialChar "@\(!\|?\|@\|\s\)" +syn match texinfoSpecialChar "@{" +syn match texinfoSpecialChar "@}" +"accents +syn match texinfoSpecialChar "@=." +syn match texinfoSpecialChar "@\('\|\"\|\^\|`\)[aeiouyAEIOUY]" +syn match texinfoSpecialChar "@\~[aeinouyAEINOUY]" +syn match texinfoSpecialChar "@dotaccent{.}" +syn match texinfoSpecialChar "@H{.}" +syn match texinfoSpecialChar "@,{[cC]}" +syn match texinfoSpecialChar "@AA{}" +syn match texinfoSpecialChar "@aa{}" +syn match texinfoSpecialChar "@L{}" +syn match texinfoSpecialChar "@l{}" +syn match texinfoSpecialChar "@O{}" +syn match texinfoSpecialChar "@o{}" +syn match texinfoSpecialChar "@ringaccent{.}" +syn match texinfoSpecialChar "@tieaccent{..}" +syn match texinfoSpecialChar "@u{.}" +syn match texinfoSpecialChar "@ubaraccent{.}" +syn match texinfoSpecialChar "@udotaccent{.}" +syn match texinfoSpecialChar "@v{.}" +"ligatures +syn match texinfoSpecialChar "@AE{}" +syn match texinfoSpecialChar "@ae{}" +syn match texinfoSpecialChar "@copyright{}" +syn match texinfoSpecialChar "@bullet" contained "for tables and lists +syn match texinfoSpecialChar "@bullet{}" +syn match texinfoSpecialChar "@dotless{i}" +syn match texinfoSpecialChar "@dotless{j}" +syn match texinfoSpecialChar "@dots{}" +syn match texinfoSpecialChar "@enddots{}" +syn match texinfoSpecialChar "@equiv" contained "for tables and lists +syn match texinfoSpecialChar "@equiv{}" +syn match texinfoSpecialChar "@error{}" +syn match texinfoSpecialChar "@exclamdown{}" +syn match texinfoSpecialChar "@expansion{}" +syn match texinfoSpecialChar "@minus" contained "for tables and lists +syn match texinfoSpecialChar "@minus{}" +syn match texinfoSpecialChar "@OE{}" +syn match texinfoSpecialChar "@oe{}" +syn match texinfoSpecialChar "@point" contained "for tables and lists +syn match texinfoSpecialChar "@point{}" +syn match texinfoSpecialChar "@pounds{}" +syn match texinfoSpecialChar "@print{}" +syn match texinfoSpecialChar "@questiondown{}" +syn match texinfoSpecialChar "@result" contained "for tables and lists +syn match texinfoSpecialChar "@result{}" +syn match texinfoSpecialChar "@ss{}" +syn match texinfoSpecialChar "@TeX{}" +"other +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@dmn{" end="}" +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@footnote{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@image{" end="}" +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@math{" end="}" +syn match texinfoAtCmd "@footnotestyle" nextgroup=texinfoSinglePar skipwhite + + +"making and preventing breaks (chap. 14 in Texinfo manual) +syn match texinfoSpecialChar "@\(\*\|-\|\.\)" +syn match texinfoAtCmd "^@need" nextgroup=texinfoSinglePar skipwhite +syn match texinfoAtCmd "^@page\s*$" +syn match texinfoAtCmd "^@sp" nextgroup=texinfoSinglePar skipwhite +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@group\s*$" end="^@end group\s*$" contains=ALL +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@hyphenation{" end="}" +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@w{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd + + +"definition commands (chap. 15 in Texinfo manual) +syn match texinfoMltlnAtCmdFLine "^@def\k\+" contained +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@def\k\+" end="^@end def\k\+$" contains=ALL + +"next 2 commands are from chap. 12; must be defined after @def* commands above to overwrite them +syn match texinfoAtCmd "@defcodeindex" nextgroup=texinfoIndexPar skipwhite +syn match texinfoAtCmd "@defindex" nextgroup=texinfoIndexPar skipwhite + + +"conditionally visible text (chap. 16 in Texinfo manual) +syn match texinfoAtCmd "^@clear" nextgroup=texinfoSinglePar skipwhite +syn region texinfoMltln2AtCmd matchgroup=texinfoAtCmd start="^@html\s*$" end="^@end html\s*$" +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ifclear" end="^@end ifclear\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ifhtml" end="^@end ifhtml\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ifinfo" end="^@end ifinfo\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ifnothtml" end="^@end ifnothtml\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ifnotinfo" end="^@end ifnotinfo\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ifnottex" end="^@end ifnottex\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@ifset" end="^@end ifset\s*$" contains=ALL +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@iftex" end="^@end iftex\s*$" contains=ALL +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@set " skip="\\$" end="$" contains=texinfoSpecialChar oneline +syn region texinfoTexCmd start="\$\$" end="\$\$" contained +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@tex" end="^@end tex\s*$" contains=texinfoTexCmd +syn region texinfoBrcPrmAtCmd matchgroup=texinfoAtCmd start="@value{" end="}" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd + + +"internationalization (chap. 17 in Texinfo manual) +syn match texinfoAtCmd "@documentencoding" nextgroup=texinfoSinglePar skipwhite +syn match texinfoAtCmd "@documentlanguage" nextgroup=texinfoIndexPar skipwhite + + +"defining new texinfo commands (chap. 18 in Texinfo manual) +syn match texinfoAtCmd "@alias" nextgroup=texinfoAssignment skipwhite +syn match texinfoDIEPar "\S*\s*,\s*\S*\s*,\s*\S*\s*$" contained +syn match texinfoAtCmd "@definfoenclose" nextgroup=texinfoDIEPar skipwhite +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@macro" end="^@end macro\s*$" contains=ALL + + +"formatting hardcopy (chap. 19 in Texinfo manual) +syn match texinfoAtCmd "^@afourlatex\s*$" +syn match texinfoAtCmd "^@afourpaper\s*$" +syn match texinfoAtCmd "^@afourwide\s*$" +syn match texinfoAtCmd "^@finalout\s*$" +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@pagesizes" end="$" oneline + + +"creating and installing Info Files (chap. 20 in Texinfo manual) +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@dircategory" skip="\\$" end="$" oneline +syn region texinfoMltlnAtCmd matchgroup=texinfoAtCmd start="^@direntry\s*$" end="^@end direntry\s*$" contains=texinfoSpecialChar +syn match texinfoAtCmd "^@novalidate\s*$" + + +"include files (appendix E in Texinfo manual) +syn match texinfoAtCmd "^@include" nextgroup=texinfoSinglePar skipwhite + + +"page headings (appendix F in Texinfo manual) +syn match texinfoHFSpecialChar "@|" contained +syn match texinfoThisAtCmd "@thischapter" contained +syn match texinfoThisAtCmd "@thischaptername" contained +syn match texinfoThisAtCmd "@thisfile" contained +syn match texinfoThisAtCmd "@thispage" contained +syn match texinfoThisAtCmd "@thistitle" contained +syn match texinfoThisAtCmd "@today{}" contained +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@evenfooting" skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoThisAtCmd,texinfoHFSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@evenheading" skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoThisAtCmd,texinfoHFSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@everyfooting" skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoThisAtCmd,texinfoHFSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@everyheading" skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoThisAtCmd,texinfoHFSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@oddfooting" skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoThisAtCmd,texinfoHFSpecialChar oneline +syn region texinfoPrmAtCmd matchgroup=texinfoAtCmd start="^@oddheading" skip="\\$" end="$" contains=texinfoSpecialChar,texinfoBrcPrmAtCmd,texinfoThisAtCmd,texinfoHFSpecialChar oneline + + +"refilling paragraphs (appendix H in Texinfo manual) +syn match texinfoAtCmd "@refill" + + +syn cluster texinfoAll contains=ALLBUT,texinfoThisAtCmd,texinfoHFSpecialChar +syn cluster texinfoReducedAll contains=texinfoSpecialChar,texinfoBrcPrmAtCmd +"============================================================================== +" highlighting + +" Only when an item doesn't have highlighting yet + +hi def link texinfoSpecialChar Special +hi def link texinfoHFSpecialChar Special + +hi def link texinfoError Error +hi def link texinfoIdent Identifier +hi def link texinfoAssignment Identifier +hi def link texinfoSinglePar Identifier +hi def link texinfoIndexPar Identifier +hi def link texinfoSIPar Identifier +hi def link texinfoDIEPar Identifier +hi def link texinfoTexCmd PreProc + + +hi def link texinfoAtCmd Statement "@-command +hi def link texinfoPrmAtCmd String "@-command in one line with unknown nr. of parameters + "is String because is found as a region and is 'matchgroup'-ed + "to texinfoAtCmd +hi def link texinfoBrcPrmAtCmd String "@-command with parameter(s) in braces ({}) + "is String because is found as a region and is 'matchgroup'-ed to texinfoAtCmd +hi def link texinfoMltlnAtCmdFLine texinfoAtCmd "repeated embedded First lines in @-commands +hi def link texinfoMltlnAtCmd String "@-command in multiple lines + "is String because is found as a region and is 'matchgroup'-ed to texinfoAtCmd +hi def link texinfoMltln2AtCmd PreProc "@-command in multiple lines (same as texinfoMltlnAtCmd, just with other colors) +hi def link texinfoMltlnDMAtCmd PreProc "@-command in multiple lines (same as texinfoMltlnAtCmd, just with other colors; used for @detailmenu, which can be included in @menu) +hi def link texinfoMltlnNAtCmd Normal "@-command in multiple lines (same as texinfoMltlnAtCmd, just with other colors) +hi def link texinfoThisAtCmd Statement "@-command used in headers and footers (@this... series) + +hi def link texinfoComment Comment + + + +let b:current_syntax = "texinfo" + +if main_syntax == 'texinfo' + unlet main_syntax +endif + +" vim: ts=8 + +endif diff --git a/syntax/texmf.vim b/syntax/texmf.vim new file mode 100644 index 0000000..78da139 --- /dev/null +++ b/syntax/texmf.vim @@ -0,0 +1,78 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" This is a GENERATED FILE. Please always refer to source file at the URI below. +" Language: Web2C TeX texmf.cnf configuration file +" Maintainer: David Ne\v{c}as (Yeti) +" Last Change: 2001-05-13 +" URL: http://physics.muni.cz/~yeti/download/syntax/texmf.vim + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +" Comments +syn match texmfComment "%..\+$" contains=texmfTodo +syn match texmfComment "%\s*$" contains=texmfTodo +syn keyword texmfTodo TODO FIXME XXX NOT contained + +" Constants and parameters +syn match texmfPassedParameter "[-+]\=%\w\W" +syn match texmfPassedParameter "[-+]\=%\w$" +syn match texmfNumber "\<\d\+\>" +syn match texmfVariable "\$\(\w\k*\|{\w\k*}\)" +syn match texmfSpecial +\\"\|\\$+ +syn region texmfString start=+"+ end=+"+ skip=+\\"\\\\+ contains=texmfVariable,texmfSpecial,texmfPassedParameter + +" Assignments +syn match texmfLHSStart "^\s*\w\k*" nextgroup=texmfLHSDot,texmfEquals +syn match texmfLHSVariable "\w\k*" contained nextgroup=texmfLHSDot,texmfEquals +syn match texmfLHSDot "\." contained nextgroup=texmfLHSVariable +syn match texmfEquals "\s*=" contained + +" Specialities +syn match texmfComma "," contained +syn match texmfColons ":\|;" +syn match texmfDoubleExclam "!!" contained + +" Catch errors caused by wrong parenthesization +syn region texmfBrace matchgroup=texmfBraceBrace start="{" end="}" contains=ALLBUT,texmfTodo,texmfBraceError,texmfLHSVariable,texmfLHSDot transparent +syn match texmfBraceError "}" + +" Define the default highlighting + +hi def link texmfComment Comment +hi def link texmfTodo Todo + +hi def link texmfPassedParameter texmfVariable +hi def link texmfVariable Identifier + +hi def link texmfNumber Number +hi def link texmfString String + +hi def link texmfLHSStart texmfLHS +hi def link texmfLHSVariable texmfLHS +hi def link texmfLHSDot texmfLHS +hi def link texmfLHS Type + +hi def link texmfEquals Normal + +hi def link texmfBraceBrace texmfDelimiter +hi def link texmfComma texmfDelimiter +hi def link texmfColons texmfDelimiter +hi def link texmfDelimiter Preproc + +hi def link texmfDoubleExclam Statement +hi def link texmfSpecial Special + +hi def link texmfBraceError texmfError +hi def link texmfError Error + + +let b:current_syntax = "texmf" + +endif diff --git a/syntax/tf.vim b/syntax/tf.vim new file mode 100644 index 0000000..83fbb76 --- /dev/null +++ b/syntax/tf.vim @@ -0,0 +1,200 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: tf +" Maintainer: Lutz Eymers +" URL: http://www.isp.de/data/tf.vim +" Email: send syntax_vim.tgz +" Last Change: 2001 May 10 +" +" Options lite_minlines = x to sync at least x lines backwards + +" Remove any old syntax stuff hanging around + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match + +if !exists("main_syntax") + let main_syntax = 'tf' +endif + +" Special global variables +syn keyword tfVar HOME LANG MAIL SHELL TERM TFHELP TFLIBDIR TFLIBRARY TZ contained +syn keyword tfVar background backslash contained +syn keyword tfVar bamf bg_output borg clearfull cleardone clock connect contained +syn keyword tfVar emulation end_color gag gethostbyname gpri hook hilite contained +syn keyword tfVar hiliteattr histsize hpri insert isize istrip kecho contained +syn keyword tfVar kprefix login lp lpquote maildelay matching max_iter contained +syn keyword tfVar max_recur mecho more mprefix oldslash promt_sec contained +syn keyword tfVar prompt_usec proxy_host proxy_port ptime qecho qprefix contained +syn keyword tfVar quite quitdone redef refreshtime scroll shpause snarf sockmload contained +syn keyword tfVar start_color tabsize telopt sub time_format visual contained +syn keyword tfVar watch_dog watchname wordpunct wrap wraplog wrapsize contained +syn keyword tfVar wrapspace contained + +" Worldvar +syn keyword tfWorld world_name world_character world_password world_host contained +syn keyword tfWorld world_port world_mfile world_type contained + +" Number +syn match tfNumber "-\=\<\d\+\>" + +" Float +syn match tfFloat "\(-\=\<\d+\|-\=\)\.\d\+\>" + +" Operator +syn match tfOperator "[-+=?:&|!]" +syn match tfOperator "/[^*~@]"he=e-1 +syn match tfOperator ":=" +syn match tfOperator "[^/%]\*"hs=s+1 +syn match tfOperator "$\+[([{]"he=e-1,me=e-1 +syn match tfOperator "\^\[\+"he=s+1 contains=tfSpecialCharEsc + +" Relational +syn match tfRelation "&&" +syn match tfRelation "||" +syn match tfRelation "[<>/!=]=" +syn match tfRelation "[<>]" +syn match tfRelation "[!=]\~" +syn match tfRelation "[=!]/" + + +" Readonly Var +syn match tfReadonly "[#*]" contained +syn match tfReadonly "\<-\=L\=\d\{-}\>" contained +syn match tfReadonly "\" contained +syn match tfReadonly "\" contained + +" Identifier +syn match tfIdentifier "%\+[a-zA-Z_#*-0-9]\w*" contains=tfVar,tfReadonly +syn match tfIdentifier "%\+[{]"he=e-1,me=e-1 +syn match tfIdentifier "\$\+{[a-zA-Z_#*-0-9]\w*}" contains=tfWorld + +" Function names +syn keyword tfFunctions ascii char columns echo filename ftime fwrite getopts +syn keyword tfFunctions getpid idle kbdel kbgoto kbhead kblen kbmatch kbpoint +syn keyword tfFunctions kbtail kbwordleft kbwordright keycode lines mod +syn keyword tfFunctions moresize pad rand read regmatch send strcat strchr +syn keyword tfFunctions strcmp strlen strncmp strrchr strrep strstr substr +syn keyword tfFunctions systype time tolower toupper + +syn keyword tfStatement addworld bamf beep bind break cat changes connect contained +syn keyword tfStatement dc def dokey echo edit escape eval export expr fg for contained +syn keyword tfStatement gag getfile grab help hilite histsize hook if input contained +syn keyword tfStatement kill lcd let list listsockets listworlds load contained +syn keyword tfStatement localecho log nohilite not partial paste ps purge contained +syn keyword tfStatement purgeworld putfile quit quote recall recordline save contained +syn keyword tfStatement saveworld send sh shift sub substitute contained +syn keyword tfStatement suspend telnet test time toggle trig trigger unbind contained +syn keyword tfStatement undef undefn undeft unhook untrig unworld contained +syn keyword tfStatement version watchdog watchname while world contained + +" Hooks +syn keyword tfHook ACTIVITY BACKGROUND BAMF CONFAIL CONFLICT CONNECT DISCONNECT +syn keyword tfHook KILL LOAD LOADFAIL LOG LOGIN MAIL MORE PENDING PENDING +syn keyword tfHook PROCESS PROMPT PROXY REDEF RESIZE RESUME SEND SHADOW SHELL +syn keyword tfHook SIGHUP SIGTERM SIGUSR1 SIGUSR2 WORLD + +" Conditional +syn keyword tfConditional if endif then else elseif contained + +" Repeat +syn keyword tfRepeat while do done repeat for contained + +" Statement +syn keyword tfStatement break quit contained + +" Include +syn keyword tfInclude require load save loaded contained + +" Define +syn keyword tfDefine bind unbind def undef undefn undefn purge hook unhook trig untrig contained +syn keyword tfDefine set unset setenv contained + +" Todo +syn keyword tfTodo TODO Todo todo contained + +" SpecialChar +syn match tfSpecialChar "\\[abcfnrtyv\\]" contained +syn match tfSpecialChar "\\\d\{3}" contained contains=tfOctalError +syn match tfSpecialChar "\\x[0-9a-fA-F]\{2}" contained +syn match tfSpecialCharEsc "\[\+" contained + +syn match tfOctalError "[89]" contained + +" Comment +syn region tfComment start="^;" end="$" contains=tfTodo + +" String +syn region tfString oneline matchgroup=None start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=tfIdentifier,tfSpecialChar,tfEscape +syn region tfString matchgroup=None start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=tfIdentifier,tfSpecialChar,tfEscape + +syn match tfParentError "[)}\]]" + +" Parents +syn region tfParent matchgroup=Delimiter start="(" end=")" contains=ALLBUT,tfReadonly +syn region tfParent matchgroup=Delimiter start="\[" end="\]" contains=ALL +syn region tfParent matchgroup=Delimiter start="{" end="}" contains=ALL + +syn match tfEndCommand "%%\{-};" +syn match tfJoinLines "\\$" + +" Types + +syn match tfType "/[a-zA-Z_~@][a-zA-Z0-9_]*" contains=tfConditional,tfRepeat,tfStatement,tfInclude,tfDefine,tfStatement + +" Catch /quote .. ' +syn match tfQuotes "/quote .\{-}'" contains=ALLBUT,tfString +" Catch $(/escape ) +syn match tfEscape "(/escape .*)" + +" sync +if exists("tf_minlines") + exec "syn sync minlines=" . tf_minlines +else + syn sync minlines=100 +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link tfComment Comment +hi def link tfString String +hi def link tfNumber Number +hi def link tfFloat Float +hi def link tfIdentifier Identifier +hi def link tfVar Identifier +hi def link tfWorld Identifier +hi def link tfReadonly Identifier +hi def link tfHook Identifier +hi def link tfFunctions Function +hi def link tfRepeat Repeat +hi def link tfConditional Conditional +hi def link tfLabel Label +hi def link tfStatement Statement +hi def link tfType Type +hi def link tfInclude Include +hi def link tfDefine Define +hi def link tfSpecialChar SpecialChar +hi def link tfSpecialCharEsc SpecialChar +hi def link tfParentError Error +hi def link tfTodo Todo +hi def link tfEndCommand Delimiter +hi def link tfJoinLines Delimiter +hi def link tfOperator Operator +hi def link tfRelation Operator + + +let b:current_syntax = "tf" + +if main_syntax == 'tf' + unlet main_syntax +endif + +" vim: ts=8 + +endif diff --git a/syntax/tidy.vim b/syntax/tidy.vim new file mode 100644 index 0000000..94f15c6 --- /dev/null +++ b/syntax/tidy.vim @@ -0,0 +1,139 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: HMTL Tidy configuration file (/etc/tidyrc ~/.tidyrc) +" Maintainer: Doug Kearns +" Last Change: 2016 Apr 24 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn iskeyword @,48-57,-,_ + +syn case ignore +syn keyword tidyBoolean contained t[rue] f[alse] y[es] n[o] 1 0 +syn keyword tidyAutoBoolean contained t[rue] f[alse] y[es] n[o] 1 0 auto +syn case match +syn keyword tidyDoctype contained html5 omit auto strict loose transitional user +syn keyword tidyEncoding contained raw ascii latin0 latin1 utf8 iso2022 mac win1252 ibm858 utf16le utf16be utf16 big5 shiftjis +syn keyword tidyNewline contained LF CRLF CR +syn match tidyNumber contained "\<\d\+\>" +syn keyword tidyRepeat contained keep-first keep-last +syn keyword tidySorter contained alpha none +syn region tidyString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ oneline +syn region tidyString contained start=+'+ skip=+\\\\\|\\'+ end=+'+ oneline +syn match tidyTags contained "\<\w\+\(\s*,\s*\w\+\)*\>" + +syn keyword tidyBooleanOption add-xml-decl add-xml-pi add-xml-space + \ anchor-as-name ascii-chars assume-xml-procins bare break-before-br + \ clean coerce-endtags decorate-inferred-ul drop-empty-paras + \ drop-empty-elements drop-font-tags drop-proprietary-attributes + \ enclose-block-text enclose-text escape-cdata escape-scripts + \ fix-backslash fix-bad-comments fix-uri force-output gdoc gnu-emacs + \ hide-comments hide-endtags indent-attributes indent-cdata + \ indent-with-tabs input-xml join-classes join-styles keep-time + \ language literal-attributes logical-emphasis lower-literals markup + \ merge-emphasis ncr numeric-entities omit-optional-tags output-html + \ output-xhtml output-xml preserve-entities punctuation-wrap quiet + \ quote-ampersand quote-marks quote-nbsp raw replace-color show-info + \ show-warnings skip-nested split strict-tags-attributes tidy-mark + \ uppercase-attributes uppercase-tags word-2000 wrap-asp + \ wrap-attributes wrap-jste wrap-php wrap-script-literals + \ wrap-sections write-back + \ contained nextgroup=tidyBooleanDelimiter + +syn match tidyBooleanDelimiter ":" nextgroup=tidyBoolean contained skipwhite + +syn keyword tidyAutoBooleanOption indent merge-divs merge-spans output-bom show-body-only vertical-space contained nextgroup=tidyAutoBooleanDelimiter +syn match tidyAutoBooleanDelimiter ":" nextgroup=tidyAutoBoolean contained skipwhite + +syn keyword tidyCSSSelectorOption css-prefix contained nextgroup=tidyCSSSelectorDelimiter +syn match tidyCSSSelectorDelimiter ":" nextgroup=tidyCSSSelector contained skipwhite + +syn keyword tidyDoctypeOption doctype contained nextgroup=tidyDoctypeDelimiter +syn match tidyDoctypeDelimiter ":" nextgroup=tidyDoctype contained skipwhite + +syn keyword tidyEncodingOption char-encoding input-encoding output-encoding contained nextgroup=tidyEncodingDelimiter +syn match tidyEncodingDelimiter ":" nextgroup=tidyEncoding contained skipwhite + +syn keyword tidyIntegerOption accessibility-check doctype-mode indent-spaces show-errors tab-size wrap contained nextgroup=tidyIntegerDelimiter +syn match tidyIntegerDelimiter ":" nextgroup=tidyNumber contained skipwhite + +syn keyword tidyNameOption slide-style contained nextgroup=tidyNameDelimiter +syn match tidyNameDelimiter ":" nextgroup=tidyName contained skipwhite + +syn keyword tidyNewlineOption newline contained nextgroup=tidyNewlineDelimiter +syn match tidyNewlineDelimiter ":" nextgroup=tidyNewline contained skipwhite + +syn keyword tidyTagsOption new-blocklevel-tags new-empty-tags new-inline-tags new-pre-tags contained nextgroup=tidyTagsDelimiter +syn match tidyTagsDelimiter ":" nextgroup=tidyTags contained skipwhite + +syn keyword tidyRepeatOption repeated-attributes contained nextgroup=tidyRepeatDelimiter +syn match tidyRepeatDelimiter ":" nextgroup=tidyRepeat contained skipwhite + +syn keyword tidySorterOption sort-attributes contained nextgroup=tidySorterDelimiter +syn match tidySorterDelimiter ":" nextgroup=tidySorter contained skipwhite + +syn keyword tidyStringOption alt-text error-file gnu-emacs-file output-file contained nextgroup=tidyStringDelimiter +syn match tidyStringDelimiter ":" nextgroup=tidyString contained skipwhite + +syn cluster tidyOptions contains=tidy.*Option + +syn match tidyStart "^" nextgroup=@tidyOptions + +syn match tidyComment "^\s*//.*$" contains=tidyTodo +syn match tidyComment "^\s*#.*$" contains=tidyTodo +syn keyword tidyTodo TODO NOTE FIXME XXX contained + +hi def link tidyAutoBooleanOption Identifier +hi def link tidyBooleanOption Identifier +hi def link tidyCSSSelectorOption Identifier +hi def link tidyDoctypeOption Identifier +hi def link tidyEncodingOption Identifier +hi def link tidyIntegerOption Identifier +hi def link tidyNameOption Identifier +hi def link tidyNewlineOption Identifier +hi def link tidyTagsOption Identifier +hi def link tidyRepeatOption Identifier +hi def link tidySorterOption Identifier +hi def link tidyStringOption Identifier + +hi def link tidyAutoBooleanDelimiter Special +hi def link tidyBooleanDelimiter Special +hi def link tidyCSSSelectorDelimiter Special +hi def link tidyDoctypeDelimiter Special +hi def link tidyEncodingDelimiter Special +hi def link tidyIntegerDelimiter Special +hi def link tidyNameDelimiter Special +hi def link tidyNewlineDelimiter Special +hi def link tidyTagsDelimiter Special +hi def link tidyRepeatDelimiter Special +hi def link tidySorterDelimiter Special +hi def link tidyStringDelimiter Special + +hi def link tidyAutoBoolean Boolean +hi def link tidyBoolean Boolean +hi def link tidyDoctype Constant +hi def link tidyEncoding Constant +hi def link tidyNewline Constant +hi def link tidyTags Constant +hi def link tidyNumber Number +hi def link tidyRepeat Constant +hi def link tidySorter Constant +hi def link tidyString String + +hi def link tidyComment Comment +hi def link tidyTodo Todo + +let b:current_syntax = "tidy" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/tilde.vim b/syntax/tilde.vim new file mode 100644 index 0000000..a0084ae --- /dev/null +++ b/syntax/tilde.vim @@ -0,0 +1,45 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" This file works only for Vim6.x +" Language: Tilde +" Maintainer: Tobias Rundström +" URL: http://www.tildesoftware.net +" CVS: $Id: tilde.vim,v 1.1 2004/06/13 19:31:51 vimboss Exp $ + +if exists("b:current_syntax") + finish +endif + +"tilde dosent care ... +syn case ignore + +syn match tildeFunction "\~[a-z_0-9]\+"ms=s+1 +syn region tildeParen start="(" end=")" contains=tildeString,tildeNumber,tildeVariable,tildeField,tildeSymtab,tildeFunction,tildeParen,tildeHexNumber,tildeOperator +syn region tildeString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ keepend +syn region tildeString contained start=+'+ skip=+\\\\\|\\"+ end=+'+ keepend +syn match tildeNumber "\d" contained +syn match tildeOperator "or\|and" contained +syn match tildeHexNumber "0x[a-z0-9]\+" contained +syn match tildeVariable "$[a-z_0-9]\+" contained +syn match tildeField "%[a-z_0-9]\+" contained +syn match tildeSymtab "@[a-z_0-9]\+" contained +syn match tildeComment "^#.*" +syn region tildeCurly start=+{+ end=+}+ contained contains=tildeLG,tildeString,tildeNumber,tildeVariable,tildeField,tildeFunction,tildeSymtab,tildeHexNumber +syn match tildeLG "=>" contained + + +hi def link tildeComment Comment +hi def link tildeFunction Operator +hi def link tildeOperator Operator +hi def link tildeString String +hi def link tildeNumber Number +hi def link tildeHexNumber Number +hi def link tildeVariable Identifier +hi def link tildeField Identifier +hi def link tildeSymtab Identifier +hi def link tildeError Error + +let b:current_syntax = "tilde" + +endif diff --git a/syntax/tli.vim b/syntax/tli.vim new file mode 100644 index 0000000..ca7986c --- /dev/null +++ b/syntax/tli.vim @@ -0,0 +1,62 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TealInfo source files (*.tli) +" Maintainer: Kurt W. Andrews +" Last Change: 2001 May 10 +" Version: 1.0 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" TealInfo Objects + +syn keyword tliObject LIST POPLIST WINDOW POPWINDOW OUTLINE CHECKMARK GOTO +syn keyword tliObject LABEL IMAGE RECT TRES PASSWORD POPEDIT POPIMAGE CHECKLIST + +" TealInfo Fields + +syn keyword tliField X Y W H BX BY BW BH SX SY FONT BFONT CYCLE DELAY TABS +syn keyword tliField STYLE BTEXT RECORD DATABASE KEY TARGET DEFAULT TEXT +syn keyword tliField LINKS MAXVAL + +" TealInfo Styles + +syn keyword tliStyle INVERTED HORIZ_RULE VERT_RULE NO_SCROLL NO_BORDER BOLD_BORDER +syn keyword tliStyle ROUND_BORDER ALIGN_RIGHT ALIGN_CENTER ALIGN_LEFT_START ALIGN_RIGHT_START +syn keyword tliStyle ALIGN_CENTER_START ALIGN_LEFT_END ALIGN_RIGHT_END ALIGN_CENTER_END +syn keyword tliStyle LOCKOUT BUTTON_SCROLL BUTTON_SELECT STROKE_FIND FILLED REGISTER + +" String and Character constants + +syn match tliSpecial "@" +syn region tliString start=+"+ end=+"+ + +"TealInfo Numbers, identifiers and comments + +syn case ignore +syn match tliNumber "\d*" +syn match tliIdentifier "\<\h\w*\>" +syn match tliComment "#.*" +syn case match + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link tliNumber Number +hi def link tliString String +hi def link tliComment Comment +hi def link tliSpecial SpecialChar +hi def link tliIdentifier Identifier +hi def link tliObject Statement +hi def link tliField Type +hi def link tliStyle PreProc + + +let b:current_syntax = "tli" + +" vim: ts=8 + +endif diff --git a/syntax/tmux.vim b/syntax/tmux.vim index 6915389..100b9b2 100644 --- a/syntax/tmux.vim +++ b/syntax/tmux.vim @@ -1,3 +1,131 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: tmux(1) configuration file +" Version: 2.3 (git-14dc2ac) +" URL: https://github.com/ericpruitt/tmux.vim/ +" Maintainer: Eric Pruitt +" License: 2-Clause BSD (http://opensource.org/licenses/BSD-2-Clause) + +if exists("b:current_syntax") + finish +endif + +" Explicitly change compatiblity options to Vim's defaults because this file +" uses line continuations. +let s:original_cpo = &cpo +set cpo&vim + +let b:current_syntax = "tmux" +setlocal iskeyword+=- +syntax case match + +syn keyword tmuxAction none any current other +syn keyword tmuxBoolean off on + +syn keyword tmuxTodo FIXME NOTE TODO XXX contained + +syn match tmuxColour /\ 231 && s:i < 235)) ? 15 : "none" + exec "syn match tmuxColour" . s:i . " /\\/ display" +\ " | highlight tmuxColour" . s:i . " ctermfg=" . s:i . " ctermbg=" . s:bg +endfor + +syn keyword tmuxOptions +\ buffer-limit command-alias default-terminal escape-time exit-unattached +\ focus-events history-file message-limit set-clipboard terminal-overrides +\ assume-paste-time base-index bell-action bell-on-alert default-command +\ default-shell destroy-unattached detach-on-destroy +\ display-panes-active-colour display-panes-colour display-panes-time +\ display-time history-limit key-table lock-after-time lock-command +\ message-attr message-bg message-command-attr message-command-bg +\ message-command-fg message-command-style message-fg message-style mouse +\ prefix prefix2 renumber-windows repeat-time set-titles set-titles-string +\ status status-attr status-bg status-fg status-interval status-justify +\ status-keys status-left status-left-attr status-left-bg status-left-fg +\ status-left-length status-left-style status-position status-right +\ status-right-attr status-right-bg status-right-fg status-right-length +\ status-right-style status-style update-environment visual-activity +\ visual-bell visual-silence word-separators aggressive-resize allow-rename +\ alternate-screen automatic-rename automatic-rename-format +\ clock-mode-colour clock-mode-style force-height force-width +\ main-pane-height main-pane-width mode-attr mode-bg mode-fg mode-keys +\ mode-style monitor-activity monitor-silence other-pane-height +\ other-pane-width pane-active-border-bg pane-active-border-fg +\ pane-active-border-style pane-base-index pane-border-bg pane-border-fg +\ pane-border-format pane-border-status pane-border-style remain-on-exit +\ synchronize-panes window-active-style window-style +\ window-status-activity-attr window-status-activity-bg +\ window-status-activity-fg window-status-activity-style window-status-attr +\ window-status-bell-attr window-status-bell-bg window-status-bell-fg +\ window-status-bell-style window-status-bg window-status-current-attr +\ window-status-current-bg window-status-current-fg +\ window-status-current-format window-status-current-style window-status-fg +\ window-status-format window-status-last-attr window-status-last-bg +\ window-status-last-fg window-status-last-style window-status-separator +\ window-status-style wrap-search xterm-keys + +syn keyword tmuxCommands +\ attach-session attach bind-key bind break-pane breakp capture-pane +\ capturep clear-history clearhist choose-buffer choose-client choose-tree +\ choose-session choose-window command-prompt confirm-before confirm +\ copy-mode clock-mode detach-client detach suspend-client suspendc +\ display-message display display-panes displayp find-window findw if-shell +\ if join-pane joinp move-pane movep kill-pane killp kill-server +\ start-server start kill-session kill-window killw unlink-window unlinkw +\ list-buffers lsb list-clients lsc list-keys lsk list-commands lscm +\ list-panes lsp list-sessions ls list-windows lsw load-buffer loadb +\ lock-server lock lock-session locks lock-client lockc move-window movew +\ link-window linkw new-session new has-session has new-window neww +\ paste-buffer pasteb pipe-pane pipep refresh-client refresh rename-session +\ rename rename-window renamew resize-pane resizep respawn-pane respawnp +\ respawn-window respawnw rotate-window rotatew run-shell run save-buffer +\ saveb show-buffer showb select-layout selectl next-layout nextl +\ previous-layout prevl select-pane selectp last-pane lastp select-window +\ selectw next-window next previous-window prev last-window last send-keys +\ send send-prefix set-buffer setb delete-buffer deleteb set-environment +\ setenv set-hook show-hooks set-option set set-window-option setw +\ show-environment showenv show-messages showmsgs show-options show +\ show-window-options showw source-file source split-window splitw swap-pane +\ swapp swap-window swapw switch-client switchc unbind-key unbind wait-for +\ wait + +let &cpo = s:original_cpo +unlet! s:original_cpo s:bg s:i + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'tmux') == -1 " Vim syntax file diff --git a/syntax/tpp.vim b/syntax/tpp.vim new file mode 100644 index 0000000..dac6277 --- /dev/null +++ b/syntax/tpp.vim @@ -0,0 +1,87 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: tpp - Text Presentation Program +" Maintainer: Debian Vim Maintainers +" Former Maintainer: Gerfried Fuchs +" Last Change: 2007-10-14 +" URL: http://git.debian.org/?p=pkg-vim/vim.git;a=blob_plain;f=runtime/syntax/tpp.vim;hb=debian +" Filenames: *.tpp +" License: BSD +" +" XXX This file is in need of a new maintainer, Debian VIM Maintainers maintain +" it only because patches have been submitted for it by Debian users and the +" former maintainer was MIA (Missing In Action), taking over its +" maintenance was thus the only way to include those patches. +" If you care about this file, and have time to maintain it please do so! +" +" Comments are very welcome - but please make sure that you are commenting on +" the latest version of this file. +" SPAM is _NOT_ welcome - be ready to be reported! + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("main_syntax") + let main_syntax = 'tpp' +endif + + +"" list of the legal switches/options +syn match tppAbstractOptionKey contained "^--\%(author\|title\|date\|footer\) *" nextgroup=tppString +syn match tppPageLocalOptionKey contained "^--\%(heading\|center\|right\|huge\|sethugefont\|exec\) *" nextgroup=tppString +syn match tppPageLocalSwitchKey contained "^--\%(horline\|-\|\%(begin\|end\)\%(\%(shell\)\?output\|slide\%(left\|right\|top\|bottom\)\)\|\%(bold\|rev\|ul\)\%(on\|off\)\|withborder\)" +syn match tppNewPageOptionKey contained "^--newpage *" nextgroup=tppString +syn match tppColorOptionKey contained "^--\%(\%(bg\|fg\)\?color\) *" +syn match tppTimeOptionKey contained "^--sleep *" + +syn match tppString contained ".*" +syn match tppColor contained "\%(white\|yellow\|red\|green\|blue\|cyan\|magenta\|black\|default\)" +syn match tppTime contained "\d\+" + +syn region tppPageLocalSwitch start="^--" end="$" contains=tppPageLocalSwitchKey oneline +syn region tppColorOption start="^--\%(\%(bg\|fg\)\?color\)" end="$" contains=tppColorOptionKey,tppColor oneline +syn region tppTimeOption start="^--sleep" end="$" contains=tppTimeOptionKey,tppTime oneline +syn region tppNewPageOption start="^--newpage" end="$" contains=tppNewPageOptionKey oneline +syn region tppPageLocalOption start="^--\%(heading\|center\|right\|huge\|sethugefont\|exec\)" end="$" contains=tppPageLocalOptionKey oneline +syn region tppAbstractOption start="^--\%(author\|title\|date\|footer\)" end="$" contains=tppAbstractOptionKey oneline + +if main_syntax != 'sh' + " shell command + syn include @tppShExec syntax/sh.vim + unlet b:current_syntax + + syn region shExec matchgroup=tppPageLocalOptionKey start='^--exec *' keepend end='$' contains=@tppShExec + +endif + +syn match tppComment "^--##.*$" + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link tppAbstractOptionKey Special +hi def link tppPageLocalOptionKey Keyword +hi def link tppPageLocalSwitchKey Keyword +hi def link tppColorOptionKey Keyword +hi def link tppTimeOptionKey Comment +hi def link tppNewPageOptionKey PreProc +hi def link tppString String +hi def link tppColor String +hi def link tppTime Number +hi def link tppComment Comment +hi def link tppAbstractOption Error +hi def link tppPageLocalOption Error +hi def link tppPageLocalSwitch Error +hi def link tppColorOption Error +hi def link tppNewPageOption Error +hi def link tppTimeOption Error + + +let b:current_syntax = "tpp" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/trasys.vim b/syntax/trasys.vim new file mode 100644 index 0000000..8e13c21 --- /dev/null +++ b/syntax/trasys.vim @@ -0,0 +1,164 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TRASYS input file +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.inp +" URL: http://www.naglenet.org/vim/syntax/trasys.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +" Force free-form fortran format +let fortran_free_source=1 + +" Load FORTRAN syntax file +runtime! syntax/fortran.vim +unlet b:current_syntax + + +" Ignore case +syn case ignore + + + +" Define keywords for TRASYS +syn keyword trasysOptions model rsrec info maxfl nogo dmpdoc +syn keyword trasysOptions rsi rti rso rto bcdou cmerg emerg +syn keyword trasysOptions user1 nnmin erplot + +syn keyword trasysSurface icsn tx ty tz rotx roty rotz inc bcsn +syn keyword trasysSurface nnx nny nnz nnax nnr nnth unnx +syn keyword trasysSurface unny unnz unnax unnr unnth type idupsf +syn keyword trasysSurface imagsf act active com shade bshade axmin +syn keyword trasysSurface axmax zmin zmax rmin rmax thmin thmin +syn keyword trasysSurface thmax alpha emiss trani trans spri sprs +syn keyword trasysSurface refno posit com dupbcs dimensions +syn keyword trasysSurface dimension position prop surfn + +syn keyword trasysSurfaceType rect trap disk cyl cone sphere parab +syn keyword trasysSurfaceType box5 box6 shpero tor ogiv elem tape poly + +syn keyword trasysSurfaceArgs ff di top bottom in out both no only + +syn keyword trasysArgs fig smn nodea zero only ir sol +syn keyword trasysArgs both wband stepn initl + +syn keyword trasysOperations orbgen build + +"syn keyword trasysSubRoutine call +syn keyword trasysSubRoutine chgblk ndata ndatas odata odatas +syn keyword trasysSubRoutine pldta ffdata cmdata adsurf rbdata +syn keyword trasysSubRoutine rtdata pffshd orbit1 orbit2 orient +syn keyword trasysSubRoutine didt1 didt1s didt2 didt2s spin +syn keyword trasysSubRoutine spinav dicomp distab drdata gbdata +syn keyword trasysSubRoutine gbaprx rkdata rcdata aqdata stfaq +syn keyword trasysSubRoutine qodata qoinit modar modpr modtr +syn keyword trasysSubRoutine modprs modshd moddat rstoff rston +syn keyword trasysSubRoutine rsmerg ffread diread ffusr1 diusr1 +syn keyword trasysSubRoutine surfp didt3 didt3s romain stfrc +syn keyword trasysSubRoutine rornt rocstr romove flxdata title + +syn keyword trassyPrcsrSegm nplot oplot plot cmcal ffcal rbcal +syn keyword trassyPrcsrSegm rtcal dical drcal sfcal gbcal rccal +syn keyword trassyPrcsrSegm rkcal aqcal qocal + + + +" Define matches for TRASYS +syn match trasysOptions "list source" +syn match trasysOptions "save source" +syn match trasysOptions "no print" + +"syn match trasysSurface "^K *.* [^$]" +"syn match trasysSurface "^D *[0-9]*\.[0-9]\+" +"syn match trasysSurface "^I *.*[0-9]\+\.\=" +"syn match trasysSurface "^N *[0-9]\+" +"syn match trasysSurface "^M *[a-z[A-Z0-9]\+" +"syn match trasysSurface "^B[C][S] *[a-zA-Z0-9]*" +"syn match trasysSurface "^S *SURFN.*[0-9]" +syn match trasysSurface "P[0-9]* *="he=e-1 + +syn match trasysIdentifier "^L "he=e-1 +syn match trasysIdentifier "^K "he=e-1 +syn match trasysIdentifier "^D "he=e-1 +syn match trasysIdentifier "^I "he=e-1 +syn match trasysIdentifier "^N "he=e-1 +syn match trasysIdentifier "^M "he=e-1 +syn match trasysIdentifier "^B[C][S]" +syn match trasysIdentifier "^S "he=e-1 + +syn match trasysComment "^C.*$" +syn match trasysComment "^R.*$" +syn match trasysComment "\$.*$" + +syn match trasysHeader "^header[^,]*" + +syn match trasysMacro "^FAC" + +syn match trasysInteger "-\=\<[0-9]*\>" +syn match trasysFloat "-\=\<[0-9]*\.[0-9]*" +syn match trasysScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>" + +syn match trasysBlank "' \+'"hs=s+1,he=e-1 + +syn match trasysEndData "^END OF DATA" + +if exists("thermal_todo") + execute 'syn match trasysTodo ' . '"^'.thermal_todo.'.*$"' +else + syn match trasysTodo "^?.*$" +endif + + + +" Define regions for TRASYS +syn region trasysComment matchgroup=trasysHeader start="^HEADER DOCUMENTATION DATA" end="^HEADER[^,]*" + + + +" Define synchronizing patterns for TRASYS +syn sync maxlines=500 +syn sync match trasysSync grouphere trasysComment "^HEADER DOCUMENTATION DATA" + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link trasysOptions Special +hi def link trasysSurface Special +hi def link trasysSurfaceType Constant +hi def link trasysSurfaceArgs Constant +hi def link trasysArgs Constant +hi def link trasysOperations Statement +hi def link trasysSubRoutine Statement +hi def link trassyPrcsrSegm PreProc +hi def link trasysIdentifier Identifier +hi def link trasysComment Comment +hi def link trasysHeader Typedef +hi def link trasysMacro Macro +hi def link trasysInteger Number +hi def link trasysFloat Float +hi def link trasysScientific Float + +hi def link trasysBlank SpecialChar + +hi def link trasysEndData Macro + +hi def link trasysTodo Todo + + + +let b:current_syntax = "trasys" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/treetop.vim b/syntax/treetop.vim new file mode 100644 index 0000000..dddccf6 --- /dev/null +++ b/syntax/treetop.vim @@ -0,0 +1,114 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Treetop +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2011-03-14 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword treetopTodo + \ contained + \ TODO + \ FIXME + \ XXX + \ NOTE + +syn match treetopComment + \ '#.*' + \ display + \ contains=treetopTodo + +syn include @treetopRuby syntax/ruby.vim +unlet b:current_syntax + +syn keyword treetopKeyword + \ require + \ end +syn region treetopKeyword + \ matchgroup=treetopKeyword + \ start='\<\%(grammar\|include\|module\)\>\ze\s' + \ end='$' + \ transparent + \ oneline + \ keepend + \ contains=@treetopRuby +syn keyword treetopKeyword + \ rule + \ nextgroup=treetopRuleName + \ skipwhite skipnl + +syn match treetopGrammarName + \ '\u\w*' + \ contained + +syn match treetopRubyModuleName + \ '\u\w*' + \ contained + +syn match treetopRuleName + \ '\h\w*' + \ contained + +syn region treetopString + \ matchgroup=treetopStringDelimiter + \ start=+"+ + \ end=+"+ +syn region treetopString + \ matchgroup=treetopStringDelimiter + \ start=+'+ + \ end=+'+ + +syn region treetopCharacterClass + \ matchgroup=treetopCharacterClassDelimiter + \ start=+\[+ + \ skip=+\\\]+ + \ end=+\]+ + +syn region treetopRubyBlock + \ matchgroup=treetopRubyBlockDelimiter + \ start=+{+ + \ end=+}+ + \ contains=@treetopRuby + +syn region treetopSemanticPredicate + \ matchgroup=treetopSemanticPredicateDelimiter + \ start=+[!&]{+ + \ end=+}+ + \ contains=@treetopRuby + +syn region treetopSubclassDeclaration + \ matchgroup=treetopSubclassDeclarationDelimiter + \ start=+<+ + \ end=+>+ + \ contains=@treetopRuby + +syn match treetopEllipsis + \ +''+ + +hi def link treetopTodo Todo +hi def link treetopComment Comment +hi def link treetopKeyword Keyword +hi def link treetopGrammarName Constant +hi def link treetopRubyModuleName Constant +hi def link treetopRuleName Identifier +hi def link treetopString String +hi def link treetopStringDelimiter treetopString +hi def link treetopCharacterClass treetopString +hi def link treetopCharacterClassDelimiter treetopCharacterClass +hi def link treetopRubyBlockDelimiter PreProc +hi def link treetopSemanticPredicateDelimiter PreProc +hi def link treetopSubclassDeclarationDelimiter PreProc +hi def link treetopEllipsis Special + +let b:current_syntax = 'treetop' + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/trustees.vim b/syntax/trustees.vim new file mode 100644 index 0000000..be975b6 --- /dev/null +++ b/syntax/trustees.vim @@ -0,0 +1,46 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: trustees +" Maintainer: Nima Talebi +" Last Change: 2005-10-12 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syntax case match +syntax sync minlines=0 maxlines=0 + +" Errors & Comments +syntax match tfsError /.*/ +highlight link tfsError Error +syntax keyword tfsSpecialComment TODO XXX FIXME contained +highlight link tfsSpecialComment Todo +syntax match tfsComment ~\s*#.*~ contains=tfsSpecialComment +highlight link tfsComment Comment + +" Operators & Delimiters +highlight link tfsSpecialChar Operator +syntax match tfsSpecialChar ~[*!+]~ contained +highlight link tfsDelimiter Delimiter +syntax match tfsDelimiter ~:~ contained + +" Trustees Rules - Part 1 of 3 - The Device +syntax region tfsRuleDevice matchgroup=tfsDeviceContainer start=~\[/~ end=~\]~ nextgroup=tfsRulePath oneline +highlight link tfsRuleDevice Label +highlight link tfsDeviceContainer PreProc + +" Trustees Rules - Part 2 of 3 - The Path +syntax match tfsRulePath ~/[-_a-zA-Z0-9/]*~ nextgroup=tfsRuleACL contained contains=tfsDelimiter +highlight link tfsRulePath String + +" Trustees Rules - Part 3 of 3 - The ACLs +syntax match tfsRuleACL ~\(:\(\*\|[+]\{0,1\}[a-zA-Z0-9/]\+\):[RWEBXODCU!]\+\)\+$~ contained contains=tfsDelimiter,tfsRuleWho,tfsRuleWhat +syntax match tfsRuleWho ~\(\*\|[+]\{0,1\}[a-zA-Z0-9/]\+\)~ contained contains=tfsSpecialChar +highlight link tfsRuleWho Identifier +syntax match tfsRuleWhat ~[RWEBXODCU!]\+~ contained contains=tfsSpecialChar +highlight link tfsRuleWhat Structure + +endif diff --git a/syntax/tsalt.vim b/syntax/tsalt.vim new file mode 100644 index 0000000..55fe13e --- /dev/null +++ b/syntax/tsalt.vim @@ -0,0 +1,210 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Telix (Modem Comm Program) SALT Script +" Maintainer: Sean M. McKee +" Last Change: 2012 Feb 03 by Thilo Six +" Version Info: @(#)tsalt.vim 1.5 97/12/16 08:11:15 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" turn case matching off +syn case ignore + +"FUNCTIONS +" Character Handling Functions +syn keyword tsaltFunction IsAscii IsAlNum IsAlpha IsCntrl IsDigit +syn keyword tsaltFunction IsLower IsUpper ToLower ToUpper + +" Connect Device Operations +syn keyword tsaltFunction Carrier cInp_Cnt cGetC cGetCT cPutC cPutN +syn keyword tsaltFunction cPutS cPutS_TR FlushBuf Get_Baud +syn keyword tsaltFunction Get_DataB Get_Port Get_StopB Hangup +syn keyword tsaltFunction KillConnectDevice MakeConnectDevice +syn keyword tsaltFunction Send_Brk Set_ConnectDevice Set_Port + +" File Input/Output Operations +syn keyword tsaltFunction fClearErr fClose fDelete fError fEOF fFlush +syn keyword tsaltFunction fGetC fGetS FileAttr FileFind FileSize +syn keyword tsaltFunction FileTime fnStrip fOpen fPutC fPutS fRead +syn keyword tsaltFunction fRename fSeek fTell fWrite + +" File Transfers and Logs +syn keyword tsaltFunction Capture Capture_Stat Printer Receive Send +syn keyword tsaltFunction Set_DefProt UsageLog Usage_Stat UStamp + +" Input String Matching +syn keyword tsaltFunction Track Track_AddChr Track_Free Track_Hit +syn keyword tsaltFunction WaitFor + +" Keyboard Operations +syn keyword tsaltFunction InKey InKeyW KeyGet KeyLoad KeySave KeySet + +" Miscellaneous Functions +syn keyword tsaltFunction ChatMode Dos Dial DosFunction ExitTelix +syn keyword tsaltFunction GetEnv GetFon HelpScreen LoadFon NewDir +syn keyword tsaltFunction Randon Redial RedirectDOS Run +syn keyword tsaltFunction Set_Terminal Show_Directory TelixVersion +syn keyword tsaltFunction Terminal TransTab Update_Term + +" Script Management +syn keyword tsaltFunction ArgCount Call CallD CompileScript GetRunPath +syn keyword tsaltFunction Is_Loaded Load_Scr ScriptVersion +syn keyword tsaltFunction TelixForWindows Unload_Scr + +" Sound Functions +syn keyword tsaltFunction Alarm PlayWave Tone + +" String Handling +syn keyword tsaltFunction CopyChrs CopyStr DelChrs GetS GetSXY +syn keyword tsaltFunction InputBox InsChrs ItoS SetChr StoI StrCat +syn keyword tsaltFunction StrChr StrCompI StrLen StrLower StrMaxLen +syn keyword tsaltFunction StrPos StrPosI StrUpper SubChr SubChrs +syn keyword tsaltFunction SubStr + +" Time, Date, and Timer Operations +syn keyword tsaltFunction CurTime Date Delay Delay_Scr Get_OnlineTime +syn keyword tsaltFunction tDay tHour tMin tMonth tSec tYear Time +syn keyword tsaltFunction Time_Up Timer_Free Time_Restart +syn keyword tsaltFunction Time_Start Time_Total + +" Video Operations +syn keyword tsaltFunction Box CNewLine Cursor_OnOff Clear_Scr +syn keyword tsaltFunction GetTermHeight GetTermWidth GetX GetY +syn keyword tsaltFunction GotoXY MsgBox NewLine PrintC PrintC_Trm +syn keyword tsaltFunction PrintN PrintN_Trm PrintS PrintS_Trm +syn keyword tsaltFunction PrintSC PRintSC_Trm +syn keyword tsaltFunction PStrA PStrAXY Scroll Status_Wind vGetChr +syn keyword tsaltFunction vGetChrs vGetChrsA vPutChr vPutChrs +syn keyword tsaltFunction vPutChrsA vRstrArea vSaveArea + +" Dynamic Data Exchange (DDE) Operations +syn keyword tsaltFunction DDEExecute DDEInitate DDEPoke DDERequest +syn keyword tsaltFunction DDETerminate DDETerminateAll +"END FUNCTIONS + +"PREDEFINED VARAIABLES +syn keyword tsaltSysVar _add_lf _alarm_on _answerback_str _asc_rcrtrans +syn keyword tsaltSysVar _asc_remabort _asc_rlftrans _asc_scpacing +syn keyword tsaltSysVar _asc_scrtrans _asc_secho _asc_slpacing +syn keyword tsaltSysVar _asc_spacechr _asc_striph _back_color +syn keyword tsaltSysVar _capture_fname _connect_str _dest_bs +syn keyword tsaltSysVar _dial_pause _dial_time _dial_post +syn keyword tsaltSysVar _dial_pref1 _dial_pref2 _dial_pref3 +syn keyword tsaltSysVar _dial_pref4 _dir_prog _down_dir +syn keyword tsaltSysVar _entry_bbstype _entry_comment _entry_enum +syn keyword tsaltSysVar _entry_name _entry_num _entry_logonname +syn keyword tsaltSysVar _entry_pass _fore_color _image_file +syn keyword tsaltSysVar _local_echo _mdm_hang_str _mdm_init_str +syn keyword tsaltSysVar _no_connect1 _no_connect2 _no_connect3 +syn keyword tsaltSysVar _no_connect4 _no_connect5 _redial_stop +syn keyword tsaltSysVar _scr_chk_key _script_dir _sound_on +syn keyword tsaltSysVar _strip_high _swap_bs _telix_dir _up_dir +syn keyword tsaltSysVar _usage_fname _zmodauto _zmod_rcrash +syn keyword tsaltSysVar _zmod_scrash +"END PREDEFINED VARAIABLES + +"TYPE +syn keyword tsaltType str int +"END TYPE + +"KEYWORDS +syn keyword tsaltStatement goto break return continue +syn keyword tsaltConditional if then else +syn keyword tsaltRepeat while for do +"END KEYWORDS + +syn keyword tsaltTodo contained TODO + +" the rest is pretty close to C ----------------------------------------- + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match tsaltSpecial contained "\^\d\d\d\|\^." +syn region tsaltString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=tsaltSpecial +syn match tsaltCharacter "'[^\\]'" +syn match tsaltSpecialCharacter "'\\.'" + +"catch errors caused by wrong parenthesis +syn region tsaltParen transparent start='(' end=')' contains=ALLBUT,tsaltParenError,tsaltIncluded,tsaltSpecial,tsaltTodo +syn match tsaltParenError ")" +syn match tsaltInParen contained "[{}]" + +hi link tsaltParenError tsaltError +hi link tsaltInParen tsaltError + +"integer number, or floating point number without a dot and with "f". +syn match tsaltNumber "\<\d\+\(u\=l\=\|lu\|f\)\>" +"floating point number, with dot, optional exponent +syn match tsaltFloat "\<\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, starting with a dot, optional exponent +syn match tsaltFloat "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match tsaltFloat "\<\d\+e[-+]\=\d\+[fl]\=\>" +"hex number +syn match tsaltNumber "0x[0-9a-f]\+\(u\=l\=\|lu\)\>" +"syn match cIdentifier "\<[a-z_][a-z0-9_]*\>" + +syn region tsaltComment start="/\*" end="\*/" contains=cTodo +syn match tsaltComment "//.*" contains=cTodo +syn match tsaltCommentError "\*/" + +syn region tsaltPreCondit start="^[ \t]*#[ \t]*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=tsaltComment,tsaltString,tsaltCharacter,tsaltNumber,tsaltCommentError +syn region tsaltIncluded contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match tsaltIncluded contained "<[^>]*>" +syn match tsaltInclude "^[ \t]*#[ \t]*include\>[ \t]*["<]" contains=tsaltIncluded +"syn match TelixSalyLineSkip "\\$" +syn region tsaltDefine start="^[ \t]*#[ \t]*\(define\>\|undef\>\)" skip="\\$" end="$" contains=ALLBUT,tsaltPreCondit,tsaltIncluded,tsaltInclude,tsaltDefine,tsaltInParen +syn region tsaltPreProc start="^[ \t]*#[ \t]*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" contains=ALLBUT,tsaltPreCondit,tsaltIncluded,tsaltInclude,tsaltDefine,tsaltInParen + +" Highlight User Labels +syn region tsaltMulti transparent start='?' end=':' contains=ALLBUT,tsaltIncluded,tsaltSpecial,tsaltTodo + +syn sync ccomment tsaltComment + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link tsaltFunction Statement +hi def link tsaltSysVar Type +"hi def link tsaltLibFunc UserDefFunc +"hi def link tsaltConstants Type +"hi def link tsaltFuncArg Type +"hi def link tsaltOperator Operator +"hi def link tsaltLabel Label +"hi def link tsaltUserLabel Label +hi def link tsaltConditional Conditional +hi def link tsaltRepeat Repeat +hi def link tsaltCharacter SpecialChar +hi def link tsaltSpecialCharacter SpecialChar +hi def link tsaltNumber Number +hi def link tsaltFloat Float +hi def link tsaltCommentError tsaltError +hi def link tsaltInclude Include +hi def link tsaltPreProc PreProc +hi def link tsaltDefine Macro +hi def link tsaltIncluded tsaltString +hi def link tsaltError Error +hi def link tsaltStatement Statement +hi def link tsaltPreCondit PreCondit +hi def link tsaltType Type +hi def link tsaltString String +hi def link tsaltComment Comment +hi def link tsaltSpecial Special +hi def link tsaltTodo Todo + + +let b:current_syntax = "tsalt" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 + +endif diff --git a/syntax/tsscl.vim b/syntax/tsscl.vim new file mode 100644 index 0000000..c90750a --- /dev/null +++ b/syntax/tsscl.vim @@ -0,0 +1,208 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TSS (Thermal Synthesizer System) Command Line +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.tsscl +" URL: http://www.naglenet.org/vim/syntax/tsscl.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case ignore + + + +" +" +" Begin syntax definitions for tss geomtery file. +" + +" Load TSS geometry syntax file +"source $VIM/myvim/tssgm.vim +"source $VIMRUNTIME/syntax/c.vim + +" Define keywords for TSS +syn keyword tssclCommand begin radk list heatrates attr draw + +syn keyword tssclKeyword cells rays error nodes levels objects cpu +syn keyword tssclKeyword units length positions energy time unit solar +syn keyword tssclKeyword solar_constant albedo planet_power + +syn keyword tssclEnd exit + +syn keyword tssclUnits cm feet meters inches +syn keyword tssclUnits Celsius Kelvin Fahrenheit Rankine + + + +" Define matches for TSS +syn match tssclString /"[^"]\+"/ contains=ALLBUT,tssInteger,tssclKeyword,tssclCommand,tssclEnd,tssclUnits + +syn match tssclComment "#.*$" + +" rational and logical operators +" < Less than +" > Greater than +" <= Less than or equal +" >= Greater than or equal +" == or = Equal to +" != Not equal to +" && or & Logical AND +" || or | Logical OR +" ! Logical NOT +" +" algebraic operators: +" ^ or ** Exponentation +" * Multiplication +" / Division +" % Remainder +" + Addition +" - Subtraction +" +syn match tssclOper "||\||\|&&\|&\|!=\|!\|>=\|<=\|>\|<\|+\|-\|^\|\*\*\|\*\|/\|%\|==\|=\|\." skipwhite + +" CLI Directive Commands, with arguments +" +" BASIC COMMAND LIST +" *ADD input_source +" *ARITHMETIC { [ON] | OFF } +" *CLOSE unit_number +" *CPU +" *DEFINE +" *ECHO[/qualifiers] { [ON] | OFF } +" *ELSE [IF { 0 | 1 } ] +" *END { IF | WHILE } +" *EXIT +" *IF { 0 | 1 } +" *LIST/n list variable +" *OPEN[/r | /r+ | /w | /w+ ] unit_number file_name +" *PROMPT prompt_string sybol_name +" *READ/unit=unit_number[/LOCAL | /GLOBAL ] sym1 [sym2, [sym3 ...]] +" *REWIND +" *STOP +" *STRCMP string_1 string_2 difference +" *SYSTEM command +" *UNDEFINE[/LOCAL][/GLOBAL] symbol_name +" *WHILE { 0 | 1 } +" *WRITE[/unit=unit_number] output text +" +syn match tssclDirective "\*ADD" +syn match tssclDirective "\*ARITHMETIC \+\(ON\|OFF\)" +syn match tssclDirective "\*CLOSE" +syn match tssclDirective "\*CPU" +syn match tssclDirective "\*DEFINE" +syn match tssclDirective "\*ECHO" +syn match tssclConditional "\*ELSE" +syn match tssclConditional "\*END \+\(IF\|WHILE\)" +syn match tssclDirective "\*EXIT" +syn match tssclConditional "\*IF" +syn match tssclDirective "\*LIST" +syn match tssclDirective "\*OPEN" +syn match tssclDirective "\*PROMPT" +syn match tssclDirective "\*READ" +syn match tssclDirective "\*REWIND" +syn match tssclDirective "\*STOP" +syn match tssclDirective "\*STRCMP" +syn match tssclDirective "\*SYSTEM" +syn match tssclDirective "\*UNDEFINE" +syn match tssclConditional "\*WHILE" +syn match tssclDirective "\*WRITE" + +syn match tssclContChar "-$" + +" C library functoins +" Bessel functions (jn, yn) +" Error and complementary error fuctions (erf, erfc) +" Exponential functions (exp) +" Logrithm (log, log10) +" Power (pow) +" Square root (sqrt) +" Floor (floor) +" Ceiling (ceil) +" Floating point remainder (fmod) +" Floating point absolute value (fabs) +" Gamma (gamma) +" Euclidean distance function (hypot) +" Hperbolic functions (sinh, cosh, tanh) +" Trigometric functions in radians (sin, cos, tan, asin, acos, atan, atan2) +" Trigometric functions in degrees (sind, cosd, tand, asind, acosd, atand, +" atan2d) +" +" local varialbles: cl_arg1, cl_arg2, etc. (cl_arg is an array of arguments) +" cl_args is the number of arguments +" +" +" I/O: *PROMPT, *WRITE, *READ +" +" Conditional branching: +" IF, ELSE IF, END +" *IF value *IF I==10 +" *ELSE IF value *ELSE IF I<10 +" *ELSE *ELSE +" *ENDIF *ENDIF +" +" +" Iterative looping: +" WHILE +" *WHILE test +" ..... +" *END WHILE +" +" +" EXAMPLE: +" *DEFINE I = 1 +" *WHILE (I <= 10) +" *WRITE I = 'I' +" *DEFINE I = (I + 1) +" *END WHILE +" + +syn match tssclQualifier "/[^/ ]\+"hs=s+1 +syn match tssclSymbol "'\S\+'" +"syn match tssclSymbol2 " \S\+ " contained + +syn match tssclInteger "-\=\<[0-9]*\>" +syn match tssclFloat "-\=\<[0-9]*\.[0-9]*" +syn match tssclScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>" + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link tssclCommand Statement +hi def link tssclKeyword Special +hi def link tssclEnd Macro +hi def link tssclUnits Special + +hi def link tssclComment Comment +hi def link tssclDirective Statement +hi def link tssclConditional Conditional +hi def link tssclContChar Macro +hi def link tssclQualifier Typedef +hi def link tssclSymbol Identifier +hi def link tssclSymbol2 Symbol +hi def link tssclString String +hi def link tssclOper Operator + +hi def link tssclInteger Number +hi def link tssclFloat Number +hi def link tssclScientific Number + + + +let b:current_syntax = "tsscl" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/tssgm.vim b/syntax/tssgm.vim new file mode 100644 index 0000000..00302b8 --- /dev/null +++ b/syntax/tssgm.vim @@ -0,0 +1,102 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TSS (Thermal Synthesizer System) Geometry +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.tssgm +" URL: http://www.naglenet.org/vim/syntax/tssgm.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case ignore + + + +" +" +" Begin syntax definitions for tss geomtery file. +" + +" Define keywords for TSS +syn keyword tssgmParam units mirror param active sides submodel include +syn keyword tssgmParam iconductor nbeta ngamma optics material thickness color +syn keyword tssgmParam initial_temp +syn keyword tssgmParam initial_id node_ids node_add node_type +syn keyword tssgmParam gamma_boundaries gamma_add beta_boundaries +syn keyword tssgmParam p1 p2 p3 p4 p5 p6 rot1 rot2 rot3 tx ty tz + +syn keyword tssgmSurfType rectangle trapezoid disc ellipse triangle +syn keyword tssgmSurfType polygon cylinder cone sphere ellipic-cone +syn keyword tssgmSurfType ogive torus box paraboloid hyperboloid ellipsoid +syn keyword tssgmSurfType quadrilateral trapeziod + +syn keyword tssgmArgs OUT IN DOWN BOTH DOUBLE NONE SINGLE RADK CC FECC +syn keyword tssgmArgs white red blue green yellow orange violet pink +syn keyword tssgmArgs turquoise grey black +syn keyword tssgmArgs Arithmetic Boundary Heater + +syn keyword tssgmDelim assembly + +syn keyword tssgmEnd end + +syn keyword tssgmUnits cm feet meters inches +syn keyword tssgmUnits Celsius Kelvin Fahrenheit Rankine + + + +" Define matches for TSS +syn match tssgmDefault "^DEFAULT/LENGTH = \(ft\|in\|cm\|m\)" +syn match tssgmDefault "^DEFAULT/TEMP = [CKFR]" + +syn match tssgmComment /comment \+= \+".*"/ contains=tssParam,tssgmCommentString +syn match tssgmCommentString /".*"/ contained + +syn match tssgmSurfIdent " \S\+\.\d\+ \=$" + +syn match tssgmString /"[^" ]\+"/ms=s+1,me=e-1 contains=ALLBUT,tssInteger + +syn match tssgmArgs / = [xyz],"/ms=s+3,me=e-2 + +syn match tssgmInteger "-\=\<[0-9]*\>" +syn match tssgmFloat "-\=\<[0-9]*\.[0-9]*" +syn match tssgmScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>" + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link tssgmParam Statement +hi def link tssgmSurfType Type +hi def link tssgmArgs Special +hi def link tssgmDelim Typedef +hi def link tssgmEnd Macro +hi def link tssgmUnits Special + +hi def link tssgmDefault SpecialComment +hi def link tssgmComment Statement +hi def link tssgmCommentString Comment +hi def link tssgmSurfIdent Identifier +hi def link tssgmString Delimiter + +hi def link tssgmInteger Number +hi def link tssgmFloat Float +hi def link tssgmScientific Float + + + +let b:current_syntax = "tssgm" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/tssop.vim b/syntax/tssop.vim new file mode 100644 index 0000000..d2dd255 --- /dev/null +++ b/syntax/tssop.vim @@ -0,0 +1,78 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: TSS (Thermal Synthesizer System) Optics +" Maintainer: Adrian Nagle, anagle@ball.com +" Last Change: 2003 May 11 +" Filenames: *.tssop +" URL: http://www.naglenet.org/vim/syntax/tssop.vim +" MAIN URL: http://www.naglenet.org/vim/ + + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + + +" Ignore case +syn case ignore + + + +" +" +" Begin syntax definitions for tss optics file. +" + +" Define keywords for TSS +syn keyword tssopParam ir_eps ir_trans ir_spec ir_tspec ir_refract +syn keyword tssopParam sol_eps sol_trans sol_spec sol_tspec sol_refract +syn keyword tssopParam color + +"syn keyword tssopProp property + +syn keyword tssopArgs white red blue green yellow orange violet pink +syn keyword tssopArgs turquoise grey black + + + +" Define matches for TSS +syn match tssopComment /comment \+= \+".*"/ contains=tssopParam,tssopCommentString +syn match tssopCommentString /".*"/ contained + +syn match tssopProp "property " +syn match tssopProp "edit/optic " +syn match tssopPropName "^property \S\+" contains=tssopProp +syn match tssopPropName "^edit/optic \S\+$" contains=tssopProp + +syn match tssopInteger "-\=\<[0-9]*\>" +syn match tssopFloat "-\=\<[0-9]*\.[0-9]*" +syn match tssopScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>" + + + +" Define the default highlighting +" Only when an item doesn't have highlighting yet + +hi def link tssopParam Statement +hi def link tssopProp Identifier +hi def link tssopArgs Special + +hi def link tssopComment Statement +hi def link tssopCommentString Comment +hi def link tssopPropName Typedef + +hi def link tssopInteger Number +hi def link tssopFloat Float +hi def link tssopScientific Float + + + +let b:current_syntax = "tssop" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/tt2.vim b/syntax/tt2.vim index 4f94834..870f0b1 100644 --- a/syntax/tt2.vim +++ b/syntax/tt2.vim @@ -1,3 +1,217 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: TT2 (Perl Template Toolkit) +" Maintainer: vim-perl +" Author: Moriki, Atsushi <4woods+vim@gmail.com> +" Homepage: http://github.com/vim-perl/vim-perl +" Bugs/requests: http://github.com/vim-perl/vim-perl/issues +" Last Change: 2015-04-25 +" +" Installation: +" put tt2.vim and tt2html.vim in to your syntax directory. +" +" add below in your filetype.vim. +" au BufNewFile,BufRead *.tt2 setf tt2 +" or +" au BufNewFile,BufRead *.tt2 +" \ if ( getline(1) . getline(2) . getline(3) =~ '<\chtml' | +" \ && getline(1) . getline(2) . getline(3) !~ '<[%?]' ) | +" \ || getline(1) =~ '' +" "PHP" +" :let b:tt2_syn_tags = '' +" "TT2 and HTML" +" :let b:tt2_syn_tags = '\[% %] ' +" +" Changes: +" 0.1.3 +" Changed fileformat from 'dos' to 'unix' +" Deleted 'echo' that print obstructive message +" 0.1.2 +" Added block comment syntax +" e.g. [%# COMMENT +" COMMENT TOO %] +" [%# IT'S SAFE %] HERE IS OUTSIDE OF TT2 DIRECTIVE +" [% # WRONG!! %] HERE STILL BE COMMENT +" 0.1.1 +" Release +" 0.1.0 +" Internal +" +" License: follow Vim :help uganda +" + +if !exists("b:tt2_syn_tags") + let b:tt2_syn_tags = '\[% %]' + "let b:tt2_syn_tags = '\[% %] \[\* \*]' +endif + +if !exists("b:tt2_syn_inc_perl") + let b:tt2_syn_inc_perl = 1 +endif + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn case match + +syn cluster tt2_top_cluster contains=tt2_perlcode,tt2_tag_region + +" TT2 TAG Region +if exists("b:tt2_syn_tags") + + let s:str = b:tt2_syn_tags . ' ' + let s:str = substitute(s:str,'^ \+','','g') + let s:str = substitute(s:str,' \+',' ','g') + + while stridx(s:str,' ') > 0 + + let s:st = strpart(s:str,0,stridx(s:str,' ')) + let s:str = substitute(s:str,'[^ ]* ','',"") + + let s:ed = strpart(s:str,0,stridx(s:str,' ')) + let s:str = substitute(s:str,'[^ ]* ','',"") + + exec 'syn region tt2_tag_region '. + \ 'matchgroup=tt2_tag '. + \ 'start=+\(' . s:st .'\)[-]\=+ '. + \ 'end=+[-]\=\(' . s:ed . '\)+ '. + \ 'contains=@tt2_statement_cluster keepend extend' + + exec 'syn region tt2_commentblock_region '. + \ 'matchgroup=tt2_tag '. + \ 'start=+\(' . s:st .'\)[-]\=\(#\)\@=+ '. + \ 'end=+[-]\=\(' . s:ed . '\)+ '. + \ 'keepend extend' + + "Include Perl syntax when 'PERL' 'RAWPERL' block + if b:tt2_syn_inc_perl + syn include @Perl $VIMRUNTIME/syntax/perl.vim + exec 'syn region tt2_perlcode '. + \ 'start=+\(\(RAW\)\=PERL\s*[-]\=' . s:ed . '\(\n\)\=\)\@<=+ ' . + \ 'end=+' . s:st . '[-]\=\s*END+me=s-1 contains=@Perl keepend' + endif + + "echo 'TAGS ' . s:st . ' ' . s:ed + unlet s:st + unlet s:ed + endwhile + +else + + syn region tt2_tag_region + \ matchgroup=tt2_tag + \ start=+\(\[%\)[-]\=+ + \ end=+[-]\=%\]+ + \ contains=@tt2_statement_cluster keepend extend + + syn region tt2_commentblock_region + \ matchgroup=tt2_tag + \ start=+\(\[%\)[-]\=#+ + \ end=+[-]\=%\]+ + \ keepend extend + + "Include Perl syntax when 'PERL' 'RAWPERL' block + if b:tt2_syn_inc_perl + syn include @Perl $VIMRUNTIME/syntax/perl.vim + syn region tt2_perlcode + \ start=+\(\(RAW\)\=PERL\s*[-]\=%]\(\n\)\=\)\@<=+ + \ end=+\[%[-]\=\s*END+me=s-1 + \ contains=@Perl keepend + endif +endif + +" Directive +syn keyword tt2_directive contained + \ GET CALL SET DEFAULT DEBUG + \ LAST NEXT BREAK STOP BLOCK + \ IF IN UNLESS ELSIF FOR FOREACH WHILE SWITCH CASE + \ USE PLUGIN MACRO META + \ TRY FINAL RETURN LAST + \ CLEAR TO STEP AND OR NOT MOD DIV + \ ELSE PERL RAWPERL END +syn match tt2_directive +|+ contained +syn keyword tt2_directive contained nextgroup=tt2_string_q,tt2_string_qq,tt2_blockname skipwhite skipempty + \ INSERT INCLUDE PROCESS WRAPPER FILTER + \ THROW CATCH +syn keyword tt2_directive contained nextgroup=tt2_def_tag skipwhite skipempty + \ TAGS + +syn match tt2_def_tag "\S\+\s\+\S\+\|\<\w\+\>" contained + +syn match tt2_variable +\I\w*+ contained +syn match tt2_operator "[+*/%:?-]" contained +syn match tt2_operator "\<\(mod\|div\|or\|and\|not\)\>" contained +syn match tt2_operator "[!=<>]=\=\|&&\|||" contained +syn match tt2_operator "\(\s\)\@<=_\(\s\)\@=" contained +syn match tt2_operator "=>\|," contained +syn match tt2_deref "\([[:alnum:]_)\]}]\s*\)\@<=\." contained +syn match tt2_comment +#.*$+ contained extend +syn match tt2_func +\<\I\w*\(\s*(\)\@=+ contained nextgroup=tt2_bracket_r skipempty skipwhite +" +syn region tt2_bracket_r start=+(+ end=+)+ contained contains=@tt2_statement_cluster keepend extend +syn region tt2_bracket_b start=+\[+ end=+]+ contained contains=@tt2_statement_cluster keepend extend +syn region tt2_bracket_b start=+{+ end=+}+ contained contains=@tt2_statement_cluster keepend extend + +syn region tt2_string_qq start=+"+ end=+"+ skip=+\\"+ contained contains=tt2_ivariable keepend extend +syn region tt2_string_q start=+'+ end=+'+ skip=+\\'+ contained keepend extend + +syn match tt2_ivariable +\$\I\w*\>\(\.\I\w*\>\)*+ contained +syn match tt2_ivariable +\${\I\w*\>\(\.\I\w*\>\)*}+ contained + +syn match tt2_number "\d\+" contained +syn match tt2_number "\d\+\.\d\+" contained +syn match tt2_number "0x\x\+" contained +syn match tt2_number "0\o\+" contained + +syn match tt2_blockname "\f\+" contained nextgroup=tt2_blockname_joint skipwhite skipempty +syn match tt2_blockname "$\w\+" contained contains=tt2_ivariable nextgroup=tt2_blockname_joint skipwhite skipempty +syn region tt2_blockname start=+"+ end=+"+ skip=+\\"+ contained contains=tt2_ivariable nextgroup=tt2_blockname_joint keepend skipwhite skipempty +syn region tt2_blockname start=+'+ end=+'+ skip=+\\'+ contained nextgroup=tt2_blockname_joint keepend skipwhite skipempty +syn match tt2_blockname_joint "+" contained nextgroup=tt2_blockname skipwhite skipempty + +syn cluster tt2_statement_cluster contains=tt2_directive,tt2_variable,tt2_operator,tt2_string_q,tt2_string_qq,tt2_deref,tt2_comment,tt2_func,tt2_bracket_b,tt2_bracket_r,tt2_number + +" Synchronizing +syn sync minlines=50 + +hi def link tt2_tag Type +hi def link tt2_tag_region Type +hi def link tt2_commentblock_region Comment +hi def link tt2_directive Statement +hi def link tt2_variable Identifier +hi def link tt2_ivariable Identifier +hi def link tt2_operator Statement +hi def link tt2_string_qq String +hi def link tt2_string_q String +hi def link tt2_blockname String +hi def link tt2_comment Comment +hi def link tt2_func Function +hi def link tt2_number Number + +if exists("b:tt2_syn_tags") + unlet b:tt2_syn_tags +endif + +let b:current_syntax = "tt2" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim:ts=4:sw=4 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Language: TT2 (Perl Template Toolkit) diff --git a/syntax/tt2html.vim b/syntax/tt2html.vim index 9d14c66..ff99387 100644 --- a/syntax/tt2html.vim +++ b/syntax/tt2html.vim @@ -1,3 +1,27 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: TT2 embedded with HTML +" Maintainer: vim-perl +" Author: Moriki, Atsushi <4woods+vim@gmail.com> +" Homepage: http://github.com/vim-perl/vim-perl +" Bugs/requests: http://github.com/vim-perl/vim-perl/issues +" Last Change: 2013-07-21 + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/html.vim +unlet b:current_syntax + +runtime! syntax/tt2.vim +unlet b:current_syntax + +syn cluster htmlPreProc add=@tt2_top_cluster + +let b:current_syntax = "tt2html" + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Language: TT2 embedded with HTML diff --git a/syntax/tt2js.vim b/syntax/tt2js.vim index 0608628..35f91a7 100644 --- a/syntax/tt2js.vim +++ b/syntax/tt2js.vim @@ -1,3 +1,27 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Language: TT2 embedded with Javascript +" Maintainer: Andy Lester +" Author: Yates, Peter +" Homepage: http://github.com/vim-perl/vim-perl +" Bugs/requests: http://github.com/vim-perl/vim-perl/issues +" Last Change: 2013-07-21 + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/javascript.vim +unlet b:current_syntax + +runtime! syntax/tt2.vim +unlet b:current_syntax + +syn cluster javascriptPreProc add=@tt2_top_cluster + +let b:current_syntax = "tt2js" + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Language: TT2 embedded with Javascript diff --git a/syntax/uc.vim b/syntax/uc.vim new file mode 100644 index 0000000..2e07c64 --- /dev/null +++ b/syntax/uc.vim @@ -0,0 +1,169 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: UnrealScript +" Maintainer: Mark Ferrell +" URL: ftp://ftp.chaoticdreams.org/pub/ut/vim/uc.vim +" Credits: Based on the java.vim syntax file by Claudio Fleiner +" Last change: 2003 May 31 + +" Please check :help uc.vim for comments on some of the options available. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" some characters that cannot be in a UnrealScript program (outside a string) +syn match ucError "[\\@`]" +syn match ucError "<<<\|\.\.\|=>\|<>\|||=\|&&=\|[^-]->\|\*\/" + +" we define it here so that included files can test for it +if !exists("main_syntax") + let main_syntax='uc' +endif + +syntax case ignore + +" keyword definitions +syn keyword ucBranch break continue +syn keyword ucConditional if else switch +syn keyword ucRepeat while for do foreach +syn keyword ucBoolean true false +syn keyword ucConstant null +syn keyword ucOperator new instanceof +syn keyword ucType boolean char byte short int long float double +syn keyword ucType void Pawn sound state auto exec function ipaddr +syn keyword ucType ELightType actor ammo defaultproperties bool +syn keyword ucType native noexport var out vector name local string +syn keyword ucType event +syn keyword ucStatement return +syn keyword ucStorageClass static synchronized transient volatile final +syn keyword ucMethodDecl synchronized throws + +" UnrealScript defines classes in sorta fscked up fashion +syn match ucClassDecl "^[Cc]lass[\s$]*\S*[\s$]*expands[\s$]*\S*;" contains=ucSpecial,ucSpecialChar,ucClassKeys +syn keyword ucClassKeys class expands extends +syn match ucExternal "^\#exec.*" contains=ucCommentString,ucNumber +syn keyword ucScopeDecl public protected private abstract + +" UnrealScript Functions +syn match ucFuncDef "^.*function\s*[\(]*" contains=ucType,ucStorageClass +syn match ucEventDef "^.*event\s*[\(]*" contains=ucType,ucStorageClass +syn match ucClassLabel "[a-zA-Z0-9]*\'[a-zA-Z0-9]*\'" contains=ucCharacter + +syn region ucLabelRegion transparent matchgroup=ucLabel start="\" matchgroup=NONE end=":" contains=ucNumber +syn match ucUserLabel "^\s*[_$a-zA-Z][_$a-zA-Z0-9_]*\s*:"he=e-1 contains=ucLabel +syn keyword ucLabel default + +" The following cluster contains all java groups except the contained ones +syn cluster ucTop contains=ucExternal,ucError,ucError,ucBranch,ucLabelRegion,ucLabel,ucConditional,ucRepeat,ucBoolean,ucConstant,ucTypedef,ucOperator,ucType,ucType,ucStatement,ucStorageClass,ucMethodDecl,ucClassDecl,ucClassDecl,ucClassDecl,ucScopeDecl,ucError,ucError2,ucUserLabel,ucClassLabel + +" Comments +syn keyword ucTodo contained TODO FIXME XXX +syn region ucCommentString contained start=+"+ end=+"+ end=+\*/+me=s-1,he=s-1 contains=ucSpecial,ucCommentStar,ucSpecialChar +syn region ucComment2String contained start=+"+ end=+$\|"+ contains=ucSpecial,ucSpecialChar +syn match ucCommentCharacter contained "'\\[^']\{1,6\}'" contains=ucSpecialChar +syn match ucCommentCharacter contained "'\\''" contains=ucSpecialChar +syn match ucCommentCharacter contained "'[^\\]'" +syn region ucComment start="/\*" end="\*/" contains=ucCommentString,ucCommentCharacter,ucNumber,ucTodo +syn match ucCommentStar contained "^\s*\*[^/]"me=e-1 +syn match ucCommentStar contained "^\s*\*$" +syn match ucLineComment "//.*" contains=ucComment2String,ucCommentCharacter,ucNumber,ucTodo +hi link ucCommentString ucString +hi link ucComment2String ucString +hi link ucCommentCharacter ucCharacter + +syn cluster ucTop add=ucComment,ucLineComment + +" match the special comment /**/ +syn match ucComment "/\*\*/" + +" Strings and constants +syn match ucSpecialError contained "\\." +"syn match ucSpecialCharError contained "[^']" +syn match ucSpecialChar contained "\\\([4-9]\d\|[0-3]\d\d\|[\"\\'ntbrf]\|u\x\{4\}\)" +syn region ucString start=+"+ end=+"+ contains=ucSpecialChar,ucSpecialError +syn match ucStringError +"\([^"\\]\|\\.\)*$+ +syn match ucCharacter "'[^']*'" contains=ucSpecialChar,ucSpecialCharError +syn match ucCharacter "'\\''" contains=ucSpecialChar +syn match ucCharacter "'[^\\]'" +syn match ucNumber "\<\(0[0-7]*\|0[xX]\x\+\|\d\+\)[lL]\=\>" +syn match ucNumber "\(\<\d\+\.\d*\|\.\d\+\)\([eE][-+]\=\d\+\)\=[fFdD]\=" +syn match ucNumber "\<\d\+[eE][-+]\=\d\+[fFdD]\=\>" +syn match ucNumber "\<\d\+\([eE][-+]\=\d\+\)\=[fFdD]\>" + +" unicode characters +syn match ucSpecial "\\u\d\{4\}" + +syn cluster ucTop add=ucString,ucCharacter,ucNumber,ucSpecial,ucStringError + +" catch errors caused by wrong parenthesis +syn region ucParen transparent start="(" end=")" contains=@ucTop,ucParen +syn match ucParenError ")" +hi link ucParenError ucError + +if !exists("uc_minlines") + let uc_minlines = 10 +endif +exec "syn sync ccomment ucComment minlines=" . uc_minlines + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link ucFuncDef Conditional +hi def link ucEventDef Conditional +hi def link ucBraces Function +hi def link ucBranch Conditional +hi def link ucLabel Label +hi def link ucUserLabel Label +hi def link ucConditional Conditional +hi def link ucRepeat Repeat +hi def link ucStorageClass StorageClass +hi def link ucMethodDecl ucStorageClass +hi def link ucClassDecl ucStorageClass +hi def link ucScopeDecl ucStorageClass +hi def link ucBoolean Boolean +hi def link ucSpecial Special +hi def link ucSpecialError Error +hi def link ucSpecialCharError Error +hi def link ucString String +hi def link ucCharacter Character +hi def link ucSpecialChar SpecialChar +hi def link ucNumber Number +hi def link ucError Error +hi def link ucStringError Error +hi def link ucStatement Statement +hi def link ucOperator Operator +hi def link ucOverLoaded Operator +hi def link ucComment Comment +hi def link ucDocComment Comment +hi def link ucLineComment Comment +hi def link ucConstant ucBoolean +hi def link ucTypedef Typedef +hi def link ucTodo Todo + +hi def link ucCommentTitle SpecialComment +hi def link ucDocTags Special +hi def link ucDocParam Function +hi def link ucCommentStar ucComment + +hi def link ucType Type +hi def link ucExternal Include + +hi def link ucClassKeys Conditional +hi def link ucClassLabel Conditional + +hi def link htmlComment Special +hi def link htmlCommentPart Special + + +let b:current_syntax = "uc" + +if main_syntax == 'uc' + unlet main_syntax +endif + +" vim: ts=8 + +endif diff --git a/syntax/udevconf.vim b/syntax/udevconf.vim new file mode 100644 index 0000000..a7b5e9e --- /dev/null +++ b/syntax/udevconf.vim @@ -0,0 +1,43 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: udev(8) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword udevconfTodo contained TODO FIXME XXX NOTE + +syn region udevconfComment display oneline start='^\s*#' end='$' + \ contains=udevconfTodo,@Spell + +syn match udevconfBegin display '^' + \ nextgroup=udevconfVariable,udevconfComment + \ skipwhite + +syn keyword udevconfVariable contained udev_root udev_db udev_rules udev_log + \ nextgroup=udevconfVariableEq + +syn match udevconfVariableEq contained '[[:space:]=]' + \ nextgroup=udevconfString skipwhite + +syn region udevconfString contained display oneline start=+"+ end=+"+ + +hi def link udevconfTodo Todo +hi def link udevconfComment Comment +hi def link udevconfVariable Identifier +hi def link udevconfVariableEq Operator +hi def link udevconfString String + +let b:current_syntax = "udevconf" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/udevperm.vim b/syntax/udevperm.vim new file mode 100644 index 0000000..25d545b --- /dev/null +++ b/syntax/udevperm.vim @@ -0,0 +1,73 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: udev(8) permissions file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match udevpermBegin display '^' nextgroup=udevpermDevice + +syn match udevpermDevice contained display '[^:]\+' + \ contains=udevpermPattern + \ nextgroup=udevpermUserColon + +syn match udevpermPattern contained '[*?]' +syn region udevpermPattern contained start='\[!\=' end='\]' + \ contains=udevpermPatRange + +syn match udevpermPatRange contained '[^[-]-[^]-]' + +syn match udevpermUserColon contained display ':' + \ nextgroup=udevpermUser + +syn match udevpermUser contained display '[^:]\+' + \ nextgroup=udevpermGroupColon + +syn match udevpermGroupColon contained display ':' + \ nextgroup=udevpermGroup + +syn match udevpermGroup contained display '[^:]\+' + \ nextgroup=udevpermPermColon + +syn match udevpermPermColon contained display ':' + \ nextgroup=udevpermPerm + +syn match udevpermPerm contained display '\<0\=\o\+\>' + \ contains=udevpermOctalZero + +syn match udevpermOctalZero contained display '\<0' +syn match udevpermOctalError contained display '\<0\o*[89]\d*\>' + +syn keyword udevpermTodo contained TODO FIXME XXX NOTE + +syn region udevpermComment display oneline start='^\s*#' end='$' + \ contains=udevpermTodo,@Spell + +hi def link udevpermTodo Todo +hi def link udevpermComment Comment +hi def link udevpermDevice String +hi def link udevpermPattern SpecialChar +hi def link udevpermPatRange udevpermPattern +hi def link udevpermColon Normal +hi def link udevpermUserColon udevpermColon +hi def link udevpermUser Identifier +hi def link udevpermGroupColon udevpermColon +hi def link udevpermGroup Type +hi def link udevpermPermColon udevpermColon +hi def link udevpermPerm Number +hi def link udevpermOctalZero PreProc +hi def link udevpermOctalError Error + +let b:current_syntax = "udevperm" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/udevrules.vim b/syntax/udevrules.vim new file mode 100644 index 0000000..e8df94c --- /dev/null +++ b/syntax/udevrules.vim @@ -0,0 +1,175 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: udev(8) rules file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-12-18 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" TODO: Line continuations. + +syn keyword udevrulesTodo contained TODO FIXME XXX NOTE + +syn region udevrulesComment display oneline start='^\s*#' end='$' + \ contains=udevrulesTodo,@Spell + +syn keyword udevrulesRuleKey ACTION DEVPATH KERNEL SUBSYSTEM KERNELS + \ SUBSYSTEMS DRIVERS RESULT + \ nextgroup=udevrulesRuleTest + \ skipwhite + +syn keyword udevrulesRuleKey ATTRS nextgroup=udevrulesAttrsPath + +syn region udevrulesAttrsPath display transparent + \ matchgroup=udevrulesDelimiter start='{' + \ matchgroup=udevrulesDelimiter end='}' + \ contains=udevrulesPath + \ nextgroup=udevrulesRuleTest + \ skipwhite + +syn keyword udevrulesRuleKey ENV nextgroup=udevrulesEnvVar + +syn region udevrulesEnvVar display transparent + \ matchgroup=udevrulesDelimiter start='{' + \ matchgroup=udevrulesDelimiter end='}' + \ contains=udevrulesVariable + \ nextgroup=udevrulesRuleTest,udevrulesRuleEq + \ skipwhite + +syn keyword udevrulesRuleKey PROGRAM RESULT + \ nextgroup=udevrulesEStringTest,udevrulesEStringEq + \ skipwhite + +syn keyword udevrulesAssignKey NAME SYMLINK OWNER GROUP RUN + \ nextgroup=udevrulesEStringEq + \ skipwhite + +syn keyword udevrulesAssignKey MODE LABEL GOTO WAIT_FOR_SYSFS + \ nextgroup=udevrulesRuleEq + \ skipwhite + +syn keyword udevrulesAssignKey ATTR nextgroup=udevrulesAttrsPath + +syn region udevrulesAttrKey display transparent + \ matchgroup=udevrulesDelimiter start='{' + \ matchgroup=udevrulesDelimiter end='}' + \ contains=udevrulesKey + \ nextgroup=udevrulesRuleEq + \ skipwhite + +syn keyword udevrulesAssignKey IMPORT nextgroup=udevrulesImport, + \ udevrulesEStringEq + \ skipwhite + +syn region udevrulesImport display transparent + \ matchgroup=udevrulesDelimiter start='{' + \ matchgroup=udevrulesDelimiter end='}' + \ contains=udevrulesImportType + \ nextgroup=udevrulesEStringEq + \ skipwhite + +syn keyword udevrulesImportType program file parent + +syn keyword udevrulesAssignKey OPTIONS + \ nextgroup=udevrulesOptionsEq + +syn match udevrulesPath contained display '[^}]\+' + +syn match udevrulesVariable contained display '[^}]\+' + +syn match udevrulesRuleTest contained display '[=!:]=' + \ nextgroup=udevrulesString skipwhite + +syn match udevrulesEStringTest contained display '[=!+:]=' + \ nextgroup=udevrulesEString skipwhite + +syn match udevrulesRuleEq contained display '+=\|=\ze[^=]' + \ nextgroup=udevrulesString skipwhite + +syn match udevrulesEStringEq contained '+=\|=\ze[^=]' + \ nextgroup=udevrulesEString skipwhite + +syn match udevrulesOptionsEq contained '+=\|=\ze[^=]' + \ nextgroup=udevrulesOptions skipwhite + +syn region udevrulesEString contained display oneline start=+"+ end=+"+ + \ contains=udevrulesStrEscapes,udevrulesStrVars + +syn match udevrulesStrEscapes contained '%[knpbMmcPrN%]' + +" TODO: This can actually stand alone (without {…}), so add a nextgroup here. +syn region udevrulesStrEscapes contained start='%c{' end='}' + \ contains=udevrulesStrNumber + +syn region udevrulesStrEscapes contained start='%s{' end='}' + \ contains=udevrulesPath + +syn region udevrulesStrEscapes contained start='%E{' end='}' + \ contains=udevrulesVariable + +syn match udevrulesStrNumber contained '\d\++\=' + +syn match udevrulesStrVars contained display '$\%(kernel\|number\|devpath\|id\|major\|minor\|result\|parent\|root\|tempnode\)\>' + +syn region udevrulesStrVars contained start='$attr{' end='}' + \ contains=udevrulesPath + +syn region udevrulesStrVars contained start='$env{' end='}' + \ contains=udevrulesVariable + +syn match udevrulesStrVars contained display '\$\$' + +syn region udevrulesString contained display oneline start=+"+ end=+"+ + \ contains=udevrulesPattern + +syn match udevrulesPattern contained '[*?]' +syn region udevrulesPattern contained start='\[!\=' end='\]' + \ contains=udevrulesPatRange + +syn match udevrulesPatRange contained '[^[-]-[^]-]' + +syn region udevrulesOptions contained display oneline start=+"+ end=+"+ + \ contains=udevrulesOption,udevrulesOptionSep + +syn keyword udevrulesOption contained last_rule ignore_device ignore_remove + \ all_partitions + +syn match udevrulesOptionSep contained ',' + +hi def link udevrulesTodo Todo +hi def link udevrulesComment Comment +hi def link udevrulesRuleKey Keyword +hi def link udevrulesDelimiter Delimiter +hi def link udevrulesAssignKey Identifier +hi def link udevrulesPath Identifier +hi def link udevrulesVariable Identifier +hi def link udevrulesAttrKey Identifier +" XXX: setting this to Operator makes for extremely intense highlighting. +hi def link udevrulesEq Normal +hi def link udevrulesRuleEq udevrulesEq +hi def link udevrulesEStringEq udevrulesEq +hi def link udevrulesOptionsEq udevrulesEq +hi def link udevrulesEString udevrulesString +hi def link udevrulesStrEscapes SpecialChar +hi def link udevrulesStrNumber Number +hi def link udevrulesStrVars Identifier +hi def link udevrulesString String +hi def link udevrulesPattern SpecialChar +hi def link udevrulesPatRange SpecialChar +hi def link udevrulesOptions udevrulesString +hi def link udevrulesOption Type +hi def link udevrulesOptionSep Delimiter +hi def link udevrulesImportType Type + +let b:current_syntax = "udevrules" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/uil.vim b/syntax/uil.vim new file mode 100644 index 0000000..d5d3215 --- /dev/null +++ b/syntax/uil.vim @@ -0,0 +1,79 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Motif UIL (User Interface Language) +" Maintainer: Thomas Koehler +" Please be aware: I'm often slow to answer email due to a high +" non-computer related workload (sometimes 4-8 weeks) +" Last Change: 2016 September 6 +" URL: http://gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/vim/syntax/uil.vim + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful keywords +syn keyword uilType arguments callbacks color +syn keyword uilType compound_string controls end +syn keyword uilType exported file include +syn keyword uilType module object procedure +syn keyword uilType user_defined xbitmapfile + +syn keyword uilTodo contained TODO + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match uilSpecial contained "\\\d\d\d\|\\." +syn region uilString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@Spell,uilSpecial +syn match uilCharacter "'[^\\]'" +syn region uilString start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@Spell,uilSpecial +syn match uilSpecialCharacter "'\\.'" +syn match uilSpecialStatement "Xm[^ =(){}:;]*" +syn match uilSpecialFunction "MrmNcreateCallback" +syn match uilRessource "XmN[^ =(){}:;]*" + +syn match uilNumber "-\=\<\d*\.\=\d\+\(e\=f\=\|[uU]\=[lL]\=\)\>" +syn match uilNumber "0[xX]\x\+\>" + +syn region uilComment start="/\*" end="\*/" contains=@Spell,uilTodo +syn match uilComment "!.*" contains=@Spell,uilTodo +syn match uilCommentError "\*/" + +syn region uilPreCondit start="^#\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=uilComment,uilString,uilCharacter,uilNumber,uilCommentError +syn match uilIncluded contained "<[^>]*>" +syn match uilInclude "^#\s*include\s\+." contains=uilString,uilIncluded +syn match uilLineSkip "\\$" +syn region uilDefine start="^#\s*\(define\>\|undef\>\)" end="$" contains=uilLineSkip,uilComment,uilString,uilCharacter,uilNumber,uilCommentError + +syn sync ccomment uilComment + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default highlighting. +hi def link uilCharacter uilString +hi def link uilSpecialCharacter uilSpecial +hi def link uilNumber uilString +hi def link uilCommentError uilError +hi def link uilInclude uilPreCondit +hi def link uilDefine uilPreCondit +hi def link uilIncluded uilString +hi def link uilSpecialFunction uilRessource +hi def link uilRessource Identifier +hi def link uilSpecialStatement Keyword +hi def link uilError Error +hi def link uilPreCondit PreCondit +hi def link uilType Type +hi def link uilString String +hi def link uilComment Comment +hi def link uilSpecial Special +hi def link uilTodo Todo + + + +let b:current_syntax = "uil" + +" vim: ts=8 + +endif diff --git a/syntax/updatedb.vim b/syntax/updatedb.vim new file mode 100644 index 0000000..86a8c15 --- /dev/null +++ b/syntax/updatedb.vim @@ -0,0 +1,45 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: updatedb.conf(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2009-05-25 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword updatedbTodo contained TODO FIXME XXX NOTE + +syn region updatedbComment display oneline start='^\s*#' end='$' + \ contains=updatedbTodo,@Spell + +syn match updatedbBegin display '^' + \ nextgroup=updatedbName,updatedbComment skipwhite + +syn keyword updatedbName contained + \ PRUNEFS + \ PRUNENAMES + \ PRUNEPATHS + \ PRUNE_BIND_MOUNTS + \ nextgroup=updatedbNameEq + +syn match updatedbNameEq contained display '=' nextgroup=updatedbValue + +syn region updatedbValue contained display oneline start='"' end='"' + +hi def link updatedbTodo Todo +hi def link updatedbComment Comment +hi def link updatedbName Identifier +hi def link updatedbNameEq Operator +hi def link updatedbValue String + +let b:current_syntax = "updatedb" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/upstart.vim b/syntax/upstart.vim new file mode 100644 index 0000000..7fe409d --- /dev/null +++ b/syntax/upstart.vim @@ -0,0 +1,115 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Upstart job files +" Maintainer: Michael Biebl +" James Hunt +" Last Change: 2012 Jan 16 +" License: The Vim license +" Version: 0.4 +" Remark: Syntax highlighting for Upstart (init(8)) job files. +" +" It is inspired by the initng syntax file and includes sh.vim to do the +" highlighting of script blocks. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let is_bash = 1 +syn include @Shell syntax/sh.vim + +syn case match + +" avoid need to use 'match' for most events +setlocal iskeyword+=- + +syn match upstartComment /#.*$/ contains=upstartTodo +syn keyword upstartTodo TODO FIXME contained + +syn region upstartString start=/"/ end=/"/ skip=/\\"/ + +syn region upstartScript matchgroup=upstartStatement start="script" end="end script" contains=@upstartShellCluster + +syn cluster upstartShellCluster contains=@Shell + +" one argument +syn keyword upstartStatement description author version instance expect +syn keyword upstartStatement pid kill normal console env exit export +syn keyword upstartStatement umask nice oom chroot chdir exec + +" two arguments +syn keyword upstartStatement limit + +" one or more arguments (events) +syn keyword upstartStatement emits + +syn keyword upstartStatement on start stop + +" flag, no parameter +syn keyword upstartStatement respawn service instance manual debug task + +" prefix for exec or script +syn keyword upstartOption pre-start post-start pre-stop post-stop + +" option for kill +syn keyword upstartOption timeout +" option for oom +syn keyword upstartOption never +" options for console +syn keyword upstartOption output owner +" options for expect +syn keyword upstartOption fork daemon +" options for limit +syn keyword upstartOption unlimited + +" 'options' for start/stop on +syn keyword upstartOption and or + +" Upstart itself and associated utilities +syn keyword upstartEvent runlevel +syn keyword upstartEvent started +syn keyword upstartEvent starting +syn keyword upstartEvent startup +syn keyword upstartEvent stopped +syn keyword upstartEvent stopping +syn keyword upstartEvent control-alt-delete +syn keyword upstartEvent keyboard-request +syn keyword upstartEvent power-status-changed + +" D-Bus +syn keyword upstartEvent dbus-activation + +" Display Manager (ie gdm) +syn keyword upstartEvent desktop-session-start +syn keyword upstartEvent login-session-start + +" mountall +syn keyword upstartEvent all-swaps +syn keyword upstartEvent filesystem +syn keyword upstartEvent mounted +syn keyword upstartEvent mounting +syn keyword upstartEvent local-filesystems +syn keyword upstartEvent remote-filesystems +syn keyword upstartEvent virtual-filesystems + +" SysV umountnfs.sh +syn keyword upstartEvent mounted-remote-filesystems + +" upstart-udev-bridge and ifup/down +syn match upstartEvent /\<\i\{-1,}-device-\(added\|removed\|up\|down\)/ + +" upstart-socket-bridge +syn keyword upstartEvent socket + +hi def link upstartComment Comment +hi def link upstartTodo Todo +hi def link upstartString String +hi def link upstartStatement Statement +hi def link upstartOption Type +hi def link upstartEvent Define + +let b:current_syntax = "upstart" + +endif diff --git a/syntax/upstreamdat.vim b/syntax/upstreamdat.vim new file mode 100644 index 0000000..67f4eca --- /dev/null +++ b/syntax/upstreamdat.vim @@ -0,0 +1,309 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Innovation Data Processing upstream.dat file +" Maintainer: Rob Owens +" Latest Revision: 2013-11-27 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Parameters: +syn keyword upstreamdat_Parameter ACCEPTPCREMOTE +syn keyword upstreamdat_Parameter ACCEPTREMOTE +syn keyword upstreamdat_Parameter ACTION +syn keyword upstreamdat_Parameter ACTIVATEONENTRY +syn keyword upstreamdat_Parameter ARCHIVEBIT +syn keyword upstreamdat_Parameter ARCHIVEBIT +syn keyword upstreamdat_Parameter ASCTOEBC +syn keyword upstreamdat_Parameter ASRBACKUP +syn keyword upstreamdat_Parameter ATTENDED +syn keyword upstreamdat_Parameter AUTHORITATIVE +syn keyword upstreamdat_Parameter AUTHORITATIVERESTORE +syn keyword upstreamdat_Parameter AUTHORITATIVERESTORE +syn keyword upstreamdat_Parameter BACKUPPROFILE +syn keyword upstreamdat_Parameter BACKUPPROFILE2 +syn keyword upstreamdat_Parameter BACKUPREPARSEFILES +syn keyword upstreamdat_Parameter BACKUPREPARSEFILES +syn keyword upstreamdat_Parameter BACKUPVERIFY +syn keyword upstreamdat_Parameter BLANKTRUNC +syn keyword upstreamdat_Parameter CALCDASDSIZE +syn keyword upstreamdat_Parameter CHANGEDIRATTRIBS +syn keyword upstreamdat_Parameter CHANGEDIRATTRIBS +syn keyword upstreamdat_Parameter COMPRESSLEVEL +syn keyword upstreamdat_Parameter CONTROLFILE +syn keyword upstreamdat_Parameter DASDOVERRIDE +syn keyword upstreamdat_Parameter DATELIMIT +syn keyword upstreamdat_Parameter DATELIMIT +syn keyword upstreamdat_Parameter DAYSOLD +syn keyword upstreamdat_Parameter DAYSOLD +syn keyword upstreamdat_Parameter DELETED +syn keyword upstreamdat_Parameter DELETED +syn keyword upstreamdat_Parameter DELETEPROMPTS +syn keyword upstreamdat_Parameter DELETEPROMPTS +syn keyword upstreamdat_Parameter DESTINATION +syn keyword upstreamdat_Parameter DESTINATION +syn keyword upstreamdat_Parameter DIRDELETE +syn keyword upstreamdat_Parameter DIRECTORVMC +syn keyword upstreamdat_Parameter DIRONLYRESTOREOK +syn keyword upstreamdat_Parameter DIRSONLY +syn keyword upstreamdat_Parameter DIRSONLY +syn keyword upstreamdat_Parameter DISASTERRECOVERY +syn keyword upstreamdat_Parameter DISPLAY +syn keyword upstreamdat_Parameter DRIVEALIAS +syn keyword upstreamdat_Parameter DRIVEALIAS +syn keyword upstreamdat_Parameter DUALCOPY +syn keyword upstreamdat_Parameter DUPDAYS +syn keyword upstreamdat_Parameter DUPLICATE +syn keyword upstreamdat_Parameter EBCTOASC +syn keyword upstreamdat_Parameter ENCRYPT +syn keyword upstreamdat_Parameter ENCRYPTLEVEL +syn keyword upstreamdat_Parameter EXCLUDELISTNAME +syn keyword upstreamdat_Parameter FAILBACKUPONERROR +syn keyword upstreamdat_Parameter FAILBACKUPONERROR +syn keyword upstreamdat_Parameter FAILIFNOFILES +syn keyword upstreamdat_Parameter FAILIFNOFILES +syn keyword upstreamdat_Parameter FAILIFSKIP +syn keyword upstreamdat_Parameter FAILJOB +syn keyword upstreamdat_Parameter FAILRESTOREONERROR +syn keyword upstreamdat_Parameter FAILRESTOREONERROR +syn keyword upstreamdat_Parameter FILEDATE +syn keyword upstreamdat_Parameter FILEDATE +syn keyword upstreamdat_Parameter FILEDELETE +syn keyword upstreamdat_Parameter FILEDELETE +syn keyword upstreamdat_Parameter FILES +syn keyword upstreamdat_Parameter FILES +syn keyword upstreamdat_Parameter FILESOPENFORUPDAT +syn keyword upstreamdat_Parameter FILESOPENFORUPDAT +syn keyword upstreamdat_Parameter FILETRANSFER +syn keyword upstreamdat_Parameter GETREMOTEFILES +syn keyword upstreamdat_Parameter HARDLINKDB +syn keyword upstreamdat_Parameter HARDLINKS +syn keyword upstreamdat_Parameter HARDLINKS +syn keyword upstreamdat_Parameter HIDDENFILES +syn keyword upstreamdat_Parameter HIDDENFILES +syn keyword upstreamdat_Parameter HOLDTAPE +syn keyword upstreamdat_Parameter HOLDUSERDIRS +syn keyword upstreamdat_Parameter HOSTFILENAME +syn keyword upstreamdat_Parameter HOSTRECORD +syn keyword upstreamdat_Parameter HOSTSORT +syn keyword upstreamdat_Parameter IGNOREPLUGINSFORRESTORE +syn keyword upstreamdat_Parameter INCRDB +syn keyword upstreamdat_Parameter INCRDBARCHIVEBIT +syn keyword upstreamdat_Parameter INCRDBDELETEDFILES +syn keyword upstreamdat_Parameter INCREMENTAL +syn keyword upstreamdat_Parameter INCREMENTAL +syn keyword upstreamdat_Parameter INQOPTIONS +syn keyword upstreamdat_Parameter INSTALLWIN2KAGENT +syn keyword upstreamdat_Parameter INSTALLWIN2KAGENT +syn keyword upstreamdat_Parameter JOBOPTIONS +syn keyword upstreamdat_Parameter JOBRETURNCODEMAP +syn keyword upstreamdat_Parameter JOBWAITTIMELIMIT +syn keyword upstreamdat_Parameter KEEPALIVE +syn keyword upstreamdat_Parameter LANINTERFACE +syn keyword upstreamdat_Parameter LANWSNAME +syn keyword upstreamdat_Parameter LANWSPASSWORD +syn keyword upstreamdat_Parameter LASTACCESS +syn keyword upstreamdat_Parameter LASTACCESS +syn keyword upstreamdat_Parameter LATESTDATE +syn keyword upstreamdat_Parameter LATESTDATE +syn keyword upstreamdat_Parameter LATESTTIME +syn keyword upstreamdat_Parameter LATESTTIME +syn keyword upstreamdat_Parameter LATESTVERSION +syn keyword upstreamdat_Parameter LINEBLOCK +syn keyword upstreamdat_Parameter LINETRUNC +syn keyword upstreamdat_Parameter LISTENFORREMOTE +syn keyword upstreamdat_Parameter LOCALBACKUP +syn keyword upstreamdat_Parameter LOCALBACKUPDIR +syn keyword upstreamdat_Parameter LOCALBACKUPMAX +syn keyword upstreamdat_Parameter LOCALBACKUPMAXFILESIZE +syn keyword upstreamdat_Parameter LOCALBACKUPMAXSIZE +syn keyword upstreamdat_Parameter LOCALEXCLUDEFILE +syn keyword upstreamdat_Parameter LOCALPARAMETERS +syn keyword upstreamdat_Parameter LOCALPASSWORD +syn keyword upstreamdat_Parameter LOCALRESTORE +syn keyword upstreamdat_Parameter LOCALUSER +syn keyword upstreamdat_Parameter LOFS +syn keyword upstreamdat_Parameter LOGNONFATAL +syn keyword upstreamdat_Parameter MAXBACKUPFILESFAIL +syn keyword upstreamdat_Parameter MAXBACKUPTIME +syn keyword upstreamdat_Parameter MAXDUPS +syn keyword upstreamdat_Parameter MAXFILENAMESIZE +syn keyword upstreamdat_Parameter MAXKFILESIZE +syn keyword upstreamdat_Parameter MAXLOGDAYS +syn keyword upstreamdat_Parameter MAXRESTOREFILESFAIL +syn keyword upstreamdat_Parameter MAXRESTORETIME +syn keyword upstreamdat_Parameter MAXRETRY +syn keyword upstreamdat_Parameter MAXRPTDAYS +syn keyword upstreamdat_Parameter MERGE +syn keyword upstreamdat_Parameter MIGRBITS +syn keyword upstreamdat_Parameter MIGRBITS +syn keyword upstreamdat_Parameter MINCOMPRESSSIZE +syn keyword upstreamdat_Parameter MINIMIZE +syn keyword upstreamdat_Parameter MODIFYFILE +syn keyword upstreamdat_Parameter MOUNTPOINTS +syn keyword upstreamdat_Parameter MOUNTPOINTS +syn keyword upstreamdat_Parameter NDS +syn keyword upstreamdat_Parameter NDS +syn keyword upstreamdat_Parameter NEWFILECOMPARE +syn keyword upstreamdat_Parameter NFSBELOW +syn keyword upstreamdat_Parameter NODATAOK +syn keyword upstreamdat_Parameter NODIRFORINCREMENTAL +syn keyword upstreamdat_Parameter NODIRFORINCREMENTAL +syn keyword upstreamdat_Parameter NONFILEDATABITMAP +syn keyword upstreamdat_Parameter NONFILEDATABITMAP +syn keyword upstreamdat_Parameter NOPOINTRESTORE +syn keyword upstreamdat_Parameter NOSPECINHERITANCE +syn keyword upstreamdat_Parameter NOTIFYEVENTS +syn keyword upstreamdat_Parameter NOTIFYFAILUREATTACHMENT +syn keyword upstreamdat_Parameter NOTIFYSUCCESSATTACHMENT +syn keyword upstreamdat_Parameter NOTIFYTARGETS +syn keyword upstreamdat_Parameter NOUIDGIDNAMES +syn keyword upstreamdat_Parameter NOUIDGIDNAMES +syn keyword upstreamdat_Parameter NOVELLMIGRATE +syn keyword upstreamdat_Parameter NOVELLMIGRATE +syn keyword upstreamdat_Parameter NOVELLMIGRATEADDEXT +syn keyword upstreamdat_Parameter NOVELLMIGRATEADDEXT +syn keyword upstreamdat_Parameter NOVELLPROFILE +syn keyword upstreamdat_Parameter NOVELLRECALL +syn keyword upstreamdat_Parameter NTFSADDPERMISSION +syn keyword upstreamdat_Parameter NTFSADDPERMISSION +syn keyword upstreamdat_Parameter NTREGRESTORE +syn keyword upstreamdat_Parameter OSTYPE +syn keyword upstreamdat_Parameter OUTPORT +syn keyword upstreamdat_Parameter PACKFLUSHAFTERFILE +syn keyword upstreamdat_Parameter PACKRECSIZE +syn keyword upstreamdat_Parameter PARAMETER +syn keyword upstreamdat_Parameter PASSWORD +syn keyword upstreamdat_Parameter PATHNAME +syn keyword upstreamdat_Parameter PATHNAME +syn keyword upstreamdat_Parameter PERFORMBITMAP +syn keyword upstreamdat_Parameter PERFORMNUMRECORDS +syn keyword upstreamdat_Parameter PERFORMRECORDSIZE +syn keyword upstreamdat_Parameter PLUGIN +syn keyword upstreamdat_Parameter PLUGIN +syn keyword upstreamdat_Parameter PLUGINPARAMETERS +syn keyword upstreamdat_Parameter PLUGINPARAMETERS +syn keyword upstreamdat_Parameter POSTJOB +syn keyword upstreamdat_Parameter PREJOB +syn keyword upstreamdat_Parameter PRTYCLASS +syn keyword upstreamdat_Parameter PRTYLEVEL +syn keyword upstreamdat_Parameter RECALLCLEANUP +syn keyword upstreamdat_Parameter RECALLOFFLINEFILES +syn keyword upstreamdat_Parameter RECALLOFFLINEFILES +syn keyword upstreamdat_Parameter RECORDSIZE +syn keyword upstreamdat_Parameter REMOTEADDR +syn keyword upstreamdat_Parameter REMOTEAPPLPREF +syn keyword upstreamdat_Parameter REMOTEAPPLRETRY +syn keyword upstreamdat_Parameter REMOTECONNECTTYPE +syn keyword upstreamdat_Parameter REMOTEFLAGS +syn keyword upstreamdat_Parameter REMOTEIPADAPTER +syn keyword upstreamdat_Parameter REMOTELOCALPARAMETERS +syn keyword upstreamdat_Parameter REMOTELOGMODE +syn keyword upstreamdat_Parameter REMOTELUNAME +syn keyword upstreamdat_Parameter REMOTEMAXRETRIES +syn keyword upstreamdat_Parameter REMOTEMODENAME +syn keyword upstreamdat_Parameter REMOTEPARAMETERFILE +syn keyword upstreamdat_Parameter REMOTEPORT +syn keyword upstreamdat_Parameter REMOTEREQUEST +syn keyword upstreamdat_Parameter REMOTERESTART +syn keyword upstreamdat_Parameter REMOTEROUTE +syn keyword upstreamdat_Parameter REMOTETARGETNAME +syn keyword upstreamdat_Parameter REMOTETCP +syn keyword upstreamdat_Parameter REMOTETIMEOUT +syn keyword upstreamdat_Parameter REMOTETMAXRETRY +syn keyword upstreamdat_Parameter REMOTETPN +syn keyword upstreamdat_Parameter REMOTEUSAPPL +syn keyword upstreamdat_Parameter REMOTEVERIFY +syn keyword upstreamdat_Parameter REMOTEWTOCOMP +syn keyword upstreamdat_Parameter REPORTNAME +syn keyword upstreamdat_Parameter REPORTOPTIONS +syn keyword upstreamdat_Parameter RESTARTLASTFILE +syn keyword upstreamdat_Parameter RESTART +syn keyword upstreamdat_Parameter RESTARTTYPE +syn keyword upstreamdat_Parameter RESTARTVERSIONDATE +syn keyword upstreamdat_Parameter RESTOREARCHIVEBIT +syn keyword upstreamdat_Parameter RESTORECHECKPOINT +syn keyword upstreamdat_Parameter RESTOREDATELIMIT +syn keyword upstreamdat_Parameter RESTOREDATELIMIT +syn keyword upstreamdat_Parameter RESTOREFILEFAIL +syn keyword upstreamdat_Parameter RESTOREMOUNTPOINTS +syn keyword upstreamdat_Parameter RESTOREMOUNTPOINTS +syn keyword upstreamdat_Parameter RESTORESEGMENTS +syn keyword upstreamdat_Parameter RESTORESEGMENTS +syn keyword upstreamdat_Parameter RESTORETODIFFFS +syn keyword upstreamdat_Parameter RETAIN +syn keyword upstreamdat_Parameter RETAIN +syn keyword upstreamdat_Parameter ROOTENTRY +syn keyword upstreamdat_Parameter ROOTENTRY +syn keyword upstreamdat_Parameter SAN +syn keyword upstreamdat_Parameter SCHEDULENAME +syn keyword upstreamdat_Parameter SEGMENTEDFILESIZE +syn keyword upstreamdat_Parameter SEGMENTEDFILESIZE +syn keyword upstreamdat_Parameter SEGMENTSIZE +syn keyword upstreamdat_Parameter SEGMENTSIZE +syn keyword upstreamdat_Parameter SENDHOSTDETAILS +syn keyword upstreamdat_Parameter SINGLEFS +syn keyword upstreamdat_Parameter SIZETRC +syn keyword upstreamdat_Parameter SKIP +syn keyword upstreamdat_Parameter SKIPBACKUPSCAN +syn keyword upstreamdat_Parameter SKIPOLD +syn keyword upstreamdat_Parameter SKIPOLD +syn keyword upstreamdat_Parameter SMSTARGETSERVICENAME +syn keyword upstreamdat_Parameter SMSTSA +syn keyword upstreamdat_Parameter SOLO +syn keyword upstreamdat_Parameter SORTBACKUP +syn keyword upstreamdat_Parameter SOSDISK +syn keyword upstreamdat_Parameter SOSDISK +syn keyword upstreamdat_Parameter SOSTIMESTAMP +syn keyword upstreamdat_Parameter SOSTIMESTAMP +syn keyword upstreamdat_Parameter SOSTIMESTAMPPATH +syn keyword upstreamdat_Parameter SOSTIMESTAMPPATH +syn keyword upstreamdat_Parameter SPECNUMBER +syn keyword upstreamdat_Parameter SPECNUMBER +syn keyword upstreamdat_Parameter SPECTYPE +syn keyword upstreamdat_Parameter SPECTYPE +syn keyword upstreamdat_Parameter STARTTIME +syn keyword upstreamdat_Parameter STORAGETYPE +syn keyword upstreamdat_Parameter SUBDIRECTORIES +syn keyword upstreamdat_Parameter SUBDIRECTORIES +syn keyword upstreamdat_Parameter SWITCHTOTAPEMB +syn keyword upstreamdat_Parameter TCPADDRESS +syn keyword upstreamdat_Parameter TCPTIMEOUT +syn keyword upstreamdat_Parameter TIMEOVERRIDE +syn keyword upstreamdat_Parameter TRACE +syn keyword upstreamdat_Parameter TRANSLATE +syn keyword upstreamdat_Parameter ULTRACOMP +syn keyword upstreamdat_Parameter ULTREG +syn keyword upstreamdat_Parameter ULTUPD +syn keyword upstreamdat_Parameter UNCMACHINEALIAS +syn keyword upstreamdat_Parameter UNCMACHINEALIAS +syn keyword upstreamdat_Parameter USEALEBRA +syn keyword upstreamdat_Parameter USECONTROLFILE +syn keyword upstreamdat_Parameter USEGID +syn keyword upstreamdat_Parameter USERID +syn keyword upstreamdat_Parameter USEUID +syn keyword upstreamdat_Parameter USNOUIDGIDERRORS +syn keyword upstreamdat_Parameter UTF8 +syn keyword upstreamdat_Parameter VAULTNUMBER +syn keyword upstreamdat_Parameter VERSIONDATE +syn keyword upstreamdat_Parameter WRITESPARSE +syn keyword upstreamdat_Parameter XFERECORDSIZE +syn keyword upstreamdat_Parameter XFERRECSEP +syn keyword upstreamdat_Parameter XFERRECUSECR + +" File Specs: +syn match upstreamdat_Filespec /file spec\c \d\{1,3}.*/ + +" Comments: +syn match upstreamdat_Comment /^#.*/ + +hi def link upstreamdat_Parameter Type +"hi def link upstreamdat_Filespec Underlined +hi def link upstreamdat_Comment Comment + +let b:current_syntax = "upstreamdat" + +endif diff --git a/syntax/upstreaminstalllog.vim b/syntax/upstreaminstalllog.vim new file mode 100644 index 0000000..a808fe7 --- /dev/null +++ b/syntax/upstreaminstalllog.vim @@ -0,0 +1,31 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Innovation Data Processing UPSTREAMInstall.log file +" Maintainer: Rob Owens +" Latest Revision: 2013-06-17 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Date: +syn match upstreaminstalllog_Date /\u\l\l \u\l\l\s\{1,2}\d\{1,2} \d\d:\d\d:\d\d \d\d\d\d/ +" Msg Types: +syn match upstreaminstalllog_MsgD /Msg #MSI\d\{4,5}D/ +syn match upstreaminstalllog_MsgE /Msg #MSI\d\{4,5}E/ +syn match upstreaminstalllog_MsgI /Msg #MSI\d\{4,5}I/ +syn match upstreaminstalllog_MsgW /Msg #MSI\d\{4,5}W/ +" IP Address: +syn match upstreaminstalllog_IPaddr / \d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}/ + +hi def link upstreaminstalllog_Date Underlined +hi def link upstreaminstalllog_MsgD Type +hi def link upstreaminstalllog_MsgE Error +hi def link upstreaminstalllog_MsgW Constant +hi def link upstreaminstalllog_IPaddr Identifier + +let b:current_syntax = "upstreaminstalllog" + +endif diff --git a/syntax/upstreamlog.vim b/syntax/upstreamlog.vim new file mode 100644 index 0000000..a8d2f2c --- /dev/null +++ b/syntax/upstreamlog.vim @@ -0,0 +1,58 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Innovation Data Processing upstream.log file +" Maintainer: Rob Owens +" Latest Revision: 2013-09-19 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Date: +syn match upstreamlog_Date /\u\l\l \u\l\l\s\{1,2}\d\{1,2} \d\d:\d\d:\d\d \d\d\d\d/ +" Msg Types: +syn match upstreamlog_MsgD /Msg #\(Agt\|PC\|Srv\)\d\{4,5}D/ nextgroup=upstreamlog_Process skipwhite +syn match upstreamlog_MsgE /Msg #\(Agt\|PC\|Srv\)\d\{4,5}E/ nextgroup=upstreamlog_Process skipwhite +syn match upstreamlog_MsgI /Msg #\(Agt\|PC\|Srv\)\d\{4,5}I/ nextgroup=upstreamlog_Process skipwhite +syn match upstreamlog_MsgW /Msg #\(Agt\|PC\|Srv\)\d\{4,5}W/ nextgroup=upstreamlog_Process skipwhite +" Processes: +syn region upstreamlog_Process start="(" end=")" contained +" IP Address: +syn match upstreamlog_IPaddr /\( \|(\)\zs\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}/ +" Profile: +syn match upstreamlog_Profile /Using default configuration for profile \zs\S\{1,8}\ze/ +syn match upstreamlog_Profile /Now running profile \zs\S\{1,8}\ze/ +syn match upstreamlog_Profile /in profile set \zs\S\{1,8}\ze/ +syn match upstreamlog_Profile /Migrate disk backup from profile \zs\S\{1,8}\ze/ +syn match upstreamlog_Profile /Profileset=\zs\S\{1,8}\ze,/ +syn match upstreamlog_Profile /Vault \(disk\|tape\) backup to vault \d\{1,4} from profile \zs\S\{1,8}\ze/ +syn match upstreamlog_Profile /Profile name \zs\"\S\{1,8}\"/ +syn match upstreamlog_Profile / Profile: \zs\S\{1,8}/ +syn match upstreamlog_Profile / Profile: \zs\S\{1,8}\ze, / +syn match upstreamlog_Profile /, profile: \zs\S\{1,8}\ze,/ +syn match upstreamlog_Profile /found Profile: \zs\S\{1,8}\ze,/ +syn match upstreamlog_Profile /Backup Profile: \zs\S\{1,8}\ze Version date/ +syn match upstreamlog_Profile /Backup profile: \zs\S\{1,8}\ze Version date/ +syn match upstreamlog_Profile /Full of \zs\S\{1,8}\ze$/ +syn match upstreamlog_Profile /Incr. of \zs\S\{1,8}\ze$/ +syn match upstreamlog_Profile /Profile=\zs\S\{1,8}\ze,/ +" Target: +syn region upstreamlog_Target start="Computer: \zs" end="\ze[\]\)]" +syn region upstreamlog_Target start="Computer name \zs\"" end="\"\ze" +syn region upstreamlog_Target start="request to registered name \zs" end=" " + + +hi def link upstreamlog_Date Underlined +hi def link upstreamlog_MsgD Type +hi def link upstreamlog_MsgE Error +hi def link upstreamlog_MsgW Constant +hi def link upstreamlog_Process Statement +hi def link upstreamlog_IPaddr Identifier +hi def link upstreamlog_Profile Identifier +hi def link upstreamlog_Target Identifier + +let b:current_syntax = "upstreamlog" + +endif diff --git a/syntax/upstreamrpt.vim b/syntax/upstreamrpt.vim new file mode 100644 index 0000000..c0de61c --- /dev/null +++ b/syntax/upstreamrpt.vim @@ -0,0 +1,314 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Innovation Data Processing upstream.rpt file +" Maintainer: Rob Owens +" Latest Revision: 2014-03-13 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +setlocal foldmethod=syntax + +" Parameters: +syn keyword upstreamdat_Parameter ACCEPTPCREMOTE +syn keyword upstreamdat_Parameter ACCEPTREMOTE +syn keyword upstreamdat_Parameter ACTION +syn keyword upstreamdat_Parameter ACTIVATEONENTRY +syn keyword upstreamdat_Parameter ARCHIVEBIT +syn keyword upstreamdat_Parameter ARCHIVEBIT +syn keyword upstreamdat_Parameter ASCTOEBC +syn keyword upstreamdat_Parameter ASRBACKUP +syn keyword upstreamdat_Parameter ATTENDED +syn keyword upstreamdat_Parameter AUTHORITATIVE +syn keyword upstreamdat_Parameter AUTHORITATIVERESTORE +syn keyword upstreamdat_Parameter AUTHORITATIVERESTORE +syn keyword upstreamdat_Parameter BACKUPPROFILE +syn keyword upstreamdat_Parameter BACKUPPROFILE2 +syn keyword upstreamdat_Parameter BACKUPREPARSEFILES +syn keyword upstreamdat_Parameter BACKUPREPARSEFILES +syn keyword upstreamdat_Parameter BACKUPVERIFY +syn keyword upstreamdat_Parameter BLANKTRUNC +syn keyword upstreamdat_Parameter CALCDASDSIZE +syn keyword upstreamdat_Parameter CHANGEDIRATTRIBS +syn keyword upstreamdat_Parameter CHANGEDIRATTRIBS +syn keyword upstreamdat_Parameter COMPRESSLEVEL +syn keyword upstreamdat_Parameter CONTROLFILE +syn keyword upstreamdat_Parameter DASDOVERRIDE +syn keyword upstreamdat_Parameter DATELIMIT +syn keyword upstreamdat_Parameter DATELIMIT +syn keyword upstreamdat_Parameter DAYSOLD +syn keyword upstreamdat_Parameter DAYSOLD +syn keyword upstreamdat_Parameter DELETED +syn keyword upstreamdat_Parameter DELETED +syn keyword upstreamdat_Parameter DELETEPROMPTS +syn keyword upstreamdat_Parameter DELETEPROMPTS +syn keyword upstreamdat_Parameter DESTINATION +syn keyword upstreamdat_Parameter DESTINATION +syn keyword upstreamdat_Parameter DIRDELETE +syn keyword upstreamdat_Parameter DIRECTORVMC +syn keyword upstreamdat_Parameter DIRONLYRESTOREOK +syn keyword upstreamdat_Parameter DIRSONLY +syn keyword upstreamdat_Parameter DIRSONLY +syn keyword upstreamdat_Parameter DISASTERRECOVERY +syn keyword upstreamdat_Parameter DISPLAY +syn keyword upstreamdat_Parameter DRIVEALIAS +syn keyword upstreamdat_Parameter DRIVEALIAS +syn keyword upstreamdat_Parameter DUALCOPY +syn keyword upstreamdat_Parameter DUPDAYS +syn keyword upstreamdat_Parameter DUPLICATE +syn keyword upstreamdat_Parameter EBCTOASC +syn keyword upstreamdat_Parameter ENCRYPT +syn keyword upstreamdat_Parameter ENCRYPTLEVEL +syn keyword upstreamdat_Parameter EXCLUDELISTNAME +syn keyword upstreamdat_Parameter FAILBACKUPONERROR +syn keyword upstreamdat_Parameter FAILBACKUPONERROR +syn keyword upstreamdat_Parameter FAILIFNOFILES +syn keyword upstreamdat_Parameter FAILIFNOFILES +syn keyword upstreamdat_Parameter FAILIFSKIP +syn keyword upstreamdat_Parameter FAILJOB +syn keyword upstreamdat_Parameter FAILRESTOREONERROR +syn keyword upstreamdat_Parameter FAILRESTOREONERROR +syn keyword upstreamdat_Parameter FILEDATE +syn keyword upstreamdat_Parameter FILEDATE +syn keyword upstreamdat_Parameter FILEDELETE +syn keyword upstreamdat_Parameter FILEDELETE +syn keyword upstreamdat_Parameter FILES +syn keyword upstreamdat_Parameter FILES +syn keyword upstreamdat_Parameter FILESOPENFORUPDAT +syn keyword upstreamdat_Parameter FILESOPENFORUPDAT +syn keyword upstreamdat_Parameter FILETRANSFER +syn keyword upstreamdat_Parameter GETREMOTEFILES +syn keyword upstreamdat_Parameter HARDLINKDB +syn keyword upstreamdat_Parameter HARDLINKS +syn keyword upstreamdat_Parameter HARDLINKS +syn keyword upstreamdat_Parameter HIDDENFILES +syn keyword upstreamdat_Parameter HIDDENFILES +syn keyword upstreamdat_Parameter HOLDTAPE +syn keyword upstreamdat_Parameter HOLDUSERDIRS +syn keyword upstreamdat_Parameter HOSTFILENAME +syn keyword upstreamdat_Parameter HOSTRECORD +syn keyword upstreamdat_Parameter HOSTSORT +syn keyword upstreamdat_Parameter IGNOREPLUGINSFORRESTORE +syn keyword upstreamdat_Parameter INCRDB +syn keyword upstreamdat_Parameter INCRDBARCHIVEBIT +syn keyword upstreamdat_Parameter INCRDBDELETEDFILES +syn keyword upstreamdat_Parameter INCREMENTAL +syn keyword upstreamdat_Parameter INCREMENTAL +syn keyword upstreamdat_Parameter INQOPTIONS +syn keyword upstreamdat_Parameter INSTALLWIN2KAGENT +syn keyword upstreamdat_Parameter INSTALLWIN2KAGENT +syn keyword upstreamdat_Parameter JOBOPTIONS +syn keyword upstreamdat_Parameter JOBRETURNCODEMAP +syn keyword upstreamdat_Parameter JOBWAITTIMELIMIT +syn keyword upstreamdat_Parameter KEEPALIVE +syn keyword upstreamdat_Parameter LANINTERFACE +syn keyword upstreamdat_Parameter LANWSNAME +syn keyword upstreamdat_Parameter LANWSPASSWORD +syn keyword upstreamdat_Parameter LASTACCESS +syn keyword upstreamdat_Parameter LASTACCESS +syn keyword upstreamdat_Parameter LATESTDATE +syn keyword upstreamdat_Parameter LATESTDATE +syn keyword upstreamdat_Parameter LATESTTIME +syn keyword upstreamdat_Parameter LATESTTIME +syn keyword upstreamdat_Parameter LATESTVERSION +syn keyword upstreamdat_Parameter LINEBLOCK +syn keyword upstreamdat_Parameter LINETRUNC +syn keyword upstreamdat_Parameter LISTENFORREMOTE +syn keyword upstreamdat_Parameter LOCALBACKUP +syn keyword upstreamdat_Parameter LOCALBACKUPDIR +syn keyword upstreamdat_Parameter LOCALBACKUPMAX +syn keyword upstreamdat_Parameter LOCALBACKUPMAXFILESIZE +syn keyword upstreamdat_Parameter LOCALBACKUPMAXSIZE +syn keyword upstreamdat_Parameter LOCALEXCLUDEFILE +syn keyword upstreamdat_Parameter LOCALPARAMETERS +syn keyword upstreamdat_Parameter LOCALPASSWORD +syn keyword upstreamdat_Parameter LOCALRESTORE +syn keyword upstreamdat_Parameter LOCALUSER +syn keyword upstreamdat_Parameter LOFS +syn keyword upstreamdat_Parameter LOGNONFATAL +syn keyword upstreamdat_Parameter MAXBACKUPFILESFAIL +syn keyword upstreamdat_Parameter MAXBACKUPTIME +syn keyword upstreamdat_Parameter MAXDUPS +syn keyword upstreamdat_Parameter MAXFILENAMESIZE +syn keyword upstreamdat_Parameter MAXKFILESIZE +syn keyword upstreamdat_Parameter MAXLOGDAYS +syn keyword upstreamdat_Parameter MAXRESTOREFILESFAIL +syn keyword upstreamdat_Parameter MAXRESTORETIME +syn keyword upstreamdat_Parameter MAXRETRY +syn keyword upstreamdat_Parameter MAXRPTDAYS +syn keyword upstreamdat_Parameter MERGE +syn keyword upstreamdat_Parameter MIGRBITS +syn keyword upstreamdat_Parameter MIGRBITS +syn keyword upstreamdat_Parameter MINCOMPRESSSIZE +syn keyword upstreamdat_Parameter MINIMIZE +syn keyword upstreamdat_Parameter MODIFYFILE +syn keyword upstreamdat_Parameter MOUNTPOINTS +syn keyword upstreamdat_Parameter MOUNTPOINTS +syn keyword upstreamdat_Parameter NDS +syn keyword upstreamdat_Parameter NDS +syn keyword upstreamdat_Parameter NEWFILECOMPARE +syn keyword upstreamdat_Parameter NFSBELOW +syn keyword upstreamdat_Parameter NODATAOK +syn keyword upstreamdat_Parameter NODIRFORINCREMENTAL +syn keyword upstreamdat_Parameter NODIRFORINCREMENTAL +syn keyword upstreamdat_Parameter NONFILEDATABITMAP +syn keyword upstreamdat_Parameter NONFILEDATABITMAP +syn keyword upstreamdat_Parameter NOPOINTRESTORE +syn keyword upstreamdat_Parameter NOSPECINHERITANCE +syn keyword upstreamdat_Parameter NOTIFYEVENTS +syn keyword upstreamdat_Parameter NOTIFYFAILUREATTACHMENT +syn keyword upstreamdat_Parameter NOTIFYSUCCESSATTACHMENT +syn keyword upstreamdat_Parameter NOTIFYTARGETS +syn keyword upstreamdat_Parameter NOUIDGIDNAMES +syn keyword upstreamdat_Parameter NOUIDGIDNAMES +syn keyword upstreamdat_Parameter NOVELLMIGRATE +syn keyword upstreamdat_Parameter NOVELLMIGRATE +syn keyword upstreamdat_Parameter NOVELLMIGRATEADDEXT +syn keyword upstreamdat_Parameter NOVELLMIGRATEADDEXT +syn keyword upstreamdat_Parameter NOVELLPROFILE +syn keyword upstreamdat_Parameter NOVELLRECALL +syn keyword upstreamdat_Parameter NTFSADDPERMISSION +syn keyword upstreamdat_Parameter NTFSADDPERMISSION +syn keyword upstreamdat_Parameter NTREGRESTORE +syn keyword upstreamdat_Parameter OSTYPE +syn keyword upstreamdat_Parameter OUTPORT +syn keyword upstreamdat_Parameter PACKFLUSHAFTERFILE +syn keyword upstreamdat_Parameter PACKRECSIZE +syn keyword upstreamdat_Parameter PARAMETER +syn keyword upstreamdat_Parameter PASSWORD +syn keyword upstreamdat_Parameter PATHNAME +syn keyword upstreamdat_Parameter PATHNAME +syn keyword upstreamdat_Parameter PERFORMBITMAP +syn keyword upstreamdat_Parameter PERFORMNUMRECORDS +syn keyword upstreamdat_Parameter PERFORMRECORDSIZE +syn keyword upstreamdat_Parameter PLUGIN +syn keyword upstreamdat_Parameter PLUGIN +syn keyword upstreamdat_Parameter PLUGINPARAMETERS +syn keyword upstreamdat_Parameter PLUGINPARAMETERS +syn keyword upstreamdat_Parameter POSTJOB +syn keyword upstreamdat_Parameter PREJOB +syn keyword upstreamdat_Parameter PRTYCLASS +syn keyword upstreamdat_Parameter PRTYLEVEL +syn keyword upstreamdat_Parameter RECALLCLEANUP +syn keyword upstreamdat_Parameter RECALLOFFLINEFILES +syn keyword upstreamdat_Parameter RECALLOFFLINEFILES +syn keyword upstreamdat_Parameter RECORDSIZE +syn keyword upstreamdat_Parameter REMOTEADDR +syn keyword upstreamdat_Parameter REMOTEAPPLPREF +syn keyword upstreamdat_Parameter REMOTEAPPLRETRY +syn keyword upstreamdat_Parameter REMOTECONNECTTYPE +syn keyword upstreamdat_Parameter REMOTEFLAGS +syn keyword upstreamdat_Parameter REMOTEIPADAPTER +syn keyword upstreamdat_Parameter REMOTELOCALPARAMETERS +syn keyword upstreamdat_Parameter REMOTELOGMODE +syn keyword upstreamdat_Parameter REMOTELUNAME +syn keyword upstreamdat_Parameter REMOTEMAXRETRIES +syn keyword upstreamdat_Parameter REMOTEMODENAME +syn keyword upstreamdat_Parameter REMOTEPARAMETERFILE +syn keyword upstreamdat_Parameter REMOTEPORT +syn keyword upstreamdat_Parameter REMOTEREQUEST +syn keyword upstreamdat_Parameter REMOTERESTART +syn keyword upstreamdat_Parameter REMOTEROUTE +syn keyword upstreamdat_Parameter REMOTETARGETNAME +syn keyword upstreamdat_Parameter REMOTETCP +syn keyword upstreamdat_Parameter REMOTETIMEOUT +syn keyword upstreamdat_Parameter REMOTETMAXRETRY +syn keyword upstreamdat_Parameter REMOTETPN +syn keyword upstreamdat_Parameter REMOTEUSAPPL +syn keyword upstreamdat_Parameter REMOTEVERIFY +syn keyword upstreamdat_Parameter REMOTEWTOCOMP +syn keyword upstreamdat_Parameter REPORTNAME +syn keyword upstreamdat_Parameter REPORTOPTIONS +syn keyword upstreamdat_Parameter RESTARTLASTFILE +syn keyword upstreamdat_Parameter RESTART +syn keyword upstreamdat_Parameter RESTARTTYPE +syn keyword upstreamdat_Parameter RESTARTVERSIONDATE +syn keyword upstreamdat_Parameter RESTOREARCHIVEBIT +syn keyword upstreamdat_Parameter RESTORECHECKPOINT +syn keyword upstreamdat_Parameter RESTOREDATELIMIT +syn keyword upstreamdat_Parameter RESTOREDATELIMIT +syn keyword upstreamdat_Parameter RESTOREFILEFAIL +syn keyword upstreamdat_Parameter RESTOREMOUNTPOINTS +syn keyword upstreamdat_Parameter RESTOREMOUNTPOINTS +syn keyword upstreamdat_Parameter RESTORESEGMENTS +syn keyword upstreamdat_Parameter RESTORESEGMENTS +syn keyword upstreamdat_Parameter RESTORETODIFFFS +syn keyword upstreamdat_Parameter RETAIN +syn keyword upstreamdat_Parameter RETAIN +syn keyword upstreamdat_Parameter ROOTENTRY +syn keyword upstreamdat_Parameter ROOTENTRY +syn keyword upstreamdat_Parameter SAN +syn keyword upstreamdat_Parameter SCHEDULENAME +syn keyword upstreamdat_Parameter SEGMENTEDFILESIZE +syn keyword upstreamdat_Parameter SEGMENTEDFILESIZE +syn keyword upstreamdat_Parameter SEGMENTSIZE +syn keyword upstreamdat_Parameter SEGMENTSIZE +syn keyword upstreamdat_Parameter SENDHOSTDETAILS +syn keyword upstreamdat_Parameter SINGLEFS +syn keyword upstreamdat_Parameter SIZETRC +syn keyword upstreamdat_Parameter SKIP +syn keyword upstreamdat_Parameter SKIPBACKUPSCAN +syn keyword upstreamdat_Parameter SKIPOLD +syn keyword upstreamdat_Parameter SKIPOLD +syn keyword upstreamdat_Parameter SMSTARGETSERVICENAME +syn keyword upstreamdat_Parameter SMSTSA +syn keyword upstreamdat_Parameter SOLO +syn keyword upstreamdat_Parameter SORTBACKUP +syn keyword upstreamdat_Parameter SOSDISK +syn keyword upstreamdat_Parameter SOSDISK +syn keyword upstreamdat_Parameter SOSTIMESTAMP +syn keyword upstreamdat_Parameter SOSTIMESTAMP +syn keyword upstreamdat_Parameter SOSTIMESTAMPPATH +syn keyword upstreamdat_Parameter SOSTIMESTAMPPATH +syn keyword upstreamdat_Parameter SPECNUMBER +syn keyword upstreamdat_Parameter SPECNUMBER +syn keyword upstreamdat_Parameter SPECTYPE +syn keyword upstreamdat_Parameter SPECTYPE +syn keyword upstreamdat_Parameter STARTTIME +syn keyword upstreamdat_Parameter STORAGETYPE +syn keyword upstreamdat_Parameter SUBDIRECTORIES +syn keyword upstreamdat_Parameter SUBDIRECTORIES +syn keyword upstreamdat_Parameter SWITCHTOTAPEMB +syn keyword upstreamdat_Parameter TCPADDRESS +syn keyword upstreamdat_Parameter TCPTIMEOUT +syn keyword upstreamdat_Parameter TIMEOVERRIDE +syn keyword upstreamdat_Parameter TRACE +syn keyword upstreamdat_Parameter TRANSLATE +syn keyword upstreamdat_Parameter ULTRACOMP +syn keyword upstreamdat_Parameter ULTREG +syn keyword upstreamdat_Parameter ULTUPD +syn keyword upstreamdat_Parameter UNCMACHINEALIAS +syn keyword upstreamdat_Parameter UNCMACHINEALIAS +syn keyword upstreamdat_Parameter USEALEBRA +syn keyword upstreamdat_Parameter USECONTROLFILE +syn keyword upstreamdat_Parameter USEGID +syn keyword upstreamdat_Parameter USERID +syn keyword upstreamdat_Parameter USEUID +syn keyword upstreamdat_Parameter USNOUIDGIDERRORS +syn keyword upstreamdat_Parameter UTF8 +syn keyword upstreamdat_Parameter VAULTNUMBER +syn keyword upstreamdat_Parameter VERSIONDATE +syn keyword upstreamdat_Parameter WRITESPARSE +syn keyword upstreamdat_Parameter XFERECORDSIZE +syn keyword upstreamdat_Parameter XFERRECSEP +syn keyword upstreamdat_Parameter XFERRECUSECR + +" File Specs: +syn match upstreamdat_Filespec /file spec\c \d\{1,3}.*/ + +" Comments: +syn match upstreamdat_Comment /^#.*/ + +" List Of Parameters: +syn region upstreamdat_Parms start="Current Parameters:" end="End Of Parameters" transparent fold + +hi def link upstreamdat_Parameter Type +"hi def link upstreamdat_Filespec Underlined +hi def link upstreamdat_Comment Comment + +let b:current_syntax = "upstreamdat" + +endif diff --git a/syntax/usserverlog.vim b/syntax/usserverlog.vim new file mode 100644 index 0000000..2eadcf6 --- /dev/null +++ b/syntax/usserverlog.vim @@ -0,0 +1,64 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Innovation Data Processing usserver.log file +" Maintainer: Rob Owens +" Latest Revision: 2013-09-19 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Date: +syn match usserverlog_Date /\u\l\l \u\l\l\s\{1,2}\d\{1,2} \d\d:\d\d:\d\d \d\d\d\d/ +" Msg Types: +syn match usserverlog_MsgD /Msg #\(Agt\|PC\|Srv\)\d\{4,5}D/ nextgroup=usserverlog_Process skipwhite +syn match usserverlog_MsgE /Msg #\(Agt\|PC\|Srv\)\d\{4,5}E/ nextgroup=usserverlog_Process skipwhite +syn match usserverlog_MsgI /Msg #\(Agt\|PC\|Srv\)\d\{4,5}I/ nextgroup=usserverlog_Process skipwhite +syn match usserverlog_MsgW /Msg #\(Agt\|PC\|Srv\)\d\{4,5}W/ nextgroup=usserverlog_Process skipwhite +" Processes: +syn region usserverlog_Process start="(" end=")" contained +" IP Address: +syn match usserverlog_IPaddr /\( \|(\)\zs\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}/ +" Profile: +syn match usserverlog_Profile /Using default configuration for profile \zs\S\{1,8}\ze/ +syn match usserverlog_Profile /Now running profile \zs\S\{1,8}\ze/ +syn match usserverlog_Profile /in profile set \zs\S\{1,8}\ze/ +syn match usserverlog_Profile /Migrate disk backup from profile \zs\S\{1,8}\ze/ +syn match usserverlog_Profile /Using profile prefix for profile \zs\S\{1,8}\ze/ +syn match usserverlog_Profile /Add\/update profile \zs\S\{1,8}\ze/ +syn match usserverlog_Profile /Profileset=\zs\S\{1,8}\ze,/ +syn match usserverlog_Profile /profileset=\zs\S\{1,8}\ze/ +syn match usserverlog_Profile /Vault \(disk\|tape\) backup to vault \d\{1,4} from profile \zs\S\{1,8}\ze/ +syn match usserverlog_Profile /Profile name \zs\"\S\{1,8}\"/ +syn match usserverlog_Profile / Profile: \zs\S\{1,8}/ +syn match usserverlog_Profile / Profile: \zs\S\{1,8}\ze, / +syn match usserverlog_Profile /, profile: \zs\S\{1,8}\ze,/ +syn match usserverlog_Profile /Expecting Profile: \zs\S\{1,8}\ze,/ +syn match usserverlog_Profile /found Profile: \zs\S\{1,8}\ze,/ +syn match usserverlog_Profile /Profile \zs\S\{1,8} \zeis a member of group: / +syn match upstreamlog_Profile /Backup Profile: \zs\S\{1,8}\ze Version date/ +syn match upstreamlog_Profile /Backup profile: \zs\S\{1,8}\ze Version date/ +syn match usserverlog_Profile /Full of \zs\S\{1,8}\ze$/ +syn match usserverlog_Profile /Incr. of \zs\S\{1,8}\ze$/ +syn match usserverlog_Profile /Profile=\zs\S\{1,8}\ze,/ +" Target: +syn region usserverlog_Target start="Computer: \zs" end="\ze[\]\)]" +syn region usserverlog_Target start="Computer name \zs\"" end="\"\ze" +syn region usserverlog_Target start="Registration add request successful \zs" end="$" +syn region usserverlog_Target start="request to registered name \zs" end=" " +syn region usserverlog_Target start=", sending to \zs" end="$" + +hi def link usserverlog_Date Underlined +hi def link usserverlog_MsgD Type +hi def link usserverlog_MsgE Error +hi def link usserverlog_MsgW Constant +hi def link usserverlog_Process Statement +hi def link usserverlog_IPaddr Identifier +hi def link usserverlog_Profile Identifier +hi def link usserverlog_Target Identifier + +let b:current_syntax = "usserverlog" + +endif diff --git a/syntax/usw2kagtlog.vim b/syntax/usw2kagtlog.vim new file mode 100644 index 0000000..4c70a6b --- /dev/null +++ b/syntax/usw2kagtlog.vim @@ -0,0 +1,58 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Innovation Data Processing USW2KAgt.log file +" Maintainer: Rob Owens +" Latest Revision: 2014-04-01 + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Date: +syn match usw2kagtlog_Date /\u\l\l \u\l\l\s\{1,2}\d\{1,2} \d\d:\d\d:\d\d \d\d\d\d/ +" Msg Types: +syn match usw2kagtlog_MsgD /Msg #\(Agt\|PC\|Srv\)\d\{4,5}D/ nextgroup=usw2kagtlog_Process skipwhite +syn match usw2kagtlog_MsgE /Msg #\(Agt\|PC\|Srv\)\d\{4,5}E/ nextgroup=usw2kagtlog_Process skipwhite +syn match usw2kagtlog_MsgI /Msg #\(Agt\|PC\|Srv\)\d\{4,5}I/ nextgroup=usw2kagtlog_Process skipwhite +syn match usw2kagtlog_MsgW /Msg #\(Agt\|PC\|Srv\)\d\{4,5}W/ nextgroup=usw2kagtlog_Process skipwhite +" Processes: +syn region usw2kagtlog_Process start="(" end=")" contained +"syn region usw2kagtlog_Process start="Starting the processing for a \zs\"" end="\ze client request" +"syn region usw2kagtlog_Process start="Ending the processing for a \zs\"" end="\ze client request" +"syn region usw2kagtlog_Process start="Starting the processing for a \zs\"" end="\ze client\s\{0,1}\r\{0,1}\s\{1,9}request" +"syn region usw2kagtlog_Process start="Ending the processing for a \zs\"" end="\ze client\s\{0,1}\r\{0,1}\s\{1,9}request" +syn region usw2kagtlog_Process start="Starting the processing for a \zs\"" end="\ze client" +syn region usw2kagtlog_Process start="Ending the processing for a \zs\"" end="\ze client" +" IP Address: +syn match usw2kagtlog_IPaddr / \d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}/ +" Profile: + +syn match usw2kagtlog_Profile /Profile name \zs\"\S\{1,8}\"/ +syn match usw2kagtlog_Profile / Profile: \zs\S\{1,8}/ +syn match usw2kagtlog_Profile / Profile: \zs\S\{1,8}\ze, / +syn match upstreamlog_Profile /Backup Profile: \zs\S\{1,8}\ze Version date/ +syn match upstreamlog_Profile /Backup profile: \zs\S\{1,8}\ze Version date/ +syn match usw2kagtlog_Profile /Full of \zs\S\{1,8}\ze$/ +syn match usw2kagtlog_Profile /Incr. of \zs\S\{1,8}\ze$/ +syn match usw2kagtlog_Profile /profile name "\zs\S\{1,8}\ze"/ +" Target: +syn region usw2kagtlog_Target start="Computer: \zs" end="\ze[\]\)]" +syn region usw2kagtlog_Target start="Computer name \zs\"" end="\"\ze" +" Agent Keywords: +syn keyword usw2kagtlog_Agentword opened closed + +hi def link usw2kagtlog_Date Underlined +hi def link usw2kagtlog_MsgD Type +hi def link usw2kagtlog_MsgE Error +hi def link usw2kagtlog_MsgW Constant +hi def link usw2kagtlog_Process Statement +hi def link usw2kagtlog_IPaddr Identifier +hi def link usw2kagtlog_Profile Identifier +hi def link usw2kagtlog_Target Identifier +hi def link usw2kagtlog_Agentword Special + +let b:current_syntax = "usw2kagentlog" + +endif diff --git a/syntax/valgrind.vim b/syntax/valgrind.vim new file mode 100644 index 0000000..b34c19a --- /dev/null +++ b/syntax/valgrind.vim @@ -0,0 +1,115 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Valgrind Memory Debugger Output +" Maintainer: Roger Luethi +" Program URL: http://devel-home.kde.org/~sewardj/ +" Last Change: 2015 Jan 27 +" Included improvement by Dominique Pelle +" +" Notes: mostly based on strace.vim and xml.vim +" +" Contributors: Christoph Gysin + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +" Lines can be long with demangled c++ functions. +setlocal synmaxcol=8000 + +syn case match +syn sync minlines=50 + +syn match valgrindSpecLine "^[+-]\{2}\d\+[+-]\{2}.*$" + +syn region valgrindRegion + \ start=+^==\z(\d\+\)== \w.*$+ + \ skip=+^==\z1==\( \| .*\)$+ + \ end=+^+ + \ fold + \ keepend + \ contains=valgrindPidChunk,valgrindLine + +syn region valgrindPidChunk + \ start=+^==\zs+ + \ end=+\ze==+ + \ contained + \ contains=valgrindPid0,valgrindPid1,valgrindPid2,valgrindPid3,valgrindPid4,valgrindPid5,valgrindPid6,valgrindPid7,valgrindPid8,valgrindPid9 + \ keepend + +syn match valgrindPid0 "\d\+0=" contained +syn match valgrindPid1 "\d\+1=" contained +syn match valgrindPid2 "\d\+2=" contained +syn match valgrindPid3 "\d\+3=" contained +syn match valgrindPid4 "\d\+4=" contained +syn match valgrindPid5 "\d\+5=" contained +syn match valgrindPid6 "\d\+6=" contained +syn match valgrindPid7 "\d\+7=" contained +syn match valgrindPid8 "\d\+8=" contained +syn match valgrindPid9 "\d\+9=" contained + +syn region valgrindLine + \ start=+\(^==\d\+== \)\@<=+ + \ end=+$+ + \ keepend + \ contained + \ contains=valgrindOptions,valgrindMsg,valgrindLoc + +syn match valgrindOptions "[ ]\{3}-.*$" contained + +syn match valgrindMsg "\S.*$" contained + \ contains=valgrindError,valgrindNote,valgrindSummary +syn match valgrindError "\(Invalid\|\d\+ errors\|.* definitely lost\).*$" contained +syn match valgrindNote ".*still reachable.*" contained +syn match valgrindSummary ".*SUMMARY:" contained + +syn match valgrindLoc "\s\+\(by\|at\|Address\).*$" contained + \ contains=valgrindAt,valgrindAddr,valgrindFunc,valgrindBin,valgrindSrc +syn match valgrindAt "at\s\@=" contained +syn match valgrindAddr "\W\zs0x\x\+" contained + +syn match valgrindFunc ": \zs\h[a-zA-Z0-9_:\[\]()<>&*+\-,=%!|^ ]*\ze([^)]*)$" contained +syn match valgrindBin "(\(with\)\=in \zs\S\+)\@=" contained +syn match valgrindSrc "(\zs[^)]*:\d\+)\@=" contained + +" Define the default highlighting + +hi def link valgrindSpecLine Type +"hi def link valgrindRegion Special + +hi def link valgrindPid0 Special +hi def link valgrindPid1 Comment +hi def link valgrindPid2 Type +hi def link valgrindPid3 Constant +hi def link valgrindPid4 Number +hi def link valgrindPid5 Identifier +hi def link valgrindPid6 Statement +hi def link valgrindPid7 Error +hi def link valgrindPid8 LineNr +hi def link valgrindPid9 Normal +"hi def link valgrindLine Special + +hi def link valgrindOptions Type +"hi def link valgrindMsg Special +"hi def link valgrindLoc Special + +hi def link valgrindError Special +hi def link valgrindNote Comment +hi def link valgrindSummary Type + +hi def link valgrindAt Special +hi def link valgrindAddr Number +hi def link valgrindFunc Type +hi def link valgrindBin Comment +hi def link valgrindSrc Statement + +let b:current_syntax = "valgrind" + +let &cpo = s:keepcpo +unlet s:keepcpo + +endif diff --git a/syntax/vb.vim b/syntax/vb.vim new file mode 100644 index 0000000..6d76146 --- /dev/null +++ b/syntax/vb.vim @@ -0,0 +1,369 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Visual Basic +" Maintainer: Tim Chase +" Former Maintainer: Robert M. Cortopassi +" (tried multiple times to contact, but email bounced) +" Last Change: +" 2005 May 25 Synched with work by Thomas Barthel +" 2004 May 30 Added a few keywords + +" This was thrown together after seeing numerous requests on the +" VIM and VIM-DEV mailing lists. It is by no means complete. +" Send comments, suggestions and requests to the maintainer. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" VB is case insensitive +syn case ignore + +syn keyword vbConditional If Then ElseIf Else Select Case + +syn keyword vbOperator AddressOf And ByRef ByVal Eqv Imp In +syn keyword vbOperator Is Like Mod Not Or To Xor + +syn match vbOperator "[()+.,\-/*=&]" +syn match vbOperator "[<>]=\=" +syn match vbOperator "<>" +syn match vbOperator "\s\+_$" + +syn keyword vbBoolean True False +syn keyword vbConst Null Nothing + +syn keyword vbRepeat Do For ForEach Loop Next +syn keyword vbRepeat Step To Until Wend While + +syn keyword vbEvents AccessKeyPress Activate ActiveRowChanged +syn keyword vbEvents AfterAddFile AfterChangeFileName AfterCloseFile +syn keyword vbEvents AfterColEdit AfterColUpdate AfterDelete +syn keyword vbEvents AfterInsert AfterLabelEdit AfterRemoveFile +syn keyword vbEvents AfterUpdate AfterWriteFile AmbientChanged +syn keyword vbEvents ApplyChanges Associate AsyncProgress +syn keyword vbEvents AsyncReadComplete AsyncReadProgress AxisActivated +syn keyword vbEvents AxisLabelActivated AxisLabelSelected +syn keyword vbEvents AxisLabelUpdated AxisSelected AxisTitleActivated +syn keyword vbEvents AxisTitleSelected AxisTitleUpdated AxisUpdated +syn keyword vbEvents BeforeClick BeforeColEdit BeforeColUpdate +syn keyword vbEvents BeforeConnect BeforeDelete BeforeInsert +syn keyword vbEvents BeforeLabelEdit BeforeLoadFile BeforeUpdate +syn keyword vbEvents BeginRequest BeginTrans ButtonClick +syn keyword vbEvents ButtonCompleted ButtonDropDown ButtonGotFocus +syn keyword vbEvents ButtonLostFocus CallbackKeyDown Change Changed +syn keyword vbEvents ChartActivated ChartSelected ChartUpdated Click +syn keyword vbEvents Close CloseQuery CloseUp ColEdit ColResize +syn keyword vbEvents Collapse ColumnClick CommitTrans Compare +syn keyword vbEvents ConfigChageCancelled ConfigChanged +syn keyword vbEvents ConfigChangedCancelled Connect ConnectionRequest +syn keyword vbEvents CurrentRecordChanged DECommandAdded +syn keyword vbEvents DECommandPropertyChanged DECommandRemoved +syn keyword vbEvents DEConnectionAdded DEConnectionPropertyChanged +syn keyword vbEvents DEConnectionRemoved DataArrival DataChanged +syn keyword vbEvents DataUpdated DateClicked DblClick Deactivate +syn keyword vbEvents DevModeChange DeviceArrival DeviceOtherEvent +syn keyword vbEvents DeviceQueryRemove DeviceQueryRemoveFailed +syn keyword vbEvents DeviceRemoveComplete DeviceRemovePending +syn keyword vbEvents Disconnect DisplayChanged Dissociate +syn keyword vbEvents DoGetNewFileName Done DonePainting DownClick +syn keyword vbEvents DragDrop DragOver DropDown EditProperty EditQuery +syn keyword vbEvents EndRequest EnterCell EnterFocus ExitFocus Expand +syn keyword vbEvents FontChanged FootnoteActivated FootnoteSelected +syn keyword vbEvents FootnoteUpdated Format FormatSize GotFocus +syn keyword vbEvents HeadClick HeightChanged Hide InfoMessage +syn keyword vbEvents IniProperties InitProperties Initialize +syn keyword vbEvents ItemActivated ItemAdded ItemCheck ItemClick +syn keyword vbEvents ItemReloaded ItemRemoved ItemRenamed +syn keyword vbEvents ItemSeletected KeyDown KeyPress KeyUp LeaveCell +syn keyword vbEvents LegendActivated LegendSelected LegendUpdated +syn keyword vbEvents LinkClose LinkError LinkExecute LinkNotify +syn keyword vbEvents LinkOpen Load LostFocus MouseDown MouseMove +syn keyword vbEvents MouseUp NodeCheck NodeClick OLECompleteDrag +syn keyword vbEvents OLEDragDrop OLEDragOver OLEGiveFeedback OLESetData +syn keyword vbEvents OLEStartDrag ObjectEvent ObjectMove OnAddNew +syn keyword vbEvents OnComm Paint PanelClick PanelDblClick PathChange +syn keyword vbEvents PatternChange PlotActivated PlotSelected +syn keyword vbEvents PlotUpdated PointActivated PointLabelActivated +syn keyword vbEvents PointLabelSelected PointLabelUpdated PointSelected +syn keyword vbEvents PointUpdated PowerQuerySuspend PowerResume +syn keyword vbEvents PowerStatusChanged PowerSuspend ProcessTag +syn keyword vbEvents ProcessingTimeout QueryChangeConfig QueryClose +syn keyword vbEvents QueryComplete QueryCompleted QueryTimeout +syn keyword vbEvents QueryUnload ReadProperties RepeatedControlLoaded +syn keyword vbEvents RepeatedControlUnloaded Reposition +syn keyword vbEvents RequestChangeFileName RequestWriteFile Resize +syn keyword vbEvents ResultsChanged RetainedProject RollbackTrans +syn keyword vbEvents RowColChange RowCurrencyChange RowResize +syn keyword vbEvents RowStatusChanged Scroll SelChange SelectionChanged +syn keyword vbEvents SendComplete SendProgress SeriesActivated +syn keyword vbEvents SeriesSelected SeriesUpdated SettingChanged Show +syn keyword vbEvents SplitChange Start StateChanged StatusUpdate +syn keyword vbEvents SysColorsChanged Terminate TimeChanged Timer +syn keyword vbEvents TitleActivated TitleSelected TitleUpdated +syn keyword vbEvents UnboundAddData UnboundDeleteRow +syn keyword vbEvents UnboundGetRelativeBookmark UnboundReadData +syn keyword vbEvents UnboundWriteData Unformat Unload UpClick Updated +syn keyword vbEvents UserEvent Validate ValidationError +syn keyword vbEvents VisibleRecordChanged WillAssociate WillChangeData +syn keyword vbEvents WillDissociate WillExecute WillUpdateRows +syn keyword vbEvents WriteProperties + + +syn keyword vbFunction Abs Array Asc AscB AscW Atn Avg BOF CBool CByte +syn keyword vbFunction CCur CDate CDbl CInt CLng CSng CStr CVDate CVErr +syn keyword vbFunction CVar CallByName Cdec Choose Chr ChrB ChrW Command +syn keyword vbFunction Cos Count CreateObject CurDir DDB Date DateAdd +syn keyword vbFunction DateDiff DatePart DateSerial DateValue Day Dir +syn keyword vbFunction DoEvents EOF Environ Error Exp FV FileAttr +syn keyword vbFunction FileDateTime FileLen FilterFix Fix Format +syn keyword vbFunction FormatCurrency FormatDateTime FormatNumber +syn keyword vbFunction FormatPercent FreeFile GetAllStrings GetAttr +syn keyword vbFunction GetAutoServerSettings GetObject GetSetting Hex +syn keyword vbFunction Hour IIf IMEStatus IPmt InStr Input InputB +syn keyword vbFunction InputBox InstrB Int IsArray IsDate IsEmpty IsError +syn keyword vbFunction IsMissing IsNull IsNumeric IsObject Join LBound +syn keyword vbFunction LCase LOF LTrim Left LeftB Len LenB LoadPicture +syn keyword vbFunction LoadResData LoadResPicture LoadResString Loc Log +syn keyword vbFunction MIRR Max Mid MidB Min Minute Month MonthName +syn keyword vbFunction MsgBox NPV NPer Now Oct PPmt PV Partition Pmt +syn keyword vbFunction QBColor RGB RTrim Rate Replace Right RightB Rnd +syn keyword vbFunction Round SLN SYD Second Seek Sgn Shell Sin Space Spc +syn keyword vbFunction Split Sqr StDev StDevP Str StrComp StrConv +syn keyword vbFunction StrReverse String Sum Switch Tab Tan Time +syn keyword vbFunction TimeSerial TimeValue Timer Trim TypeName UBound +syn keyword vbFunction UCase Val Var VarP VarType Weekday WeekdayName +syn keyword vbFunction Year + +syn keyword vbMethods AboutBox Accept Activate Add AddCustom AddFile +syn keyword vbMethods AddFromFile AddFromGuid AddFromString +syn keyword vbMethods AddFromTemplate AddItem AddNew AddToAddInToolbar +syn keyword vbMethods AddToolboxProgID Append AppendAppendChunk +syn keyword vbMethods AppendChunk Arrange Assert AsyncRead BatchUpdate +syn keyword vbMethods BeginQueryEdit BeginTrans Bind BuildPath +syn keyword vbMethods CanPropertyChange Cancel CancelAsyncRead +syn keyword vbMethods CancelBatch CancelUpdate CaptureImage CellText +syn keyword vbMethods CellValue Circle Clear ClearFields ClearSel +syn keyword vbMethods ClearSelCols ClearStructure Clone Close Cls +syn keyword vbMethods ColContaining CollapseAll ColumnSize CommitTrans +syn keyword vbMethods CompactDatabase Compose Connect Copy CopyFile +syn keyword vbMethods CopyFolder CopyQueryDef Count CreateDatabase +syn keyword vbMethods CreateDragImage CreateEmbed CreateField +syn keyword vbMethods CreateFolder CreateGroup CreateIndex CreateLink +syn keyword vbMethods CreatePreparedStatement CreatePropery CreateQuery +syn keyword vbMethods CreateQueryDef CreateRelation CreateTableDef +syn keyword vbMethods CreateTextFile CreateToolWindow CreateUser +syn keyword vbMethods CreateWorkspace Customize Cut Delete +syn keyword vbMethods DeleteColumnLabels DeleteColumns DeleteFile +syn keyword vbMethods DeleteFolder DeleteLines DeleteRowLabels +syn keyword vbMethods DeleteRows DeselectAll DesignerWindow DoVerb Drag +syn keyword vbMethods Draw DriveExists Edit EditCopy EditPaste EndDoc +syn keyword vbMethods EnsureVisible EstablishConnection Execute Exists +syn keyword vbMethods Expand Export ExportReport ExtractIcon Fetch +syn keyword vbMethods FetchVerbs FileExists Files FillCache Find +syn keyword vbMethods FindFirst FindItem FindLast FindNext FindPrevious +syn keyword vbMethods FolderExists Forward GetAbsolutePathName +syn keyword vbMethods GetBaseName GetBookmark GetChunk GetClipString +syn keyword vbMethods GetData GetDrive GetDriveName GetFile GetFileName +syn keyword vbMethods GetFirstVisible GetFolder GetFormat GetHeader +syn keyword vbMethods GetLineFromChar GetNumTicks GetParentFolderName +syn keyword vbMethods GetRows GetSelectedPart GetSelection +syn keyword vbMethods GetSpecialFolder GetTempName GetText +syn keyword vbMethods GetVisibleCount GoBack GoForward Hide HitTest +syn keyword vbMethods HoldFields Idle Import InitializeLabels Insert +syn keyword vbMethods InsertColumnLabels InsertColumns InsertFile +syn keyword vbMethods InsertLines InsertObjDlg InsertRowLabels +syn keyword vbMethods InsertRows Item Keys KillDoc Layout Line Lines +syn keyword vbMethods LinkExecute LinkPoke LinkRequest LinkSend Listen +syn keyword vbMethods LoadFile LoadResData LoadResPicture LoadResString +syn keyword vbMethods LogEvent MakeCompileFile MakeCompiledFile +syn keyword vbMethods MakeReplica MoreResults Move MoveData MoveFile +syn keyword vbMethods MoveFirst MoveFolder MoveLast MoveNext +syn keyword vbMethods MovePrevious NavigateTo NewPage NewPassword +syn keyword vbMethods NextRecordset OLEDrag OnAddinsUpdate OnConnection +syn keyword vbMethods OnDisconnection OnStartupComplete Open +syn keyword vbMethods OpenAsTextStream OpenConnection OpenDatabase +syn keyword vbMethods OpenQueryDef OpenRecordset OpenResultset OpenURL +syn keyword vbMethods Overlay PSet PaintPicture PastSpecialDlg Paste +syn keyword vbMethods PeekData Play Point PopulatePartial PopupMenu +syn keyword vbMethods Print PrintForm PrintReport PropertyChanged Quit +syn keyword vbMethods Raise RandomDataFill RandomFillColumns +syn keyword vbMethods RandomFillRows ReFill Read ReadAll ReadFromFile +syn keyword vbMethods ReadLine ReadProperty Rebind Refresh RefreshLink +syn keyword vbMethods RegisterDatabase ReleaseInstance Reload Remove +syn keyword vbMethods RemoveAddInFromToolbar RemoveAll RemoveItem Render +syn keyword vbMethods RepairDatabase ReplaceLine Reply ReplyAll Requery +syn keyword vbMethods ResetCustom ResetCustomLabel ResolveName +syn keyword vbMethods RestoreToolbar Resync Rollback RollbackTrans +syn keyword vbMethods RowBookmark RowContaining RowTop Save SaveAs +syn keyword vbMethods SaveFile SaveToFile SaveToOle1File SaveToolbar +syn keyword vbMethods Scale ScaleX ScaleY Scroll SelPrint SelectAll +syn keyword vbMethods SelectPart Send SendData Set SetAutoServerSettings +syn keyword vbMethods SetData SetFocus SetOption SetSelection SetSize +syn keyword vbMethods SetText SetViewport Show ShowColor ShowFont +syn keyword vbMethods ShowHelp ShowOpen ShowPrinter ShowSave +syn keyword vbMethods ShowWhatsThis SignOff SignOn Size Skip SkipLine +syn keyword vbMethods Span Split SplitContaining StartLabelEdit +syn keyword vbMethods StartLogging Stop Synchronize Tag TextHeight +syn keyword vbMethods TextWidth ToDefaults Trace TwipsToChartPart +syn keyword vbMethods TypeByChartType URLFor Update UpdateControls +syn keyword vbMethods UpdateRecord UpdateRow Upto ValidateControls Value +syn keyword vbMethods WhatsThisMode Write WriteBlankLines WriteLine +syn keyword vbMethods WriteProperty WriteTemplate ZOrder +syn keyword vbMethods rdoCreateEnvironment rdoRegisterDataSource + +syn keyword vbStatement Alias AppActivate As Base Beep Begin Call ChDir +syn keyword vbStatement ChDrive Close Const Date Declare DefBool DefByte +syn keyword vbStatement DefCur DefDate DefDbl DefDec DefInt DefLng DefObj +syn keyword vbStatement DefSng DefStr DefVar Deftype DeleteSetting Dim Do +syn keyword vbStatement Each ElseIf End Enum Erase Error Event Exit +syn keyword vbStatement Explicit FileCopy For ForEach Function Get GoSub +syn keyword vbStatement GoTo Gosub Implements Kill LSet Let Lib LineInput +syn keyword vbStatement Load Lock Loop Mid MkDir Name Next On OnError Open +syn keyword vbStatement Option Preserve Private Property Public Put RSet +syn keyword vbStatement RaiseEvent Randomize ReDim Redim Reset Resume +syn keyword vbStatement Return RmDir SavePicture SaveSetting Seek SendKeys +syn keyword vbStatement Sendkeys Set SetAttr Static Step Stop Sub Time +syn keyword vbStatement Type Unload Unlock Until Wend While Width With +syn keyword vbStatement Write + +syn keyword vbKeyword As Binary ByRef ByVal Date Empty Error Friend Get +syn keyword vbKeyword Input Is Len Lock Me Mid New Nothing Null On +syn keyword vbKeyword Option Optional ParamArray Print Private Property +syn keyword vbKeyword Public PublicNotCreateable OnNewProcessSingleUse +syn keyword vbKeyword InSameProcessMultiUse GlobalMultiUse Resume Seek +syn keyword vbKeyword Set Static Step String Time WithEvents + +syn keyword vbTodo contained TODO + +"Datatypes +syn keyword vbTypes Boolean Byte Currency Date Decimal Double Empty +syn keyword vbTypes Integer Long Object Single String Variant + +"VB defined values +syn keyword vbDefine dbBigInt dbBinary dbBoolean dbByte dbChar +syn keyword vbDefine dbCurrency dbDate dbDecimal dbDouble dbFloat +syn keyword vbDefine dbGUID dbInteger dbLong dbLongBinary dbMemo +syn keyword vbDefine dbNumeric dbSingle dbText dbTime dbTimeStamp +syn keyword vbDefine dbVarBinary + +"VB defined values +syn keyword vbDefine vb3DDKShadow vb3DFace vb3DHighlight vb3DLight +syn keyword vbDefine vb3DShadow vbAbort vbAbortRetryIgnore +syn keyword vbDefine vbActiveBorder vbActiveTitleBar vbAlias +syn keyword vbDefine vbApplicationModal vbApplicationWorkspace +syn keyword vbDefine vbAppTaskManager vbAppWindows vbArchive vbArray +syn keyword vbDefine vbBack vbBinaryCompare vbBlack vbBlue vbBoolean +syn keyword vbDefine vbButtonFace vbButtonShadow vbButtonText vbByte +syn keyword vbDefine vbCalGreg vbCalHijri vbCancel vbCr vbCritical +syn keyword vbDefine vbCrLf vbCurrency vbCyan vbDatabaseCompare +syn keyword vbDefine vbDataObject vbDate vbDecimal vbDefaultButton1 +syn keyword vbDefine vbDefaultButton2 vbDefaultButton3 vbDefaultButton4 +syn keyword vbDefine vbDesktop vbDirectory vbDouble vbEmpty vbError +syn keyword vbDefine vbExclamation vbFirstFourDays vbFirstFullWeek +syn keyword vbDefine vbFirstJan1 vbFormCode vbFormControlMenu +syn keyword vbDefine vbFormFeed vbFormMDIForm vbFriday vbFromUnicode +syn keyword vbDefine vbGrayText vbGreen vbHidden vbHide vbHighlight +syn keyword vbDefine vbHighlightText vbHiragana vbIgnore vbIMEAlphaDbl +syn keyword vbDefine vbIMEAlphaSng vbIMEDisable vbIMEHiragana +syn keyword vbDefine vbIMEKatakanaDbl vbIMEKatakanaSng vbIMEModeAlpha +syn keyword vbDefine vbIMEModeAlphaFull vbIMEModeDisable +syn keyword vbDefine vbIMEModeHangul vbIMEModeHangulFull +syn keyword vbDefine vbIMEModeHiragana vbIMEModeKatakana +syn keyword vbDefine vbIMEModeKatakanaHalf vbIMEModeNoControl +syn keyword vbDefine vbIMEModeOff vbIMEModeOn vbIMENoOp vbIMEOff +syn keyword vbDefine vbIMEOn vbInactiveBorder vbInactiveCaptionText +syn keyword vbDefine vbInactiveTitleBar vbInfoBackground vbInformation +syn keyword vbDefine vbInfoText vbInteger vbKatakana vbKey0 vbKey1 +syn keyword vbDefine vbKey2 vbKey3 vbKey4 vbKey5 vbKey6 vbKey7 vbKey8 +syn keyword vbDefine vbKey9 vbKeyA vbKeyAdd vbKeyB vbKeyBack vbKeyC +syn keyword vbDefine vbKeyCancel vbKeyCapital vbKeyClear vbKeyControl +syn keyword vbDefine vbKeyD vbKeyDecimal vbKeyDelete vbKeyDivide +syn keyword vbDefine vbKeyDown vbKeyE vbKeyEnd vbKeyEscape vbKeyExecute +syn keyword vbDefine vbKeyF vbKeyF1 vbKeyF10 vbKeyF11 vbKeyF12 vbKeyF13 +syn keyword vbDefine vbKeyF14 vbKeyF15 vbKeyF16 vbKeyF2 vbKeyF3 vbKeyF4 +syn keyword vbDefine vbKeyF5 vbKeyF6 vbKeyF7 vbKeyF8 vbKeyF9 vbKeyG +syn keyword vbDefine vbKeyH vbKeyHelp vbKeyHome vbKeyI vbKeyInsert +syn keyword vbDefine vbKeyJ vbKeyK vbKeyL vbKeyLButton vbKeyLeft vbKeyM +syn keyword vbDefine vbKeyMButton vbKeyMenu vbKeyMultiply vbKeyN +syn keyword vbDefine vbKeyNumlock vbKeyNumpad0 vbKeyNumpad1 +syn keyword vbDefine vbKeyNumpad2 vbKeyNumpad3 vbKeyNumpad4 +syn keyword vbDefine vbKeyNumpad5 vbKeyNumpad6 vbKeyNumpad7 +syn keyword vbDefine vbKeyNumpad8 vbKeyNumpad9 vbKeyO vbKeyP +syn keyword vbDefine vbKeyPageDown vbKeyPageUp vbKeyPause vbKeyPrint +syn keyword vbDefine vbKeyQ vbKeyR vbKeyRButton vbKeyReturn vbKeyRight +syn keyword vbDefine vbKeyS vbKeySelect vbKeySeparator vbKeyShift +syn keyword vbDefine vbKeySnapshot vbKeySpace vbKeySubtract vbKeyT +syn keyword vbDefine vbKeyTab vbKeyU vbKeyUp vbKeyV vbKeyW vbKeyX +syn keyword vbDefine vbKeyY vbKeyZ vbLf vbLong vbLowerCase vbMagenta +syn keyword vbDefine vbMaximizedFocus vbMenuBar vbMenuText +syn keyword vbDefine vbMinimizedFocus vbMinimizedNoFocus vbMonday +syn keyword vbDefine vbMsgBox vbMsgBoxHelpButton vbMsgBoxRight +syn keyword vbDefine vbMsgBoxRtlReading vbMsgBoxSetForeground +syn keyword vbDefine vbMsgBoxText vbNarrow vbNewLine vbNo vbNormal +syn keyword vbDefine vbNormalFocus vbNormalNoFocus vbNull vbNullChar +syn keyword vbDefine vbNullString vbObject vbObjectError vbOK +syn keyword vbDefine vbOKCancel vbOKOnly vbProperCase vbQuestion +syn keyword vbDefine vbReadOnly vbRed vbRetry vbRetryCancel vbSaturday +syn keyword vbDefine vbScrollBars vbSingle vbString vbSunday vbSystem +syn keyword vbDefine vbSystemModal vbTab vbTextCompare vbThursday +syn keyword vbDefine vbTitleBarText vbTuesday vbUnicode vbUpperCase +syn keyword vbDefine vbUseSystem vbUseSystemDayOfWeek vbVariant +syn keyword vbDefine vbVerticalTab vbVolume vbWednesday vbWhite vbWide +syn keyword vbDefine vbWindowBackground vbWindowFrame vbWindowText +syn keyword vbDefine vbYellow vbYes vbYesNo vbYesNoCancel + +"Numbers +"integer number, or floating point number without a dot. +syn match vbNumber "\<\d\+\>" +"floating point number, with dot +syn match vbNumber "\<\d\+\.\d*\>" +"floating point number, starting with a dot +syn match vbNumber "\.\d\+\>" +"syn match vbNumber "{[[:xdigit:]-]\+}\|&[hH][[:xdigit:]]\+&" +"syn match vbNumber ":[[:xdigit:]]\+" +"syn match vbNumber "[-+]\=\<\d\+\>" +syn match vbFloat "[-+]\=\<\d\+[eE][\-+]\=\d\+" +syn match vbFloat "[-+]\=\<\d\+\.\d*\([eE][\-+]\=\d\+\)\=" +syn match vbFloat "[-+]\=\<\.\d\+\([eE][\-+]\=\d\+\)\=" + +" String and Character contstants +syn region vbString start=+"+ end=+"\|$+ +syn region vbComment start="\(^\|\s\)REM\s" end="$" contains=vbTodo +syn region vbComment start="\(^\|\s\)\'" end="$" contains=vbTodo +syn match vbLineNumber "^\d\+\(\s\|$\)" +syn match vbTypeSpecifier "[a-zA-Z0-9][\$%&!#]"ms=s+1 +syn match vbTypeSpecifier "#[a-zA-Z0-9]"me=e-1 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link vbBoolean Boolean +hi def link vbLineNumber Comment +hi def link vbComment Comment +hi def link vbConditional Conditional +hi def link vbConst Constant +hi def link vbDefine Constant +hi def link vbError Error +hi def link vbFunction Identifier +hi def link vbIdentifier Identifier +hi def link vbNumber Number +hi def link vbFloat Float +hi def link vbMethods PreProc +hi def link vbOperator Operator +hi def link vbRepeat Repeat +hi def link vbString String +hi def link vbStatement Statement +hi def link vbKeyword Statement +hi def link vbEvents Special +hi def link vbTodo Todo +hi def link vbTypes Type +hi def link vbTypeSpecifier Type + + +let b:current_syntax = "vb" + +" vim: ts=8 + +endif diff --git a/syntax/vera.vim b/syntax/vera.vim new file mode 100644 index 0000000..de7e28a --- /dev/null +++ b/syntax/vera.vim @@ -0,0 +1,352 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Vera +" Maintainer: Dave Eggum (opine at bluebottle dOt com) +" Last Change: 2005 Dec 19 + +" NOTE: extra white space at the end of the line will be highlighted if you +" add this line to your colorscheme: + +" highlight SpaceError guibg=#204050 + +" (change the value for guibg to any color you like) + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" A bunch of useful Vera keywords +syn keyword veraStatement break return continue fork join terminate +syn keyword veraStatement breakpoint proceed + +syn keyword veraLabel bad_state bad_trans bind constraint coverage_group +syn keyword veraLabel class CLOCK default function interface m_bad_state +syn keyword veraLabel m_bad_trans m_state m_trans program randseq state +syn keyword veraLabel task trans + +syn keyword veraConditional if else case casex casez randcase +syn keyword veraRepeat repeat while for do foreach +syn keyword veraModifier after all any around assoc_size async +syn keyword veraModifier before big_endian bit_normal bit_reverse export +syn keyword veraModifier extends extern little_endian local hdl_node hdl_task +syn keyword veraModifier negedge none packed protected posedge public rules +syn keyword veraModifier shadow soft static super this typedef unpacked var +syn keyword veraModifier vca virtual virtuals wildcard with + +syn keyword veraType reg string enum event bit +syn keyword veraType rand randc integer port prod + +syn keyword veraDeprecated call_func call_task close_conn get_bind get_bind_id +syn keyword veraDeprecated get_conn_err mailbox_receive mailbox_send make_client +syn keyword veraDeprecated make_server simwave_plot up_connections + +" predefined tasks and functions +syn keyword veraTask alloc assoc_index cast_assign cm_coverage +syn keyword veraTask cm_get_coverage cm_get_limit delay error error_mode +syn keyword veraTask exit fclose feof ferror fflush flag fopen fprintf +syn keyword veraTask freadb freadh freadstr get_cycle get_env get_memsize +syn keyword veraTask get_plus_arg getstate get_systime get_time get_time_unit +syn keyword veraTask initstate lock_file mailbox_get mailbox_put os_command +syn keyword veraTask printf prodget prodset psprintf query query_str query_x +syn keyword veraTask rand48 random region_enter region_exit rewind +syn keyword veraTask semaphore_get semaphore_put setstate signal_connect +syn keyword veraTask sprintf srandom sscanf stop suspend_thread sync +syn keyword veraTask timeout trace trigger unit_delay unlock_file urand48 +syn keyword veraTask urandom urandom_range vera_bit_reverse vera_crc +syn keyword veraTask vera_pack vera_pack_big_endian vera_plot +syn keyword veraTask vera_report_profile vera_unpack vera_unpack_big_endian +syn keyword veraTask vsv_call_func vsv_call_task vsv_get_conn_err +syn keyword veraTask vsv_make_client vsv_make_server vsv_up_connections +syn keyword veraTask vsv_wait_for_done vsv_wait_for_input wait_child wait_var + +syn cluster veraOperGroup contains=veraOperator,veraOperParen,veraNumber,veraString,veraOperOk,veraType +" syn match veraOperator "++\|--\|&\|\~&\||\|\~|\|^\|\~^\|\~\|><" +" syn match veraOperator "*\|/\|%\|+\|-\|<<\|>>\|<\|<=\|>\|>=\|!in" +" syn match veraOperator "=?=\|!?=\|==\|!=\|===\|!==\|&\~\|^\~\||\~" +" syn match veraOperator "&&\|||\|=\|+=\|-=\|*=\|/=\|%=\|<<=\|>>=\|&=" +" syn match veraOperator "|=\|^=\|\~&=\|\~|=\|\~^=" + +syn match veraOperator "[&|\~>" +" "hex number +" syn match veraNumber display contained "0x\x\+\(u\=l\{0,2}\|ll\=u\)\>" +" syn match veraNumber "\(\<[0-9]\+\|\)'[bdoh][0-9a-fxzA-FXZ_]\+\>" +syn match veraNumber "\<\(\<[0-9]\+\)\?\('[bdoh]\)\?[0-9a-fxz_]\+\>" +" syn match veraNumber "\<[+-]\=[0-9]\+\>" +" Flag the first zero of an octal number as something special +syn match veraOctal display contained "0\o\+\(u\=l\{0,2}\|ll\=u\)\>" contains=veraOctalZero +syn match veraOctalZero display contained "\<0" +syn match veraFloat display contained "\d\+f" +"floating point number, with dot, optional exponent +syn match veraFloat display contained "\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=" +"floating point number, starting with a dot, optional exponent +syn match veraFloat display contained "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +"floating point number, without dot, with exponent +syn match veraFloat display contained "\d\+e[-+]\=\d\+[fl]\=\>" +"hexadecimal floating point number, optional leading digits, with dot, with exponent +syn match veraFloat display contained "0x\x*\.\x\+p[-+]\=\d\+[fl]\=\>" +"hexadecimal floating point number, with leading digits, optional dot, with exponent +syn match veraFloat display contained "0x\x\+\.\=p[-+]\=\d\+[fl]\=\>" + +" flag an octal number with wrong digits +syn match veraOctalError display contained "0\o*[89]\d*" +syn case match + +let vera_comment_strings = 1 + +if exists("vera_comment_strings") + " A comment can contain veraString, veraCharacter and veraNumber. + " But a "*/" inside a veraString in a veraComment DOES end the comment! So we + " need to use a special type of veraString: veraCommentString, which also ends on + " "*/", and sees a "*" at the start of the line as comment again. + " Unfortunately this doesn't work very well for // type of comments :-( + syntax match veraCommentSkip contained "^\s*\*\($\|\s\+\)" + syntax region veraCommentString contained start=+L\=\\\@" + +syn match veraClass "\zs\w\+\ze::" +syn match veraClass "\zs\w\+\ze\s\+\w\+\s*[=;,)\[]" contains=veraConstant,veraUserConstant +syn match veraClass "\zs\w\+\ze\s\+\w\+\s*$" contains=veraConstant,veraUserConstant +syn match veraUserMethod "\zs\w\+\ze\s*(" contains=veraConstant,veraUserConstant +syn match veraObject "\zs\w\+\ze\.\w" +syn match veraObject "\zs\w\+\ze\.\$\w" + +" Accept ` for # (Verilog) +syn region veraPreCondit start="^\s*\(`\|#\)\s*\(if\|ifdef\|ifndef\|elif\)\>" skip="\\$" end="$" end="//"me=s-1 contains=veraComment,veraCppString,veraCharacter,veraCppParen,veraParenError,veraNumbers,veraCommentError,veraSpaceError +syn match veraPreCondit display "^\s*\(`\|#\)\s*\(else\|endif\)\>" +if !exists("vera_no_if0") + syn region veraCppOut start="^\s*\(`\|#\)\s*if\s\+0\+\>" end=".\@=\|$" contains=veraCppOut2 + syn region veraCppOut2 contained start="0" end="^\s*\(`\|#\)\s*\(endif\>\|else\>\|elif\>\)" contains=veraSpaceError,veraCppSkip + syn region veraCppSkip contained start="^\s*\(`\|#\)\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*\(`\|#\)\s*endif\>" contains=veraSpaceError,veraCppSkip +endif +syn region veraIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match veraIncluded display contained "<[^>]*>" +syn match veraInclude display "^\s*\(`\|#\)\s*include\>\s*["<]" contains=veraIncluded +"syn match veraLineSkip "\\$" +syn cluster veraPreProcGroup contains=veraPreCondit,veraIncluded,veraInclude,veraDefine,veraErrInParen,veraErrInBracket,veraUserLabel,veraSpecial,veraOctalZero,veraCppOut,veraCppOut2,veraCppSkip,veraFormat,veraNumber,veraFloat,veraOctal,veraOctalError,veraNumbersCom,veraString,veraCommentSkip,veraCommentString,veraComment2String,@veraCommentGroup,veraCommentStartError,veraParen,veraBracket,veraMulti +syn region veraDefine start="^\s*\(`\|#\)\s*\(define\|undef\)\>" skip="\\$" end="$" end="//"me=s-1 contains=ALLBUT,@veraPreProcGroup,@Spell +syn region veraPreProc start="^\s*\(`\|#\)\s*\(pragma\>\|line\>\|warning\>\|error\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@veraPreProcGroup,@Spell + +" Highlight User Labels +syn cluster veraMultiGroup contains=veraIncluded,veraSpecial,veraCommentSkip,veraCommentString,veraComment2String,@veraCommentGroup,veraCommentStartError,veraUserCont,veraUserLabel,veraBitField,veraOctalZero,veraCppOut,veraCppOut2,veraCppSkip,veraFormat,veraNumber,veraFloat,veraOctal,veraOctalError,veraNumbersCom,veraCppParen,veraCppBracket,veraCppString +syn region veraMulti transparent start='?' skip='::' end=':' contains=ALLBUT,@veraMultiGroup,@Spell +" syn region veraMulti transparent start='?' skip='::' end=':' contains=ALL +" The above causes veraCppOut2 to catch on: +" i = (isTrue) ? 0 : 1; +" which ends up commenting the rest of the file + +" Avoid matching foo::bar() by requiring that the next char is not ':' +syn cluster veraLabelGroup contains=veraUserLabel +syn match veraUserCont display "^\s*\I\i*\s*:$" contains=@veraLabelGroup +syn match veraUserCont display ";\s*\I\i*\s*:$" contains=@veraLabelGroup +syn match veraUserCont display "^\s*\I\i*\s*:[^:]"me=e-1 contains=@veraLabelGroup +syn match veraUserCont display ";\s*\I\i*\s*:[^:]"me=e-1 contains=@veraLabelGroup + +syn match veraUserLabel display "\I\i*" contained + +" Avoid recognizing most bitfields as labels +syn match veraBitField display "^\s*\I\i*\s*:\s*[1-9]"me=e-1 +syn match veraBitField display ";\s*\I\i*\s*:\s*[1-9]"me=e-1 + +if exists("vera_minlines") + let b:vera_minlines = vera_minlines +else + if !exists("vera_no_if0") + let b:vera_minlines = 50 " #if 0 constructs can be long + else + let b:vera_minlines = 15 " mostly for () constructs + endif +endif +exec "syn sync ccomment veraComment minlines=" . b:vera_minlines + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link veraClass Identifier +hi def link veraObject Identifier +hi def link veraUserMethod Function +hi def link veraTask Keyword +hi def link veraModifier Tag +hi def link veraDeprecated veraError +hi def link veraMethods Statement +" hi def link veraInterface Label +hi def link veraInterface Function + +hi def link veraFormat veraSpecial +hi def link veraCppString veraString +hi def link veraCommentL veraComment +hi def link veraCommentStart veraComment +hi def link veraLabel Label +hi def link veraUserLabel Label +hi def link veraConditional Conditional +hi def link veraRepeat Repeat +hi def link veraCharacter Character +hi def link veraSpecialCharacter veraSpecial +hi def link veraNumber Number +hi def link veraOctal Number +hi def link veraOctalZero PreProc " link this to Error if you want +hi def link veraFloat Float +hi def link veraOctalError veraError +hi def link veraParenError veraError +hi def link veraErrInParen veraError +hi def link veraErrInBracket veraError +hi def link veraCommentError veraError +hi def link veraCommentStartError veraError +hi def link veraSpaceError SpaceError +hi def link veraSpecialError veraError +hi def link veraOperator Operator +hi def link veraStructure Structure +hi def link veraInclude Include +hi def link veraPreProc PreProc +hi def link veraDefine Macro +hi def link veraIncluded veraString +hi def link veraError Error +hi def link veraStatement Statement +hi def link veraPreCondit PreCondit +hi def link veraType Type +" hi def link veraConstant Constant +hi def link veraConstant Keyword +hi def link veraUserConstant Constant +hi def link veraCommentString veraString +hi def link veraComment2String veraString +hi def link veraCommentSkip veraComment +hi def link veraString String +hi def link veraComment Comment +hi def link veraSpecial SpecialChar +hi def link veraTodo Todo +hi def link veraCppSkip veraCppOut +hi def link veraCppOut2 veraCppOut +hi def link veraCppOut Comment + + +let b:current_syntax = "vera" + +" vim: ts=8 + +endif diff --git a/syntax/verilog.vim b/syntax/verilog.vim new file mode 100644 index 0000000..fafc5f3 --- /dev/null +++ b/syntax/verilog.vim @@ -0,0 +1,123 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Verilog +" Maintainer: Mun Johl +" Last Update: Wed Jul 20 16:04:19 PDT 2011 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Set the local value of the 'iskeyword' option. +" NOTE: '?' was added so that verilogNumber would be processed correctly when +" '?' is the last character of the number. +setlocal iskeyword=@,48-57,63,_,192-255 + +" A bunch of useful Verilog keywords + +syn keyword verilogStatement always and assign automatic buf +syn keyword verilogStatement bufif0 bufif1 cell cmos +syn keyword verilogStatement config deassign defparam design +syn keyword verilogStatement disable edge endconfig +syn keyword verilogStatement endfunction endgenerate endmodule +syn keyword verilogStatement endprimitive endspecify endtable endtask +syn keyword verilogStatement event force function +syn keyword verilogStatement generate genvar highz0 highz1 ifnone +syn keyword verilogStatement incdir include initial inout input +syn keyword verilogStatement instance integer large liblist +syn keyword verilogStatement library localparam macromodule medium +syn keyword verilogStatement module nand negedge nmos nor +syn keyword verilogStatement noshowcancelled not notif0 notif1 or +syn keyword verilogStatement output parameter pmos posedge primitive +syn keyword verilogStatement pull0 pull1 pulldown pullup +syn keyword verilogStatement pulsestyle_onevent pulsestyle_ondetect +syn keyword verilogStatement rcmos real realtime reg release +syn keyword verilogStatement rnmos rpmos rtran rtranif0 rtranif1 +syn keyword verilogStatement scalared showcancelled signed small +syn keyword verilogStatement specify specparam strong0 strong1 +syn keyword verilogStatement supply0 supply1 table task time tran +syn keyword verilogStatement tranif0 tranif1 tri tri0 tri1 triand +syn keyword verilogStatement trior trireg unsigned use vectored wait +syn keyword verilogStatement wand weak0 weak1 wire wor xnor xor +syn keyword verilogLabel begin end fork join +syn keyword verilogConditional if else case casex casez default endcase +syn keyword verilogRepeat forever repeat while for + +syn keyword verilogTodo contained TODO FIXME + +syn match verilogOperator "[&|~>" +syn match verilogGlobal "`celldefine" +syn match verilogGlobal "`default_nettype" +syn match verilogGlobal "`define" +syn match verilogGlobal "`else" +syn match verilogGlobal "`elsif" +syn match verilogGlobal "`endcelldefine" +syn match verilogGlobal "`endif" +syn match verilogGlobal "`ifdef" +syn match verilogGlobal "`ifndef" +syn match verilogGlobal "`include" +syn match verilogGlobal "`line" +syn match verilogGlobal "`nounconnected_drive" +syn match verilogGlobal "`resetall" +syn match verilogGlobal "`timescale" +syn match verilogGlobal "`unconnected_drive" +syn match verilogGlobal "`undef" +syn match verilogGlobal "$[a-zA-Z0-9_]\+\>" + +syn match verilogConstant "\<[A-Z][A-Z0-9_]\+\>" + +syn match verilogNumber "\(\<\d\+\|\)'[sS]\?[bB]\s*[0-1_xXzZ?]\+\>" +syn match verilogNumber "\(\<\d\+\|\)'[sS]\?[oO]\s*[0-7_xXzZ?]\+\>" +syn match verilogNumber "\(\<\d\+\|\)'[sS]\?[dD]\s*[0-9_xXzZ?]\+\>" +syn match verilogNumber "\(\<\d\+\|\)'[sS]\?[hH]\s*[0-9a-fA-F_xXzZ?]\+\>" +syn match verilogNumber "\<[+-]\=[0-9_]\+\(\.[0-9_]*\|\)\(e[0-9_]*\|\)\>" + +syn region verilogString start=+"+ skip=+\\"+ end=+"+ contains=verilogEscape,@Spell +syn match verilogEscape +\\[nt"\\]+ contained +syn match verilogEscape "\\\o\o\=\o\=" contained + +" Directives +syn match verilogDirective "//\s*synopsys\>.*$" +syn region verilogDirective start="/\*\s*synopsys\>" end="\*/" +syn region verilogDirective start="//\s*synopsys dc_script_begin\>" end="//\s*synopsys dc_script_end\>" + +syn match verilogDirective "//\s*\$s\>.*$" +syn region verilogDirective start="/\*\s*\$s\>" end="\*/" +syn region verilogDirective start="//\s*\$s dc_script_begin\>" end="//\s*\$s dc_script_end\>" + +"Modify the following as needed. The trade-off is performance versus +"functionality. +syn sync minlines=50 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default highlighting. +hi def link verilogCharacter Character +hi def link verilogConditional Conditional +hi def link verilogRepeat Repeat +hi def link verilogString String +hi def link verilogTodo Todo +hi def link verilogComment Comment +hi def link verilogConstant Constant +hi def link verilogLabel Label +hi def link verilogNumber Number +hi def link verilogOperator Special +hi def link verilogStatement Statement +hi def link verilogGlobal Define +hi def link verilogDirective SpecialComment +hi def link verilogEscape Special + + +let b:current_syntax = "verilog" + +" vim: ts=8 + +endif diff --git a/syntax/verilogams.vim b/syntax/verilogams.vim new file mode 100644 index 0000000..a471eb6 --- /dev/null +++ b/syntax/verilogams.vim @@ -0,0 +1,136 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Verilog-AMS +" Maintainer: S. Myles Prather +" +" Version 1.1 S. Myles Prather +" Moved some keywords to the type category. +" Added the metrix suffixes to the number matcher. +" Version 1.2 Prasanna Tamhankar +" Minor reserved keyword updates. +" Last Update: Thursday September 15 15:36:03 CST 2005 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Set the local value of the 'iskeyword' option +setlocal iskeyword=@,48-57,_,192-255 + +" Annex B.1 'All keywords' +syn keyword verilogamsStatement above abs absdelay acos acosh ac_stim +syn keyword verilogamsStatement always analog analysis and asin +syn keyword verilogamsStatement asinh assign atan atan2 atanh +syn keyword verilogamsStatement buf bufif0 bufif1 ceil cmos connectmodule +syn keyword verilogamsStatement connectrules cos cosh cross ddt ddx deassign +syn keyword verilogamsStatement defparam disable discipline +syn keyword verilogamsStatement driver_update edge enddiscipline +syn keyword verilogamsStatement endconnectrules endmodule endfunction endgenerate +syn keyword verilogamsStatement endnature endparamset endprimitive endspecify +syn keyword verilogamsStatement endtable endtask event exp final_step +syn keyword verilogamsStatement flicker_noise floor flow force fork +syn keyword verilogamsStatement function generate highz0 +syn keyword verilogamsStatement highz1 hypot idt idtmod if ifnone inf initial +syn keyword verilogamsStatement initial_step inout input join +syn keyword verilogamsStatement laplace_nd laplace_np laplace_zd laplace_zp +syn keyword verilogamsStatement large last_crossing limexp ln localparam log +syn keyword verilogamsStatement macromodule max medium min module nand nature +syn keyword verilogamsStatement negedge net_resolution nmos noise_table nor not +syn keyword verilogamsStatement notif0 notif1 or output paramset pmos +syn keyword verilogamsType parameter real integer electrical input output +syn keyword verilogamsType inout reg tri tri0 tri1 triand trior trireg +syn keyword verilogamsType string from exclude aliasparam ground genvar +syn keyword verilogamsType branch time realtime +syn keyword verilogamsStatement posedge potential pow primitive pull0 pull1 +syn keyword verilogamsStatement pullup pulldown rcmos release +syn keyword verilogamsStatement rnmos rpmos rtran rtranif0 rtranif1 +syn keyword verilogamsStatement scalared sin sinh slew small specify specparam +syn keyword verilogamsStatement sqrt strong0 strong1 supply0 supply1 +syn keyword verilogamsStatement table tan tanh task timer tran tranif0 +syn keyword verilogamsStatement tranif1 transition +syn keyword verilogamsStatement vectored wait wand weak0 weak1 +syn keyword verilogamsStatement white_noise wire wor wreal xnor xor zi_nd +syn keyword verilogamsStatement zi_np zi_zd zi_zp +syn keyword verilogamsRepeat forever repeat while for +syn keyword verilogamsLabel begin end +syn keyword verilogamsConditional if else case casex casez default endcase +syn match verilogamsConstant ":inf"lc=1 +syn match verilogamsConstant "-inf"lc=1 +" Annex B.2 Discipline/nature +syn keyword verilogamsStatement abstol access continuous ddt_nature discrete +syn keyword verilogamsStatement domain idt_nature units +" Annex B.3 Connect Rules +syn keyword verilogamsStatement connect merged resolveto split + +syn match verilogamsOperator "[&|~>" + +syn match verilogamsConstant "\<[A-Z][A-Z0-9_]\+\>" + +syn match verilogamsNumber "\(\<\d\+\|\)'[bB]\s*[0-1_xXzZ?]\+\>" +syn match verilogamsNumber "\(\<\d\+\|\)'[oO]\s*[0-7_xXzZ?]\+\>" +syn match verilogamsNumber "\(\<\d\+\|\)'[dD]\s*[0-9_xXzZ?]\+\>" +syn match verilogamsNumber "\(\<\d\+\|\)'[hH]\s*[0-9a-fA-F_xXzZ?]\+\>" +syn match verilogamsNumber "\<[+-]\=[0-9_]\+\(\.[0-9_]*\|\)\(e[0-9_]*\|\)[TGMKkmunpfa]\=\>" + +syn region verilogamsString start=+"+ skip=+\\"+ end=+"+ contains=verilogamsEscape +syn match verilogamsEscape +\\[nt"\\]+ contained +syn match verilogamsEscape "\\\o\o\=\o\=" contained + +"Modify the following as needed. The trade-off is performance versus +"functionality. +syn sync lines=50 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default highlighting. +hi def link verilogamsCharacter Character +hi def link verilogamsConditional Conditional +hi def link verilogamsRepeat Repeat +hi def link verilogamsString String +hi def link verilogamsTodo Todo +hi def link verilogamsComment Comment +hi def link verilogamsConstant Constant +hi def link verilogamsLabel Label +hi def link verilogamsNumber Number +hi def link verilogamsOperator Special +hi def link verilogamsStatement Statement +hi def link verilogamsGlobal Define +hi def link verilogamsDirective SpecialComment +hi def link verilogamsEscape Special +hi def link verilogamsType Type +hi def link verilogamsSystask Function + + +let b:current_syntax = "verilogams" + +" vim: ts=8 + +endif diff --git a/syntax/vgrindefs.vim b/syntax/vgrindefs.vim new file mode 100644 index 0000000..ebd9f25 --- /dev/null +++ b/syntax/vgrindefs.vim @@ -0,0 +1,49 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Vgrindefs +" Maintainer: Bram Moolenaar +" Last Change: 2005 Jun 20 + +" The Vgrindefs file is used to specify a language for vgrind + +" Quit when a (custom) syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Comments +syn match vgrindefsComment "^#.*" + +" The fields that vgrind recognizes +syn match vgrindefsField ":ab=" +syn match vgrindefsField ":ae=" +syn match vgrindefsField ":pb=" +syn match vgrindefsField ":bb=" +syn match vgrindefsField ":be=" +syn match vgrindefsField ":cb=" +syn match vgrindefsField ":ce=" +syn match vgrindefsField ":sb=" +syn match vgrindefsField ":se=" +syn match vgrindefsField ":lb=" +syn match vgrindefsField ":le=" +syn match vgrindefsField ":nc=" +syn match vgrindefsField ":tl" +syn match vgrindefsField ":oc" +syn match vgrindefsField ":kw=" + +" Also find the ':' at the end of the line, so all ':' are highlighted +syn match vgrindefsField ":\\$" +syn match vgrindefsField ":$" +syn match vgrindefsField "\\$" + +" Define the default highlighting. +" Only used when an item doesn't have highlighting yet +hi def link vgrindefsField Statement +hi def link vgrindefsComment Comment + +let b:current_syntax = "vgrindefs" + +" vim: ts=8 + +endif diff --git a/syntax/vhdl.vim b/syntax/vhdl.vim new file mode 100644 index 0000000..bb46936 --- /dev/null +++ b/syntax/vhdl.vim @@ -0,0 +1,264 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: VHDL [VHSIC (Very High Speed Integrated Circuit) Hardware Description Language] +" Maintainer: Daniel Kho +" Previous Maintainer: Czo +" Credits: Stephan Hegel +" Last Changed: 2016 Mar 05 by Daniel Kho + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" case is not significant +syn case ignore + +" VHDL keywords +syn keyword vhdlStatement access after alias all assert +syn keyword vhdlStatement architecture array attribute +syn keyword vhdlStatement assume assume_guarantee +syn keyword vhdlStatement begin block body buffer bus +syn keyword vhdlStatement case component configuration constant +syn keyword vhdlStatement context cover +syn keyword vhdlStatement default disconnect downto +syn keyword vhdlStatement elsif end entity exit +syn keyword vhdlStatement file for function +syn keyword vhdlStatement fairness force +syn keyword vhdlStatement generate generic group guarded +syn keyword vhdlStatement impure in inertial inout is +syn keyword vhdlStatement label library linkage literal loop +syn keyword vhdlStatement map +syn keyword vhdlStatement new next null +syn keyword vhdlStatement of on open others out +syn keyword vhdlStatement package port postponed procedure process pure +syn keyword vhdlStatement parameter property protected +syn keyword vhdlStatement range record register reject report return +syn keyword vhdlStatement release restrict restrict_guarantee +syn keyword vhdlStatement select severity signal shared +syn keyword vhdlStatement subtype +syn keyword vhdlStatement sequence strong +syn keyword vhdlStatement then to transport type +syn keyword vhdlStatement unaffected units until use +syn keyword vhdlStatement variable +syn keyword vhdlStatement vmode vprop vunit +syn keyword vhdlStatement wait when while with +syn keyword vhdlStatement note warning error failure + +" Linting of conditionals. +syn match vhdlStatement "\<\(if\|else\)\>" +syn match vhdlError "\" + +" Types and type qualifiers +" Predefined standard VHDL types +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" + +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" + +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +"syn keyword vhdlType severity_level +syn keyword vhdlType line +syn keyword vhdlType text + +" Predefined standard IEEE VHDL types +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" +syn match vhdlType "\\'\=" + + +" array attributes +syn match vhdlAttribute "\'high" +syn match vhdlAttribute "\'left" +syn match vhdlAttribute "\'length" +syn match vhdlAttribute "\'low" +syn match vhdlAttribute "\'range" +syn match vhdlAttribute "\'reverse_range" +syn match vhdlAttribute "\'right" +syn match vhdlAttribute "\'ascending" +" block attributes +syn match vhdlAttribute "\'simple_name" +syn match vhdlAttribute "\'instance_name" +syn match vhdlAttribute "\'path_name" +syn match vhdlAttribute "\'foreign" " VHPI +" signal attribute +syn match vhdlAttribute "\'active" +syn match vhdlAttribute "\'delayed" +syn match vhdlAttribute "\'event" +syn match vhdlAttribute "\'last_active" +syn match vhdlAttribute "\'last_event" +syn match vhdlAttribute "\'last_value" +syn match vhdlAttribute "\'quiet" +syn match vhdlAttribute "\'stable" +syn match vhdlAttribute "\'transaction" +syn match vhdlAttribute "\'driving" +syn match vhdlAttribute "\'driving_value" +" type attributes +syn match vhdlAttribute "\'base" +syn match vhdlAttribute "\'subtype" +syn match vhdlAttribute "\'element" +syn match vhdlAttribute "\'leftof" +syn match vhdlAttribute "\'pos" +syn match vhdlAttribute "\'pred" +syn match vhdlAttribute "\'rightof" +syn match vhdlAttribute "\'succ" +syn match vhdlAttribute "\'val" +syn match vhdlAttribute "\'image" +syn match vhdlAttribute "\'value" + +syn keyword vhdlBoolean true false + +" for this vector values case is significant +syn case match +" Values for standard VHDL types +syn match vhdlVector "\'[0L1HXWZU\-\?]\'" +syn case ignore + +syn match vhdlVector "B\"[01_]\+\"" +syn match vhdlVector "O\"[0-7_]\+\"" +syn match vhdlVector "X\"[0-9a-f_]\+\"" +syn match vhdlCharacter "'.'" +syn region vhdlString start=+"+ end=+"+ + +" floating numbers +syn match vhdlNumber "-\=\<\d\+\.\d\+\(E[+\-]\=\d\+\)\>" +syn match vhdlNumber "-\=\<\d\+\.\d\+\>" +syn match vhdlNumber "0*2#[01_]\+\.[01_]\+#\(E[+\-]\=\d\+\)\=" +syn match vhdlNumber "0*16#[0-9a-f_]\+\.[0-9a-f_]\+#\(E[+\-]\=\d\+\)\=" +" integer numbers +syn match vhdlNumber "-\=\<\d\+\(E[+\-]\=\d\+\)\>" +syn match vhdlNumber "-\=\<\d\+\>" +syn match vhdlNumber "0*2#[01_]\+#\(E[+\-]\=\d\+\)\=" +syn match vhdlNumber "0*16#[0-9a-f_]\+#\(E[+\-]\=\d\+\)\=" + +" operators +syn keyword vhdlOperator and nand or nor xor xnor +syn keyword vhdlOperator rol ror sla sll sra srl +syn keyword vhdlOperator mod rem abs not + +" Concatenation and math operators +syn match vhdlOperator "&\|+\|-\|\*\|\/" + +" Equality and comparison operators +syn match vhdlOperator "=\|\/=\|>\|<\|>=" + +" Assignment operators +syn match vhdlOperator "<=\|:=" +syn match vhdlOperator "=>" + +" VHDL-2008 conversion, matching equality/non-equality operators +syn match vhdlOperator "??\|?=\|?\/=\|?<\|?<=\|?>\|?>=" + +" VHDL-2008 external names +syn match vhdlOperator "<<\|>>" + +" Linting for illegal operators +" '=' +syn match vhdlError "\(=\)[<=&+\-\*\/\\]\+" +syn match vhdlError "[=&+\-\*\\]\+\(=\)" +" '>', '<' +" Allow external names: '<< ... >>' +syn match vhdlError "\(>\)[<&+\-\/\\]\+" +syn match vhdlError "[&+\-\/\\]\+\(>\)" +syn match vhdlError "\(<\)[&+\-\/\\]\+" +syn match vhdlError "[>=&+\-\/\\]\+\(<\)" +" Covers most operators +" support negative sign after operators. E.g. q<=-b; +syn match vhdlError "\(&\|+\|\-\|\*\*\|\/=\|??\|?=\|?\/=\|?<=\|?>=\|>=\|<=\|:=\|=>\)[<>=&+\*\\?:]\+" +syn match vhdlError "[<>=&+\-\*\\:]\+\(&\|+\|\*\*\|\/=\|??\|?=\|?\/=\|?<\|?<=\|?>\|?>=\|>=\|<=\|:=\|=>\)" +syn match vhdlError "\(?<\|?>\)[<>&+\*\/\\?:]\+" +syn match vhdlError "\(<<\|>>\)[<>&+\*\/\\?:]\+" + +"syn match vhdlError "[?]\+\(&\|+\|\-\|\*\*\|??\|?=\|?\/=\|?<\|?<=\|?>\|?>=\|:=\|=>\)" +" '/' +syn match vhdlError "\(\/\)[<>&+\-\*\/\\?:]\+" +syn match vhdlError "[<>=&+\-\*\/\\:]\+\(\/\)" + +syn match vhdlSpecial "<>" +syn match vhdlSpecial "[().,;]" + + +" time +syn match vhdlTime "\<\d\+\s\+\(\([fpnum]s\)\|\(sec\)\|\(min\)\|\(hr\)\)\>" +syn match vhdlTime "\<\d\+\.\d\+\s\+\(\([fpnum]s\)\|\(sec\)\|\(min\)\|\(hr\)\)\>" + +syn case match +syn keyword vhdlTodo contained TODO NOTE +syn keyword vhdlFixme contained FIXME +syn case ignore + +syn region vhdlComment start="/\*" end="\*/" contains=vhdlTodo,vhdlFixme,@Spell +syn match vhdlComment "\(^\|\s\)--.*" contains=vhdlTodo,vhdlFixme,@Spell + +" Standard IEEE P1076.6 preprocessor directives (metacomments). +syn match vhdlPreProc "/\*\s*rtl_synthesis\s\+\(on\|off\)\s*\*/" +syn match vhdlPreProc "\(^\|\s\)--\s*rtl_synthesis\s\+\(on\|off\)\s*" +syn match vhdlPreProc "/\*\s*rtl_syn\s\+\(on\|off\)\s*\*/" +syn match vhdlPreProc "\(^\|\s\)--\s*rtl_syn\s\+\(on\|off\)\s*" + +" Industry-standard directives. These are not standard VHDL, but are commonly +" used in the industry. +syn match vhdlPreProc "/\*\s*synthesis\s\+translate_\(on\|off\)\s*\*/" +"syn match vhdlPreProc "/\*\s*simulation\s\+translate_\(on\|off\)\s*\*/" +syn match vhdlPreProc "/\*\s*pragma\s\+translate_\(on\|off\)\s*\*/" +syn match vhdlPreProc "/\*\s*pragma\s\+synthesis_\(on\|off\)\s*\*/" +syn match vhdlPreProc "/\*\s*synopsys\s\+translate_\(on\|off\)\s*\*/" + +syn match vhdlPreProc "\(^\|\s\)--\s*synthesis\s\+translate_\(on\|off\)\s*" +"syn match vhdlPreProc "\(^\|\s\)--\s*simulation\s\+translate_\(on\|off\)\s*" +syn match vhdlPreProc "\(^\|\s\)--\s*pragma\s\+translate_\(on\|off\)\s*" +syn match vhdlPreProc "\(^\|\s\)--\s*pragma\s\+synthesis_\(on\|off\)\s*" +syn match vhdlPreProc "\(^\|\s\)--\s*synopsys\s\+translate_\(on\|off\)\s*" + +"Modify the following as needed. The trade-off is performance versus functionality. +syn sync minlines=600 + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link vhdlSpecial Special +hi def link vhdlStatement Statement +hi def link vhdlCharacter Character +hi def link vhdlString String +hi def link vhdlVector Number +hi def link vhdlBoolean Number +hi def link vhdlTodo Todo +hi def link vhdlFixme Fixme +hi def link vhdlComment Comment +hi def link vhdlNumber Number +hi def link vhdlTime Number +hi def link vhdlType Type +hi def link vhdlOperator Operator +hi def link vhdlError Error +hi def link vhdlAttribute Special +hi def link vhdlPreProc PreProc + + +let b:current_syntax = "vhdl" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8 + +endif diff --git a/syntax/vim.vim b/syntax/vim.vim new file mode 100644 index 0000000..1d40f1c --- /dev/null +++ b/syntax/vim.vim @@ -0,0 +1,981 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Vim 8.0 script +" Maintainer: Charles E. Campbell +" Last Change: Jan 19, 2017 +" Version: 8.0-02 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_VIM +" Automatically generated keyword lists: {{{1 + +" Quit when a syntax file was already loaded {{{2 +if exists("b:current_syntax") + finish +endif +let s:keepcpo= &cpo +set cpo&vim + +" vimTodo: contains common special-notices for comments {{{2 +" Use the vimCommentGroup cluster to add your own. +syn keyword vimTodo contained COMBAK FIXME TODO XXX +syn cluster vimCommentGroup contains=vimTodo,@Spell + +" regular vim commands {{{2 +syn keyword vimCommand contained a argd[elete] as[cii] bd[elete] bo[tright] breakl[ist] cN[ext] caddf[ile] ccl[ose] cfdo chd[ir] cle[arjumps] co[py] con[tinue] cr[ewind] d[elete] deletel delm[arks] diffo[ff] dir dp earlier em[enu] ene[w] filet fir[st] foldo[pen] grepa[dd] helpf[ind] i in ju[mps] keepp[atterns] lad[dexpr] later lcl[ose] lefta[bove] lg[etfile] lh[elpgrep] lmak[e] lo[adview] lol[der] ls lv[imgrep] mak[e] messages mkvie[w] nb[key] noa nos[wapfile] on[ly] packl[oadall] po[p] pro ps[earch] ptl[ast] pu[t] pydo quita[ll] redr[aw] retu[rn] rub[y] sI sIn sal[l] sba[ll] sbp[revious] scg scripte[ncoding] setg[lobal] sgI sgn sic sim[alt] sla[st] smile so[urce] spelli[nfo] sr sri sta[g] stopi[nsert] sus[pend] sync ta[g] tabe[dit] tabn[ext] tabs te[aroff] tm[enu] try undoj[oin] up[date] vi[sual] vmapc[lear] wa[ll] winp[os] ws[verb] xmapc[lear] xprop +syn keyword vimCommand contained abc[lear] argdo au bel[owright] bp[revious] bro[wse] cNf[ile] cal[l] cd cfir[st] che[ckpath] clo[se] col[der] conf[irm] cs debug deletep delp diffp[atch] dj[ump] dr[op] echoe[rr] en[dif] ex filetype fix[del] for gui helpg[rep] iabc[lear] intro k lN[ext] laddb[uffer] lb[uffer] lcs lex[pr] lgetb[uffer] lhi[story] lmapc[lear] loadk lop[en] lt[ag] lvimgrepa[dd] marks mk[exrc] mod[e] nbc[lose] noautocmd nu[mber] opt[ions] pc[lose] popu[p] prof[ile] ptN[ext] ptn[ext] pw[d] pyf[ile] r[ead] redraws[tatus] rew[ind] rubyd[o] sIc sIp san[dbox] sbf[irst] sbr[ewind] sci scs setl[ocal] sgc sgp sie sin sm[agic] sn[ext] sor[t] spellr[epall] srI srl star[tinsert] sts[elect] sv[iew] syncbind tab tabf[ind] tabnew tags tf[irst] tn[ext] ts[elect] undol[ist] v vie[w] vne[w] wh[ile] wn[ext] wundo xme xunme +syn keyword vimCommand contained abo[veleft] arge[dit] bN[ext] bf[irst] br[ewind] bufdo c[hange] cat[ch] cdo cg[etfile] checkt[ime] cmapc[lear] colo[rscheme] cope[n] cscope debugg[reedy] deletl dep diffpu[t] dl ds[earch] echom[sg] endf[unction] exi[t] filt[er] fo[ld] fu[nction] gvim helpt[ags] if is[earch] kee[pmarks] lNf[ile] laddf[ile] lbo[ttom] lcscope lf[ile] lgete[xpr] ll lne[xt] loadkeymap lp[revious] lua lw[indow] mat[ch] mks[ession] mz[scheme] nbs[tart] noh[lsearch] o[pen] ownsyntax pe[rl] pp[op] profd[el] pta[g] ptp[revious] py3 python3 rec[over] reg[isters] ri[ght] rubyf[ile] sIe sIr sav[eas] sbl[ast] sc scl scscope sf[ind] sge sgr sig sip sm[ap] sno[magic] sp[lit] spellu[ndo] src srn startg[replace] sun[hide] sw[apname] syntime tabN[ext] tabfir[st] tabo[nly] tc[l] th[row] to[pleft] tu[nmenu] unh[ide] ve[rsion] vim[grep] vs[plit] win[size] wp[revious] wv[iminfo] xmenu xunmenu +syn keyword vimCommand contained al[l] argg[lobal] b[uffer] bl[ast] brea[k] buffers cabc[lear] cb[uffer] ce[nter] cgetb[uffer] chi[story] cn[ext] com cp[revious] cstag delc[ommand] deletp di[splay] diffs[plit] dli[st] dsp[lit] echon endfo[r] exu[sage] fin[d] foldc[lose] g h[elp] hi ij[ump] isp[lit] keepa l[ist] lan[guage] lc[d] ld[o] lfdo lgr[ep] lla[st] lnew[er] loc[kmarks] lpf[ile] luado m[ove] menut[ranslate] mksp[ell] mzf[ile] new nor ol[dfiles] p[rint] ped[it] pre[serve] promptf[ind] ptf[irst] ptr[ewind] py3do q[uit] red[o] res[ize] rightb[elow] rundo sIg sN[ext] sbN[ext] sbm[odified] scI scp se[t] sfir[st] sgi sh[ell] sign sir sme snoreme spe[llgood] spellw[rong] sre[wind] srp startr[eplace] sunme sy t tabc[lose] tabl[ast] tabp[revious] tcld[o] tj[ump] tp[revious] u[ndo] unlo[ckvar] verb[ose] vimgrepa[dd] wN[ext] winc[md] wq x[it] xnoreme xwininfo +syn keyword vimCommand contained ar[gs] argl[ocal] ba[ll] bm[odified] breaka[dd] bun[load] cad[dbuffer] cbo[ttom] cex[pr] cgete[xpr] cl[ist] cnew[er] comc[lear] cpf[ile] cuna[bbrev] delel delf[unction] dif[fupdate] difft[his] do e[dit] el[se] endt[ry] f[ile] fina[lly] foldd[oopen] go[to] ha[rdcopy] hid[e] il[ist] iuna[bbrev] keepalt la[st] lat lch[dir] le[ft] lfir[st] lgrepa[dd] lli[st] lnf[ile] lockv[ar] lr[ewind] luafile ma[rk] mes mkv[imrc] n[ext] nmapc[lear] nore omapc[lear] pa[ckadd] perld[o] prev[ious] promptr[epl] ptj[ump] pts[elect] py[thon] qa[ll] redi[r] ret[ab] ru[ntime] rv[iminfo] sIl sa[rgument] sb[uffer] sbn[ext] sce scr[iptnames] setf[iletype] sg sgl si sil[ent] sl[eep] smenu snoremenu spelld[ump] spr[evious] srg st[op] stj[ump] sunmenu syn tN[ext] tabd[o] tabm[ove] tabr[ewind] tclf[ile] tl[ast] tr[ewind] una[bbreviate] uns[ilent] vert[ical] viu[sage] w[rite] windo wqa[ll] xa[ll] xnoremenu y[ank] +syn keyword vimCommand contained arga[dd] argu[ment] bad[d] bn[ext] breakd[el] bw[ipeout] cadde[xpr] cc cf[ile] changes cla[st] cnf[ile] comp[iler] cq[uit] cw[indow] delep dell diffg[et] dig[raphs] doau ea elsei[f] endw[hile] files fini[sh] folddoc[losed] gr[ep] helpc[lose] his[tory] imapc[lear] j[oin] keepj[umps] +syn match vimCommand contained "\" +syn keyword vimStdPlugin contained DiffOrig Man N[ext] P[rint] S TOhtml XMLent XMLns + +" vimOptions are caught only when contained in a vimSet {{{2 +syn keyword vimOption contained acd ambw arshape background ballooneval bg bomb bs cb ch cinoptions cms commentstring copyindent cscopepathcomp csprg cursorbind delcombine digraph eadirection ek ep et fdc fdo ffs filetype fml foldignore foldopen fs gfn grepprg guiheadroom helplang history hls imactivatefunc imdisable inc indk isfname joinspaces kmp lazyredraw lispwords lpl ma matchtime mco ml modeline mousefocus mousetime nrformats ofu packpath path ph pp printfont pumheight rdt renderoptions rl ru sbo scrollbind secure shcf shelltemp shortmess showtabline sj smd spell splitbelow ssl stl sw sxe tabpagemax tags tbs termguicolors tgst titleold top ttimeoutlen ttyscroll ul ur verbosefile visualbell wcm wi wildmenu winfixwidth wm wrapscan +syn keyword vimOption contained ai anti autochdir backspace balloonexpr bh breakat bsdir cc charconvert cinw co compatible cot cscopeprg csqf cursorcolumn dex dip eb emo equalalways eventignore fde fdt fic fillchars fmr foldlevel foldtext fsync gfs gtl guioptions hf hk hlsearch imactivatekey imi include inex isi js kp lbr list lrm macatsui maxcombine mef mls modelines mousehide mp nu omnifunc para pdev pheader preserveindent printheader pvh re report rlc rubydll sbr scrolljump sel shell shelltype shortname shq slm sn spellcapcheck splitright ssop stmp swapfile sxq tabstop tagstack tc terse thesaurus titlestring tpm ttm ttytype undodir ut vfile vop wd wic wildmode winheight wmh write +syn keyword vimOption contained akm antialias autoindent backup bdir bin breakindent bsk ccv ci cinwords cocu complete cp cscopequickfix csre cursorline dg dir ed emoji equalprg ex fdi fen fileencoding fixendofline fo foldlevelstart formatexpr ft gfw gtt guipty hh hkmap ic imaf iminsert includeexpr inf isident key langmap lcs listchars ls magic maxfuncdepth menuitems mm modifiable mousem mps number opendevice paragraphs penc pi previewheight printmbcharset pvw readonly restorescreen rnu ruf sc scrolloff selection shellcmdflag shellxescape showbreak si sm so spellfile spr st sts swapsync syn tag tal tcldll textauto tildeop tl tr tty tw undofile vb vi wa weirdinvert wig wildoptions winminheight wmnu writeany +syn keyword vimOption contained al ar autoread backupcopy bdlay binary breakindentopt bt cd cin clipboard cole completefunc cpo cscoperelative cst cwh dict directory edcompatible enc errorbells expandtab fdl fenc fileencodings fixeol foldclose foldmarker formatlistpat gcr ghr guicursor guitablabel hi hkmapp icon imak ims incsearch infercase isk keymap langmenu linebreak lm lsp makeef maxmapdepth mfd mmd modified mousemodel msm numberwidth operatorfunc paste perldll pm previewwindow printmbfont pythondll redrawtime revins ro ruler scb scrollopt selectmode shellpipe shellxquote showcmd sidescroll smartcase softtabstop spelllang sps sta su swb synmaxcol tagbsearch tb tenc textmode timeout tm ts ttybuiltin tx undolevels vbs viewdir wak wfh wildchar wim winminwidth wmw writebackup +syn keyword vimOption contained aleph arab autowrite backupdir belloff bk bri bufhidden cdpath cindent cm colorcolumn completeopt cpoptions cscopetag csto debug dictionary display ef encoding errorfile exrc fdls fencs fileformat fk foldcolumn foldmethod formatoptions gd go guifont guitabtooltip hid hkp iconstring imc imsearch inde insertmode iskeyword keymodel langnoremap lines lmap luadll makeprg maxmem mh mmp more mouses mzq nuw opfunc pastetoggle pex pmbcs printdevice printoptions pythonthreedll regexpengine ri rop rulerformat scl scs sessionoptions shellquote shiftround showfulltag sidescrolloff smartindent sol spellsuggest sr stal sua swf syntax tagcase tbi term textwidth timeoutlen to tsl ttyfast uc undoreload vdir viewoptions warn wfw wildcharm winaltkeys winwidth wop writedelay +syn keyword vimOption contained allowrevins arabic autowriteall backupext beval bkc briopt buflisted cedit cink cmdheight columns concealcursor cpt cscopetagorder csverb deco diff dy efm endofline errorformat fcl fdm fex fileformats fkmap foldenable foldminlines formatprg gdefault gp guifontset helpfile hidden hl ignorecase imcmdline imsf indentexpr is isp keywordprg langremap linespace lnr lw mat maxmempattern mis mmt mouse mouseshape mzquantum odev osfiletype patchexpr pexpr pmbfn printencoding prompt qe relativenumber rightleft rs runtimepath scr sect sft shellredir shiftwidth showmatch signcolumn smarttab sp spf srr startofline suffixes switchbuf ta taglength tbidi termbidi tf title toolbar tsr ttym udf updatecount ve viminfo wb wh wildignore window wiv wrap ws +syn keyword vimOption contained altkeymap arabicshape aw backupskip bex bl brk buftype cf cinkeys cmdwinheight com conceallevel crb cscopeverbose cuc def diffexpr ea ei eol esckeys fcs fdn ff fileignorecase flp foldexpr foldnestmax fp gfm grepformat guifontwide helpheight highlight hlg im imd imstatusfunc indentkeys isf isprint km laststatus lisp loadplugins lz matchpairs maxmemtot mkspellmem mod mousef mouset nf oft pa patchmode pfn popt printexpr pt quoteescape remap rightleftcmd rtp sb scroll sections sh shellslash shm showmode siso smc spc spl ss statusline suffixesadd sws tabline tagrelative tbis termencoding tgc titlelen toolbariconsize ttimeout ttymouse udir updatetime verbose virtualedit wc whichwrap wildignorecase winfixheight wiw wrapmargin ww +syn keyword vimOption contained ambiwidth ari awa balloondelay bexpr bo browsedir casemap cfu cino cmp comments confirm cryptmethod cspc cul define diffopt ead + +" vimOptions: These are the turn-off setting variants {{{2 +syn keyword vimOption contained noacd noallowrevins noantialias noarabic noarshape noautoread noaw noballooneval nobinary nobomb nobuflisted nocin noconfirm nocrb nocscopeverbose nocsverb nocursorbind nodeco nodiff noeb noek noendofline noerrorbells noex nofen nofixendofline nofkmap nofsync noguipty nohk nohkp noic noim noimd noinf nois nolangnoremap nolazyredraw nolinebreak nolist noloadplugins nolrm noma nomagic noml nomodeline nomodified nomousef nomousehide nonumber noopendevice nopi nopreviewwindow nopvw norelativenumber norestorescreen nori norl noro noru nosb noscb noscs nosft noshelltemp noshortname noshowfulltag noshowmode nosm nosmartindent nosmd nosol nosplitbelow nospr nossl nostartofline noswapfile nota notagrelative notbi notbs noterse notextmode notgst notimeout noto notr nottybuiltin notx noundofile novisualbell nowarn noweirdinvert nowfw nowildignorecase nowinfixheight nowiv nowrap nowrite nowritebackup +syn keyword vimOption contained noai noaltkeymap noar noarabicshape noautochdir noautowrite noawa nobeval nobk nobreakindent nocf nocindent nocopyindent nocscoperelative nocsre nocuc nocursorcolumn nodelcombine nodigraph noed noemo noeol noesckeys noexpandtab nofic nofixeol nofoldenable nogd nohid nohkmap nohls noicon noimc noimdisable noinfercase nojoinspaces nolangremap nolbr nolisp nolnr nolpl nolz nomacatsui nomh nomod nomodifiable nomore nomousefocus nonu noodev nopaste nopreserveindent noprompt noreadonly noremap norevins norightleft nornu nors noruler nosc noscrollbind nosecure noshellslash noshiftround noshowcmd noshowmatch nosi nosmartcase nosmarttab nosn nospell nosplitright nosr nosta nostmp noswf notagbsearch notagstack notbidi notermbidi notextauto notf notildeop notitle notop nottimeout nottyfast noudf novb nowa nowb nowfh nowic nowildmenu nowinfixwidth nowmnu nowrapscan nowriteany nows +syn keyword vimOption contained noakm noanti noarab noari noautoindent noautowriteall nobackup nobin nobl nobri noci nocompatible nocp nocscopetag nocst nocul nocursorline nodg noea noedcompatible noemoji noequalalways noet noexrc nofileignorecase nofk nofs nogdefault nohidden nohkmapp nohlsearch noignorecase noimcmdline noincsearch noinsertmode nojs + +" vimOptions: These are the invertible variants {{{2 +syn keyword vimOption contained invacd invallowrevins invantialias invarabic invarshape invautoread invaw invballooneval invbinary invbomb invbuflisted invcin invconfirm invcrb invcscopeverbose invcsverb invcursorbind invdeco invdiff inveb invek invendofline inverrorbells invex invfen invfixendofline invfkmap invfsync invguipty invhk invhkp invic invim invimd invinf invis invlangnoremap invlazyredraw invlinebreak invlist invloadplugins invlrm invma invmagic invml invmodeline invmodified invmousef invmousehide invnumber invopendevice invpi invpreviewwindow invpvw invrelativenumber invrestorescreen invri invrl invro invru invsb invscb invscs invsft invshelltemp invshortname invshowfulltag invshowmode invsm invsmartindent invsmd invsol invsplitbelow invspr invssl invstartofline invswapfile invta invtagrelative invtbi invtbs invterse invtextmode invtgst invtimeout invto invtr invttybuiltin invtx invundofile invvisualbell invwarn invweirdinvert invwfw invwildignorecase invwinfixheight invwiv invwrap invwrite invwritebackup +syn keyword vimOption contained invai invaltkeymap invar invarabicshape invautochdir invautowrite invawa invbeval invbk invbreakindent invcf invcindent invcopyindent invcscoperelative invcsre invcuc invcursorcolumn invdelcombine invdigraph inved invemo inveol invesckeys invexpandtab invfic invfixeol invfoldenable invgd invhid invhkmap invhls invicon invimc invimdisable invinfercase invjoinspaces invlangremap invlbr invlisp invlnr invlpl invlz invmacatsui invmh invmod invmodifiable invmore invmousefocus invnu invodev invpaste invpreserveindent invprompt invreadonly invremap invrevins invrightleft invrnu invrs invruler invsc invscrollbind invsecure invshellslash invshiftround invshowcmd invshowmatch invsi invsmartcase invsmarttab invsn invspell invsplitright invsr invsta invstmp invswf invtagbsearch invtagstack invtbidi invtermbidi invtextauto invtf invtildeop invtitle invtop invttimeout invttyfast invudf invvb invwa invwb invwfh invwic invwildmenu invwinfixwidth invwmnu invwrapscan invwriteany invws +syn keyword vimOption contained invakm invanti invarab invari invautoindent invautowriteall invbackup invbin invbl invbri invci invcompatible invcp invcscopetag invcst invcul invcursorline invdg invea invedcompatible invemoji invequalalways invet invexrc invfileignorecase invfk invfs invgdefault invhidden invhkmapp invhlsearch invignorecase invimcmdline invincsearch invinsertmode invjs + +" termcap codes (which can also be set) {{{2 +syn keyword vimOption contained t_8b t_AB t_AL t_CV t_Co t_DL t_F1 t_F3 t_F5 t_F7 t_F9 t_IS t_K1 t_K3 t_K4 t_K5 t_K6 t_K7 t_K8 t_K9 t_KA t_KB t_KC t_KD t_KE t_KF t_KG t_KH t_KI t_KJ t_KK t_KL t_RB t_RI t_RV t_SI t_SR t_Sb t_Sf t_WP t_WS t_ZH t_ZR t_al t_bc t_cd t_ce t_cl t_cm t_cs t_da t_db t_dl t_fs t_k1 t_k2 t_k3 t_k4 t_k5 t_k6 t_k7 t_k8 t_k9 t_kB t_kD t_kI t_kN t_kP t_kb t_kd t_ke t_kh t_kl t_kr t_ks t_ku t_le t_mb t_md t_me t_mr t_ms t_nd t_op t_se t_so t_sr t_te t_ti t_ts t_u7 t_ue t_us t_ut t_vb t_ve t_vi t_vs t_xn t_xs +syn keyword vimOption contained t_8f t_AF t_CS t_Ce t_Cs t_EI t_F2 t_F4 t_F6 t_F8 t_IE +syn match vimOption contained "t_#2" +syn match vimOption contained "t_#4" +syn match vimOption contained "t_%1" +syn match vimOption contained "t_%i" +syn match vimOption contained "t_&8" +syn match vimOption contained "t_*7" +syn match vimOption contained "t_@7" +syn match vimOption contained "t_k;" + +" unsupported settings: some were supported by vi but don't do anything in vim {{{2 +" others have been dropped along with msdos support +syn keyword vimErrSetting contained bioskey biosk conskey consk autoprint beautify flash graphic hardtabs mesg novice open op optimize redraw slow slowopen sourceany w300 w1200 w9600 hardtabs ht nobioskey nobiosk noconskey noconsk noautoprint nobeautify noflash nographic nohardtabs nomesg nonovice noopen noop nooptimize noredraw noslow noslowopen nosourceany now300 now1200 now9600 w1200 w300 w9600 + +" AutoCmd Events {{{2 +syn case ignore +syn keyword vimAutoEvent contained BufAdd BufCreate BufDelete BufEnter BufFilePost BufFilePre BufHidden BufLeave BufNew BufNewFile BufRead BufReadCmd BufReadPost BufReadPre BufUnload BufWinEnter BufWinLeave BufWipeout BufWrite BufWriteCmd BufWritePost BufWritePre CmdUndefined CmdwinEnter CmdwinLeave ColorScheme CompleteDone CursorHold CursorHoldI CursorMoved CursorMovedI EncodingChanged FileAppendCmd FileAppendPost FileAppendPre FileChangedRO FileChangedShell FileChangedShellPost FileEncoding FileReadCmd FileReadPost FileReadPre FileType FileWriteCmd FileWritePost FileWritePre FilterReadPost FilterReadPre FilterWritePost FilterWritePre FocusGained FocusLost FuncUndefined GUIEnter GUIFailed InsertChange InsertCharPre InsertEnter InsertLeave MenuPopup OptionSet QuickFixCmdPost QuickFixCmdPre QuitPre RemoteReply SessionLoadPost ShellCmdPost ShellFilterPost SourceCmd SourcePre SpellFileMissing StdinReadPost StdinReadPre SwapExists Syntax TabClosed TabEnter TabLeave TabNew TermChanged TermResponse TextChanged TextChangedI User VimEnter VimLeave VimLeavePre VimResized WinEnter WinLeave WinNew + +" Highlight commonly used Groupnames {{{2 +syn keyword vimGroup contained Comment Constant String Character Number Boolean Float Identifier Function Statement Conditional Repeat Label Operator Keyword Exception PreProc Include Define Macro PreCondit Type StorageClass Structure Typedef Special SpecialChar Tag Delimiter SpecialComment Debug Underlined Ignore Error Todo + +" Default highlighting groups {{{2 +syn keyword vimHLGroup contained ColorColumn Cursor CursorColumn CursorIM CursorLine CursorLineNr DiffAdd DiffChange DiffDelete DiffText Directory EndOfBuffer ErrorMsg FoldColumn Folded IncSearch LineNr MatchParen Menu ModeMsg MoreMsg NonText Normal Pmenu PmenuSbar PmenuSel PmenuThumb Question Scrollbar Search SignColumn SpecialKey SpellBad SpellCap SpellLocal SpellRare StatusLine StatusLineNC TabLine TabLineFill TabLineSel Title Tooltip VertSplit Visual VisualNOS WarningMsg WildMenu +syn match vimHLGroup contained "Conceal" +syn case match + +" Function Names {{{2 +syn keyword vimFuncName contained abs append argv assert_fails assert_notequal atan2 buflisted bufwinid byteidxcomp ch_close_in ch_getjob ch_open ch_sendraw char2nr complete copy cscope_connection did_filetype escape execute expand filewritable float2nr fnamemodify foldtext function getbufline getcharsearch getcmdwintype getfontname getftype getpid getregtype getwininfo glob has_key histdel hlexists index inputrestore invert items job_start js_decode json_encode libcall line2byte log map match matcharg matchlist max mode nr2char perleval printf pyeval reltime remote_expr remote_read rename reverse screenchar search searchpairpos serverlist setcmdpos setloclist setqflist settabwinvar shellescape sin soundfold split str2nr strdisplaywidth stridx strpart strwidth synID synconcealed systemlist tabpagewinnr tan test_alloc_fail test_garbagecollect_now test_null_job test_null_string timer_pause timer_stopall tr undofile values wildmenumode win_gotoid winbufnr winline winrestview wordcount +syn keyword vimFuncName contained acos argc asin assert_false assert_notmatch browse bufloaded bufwinnr call ch_evalexpr ch_info ch_read ch_setoptions cindent complete_add cos cursor diff_filler eval exepath extend filter floor foldclosed foldtextresult garbagecollect getbufvar getcmdline getcompletion getfperm getline getpos gettabinfo getwinposx glob2regpat haslocaldir histget hostname input inputsave isdirectory job_getchannel job_status js_encode keys libcallnr lispindent log10 maparg matchadd matchdelete matchstr min mzeval or pow pumvisible range reltimefloat remote_foreground remote_send repeat round screencol searchdecl searchpos setbufline setbufvar setfperm setmatches setreg setwinvar shiftwidth sinh spellbadword sqrt strcharpart strftime string strridx submatch synIDattr synstack tabpagebuflist tagfiles tanh test_autochdir test_null_channel test_null_list test_settime timer_start tolower trunc undotree virtcol win_findbuf win_id2tabwin wincol winnr winsaveview writefile +syn keyword vimFuncName contained add argidx assert_equal assert_inrange assert_true browsedir bufname byte2line ceil ch_evalraw ch_log ch_readraw ch_status clearmatches complete_check cosh deepcopy diff_hlID eventhandler exists feedkeys finddir fmod foldclosedend foreground get getchar getcmdpos getcurpos getfsize getloclist getqflist gettabvar getwinposy globpath hasmapto histnr iconv inputdialog inputsecret islocked job_info job_stop json_decode len line localtime luaeval mapcheck matchaddpos matchend matchstrpos mkdir nextnonblank pathshorten prevnonblank py3eval readfile reltimestr remote_peek remove resolve screenattr screenrow searchpair server2client setcharsearch setline setpos settabvar sha256 simplify sort spellsuggest str2float strchars strgetchar strlen strtrans substitute synIDtrans system tabpagenr taglist tempname test_disable_char_avail test_null_dict test_null_partial timer_info timer_stop toupper type uniq visualmode win_getid win_id2win winheight winrestcmd winwidth xor +syn keyword vimFuncName contained and arglistid assert_exception assert_match atan bufexists bufnr byteidx ch_close ch_getbufnr ch_logfile ch_sendexpr changenr col confirm count delete empty executable exp filereadable findfile fnameescape foldlevel funcref getbufinfo getcharmod getcmdtype getcwd getftime getmatches getreg gettabwinvar getwinvar has histadd hlID indent inputlist insert isnan job_setoptions join + +"--- syntax here and above generated by mkvimvim --- +" Special Vim Highlighting (not automatic) {{{1 + +" Set up folding commands +if exists("g:vimsyn_folding") && g:vimsyn_folding =~# '[aflmpPrt]' + if g:vimsyn_folding =~# 'a' + com! -nargs=* VimFolda fold + else + com! -nargs=* VimFolda + endif + if g:vimsyn_folding =~# 'f' + com! -nargs=* VimFoldf fold + else + com! -nargs=* VimFoldf + endif + if g:vimsyn_folding =~# 'l' + com! -nargs=* VimFoldl fold + else + com! -nargs=* VimFoldl + endif + if g:vimsyn_folding =~# 'm' + com! -nargs=* VimFoldm fold + else + com! -nargs=* VimFoldm + endif + if g:vimsyn_folding =~# 'p' + com! -nargs=* VimFoldp fold + else + com! -nargs=* VimFoldp + endif + if g:vimsyn_folding =~# 'P' + com! -nargs=* VimFoldP fold + else + com! -nargs=* VimFoldP + endif + if g:vimsyn_folding =~# 'r' + com! -nargs=* VimFoldr fold + else + com! -nargs=* VimFoldr + endif + if g:vimsyn_folding =~# 't' + com! -nargs=* VimFoldt fold + else + com! -nargs=* VimFoldt + endif +else + com! -nargs=* VimFolda + com! -nargs=* VimFoldf + com! -nargs=* VimFoldl + com! -nargs=* VimFoldm + com! -nargs=* VimFoldp + com! -nargs=* VimFoldP + com! -nargs=* VimFoldr + com! -nargs=* VimFoldt +endif + +" commands not picked up by the generator (due to non-standard format) +syn keyword vimCommand contained py3 + +" Deprecated variable options {{{2 +if exists("g:vim_minlines") + let g:vimsyn_minlines= g:vim_minlines +endif +if exists("g:vim_maxlines") + let g:vimsyn_maxlines= g:vim_maxlines +endif +if exists("g:vimsyntax_noerror") + let g:vimsyn_noerror= g:vimsyntax_noerror +endif + +" Variable options {{{2 +if exists("g:vim_maxlines") + let s:vimsyn_maxlines= g:vim_maxlines +else + let s:vimsyn_maxlines= 60 +endif + +" Numbers {{{2 +" ======= +syn match vimNumber "\<\d\+\%(\.\d\+\%([eE][+-]\=\d\+\)\=\)\=" skipwhite nextgroup=vimGlobal,vimSubst,vimCommand +syn match vimNumber "-\d\+\%(\.\d\+\%([eE][+-]\=\d\+\)\=\)\=" skipwhite nextgroup=vimGlobal,vimSubst,vimCommand +syn match vimNumber "\<0[xX]\x\+" +syn match vimNumber "\<0[bB][01]\+" +syn match vimNumber "\%(^\|[^a-zA-Z]\)\zs#\x\{6}" + +" All vimCommands are contained by vimIsCommands. {{{2 +syn match vimCmdSep "[:|]\+" skipwhite nextgroup=vimAddress,vimAutoCmd,vimIsCommand,vimExtCmd,vimFilter,vimLet,vimMap,vimMark,vimSet,vimSyntax,vimUserCmd +syn match vimIsCommand "\<\h\w*\>" contains=vimCommand +syn match vimVar contained "\<\h[a-zA-Z0-9#_]*\>" +syn match vimVar "\<[bwglstav]:\h[a-zA-Z0-9#_]*\>" +syn match vimFBVar contained "\<[bwglstav]:\h[a-zA-Z0-9#_]*\>" +syn keyword vimCommand contained in + +" Insertions And Appends: insert append {{{2 +" ======================= +syn region vimInsert matchgroup=vimCommand start="^[: \t]*\(\d\+\(,\d\+\)\=\)\=a\%[ppend]$" matchgroup=vimCommand end="^\.$"" +syn region vimInsert matchgroup=vimCommand start="^[: \t]*\(\d\+\(,\d\+\)\=\)\=c\%[hange]$" matchgroup=vimCommand end="^\.$"" +syn region vimInsert matchgroup=vimCommand start="^[: \t]*\(\d\+\(,\d\+\)\=\)\=i\%[nsert]$" matchgroup=vimCommand end="^\.$"" + +" Behave! {{{2 +" ======= +syn match vimBehave "\" skipwhite nextgroup=vimBehaveModel,vimBehaveError +syn keyword vimBehaveModel contained mswin xterm +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_nobehaveerror") + syn match vimBehaveError contained "[^ ]\+" +endif + +" Filetypes {{{2 +" ========= +syn match vimFiletype "\\s\+[eE][nN][dD]\>" +endif +syn keyword vimAugroupKey contained aug[roup] + +" Operators: {{{2 +" ========= +syn cluster vimOperGroup contains=vimEnvvar,vimFunc,vimFuncVar,vimOper,vimOperParen,vimNumber,vimString,vimRegister,vimContinue +syn match vimOper "\(==\|!=\|>=\|<=\|=\~\|!\~\|>\|<\|=\)[?#]\{0,2}" skipwhite nextgroup=vimString,vimSpecFile +syn match vimOper "||\|&&\|[-+.]" skipwhite nextgroup=vimString,vimSpecFile +syn region vimOperParen matchgroup=vimParenSep start="(" end=")" contains=@vimOperGroup +syn region vimOperParen matchgroup=vimSep start="{" end="}" contains=@vimOperGroup nextgroup=vimVar,vimFuncVar +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_noopererror") + syn match vimOperError ")" +endif + +" Functions : Tag is provided for those who wish to highlight tagged functions {{{2 +" ========= +syn cluster vimFuncList contains=vimCommand,vimFunctionError,vimFuncKey,Tag,vimFuncSID +syn cluster vimFuncBodyList contains=vimAbb,vimAddress,vimAugroupKey,vimAutoCmd,vimCmplxRepeat,vimComment,vimContinue,vimCtrlChar,vimEcho,vimEchoHL,vimExecute,vimIf,vimIsCommand,vimFBVar,vimFunc,vimFunction,vimFuncVar,vimGlobal,vimHighlight,vimIsCommand,vimLet,vimLineComment,vimMap,vimMark,vimNorm,vimNotation,vimNotFunc,vimNumber,vimOper,vimOperParen,vimRegion,vimRegister,vimSet,vimSpecFile,vimString,vimSubst,vimSynLine,vimUnmap,vimUserCommand +syn match vimFunction "\\|[sSgGbBwWtTlL]:\)\=\%(\i\|[#.]\|{.\{-1,}}\)*\ze\s*(" contains=@vimFuncList nextgroup=vimFuncBody + +if exists("g:vimsyn_folding") && g:vimsyn_folding =~# 'f' + syn region vimFuncBody contained fold start="\ze\s*(" matchgroup=vimCommand end="\<\(endf\>\|endfu\%[nction]\>\)" contains=@vimFuncBodyList +else + syn region vimFuncBody contained start="\ze\s*(" matchgroup=vimCommand end="\<\(endf\>\|endfu\%[nction]\>\)" contains=@vimFuncBodyList +endif +syn match vimFuncVar contained "a:\(\K\k*\|\d\+\)" +syn match vimFuncSID contained "\c\|\" nextgroup=vimSpecFileMod,vimSubst +syn match vimSpecFile "<\([acs]file\|amatch\|abuf\)>" nextgroup=vimSpecFileMod,vimSubst +syn match vimSpecFile "\s%[ \t:]"ms=s+1,me=e-1 nextgroup=vimSpecFileMod,vimSubst +syn match vimSpecFile "\s%$"ms=s+1 nextgroup=vimSpecFileMod,vimSubst +syn match vimSpecFile "\s%<"ms=s+1,me=e-1 nextgroup=vimSpecFileMod,vimSubst +syn match vimSpecFile "#\d\+\|[#%]<\>" nextgroup=vimSpecFileMod,vimSubst +syn match vimSpecFileMod "\(:[phtre]\)\+" contained + +" User-Specified Commands: {{{2 +" ======================= +syn cluster vimUserCmdList contains=vimAddress,vimSyntax,vimHighlight,vimAutoCmd,vimCmplxRepeat,vimComment,vimCtrlChar,vimEscapeBrace,vimFilter,vimFunc,vimFuncName,vimFunction,vimFunctionError,vimIsCommand,vimMark,vimNotation,vimNumber,vimOper,vimRegion,vimRegister,vimLet,vimSet,vimSetEqual,vimSetString,vimSpecFile,vimString,vimSubst,vimSubstRep,vimSubstRange,vimSynLine +syn keyword vimUserCommand contained com[mand] +syn match vimUserCmd "\.*$" contains=vimUserAttrb,vimUserAttrbError,vimUserCommand,@vimUserCmdList +syn match vimUserAttrbError contained "-\a\+\ze\s" +syn match vimUserAttrb contained "-nargs=[01*?+]" contains=vimUserAttrbKey,vimOper +syn match vimUserAttrb contained "-complete=" contains=vimUserAttrbKey,vimOper nextgroup=vimUserAttrbCmplt,vimUserCmdError +syn match vimUserAttrb contained "-range\(=%\|=\d\+\)\=" contains=vimNumber,vimOper,vimUserAttrbKey +syn match vimUserAttrb contained "-count\(=\d\+\)\=" contains=vimNumber,vimOper,vimUserAttrbKey +syn match vimUserAttrb contained "-bang\>" contains=vimOper,vimUserAttrbKey +syn match vimUserAttrb contained "-bar\>" contains=vimOper,vimUserAttrbKey +syn match vimUserAttrb contained "-buffer\>" contains=vimOper,vimUserAttrbKey +syn match vimUserAttrb contained "-register\>" contains=vimOper,vimUserAttrbKey +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_nousercmderror") + syn match vimUserCmdError contained "\S\+\>" +endif +syn case ignore +syn keyword vimUserAttrbKey contained bar ban[g] cou[nt] ra[nge] com[plete] n[args] re[gister] +syn keyword vimUserAttrbCmplt contained augroup buffer behave color command compiler cscope dir environment event expression file file_in_path filetype function help highlight history locale mapping menu option packadd shellcmd sign syntax syntime tag tag_listfiles user var +syn keyword vimUserAttrbCmplt contained custom customlist nextgroup=vimUserAttrbCmpltFunc,vimUserCmdError +syn match vimUserAttrbCmpltFunc contained ",\%([sS]:\|<[sS][iI][dD]>\)\=\%(\h\w*\%(#\h\w*\)\+\|\h\w*\)"hs=s+1 nextgroup=vimUserCmdError + +syn case match +syn match vimUserAttrbCmplt contained "custom,\u\w*" + +" Lower Priority Comments: after some vim commands... {{{2 +" ======================= +syn match vimComment excludenl +\s"[^\-:.%#=*].*$+lc=1 contains=@vimCommentGroup,vimCommentString +syn match vimComment +\!\\@]"+lc=1 skip=+\\\\\|\\"+ end=+"+ contains=@vimStringGroup +syn region vimString oneline keepend start=+[^:a-zA-Z>!\\@]'+lc=1 end=+'+ +syn region vimString oneline start=+=!+lc=1 skip=+\\\\\|\\!+ end=+!+ contains=@vimStringGroup +syn region vimString oneline start="=+"lc=1 skip="\\\\\|\\+" end="+" contains=@vimStringGroup +syn region vimString oneline start="\s/\s*\A"lc=1 skip="\\\\\|\\+" end="/" contains=@vimStringGroup +syn match vimString contained +"[^"]*\\$+ skipnl nextgroup=vimStringCont +syn match vimStringCont contained +\(\\\\\|.\)\{-}[^\\]"+ + +" Substitutions: {{{2 +" ============= +syn cluster vimSubstList contains=vimPatSep,vimPatRegion,vimPatSepErr,vimSubstTwoBS,vimSubstRange,vimNotation +syn cluster vimSubstRepList contains=vimSubstSubstr,vimSubstTwoBS,vimNotation +syn cluster vimSubstList add=vimCollection +syn match vimSubst "\(:\+\s*\|^\s*\||\s*\)\<\%(\\|\\|\\)[:#[:alpha:]]\@!" nextgroup=vimSubstPat +syn match vimSubst "\%(^\|[^\\]\)\[:#[:alpha:]]\@!" nextgroup=vimSubstPat contained +syn match vimSubst "/\zs\\ze/" nextgroup=vimSubstPat +syn match vimSubst "\(:\+\s*\|^\s*\)s\ze#.\{-}#.\{-}#" nextgroup=vimSubstPat +syn match vimSubst1 contained "\" nextgroup=vimSubstPat +syn region vimSubstPat contained matchgroup=vimSubstDelim start="\z([^a-zA-Z( \t[\]&]\)"rs=s+1 skip="\\\\\|\\\z1" end="\z1"re=e-1,me=e-1 contains=@vimSubstList nextgroup=vimSubstRep4 oneline +syn region vimSubstRep4 contained matchgroup=vimSubstDelim start="\z(.\)" skip="\\\\\|\\\z1" end="\z1" matchgroup=vimNotation end="<[cC][rR]>" contains=@vimSubstRepList nextgroup=vimSubstFlagErr oneline +syn region vimCollection contained transparent start="\\\@]\ze[-+,!]" nextgroup=vimOper,vimMarkNumber,vimSubst +syn match vimMark ",\zs'[<>]\ze" nextgroup=vimOper,vimMarkNumber,vimSubst +syn match vimMark "[!,:]\zs'[a-zA-Z0-9]" nextgroup=vimOper,vimMarkNumber,vimSubst +syn match vimMark "\'lc=1 +syn match vimCmplxRepeat '@[0-9a-z".=@:]\ze\($\|[^a-zA-Z]\>\)' + +" Set command and associated set-options (vimOptions) with comment {{{2 +syn region vimSet matchgroup=vimCommand start="\<\%(setl\%[ocal]\|setg\%[lobal]\|se\%[t]\)\>" skip="\%(\\\\\)*\\." end="$" matchgroup=vimNotation end="<[cC][rR]>" keepend oneline contains=vimSetEqual,vimOption,vimErrSetting,vimComment,vimSetString,vimSetMod +syn region vimSetEqual contained start="[=:]\|[-+^]=" skip="\\\\\|\\\s" end="[| \t]\|$"me=e-1 contains=vimCtrlChar,vimSetSep,vimNotation,vimEnvvar oneline +syn region vimSetString contained start=+="+hs=s+1 skip=+\\\\\|\\"+ end=+"+ contains=vimCtrlChar +syn match vimSetSep contained "[,:]" skipwhite nextgroup=vimCommand +syn match vimSetMod contained "&vim\=\|[!&?<]\|all&" + +" Let {{{2 +" === +syn keyword vimLet let unl[et] skipwhite nextgroup=vimVar,vimFuncVar + +" Abbreviations {{{2 +" ============= +syn keyword vimAbb ab[breviate] ca[bbrev] inorea[bbrev] cnorea[bbrev] norea[bbrev] ia[bbrev] skipwhite nextgroup=vimMapMod,vimMapLhs + +" Autocmd {{{2 +" ======= +syn match vimAutoEventList contained "\(!\s\+\)\=\(\a\+,\)*\a\+" contains=vimAutoEvent nextgroup=vimAutoCmdSpace +syn match vimAutoCmdSpace contained "\s\+" nextgroup=vimAutoCmdSfxList +syn match vimAutoCmdSfxList contained "\S*" +syn keyword vimAutoCmd au[tocmd] do[autocmd] doautoa[ll] skipwhite nextgroup=vimAutoEventList + +" Echo and Execute -- prefer strings! {{{2 +" ================ +syn region vimEcho oneline excludenl matchgroup=vimCommand start="\" skip="\(\\\\\)*\\|" end="$\||" contains=vimFunc,vimFuncVar,vimString,vimVar +syn region vimExecute oneline excludenl matchgroup=vimCommand start="\" skip="\(\\\\\)*\\|" end="$\||\|<[cC][rR]>" contains=vimFuncVar,vimIsCommand,vimOper,vimNotation,vimOperParen,vimString,vimVar +syn match vimEchoHL "echohl\=" skipwhite nextgroup=vimGroup,vimHLGroup,vimEchoHLNone +syn case ignore +syn keyword vimEchoHLNone none +syn case match + +" Maps {{{2 +" ==== +syn match vimMap "\!\=\ze\s*[^(]" skipwhite nextgroup=vimMapMod,vimMapLhs +syn keyword vimMap cm[ap] cno[remap] im[ap] ino[remap] lm[ap] ln[oremap] nm[ap] nn[oremap] no[remap] om[ap] ono[remap] smap snor[emap] vm[ap] vn[oremap] xm[ap] xn[oremap] skipwhite nextgroup=vimMapBang,vimMapMod,vimMapLhs +syn keyword vimMap mapc[lear] smapc[lear] +syn keyword vimUnmap cu[nmap] iu[nmap] lu[nmap] nun[map] ou[nmap] sunm[ap] unm[ap] unm[ap] vu[nmap] xu[nmap] skipwhite nextgroup=vimMapBang,vimMapMod,vimMapLhs +syn match vimMapLhs contained "\S\+" contains=vimNotation,vimCtrlChar skipwhite nextgroup=vimMapRhs +syn match vimMapBang contained "!" skipwhite nextgroup=vimMapMod,vimMapLhs +syn match vimMapMod contained "\c<\(buffer\|expr\|\(local\)\=leader\|nowait\|plug\|script\|sid\|unique\|silent\)\+>" contains=vimMapModKey,vimMapModErr skipwhite nextgroup=vimMapMod,vimMapLhs +syn match vimMapRhs contained ".*" contains=vimNotation,vimCtrlChar skipnl nextgroup=vimMapRhsExtend +syn match vimMapRhsExtend contained "^\s*\\.*$" contains=vimContinue +syn case ignore +syn keyword vimMapModKey contained buffer expr leader localleader nowait plug script sid silent unique +syn case match + +" Menus {{{2 +" ===== +syn cluster vimMenuList contains=vimMenuBang,vimMenuPriority,vimMenuName,vimMenuMod +syn keyword vimCommand am[enu] an[oremenu] aun[menu] cme[nu] cnoreme[nu] cunme[nu] ime[nu] inoreme[nu] iunme[nu] me[nu] nme[nu] nnoreme[nu] noreme[nu] nunme[nu] ome[nu] onoreme[nu] ounme[nu] unme[nu] vme[nu] vnoreme[nu] vunme[nu] skipwhite nextgroup=@vimMenuList +syn match vimMenuName "[^ \t\\<]\+" contained nextgroup=vimMenuNameMore,vimMenuMap +syn match vimMenuPriority "\d\+\(\.\d\+\)*" contained skipwhite nextgroup=vimMenuName +syn match vimMenuNameMore "\c\\\s\|\|\\\." contained nextgroup=vimMenuName,vimMenuNameMore contains=vimNotation +syn match vimMenuMod contained "\c<\(script\|silent\)\+>" skipwhite contains=vimMapModKey,vimMapModErr nextgroup=@vimMenuList +syn match vimMenuMap "\s" contained skipwhite nextgroup=vimMenuRhs +syn match vimMenuRhs ".*$" contained contains=vimString,vimComment,vimIsCommand +syn match vimMenuBang "!" contained skipwhite nextgroup=@vimMenuList + +" Angle-Bracket Notation (tnx to Michael Geddes) {{{2 +" ====================== +syn case ignore +syn match vimNotation "\(\\\|\)\=<\([scamd]-\)\{0,4}x\=\(f\d\{1,2}\|[^ \t:]\|cr\|lf\|linefeed\|return\|k\=del\%[ete]\|bs\|backspace\|tab\|esc\|right\|left\|help\|undo\|insert\|ins\|k\=home\|k\=end\|kplus\|kminus\|kdivide\|kmultiply\|kenter\|kpoint\|space\|k\=\(page\)\=\(\|down\|up\|k\d\>\)\)>" contains=vimBracket +syn match vimNotation "\(\\\|\)\=<\([scam2-4]-\)\{0,4}\(right\|left\|middle\)\(mouse\)\=\(drag\|release\)\=>" contains=vimBracket +syn match vimNotation "\(\\\|\)\=<\(bslash\|plug\|sid\|space\|bar\|nop\|nul\|lt\)>" contains=vimBracket +syn match vimNotation '\(\\\|\)\=[0-9a-z"%#:.\-=]'he=e-1 contains=vimBracket +syn match vimNotation '\(\\\|\)\=<\%(q-\)\=\(line[12]\|count\|bang\|reg\|args\|mods\|f-args\|f-mods\|lt\)>' contains=vimBracket +syn match vimNotation "\(\\\|\)\=<\([cas]file\|abuf\|amatch\|cword\|cWORD\|client\)>" contains=vimBracket +syn match vimBracket contained "[\\<>]" +syn case match + +" User Function Highlighting {{{2 +" (following Gautam Iyer's suggestion) +" ========================== +syn match vimFunc "\%(\%([sSgGbBwWtTlL]:\|<[sS][iI][dD]>\)\=\%([a-zA-Z0-9_]\+\.\)*\I[a-zA-Z0-9_.]*\)\ze\s*(" contains=vimFuncName,vimUserFunc,vimExecute +syn match vimUserFunc contained "\%(\%([sSgGbBwWtTlL]:\|<[sS][iI][dD]>\)\=\%([a-zA-Z0-9_]\+\.\)*\I[a-zA-Z0-9_.]*\)\|\<\u[a-zA-Z0-9.]*\>\|\" contains=vimNotation +syn match vimNotFunc "\\|\\|\\|\" + +" Errors And Warnings: {{{2 +" ==================== +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_novimfunctionerror") + syn match vimFunctionError "\s\zs[a-z0-9]\i\{-}\ze\s*(" contained contains=vimFuncKey,vimFuncBlank +" syn match vimFunctionError "\s\zs\%(<[sS][iI][dD]>\|[sSgGbBwWtTlL]:\)[0-9]\i\{-}\ze\s*(" contained contains=vimFuncKey,vimFuncBlank + syn match vimElseIfErr "\" + syn match vimBufnrWarn /\" contains=vimCommand skipwhite nextgroup=vimSynType,vimComment +syn match vimAuSyntax contained "\s+sy\%[ntax]" contains=vimCommand skipwhite nextgroup=vimSynType,vimComment +syn cluster vimFuncBodyList add=vimSyntax + +" Syntax: case {{{2 +syn keyword vimSynType contained case skipwhite nextgroup=vimSynCase,vimSynCaseError +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_novimsyncaseerror") + syn match vimSynCaseError contained "\i\+" +endif +syn keyword vimSynCase contained ignore match + +" Syntax: clear {{{2 +syn keyword vimSynType contained clear skipwhite nextgroup=vimGroupList + +" Syntax: cluster {{{2 +syn keyword vimSynType contained cluster skipwhite nextgroup=vimClusterName +syn region vimClusterName contained matchgroup=vimGroupName start="\h\w*" skip="\\\\\|\\|" matchgroup=vimSep end="$\||" contains=vimGroupAdd,vimGroupRem,vimSynContains,vimSynError +syn match vimGroupAdd contained "add=" nextgroup=vimGroupList +syn match vimGroupRem contained "remove=" nextgroup=vimGroupList +syn cluster vimFuncBodyList add=vimSynType,vimGroupAdd,vimGroupRem + +" Syntax: iskeyword {{{2 +syn keyword vimSynType contained iskeyword skipwhite nextgroup=vimIskList +syn match vimIskList contained '\S\+' contains=vimIskSep +syn match vimIskSep contained ',' + +" Syntax: include {{{2 +syn keyword vimSynType contained include skipwhite nextgroup=vimGroupList +syn cluster vimFuncBodyList add=vimSynType + +" Syntax: keyword {{{2 +syn cluster vimSynKeyGroup contains=vimSynNextgroup,vimSynKeyOpt,vimSynKeyContainedin +syn keyword vimSynType contained keyword skipwhite nextgroup=vimSynKeyRegion +syn region vimSynKeyRegion contained oneline keepend matchgroup=vimGroupName start="\h\w*" skip="\\\\\|\\|" matchgroup=vimSep end="|\|$" contains=@vimSynKeyGroup +syn match vimSynKeyOpt contained "\<\(conceal\|contained\|transparent\|skipempty\|skipwhite\|skipnl\)\>" +syn cluster vimFuncBodyList add=vimSynType + +" Syntax: match {{{2 +syn cluster vimSynMtchGroup contains=vimMtchComment,vimSynContains,vimSynError,vimSynMtchOpt,vimSynNextgroup,vimSynRegPat,vimNotation +syn keyword vimSynType contained match skipwhite nextgroup=vimSynMatchRegion +syn region vimSynMatchRegion contained keepend matchgroup=vimGroupName start="\h\w*" matchgroup=vimSep end="|\|$" contains=@vimSynMtchGroup +syn match vimSynMtchOpt contained "\<\(conceal\|transparent\|contained\|excludenl\|keepend\|skipempty\|skipwhite\|display\|extend\|skipnl\|fold\)\>" +if has("conceal") + syn match vimSynMtchOpt contained "\" +syn match vimSynReg contained "\(start\|skip\|end\)="he=e-1 nextgroup=vimSynRegPat +syn match vimSynMtchGrp contained "matchgroup=" nextgroup=vimGroup,vimHLGroup +syn region vimSynRegPat contained extend start="\z([-`~!@#$%^&*_=+;:'",./?]\)" skip="\\\\\|\\\z1" end="\z1" contains=@vimSynRegPatGroup skipwhite nextgroup=vimSynPatMod,vimSynReg +syn match vimSynPatMod contained "\(hs\|ms\|me\|hs\|he\|rs\|re\)=[se]\([-+]\d\+\)\=" +syn match vimSynPatMod contained "\(hs\|ms\|me\|hs\|he\|rs\|re\)=[se]\([-+]\d\+\)\=," nextgroup=vimSynPatMod +syn match vimSynPatMod contained "lc=\d\+" +syn match vimSynPatMod contained "lc=\d\+," nextgroup=vimSynPatMod +syn region vimSynPatRange contained start="\[" skip="\\\\\|\\]" end="]" +syn match vimSynNotPatRange contained "\\\\\|\\\[" +syn match vimMtchComment contained '"[^"]\+$' +syn cluster vimFuncBodyList add=vimSynType + +" Syntax: sync {{{2 +" ============ +syn keyword vimSynType contained sync skipwhite nextgroup=vimSyncC,vimSyncLines,vimSyncMatch,vimSyncError,vimSyncLinebreak,vimSyncLinecont,vimSyncRegion +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_novimsyncerror") + syn match vimSyncError contained "\i\+" +endif +syn keyword vimSyncC contained ccomment clear fromstart +syn keyword vimSyncMatch contained match skipwhite nextgroup=vimSyncGroupName +syn keyword vimSyncRegion contained region skipwhite nextgroup=vimSynReg +syn match vimSyncLinebreak contained "\" skipwhite nextgroup=vimSyncGroup +syn match vimSyncGroup contained "\h\w*" skipwhite nextgroup=vimSynRegPat,vimSyncNone +syn keyword vimSyncNone contained NONE + +" Additional IsCommand, here by reasons of precedence {{{2 +" ==================== +syn match vimIsCommand "\s*\a\+" transparent contains=vimCommand,vimNotation + +" Highlighting {{{2 +" ============ +syn cluster vimHighlightCluster contains=vimHiLink,vimHiClear,vimHiKeyList,vimComment +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_novimhictermerror") + syn match vimHiCtermError contained "[^0-9]\i*" +endif +syn match vimHighlight "\" skipwhite nextgroup=vimHiBang,@vimHighlightCluster +syn match vimHiBang contained "!" skipwhite nextgroup=@vimHighlightCluster + +syn match vimHiGroup contained "\i\+" +syn case ignore +syn keyword vimHiAttrib contained none bold inverse italic reverse standout underline undercurl nocombine +syn keyword vimFgBgAttrib contained none bg background fg foreground +syn case match +syn match vimHiAttribList contained "\i\+" contains=vimHiAttrib +syn match vimHiAttribList contained "\i\+,"he=e-1 contains=vimHiAttrib nextgroup=vimHiAttribList +syn case ignore +syn keyword vimHiCtermColor contained black blue brown cyan darkblue darkcyan darkgray darkgreen darkgrey darkmagenta darkred darkyellow gray green grey lightblue lightcyan lightgray lightgreen lightgrey lightmagenta lightred magenta red white yellow +syn match vimHiCtermColor contained "\" + +syn case match +syn match vimHiFontname contained "[a-zA-Z\-*]\+" +syn match vimHiGuiFontname contained "'[a-zA-Z\-* ]\+'" +syn match vimHiGuiRgb contained "#\x\{6}" + +" Highlighting: hi group key=arg ... {{{2 +syn cluster vimHiCluster contains=vimGroup,vimHiGroup,vimHiTerm,vimHiCTerm,vimHiStartStop,vimHiCtermFgBg,vimHiGui,vimHiGuiFont,vimHiGuiFgBg,vimHiKeyError,vimNotation +syn region vimHiKeyList contained oneline start="\i\+" skip="\\\\\|\\|" end="$\||" contains=@vimHiCluster +if !exists("g:vimsyn_noerror") && !exists("g:vimsyn_vimhikeyerror") + syn match vimHiKeyError contained "\i\+="he=e-1 +endif +syn match vimHiTerm contained "\cterm="he=e-1 nextgroup=vimHiAttribList +syn match vimHiStartStop contained "\c\(start\|stop\)="he=e-1 nextgroup=vimHiTermcap,vimOption +syn match vimHiCTerm contained "\ccterm="he=e-1 nextgroup=vimHiAttribList +syn match vimHiCtermFgBg contained "\ccterm[fb]g="he=e-1 nextgroup=vimHiNmbr,vimHiCtermColor,vimFgBgAttrib,vimHiCtermError +syn match vimHiGui contained "\cgui="he=e-1 nextgroup=vimHiAttribList +syn match vimHiGuiFont contained "\cfont="he=e-1 nextgroup=vimHiFontname +syn match vimHiGuiFgBg contained "\cgui\%([fb]g\|sp\)="he=e-1 nextgroup=vimHiGroup,vimHiGuiFontname,vimHiGuiRgb,vimFgBgAttrib +syn match vimHiTermcap contained "\S\+" contains=vimNotation +syn match vimHiNmbr contained '\d\+' + +" Highlight: clear {{{2 +syn keyword vimHiClear contained clear nextgroup=vimHiGroup + +" Highlight: link {{{2 +syn region vimHiLink contained oneline matchgroup=vimCommand start="\(\\|\\)" end="$" contains=vimHiGroup,vimGroup,vimHLGroup,vimNotation +syn cluster vimFuncBodyList add=vimHiLink + +" Control Characters {{{2 +" ================== +syn match vimCtrlChar "[- -]" + +" Beginners - Patterns that involve ^ {{{2 +" ========= +syn match vimLineComment +^[ \t:]*".*$+ contains=@vimCommentGroup,vimCommentString,vimCommentTitle +syn match vimCommentTitle '"\s*\%([sS]:\|\h\w*#\)\=\u\w*\(\s\+\u\w*\)*:'hs=s+1 contained contains=vimCommentTitleLeader,vimTodo,@vimCommentGroup +syn match vimContinue "^\s*\\" +syn region vimString start="^\s*\\\z(['"]\)" skip='\\\\\|\\\z1' end="\z1" oneline keepend contains=@vimStringGroup,vimContinue +syn match vimCommentTitleLeader '"\s\+'ms=s+1 contained + +" Searches And Globals: {{{2 +" ==================== +syn match vimSearch '^\s*[/?].*' contains=vimSearchDelim +syn match vimSearchDelim '^\s*\zs[/?]\|[/?]$' contained +syn region vimGlobal matchgroup=Statement start='\:p:h")."/lua.vim") +if !filereadable(s:luapath) + for s:luapath in split(globpath(&rtp,"syntax/lua.vim"),"\n") + if filereadable(fnameescape(s:luapath)) + let s:luapath= fnameescape(s:luapath) + break + endif + endfor +endif +if (g:vimsyn_embed =~# 'l' && has("lua")) && filereadable(s:luapath) + unlet! b:current_syntax + exe "syn include @vimLuaScript ".s:luapath + VimFoldl syn region vimLuaRegion matchgroup=vimScriptDelim start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimLuaScript + VimFoldl syn region vimLuaRegion matchgroup=vimScriptDelim start=+lua\s*<<\s*$+ end=+\.$+ contains=@vimLuaScript + syn cluster vimFuncBodyList add=vimLuaRegion +else + syn region vimEmbedError start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+lua\s*<<\s*$+ end=+\.$+ +endif +unlet s:luapath + +" [-- perl --] {{{3 +let s:perlpath= fnameescape(expand(":p:h")."/perl.vim") +if !filereadable(s:perlpath) + for s:perlpath in split(globpath(&rtp,"syntax/perl.vim"),"\n") + if filereadable(fnameescape(s:perlpath)) + let s:perlpath= fnameescape(s:perlpath) + break + endif + endfor +endif +if (g:vimsyn_embed =~# 'p' && has("perl")) && filereadable(s:perlpath) + unlet! b:current_syntax + exe "syn include @vimPerlScript ".s:perlpath + VimFoldp syn region vimPerlRegion matchgroup=vimScriptDelim start=+pe\%[rl]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimPerlScript + VimFoldp syn region vimPerlRegion matchgroup=vimScriptDelim start=+pe\%[rl]\s*<<\s*$+ end=+\.$+ contains=@vimPerlScript + syn cluster vimFuncBodyList add=vimPerlRegion +else + syn region vimEmbedError start=+pe\%[rl]\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+pe\%[rl]\s*<<\s*$+ end=+\.$+ +endif +unlet s:perlpath + +" [-- ruby --] {{{3 +let s:rubypath= fnameescape(expand(":p:h")."/ruby.vim") +if !filereadable(s:rubypath) + for s:rubypath in split(globpath(&rtp,"syntax/ruby.vim"),"\n") + if filereadable(fnameescape(s:rubypath)) + let s:rubypath= fnameescape(s:rubypath) + break + endif + endfor +endif +if (g:vimsyn_embed =~# 'r' && has("ruby")) && filereadable(s:rubypath) + unlet! b:current_syntax + exe "syn include @vimRubyScript ".s:rubypath + VimFoldr syn region vimRubyRegion matchgroup=vimScriptDelim start=+rub[y]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimRubyScript + syn region vimRubyRegion matchgroup=vimScriptDelim start=+rub[y]\s*<<\s*$+ end=+\.$+ contains=@vimRubyScript + syn cluster vimFuncBodyList add=vimRubyRegion +else + syn region vimEmbedError start=+rub[y]\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+rub[y]\s*<<\s*$+ end=+\.$+ +endif +unlet s:rubypath + +" [-- python --] {{{3 +let s:pythonpath= fnameescape(expand(":p:h")."/python.vim") +if !filereadable(s:pythonpath) + for s:pythonpath in split(globpath(&rtp,"syntax/python.vim"),"\n") + if filereadable(fnameescape(s:pythonpath)) + let s:pythonpath= fnameescape(s:pythonpath) + break + endif + endfor +endif +if g:vimsyn_embed =~# 'P' && (has("python") || has("python3")) && filereadable(s:pythonpath) + unlet! b:current_syntax + exe "syn include @vimPythonScript ".s:pythonpath + VimFoldP syn region vimPythonRegion matchgroup=vimScriptDelim start=+py\%[thon]3\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimPythonScript + VimFoldP syn region vimPythonRegion matchgroup=vimScriptDelim start=+py\%[thon]3\=\s*<<\s*$+ end=+\.$+ contains=@vimPythonScript + VimFoldP syn region vimPythonRegion matchgroup=vimScriptDelim start=+Py\%[thon]2or3\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimPythonScript + VimFoldP syn region vimPythonRegion matchgroup=vimScriptDelim start=+Py\%[thon]2or3\=\s*<<\s*$+ end=+\.$+ contains=@vimPythonScript + syn cluster vimFuncBodyList add=vimPythonRegion +else + syn region vimEmbedError start=+py\%[thon]3\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+py\%[thon]3\=\s*<<\s*$+ end=+\.$+ +endif +unlet s:pythonpath + +" [-- tcl --] {{{3 +if has("win32") || has("win95") || has("win64") || has("win16") + " apparently has("tcl") has been hanging vim on some windows systems with cygwin + let s:trytcl= (&shell !~ '\<\%(bash\>\|4[nN][tT]\|\\%(\.exe\)\=$') +else + let s:trytcl= 1 +endif +if s:trytcl + let s:tclpath= fnameescape(expand(":p:h")."/tcl.vim") + if !filereadable(s:tclpath) + for s:tclpath in split(globpath(&rtp,"syntax/tcl.vim"),"\n") + if filereadable(fnameescape(s:tclpath)) + let s:tclpath= fnameescape(s:tclpath) + break + endif + endfor + endif + if (g:vimsyn_embed =~# 't' && has("tcl")) && filereadable(s:tclpath) + unlet! b:current_syntax + exe "syn include @vimTclScript ".s:tclpath + VimFoldt syn region vimTclRegion matchgroup=vimScriptDelim start=+tc[l]\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimTclScript + VimFoldt syn region vimTclRegion matchgroup=vimScriptDelim start=+tc[l]\=\s*<<\s*$+ end=+\.$+ contains=@vimTclScript + syn cluster vimFuncBodyList add=vimTclScript + else + syn region vimEmbedError start=+tc[l]\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+tc[l]\=\s*<<\s*$+ end=+\.$+ + endif + unlet s:tclpath +else + syn region vimEmbedError start=+tc[l]\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+tc[l]\=\s*<<\s*$+ end=+\.$+ +endif +unlet s:trytcl + +" [-- mzscheme --] {{{3 +let s:mzschemepath= fnameescape(expand(":p:h")."/scheme.vim") +if !filereadable(s:mzschemepath) + for s:mzschemepath in split(globpath(&rtp,"syntax/mzscheme.vim"),"\n") + if filereadable(fnameescape(s:mzschemepath)) + let s:mzschemepath= fnameescape(s:mzschemepath) + break + endif + endfor +endif +if (g:vimsyn_embed =~# 'm' && has("mzscheme")) && filereadable(s:mzschemepath) + unlet! b:current_syntax + let s:iskKeep= &isk + exe "syn include @vimMzSchemeScript ".s:mzschemepath + let &isk= s:iskKeep + unlet s:iskKeep + VimFoldm syn region vimMzSchemeRegion matchgroup=vimScriptDelim start=+mz\%[scheme]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimMzSchemeScript + VimFoldm syn region vimMzSchemeRegion matchgroup=vimScriptDelim start=+mz\%[scheme]\s*<<\s*$+ end=+\.$+ contains=@vimMzSchemeScript + syn cluster vimFuncBodyList add=vimMzSchemeRegion +else + syn region vimEmbedError start=+mz\%[scheme]\s*<<\s*\z(.*\)$+ end=+^\z1$+ + syn region vimEmbedError start=+mz\%[scheme]\s*<<\s*$+ end=+\.$+ +endif +unlet s:mzschemepath + +" Synchronize (speed) {{{2 +"============ +if exists("g:vimsyn_minlines") + exe "syn sync minlines=".g:vimsyn_minlines +endif +exe "syn sync maxlines=".s:vimsyn_maxlines +syn sync linecont "^\s\+\\" +syn sync match vimAugroupSyncA groupthere NONE "\\s\+[eE][nN][dD]" + +" ==================== +" Highlighting Settings {{{2 +" ==================== + +if !exists("skip_vim_syntax_inits") + if !exists("g:vimsyn_noerror") + hi def link vimBehaveError vimError + hi def link vimCollClassErr vimError + hi def link vimErrSetting vimError + hi def link vimEmbedError vimError + hi def link vimFTError vimError + hi def link vimFunctionError vimError + hi def link vimFunc vimError + hi def link vimHiAttribList vimError + hi def link vimHiCtermError vimError + hi def link vimHiKeyError vimError + hi def link vimKeyCodeError vimError + hi def link vimMapModErr vimError + hi def link vimSubstFlagErr vimError + hi def link vimSynCaseError vimError + hi def link vimBufnrWarn vimWarn + endif + + hi def link vimAbb vimCommand + hi def link vimAddress vimMark + hi def link vimAugroupError vimError + hi def link vimAugroupKey vimCommand + hi def link vimAuHighlight vimHighlight + hi def link vimAutoCmdOpt vimOption + hi def link vimAutoCmd vimCommand + hi def link vimAutoEvent Type + hi def link vimAutoSet vimCommand + hi def link vimBehaveModel vimBehave + hi def link vimBehave vimCommand + hi def link vimBracket Delimiter + hi def link vimCmplxRepeat SpecialChar + hi def link vimCommand Statement + hi def link vimComment Comment + hi def link vimCommentString vimString + hi def link vimCommentTitle PreProc + hi def link vimCondHL vimCommand + hi def link vimContinue Special + hi def link vimCtrlChar SpecialChar + hi def link vimEchoHLNone vimGroup + hi def link vimEchoHL vimCommand + hi def link vimElseIfErr Error + hi def link vimElseif vimCondHL + hi def link vimEnvvar PreProc + hi def link vimError Error + hi def link vimFBVar vimVar + hi def link vimFgBgAttrib vimHiAttrib + hi def link vimFold Folded + hi def link vimFTCmd vimCommand + hi def link vimFTOption vimSynType + hi def link vimFuncKey vimCommand + hi def link vimFuncName Function + hi def link vimFuncSID Special + hi def link vimFuncVar Identifier + hi def link vimGroupAdd vimSynOption + hi def link vimGroupName vimGroup + hi def link vimGroupRem vimSynOption + hi def link vimGroupSpecial Special + hi def link vimGroup Type + hi def link vimHiAttrib PreProc + hi def link vimHiClear vimHighlight + hi def link vimHiCtermFgBg vimHiTerm + hi def link vimHiCTerm vimHiTerm + hi def link vimHighlight vimCommand + hi def link vimHiGroup vimGroupName + hi def link vimHiGuiFgBg vimHiTerm + hi def link vimHiGuiFont vimHiTerm + hi def link vimHiGuiRgb vimNumber + hi def link vimHiGui vimHiTerm + hi def link vimHiNmbr Number + hi def link vimHiStartStop vimHiTerm + hi def link vimHiTerm Type + hi def link vimHLGroup vimGroup + hi def link vimHLMod PreProc + hi def link vimInsert vimString + hi def link vimIskSep Delimiter + hi def link vimKeyCode vimSpecFile + hi def link vimKeyword Statement + hi def link vimLet vimCommand + hi def link vimLineComment vimComment + hi def link vimMapBang vimCommand + hi def link vimMapModKey vimFuncSID + hi def link vimMapMod vimBracket + hi def link vimMap vimCommand + hi def link vimMark Number + hi def link vimMarkNumber vimNumber + hi def link vimMenuMod vimMapMod + hi def link vimMenuNameMore vimMenuName + hi def link vimMenuName PreProc + hi def link vimMtchComment vimComment + hi def link vimNorm vimCommand + hi def link vimNotation Special + hi def link vimNotFunc vimCommand + hi def link vimNotPatSep vimString + hi def link vimNumber Number + hi def link vimOperError Error + hi def link vimOper Operator + hi def link vimOption PreProc + hi def link vimParenSep Delimiter + hi def link vimPatSepErr vimPatSep + hi def link vimPatSepR vimPatSep + hi def link vimPatSep SpecialChar + hi def link vimPatSepZone vimString + hi def link vimPatSepZ vimPatSep + hi def link vimPattern Type + hi def link vimPlainMark vimMark + hi def link vimPlainRegister vimRegister + hi def link vimRegister SpecialChar + hi def link vimScriptDelim Comment + hi def link vimSearchDelim Statement + hi def link vimSearch vimString + hi def link vimSep Delimiter + hi def link vimSetMod vimOption + hi def link vimSetSep Statement + hi def link vimSetString vimString + hi def link vimSpecFile Identifier + hi def link vimSpecFileMod vimSpecFile + hi def link vimSpecial Type + hi def link vimStatement Statement + hi def link vimStringCont vimString + hi def link vimString String + hi def link vimSubst1 vimSubst + hi def link vimSubstDelim Delimiter + hi def link vimSubstFlags Special + hi def link vimSubstSubstr SpecialChar + hi def link vimSubstTwoBS vimString + hi def link vimSubst vimCommand + hi def link vimSynCaseError Error + hi def link vimSynCase Type + hi def link vimSyncC Type + hi def link vimSyncError Error + hi def link vimSyncGroupName vimGroupName + hi def link vimSyncGroup vimGroupName + hi def link vimSyncKey Type + hi def link vimSyncNone Type + hi def link vimSynContains vimSynOption + hi def link vimSynError Error + hi def link vimSynKeyContainedin vimSynContains + hi def link vimSynKeyOpt vimSynOption + hi def link vimSynMtchGrp vimSynOption + hi def link vimSynMtchOpt vimSynOption + hi def link vimSynNextgroup vimSynOption + hi def link vimSynNotPatRange vimSynRegPat + hi def link vimSynOption Special + hi def link vimSynPatRange vimString + hi def link vimSynRegOpt vimSynOption + hi def link vimSynRegPat vimString + hi def link vimSynReg Type + hi def link vimSyntax vimCommand + hi def link vimSynType vimSpecial + hi def link vimTodo Todo + hi def link vimUnmap vimMap + hi def link vimUserAttrbCmpltFunc Special + hi def link vimUserAttrbCmplt vimSpecial + hi def link vimUserAttrbKey vimOption + hi def link vimUserAttrb vimSpecial + hi def link vimUserAttrbError Error + hi def link vimUserCmdError Error + hi def link vimUserCommand vimCommand + hi def link vimUserFunc Normal + hi def link vimVar Identifier + hi def link vimWarn WarningMsg +endif + +" Current Syntax Variable: {{{2 +let b:current_syntax = "vim" + +" --------------------------------------------------------------------- +" Cleanup: {{{1 +delc VimFolda +delc VimFoldf +delc VimFoldl +delc VimFoldm +delc VimFoldp +delc VimFoldP +delc VimFoldr +delc VimFoldt +let &cpo = s:keepcpo +unlet s:keepcpo +" vim:ts=18 fdm=marker + +endif diff --git a/syntax/viminfo.vim b/syntax/viminfo.vim new file mode 100644 index 0000000..42b9d49 --- /dev/null +++ b/syntax/viminfo.vim @@ -0,0 +1,52 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Vim .viminfo file +" Maintainer: Bram Moolenaar +" Last Change: 2016 Jun 05 + +" Quit when a (custom) syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" The lines that are NOT recognized +syn match viminfoError "^[^\t].*" + +" The one-character one-liners that are recognized +syn match viminfoStatement "^[/&$@:?=%!<]" + +" The two-character one-liners that are recognized +syn match viminfoStatement "^[-'>"]." +syn match viminfoStatement +^"".+ +syn match viminfoStatement "^\~[/&]" +syn match viminfoStatement "^\~[hH]" +syn match viminfoStatement "^\~[mM][sS][lL][eE]\d\+\~\=[/&]" + +syn match viminfoOption "^\*.*=" contains=viminfoOptionName +syn match viminfoOptionName "\*\a*"ms=s+1 contained + +" Comments +syn match viminfoComment "^#.*" + +" New style lines. TODO: highlight numbers and strings. +syn match viminfoNew "^|.*" + +" Define the default highlighting. +" Only used when an item doesn't have highlighting yet +hi def link viminfoComment Comment +hi def link viminfoError Error +hi def link viminfoStatement Statement +hi def link viminfoNew String + +let b:current_syntax = "viminfo" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/virata.vim b/syntax/virata.vim new file mode 100644 index 0000000..60200de --- /dev/null +++ b/syntax/virata.vim @@ -0,0 +1,211 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Virata AConfig Configuration Script +" Maintainer: Manuel M.H. Stol +" Last Change: 2003 May 11 +" Vim URL: http://www.vim.org/lang.html +" Virata URL: http://www.globespanvirata.com/ + + +" Virata AConfig Configuration Script syntax +" Can be detected by: 1) Extension .hw, .sw, .pkg and .module +" 2) The file name pattern "mk.*\.cfg" +" 3) The string "Virata" in the first 5 lines + + +" Setup Syntax: +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif +" Virata syntax is case insensitive (mostly) +syn case ignore + + + +" Comments: +" Virata comments start with %, but % is not a keyword character +syn region virataComment start="^%" start="\s%"lc=1 keepend end="$" contains=@virataGrpInComments +syn region virataSpclComment start="^%%" start="\s%%"lc=1 keepend end="$" contains=@virataGrpInComments +syn keyword virataInCommentTodo contained TODO FIXME XXX[XXXXX] REVIEW TBD +syn cluster virataGrpInComments contains=virataInCommentTodo +syn cluster virataGrpComments contains=@virataGrpInComments,virataComment,virataSpclComment + + +" Constants: +syn match virataStringError +["]+ +syn region virataString start=+"+ skip=+\(\\\\\|\\"\)+ end=+"+ oneline contains=virataSpclCharError,virataSpclChar,@virataGrpDefSubsts +syn match virataCharacter +'[^']\{-}'+ contains=virataSpclCharError,virataSpclChar +syn match virataSpclChar contained +\\\(x\x\+\|\o\{1,3}\|['\"?\\abefnrtv]\)+ +syn match virataNumberError "\<\d\{-1,}\I\{-1,}\>" +syn match virataNumberError "\<0x\x*\X\x*\>" +syn match virataNumberError "\<\d\+\.\d*\(e[+-]\=\d\+\)\=\>" +syn match virataDecNumber "\<\d\+U\=L\=\>" +syn match virataHexNumber "\<0x\x\+U\=L\=\>" +syn match virataSizeNumber "\<\d\+[BKM]\>"he=e-1 +syn match virataSizeNumber "\<\d\+[KM]B\>"he=e-2 +syn cluster virataGrpNumbers contains=virataNumberError,virataDecNumber,virataHexNumber,virataSizeNumber +syn cluster virataGrpConstants contains=@virataGrpNumbers,virataStringError,virataString,virataCharacter,virataSpclChar + + +" Identifiers: +syn match virataIdentError contained "\<\D\S*\>" +syn match virataIdentifier contained "\<\I\i\{-}\(\-\i\{-1,}\)*\>" contains=@virataGrpDefSubsts +syn match virataFileIdent contained "\F\f*" contains=@virataGrpDefSubsts +syn cluster virataGrpIdents contains=virataIdentifier,virataIdentError +syn cluster virataGrpFileIdents contains=virataFileIdent,virataIdentError + + +" Statements: +syn match virataStatement "^\s*Config\(\(/Kernel\)\=\.\(hs\=\|s\)\)\=\>" +syn match virataStatement "^\s*Config\s\+\I\i\{-}\(\-\i\{-1,}\)*\.\(hs\=\|s\)\>" +syn match virataStatement "^\s*Make\.\I\i\{-}\(\-\i\{-1}\)*\>" skipwhite nextgroup=@virataGrpIdents +syn match virataStatement "^\s*Make\.c\(at\)\=++\s"me=e-1 skipwhite nextgroup=@virataGrpIdents +syn match virataStatement "^\s*\(Architecture\|GetEnv\|Reserved\|\(Un\)\=Define\|Version\)\>" skipwhite nextgroup=@virataGrpIdents +syn match virataStatement "^\s*\(Hardware\|ModuleSource\|\(Release\)\=Path\|Software\)\>" skipwhite nextgroup=@virataGrpFileIdents +syn match virataStatement "^\s*\(DefaultPri\|Hydrogen\)\>" skipwhite nextgroup=virataDecNumber,virataNumberError +syn match virataStatement "^\s*\(NoInit\|PCI\|SysLink\)\>" +syn match virataStatement "^\s*Allow\s\+\(ModuleConfig\)\>" +syn match virataStatement "^\s*NoWarn\s\+\(Export\|Parse\=able\|Relative]\)\>" +syn match virataStatement "^\s*Debug\s\+O\(ff\|n\)\>" + +" Import (Package |Module from ) +syn region virataImportDef transparent matchgroup=virataStatement start="^\s*Import\>" keepend end="$" contains=virataInImport,virataModuleDef,virataNumberError,virataStringError,@virataGrpDefSubsts +syn match virataInImport contained "\<\(Module\|Package\|from\)\>" skipwhite nextgroup=@virataGrpFileIdents +" Export (Header
|SLibrary ) +syn region virataExportDef transparent matchgroup=virataStatement start="^\s*Export\>" keepend end="$" contains=virataInExport,virataNumberError,virataStringError,@virataGrpDefSubsts +syn match virataInExport contained "\<\(Header\|[SU]Library\)\>" skipwhite nextgroup=@virataGrpFileIdents +" Process is +syn region virataProcessDef transparent matchgroup=virataStatement start="^\s*Process\>" keepend end="$" contains=virataInProcess,virataInExec,virataNumberError,virataStringError,@virataGrpDefSubsts,@virataGrpIdents +syn match virataInProcess contained "\" +" Instance of +syn region virataInstanceDef transparent matchgroup=virataStatement start="^\s*Instance\>" keepend end="$" contains=virataInInstance,virataNumberError,virataStringError,@virataGrpDefSubsts,@virataGrpIdents +syn match virataInInstance contained "\" +" Module from +syn region virataModuleDef transparent matchgroup=virataStatement start="^\s*\(Package\|Module\)\>" keepend end="$" contains=virataInModule,virataNumberError,virataStringError,@virataGrpDefSubsts +syn match virataInModule contained "^\s*Package\>"hs=e-7 skipwhite nextgroup=@virataGrpIdents +syn match virataInModule contained "^\s*Module\>"hs=e-6 skipwhite nextgroup=@virataGrpIdents +syn match virataInModule contained "\" skipwhite nextgroup=@virataGrpFileIdents +" Colour from +syn region virataColourDef transparent matchgroup=virataStatement start="^\s*Colour\>" keepend end="$" contains=virataInColour,virataNumberError,virataStringError,@virataGrpDefSubsts +syn match virataInColour contained "^\s*Colour\>"hs=e-6 skipwhite nextgroup=@virataGrpIdents +syn match virataInColour contained "\" skipwhite nextgroup=@virataGrpFileIdents +" Link {} +" Object {Executable []} +syn match virataStatement "^\s*\(Link\|Object\)" +" Executable [] +syn region virataExecDef transparent matchgroup=virataStatement start="^\s*Executable\>" keepend end="$" contains=virataInExec,virataNumberError,virataStringError +syn match virataInExec contained "^\s*Executable\>" skipwhite nextgroup=@virataGrpDefSubsts,@virataGrpIdents +syn match virataInExec contained "\<\(epilogue\|pro\(logue\|cess\)\|qhandler\)\>" skipwhite nextgroup=@virataGrpDefSubsts,@virataGrpIdents +syn match virataInExec contained "\<\(priority\|stack\)\>" skipwhite nextgroup=@virataGrpDefSubsts,@virataGrpNumbers +" Message {} +" MessageId +syn match virataStatement "^\s*Message\(Id\)\=\>" skipwhite nextgroup=@virataGrpNumbers +" MakeRule {} +syn region virataMakeDef transparent matchgroup=virataStatement start="^\s*MakeRule\>" keepend end="$" contains=virataInMake,@virataGrpDefSubsts +syn case match +syn match virataInMake contained "\" +syn case ignore +" (Append|Edit|Copy)Rule +syn match virataStatement "^\s*\(Append\|Copy\|Edit\)Rule\>" +" AlterRules in +syn region virataAlterDef transparent matchgroup=virataStatement start="^\s*AlterRules\>" keepend end="$" contains=virataInAlter,@virataGrpDefSubsts +syn match virataInAlter contained "\" skipwhite nextgroup=@virataGrpIdents +" Clustering +syn cluster virataGrpInStatmnts contains=virataInImport,virataInExport,virataInExec,virataInProcess,virataInAlter,virataInInstance,virataInModule,virataInColour +syn cluster virataGrpStatements contains=@virataGrpInStatmnts,virataStatement,virataImportDef,virataExportDef,virataExecDef,virataProcessDef,virataAlterDef,virataInstanceDef,virataModuleDef,virataColourDef + + +" MkFlash.Cfg File Statements: +syn region virataCfgFileDef transparent matchgroup=virataCfgStatement start="^\s*Dir\>" start="^\s*\a\{-}File\>" start="^\s*OutputFile\d\d\=\>" start="^\s*\a\w\{-}[NP]PFile\>" keepend end="$" contains=@virataGrpFileIdents +syn region virataCfgSizeDef transparent matchgroup=virataCfgStatement start="^\s*\a\{-}Size\>" start="^\s*ConfigInfo\>" keepend end="$" contains=@virataGrpNumbers,@virataGrpDefSubsts,virataIdentError +syn region virataCfgNumberDef transparent matchgroup=virataCfgStatement start="^\s*FlashchipNum\(b\(er\=\)\=\)\=\>" start="^\s*Granularity\>" keepend end="$" contains=@virataGrpNumbers,@virataGrpDefSubsts +syn region virataCfgMacAddrDef transparent matchgroup=virataCfgStatement start="^\s*MacAddress\>" keepend end="$" contains=virataNumberError,virataStringError,virataIdentError,virataInMacAddr,@virataGrpDefSubsts +syn match virataInMacAddr contained "\x[:]\x\{1,2}\>"lc=2 +syn match virataInMacAddr contained "\s\x\{1,2}[:]\x"lc=1,me=e-1,he=e-2 nextgroup=virataInMacAddr +syn match virataCfgStatement "^\s*Target\>" skipwhite nextgroup=@virataGrpIdents +syn cluster virataGrpCfgs contains=virataCfgStatement,virataCfgFileDef,virataCfgSizeDef,virataCfgNumberDef,virataCfgMacAddrDef,virataInMacAddr + + + +" PreProcessor Instructions: +" Defines +syn match virataDefine "^\s*\(Un\)\=Set\>" skipwhite nextgroup=@virataGrpIdents +syn match virataInclude "^\s*Include\>" skipwhite nextgroup=@virataGrpFileIdents +syn match virataDefSubstError "[^$]\$"lc=1 +syn match virataDefSubstError "\$\(\w\|{\(.\{-}}\)\=\)" +syn case match +syn match virataDefSubst "\$\(\d\|[DINORS]\|{\I\i\{-}\(\-\i\{-1,}\)*}\)" +syn case ignore +" Conditionals +syn cluster virataGrpCntnPreCon contains=ALLBUT,@virataGrpInComments,@virataGrpFileIdents,@virataGrpInStatmnts +syn region virataPreConDef transparent matchgroup=virataPreCondit start="^\s*If\>" end="^\s*Endif\>" contains=@virataGrpCntnPreCon +syn match virataPreCondit contained "^\s*Else\(\s\+If\)\=\>" +syn region virataPreConDef transparent matchgroup=virataPreCondit start="^\s*ForEach\>" end="^\s*Done\>" contains=@virataGrpCntnPreCon +" Pre-Processors +syn region virataPreProc start="^\s*Error\>" start="^\s*Warning\>" oneline end="$" contains=@virataGrpConstants,@virataGrpDefSubsts +syn cluster virataGrpDefSubsts contains=virataDefSubstError,virataDefSubst +syn cluster virataGrpPreProcs contains=@virataGrpDefSubsts,virataDefine,virataInclude,virataPreConDef,virataPreCondit,virataPreProc + + +" Synchronize Syntax: +syn sync clear +syn sync minlines=50 "for multiple region nesting + + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" Sub Links: +hi def link virataDefSubstError virataPreProcError +hi def link virataDefSubst virataPreProc +hi def link virataInAlter virataOperator +hi def link virataInExec virataOperator +hi def link virataInExport virataOperator +hi def link virataInImport virataOperator +hi def link virataInInstance virataOperator +hi def link virataInMake virataOperator +hi def link virataInModule virataOperator +hi def link virataInProcess virataOperator +hi def link virataInMacAddr virataHexNumber + +" Comment Group: +hi def link virataComment Comment +hi def link virataSpclComment SpecialComment +hi def link virataInCommentTodo Todo + +" Constant Group: +hi def link virataString String +hi def link virataStringError Error +hi def link virataCharacter Character +hi def link virataSpclChar Special +hi def link virataDecNumber Number +hi def link virataHexNumber Number +hi def link virataSizeNumber Number +hi def link virataNumberError Error + +" Identifier Group: +hi def link virataIdentError Error + +" PreProc Group: +hi def link virataPreProc PreProc +hi def link virataDefine Define +hi def link virataInclude Include +hi def link virataPreCondit PreCondit +hi def link virataPreProcError Error +hi def link virataPreProcWarn Todo + +" Directive Group: +hi def link virataStatement Statement +hi def link virataCfgStatement Statement +hi def link virataOperator Operator +hi def link virataDirective Keyword + + +let b:current_syntax = "virata" + +" vim:ts=8:sw=2:noet: + +endif diff --git a/syntax/vmasm.vim b/syntax/vmasm.vim new file mode 100644 index 0000000..1eb54e2 --- /dev/null +++ b/syntax/vmasm.vim @@ -0,0 +1,242 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: (VAX) Macro Assembly +" Maintainer: Tom Uijldert +" Last change: 2004 May 16 +" +" This is incomplete. Feel free to contribute... +" + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" Partial list of register symbols +syn keyword vmasmReg r0 r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 +syn keyword vmasmReg ap fp sp pc iv dv + +" All matches - order is important! +syn keyword vmasmOpcode adawi adwc ashl ashq bitb bitw bitl decb decw decl +syn keyword vmasmOpcode ediv emul incb incw incl mcomb mcomw mcoml +syn keyword vmasmOpcode movzbw movzbl movzwl popl pushl rotl sbwc +syn keyword vmasmOpcode cmpv cmpzv cmpc3 cmpc5 locc matchc movc3 movc5 +syn keyword vmasmOpcode movtc movtuc scanc skpc spanc crc extv extzv +syn keyword vmasmOpcode ffc ffs insv aobleq aoblss bbc bbs bbcci bbssi +syn keyword vmasmOpcode blbc blbs brb brw bsbb bsbw caseb casew casel +syn keyword vmasmOpcode jmp jsb rsb sobgeq sobgtr callg calls ret +syn keyword vmasmOpcode bicpsw bispsw bpt halt index movpsl nop popr pushr xfc +syn keyword vmasmOpcode insqhi insqti insque remqhi remqti remque +syn keyword vmasmOpcode addp4 addp6 ashp cmpp3 cmpp4 cvtpl cvtlp cvtps cvtpt +syn keyword vmasmOpcode cvtsp cvttp divp movp mulp subp4 subp6 editpc +syn keyword vmasmOpcode prober probew rei ldpctx svpctx mfpr mtpr bugw bugl +syn keyword vmasmOpcode vldl vldq vgathl vgathq vstl vstq vscatl vscatq +syn keyword vmasmOpcode vvcvt iota mfvp mtvp vsync +syn keyword vmasmOpcode beql[u] bgtr[u] blss[u] +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" +syn match vmasmOpcode "\" + +" Various number formats +syn match vmasmdecNumber "[+-]\=[0-9]\+\>" +syn match vmasmdecNumber "^d[0-9]\+\>" +syn match vmasmhexNumber "^x[0-9a-f]\+\>" +syn match vmasmoctNumber "^o[0-7]\+\>" +syn match vmasmbinNumber "^b[01]\+\>" +syn match vmasmfloatNumber "[-+]\=[0-9]\+E[-+]\=[0-9]\+" +syn match vmasmfloatNumber "[-+]\=[0-9]\+\.[0-9]*\(E[-+]\=[0-9]\+\)\=" + +" Valid labels +syn match vmasmLabel "^[a-z_$.][a-z0-9_$.]\{,30}::\=" +syn match vmasmLabel "\<[0-9]\{1,5}\$:\=" " Local label + +" Character string constants +" Too complex really. Could be "<...>" but those could also be +" expressions. Don't know how to handle chosen delimiters +" ("^...") +" syn region vmasmString start="<" end=">" oneline + +" Operators +syn match vmasmOperator "[-+*/@&!\\]" +syn match vmasmOperator "=" +syn match vmasmOperator "==" " Global assignment +syn match vmasmOperator "%length(.*)" +syn match vmasmOperator "%locate(.*)" +syn match vmasmOperator "%extract(.*)" +syn match vmasmOperator "^[amfc]" +syn match vmasmOperator "[bwlg]^" + +syn match vmasmOperator "\<\(not_\)\=equal\>" +syn match vmasmOperator "\" +syn match vmasmOperator "\" +syn match vmasmOperator "\" +syn match vmasmOperator "\<\(not_\)\=defined\>" +syn match vmasmOperator "\<\(not_\)\=blank\>" +syn match vmasmOperator "\" +syn match vmasmOperator "\" +syn match vmasmOperator "\" +syn match vmasmOperator "\<[gl]t\>" +syn match vmasmOperator "\" +syn match vmasmOperator "\" +syn match vmasmOperator "\" +syn match vmasmOperator "\<[nlg]e\>" +syn match vmasmOperator "\" + +" Special items for comments +syn keyword vmasmTodo contained todo + +" Comments +syn match vmasmComment ";.*" contains=vmasmTodo + +" Include +syn match vmasmInclude "\.library\>" + +" Macro definition +syn match vmasmMacro "\.macro\>" +syn match vmasmMacro "\.mexit\>" +syn match vmasmMacro "\.endm\>" +syn match vmasmMacro "\.mcall\>" +syn match vmasmMacro "\.mdelete\>" + +" Conditional assembly +syn match vmasmPreCond "\.iff\=\>" +syn match vmasmPreCond "\.if_false\>" +syn match vmasmPreCond "\.iftf\=\>" +syn match vmasmPreCond "\.if_true\(_false\)\=\>" +syn match vmasmPreCond "\.iif\>" + +" Loop control +syn match vmasmRepeat "\.irpc\=\>" +syn match vmasmRepeat "\.repeat\>" +syn match vmasmRepeat "\.rept\>" +syn match vmasmRepeat "\.endr\>" + +" Directives +syn match vmasmDirective "\.address\>" +syn match vmasmDirective "\.align\>" +syn match vmasmDirective "\.asci[cdiz]\>" +syn match vmasmDirective "\.blk[abdfghloqw]\>" +syn match vmasmDirective "\.\(signed_\)\=byte\>" +syn match vmasmDirective "\.\(no\)\=cross\>" +syn match vmasmDirective "\.debug\>" +syn match vmasmDirective "\.default displacement\>" +syn match vmasmDirective "\.[dfgh]_floating\>" +syn match vmasmDirective "\.disable\>" +syn match vmasmDirective "\.double\>" +syn match vmasmDirective "\.dsabl\>" +syn match vmasmDirective "\.enable\=\>" +syn match vmasmDirective "\.endc\=\>" +syn match vmasmDirective "\.entry\>" +syn match vmasmDirective "\.error\>" +syn match vmasmDirective "\.even\>" +syn match vmasmDirective "\.external\>" +syn match vmasmDirective "\.extrn\>" +syn match vmasmDirective "\.float\>" +syn match vmasmDirective "\.globa\=l\>" +syn match vmasmDirective "\.ident\>" +syn match vmasmDirective "\.link\>" +syn match vmasmDirective "\.list\>" +syn match vmasmDirective "\.long\>" +syn match vmasmDirective "\.mask\>" +syn match vmasmDirective "\.narg\>" +syn match vmasmDirective "\.nchr\>" +syn match vmasmDirective "\.nlist\>" +syn match vmasmDirective "\.ntype\>" +syn match vmasmDirective "\.octa\>" +syn match vmasmDirective "\.odd\>" +syn match vmasmDirective "\.opdef\>" +syn match vmasmDirective "\.packed\>" +syn match vmasmDirective "\.page\>" +syn match vmasmDirective "\.print\>" +syn match vmasmDirective "\.psect\>" +syn match vmasmDirective "\.quad\>" +syn match vmasmDirective "\.ref[1248]\>" +syn match vmasmDirective "\.ref16\>" +syn match vmasmDirective "\.restore\(_psect\)\=\>" +syn match vmasmDirective "\.save\(_psect\)\=\>" +syn match vmasmDirective "\.sbttl\>" +syn match vmasmDirective "\.\(no\)\=show\>" +syn match vmasmDirective "\.\(sub\)\=title\>" +syn match vmasmDirective "\.transfer\>" +syn match vmasmDirective "\.warn\>" +syn match vmasmDirective "\.weak\>" +syn match vmasmDirective "\.\(signed_\)\=word\>" + +syn case match + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +" The default methods for highlighting. Can be overridden later +" Comment Constant Error Identifier PreProc Special Statement Todo Type +" +" Constant Boolean Character Number String +" Identifier Function +" PreProc Define Include Macro PreCondit +" Special Debug Delimiter SpecialChar SpecialComment Tag +" Statement Conditional Exception Keyword Label Operator Repeat +" Type StorageClass Structure Typedef + +hi def link vmasmComment Comment +hi def link vmasmTodo Todo + +hi def link vmasmhexNumber Number " Constant +hi def link vmasmoctNumber Number " Constant +hi def link vmasmbinNumber Number " Constant +hi def link vmasmdecNumber Number " Constant +hi def link vmasmfloatNumber Number " Constant + +" hi def link vmasmString String " Constant + +hi def link vmasmReg Identifier +hi def link vmasmOperator Identifier + +hi def link vmasmInclude Include " PreProc +hi def link vmasmMacro Macro " PreProc +" hi def link vmasmMacroParam Keyword " Statement + +hi def link vmasmDirective Special +hi def link vmasmPreCond Special + + +hi def link vmasmOpcode Statement +hi def link vmasmCond Conditional " Statement +hi def link vmasmRepeat Repeat " Statement + +hi def link vmasmLabel Type + +let b:current_syntax = "vmasm" + +" vim: ts=8 sw=2 + +endif diff --git a/syntax/voscm.vim b/syntax/voscm.vim new file mode 100644 index 0000000..5dcc74b --- /dev/null +++ b/syntax/voscm.vim @@ -0,0 +1,98 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: VOS CM macro +" Maintainer: Andrew McGill andrewm at lunch.za.net +" Last Change: Apr 06, 2007 +" Version: 1 +" URL: http://lunch.za.net/ +" + +" For version 5.x: Clear all syntax items +" For version 6.x: Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match +" set iskeyword=48-57,_,a-z,A-Z + +syn match voscmStatement "^!" +syn match voscmStatement "&\(label\|begin_parameters\|end_parameters\|goto\|attach_input\|break\|continue\|control\|detach_input\|display_line\|display_line_partial\|echo\|eof\|eval\|if\|mode\|return\|while\|set\|set_string\|then\|else\|do\|done\|end\)\>" +syn match voscmJump "\(&label\|&goto\) *" nextgroup=voscmLabelId +syn match voscmLabelId contained "\<[A-Za-z][A-Z_a-z0-9]* *$" +syn match voscmSetvar "\(&set_string\|&set\) *" nextgroup=voscmVariable +syn match voscmError "\(&set_string\|&set\) *&" +syn match voscmVariable contained "\<[A-Za-z][A-Z_a-z0-9]\+\>" +syn keyword voscmParamKeyword contained number req string switch allow byte disable_input hidden length longword max min no_abbrev output_path req required req_for_form word +syn region voscmParamList matchgroup=voscmParam start="&begin_parameters" end="&end_parameters" contains=voscmParamKeyword,voscmString,voscmParamName,voscmParamId +syn match voscmParamName contained "\(^\s*[A-Za-z_0-9]\+\s\+\)\@<=\k\+" +syn match voscmParamId contained "\(^\s*\)\@<=\k\+" +syn region par1 matchgroup=par1 start=/(/ end=/)/ contains=voscmFunction,voscmIdentifier,voscmString transparent +" FIXME: functions should only be allowed after a bracket ... ie (ask ...): +syn keyword voscmFunction contained abs access after ask before break byte calc ceil command_status concat +syn keyword voscmFunction contained contents path_name copy count current_dir current_module date date_time +syn keyword voscmFunction contained decimal directory_name end_of_file exists file_info floor given group_name +syn keyword voscmFunction contained has_access hexadecimal home_dir index iso_date iso_date_time language_name +syn keyword voscmFunction contained length lock_type locked ltrim master_disk max message min mod module_info +syn keyword voscmFunction contained module_name object_name online path_name person_name process_dir process_info +syn keyword voscmFunction contained process_type quote rank referencing_dir reverse rtrim search +syn keyword voscmFunction contained software_purchased string substitute substr system_name terminal_info +syn keyword voscmFunction contained terminal_name time translate trunc unique_string unquote user_name verify +syn keyword voscmFunction contained where_path +syn keyword voscmTodo contained TODO FIXME XXX DEBUG NOTE +syn match voscmTab "\t\+" + +syn keyword voscmCommand add_entry_names add_library_path add_profile analyze_pc_samples attach_default_output attach_port batch bind break_process c c_preprocess call_thru cancel_batch_requests cancel_device_reservation cancel_print_requests cc change_current_dir check_posix cobol comment_on_manual compare_dirs compare_files convert_text_file copy_dir copy_file copy_tape cpp create_data_object create_deleted_record_index create_dir create_file create_index create_record_index create_tape_volumes cvt_fixed_to_stream cvt_stream_to_fixed debug delete_dir delete_file delete_index delete_library_path detach_default_output detach_port dismount_tape display display_access display_access_list display_batch_status display_current_dir display_current_module display_date_time display_default_access_list display_device_info display_dir_status display_disk_info display_disk_usage display_error display_file display_file_status display_line display_notices display_object_module_info display_print_defaults display_print_status display_program_module display_system_usage display_tape_params display_terminal_parameters dump_file dump_record dump_tape edit edit_form emacs enforce_region_locks fortran get_external_variable give_access give_default_access handle_sig_dfl harvest_pc_samples help kill line_edit link link_dirs list list_batch_requests list_devices list_gateways list_library_paths list_modules list_port_attachments list_print_requests list_process_cmd_limits list_save_tape list_systems list_tape list_terminal_types list_users locate_files locate_large_files login logout mount_tape move_device_reservation move_dir move_file mp_debug nls_edit_form pascal pl1 position_tape preprocess_file print profile propagate_access read_tape ready remove_access remove_default_access rename reserve_device restore_object save_object send_message set set_cpu_time_limit set_expiration_date set_external_variable set_file_allocation set_implicit_locking set_index_flags set_language set_library_paths set_line_wrap_width set_log_protected_file set_owner_access set_pipe_file set_priority set_ready set_safety_switch set_second_tape set_tape_drive_params set_tape_file_params set_tape_mount_params set_terminal_parameters set_text_file set_time_zone sleep sort start_logging start_process stop_logging stop_process tail_file text_data_merge translate_links truncate_file unlink update_batch_requests update_print_requests update_process_cmd_limits use_abbreviations use_message_file vcc verify_posix_access verify_save verify_system_access walk_dir where_command where_path who_locked write_tape + +syn match voscmIdentifier "&[A-Za-z][a-z0-9_A-Z]*&" + +syn match voscmString "'[^']*'" + +" Number formats +syn match voscmNumber "\<\d\+\>" +"Floating point number part only +syn match voscmDecimalNumber "\.\d\+\([eE][-+]\=\d\)\=\>" + +"syn region voscmComment start="^[ ]*&[ ]+" end="$" +"syn match voscmComment "^[ ]*&[ ].*$" +"syn match voscmComment "^&$" +syn region voscmComment start="^[ ]*&[ ]" end="$" contains=voscmTodo +syn match voscmComment "^&$" +syn match voscmContinuation "&+$" + +"syn match voscmIdentifier "[A-Za-z0-9&._-]\+" + +"Synchronization with Statement terminator $ +" syn sync maxlines=100 + +hi def link voscmConditional Conditional +hi def link voscmStatement Statement +hi def link voscmSetvar Statement +hi def link voscmNumber Number +hi def link voscmDecimalNumber Float +hi def link voscmString String +hi def link voscmIdentifier Identifier +hi def link voscmVariable Identifier +hi def link voscmComment Comment +hi def link voscmJump Statement +hi def link voscmContinuation Macro +hi def link voscmLabelId String +hi def link voscmParamList NONE +hi def link voscmParamId Identifier +hi def link voscmParamName String +hi def link voscmParam Statement +hi def link voscmParamKeyword Statement +hi def link voscmFunction Function +hi def link voscmCommand Structure +"hi def link voscmIdentifier NONE +"hi def link voscmSpecial Special " not used +hi def link voscmTodo Todo +hi def link voscmTab Error +hi def link voscmError Error + +let b:current_syntax = "voscm" + +" vim: ts=8 + +endif diff --git a/syntax/vrml.vim b/syntax/vrml.vim new file mode 100644 index 0000000..59dc401 --- /dev/null +++ b/syntax/vrml.vim @@ -0,0 +1,226 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: VRML97 +" Modified from: VRML 1.0C by David Brown +" Maintainer: vacancy! +" Former Maintainer: Gregory Seidman +" Last change: 2006 May 03 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" keyword definitions + +syn keyword VRMLFields ambientIntensity appearance attenuation +syn keyword VRMLFields autoOffset avatarSize axisOfRotation backUrl +syn keyword VRMLFields bboxCenter bboxSize beamWidth beginCap +syn keyword VRMLFields bottom bottomRadius bottomUrl ccw center +syn keyword VRMLFields children choice collide color colorIndex +syn keyword VRMLFields colorPerVertex convex coord coordIndex +syn keyword VRMLFields creaseAngle crossSection cutOffAngle +syn keyword VRMLFields cycleInterval description diffuseColor +syn keyword VRMLFields directOutput direction diskAngle +syn keyword VRMLFields emissiveColor enabled endCap family +syn keyword VRMLFields fieldOfView fogType fontStyle frontUrl +syn keyword VRMLFields geometry groundAngle groundColor headlight +syn keyword VRMLFields height horizontal info intensity jump +syn keyword VRMLFields justify key keyValue language leftToRight +syn keyword VRMLFields leftUrl length level location loop material +syn keyword VRMLFields maxAngle maxBack maxExtent maxFront +syn keyword VRMLFields maxPosition minAngle minBack minFront +syn keyword VRMLFields minPosition mustEvaluate normal normalIndex +syn keyword VRMLFields normalPerVertex offset on orientation +syn keyword VRMLFields parameter pitch point position priority +syn keyword VRMLFields proxy radius range repeatS repeatT rightUrl +syn keyword VRMLFields rotation scale scaleOrientation shininess +syn keyword VRMLFields side size skyAngle skyColor solid source +syn keyword VRMLFields spacing spatialize specularColor speed spine +syn keyword VRMLFields startTime stopTime string style texCoord +syn keyword VRMLFields texCoordIndex texture textureTransform title +syn keyword VRMLFields top topToBottom topUrl translation +syn keyword VRMLFields transparency type url vector visibilityLimit +syn keyword VRMLFields visibilityRange whichChoice xDimension +syn keyword VRMLFields xSpacing zDimension zSpacing +syn match VRMLFields "\<[A-Za-z_][A-Za-z0-9_]*\>" contains=VRMLComment,VRMLProtos,VRMLfTypes +" syn match VRMLFields "\<[A-Za-z_][A-Za-z0-9_]*\>\(,\|\s\)*\(#.*$\)*\\(#.*$\)*\(,\|\s\)*\<[A-Za-z_][A-Za-z0-9_]*\>\(,\|\s\)*\(#.*$\)*" contains=VRMLComment,VRMLProtos +" syn region VRMLFields start="\<[A-Za-z_][A-Za-z0-9_]*\>" end=+\(,\|#\|\s\)+me=e-1 contains=VRMLComment,VRMLProtos + +syn keyword VRMLEvents addChildren ambientIntensity_changed +syn keyword VRMLEvents appearance_changed attenuation_changed +syn keyword VRMLEvents autoOffset_changed avatarSize_changed +syn keyword VRMLEvents axisOfRotation_changed backUrl_changed +syn keyword VRMLEvents beamWidth_changed bindTime bottomUrl_changed +syn keyword VRMLEvents center_changed children_changed +syn keyword VRMLEvents choice_changed collideTime collide_changed +syn keyword VRMLEvents color_changed coord_changed +syn keyword VRMLEvents cutOffAngle_changed cycleInterval_changed +syn keyword VRMLEvents cycleTime description_changed +syn keyword VRMLEvents diffuseColor_changed direction_changed +syn keyword VRMLEvents diskAngle_changed duration_changed +syn keyword VRMLEvents emissiveColor_changed enabled_changed +syn keyword VRMLEvents enterTime exitTime fogType_changed +syn keyword VRMLEvents fontStyle_changed fraction_changed +syn keyword VRMLEvents frontUrl_changed geometry_changed +syn keyword VRMLEvents groundAngle_changed headlight_changed +syn keyword VRMLEvents hitNormal_changed hitPoint_changed +syn keyword VRMLEvents hitTexCoord_changed intensity_changed +syn keyword VRMLEvents isActive isBound isOver jump_changed +syn keyword VRMLEvents keyValue_changed key_changed leftUrl_changed +syn keyword VRMLEvents length_changed level_changed +syn keyword VRMLEvents location_changed loop_changed +syn keyword VRMLEvents material_changed maxAngle_changed +syn keyword VRMLEvents maxBack_changed maxExtent_changed +syn keyword VRMLEvents maxFront_changed maxPosition_changed +syn keyword VRMLEvents minAngle_changed minBack_changed +syn keyword VRMLEvents minFront_changed minPosition_changed +syn keyword VRMLEvents normal_changed offset_changed on_changed +syn keyword VRMLEvents orientation_changed parameter_changed +syn keyword VRMLEvents pitch_changed point_changed position_changed +syn keyword VRMLEvents priority_changed radius_changed +syn keyword VRMLEvents removeChildren rightUrl_changed +syn keyword VRMLEvents rotation_changed scaleOrientation_changed +syn keyword VRMLEvents scale_changed set_ambientIntensity +syn keyword VRMLEvents set_appearance set_attenuation +syn keyword VRMLEvents set_autoOffset set_avatarSize +syn keyword VRMLEvents set_axisOfRotation set_backUrl set_beamWidth +syn keyword VRMLEvents set_bind set_bottomUrl set_center +syn keyword VRMLEvents set_children set_choice set_collide +syn keyword VRMLEvents set_color set_colorIndex set_coord +syn keyword VRMLEvents set_coordIndex set_crossSection +syn keyword VRMLEvents set_cutOffAngle set_cycleInterval +syn keyword VRMLEvents set_description set_diffuseColor +syn keyword VRMLEvents set_direction set_diskAngle +syn keyword VRMLEvents set_emissiveColor set_enabled set_fogType +syn keyword VRMLEvents set_fontStyle set_fraction set_frontUrl +syn keyword VRMLEvents set_geometry set_groundAngle set_headlight +syn keyword VRMLEvents set_height set_intensity set_jump set_key +syn keyword VRMLEvents set_keyValue set_leftUrl set_length +syn keyword VRMLEvents set_level set_location set_loop set_material +syn keyword VRMLEvents set_maxAngle set_maxBack set_maxExtent +syn keyword VRMLEvents set_maxFront set_maxPosition set_minAngle +syn keyword VRMLEvents set_minBack set_minFront set_minPosition +syn keyword VRMLEvents set_normal set_normalIndex set_offset set_on +syn keyword VRMLEvents set_orientation set_parameter set_pitch +syn keyword VRMLEvents set_point set_position set_priority +syn keyword VRMLEvents set_radius set_rightUrl set_rotation +syn keyword VRMLEvents set_scale set_scaleOrientation set_shininess +syn keyword VRMLEvents set_size set_skyAngle set_skyColor +syn keyword VRMLEvents set_source set_specularColor set_speed +syn keyword VRMLEvents set_spine set_startTime set_stopTime +syn keyword VRMLEvents set_string set_texCoord set_texCoordIndex +syn keyword VRMLEvents set_texture set_textureTransform set_topUrl +syn keyword VRMLEvents set_translation set_transparency set_type +syn keyword VRMLEvents set_url set_vector set_visibilityLimit +syn keyword VRMLEvents set_visibilityRange set_whichChoice +syn keyword VRMLEvents shininess_changed size_changed +syn keyword VRMLEvents skyAngle_changed skyColor_changed +syn keyword VRMLEvents source_changed specularColor_changed +syn keyword VRMLEvents speed_changed startTime_changed +syn keyword VRMLEvents stopTime_changed string_changed +syn keyword VRMLEvents texCoord_changed textureTransform_changed +syn keyword VRMLEvents texture_changed time topUrl_changed +syn keyword VRMLEvents touchTime trackPoint_changed +syn keyword VRMLEvents translation_changed transparency_changed +syn keyword VRMLEvents type_changed url_changed value_changed +syn keyword VRMLEvents vector_changed visibilityLimit_changed +syn keyword VRMLEvents visibilityRange_changed whichChoice_changed +syn region VRMLEvents start="\S+[^0-9]+\.[A-Za-z_]+"ms=s+1 end="\(,\|$\|\s\)"me=e-1 + +syn keyword VRMLNodes Anchor Appearance AudioClip Background +syn keyword VRMLNodes Billboard Box Collision Color +syn keyword VRMLNodes ColorInterpolator Cone Coordinate +syn keyword VRMLNodes CoordinateInterpolator Cylinder +syn keyword VRMLNodes CylinderSensor DirectionalLight +syn keyword VRMLNodes ElevationGrid Extrusion Fog FontStyle +syn keyword VRMLNodes Group ImageTexture IndexedFaceSet +syn keyword VRMLNodes IndexedLineSet Inline LOD Material +syn keyword VRMLNodes MovieTexture NavigationInfo Normal +syn keyword VRMLNodes NormalInterpolator OrientationInterpolator +syn keyword VRMLNodes PixelTexture PlaneSensor PointLight +syn keyword VRMLNodes PointSet PositionInterpolator +syn keyword VRMLNodes ProximitySensor ScalarInterpolator +syn keyword VRMLNodes Script Shape Sound Sphere SphereSensor +syn keyword VRMLNodes SpotLight Switch Text TextureCoordinate +syn keyword VRMLNodes TextureTransform TimeSensor TouchSensor +syn keyword VRMLNodes Transform Viewpoint VisibilitySensor +syn keyword VRMLNodes WorldInfo + +" the following line doesn't catch since \n +" doesn't match as an atom yet :-( +syn match VRMLNodes "[A-Za-z_][A-Za-z0-9_]*\(,\|\s\)*{"me=e-1 +syn region VRMLNodes start="\\(,\|\s\)*[A-Za-z_]"ms=e start="\\(,\|\s\)*" end="[\s]*\["me=e-1 contains=VRMLProtos,VRMLComment +syn region VRMLNodes start="PROTO\>\(,\|\s\)*[A-Za-z_]"ms=e start="PROTO\>\(,\|\s\)*" end="[\s]*\["me=e-1 contains=VRMLProtos,VRMLComment + +syn keyword VRMLTypes SFBool SFColor MFColor SFFloat MFFloat +syn keyword VRMLTypes SFImage SFInt32 MFInt32 SFNode MFNode +syn keyword VRMLTypes SFRotation MFRotation SFString MFString +syn keyword VRMLTypes SFTime MFTime SFVec2f MFVec2f SFVec3f MFVec3f + +syn keyword VRMLfTypes field exposedField eventIn eventOut + +syn keyword VRMLValues TRUE FALSE NULL + +syn keyword VRMLProtos contained EXTERNPROTO PROTO IS + +syn keyword VRMLRoutes contained ROUTE TO + +"containment! +syn include @jscript $VIMRUNTIME/syntax/javascript.vim +syn region VRMLjScriptString contained start=+"\(\(javascript\)\|\(vrmlscript\)\|\(ecmascript\)\):+ms=e+1 skip=+\\\\\|\\"+ end=+"+me=e-1 contains=@jscript + +" match definitions. +syn match VRMLSpecial contained "\\[0-9][0-9][0-9]\|\\." +syn region VRMLString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=VRMLSpecial,VRMLjScriptString +syn match VRMLCharacter "'[^\\]'" +syn match VRMLSpecialCharacter "'\\.'" +syn match VRMLNumber "[-+]\=\<[0-9]\+\(\.[0-9]\+\)\=\([eE]\{1}[-+]\=[0-9]\+\)\=\>\|0[xX][0-9a-fA-F]\+\>" +syn match VRMLNumber "0[xX][0-9a-fA-F]\+\>" +syn match VRMLComment "#.*$" + +" newlines should count as whitespace, but they can't be matched yet :-( +syn region VRMLRouteNode start="[^O]TO\(,\|\s\)*" end="\."me=e-1 contains=VRMLRoutes,VRMLComment +syn region VRMLRouteNode start="ROUTE\(,\|\s\)*" end="\."me=e-1 contains=VRMLRoutes,VRMLComment +syn region VRMLInstName start="DEF\>"hs=e+1 skip="DEF\(,\|\s\)*" end="[A-Za-z0-9_]\(\s\|$\|,\)"me=e contains=VRMLInstances,VRMLComment +syn region VRMLInstName start="USE\>"hs=e+1 skip="USE\(,\|\s\)*" end="[A-Za-z0-9_]\(\s\|$\|,\)"me=e contains=VRMLInstances,VRMLComment + +syn keyword VRMLInstances contained DEF USE +syn sync minlines=1 + +"FOLDS! +syn sync fromstart +"setlocal foldmethod=syntax +syn region braceFold start="{" end="}" transparent fold contains=TOP +syn region bracketFold start="\[" end="]" transparent fold contains=TOP +syn region VRMLString start=+"+ skip=+\\\\\|\\"+ end=+"+ fold contains=VRMLSpecial,VRMLjScriptString + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link VRMLCharacter VRMLString +hi def link VRMLSpecialCharacter VRMLSpecial +hi def link VRMLNumber VRMLString +hi def link VRMLValues VRMLString +hi def link VRMLString String +hi def link VRMLSpecial Special +hi def link VRMLComment Comment +hi def link VRMLNodes Statement +hi def link VRMLFields Type +hi def link VRMLEvents Type +hi def link VRMLfTypes LineNr +" hi VRMLfTypes ctermfg=6 guifg=Brown +hi def link VRMLInstances PreCondit +hi def link VRMLRoutes PreCondit +hi def link VRMLProtos PreProc +hi def link VRMLRouteNode Identifier +hi def link VRMLInstName Identifier +hi def link VRMLTypes Identifier + + +let b:current_syntax = "vrml" + +" vim: ts=8 + +endif diff --git a/syntax/vroom.vim b/syntax/vroom.vim new file mode 100644 index 0000000..fd26b26 --- /dev/null +++ b/syntax/vroom.vim @@ -0,0 +1,114 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Vroom (vim testing and executable documentation) +" Maintainer: David Barnett (https://github.com/google/vim-ft-vroom) +" Last Change: 2014 Jul 23 + +" quit when a syntax file was already loaded +if exists('b:current_syntax') + finish +endif + +let s:cpo_save = &cpo +set cpo-=C + + +syn include @vroomVim syntax/vim.vim +syn include @vroomShell syntax/sh.vim + +syntax region vroomAction + \ matchgroup=vroomOutput + \ start='\m^ ' end='\m$' keepend + \ contains=vroomControlBlock + +syntax region vroomAction + \ matchgroup=vroomOutput + \ start='\m^ & ' end='\m$' keepend + \ contains=vroomControlBlock + +syntax match vroomOutput '\m^ &$' + +syntax region vroomMessageBody + \ matchgroup=vroomMessage + \ start='\m^ \~ ' end='\m$' keepend + \ contains=vroomControlBlock + +syntax region vroomColoredAction + \ matchgroup=vroomInput + \ start='\m^ > ' end='\m$' keepend + \ contains=vimNotation,vroomControlBlock +syntax region vroomAction + \ matchgroup=vroomInput + \ start='\m^ % ' end='\m$' keepend + \ contains=vimNotation,vroomControlBlock + +syntax region vroomAction + \ matchgroup=vroomContinuation + \ start='\m^ |' end='\m$' keepend + +syntax region vroomAction + \ start='\m^ \ze:' end='\m$' keepend + \ contains=@vroomVim,vroomControlBlock + +syntax region vroomAction + \ matchgroup=vroomDirective + \ start='\m^ @\i\+' end='\m$' keepend + \ contains=vroomControlBlock + +syntax region vroomSystemAction + \ matchgroup=vroomSystem + \ start='\m^ ! ' end='\m$' keepend + \ contains=@vroomShell,vroomControlBlock + +syntax region vroomHijackAction + \ matchgroup=vroomHijack + \ start='\m^ \$ ' end='\m$' keepend + \ contains=vroomControlBlock + +syntax match vroomControlBlock contains=vroomControlEscape,@vroomControls + \ '\v \([^&()][^()]*\)$' + +syntax match vroomControlEscape '\m&' contained + +syntax cluster vroomControls + \ contains=vroomDelay,vroomMode,vroomBuffer,vroomRange + \,vroomChannel,vroomBind,vroomStrictness +syntax match vroomRange '\v\.(,\+?(\d+|\$)?)?' contained +syntax match vroomRange '\v\d*,\+?(\d+|\$)?' contained +syntax match vroomBuffer '\v\d+,@!' contained +syntax match vroomDelay '\v\d+(\.\d+)?s' contained +syntax match vroomMode '\v<%(regex|glob|verbatim)' contained +syntax match vroomChannel '\v<%(stderr|stdout|command|status)>' contained +syntax match vroomBind '\v' contained +syntax match vroomStrictness '\v\<%(STRICT|RELAXED|GUESS-ERRORS)\>' contained + +highlight default link vroomInput Identifier +highlight default link vroomDirective vroomInput +highlight default link vroomControlBlock vroomInput +highlight default link vroomSystem vroomInput +highlight default link vroomOutput Statement +highlight default link vroomContinuation Constant +highlight default link vroomHijack Special +highlight default link vroomColoredAction Statement +highlight default link vroomSystemAction vroomSystem +highlight default link vroomHijackAction vroomHijack +highlight default link vroomMessage vroomOutput +highlight default link vroomMessageBody Constant + +highlight default link vroomControlEscape Special +highlight default link vroomBuffer vroomInput +highlight default link vroomRange Include +highlight default link vroomMode Constant +highlight default link vroomDelay Type +highlight default link vroomStrictness vroomMode +highlight default link vroomChannel vroomMode +highlight default link vroomBind vroomMode + +let b:current_syntax = 'vroom' + + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/vsejcl.vim b/syntax/vsejcl.vim new file mode 100644 index 0000000..77f6b9c --- /dev/null +++ b/syntax/vsejcl.vim @@ -0,0 +1,40 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: JCL job control language - DOS/VSE +" Maintainer: Davyd Ondrejko +" URL: +" Last change: 2001 May 10 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" tags +syn keyword vsejclKeyword DLBL EXEC JOB ASSGN EOJ +syn keyword vsejclField JNM CLASS DISP USER SYSID JSEP SIZE +syn keyword vsejclField VSAM +syn region vsejclComment start="^/\*" end="$" +syn region vsejclComment start="^[\* ]\{}$" end="$" +syn region vsejclMisc start="^ " end="$" contains=Jparms +syn match vsejclString /'.\{-}'/ +syn match vsejclParms /(.\{-})/ contained + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link vsejclComment Comment +hi def link vsejclField Type +hi def link vsejclKeyword Statement +hi def link vsejclObject Constant +hi def link vsejclString Constant +hi def link vsejclMisc Special +hi def link vsejclParms Constant + + +let b:current_syntax = "vsejcl" + +" vim: ts=4 + +endif diff --git a/syntax/wdiff.vim b/syntax/wdiff.vim new file mode 100644 index 0000000..fa552aa --- /dev/null +++ b/syntax/wdiff.vim @@ -0,0 +1,33 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: wDiff (wordwise diff) +" Maintainer: Gerfried Fuchs +" Last Change: 25 Apr 2001 +" URL: http://alfie.ist.org/vim/syntax/wdiff.vim +" +" Comments are very welcome - but please make sure that you are commenting on +" the latest version of this file. +" SPAM is _NOT_ welcome - be ready to be reported! + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +syn region wdiffOld start=+\[-+ end=+-]+ +syn region wdiffNew start="{+" end="+}" + + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link wdiffOld Special +hi def link wdiffNew Identifier + + +let b:current_syntax = "wdiff" + +endif diff --git a/syntax/web.vim b/syntax/web.vim new file mode 100644 index 0000000..c96f0aa --- /dev/null +++ b/syntax/web.vim @@ -0,0 +1,36 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: WEB +" Maintainer: Andreas Scherer +" Last Change: April 30, 2001 + +" Details of the WEB language can be found in the article by Donald E. Knuth, +" "The WEB System of Structured Documentation", included as "webman.tex" in +" the standard WEB distribution, available for anonymous ftp at +" ftp://labrea.stanford.edu/pub/tex/web/. + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" Although WEB is the ur-language for the "Literate Programming" paradigm, +" we base this syntax file on the modern superset, CWEB. Note: This shortcut +" may introduce some illegal constructs, e.g., CWEB's "@c" does _not_ start a +" code section in WEB. Anyway, I'm not a WEB programmer. +runtime! syntax/cweb.vim +unlet b:current_syntax + +" Replace C/C++ syntax by Pascal syntax. +syntax include @webIncludedC :p:h/pascal.vim + +" Double-@ means single-@, anywhere in the WEB source (as in CWEB). +" Don't misinterpret "@'" as the start of a Pascal string. +syntax match webIgnoredStuff "@[@']" + +let b:current_syntax = "web" + +" vim: ts=8 + +endif diff --git a/syntax/webmacro.vim b/syntax/webmacro.vim new file mode 100644 index 0000000..3337faa --- /dev/null +++ b/syntax/webmacro.vim @@ -0,0 +1,71 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" WebMacro syntax file +" Language: WebMacro +" Maintainer: Claudio Fleiner +" URL: http://www.fleiner.com/vim/syntax/webmacro.vim +" Last Change: 2003 May 11 + +" webmacro is a nice little language that you should +" check out if you use java servlets. +" webmacro: http://www.webmacro.org + +" For version 5.x: Clear all syntax items +" For version 6.x: Quit when a syntax file was already loaded +if !exists("main_syntax") + " quit when a syntax file was already loaded + if exists("b:current_syntax") + finish + endif + let main_syntax = 'webmacro' +endif + + +runtime! syntax/html.vim +unlet b:current_syntax + +syn cluster htmlPreProc add=webmacroIf,webmacroUse,webmacroBraces,webmacroParse,webmacroInclude,webmacroSet,webmacroForeach,webmacroComment + +syn match webmacroVariable "\$[a-zA-Z0-9.()]*;\=" +syn match webmacroNumber "[-+]\=\d\+[lL]\=" contained +syn keyword webmacroBoolean true false contained +syn match webmacroSpecial "\\." contained +syn region webmacroString contained start=+"+ end=+"+ contains=webmacroSpecial,webmacroVariable +syn region webmacroString contained start=+'+ end=+'+ contains=webmacroSpecial,webmacroVariable +syn region webmacroList contained matchgroup=Structure start="\[" matchgroup=Structure end="\]" contains=webmacroString,webmacroVariable,webmacroNumber,webmacroBoolean,webmacroList + +syn region webmacroIf start="#if" start="#else" end="{"me=e-1 contains=webmacroVariable,webmacroNumber,webmacroString,webmacroBoolean,webmacroList nextgroup=webmacroBraces +syn region webmacroForeach start="#foreach" end="{"me=e-1 contains=webmacroVariable,webmacroNumber,webmacroString,webmacroBoolean,webmacroList nextgroup=webmacroBraces +syn match webmacroSet "#set .*$" contains=webmacroVariable,webmacroNumber,webmacroNumber,webmacroBoolean,webmacroString,webmacroList +syn match webmacroInclude "#include .*$" contains=webmacroVariable,webmacroNumber,webmacroNumber,webmacroBoolean,webmacroString,webmacroList +syn match webmacroParse "#parse .*$" contains=webmacroVariable,webmacroNumber,webmacroNumber,webmacroBoolean,webmacroString,webmacroList +syn region webmacroUse matchgroup=PreProc start="#use .*" matchgroup=PreProc end="^-.*" contains=webmacroHash,@HtmlTop +syn region webmacroBraces matchgroup=Structure start="{" matchgroup=Structure end="}" contained transparent +syn match webmacroBracesError "[{}]" +syn match webmacroComment "##.*$" +syn match webmacroHash "[#{}\$]" contained + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link webmacroComment CommentTitle +hi def link webmacroVariable PreProc +hi def link webmacroIf webmacroStatement +hi def link webmacroForeach webmacroStatement +hi def link webmacroSet webmacroStatement +hi def link webmacroInclude webmacroStatement +hi def link webmacroParse webmacroStatement +hi def link webmacroStatement Function +hi def link webmacroNumber Number +hi def link webmacroBoolean Boolean +hi def link webmacroSpecial Special +hi def link webmacroString String +hi def link webmacroBracesError Error + +let b:current_syntax = "webmacro" + +if main_syntax == 'webmacro' + unlet main_syntax +endif + +endif diff --git a/syntax/wget.vim b/syntax/wget.vim new file mode 100644 index 0000000..7cea73c --- /dev/null +++ b/syntax/wget.vim @@ -0,0 +1,193 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Wget configuration file (/etc/wgetrc ~/.wgetrc) +" Maintainer: Doug Kearns +" Last Change: 2013 Jun 1 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn match wgetComment "#.*$" contains=wgetTodo contained + +syn keyword wgetTodo TODO NOTE FIXME XXX contained + +syn region wgetString start=+"+ skip=+\\\\\|\\"+ end=+"+ contained oneline +syn region wgetString start=+'+ skip=+\\\\\|\\'+ end=+'+ contained oneline + +syn case ignore +syn keyword wgetBoolean on off contained +syn keyword wgetNumber inf contained +syn case match + +syn match wgetNumber "\<\%(\d\+\|inf\)\>" contained +syn match wgetQuota "\<\d\+[kKmM]\>" contained +syn match wgetTime "\<\d\+[smhdw]\>" contained + +"{{{ Commands +let s:commands = map([ + \ "accept", + \ "add_hostdir", + \ "adjust_extension", + \ "always_rest", + \ "ask_password", + \ "auth_no_challenge", + \ "background", + \ "backup_converted", + \ "backups", + \ "base", + \ "bind_address", + \ "ca_certificate", + \ "ca_directory", + \ "cache", + \ "certificate", + \ "certificate_type", + \ "check_certificate", + \ "connect_timeout", + \ "content_disposition", + \ "continue", + \ "convert_links", + \ "cookies", + \ "cut_dirs", + \ "debug", + \ "default_page", + \ "delete_after", + \ "dns_cache", + \ "dns_timeout", + \ "dir_prefix", + \ "dir_struct", + \ "domains", + \ "dot_bytes", + \ "dots_in_line", + \ "dot_spacing", + \ "dot_style", + \ "egd_file", + \ "exclude_directories", + \ "exclude_domains", + \ "follow_ftp", + \ "follow_tags", + \ "force_html", + \ "ftp_passwd", + \ "ftp_password", + \ "ftp_user", + \ "ftp_proxy", + \ "glob", + \ "header", + \ "html_extension", + \ "htmlify", + \ "http_keep_alive", + \ "http_passwd", + \ "http_password", + \ "http_proxy", + \ "https_proxy", + \ "http_user", + \ "ignore_case", + \ "ignore_length", + \ "ignore_tags", + \ "include_directories", + \ "inet4_only", + \ "inet6_only", + \ "input", + \ "iri", + \ "keep_session_cookies", + \ "kill_longer", + \ "limit_rate", + \ "load_cookies", + \ "locale", + \ "local_encoding", + \ "logfile", + \ "login", + \ "max_redirect", + \ "mirror", + \ "netrc", + \ "no_clobber", + \ "no_parent", + \ "no_proxy", + \ "numtries", + \ "output_document", + \ "page_requisites", + \ "passive_ftp", + \ "passwd", + \ "password", + \ "post_data", + \ "post_file", + \ "prefer_family", + \ "preserve_permissions", + \ "private_key", + \ "private_key_type", + \ "progress", + \ "protocol_directories", + \ "proxy_passwd", + \ "proxy_password", + \ "proxy_user", + \ "quiet", + \ "quota", + \ "random_file", + \ "random_wait", + \ "read_timeout", + \ "reclevel", + \ "recursive", + \ "referer", + \ "reject", + \ "relative_only", + \ "remote_encoding", + \ "remove_listing", + \ "restrict_file_names", + \ "retr_symlinks", + \ "retry_connrefused", + \ "robots", + \ "save_cookies", + \ "save_headers", + \ "secure_protocol", + \ "server_response", + \ "show_all_dns_entries", + \ "simple_host_check", + \ "span_hosts", + \ "spider", + \ "strict_comments", + \ "sslcertfile", + \ "sslcertkey", + \ "timeout", + \ "time_stamping", + \ "use_server_timestamps", + \ "tries", + \ "trust_server_names", + \ "user", + \ "use_proxy", + \ "user_agent", + \ "verbose", + \ "wait", + \ "wait_retry"], + \ "substitute(v:val, '_', '[-_]\\\\=', 'g')") +"}}} + +syn case ignore +for cmd in s:commands + exe 'syn match wgetCommand "' . cmd . '" nextgroup=wgetAssignmentOperator skipwhite contained' +endfor +syn case match + +syn match wgetStart "^" nextgroup=wgetCommand,wgetComment skipwhite +syn match wgetAssignmentOperator "=" nextgroup=wgetString,wgetBoolean,wgetNumber,wgetQuota,wgetTime skipwhite contained + +hi def link wgetAssignmentOperator Special +hi def link wgetBoolean Boolean +hi def link wgetCommand Identifier +hi def link wgetComment Comment +hi def link wgetNumber Number +hi def link wgetQuota Number +hi def link wgetString String +hi def link wgetTodo Todo + +let b:current_syntax = "wget" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 fdm=marker: + +endif diff --git a/syntax/whitespace.vim b/syntax/whitespace.vim new file mode 100644 index 0000000..043b584 --- /dev/null +++ b/syntax/whitespace.vim @@ -0,0 +1,17 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Simplistic way to make spaces and Tabs visible + +" This can be added to an already active syntax. + +syn match Space " " +syn match Tab "\t" +if &background == "dark" + hi def Space ctermbg=darkred guibg=#500000 + hi def Tab ctermbg=darkgreen guibg=#003000 +else + hi def Space ctermbg=lightred guibg=#ffd0d0 + hi def Tab ctermbg=lightgreen guibg=#d0ffd0 +endif + +endif diff --git a/syntax/winbatch.vim b/syntax/winbatch.vim new file mode 100644 index 0000000..721c5a1 --- /dev/null +++ b/syntax/winbatch.vim @@ -0,0 +1,178 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: WinBatch/Webbatch (*.wbt, *.web) +" Maintainer: dominique@mggen.com +" URL: http://www.mggen.com/vim/syntax/winbatch.zip +" Last change: 2001 May 10 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +syn keyword winbatchCtl if then else endif break end return exit next +syn keyword winbatchCtl while for gosub goto switch select to case +syn keyword winbatchCtl endselect endwhile endselect endswitch + +" String +syn region winbatchVar start=+%+ end=+%+ +" %var% in strings +syn region winbatchString start=+"+ end=+"+ contains=winbatchVar + +syn match winbatchComment ";.*$" +syn match winbatchLabel "^\ *:[0-9a-zA-Z_\-]\+\>" + +" constant (bezgin by @) +syn match winbatchConstant "@[0_9a-zA-Z_\-]\+" + +" number +syn match winbatchNumber "\<[0-9]\+\(u\=l\=\|lu\|f\)\>" + +syn keyword winbatchImplicit aboveicons acc_attrib acc_chng_nt acc_control acc_create +syn keyword winbatchImplicit acc_delete acc_full_95 acc_full_nt acc_list acc_pfull_nt +syn keyword winbatchImplicit acc_pmang_nt acc_print_nt acc_read acc_read_95 acc_read_nt +syn keyword winbatchImplicit acc_write amc arrange ascending attr_a attr_a attr_ci attr_ci +syn keyword winbatchImplicit attr_dc attr_dc attr_di attr_di attr_dm attr_dm attr_h attr_h +syn keyword winbatchImplicit attr_ic attr_ic attr_p attr_p attr_ri attr_ri attr_ro attr_ro +syn keyword winbatchImplicit attr_sh attr_sh attr_sy attr_sy attr_t attr_t attr_x attr_x +syn keyword winbatchImplicit avogadro backscan boltzmann cancel capslock check columns +syn keyword winbatchImplicit commonformat cr crlf ctrl default default deg2rad descending +syn keyword winbatchImplicit disable drive electric enable eulers false faraday float8 +syn keyword winbatchImplicit fwdscan gftsec globalgroup gmtsec goldenratio gravitation hidden +syn keyword winbatchImplicit icon lbutton lclick ldblclick lf lightmps lightmtps localgroup +syn keyword winbatchImplicit magfield major mbokcancel mbutton mbyesno mclick mdblclick minor +syn keyword winbatchImplicit msformat multiple ncsaformat no none none noresize normal +syn keyword winbatchImplicit notify nowait numlock off on open parsec parseonly pi +syn keyword winbatchImplicit planckergs planckjoules printer rad2deg rbutton rclick rdblclick +syn keyword winbatchImplicit regclasses regcurrent regmachine regroot regusers rows save +syn keyword winbatchImplicit scrolllock server shift single sorted stack string tab tile +syn keyword winbatchImplicit true uncheck unsorted wait wholesection word1 word2 word4 yes +syn keyword winbatchImplicit zoomed about abs acos addextender appexist appwaitclose asin +syn keyword winbatchImplicit askfilename askfiletext askitemlist askline askpassword askyesno +syn keyword winbatchImplicit atan average beep binaryalloc binarycopy binaryeodget binaryeodset +syn keyword winbatchImplicit binaryfree binaryhashrec binaryincr binaryincr2 binaryincr4 +syn keyword winbatchImplicit binaryincrflt binaryindex binaryindexnc binaryoletype binarypeek +syn keyword winbatchImplicit binarypeek2 binarypeek4 binarypeekflt binarypeekstr binarypoke +syn keyword winbatchImplicit binarypoke2 binarypoke4 binarypokeflt binarypokestr binaryread +syn keyword winbatchImplicit binarysort binarystrcnt binarywrite boxbuttondraw boxbuttonkill +syn keyword winbatchImplicit boxbuttonstat boxbuttonwait boxcaption boxcolor +syn keyword winbatchImplicit boxdataclear boxdatatag +syn keyword winbatchImplicit boxdestroy boxdrawcircle boxdrawline boxdrawrect boxdrawtext +syn keyword winbatchImplicit boxesup boxmapmode boxnew boxopen boxpen boxshut boxtext boxtextcolor +syn keyword winbatchImplicit boxtextfont boxtitle boxupdates break buttonnames by call +syn keyword winbatchImplicit callext ceiling char2num clipappend clipget clipput +syn keyword winbatchImplicit continue cos cosh datetime +syn keyword winbatchImplicit ddeexecute ddeinitiate ddepoke dderequest ddeterminate +syn keyword winbatchImplicit ddetimeout debug debugdata decimals delay dialog +syn keyword winbatchImplicit dialogbox dirattrget dirattrset dirchange direxist +syn keyword winbatchImplicit dirget dirhome diritemize dirmake dirremove dirrename +syn keyword winbatchImplicit dirwindows diskexist diskfree diskinfo diskscan disksize +syn keyword winbatchImplicit diskvolinfo display dllcall dllfree dllhinst dllhwnd dllload +syn keyword winbatchImplicit dosboxcursorx dosboxcursory dosboxgetall dosboxgetdata +syn keyword winbatchImplicit dosboxheight dosboxscrmode dosboxversion dosboxwidth dosversion +syn keyword winbatchImplicit drop edosgetinfo edosgetvar edoslistvars edospathadd edospathchk +syn keyword winbatchImplicit edospathdel edossetvar +syn keyword winbatchImplicit endsession envgetinfo envgetvar environment +syn keyword winbatchImplicit environset envitemize envlistvars envpathadd envpathchk +syn keyword winbatchImplicit envpathdel envsetvar errormode exclusive execute exetypeinfo +syn keyword winbatchImplicit exp fabs fileappend fileattrget fileattrset fileclose +syn keyword winbatchImplicit filecompare filecopy filedelete fileexist fileextension filefullname +syn keyword winbatchImplicit fileitemize filelocate filemapname filemove filenameeval1 +syn keyword winbatchImplicit filenameeval2 filenamelong filenameshort fileopen filepath +syn keyword winbatchImplicit fileread filerename fileroot filesize filetimecode filetimeget +syn keyword winbatchImplicit filetimeset filetimetouch fileverinfo filewrite fileymdhms +syn keyword winbatchImplicit findwindow floor getexacttime gettickcount +syn keyword winbatchImplicit iconarrange iconreplace ignoreinput inidelete inideletepvt +syn keyword winbatchImplicit iniitemize iniitemizepvt iniread inireadpvt iniwrite iniwritepvt +syn keyword winbatchImplicit installfile int intcontrol isdefined isfloat isint iskeydown +syn keyword winbatchImplicit islicensed isnumber itemcount itemextract iteminsert itemlocate +syn keyword winbatchImplicit itemremove itemselect itemsort keytoggleget keytoggleset +syn keyword winbatchImplicit lasterror log10 logdisk loge max message min mod mouseclick +syn keyword winbatchImplicit mouseclickbtn mousedrag mouseinfo mousemove msgtextget n3attach +syn keyword winbatchImplicit n3captureend n3captureprt n3chgpassword n3detach n3dirattrget +syn keyword winbatchImplicit n3dirattrset n3drivepath n3drivepath2 n3drivestatus n3fileattrget +syn keyword winbatchImplicit n3fileattrset n3getloginid n3getmapped n3getnetaddr n3getuser +syn keyword winbatchImplicit n3getuserid n3logout n3map n3mapdelete n3mapdir n3maproot n3memberdel +syn keyword winbatchImplicit n3memberget n3memberset n3msgsend n3msgsendall n3serverinfo +syn keyword winbatchImplicit n3serverlist n3setsrchdrv n3usergroups n3version n4attach +syn keyword winbatchImplicit n4captureend n4captureprt n4chgpassword n4detach n4dirattrget +syn keyword winbatchImplicit n4dirattrset n4drivepath n4drivestatus n4fileattrget n4fileattrset +syn keyword winbatchImplicit n4getloginid n4getmapped n4getnetaddr n4getuser n4getuserid +syn keyword winbatchImplicit n4login n4logout n4map n4mapdelete n4mapdir n4maproot n4memberdel +syn keyword winbatchImplicit n4memberget n4memberset n4msgsend n4msgsendall n4serverinfo +syn keyword winbatchImplicit n4serverlist n4setsrchdrv n4usergroups n4version netadddrive +syn keyword winbatchImplicit netaddprinter netcancelcon netdirdialog netgetcon netgetuser +syn keyword winbatchImplicit netinfo netresources netversion num2char objectclose +syn keyword winbatchImplicit objectopen parsedata pause playmedia playmidi playwaveform +syn keyword winbatchImplicit print random regapp regclosekey regconnect regcreatekey +syn keyword winbatchImplicit regdeletekey regdelvalue regentrytype regloadhive regopenkey +syn keyword winbatchImplicit regquerybin regquerydword regqueryex regqueryexpsz regqueryitem +syn keyword winbatchImplicit regquerykey regquerymulsz regqueryvalue regsetbin +syn keyword winbatchImplicit regsetdword regsetex regsetexpsz regsetmulsz regsetvalue +syn keyword winbatchImplicit regunloadhive reload reload rtstatus run runenviron +syn keyword winbatchImplicit runexit runhide runhidewait runicon runiconwait runshell runwait +syn keyword winbatchImplicit runzoom runzoomwait sendkey sendkeyschild sendkeysto +syn keyword winbatchImplicit sendmenusto shellexecute shortcutedit shortcutextra shortcutinfo +syn keyword winbatchImplicit shortcutmake sin sinh snapshot sounds sqrt +syn keyword winbatchImplicit srchfree srchinit srchnext strcat strcharcount strcmp +syn keyword winbatchImplicit strfill strfix strfixchars stricmp strindex strlen +syn keyword winbatchImplicit strlower strreplace strscan strsub strtrim strupper +syn keyword winbatchImplicit tan tanh tcpaddr2host tcpftpchdir tcpftpclose tcpftpget +syn keyword winbatchImplicit tcpftplist tcpftpmode tcpftpopen tcpftpput tcphost2addr tcphttpget +syn keyword winbatchImplicit tcphttppost tcpparmget tcpparmset tcpping tcpsmtp terminate +syn keyword winbatchImplicit textbox textboxsort textoutbufdel textoutbuffer textoutdebug +syn keyword winbatchImplicit textoutfree textoutinfo textoutreset textouttrack textouttrackb +syn keyword winbatchImplicit textouttrackp textoutwait textselect timeadd timedate +syn keyword winbatchImplicit timedelay timediffdays timediffsecs timejulianday timejultoymd +syn keyword winbatchImplicit timesubtract timewait timeymdhms version versiondll +syn keyword winbatchImplicit w3addcon w3cancelcon w3dirbrowse w3getcaps w3getcon w3netdialog +syn keyword winbatchImplicit w3netgetuser w3prtbrowse w3version w95accessadd w95accessdel +syn keyword winbatchImplicit w95adddrive w95addprinter w95cancelcon w95dirdialog w95getcon +syn keyword winbatchImplicit w95getuser w95resources w95shareadd w95sharedel w95shareset +syn keyword winbatchImplicit w95version waitforkey wallpaper webbaseconv webcloselog +syn keyword winbatchImplicit webcmddata webcondata webcounter webdatdata webdumperror webhashcode +syn keyword winbatchImplicit webislocal weblogline webopenlog webout weboutfile webparamdata +syn keyword winbatchImplicit webparamnames websettimeout webverifycard winactivate +syn keyword winbatchImplicit winactivchild winarrange winclose winclosenot winconfig winexename +syn keyword winbatchImplicit winexist winparset winparget winexistchild wingetactive +syn keyword winbatchImplicit winhelp winhide winiconize winidget winisdos winitemchild +syn keyword winbatchImplicit winitemize winitemnameid winmetrics winname winparmget +syn keyword winbatchImplicit winparmset winplace winplaceget winplaceset +syn keyword winbatchImplicit winposition winresources winshow winstate winsysinfo +syn keyword winbatchImplicit wintitle winversion winwaitchild winwaitclose winwaitexist +syn keyword winbatchImplicit winzoom wnaddcon wncancelcon wncmptrinfo wndialog +syn keyword winbatchImplicit wndlgbrowse wndlgcon wndlgcon2 wndlgcon3 +syn keyword winbatchImplicit wndlgcon4 wndlgdiscon wndlgnoshare wndlgshare wngetcaps +syn keyword winbatchImplicit wngetcon wngetuser wnnetnames wnrestore wnservers wnsharecnt +syn keyword winbatchImplicit wnsharename wnsharepath wnshares wntaccessadd wntaccessdel +syn keyword winbatchImplicit wntaccessget wntadddrive wntaddprinter wntcancelcon wntdirdialog +syn keyword winbatchImplicit wntgetcon wntgetuser wntlistgroups wntmemberdel wntmemberget +syn keyword winbatchImplicit wntmembergrps wntmemberlist wntmemberset wntresources wntshareadd +syn keyword winbatchImplicit wntsharedel wntshareset wntversion wnversion wnwrkgroups wwenvunload +syn keyword winbatchImplicit xbaseconvert xcursorset xdisklabelget xdriveready xextenderinfo +syn keyword winbatchImplicit xgetchildhwnd xgetelapsed xhex xmemcompact xmessagebox +syn keyword winbatchImplicit xsendmessage xverifyccard yield + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link winbatchLabel PreProc +hi def link winbatchCtl Operator +hi def link winbatchStatement Statement +hi def link winbatchTodo Todo +hi def link winbatchString String +hi def link winbatchVar Type +hi def link winbatchComment Comment +hi def link winbatchImplicit Special +hi def link winbatchNumber Number +hi def link winbatchConstant StorageClass + + +let b:current_syntax = "winbatch" + +" vim: ts=8 + +endif diff --git a/syntax/wml.vim b/syntax/wml.vim new file mode 100644 index 0000000..1ec5891 --- /dev/null +++ b/syntax/wml.vim @@ -0,0 +1,154 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: WML - Website MetaLanguage +" Maintainer: Gerfried Fuchs +" Filenames: *.wml +" Last Change: 07 Feb 2002 +" URL: http://alfie.ist.org/software/vim/syntax/wml.vim +" +" Original Version: Craig Small + +" Comments are very welcome - but please make sure that you are commenting on +" the latest version of this file. +" SPAM is _NOT_ welcome - be ready to be reported! + +" If you are looking for the "Wireless Markup Language" syntax file, +" please take a look at the wap.vim file done by Ralf Schandl, soon in a +" vim-package around your corner :) + + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + + +" A lot of the web stuff looks like HTML so we load that first +runtime! syntax/html.vim +unlet b:current_syntax + +if !exists("main_syntax") + let main_syntax = 'wml' +endif + +" special character +syn match wmlNextLine "\\$" + +" Redfine htmlTag +syn clear htmlTag +syn region htmlTag start=+<[^/<]+ end=+>+ contains=htmlTagN,htmlString,htmlArg,htmlValue,htmlTagError,htmlEvent,htmlCssDefinition + +" +" Add in extra Arguments used by wml +syn keyword htmlTagName contained gfont imgbg imgdot lowsrc +syn keyword htmlTagName contained navbar:define navbar:header +syn keyword htmlTagName contained navbar:footer navbar:prolog +syn keyword htmlTagName contained navbar:epilog navbar:button +syn keyword htmlTagName contained navbar:filter navbar:debug +syn keyword htmlTagName contained navbar:render +syn keyword htmlTagName contained preload rollover +syn keyword htmlTagName contained space hspace vspace over +syn keyword htmlTagName contained ps ds pi ein big sc spaced headline +syn keyword htmlTagName contained ue subheadline zwue verbcode +syn keyword htmlTagName contained isolatin pod sdf text url verbatim +syn keyword htmlTagName contained xtable +syn keyword htmlTagName contained csmap fsview import box +syn keyword htmlTagName contained case:upper case:lower +syn keyword htmlTagName contained grid cell info lang: logo page +syn keyword htmlTagName contained set-var restore +syn keyword htmlTagName contained array:push array:show set-var ifdef +syn keyword htmlTagName contained say m4 symbol dump enter divert +syn keyword htmlTagName contained toc +syn keyword htmlTagName contained wml card do refresh oneevent catch spawn + +" +" The wml arguments +syn keyword htmlArg contained adjust background base bdcolor bdspace +syn keyword htmlArg contained bdwidth complete copyright created crop +syn keyword htmlArg contained direction description domainname eperlfilter +syn keyword htmlArg contained file hint imgbase imgstar interchar interline +syn keyword htmlArg contained keephr keepindex keywords layout spacing +syn keyword htmlArg contained padding nonetscape noscale notag notypo +syn keyword htmlArg contained onload oversrc pos select slices style +syn keyword htmlArg contained subselected txtcol_select txtcol_normal +syn keyword htmlArg contained txtonly via +syn keyword htmlArg contained mode columns localsrc ordered + + +" Lines starting with an # are usually comments +syn match wmlComment "^\s*#.*" +" The different exceptions to comments +syn match wmlSharpBang "^#!.*" +syn match wmlUsed contained "\s\s*[A-Za-z:_-]*" +syn match wmlUse "^\s*#\s*use\s\+" contains=wmlUsed +syn match wmlInclude "^\s*#\s*include.+" + +syn region wmlBody contained start=+<<+ end=+>>+ + +syn match wmlLocationId contained "[A-Za-z]\+" +syn region wmlLocation start=+<<+ end=+>>+ contains=wmlLocationId +"syn region wmlLocation start=+{#+ end=+#}+ contains=wmlLocationId +"syn region wmlLocationed contained start=+<<+ end=+>>+ contains=wmlLocationId + +syn match wmlDivert "\.\.[a-zA-Z_]\+>>" +syn match wmlDivertEnd "<<\.\." +" new version +"syn match wmlDivert "{#[a-zA-Z_]\+#:" +"syn match wmlDivertEnd ":##}" + +syn match wmlDefineName contained "\s\+[A-Za-z-]\+" +syn region htmlTagName start="\<\(define-tag\|define-region\)" end="\>" contains=wmlDefineName + +" The perl include stuff +if main_syntax != 'perl' + " Perl script + syn include @wmlPerlScript syntax/perl.vim + unlet b:current_syntax + + syn region perlScript start=++ keepend end=++ contains=@wmlPerlScript,wmlPerlTag +" eperl between '<:' and ':>' -- Alfie [1999-12-26] + syn region perlScript start=+<:+ keepend end=+:>+ contains=@wmlPerlScript,wmlPerlTag + syn match wmlPerlTag contained "" contains=wmlPerlTagN + syn keyword wmlPerlTagN contained perl + + hi link wmlPerlTag htmlTag + hi link wmlPerlTagN htmlStatement +endif + +" verbatim tags -- don't highlight anything in between -- Alfie [2002-02-07] +syn region wmlVerbatimText start=++ keepend end=++ contains=wmlVerbatimTag +syn match wmlVerbatimTag contained "" contains=wmlVerbatimTagN +syn keyword wmlVerbatimTagN contained verbatim +hi link wmlVerbatimTag htmlTag +hi link wmlVerbatimTagN htmlStatement + +if main_syntax == "html" + syn sync match wmlHighlight groupthere NONE "" + syn sync match wmlHighlightSkip "^.*['\"].*$" + syn sync minlines=10 +endif + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link wmlNextLine Special +hi def link wmlUse Include +hi def link wmlUsed String +hi def link wmlBody Special +hi def link wmlDiverted Label +hi def link wmlDivert Delimiter +hi def link wmlDivertEnd Delimiter +hi def link wmlLocationId Label +hi def link wmlLocation Delimiter +" hi def link wmlLocationed Delimiter +hi def link wmlDefineName String +hi def link wmlComment Comment +hi def link wmlInclude Include +hi def link wmlSharpBang PreProc + + +let b:current_syntax = "wml" + +endif diff --git a/syntax/wsh.vim b/syntax/wsh.vim new file mode 100644 index 0000000..1d5199c --- /dev/null +++ b/syntax/wsh.vim @@ -0,0 +1,49 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Windows Scripting Host +" Maintainer: Paul Moore +" Last Change: Fre, 24 Nov 2000 21:54:09 +0100 + +" This reuses the XML, VB and JavaScript syntax files. While VB is not +" VBScript, it's close enough for us. No attempt is made to handle +" other languages. +" Send comments, suggestions and requests to the maintainer. + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:wsh_cpo_save = &cpo +set cpo&vim + +runtime! syntax/xml.vim +unlet b:current_syntax + +syn case ignore +syn include @wshVBScript :p:h/vb.vim +unlet b:current_syntax +syn include @wshJavaScript :p:h/javascript.vim +unlet b:current_syntax +syn region wshVBScript + \ matchgroup=xmlTag start="]*VBScript\(>\|[^>]*[^/>]>\)" + \ matchgroup=xmlEndTag end="" + \ fold + \ contains=@wshVBScript + \ keepend +syn region wshJavaScript + \ matchgroup=xmlTag start="]*J\(ava\)\=Script\(>\|[^>]*[^/>]>\)" + \ matchgroup=xmlEndTag end="" + \ fold + \ contains=@wshJavaScript + \ keepend + +syn cluster xmlRegionHook add=wshVBScript,wshJavaScript + +let b:current_syntax = "wsh" + +let &cpo = s:wsh_cpo_save +unlet s:wsh_cpo_save + +endif diff --git a/syntax/wsml.vim b/syntax/wsml.vim new file mode 100644 index 0000000..cc6ae18 --- /dev/null +++ b/syntax/wsml.vim @@ -0,0 +1,117 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: WSML +" Maintainer: Thomas Haselwanter +" URL: none +" Last Change: 2006 Apr 30 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" WSML +syn keyword wsmlHeader wsmlVariant +syn keyword wsmlNamespace namespace +syn keyword wsmlTopLevel concept instance relationInstance ofType usesMediator usesService relation sharedVariables importsOntology +syn keyword wsmlOntology hasValue memberOf ofType impliesType subConceptOf +syn keyword wsmlAxiom axiom definedBy +syn keyword wsmlService assumption effect postcondition precondition capability interface +syn keyword wsmlTopLevel ooMediator wwMediator wgMediator ggMediator +syn keyword wsmlMediation usesService source target +syn match wsmlDataTypes "\( _string\| _decimal\| _integer\| _float\| _double\| _iri\| _sqname\| _boolean\| _duration\| _dateTime\| _time\| _date\| _gyearmonth\| _gyear\| _gmonthday\| _gday\| _gmonth\| _hexbinary\| _base64binary\)\((\S*)\)\?" contains=wsmlString,wsmlNumber,wsmlCharacter +syn keyword wsmlTopLevel goal webService ontology +syn keyword wsmlKeywordsInsideLEs true false memberOf hasValue subConceptOf ofType impliesType and or implies impliedBy equivalent neg naf forall exists +syn keyword wsmlNFP nfp endnfp nonFunctionalProperties endNonFunctionalProperties +syn region wsmlNFPregion start="nfp\|nonFunctionalProperties" end="endnfp\|endNonFunctionalProperties" contains=ALL +syn region wsmlNamespace start="namespace" end="}" contains=wsmlIdentifier +syn match wsmlOperator "!=\|:=:\|=<\|>=\|=\|+\|\*\|/\|<->\|->\|<-\|:-\|!-\|-\|<\|>" +syn match wsmlBrace "(\|)\|\[\|\]\|{\|}" +syn match wsmlIdentifier +_"\S*"+ +syn match wsmlIdentifier "_#\d*" +syn match wsmlSqName "[0-9A-Za-z]\+#[0-9A-Za-z]\+" +syn match wsmlVariable "?[0-9A-Za-z]\+" + +" ASM-specific code +syn keyword wsmlBehavioral choreography orchestration transitionRules +syn keyword wsmlChoreographyPri stateSignature in out shared static controlled +syn keyword wsmlChoreographySec with do withGrounding forall endForall choose if then endIf +syn match wsmlChoreographyTer "\(\s\|\_^\)\(add\|delete\|update\)\s*(.*)" contains=wsmlKeywordsInsideLEs,wsmlIdentifier,wsmlSqName,wsmlString,wsmlNumber,wsmlDataTypes,wsmlVariable + +" Comments +syn keyword wsmlTodo contained TODO +syn keyword wsmlFixMe contained FIXME +if exists("wsml_comment_strings") + syn region wsmlCommentString contained start=+"+ end=+"+ end=+$+ end=+\*/+me=s-1,he=s-1 contains=wsmlSpecial,wsmlCommentStar,wsmlSpecialChar,@Spell + syn region wsmlComment2String contained start=+"+ end=+$\|"+ contains=wsmlSpecial,wsmlSpecialChar,@Spell + syn match wsmlCommentCharacter contained "'\\[^']\{1,6\}'" contains=wsmlSpecialChar + syn match wsmlCommentCharacter contained "'\\''" contains=wsmlSpecialChar + syn match wsmlCommentCharacter contained "'[^\\]'" + syn cluster wsmlCommentSpecial add=wsmlCommentString,wsmlCommentCharacter,wsmlNumber + syn cluster wsmlCommentSpecial2 add=wsmlComment2String,wsmlCommentCharacter,wsmlNumber +endif + +syn region wsmlComment start="/\*" end="\*/" contains=@wsmlCommentSpecial,wsmlTodo,wsmlFixMe,@Spell +syn match wsmlCommentStar contained "^\s*\*[^/]"me=e-1 +syn match wsmlCommentStar contained "^\s*\*$" +syn match wsmlLineComment "//.*" contains=@wsmlCommentSpecial2,wsmlTodo,@Spell + +syn cluster wsmlTop add=wsmlComment,wsmlLineComment + +"match the special comment /**/ +syn match wsmlComment "/\*\*/" + +" Strings +syn region wsmlString start=+"+ end=+"+ contains=wsmlSpecialChar,wsmlSpecialError,@Spell +syn match wsmlCharacter "'[^']*'" contains=javaSpecialChar,javaSpecialCharError +syn match wsmlCharacter "'\\''" contains=javaSpecialChar +syn match wsmlCharacter "'[^\\]'" +syn match wsmlNumber "\<\(0[0-7]*\|0[xX]\x\+\|\d\+\)[lL]\=\>" +syn match wsmlNumber "\(\<\d\+\.\d*\|\.\d\+\)\([eE][-+]\=\d\+\)\=[fFdD]\=" +syn match wsmlNumber "\<\d\+[eE][-+]\=\d\+[fFdD]\=\>" +syn match wsmlNumber "\<\d\+\([eE][-+]\=\d\+\)\=[fFdD]\>" + +" unicode characters +syn match wsmlSpecial "\\u\d\{4\}" + +syn cluster wsmlTop add=wsmlString,wsmlCharacter,wsmlNumber,wsmlSpecial,wsmlStringError + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link wsmlHeader TypeDef +hi def link wsmlNamespace TypeDef +hi def link wsmlOntology Statement +hi def link wsmlAxiom TypeDef +hi def link wsmlService TypeDef +hi def link wsmlNFP TypeDef +hi def link wsmlTopLevel TypeDef +hi def link wsmlMediation TypeDef +hi def link wsmlBehavioral TypeDef +hi def link wsmlChoreographyPri TypeDef +hi def link wsmlChoreographySec Operator +hi def link wsmlChoreographyTer Special +hi def link wsmlString String +hi def link wsmlIdentifier Normal +hi def link wsmlSqName Normal +hi def link wsmlVariable Define +hi def link wsmlKeywordsInsideLEs Operator +hi def link wsmlOperator Operator +hi def link wsmlBrace Operator +hi def link wsmlCharacter Character +hi def link wsmlNumber Number +hi def link wsmlDataTypes Special +hi def link wsmlComment Comment +hi def link wsmlDocComment Comment +hi def link wsmlLineComment Comment +hi def link wsmlTodo Todo +hi def link wsmlFixMe Error +hi def link wsmlCommentTitle SpecialComment +hi def link wsmlCommentStar wsmlComment + + +let b:current_syntax = "wsml" +let b:spell_options="contained" + + +endif diff --git a/syntax/wvdial.vim b/syntax/wvdial.vim new file mode 100644 index 0000000..b09214e --- /dev/null +++ b/syntax/wvdial.vim @@ -0,0 +1,32 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Configuration file for WvDial +" Maintainer: Prahlad Vaidyanathan +" Last Update: Mon, 15 Oct 2001 09:39:03 Indian Standard Time + +" Quit if syntax file is already loaded +if exists("b:current_syntax") + finish +endif + +syn match wvdialComment "^;.*$"lc=1 +syn match wvdialComment "[^\\];.*$"lc=1 +syn match wvdialSection "^\s*\[.*\]" +syn match wvdialValue "=.*$"ms=s+1 +syn match wvdialValue "\s*[^ ;"' ]\+"lc=1 +syn match wvdialVar "^\s*\(Inherits\|Modem\|Baud\|Init.\|Phone\|Area\ Code\|Dial\ Prefix\|Dial\ Command\|Login\|Login\| Prompt\|Password\|Password\ Prompt\|PPPD\ Path\|Force\ Address\|Remote\ Name\|Carrier\ Check\|Stupid\ [Mm]ode\|New\ PPPD\|Default\ Reply\|Auto\ Reconnect\|SetVolume\|Username\)" +syn match wvdialEqual "=" + +" The default highlighting +hi def link wvdialComment Comment +hi def link wvdialSection PreProc +hi def link wvdialVar Identifier +hi def link wvdialValue String +hi def link wvdialEqual Statement + +let b:current_syntax = "wvdial" + +"EOF vim: tw=78:ft=vim:ts=8 + +endif diff --git a/syntax/xbl.vim b/syntax/xbl.vim new file mode 100644 index 0000000..1394eba --- /dev/null +++ b/syntax/xbl.vim @@ -0,0 +1,33 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: XBL 1.0 +" Maintainer: Doug Kearns +" Latest Revision: 2007 November 5 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +runtime! syntax/xml.vim +unlet b:current_syntax + +syn include @javascriptTop syntax/javascript.vim +unlet b:current_syntax + +syn region xblJavascript + \ matchgroup=xmlCdataStart start=++ + \ contains=@javascriptTop keepend extend + +let b:current_syntax = "xbl" + +let &cpo = s:cpo_save +unlet s:cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/xdefaults.vim b/syntax/xdefaults.vim new file mode 100644 index 0000000..6d12496 --- /dev/null +++ b/syntax/xdefaults.vim @@ -0,0 +1,136 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: X resources files like ~/.Xdefaults (xrdb) +" Maintainer: Johannes Zellner +" Author and previous maintainer: +" Gautam H. Mudunuri +" Last Change: Di, 09 Mai 2006 23:10:23 CEST +" $Id: xdefaults.vim,v 1.2 2007/05/05 17:19:40 vimboss Exp $ +" +" REFERENCES: +" xrdb manual page +" xrdb source: ftp://ftp.x.org/pub/R6.4/xc/programs/xrdb/xrdb.c + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" turn case on +syn case match + + +if !exists("xdefaults_no_colon_errors") + " mark lines which do not contain a colon as errors. + " This does not really catch all errors but only lines + " which contain at least two WORDS and no colon. This + " was done this way so that a line is not marked as + " error while typing (which would be annoying). + syntax match xdefaultsErrorLine "^\s*[a-zA-Z.*]\+\s\+[^: ]\+" +endif + + +" syn region xdefaultsLabel start=+^[^:]\{-}:+he=e-1 skip=+\\+ end="$" +syn match xdefaultsLabel +^[^:]\{-}:+he=e-1 contains=xdefaultsPunct,xdefaultsSpecial,xdefaultsLineEnd +syn region xdefaultsValue keepend start=+:+lc=1 skip=+\\+ end=+$+ contains=xdefaultsSpecial,xdefaultsLabel,xdefaultsLineEnd + +syn match xdefaultsSpecial contained +#override+ +syn match xdefaultsSpecial contained +#augment+ +syn match xdefaultsPunct contained +[.*:]+ +syn match xdefaultsLineEnd contained +\\$+ +syn match xdefaultsLineEnd contained +\\n\\$+ +syn match xdefaultsLineEnd contained +\\n$+ + + + +" COMMENTS + +" note, that the '!' must be at the very first position of the line +syn match xdefaultsComment "^!.*$" contains=xdefaultsTodo,@Spell + +" lines starting with a '#' mark and which are not preprocessor +" lines are skipped. This is not part of the xrdb documentation. +" It was reported by Bram Moolenaar and could be confirmed by +" having a look at xrdb.c:GetEntries() +syn match xdefaultsCommentH "^#.*$" +"syn region xdefaultsComment start="^#" end="$" keepend contains=ALL +syn region xdefaultsComment start="/\*" end="\*/" contains=xdefaultsTodo,@Spell + +syntax match xdefaultsCommentError "\*/" + +syn keyword xdefaultsTodo contained TODO FIXME XXX display + + + +" PREPROCESSOR STUFF + +syn region xdefaultsPreProc start="^\s*#\s*\(if\|ifdef\|ifndef\|elif\|else\|endif\)\>" skip="\\$" end="$" contains=xdefaultsSymbol +if !exists("xdefaults_no_if0") + syn region xdefaultsCppOut start="^\s*#\s*if\s\+0\>" end=".\|$" contains=xdefaultsCppOut2 + syn region xdefaultsCppOut2 contained start="0" end="^\s*#\s*\(endif\>\|else\>\|elif\>\)" contains=xdefaultsCppSkip + syn region xdefaultsCppSkip contained start="^\s*#\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*#\s*endif\>" contains=xdefaultsCppSkip +endif +syn region xdefaultsIncluded contained start=+"+ skip=+\\\\\|\\"+ end=+"+ +syn match xdefaultsIncluded contained "<[^>]*>" +syn match xdefaultsInclude "^\s*#\s*include\>\s*["<]" contains=xdefaultsIncluded +syn cluster xdefaultsPreProcGroup contains=xdefaultsPreProc,xdefaultsIncluded,xdefaultsInclude,xdefaultsDefine,xdefaultsCppOut,xdefaultsCppOut2,xdefaultsCppSkip +syn region xdefaultsDefine start="^\s*#\s*\(define\|undef\)\>" skip="\\$" end="$" contains=ALLBUT,@xdefaultsPreProcGroup,xdefaultsCommentH,xdefaultsErrorLine,xdefaultsLabel,xdefaultsValue +syn region xdefaultsPreProc start="^\s*#\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@xdefaultsPreProcGroup,xdefaultsCommentH,xdefaultsErrorLine,xdefaultsLabel,xdefaultsValue + + + +" symbols as defined by xrdb +syn keyword xdefaultsSymbol contained SERVERHOST +syn match xdefaultsSymbol contained "SRVR_[a-zA-Z0-9_]\+" +syn keyword xdefaultsSymbol contained HOST +syn keyword xdefaultsSymbol contained DISPLAY_NUM +syn keyword xdefaultsSymbol contained CLIENTHOST +syn match xdefaultsSymbol contained "CLNT_[a-zA-Z0-9_]\+" +syn keyword xdefaultsSymbol contained RELEASE +syn keyword xdefaultsSymbol contained REVISION +syn keyword xdefaultsSymbol contained VERSION +syn keyword xdefaultsSymbol contained VENDOR +syn match xdefaultsSymbol contained "VNDR_[a-zA-Z0-9_]\+" +syn match xdefaultsSymbol contained "EXT_[a-zA-Z0-9_]\+" +syn keyword xdefaultsSymbol contained NUM_SCREENS +syn keyword xdefaultsSymbol contained SCREEN_NUM +syn keyword xdefaultsSymbol contained BITS_PER_RGB +syn keyword xdefaultsSymbol contained CLASS +syn keyword xdefaultsSymbol contained StaticGray GrayScale StaticColor PseudoColor TrueColor DirectColor +syn match xdefaultsSymbol contained "CLASS_\(StaticGray\|GrayScale\|StaticColor\|PseudoColor\|TrueColor\|DirectColor\)" +syn keyword xdefaultsSymbol contained COLOR +syn match xdefaultsSymbol contained "CLASS_\(StaticGray\|GrayScale\|StaticColor\|PseudoColor\|TrueColor\|DirectColor\)_[0-9]\+" +syn keyword xdefaultsSymbol contained HEIGHT +syn keyword xdefaultsSymbol contained WIDTH +syn keyword xdefaultsSymbol contained PLANES +syn keyword xdefaultsSymbol contained X_RESOLUTION +syn keyword xdefaultsSymbol contained Y_RESOLUTION + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +hi def link xdefaultsLabel Type +hi def link xdefaultsValue Constant +hi def link xdefaultsComment Comment +hi def link xdefaultsCommentH xdefaultsComment +hi def link xdefaultsPreProc PreProc +hi def link xdefaultsInclude xdefaultsPreProc +hi def link xdefaultsCppSkip xdefaultsCppOut +hi def link xdefaultsCppOut2 xdefaultsCppOut +hi def link xdefaultsCppOut Comment +hi def link xdefaultsIncluded String +hi def link xdefaultsDefine Macro +hi def link xdefaultsSymbol Statement +hi def link xdefaultsSpecial Statement +hi def link xdefaultsErrorLine Error +hi def link xdefaultsCommentError Error +hi def link xdefaultsPunct Normal +hi def link xdefaultsLineEnd Special +hi def link xdefaultsTodo Todo + + +let b:current_syntax = "xdefaults" + +" vim:ts=8 + +endif diff --git a/syntax/xf86conf.vim b/syntax/xf86conf.vim new file mode 100644 index 0000000..4d0e68d --- /dev/null +++ b/syntax/xf86conf.vim @@ -0,0 +1,209 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" This is a GENERATED FILE. Please always refer to source file at the URI below. +" Language: XF86Config (XFree86 configuration file) +" Former Maintainer: David Ne\v{c}as (Yeti) +" Last Change: 2010 Nov 01 +" URL: http://trific.ath.cx/Ftp/vim/syntax/xf86conf.vim +" Required Vim Version: 6.0 +" +" Options: let xf86conf_xfree86_version = 3 or 4 +" to force XFree86 3.x or 4.x XF86Config syntax + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +if !exists("b:xf86conf_xfree86_version") + if exists("xf86conf_xfree86_version") + let b:xf86conf_xfree86_version = xf86conf_xfree86_version + else + let b:xf86conf_xfree86_version = 4 + endif +endif + +syn case ignore + +" Comments +syn match xf86confComment "#.*$" contains=xf86confTodo +syn case match +syn keyword xf86confTodo FIXME TODO XXX NOT contained +syn case ignore +syn match xf86confTodo "???" contained + +" Sectioning errors +syn keyword xf86confSectionError Section contained +syn keyword xf86confSectionError EndSection +syn keyword xf86confSubSectionError SubSection +syn keyword xf86confSubSectionError EndSubSection +syn keyword xf86confModeSubSectionError Mode +syn keyword xf86confModeSubSectionError EndMode +syn cluster xf86confSectionErrors contains=xf86confSectionError,xf86confSubSectionError,xf86confModeSubSectionError + +" Values +if b:xf86conf_xfree86_version >= 4 + syn region xf86confString start=+"+ skip=+\\\\\|\\"+ end=+"+ contained contains=xf86confSpecialChar,xf86confConstant,xf86confOptionName oneline keepend nextgroup=xf86confValue skipwhite +else + syn region xf86confString start=+"+ skip=+\\\\\|\\"+ end=+"+ contained contains=xf86confSpecialChar,xf86confOptionName oneline keepend +endif +syn match xf86confSpecialChar "\\\d\d\d\|\\." contained +syn match xf86confDecimalNumber "\(\s\|-\)\zs\d*\.\=\d\+\>" +syn match xf86confFrequency "\(\s\|-\)\zs\d\+\.\=\d*\(Hz\|k\|kHz\|M\|MHz\)" +syn match xf86confOctalNumber "\<0\o\+\>" +syn match xf86confOctalNumberError "\<0\o\+[89]\d*\>" +syn match xf86confHexadecimalNumber "\<0x\x\+\>" +syn match xf86confValue "\s\+.*$" contained contains=xf86confComment,xf86confString,xf86confFrequency,xf86conf\w\+Number,xf86confConstant +syn keyword xf86confOption Option nextgroup=xf86confString skipwhite +syn match xf86confModeLineValue "\"[^\"]\+\"\(\_s\+[0-9.]\+\)\{9}" nextgroup=xf86confSync skipwhite skipnl + +" Sections and subsections +if b:xf86conf_xfree86_version >= 4 + syn region xf86confSection matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"\(Files\|Server[_ ]*Flags\|Input[_ ]*Device\|Device\|Video[_ ]*Adaptor\|Server[_ ]*Layout\|DRI\|Extensions\|Vendor\|Keyboard\|Pointer\|InputClass\)\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confOption,xf86confKeyword,xf86confSectionError + syn region xf86confSectionModule matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"Module\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confSubsectionAny,xf86confComment,xf86confOption,xf86confKeyword + syn region xf86confSectionMonitor matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"Monitor\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confSubsectionMode,xf86confModeLine,xf86confComment,xf86confOption,xf86confKeyword + syn region xf86confSectionModes matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"Modes\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confSubsectionMode,xf86confModeLine,xf86confComment + syn region xf86confSectionScreen matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"Screen\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confSubsectionDisplay,xf86confComment,xf86confOption,xf86confKeyword + syn region xf86confSubSectionAny matchgroup=xf86confSectionDelim start="^\s*SubSection\s\+\"[^\"]\+\"" end="^\s*EndSubSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confOption,xf86confKeyword,@xf86confSectionErrors + syn region xf86confSubSectionMode matchgroup=xf86confSectionDelim start="^\s*Mode\s\+\"[^\"]\+\"" end="^\s*EndMode\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confKeyword,@xf86confSectionErrors + syn region xf86confSubSectionDisplay matchgroup=xf86confSectionDelim start="^\s*SubSection\s\+\"Display\"" end="^\s*EndSubSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confOption,xf86confKeyword,@xf86confSectionErrors +else + syn region xf86confSection matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"\(Files\|Server[_ ]*Flags\|Device\|Keyboard\|Pointer\)\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confOptionName,xf86confOption,xf86confKeyword + syn region xf86confSectionMX matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"\(Module\|Xinput\)\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confSubsectionAny,xf86confComment,xf86confOptionName,xf86confOption,xf86confKeyword + syn region xf86confSectionMonitor matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"Monitor\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confSubsectionMode,xf86confModeLine,xf86confComment,xf86confOptionName,xf86confOption,xf86confKeyword + syn region xf86confSectionScreen matchgroup=xf86confSectionDelim start="^\s*Section\s\+\"Screen\"" end="^\s*EndSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confSubsectionDisplay,xf86confComment,xf86confOptionName,xf86confOption,xf86confKeyword + syn region xf86confSubSectionAny matchgroup=xf86confSectionDelim start="^\s*SubSection\s\+\"[^\"]\+\"" end="^\s*EndSubSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confOptionName,xf86confOption,xf86confKeyword,@xf86confSectionErrors + syn region xf86confSubSectionMode matchgroup=xf86confSectionDelim start="^\s*Mode\s\+\"[^\"]\+\"" end="^\s*EndMode\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confOptionName,xf86confOption,xf86confKeyword,@xf86confSectionErrors + syn region xf86confSubSectionDisplay matchgroup=xf86confSectionDelim start="^\s*SubSection\s\+\"Display\"" end="^\s*EndSubSection\>" skip="#.*$\|\"[^\"]*\"" contains=xf86confComment,xf86confOptionName,xf86confOption,xf86confKeyword,@xf86confSectionErrors +endif + +" Options +if b:xf86conf_xfree86_version >= 4 + command -nargs=+ Xf86confdeclopt syn keyword xf86confOptionName contained +else + command -nargs=+ Xf86confdeclopt syn keyword xf86confOptionName contained nextgroup=xf86confValue,xf86confComment skipwhite +endif + +Xf86confdeclopt 18bitBus AGPFastWrite AGPMode Accel AllowClosedownGrabs AllowDeactivateGrabs +Xf86confdeclopt AllowMouseOpenFail AllowNonLocalModInDev AllowNonLocalXvidtune AlwaysCore +Xf86confdeclopt AngleOffset AutoRepeat BaudRate BeamTimeout Beep BlankTime BlockWrite BottomX +Xf86confdeclopt BottomY ButtonNumber ButtonThreshold Buttons ByteSwap CacheLines ChordMiddle +Xf86confdeclopt ClearDTR ClearDTS ClickMode CloneDisplay CloneHSync CloneMode CloneVRefresh +Xf86confdeclopt ColorKey Composite CompositeSync CoreKeyboard CorePointer Crt2Memory CrtScreen +Xf86confdeclopt CrtcNumber CyberShadow CyberStretch DDC DDCMode DMAForXv DPMS Dac6Bit DacSpeed +Xf86confdeclopt DataBits Debug DebugLevel DefaultServerLayout DeltaX DeltaY Device DeviceName +Xf86confdeclopt DisableModInDev DisableVidModeExtension Display Display1400 DontVTSwitch +Xf86confdeclopt DontZap DontZoom DoubleScan DozeMode DozeScan DozeTime DragLockButtons +Xf86confdeclopt DualCount DualRefresh EarlyRasPrecharge Emulate3Buttons Emulate3Timeout +Xf86confdeclopt EmulateWheel EmulateWheelButton EmulateWheelInertia EnablePageFlip EnterCount +Xf86confdeclopt EstimateSizesAggressively ExternDisp FPClock16 FPClock24 FPClock32 +Xf86confdeclopt FPClock8 FPDither FastDram FifoAggresive FifoConservative FifoModerate +Xf86confdeclopt FireGL3000 FixPanelSize FlatPanel FlipXY FlowControl ForceCRT1 ForceCRT2Type +Xf86confdeclopt ForceLegacyCRT ForcePCIMode FpmVRAM FrameBufferWC FullMMIO GammaBrightness +Xf86confdeclopt HWClocks HWCursor HandleSpecialKeys HistorySize Interlace Interlaced InternDisp +Xf86confdeclopt InvX InvY InvertX InvertY KeepShape LCDClock LateRasPrecharge LcdCenter +Xf86confdeclopt LeftAlt Linear MGASDRAM MMIO MMIOCache MTTR MaxX MaxY MaximumXPosition +Xf86confdeclopt MaximumYPosition MinX MinY MinimumXPosition MinimumYPosition NoAccel +Xf86confdeclopt NoAllowMouseOpenFail NoAllowNonLocalModInDev NoAllowNonLocalXvidtune +Xf86confdeclopt NoBlockWrite NoCompositeSync NoCompression NoCrtScreen NoCyberShadow NoDCC +Xf86confdeclopt NoDDC NoDac6Bit NoDebug NoDisableModInDev NoDisableVidModeExtension NoDontZap +Xf86confdeclopt NoDontZoom NoFireGL3000 NoFixPanelSize NoFpmVRAM NoFrameBufferWC NoHWClocks +Xf86confdeclopt NoHWCursor NoHal NoLcdCenter NoLinear NoMGASDRAM NoMMIO NoMMIOCache NoMTTR +Xf86confdeclopt NoOverClockMem NoOverlay NoPC98 NoPM NoPciBurst NoPciRetry NoProbeClock +Xf86confdeclopt NoSTN NoSWCursor NoShadowFb NoShowCache NoSlowEDODRAM NoStretch NoSuspendHack +Xf86confdeclopt NoTexturedVideo NoTrapSignals NoUseFBDev NoUseModeline NoUseVclk1 NoVTSysReq +Xf86confdeclopt NoXVideo NvAGP OSMImageBuffers OffTime Origin OverClockMem Overlay +Xf86confdeclopt PC98 PCIBurst PM PWMActive PWMSleep PanelDelayCompensation PanelHeight +Xf86confdeclopt PanelOff PanelWidth Parity PciBurst PciRetry Pixmap Port PressDur PressPitch +Xf86confdeclopt PressVol ProbeClocks ProgramFPRegs Protocol RGBBits ReleaseDur ReleasePitch +Xf86confdeclopt ReportingMode Resolution RightAlt RightCtl Rotate STN SWCursor SampleRate +Xf86confdeclopt ScreenNumber ScrollLock SendCoreEvents SendDragEvents Serial ServerNumLock +Xf86confdeclopt SetLcdClk SetMClk SetRefClk ShadowFb ShadowStatus ShowCache SleepMode +Xf86confdeclopt SleepScan SleepTime SlowDram SlowEDODRAM StandbyTime StopBits Stretch +Xf86confdeclopt SuspendHack SuspendTime SwapXY SyncOnGreen TV TVOutput TVOverscan TVStandard +Xf86confdeclopt TVXPosOffset TVYPosOffset TexturedVideo Threshold Tilt TopX TopY TouchTime +Xf86confdeclopt TrapSignals Type USB UseBIOS UseFB UseFBDev UseFlatPanel UseModeline +Xf86confdeclopt UseROMData UseVclk1 VTInit VTSysReq VTime VideoKey Vmin XAxisMapping +Xf86confdeclopt XLeds XVideo XaaNoCPUToScreenColorExpandFill XaaNoColor8x8PatternFillRect +Xf86confdeclopt XaaNoColor8x8PatternFillTrap XaaNoDashedBresenhamLine XaaNoDashedTwoPointLine +Xf86confdeclopt XaaNoImageWriteRect XaaNoMono8x8PatternFillRect XaaNoMono8x8PatternFillTrap +Xf86confdeclopt XaaNoOffscreenPixmaps XaaNoPixmapCache XaaNoScanlineCPUToScreenColorExpandFill +Xf86confdeclopt XaaNoScanlineImageWriteRect XaaNoScreenToScreenColorExpandFill +Xf86confdeclopt XaaNoScreenToScreenCopy XaaNoSolidBresenhamLine XaaNoSolidFillRect +Xf86confdeclopt XaaNoSolidFillTrap XaaNoSolidHorVertLine XaaNoSolidTwoPointLine Xinerama +Xf86confdeclopt XkbCompat XkbDisable XkbGeometry XkbKeycodes XkbKeymap XkbLayout XkbModel +Xf86confdeclopt XkbOptions XkbRules XkbSymbols XkbTypes XkbVariant XvBskew XvHsync XvOnCRT2 +Xf86confdeclopt XvRskew XvVsync YAxisMapping ZAxisMapping ZoomOnLCD + +delcommand Xf86confdeclopt + +" Keywords +syn keyword xf86confKeyword Device Driver FontPath Group Identifier Load ModelName ModulePath Monitor RGBPath VendorName VideoAdaptor Visual nextgroup=xf86confComment,xf86confString skipwhite +syn keyword xf86confKeyword BiosBase Black BoardName BusID ChipID ChipRev Chipset nextgroup=xf86confComment,xf86confValue +syn keyword xf86confKeyword ClockChip Clocks DacSpeed DefaultDepth DefaultFbBpp nextgroup=xf86confComment,xf86confValue +syn keyword xf86confKeyword DefaultColorDepth nextgroup=xf86confComment,xf86confValue +syn keyword xf86confKeyword Depth DisplaySize DotClock FbBpp Flags Gamma HorizSync nextgroup=xf86confComment,xf86confValue +syn keyword xf86confKeyword Hskew HTimings InputDevice IOBase MemBase Mode nextgroup=xf86confComment,xf86confValue +syn keyword xf86confKeyword Modes Ramdac Screen TextClockFreq UseModes VendorName nextgroup=xf86confComment,xf86confValue +syn keyword xf86confKeyword VertRefresh VideoRam ViewPort Virtual VScan VTimings nextgroup=xf86confComment,xf86confValue +syn keyword xf86confKeyword Weight White nextgroup=xf86confComment,xf86confValue +syn keyword xf86confModeLine ModeLine nextgroup=xf86confComment,xf86confModeLineValue skipwhite skipnl + +" Constants +if b:xf86conf_xfree86_version >= 4 + syn keyword xf86confConstant true false on off yes no omit contained +else + syn keyword xf86confConstant Meta Compose Control +endif +syn keyword xf86confConstant StaticGray GrayScale StaticColor PseudoColor TrueColor DirectColor contained +syn keyword xf86confConstant Absolute RightOf LeftOf Above Below Relative StaticGray GrayScale StaticColor PseudoColor TrueColor DirectColor contained +syn match xf86confSync "\(\s\+[+-][CHV]_*Sync\)\+" contained + +" Synchronization +if b:xf86conf_xfree86_version >= 4 + syn sync match xf86confSyncSection grouphere xf86confSection "^\s*Section\s\+\"\(Files\|Server[_ ]*Flags\|Input[_ ]*Device\|Device\|Video[_ ]*Adaptor\|Server[_ ]*Layout\|DRI\|Extensions\|Vendor\|Keyboard\|Pointer\|InputClass\)\"" + syn sync match xf86confSyncSectionModule grouphere xf86confSectionModule "^\s*Section\s\+\"Module\"" + syn sync match xf86confSyncSectionModes groupthere xf86confSectionModes "^\s*Section\s\+\"Modes\"" +else + syn sync match xf86confSyncSection grouphere xf86confSection "^\s*Section\s\+\"\(Files\|Server[_ ]*Flags\|Device\|Keyboard\|Pointer\)\"" + syn sync match xf86confSyncSectionMX grouphere xf86confSectionMX "^\s*Section\s\+\"\(Module\|Xinput\)\"" +endif +syn sync match xf86confSyncSectionMonitor groupthere xf86confSectionMonitor "^\s*Section\s\+\"Monitor\"" +syn sync match xf86confSyncSectionScreen groupthere xf86confSectionScreen "^\s*Section\s\+\"Screen\"" +syn sync match xf86confSyncEndSection groupthere NONE "^\s*End_*Section\s*$" + +" Define the default highlighting +hi def link xf86confComment Comment +hi def link xf86confTodo Todo +hi def link xf86confSectionDelim Statement +hi def link xf86confOptionName Identifier + +hi def link xf86confSectionError xf86confError +hi def link xf86confSubSectionError xf86confError +hi def link xf86confModeSubSectionError xf86confError +hi def link xf86confOctalNumberError xf86confError +hi def link xf86confError Error + +hi def link xf86confOption xf86confKeyword +hi def link xf86confModeLine xf86confKeyword +hi def link xf86confKeyword Type + +hi def link xf86confDecimalNumber xf86confNumber +hi def link xf86confOctalNumber xf86confNumber +hi def link xf86confHexadecimalNumber xf86confNumber +hi def link xf86confFrequency xf86confNumber +hi def link xf86confModeLineValue Constant +hi def link xf86confNumber Constant + +hi def link xf86confSync xf86confConstant +hi def link xf86confConstant Special +hi def link xf86confSpecialChar Special +hi def link xf86confString String + +hi def link xf86confValue Constant + +let b:current_syntax = "xf86conf" + +endif diff --git a/syntax/xhtml.vim b/syntax/xhtml.vim new file mode 100644 index 0000000..e0859d3 --- /dev/null +++ b/syntax/xhtml.vim @@ -0,0 +1,15 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: XHTML +" Maintainer: noone +" Last Change: 2003 Feb 04 + +" Load the HTML syntax for now. +runtime! syntax/html.vim + +let b:current_syntax = "xhtml" + +" vim: ts=8 + +endif diff --git a/syntax/xinetd.vim b/syntax/xinetd.vim new file mode 100644 index 0000000..dac59d9 --- /dev/null +++ b/syntax/xinetd.vim @@ -0,0 +1,351 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: xinetd.conf(5) configuration file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword xinetdTodo contained TODO FIXME XXX NOTE + +syn region xinetdComment display oneline start='^\s*#' end='$' + \ contains=xinetdTodo,@Spell + +syn match xinetdService '^\s*service\>' + \ nextgroup=xinetdServiceName skipwhite + +syn match xinetdServiceName contained '\S\+' + \ nextgroup=xinetdServiceGroup skipwhite skipnl + +syn match xinetdDefaults '^\s*defaults' + \ nextgroup=xinetdServiceGroup skipwhite skipnl + +syn region xinetdServiceGroup contained transparent + \ matchgroup=xinetdServiceGroupD start='{' + \ matchgroup=xinetdServiceGroupD end='}' + \ contains=xinetdAttribute,xinetdReqAttribute, + \ xinetdDisable + +syn keyword xinetdReqAttribute contained user server protocol + \ nextgroup=xinetdStringEq skipwhite + +syn keyword xinetdAttribute contained id group bind + \ interface + \ nextgroup=xinetdStringEq skipwhite + +syn match xinetdStringEq contained display '=' + \ nextgroup=xinetdString skipwhite + +syn match xinetdString contained display '\S\+' + +syn keyword xinetdAttribute contained type nextgroup=xinetdTypeEq skipwhite + +syn match xinetdTypeEq contained display '=' + \ nextgroup=xinetdType skipwhite + +syn keyword xinetdType contained RPC INTERNAL TCPMUX TCPMUXPLUS + \ UNLISTED + \ nextgroup=xinetdType skipwhite + +syn keyword xinetdAttribute contained flags + \ nextgroup=xinetdFlagsEq skipwhite + +syn cluster xinetdFlagsC contains=xinetdFlags,xinetdDeprFlags + +syn match xinetdFlagsEq contained display '=' + \ nextgroup=@xinetdFlagsC skipwhite + +syn keyword xinetdFlags contained INTERCEPT NORETRY IDONLY NAMEINARGS + \ NODELAY KEEPALIVE NOLIBWRAP SENSOR IPv4 IPv6 + \ nextgroup=@xinetdFlagsC skipwhite + +syn keyword xinetdDeprFlags contained REUSE nextgroup=xinetdFlagsC skipwhite + +syn keyword xinetdDisable contained disable + \ nextgroup=xinetdBooleanEq skipwhite + +syn match xinetdBooleanEq contained display '=' + \ nextgroup=xinetdBoolean skipwhite + +syn keyword xinetdBoolean contained yes no + +syn keyword xinetdReqAttribute contained socket_type + \ nextgroup=xinetdSocketTypeEq skipwhite + +syn match xinetdSocketTypeEq contained display '=' + \ nextgroup=xinetdSocketType skipwhite + +syn keyword xinetdSocketType contained stream dgram raw seqpacket + +syn keyword xinetdReqAttribute contained wait + \ nextgroup=xinetdBooleanEq skipwhite + +syn keyword xinetdAttribute contained groups mdns + \ nextgroup=xinetdBooleanEq skipwhite + +syn keyword xinetdAttribute contained instances per_source rlimit_cpu + \ rlimit_data rlimit_rss rlimit_stack + \ nextgroup=xinetdUNumberEq skipwhite + +syn match xinetdUNumberEq contained display '=' + \ nextgroup=xinetdUnlimited,xinetdNumber + \ skipwhite + +syn keyword xinetdUnlimited contained UNLIMITED + +syn match xinetdNumber contained display '\<\d\+\>' + +syn keyword xinetdAttribute contained nice + \ nextgroup=xinetdSignedNumEq skipwhite + +syn match xinetdSignedNumEq contained display '=' + \ nextgroup=xinetdSignedNumber skipwhite + +syn match xinetdSignedNumber contained display '[+-]\=\d\+\>' + +syn keyword xinetdAttribute contained server_args + \ enabled + \ nextgroup=xinetdStringsEq skipwhite + +syn match xinetdStringsEq contained display '=' + \ nextgroup=xinetdStrings skipwhite + +syn match xinetdStrings contained display '\S\+' + \ nextgroup=xinetdStrings skipwhite + +syn keyword xinetdAttribute contained only_from no_access passenv + \ nextgroup=xinetdStringsAdvEq skipwhite + +syn match xinetdStringsAdvEq contained display '[+-]\==' + \ nextgroup=xinetdStrings skipwhite + +syn keyword xinetdAttribute contained access_times + \ nextgroup=xinetdTimeRangesEq skipwhite + +syn match xinetdTimeRangesEq contained display '=' + \ nextgroup=xinetdTimeRanges skipwhite + +syn match xinetdTimeRanges contained display + \ '\%(0?\d\|1\d\|2[0-3]\):\%(0?\d\|[1-5]\d\)-\%(0?\d\|1\d\|2[0-3]\):\%(0?\d\|[1-5]\d\)' + \ nextgroup=xinetdTimeRanges skipwhite + +syn keyword xinetdAttribute contained log_type nextgroup=xinetdLogTypeEq + \ skipwhite + +syn match xinetdLogTypeEq contained display '=' + \ nextgroup=xinetdLogType skipwhite + +syn keyword xinetdLogType contained SYSLOG nextgroup=xinetdSyslogType + \ skipwhite + +syn keyword xinetdLogType contained FILE nextgroup=xinetdLogFile skipwhite + +syn keyword xinetdSyslogType contained daemon auth authpriv user mail lpr + \ news uucp ftp local0 local1 local2 local3 + \ local4 local5 local6 local7 + \ nextgroup=xinetdSyslogLevel skipwhite + +syn keyword xinetdSyslogLevel contained emerg alert crit err warning notice + \ info debug + +syn match xinetdLogFile contained display '\S\+' + \ nextgroup=xinetdLogSoftLimit skipwhite + +syn match xinetdLogSoftLimit contained display '\<\d\+\>' + \ nextgroup=xinetdLogHardLimit skipwhite + +syn match xinetdLogHardLimit contained display '\<\d\+\>' + +syn keyword xinetdAttribute contained log_on_success + \ nextgroup=xinetdLogSuccessEq skipwhite + +syn match xinetdLogSuccessEq contained display '[+-]\==' + \ nextgroup=xinetdLogSuccess skipwhite + +syn keyword xinetdLogSuccess contained PID HOST USERID EXIT DURATION TRAFFIC + \ nextgroup=xinetdLogSuccess skipwhite + +syn keyword xinetdAttribute contained log_on_failure + \ nextgroup=xinetdLogFailureEq skipwhite + +syn match xinetdLogFailureEq contained display '[+-]\==' + \ nextgroup=xinetdLogFailure skipwhite + +syn keyword xinetdLogFailure contained HOST USERID ATTEMPT + \ nextgroup=xinetdLogFailure skipwhite + +syn keyword xinetdReqAttribute contained rpc_version + \ nextgroup=xinetdRPCVersionEq skipwhite + +syn match xinetdRPCVersionEq contained display '=' + \ nextgroup=xinetdRPCVersion skipwhite + +syn match xinetdRPCVersion contained display '\d\+\%(-\d\+\)\=\>' + +syn keyword xinetdReqAttribute contained rpc_number port + \ nextgroup=xinetdNumberEq skipwhite + +syn match xinetdNumberEq contained display '=' + \ nextgroup=xinetdNumber skipwhite + +syn keyword xinetdAttribute contained env nextgroup=xinetdEnvEq skipwhite + +syn match xinetdEnvEq contained display '+\==' + \ nextgroup=xinetdEnvName skipwhite + +syn match xinetdEnvName contained display '[^=]\+' + \ nextgroup=xinetdEnvNameEq + +syn match xinetdEnvNameEq contained display '=' nextgroup=xinetdEnvValue + +syn match xinetdEnvValue contained display '\S\+' + \ nextgroup=xinetdEnvName skipwhite + +syn keyword xinetdAttribute contained banner banner_success banner_failure + \ nextgroup=xinetdPathEq skipwhite + +syn keyword xinetdPPAttribute include includedir + \ nextgroup=xinetdPath skipwhite + +syn match xinetdPathEq contained display '=' + \ nextgroup=xinetdPath skipwhite + +syn match xinetdPath contained display '\S\+' + +syn keyword xinetdAttribute contained redirect nextgroup=xinetdRedirectEq + \ skipwhite + +syn match xinetdRedirectEq contained display '=' + \ nextgroup=xinetdRedirectIP skipwhite + +syn match xinetdRedirectIP contained display '\S\+' + \ nextgroup=xinetdNumber skipwhite + +syn keyword xinetdAttribute contained cps nextgroup=xinetdCPSEq skipwhite + +syn match xinetdCPSEq contained display '=' + \ nextgroup=xinetdCPS skipwhite + +syn match xinetdCPS contained display '\<\d\+\>' + \ nextgroup=xinetdNumber skipwhite + +syn keyword xinetdAttribute contained max_load nextgroup=xinetdFloatEq + \ skipwhite + +syn match xinetdFloatEq contained display '=' + \ nextgroup=xinetdFloat skipwhite + +syn match xinetdFloat contained display '\d\+\.\d*\|\.\d\+' + +syn keyword xinetdAttribute contained umask nextgroup=xinetdOctalEq + \ skipwhite + +syn match xinetdOctalEq contained display '=' + \ nextgroup=xinetdOctal,xinetdOctalError + \ skipwhite + +syn match xinetdOctal contained display '\<0\o\+\>' + \ contains=xinetdOctalZero +syn match xinetdOctalZero contained display '\<0' +syn match xinetdOctalError contained display '\<0\o*[89]\d*\>' + +syn keyword xinetdAttribute contained rlimit_as nextgroup=xinetdASEq + \ skipwhite + +syn match xinetdASEq contained display '=' + \ nextgroup=xinetdAS,xinetdUnlimited + \ skipwhite + +syn match xinetdAS contained display '\d\+' nextgroup=xinetdASMult + +syn match xinetdASMult contained display '[KM]' + +syn keyword xinetdAttribute contained deny_time nextgroup=xinetdDenyTimeEq + \ skipwhite + +syn match xinetdDenyTimeEq contained display '=' + \ nextgroup=xinetdDenyTime,xinetdNumber + \ skipwhite + +syn keyword xinetdDenyTime contained FOREVER NEVER + +hi def link xinetdTodo Todo +hi def link xinetdComment Comment +hi def link xinetdService Keyword +hi def link xinetdServiceName String +hi def link xinetdDefaults Keyword +hi def link xinetdServiceGroupD Delimiter +hi def link xinetdReqAttribute Keyword +hi def link xinetdAttribute Type +hi def link xinetdEq Operator +hi def link xinetdStringEq xinetdEq +hi def link xinetdString String +hi def link xinetdTypeEq xinetdEq +hi def link xinetdType Identifier +hi def link xinetdFlagsEq xinetdEq +hi def link xinetdFlags xinetdType +hi def link xinetdDeprFlags WarningMsg +hi def link xinetdDisable Special +hi def link xinetdBooleanEq xinetdEq +hi def link xinetdBoolean Boolean +hi def link xinetdSocketTypeEq xinetdEq +hi def link xinetdSocketType xinetdType +hi def link xinetdUNumberEq xinetdEq +hi def link xinetdUnlimited Define +hi def link xinetdNumber Number +hi def link xinetdSignedNumEq xinetdEq +hi def link xinetdSignedNumber xinetdNumber +hi def link xinetdStringsEq xinetdEq +hi def link xinetdStrings xinetdString +hi def link xinetdStringsAdvEq xinetdEq +hi def link xinetdTimeRangesEq xinetdEq +hi def link xinetdTimeRanges Number +hi def link xinetdLogTypeEq xinetdEq +hi def link xinetdLogType Keyword +hi def link xinetdSyslogType xinetdType +hi def link xinetdSyslogLevel Number +hi def link xinetdLogFile xinetdPath +hi def link xinetdLogSoftLimit xinetdNumber +hi def link xinetdLogHardLimit xinetdNumber +hi def link xinetdLogSuccessEq xinetdEq +hi def link xinetdLogSuccess xinetdType +hi def link xinetdLogFailureEq xinetdEq +hi def link xinetdLogFailure xinetdType +hi def link xinetdRPCVersionEq xinetdEq +hi def link xinetdRPCVersion xinetdNumber +hi def link xinetdNumberEq xinetdEq +hi def link xinetdEnvEq xinetdEq +hi def link xinetdEnvName Identifier +hi def link xinetdEnvNameEq xinetdEq +hi def link xinetdEnvValue String +hi def link xinetdPPAttribute PreProc +hi def link xinetdPathEq xinetdEq +hi def link xinetdPath String +hi def link xinetdRedirectEq xinetdEq +hi def link xinetdRedirectIP String +hi def link xinetdCPSEq xinetdEq +hi def link xinetdCPS xinetdNumber +hi def link xinetdFloatEq xinetdEq +hi def link xinetdFloat xinetdNumber +hi def link xinetdOctalEq xinetdEq +hi def link xinetdOctal xinetdNumber +hi def link xinetdOctalZero PreProc +hi def link xinetdOctalError Error +hi def link xinetdASEq xinetdEq +hi def link xinetdAS xinetdNumber +hi def link xinetdASMult PreProc +hi def link xinetdDenyTimeEq xinetdEq +hi def link xinetdDenyTime PreProc + +let b:current_syntax = "xinetd" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/xkb.vim b/syntax/xkb.vim new file mode 100644 index 0000000..f0f58cd --- /dev/null +++ b/syntax/xkb.vim @@ -0,0 +1,83 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" This is a GENERATED FILE. Please always refer to source file at the URI below. +" Language: XKB (X Keyboard Extension) components +" Maintainer: David Ne\v{c}as (Yeti) +" Last Change: 2003-04-13 +" URL: http://trific.ath.cx/Ftp/vim/syntax/xkb.vim + +" Setup +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case match +syn sync minlines=100 + +" Comments +syn region xkbComment start="//" skip="\\$" end="$" keepend contains=xkbTodo +syn region xkbComment start="/\*" matchgroup=NONE end="\*/" contains=xkbCommentStartError,xkbTodo +syn match xkbCommentError "\*/" +syntax match xkbCommentStartError "/\*" contained +syn sync ccomment xkbComment +syn keyword xkbTodo TODO FIXME contained + +" Literal strings +syn match xkbSpecialChar "\\\d\d\d\|\\." contained +syn region xkbString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=xkbSpecialChar oneline + +" Catch errors caused by wrong parenthesization +syn region xkbParen start='(' end=')' contains=ALLBUT,xkbParenError,xkbSpecial,xkbTodo transparent +syn match xkbParenError ")" +syn region xkbBrace start='{' end='}' contains=ALLBUT,xkbBraceError,xkbSpecial,xkbTodo transparent +syn match xkbBraceError "}" +syn region xkbBracket start='\[' end='\]' contains=ALLBUT,xkbBracketError,xkbSpecial,xkbTodo transparent +syn match xkbBracketError "\]" + +" Physical keys +syn match xkbPhysicalKey "<\w\+>" + +" Keywords +syn keyword xkbPreproc augment include replace +syn keyword xkbConstant False True +syn keyword xkbModif override replace +syn keyword xkbIdentifier action affect alias allowExplicit approx baseColor button clearLocks color controls cornerRadius count ctrls description driveskbd font fontSize gap group groups height indicator indicatorDrivesKeyboard interpret key keys labelColor latchToLock latchMods left level_name map maximum minimum modifier_map modifiers name offColor onColor outline preserve priority repeat row section section setMods shape slant solid symbols text top type useModMapMods virtualModifier virtualMods virtual_modifiers weight whichModState width +syn keyword xkbFunction AnyOf ISOLock LatchGroup LatchMods LockControls LockGroup LockMods LockPointerButton MovePtr NoAction PointerButton SetControls SetGroup SetMods SetPtrDflt Terminate +syn keyword xkbTModif default hidden partial virtual +syn keyword xkbSect alphanumeric_keys alternate_group function_keys keypad_keys modifier_keys xkb_compatibility xkb_geometry xkb_keycodes xkb_keymap xkb_semantics xkb_symbols xkb_types + +" Define the default highlighting + +hi def link xkbModif xkbPreproc +hi def link xkbTModif xkbPreproc +hi def link xkbPreproc Preproc + +hi def link xkbIdentifier Keyword +hi def link xkbFunction Function +hi def link xkbSect Type +hi def link xkbPhysicalKey Identifier +hi def link xkbKeyword Keyword + +hi def link xkbComment Comment +hi def link xkbTodo Todo + +hi def link xkbConstant Constant +hi def link xkbString String + +hi def link xkbSpecialChar xkbSpecial +hi def link xkbSpecial Special + +hi def link xkbParenError xkbBalancingError +hi def link xkbBraceError xkbBalancingError +hi def link xkbBraketError xkbBalancingError +hi def link xkbBalancingError xkbError +hi def link xkbCommentStartError xkbCommentError +hi def link xkbCommentError xkbError +hi def link xkbError Error + + +let b:current_syntax = "xkb" + +endif diff --git a/syntax/xmath.vim b/syntax/xmath.vim new file mode 100644 index 0000000..c9c403f --- /dev/null +++ b/syntax/xmath.vim @@ -0,0 +1,229 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: xmath (a simulation tool) +" Maintainer: Charles E. Campbell +" Last Change: Aug 31, 2016 +" Version: 9 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_XMATH + +" For version 5.x: Clear all syntax items +" For version 6.x: Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" parenthesis sanity checker +syn region xmathZone matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" transparent contains=ALLBUT,xmathError,xmathBraceError,xmathCurlyError +syn region xmathZone matchgroup=Delimiter start="{" matchgroup=Delimiter end="}" transparent contains=ALLBUT,xmathError,xmathBraceError,xmathParenError +syn region xmathZone matchgroup=Delimiter start="\[" matchgroup=Delimiter end="]" transparent contains=ALLBUT,xmathError,xmathCurlyError,xmathParenError +syn match xmathError "[)\]}]" +syn match xmathBraceError "[)}]" contained +syn match xmathCurlyError "[)\]]" contained +syn match xmathParenError "[\]}]" contained +syn match xmathComma "[,;:]" +syn match xmathComma "\.\.\.$" + +" A bunch of useful xmath keywords +syn case ignore +syn keyword xmathFuncCmd function endfunction command endcommand +syn keyword xmathStatement abort beep debug default define +syn keyword xmathStatement execute exit pause return undefine +syn keyword xmathConditional if else elseif endif +syn keyword xmathRepeat while for endwhile endfor +syn keyword xmathCmd anigraph deletedatastore keep renamedatastore +syn keyword xmathCmd autocode deletestd linkhyper renamestd +syn keyword xmathCmd build deletesuperblock linksim renamesuperblock +syn keyword xmathCmd comment deletetransition listusertype save +syn keyword xmathCmd copydatastore deleteusertype load sbadisplay +syn keyword xmathCmd copystd detailmodel lock set +syn keyword xmathCmd copysuperblock display minmax_display setsbdefault +syn keyword xmathCmd createblock documentit modifyblock show +syn keyword xmathCmd createbubble editcatalog modifybubble showlicense +syn keyword xmathCmd createconnection erase modifystd showsbdefault +syn keyword xmathCmd creatertf expandsuperbubble modifysuperblock stop +syn keyword xmathCmd createstd for modifytransition stopcosim +syn keyword xmathCmd createsuperblock go modifyusertype syntax +syn keyword xmathCmd createsuperbubble goto new unalias +syn keyword xmathCmd createtransition hardcopy next unlock +syn keyword xmathCmd createusertype help polargraph usertype +syn keyword xmathCmd delete hyperbuild print whatis +syn keyword xmathCmd deleteblock if printmodel while +syn keyword xmathCmd deletebubble ifilter quit who +syn keyword xmathCmd deleteconnection ipcwc remove xgraph + +syn keyword xmathFunc abcd eye irea querystdoptions +syn keyword xmathFunc abs eyepattern is querysuperblock +syn keyword xmathFunc acos feedback ISID querysuperblockopt +syn keyword xmathFunc acosh fft ISID Models querytransition +syn keyword xmathFunc adconversion fftpdm kronecker querytransitionopt +syn keyword xmathFunc afeedback filter length qz +syn keyword xmathFunc all find limit rampinvar +syn keyword xmathFunc ambiguity firparks lin random +syn keyword xmathFunc amdemod firremez lin30 randpdm +syn keyword xmathFunc analytic firwind linearfm randpert +syn keyword xmathFunc analyze fmdemod linfnorm randsys +syn keyword xmathFunc any forwdiff lintodb rank +syn keyword xmathFunc append fprintf list rayleigh +syn keyword xmathFunc argn frac log rcepstrum +syn keyword xmathFunc argv fracred log10 rcond +syn keyword xmathFunc arma freq logm rdintegrate +syn keyword xmathFunc arma2ss freqcircle lognormal read +syn keyword xmathFunc armax freqcont logspace real +syn keyword xmathFunc ascii frequencyhop lowpass rectify +syn keyword xmathFunc asin fsesti lpopt redschur +syn keyword xmathFunc asinh fslqgcomp lqgcomp reflect +syn keyword xmathFunc atan fsregu lqgltr regulator +syn keyword xmathFunc atan2 fwls ls residue +syn keyword xmathFunc atanh gabor ls2unc riccati +syn keyword xmathFunc attach_ac100 garb ls2var riccati_eig +syn keyword xmathFunc backdiff gaussian lsjoin riccati_schur +syn keyword xmathFunc balance gcexp lu ricean +syn keyword xmathFunc balmoore gcos lyapunov rifd +syn keyword xmathFunc bandpass gdfileselection makecontinuous rlinfo +syn keyword xmathFunc bandstop gdmessage makematrix rlocus +syn keyword xmathFunc bj gdselection makepoly rms +syn keyword xmathFunc blknorm genconv margin rootlocus +syn keyword xmathFunc bode get markoff roots +syn keyword xmathFunc bpm get_info30 matchedpz round +syn keyword xmathFunc bpm2inn get_inn max rref +syn keyword xmathFunc bpmjoin gfdm maxlike rve_get +syn keyword xmathFunc bpmsplit gfsk mean rve_info +syn keyword xmathFunc bst gfskernel mergeseg rve_reset +syn keyword xmathFunc buttconstr gfunction min rve_update +syn keyword xmathFunc butterworth ggauss minimal samplehold +syn keyword xmathFunc cancel giv mkpert schur +syn keyword xmathFunc canform giv2var mkphase sdf +syn keyword xmathFunc ccepstrum givjoin mma sds +syn keyword xmathFunc char gpsk mmaget sdtrsp +syn keyword xmathFunc chebconstr gpulse mmaput sec +syn keyword xmathFunc chebyshev gqam mod sech +syn keyword xmathFunc check gqpsk modal siginterp +syn keyword xmathFunc cholesky gramp modalstate sign +syn keyword xmathFunc chop gsawtooth modcarrier sim +syn keyword xmathFunc circonv gsigmoid mreduce sim30 +syn keyword xmathFunc circorr gsin mtxplt simin +syn keyword xmathFunc clock gsinc mu simin30 +syn keyword xmathFunc clocus gsqpsk mulhank simout +syn keyword xmathFunc clsys gsquarewave multipath simout30 +syn keyword xmathFunc coherence gstep musynfit simtransform +syn keyword xmathFunc colorind GuiDialogCreate mxstr2xmstr sin +syn keyword xmathFunc combinepf GuiDialogDestroy mxstring2xmstring singriccati +syn keyword xmathFunc commentof GuiFlush names sinh +syn keyword xmathFunc compare GuiGetValue nichols sinm +syn keyword xmathFunc complementaryerf GuiManage noisefilt size +syn keyword xmathFunc complexenvelope GuiPlot none smargin +syn keyword xmathFunc complexfreqshift GuiPlotGet norm sns2sys +syn keyword xmathFunc concatseg GuiSetValue numden sort +syn keyword xmathFunc condition GuiShellCreate nyquist spectrad +syn keyword xmathFunc conj GuiShellDeiconify obscf spectrum +syn keyword xmathFunc conmap GuiShellDestroy observable spline +syn keyword xmathFunc connect GuiShellIconify oe sprintf +syn keyword xmathFunc conpdm GuiShellLower ones sqrt +syn keyword xmathFunc constellation GuiShellRaise ophank sqrtm +syn keyword xmathFunc consys GuiShellRealize optimize sresidualize +syn keyword xmathFunc controllable GuiShellUnrealize optscale ss2arma +syn keyword xmathFunc convolve GuiTimer orderfilt sst +syn keyword xmathFunc correlate GuiToolCreate orderstate ssv +syn keyword xmathFunc cos GuiToolDestroy orth stable +syn keyword xmathFunc cosh GuiToolExist oscmd stair +syn keyword xmathFunc cosm GuiUnmanage oscope starp +syn keyword xmathFunc cot GuiWidgetExist osscale step +syn keyword xmathFunc coth h2norm padcrop stepinvar +syn keyword xmathFunc covariance h2syn partialsum string +syn keyword xmathFunc csc hadamard pdm stringex +syn keyword xmathFunc csch hankelsv pdmslice substr +syn keyword xmathFunc csum hessenberg pem subsys +syn keyword xmathFunc ctrcf highpass perfplots sum +syn keyword xmathFunc ctrlplot hilbert period svd +syn keyword xmathFunc daug hilberttransform pfscale svplot +syn keyword xmathFunc dbtolin hinfcontr phaseshift sweep +syn keyword xmathFunc dct hinfnorm pinv symbolmap +syn keyword xmathFunc decimate hinfsyn plot sys2sns +syn keyword xmathFunc defFreqRange histogram plot30 sysic +syn keyword xmathFunc defTimeRange idfreq pmdemod Sysid +syn keyword xmathFunc delay idimpulse poisson system +syn keyword xmathFunc delsubstr idsim poissonimpulse tan +syn keyword xmathFunc det ifft poleplace tanh +syn keyword xmathFunc detrend imag poles taper +syn keyword xmathFunc dht impinvar polezero tfid +syn keyword xmathFunc diagonal impplot poltrend toeplitz +syn keyword xmathFunc differentiate impulse polyfit trace +syn keyword xmathFunc directsequence index polynomial tril +syn keyword xmathFunc discretize indexlist polyval trim +syn keyword xmathFunc divide initial polyvalm trim30 +syn keyword xmathFunc domain initmodel prbs triu +syn keyword xmathFunc dst initx0 product trsp +syn keyword xmathFunc eig inn2bpm psd truncate +syn keyword xmathFunc ellipconstr inn2pe put_inn tustin +syn keyword xmathFunc elliptic inn2unc qpopt uniform +syn keyword xmathFunc erf insertseg qr val +syn keyword xmathFunc error int quantize variance +syn keyword xmathFunc estimator integrate queryblock videolines +syn keyword xmathFunc etfe integratedump queryblockoptions wcbode +syn keyword xmathFunc exist interp querybubble wcgain +syn keyword xmathFunc exp interpolate querybubbleoptionswindow +syn keyword xmathFunc expm inv querycatalog wtbalance +syn keyword xmathFunc extractchan invhilbert queryconnection zeros +syn keyword xmathFunc extractseg iqmix querystd + +syn case match + +" Labels (supports xmath's goto) +syn match xmathLabel "^\s*<[a-zA-Z_][a-zA-Z0-9]*>" + +" String and Character constants +" Highlight special characters (those which have a backslash) differently +syn match xmathSpecial contained "\\\d\d\d\|\\." +syn region xmathString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=xmathSpecial,@Spell +syn match xmathCharacter "'[^\\]'" +syn match xmathSpecialChar "'\\.'" + +syn match xmathNumber "-\=\<\d\+L\=\>\|0[xX][0-9a-fA-F]\+\>" + +" Comments: +" xmath supports #... (like Unix shells) +" and #{ ... }# comment blocks +syn cluster xmathCommentGroup contains=xmathString,xmathTodo,@Spell +syn keyword xmathTodo contained COMBAK DEBUG FIXME Todo TODO XXX +syn match xmathComment "#.*$" contains=@xmathCommentGroup +syn region xmathCommentBlock start="#{" end="}#" contains=@xmathCommentGroup + +" synchronizing +syn sync match xmathSyncComment grouphere xmathCommentBlock "#{" +syn sync match xmathSyncComment groupthere NONE "}#" + +" Define the default highlighting. +if !exists("skip_xmath_syntax_inits") + + hi def link xmathBraceError xmathError + hi def link xmathCmd xmathStatement + hi def link xmathCommentBlock xmathComment + hi def link xmathCurlyError xmathError + hi def link xmathFuncCmd xmathStatement + hi def link xmathParenError xmathError + + " The default methods for highlighting. Can be overridden later + hi def link xmathCharacter Character + hi def link xmathComma Delimiter + hi def link xmathComment Comment + hi def link xmathCommentBlock Comment + hi def link xmathConditional Conditional + hi def link xmathError Error + hi def link xmathFunc Function + hi def link xmathLabel PreProc + hi def link xmathNumber Number + hi def link xmathRepeat Repeat + hi def link xmathSpecial Type + hi def link xmathSpecialChar SpecialChar + hi def link xmathStatement Statement + hi def link xmathString String + hi def link xmathTodo Todo + +endif + +let b:current_syntax = "xmath" + +" vim: ts=17 + +endif diff --git a/syntax/xml.vim b/syntax/xml.vim new file mode 100644 index 0000000..31a1043 --- /dev/null +++ b/syntax/xml.vim @@ -0,0 +1,350 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: XML +" Maintainer: Johannes Zellner +" Author and previous maintainer: +" Paul Siegmann +" Last Change: 2013 Jun 07 +" Filenames: *.xml +" $Id: xml.vim,v 1.3 2006/04/11 21:32:00 vimboss Exp $ + +" CONFIGURATION: +" syntax folding can be turned on by +" +" let g:xml_syntax_folding = 1 +" +" before the syntax file gets loaded (e.g. in ~/.vimrc). +" This might slow down syntax highlighting significantly, +" especially for large files. +" +" CREDITS: +" The original version was derived by Paul Siegmann from +" Claudio Fleiner's html.vim. +" +" REFERENCES: +" [1] http://www.w3.org/TR/2000/REC-xml-20001006 +" [2] http://www.w3.org/XML/1998/06/xmlspec-report-19980910.htm +" +" as pointed out according to reference [1] +" +" 2.3 Common Syntactic Constructs +" [4] NameChar ::= Letter | Digit | '.' | '-' | '_' | ':' | CombiningChar | Extender +" [5] Name ::= (Letter | '_' | ':') (NameChar)* +" +" NOTE: +" 1) empty tag delimiters "/>" inside attribute values (strings) +" confuse syntax highlighting. +" 2) for large files, folding can be pretty slow, especially when +" loading a file the first time and viewoptions contains 'folds' +" so that folds of previous sessions are applied. +" Don't use 'foldmethod=syntax' in this case. + + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:xml_cpo_save = &cpo +set cpo&vim + +syn case match + +" mark illegal characters +syn match xmlError "[<&]" + +" strings (inside tags) aka VALUES +" +" EXAMPLE: +" +" +" ^^^^^^^ +syn region xmlString contained start=+"+ end=+"+ contains=xmlEntity,@Spell display +syn region xmlString contained start=+'+ end=+'+ contains=xmlEntity,@Spell display + + +" punctuation (within attributes) e.g. +" ^ ^ +" syn match xmlAttribPunct +[-:._]+ contained display +syn match xmlAttribPunct +[:.]+ contained display + +" no highlighting for xmlEqual (xmlEqual has no highlighting group) +syn match xmlEqual +=+ display + + +" attribute, everything before the '=' +" +" PROVIDES: @xmlAttribHook +" +" EXAMPLE: +" +" +" ^^^^^^^^^^^^^ +" +syn match xmlAttrib + \ +[-'"<]\@1\%(['">]\@!\|$\)+ + \ contained + \ contains=xmlAttribPunct,@xmlAttribHook + \ display + + +" namespace spec +" +" PROVIDES: @xmlNamespaceHook +" +" EXAMPLE: +" +" +" ^^^ +" +if exists("g:xml_namespace_transparent") +syn match xmlNamespace + \ +\(<\|"':]\+[:]\@=+ + \ contained + \ contains=@xmlNamespaceHook + \ transparent + \ display +else +syn match xmlNamespace + \ +\(<\|"':]\+[:]\@=+ + \ contained + \ contains=@xmlNamespaceHook + \ display +endif + + +" tag name +" +" PROVIDES: @xmlTagHook +" +" EXAMPLE: +" +" +" ^^^ +" +syn match xmlTagName + \ +<\@1<=[^ /!?<>"']\++ + \ contained + \ contains=xmlNamespace,xmlAttribPunct,@xmlTagHook + \ display + + +if exists('g:xml_syntax_folding') + + " start tag + " use matchgroup=xmlTag to skip over the leading '<' + " + " PROVIDES: @xmlStartTagHook + " + " EXAMPLE: + " + " + " s^^^^^^^^^^^^^^^e + " + syn region xmlTag + \ matchgroup=xmlTag start=+<[^ /!?<>"']\@=+ + \ matchgroup=xmlTag end=+>+ + \ contained + \ contains=xmlError,xmlTagName,xmlAttrib,xmlEqual,xmlString,@xmlStartTagHook + + + " highlight the end tag + " + " PROVIDES: @xmlTagHook + " (should we provide a separate @xmlEndTagHook ?) + " + " EXAMPLE: + " + " + " ^^^^^^ + " + syn match xmlEndTag + \ +"']\+>+ + \ contained + \ contains=xmlNamespace,xmlAttribPunct,@xmlTagHook + + + " tag elements with syntax-folding. + " NOTE: NO HIGHLIGHTING -- highlighting is done by contained elements + " + " PROVIDES: @xmlRegionHook + " + " EXAMPLE: + " + " + " + " + " + " some data + " + " + syn region xmlRegion + \ start=+<\z([^ /!?<>"']\+\)+ + \ skip=++ + \ end=++ + \ matchgroup=xmlEndTag end=+/>+ + \ fold + \ contains=xmlTag,xmlEndTag,xmlCdata,xmlRegion,xmlComment,xmlEntity,xmlProcessing,@xmlRegionHook,@Spell + \ keepend + \ extend + +else + + " no syntax folding: + " - contained attribute removed + " - xmlRegion not defined + " + syn region xmlTag + \ matchgroup=xmlTag start=+<[^ /!?<>"']\@=+ + \ matchgroup=xmlTag end=+>+ + \ contains=xmlError,xmlTagName,xmlAttrib,xmlEqual,xmlString,@xmlStartTagHook + + syn match xmlEndTag + \ +"']\+>+ + \ contains=xmlNamespace,xmlAttribPunct,@xmlTagHook + +endif + + +" &entities; compare with dtd +syn match xmlEntity "&[^; \t]*;" contains=xmlEntityPunct +syn match xmlEntityPunct contained "[&.;]" + +if exists('g:xml_syntax_folding') + + " The real comments (this implements the comments as defined by xml, + " but not all xml pages actually conform to it. Errors are flagged. + syn region xmlComment + \ start=++ + \ contains=xmlCommentStart,xmlCommentError + \ extend + \ fold + +else + + " no syntax folding: + " - fold attribute removed + " + syn region xmlComment + \ start=++ + \ contains=xmlCommentStart,xmlCommentError + \ extend + +endif + +syn match xmlCommentStart contained "+ + \ contains=xmlCdataStart,xmlCdataEnd,@xmlCdataHook,@Spell + \ keepend + \ extend + +" using the following line instead leads to corrupt folding at CDATA regions +" syn match xmlCdata ++ contains=xmlCdataStart,xmlCdataEnd,@xmlCdataHook +syn match xmlCdataStart ++ contained + + +" Processing instructions +" This allows "?>" inside strings -- good idea? +syn region xmlProcessing matchgroup=xmlProcessingDelim start="" contains=xmlAttrib,xmlEqual,xmlString + + +if exists('g:xml_syntax_folding') + + " DTD -- we use dtd.vim here + syn region xmlDocType matchgroup=xmlDocTypeDecl + \ start="" + \ fold + \ contains=xmlDocTypeKeyword,xmlInlineDTD,xmlString +else + + " no syntax folding: + " - fold attribute removed + " + syn region xmlDocType matchgroup=xmlDocTypeDecl + \ start="" + \ contains=xmlDocTypeKeyword,xmlInlineDTD,xmlString + +endif + +syn keyword xmlDocTypeKeyword contained DOCTYPE PUBLIC SYSTEM +syn region xmlInlineDTD contained matchgroup=xmlDocTypeDecl start="\[" end="]" contains=@xmlDTD +syn include @xmlDTD :p:h/dtd.vim +unlet b:current_syntax + + +" synchronizing +" TODO !!! to be improved !!! + +syn sync match xmlSyncDT grouphere xmlDocType +\_.\(+ + +if exists('g:xml_syntax_folding') + syn sync match xmlSync grouphere xmlRegion +\_.\(<[^ /!?<>"']\+\)\@=+ + " syn sync match xmlSync grouphere xmlRegion "<[^ /!?<>"']*>" + syn sync match xmlSync groupthere xmlRegion +"']\+>+ +endif + +syn sync minlines=100 + + +" The default highlighting. +hi def link xmlTodo Todo +hi def link xmlTag Function +hi def link xmlTagName Function +hi def link xmlEndTag Identifier +if !exists("g:xml_namespace_transparent") + hi def link xmlNamespace Tag +endif +hi def link xmlEntity Statement +hi def link xmlEntityPunct Type + +hi def link xmlAttribPunct Comment +hi def link xmlAttrib Type + +hi def link xmlString String +hi def link xmlComment Comment +hi def link xmlCommentStart xmlComment +hi def link xmlCommentPart Comment +hi def link xmlCommentError Error +hi def link xmlError Error + +hi def link xmlProcessingDelim Comment +hi def link xmlProcessing Type + +hi def link xmlCdata String +hi def link xmlCdataCdata Statement +hi def link xmlCdataStart Type +hi def link xmlCdataEnd Type + +hi def link xmlDocTypeDecl Function +hi def link xmlDocTypeKeyword Statement +hi def link xmlInlineDTD Function + +let b:current_syntax = "xml" + +let &cpo = s:xml_cpo_save +unlet s:xml_cpo_save + +" vim: ts=8 + +endif diff --git a/syntax/xmodmap.vim b/syntax/xmodmap.vim new file mode 100644 index 0000000..8e64ce6 --- /dev/null +++ b/syntax/xmodmap.vim @@ -0,0 +1,681 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: xmodmap(1) definition file +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2006-04-19 + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn keyword xmodmapTodo contained TODO FIXME XXX NOTE + +syn region xmodmapComment display oneline start='^!' end='$' + \ contains=xmodmapTodo,@Spell + +syn case ignore +syn match xmodmapInt display '\<\d\+\>' +syn match xmodmapHex display '\<0x\x\+\>' +syn match xmodmapOctal display '\<0\o\+\>' +syn match xmodmapOctalError display '\<0\o*[89]\d*' +syn case match + +syn match xmodmapKeySym display '\<[A-Za-z]\>' + +" #include +syn keyword xmodmapKeySym XK_VoidSymbol XK_BackSpace XK_Tab XK_Linefeed + \ XK_Clear XK_Return XK_Pause XK_Scroll_Lock + \ XK_Sys_Req XK_Escape XK_Delete XK_Multi_key + \ XK_Codeinput XK_SingleCandidate + \ XK_MultipleCandidate XK_PreviousCandidate + \ XK_Kanji XK_Muhenkan XK_Henkan_Mode + \ XK_Henkan XK_Romaji XK_Hiragana XK_Katakana + \ XK_Hiragana_Katakana XK_Zenkaku XK_Hankaku + \ XK_Zenkaku_Hankaku XK_Touroku XK_Massyo + \ XK_Kana_Lock XK_Kana_Shift XK_Eisu_Shift + \ XK_Eisu_toggle XK_Kanji_Bangou XK_Zen_Koho + \ XK_Mae_Koho XK_Home XK_Left XK_Up XK_Right + \ XK_Down XK_Prior XK_Page_Up XK_Next + \ XK_Page_Down XK_End XK_Begin XK_Select + \ XK_Print XK_Execute XK_Insert XK_Undo XK_Redo + \ XK_Menu XK_Find XK_Cancel XK_Help XK_Break + \ XK_Mode_switch XK_script_switch XK_Num_Lock + \ XK_KP_Space XK_KP_Tab XK_KP_Enter XK_KP_F1 + \ XK_KP_F2 XK_KP_F3 XK_KP_F4 XK_KP_Home + \ XK_KP_Left XK_KP_Up XK_KP_Right XK_KP_Down + \ XK_KP_Prior XK_KP_Page_Up XK_KP_Next + \ XK_KP_Page_Down XK_KP_End XK_KP_Begin + \ XK_KP_Insert XK_KP_Delete XK_KP_Equal + \ XK_KP_Multiply XK_KP_Add XK_KP_Separator + \ XK_KP_Subtract XK_KP_Decimal XK_KP_Divide + \ XK_KP_0 XK_KP_1 XK_KP_2 XK_KP_3 XK_KP_4 + \ XK_KP_5 XK_KP_6 XK_KP_7 XK_KP_8 XK_KP_9 XK_F1 + \ XK_F2 XK_F3 XK_F4 XK_F5 XK_F6 XK_F7 XK_F8 + \ XK_F9 XK_F10 XK_F11 XK_L1 XK_F12 XK_L2 XK_F13 + \ XK_L3 XK_F14 XK_L4 XK_F15 XK_L5 XK_F16 XK_L6 + \ XK_F17 XK_L7 XK_F18 XK_L8 XK_F19 XK_L9 XK_F20 + \ XK_L10 XK_F21 XK_R1 XK_F22 XK_R2 XK_F23 + \ XK_R3 XK_F24 XK_R4 XK_F25 XK_R5 XK_F26 + \ XK_R6 XK_F27 XK_R7 XK_F28 XK_R8 XK_F29 + \ XK_R9 XK_F30 XK_R10 XK_F31 XK_R11 XK_F32 + \ XK_R12 XK_F33 XK_R13 XK_F34 XK_R14 XK_F35 + \ XK_R15 XK_Shift_L XK_Shift_R XK_Control_L + \ XK_Control_R XK_Caps_Lock XK_Shift_Lock + \ XK_Meta_L XK_Meta_R XK_Alt_L XK_Alt_R + \ XK_Super_L XK_Super_R XK_Hyper_L XK_Hyper_R + \ XK_dead_hook XK_dead_horn XK_3270_Duplicate + \ XK_3270_FieldMark XK_3270_Right2 XK_3270_Left2 + \ XK_3270_BackTab XK_3270_EraseEOF + \ XK_3270_EraseInput XK_3270_Reset + \ XK_3270_Quit XK_3270_PA1 XK_3270_PA2 + \ XK_3270_PA3 XK_3270_Test XK_3270_Attn + \ XK_3270_CursorBlink XK_3270_AltCursor + \ XK_3270_KeyClick XK_3270_Jump + \ XK_3270_Ident XK_3270_Rule XK_3270_Copy + \ XK_3270_Play XK_3270_Setup XK_3270_Record + \ XK_3270_ChangeScreen XK_3270_DeleteWord + \ XK_3270_ExSelect XK_3270_CursorSelect + \ XK_3270_PrintScreen XK_3270_Enter XK_space + \ XK_exclam XK_quotedbl XK_numbersign XK_dollar + \ XK_percent XK_ampersand XK_apostrophe + \ XK_quoteright XK_parenleft XK_parenright + \ XK_asterisk XK_plus XK_comma XK_minus + \ XK_period XK_slash XK_0 XK_1 XK_2 XK_3 + \ XK_4 XK_5 XK_6 XK_7 XK_8 XK_9 XK_colon + \ XK_semicolon XK_less XK_equal XK_greater + \ XK_question XK_at XK_A XK_B XK_C XK_D XK_E + \ XK_F XK_G XK_H XK_I XK_J XK_K XK_L XK_M XK_N + \ XK_O XK_P XK_Q XK_R XK_S XK_T XK_U XK_V XK_W + \ XK_X XK_Y XK_Z XK_bracketleft XK_backslash + \ XK_bracketright XK_asciicircum XK_underscore + \ XK_grave XK_quoteleft XK_a XK_b XK_c XK_d + \ XK_e XK_f XK_g XK_h XK_i XK_j XK_k XK_l + \ XK_m XK_n XK_o XK_p XK_q XK_r XK_s XK_t XK_u + \ XK_v XK_w XK_x XK_y XK_z XK_braceleft XK_bar + \ XK_braceright XK_asciitilde XK_nobreakspace + \ XK_exclamdown XK_cent XK_sterling XK_currency + \ XK_yen XK_brokenbar XK_section XK_diaeresis + \ XK_copyright XK_ordfeminine XK_guillemotleft + \ XK_notsign XK_hyphen XK_registered XK_macron + \ XK_degree XK_plusminus XK_twosuperior + \ XK_threesuperior XK_acute XK_mu XK_paragraph + \ XK_periodcentered XK_cedilla XK_onesuperior + \ XK_masculine XK_guillemotright XK_onequarter + \ XK_onehalf XK_threequarters XK_questiondown + \ XK_Agrave XK_Aacute XK_Acircumflex XK_Atilde + \ XK_Adiaeresis XK_Aring XK_AE XK_Ccedilla + \ XK_Egrave XK_Eacute XK_Ecircumflex + \ XK_Ediaeresis XK_Igrave XK_Iacute + \ XK_Icircumflex XK_Idiaeresis XK_ETH XK_Eth + \ XK_Ntilde XK_Ograve XK_Oacute XK_Ocircumflex + \ XK_Otilde XK_Odiaeresis XK_multiply + \ XK_Ooblique XK_Ugrave XK_Uacute XK_Ucircumflex + \ XK_Udiaeresis XK_Yacute XK_THORN XK_Thorn + \ XK_ssharp XK_agrave XK_aacute XK_acircumflex + \ XK_atilde XK_adiaeresis XK_aring XK_ae + \ XK_ccedilla XK_egrave XK_eacute XK_ecircumflex + \ XK_ediaeresis XK_igrave XK_iacute + \ XK_icircumflex XK_idiaeresis XK_eth XK_ntilde + \ XK_ograve XK_oacute XK_ocircumflex XK_otilde + \ XK_odiaeresis XK_division XK_oslash XK_ugrave + \ XK_uacute XK_ucircumflex XK_udiaeresis + \ XK_yacute XK_thorn XK_ydiaeresis XK_Aogonek + \ XK_breve XK_Lstroke XK_Lcaron XK_Sacute + \ XK_Scaron XK_Scedilla XK_Tcaron XK_Zacute + \ XK_Zcaron XK_Zabovedot XK_aogonek XK_ogonek + \ XK_lstroke XK_lcaron XK_sacute XK_caron + \ XK_scaron XK_scedilla XK_tcaron XK_zacute + \ XK_doubleacute XK_zcaron XK_zabovedot + \ XK_Racute XK_Abreve XK_Lacute XK_Cacute + \ XK_Ccaron XK_Eogonek XK_Ecaron XK_Dcaron + \ XK_Dstroke XK_Nacute XK_Ncaron XK_Odoubleacute + \ XK_Rcaron XK_Uring XK_Udoubleacute + \ XK_Tcedilla XK_racute XK_abreve XK_lacute + \ XK_cacute XK_ccaron XK_eogonek XK_ecaron + \ XK_dcaron XK_dstroke XK_nacute XK_ncaron + \ XK_odoubleacute XK_udoubleacute XK_rcaron + \ XK_uring XK_tcedilla XK_abovedot XK_Hstroke + \ XK_Hcircumflex XK_Iabovedot XK_Gbreve + \ XK_Jcircumflex XK_hstroke XK_hcircumflex + \ XK_idotless XK_gbreve XK_jcircumflex + \ XK_Cabovedot XK_Ccircumflex XK_Gabovedot + \ XK_Gcircumflex XK_Ubreve XK_Scircumflex + \ XK_cabovedot XK_ccircumflex XK_gabovedot + \ XK_gcircumflex XK_ubreve XK_scircumflex XK_kra + \ XK_kappa XK_Rcedilla XK_Itilde XK_Lcedilla + \ XK_Emacron XK_Gcedilla XK_Tslash XK_rcedilla + \ XK_itilde XK_lcedilla XK_emacron XK_gcedilla + \ XK_tslash XK_ENG XK_eng XK_Amacron XK_Iogonek + \ XK_Eabovedot XK_Imacron XK_Ncedilla XK_Omacron + \ XK_Kcedilla XK_Uogonek XK_Utilde XK_Umacron + \ XK_amacron XK_iogonek XK_eabovedot XK_imacron + \ XK_ncedilla XK_omacron XK_kcedilla XK_uogonek + \ XK_utilde XK_umacron XK_Babovedot XK_babovedot + \ XK_Dabovedot XK_Wgrave XK_Wacute XK_dabovedot + \ XK_Ygrave XK_Fabovedot XK_fabovedot + \ XK_Mabovedot XK_mabovedot XK_Pabovedot + \ XK_wgrave XK_pabovedot XK_wacute XK_Sabovedot + \ XK_ygrave XK_Wdiaeresis XK_wdiaeresis + \ XK_sabovedot XK_Wcircumflex XK_Tabovedot + \ XK_Ycircumflex XK_wcircumflex + \ XK_tabovedot XK_ycircumflex XK_OE XK_oe + \ XK_Ydiaeresis XK_overline XK_kana_fullstop + \ XK_kana_openingbracket XK_kana_closingbracket + \ XK_kana_comma XK_kana_conjunctive + \ XK_kana_middledot XK_kana_WO XK_kana_a + \ XK_kana_i XK_kana_u XK_kana_e XK_kana_o + \ XK_kana_ya XK_kana_yu XK_kana_yo + \ XK_kana_tsu XK_kana_tu XK_prolongedsound + \ XK_kana_A XK_kana_I XK_kana_U XK_kana_E + \ XK_kana_O XK_kana_KA XK_kana_KI XK_kana_KU + \ XK_kana_KE XK_kana_KO XK_kana_SA XK_kana_SHI + \ XK_kana_SU XK_kana_SE XK_kana_SO XK_kana_TA + \ XK_kana_CHI XK_kana_TI XK_kana_TSU + \ XK_kana_TU XK_kana_TE XK_kana_TO XK_kana_NA + \ XK_kana_NI XK_kana_NU XK_kana_NE XK_kana_NO + \ XK_kana_HA XK_kana_HI XK_kana_FU XK_kana_HU + \ XK_kana_HE XK_kana_HO XK_kana_MA XK_kana_MI + \ XK_kana_MU XK_kana_ME XK_kana_MO XK_kana_YA + \ XK_kana_YU XK_kana_YO XK_kana_RA XK_kana_RI + \ XK_kana_RU XK_kana_RE XK_kana_RO XK_kana_WA + \ XK_kana_N XK_voicedsound XK_semivoicedsound + \ XK_kana_switch XK_Farsi_0 XK_Farsi_1 + \ XK_Farsi_2 XK_Farsi_3 XK_Farsi_4 XK_Farsi_5 + \ XK_Farsi_6 XK_Farsi_7 XK_Farsi_8 XK_Farsi_9 + \ XK_Arabic_percent XK_Arabic_superscript_alef + \ XK_Arabic_tteh XK_Arabic_peh XK_Arabic_tcheh + \ XK_Arabic_ddal XK_Arabic_rreh XK_Arabic_comma + \ XK_Arabic_fullstop XK_Arabic_0 XK_Arabic_1 + \ XK_Arabic_2 XK_Arabic_3 XK_Arabic_4 + \ XK_Arabic_5 XK_Arabic_6 XK_Arabic_7 + \ XK_Arabic_8 XK_Arabic_9 XK_Arabic_semicolon + \ XK_Arabic_question_mark XK_Arabic_hamza + \ XK_Arabic_maddaonalef XK_Arabic_hamzaonalef + \ XK_Arabic_hamzaonwaw XK_Arabic_hamzaunderalef + \ XK_Arabic_hamzaonyeh XK_Arabic_alef + \ XK_Arabic_beh XK_Arabic_tehmarbuta + \ XK_Arabic_teh XK_Arabic_theh XK_Arabic_jeem + \ XK_Arabic_hah XK_Arabic_khah XK_Arabic_dal + \ XK_Arabic_thal XK_Arabic_ra XK_Arabic_zain + \ XK_Arabic_seen XK_Arabic_sheen + \ XK_Arabic_sad XK_Arabic_dad XK_Arabic_tah + \ XK_Arabic_zah XK_Arabic_ain XK_Arabic_ghain + \ XK_Arabic_tatweel XK_Arabic_feh XK_Arabic_qaf + \ XK_Arabic_kaf XK_Arabic_lam XK_Arabic_meem + \ XK_Arabic_noon XK_Arabic_ha XK_Arabic_heh + \ XK_Arabic_waw XK_Arabic_alefmaksura + \ XK_Arabic_yeh XK_Arabic_fathatan + \ XK_Arabic_dammatan XK_Arabic_kasratan + \ XK_Arabic_fatha XK_Arabic_damma + \ XK_Arabic_kasra XK_Arabic_shadda + \ XK_Arabic_sukun XK_Arabic_madda_above + \ XK_Arabic_hamza_above XK_Arabic_hamza_below + \ XK_Arabic_jeh XK_Arabic_veh XK_Arabic_keheh + \ XK_Arabic_gaf XK_Arabic_noon_ghunna + \ XK_Arabic_heh_doachashmee XK_Farsi_yeh + \ XK_Arabic_yeh_baree XK_Arabic_heh_goal + \ XK_Arabic_switch XK_Cyrillic_GHE_bar + \ XK_Cyrillic_ghe_bar XK_Cyrillic_ZHE_descender + \ XK_Cyrillic_zhe_descender + \ XK_Cyrillic_KA_descender + \ XK_Cyrillic_ka_descender + \ XK_Cyrillic_KA_vertstroke + \ XK_Cyrillic_ka_vertstroke + \ XK_Cyrillic_EN_descender + \ XK_Cyrillic_en_descender + \ XK_Cyrillic_U_straight XK_Cyrillic_u_straight + \ XK_Cyrillic_U_straight_bar + \ XK_Cyrillic_u_straight_bar + \ XK_Cyrillic_HA_descender + \ XK_Cyrillic_ha_descender + \ XK_Cyrillic_CHE_descender + \ XK_Cyrillic_che_descender + \ XK_Cyrillic_CHE_vertstroke + \ XK_Cyrillic_che_vertstroke XK_Cyrillic_SHHA + \ XK_Cyrillic_shha XK_Cyrillic_SCHWA + \ XK_Cyrillic_schwa XK_Cyrillic_I_macron + \ XK_Cyrillic_i_macron XK_Cyrillic_O_bar + \ XK_Cyrillic_o_bar XK_Cyrillic_U_macron + \ XK_Cyrillic_u_macron XK_Serbian_dje + \ XK_Macedonia_gje XK_Cyrillic_io + \ XK_Ukrainian_ie XK_Ukranian_je + \ XK_Macedonia_dse XK_Ukrainian_i XK_Ukranian_i + \ XK_Ukrainian_yi XK_Ukranian_yi XK_Cyrillic_je + \ XK_Serbian_je XK_Cyrillic_lje XK_Serbian_lje + \ XK_Cyrillic_nje XK_Serbian_nje XK_Serbian_tshe + \ XK_Macedonia_kje XK_Ukrainian_ghe_with_upturn + \ XK_Byelorussian_shortu XK_Cyrillic_dzhe + \ XK_Serbian_dze XK_numerosign + \ XK_Serbian_DJE XK_Macedonia_GJE + \ XK_Cyrillic_IO XK_Ukrainian_IE XK_Ukranian_JE + \ XK_Macedonia_DSE XK_Ukrainian_I XK_Ukranian_I + \ XK_Ukrainian_YI XK_Ukranian_YI XK_Cyrillic_JE + \ XK_Serbian_JE XK_Cyrillic_LJE XK_Serbian_LJE + \ XK_Cyrillic_NJE XK_Serbian_NJE XK_Serbian_TSHE + \ XK_Macedonia_KJE XK_Ukrainian_GHE_WITH_UPTURN + \ XK_Byelorussian_SHORTU XK_Cyrillic_DZHE + \ XK_Serbian_DZE XK_Cyrillic_yu + \ XK_Cyrillic_a XK_Cyrillic_be XK_Cyrillic_tse + \ XK_Cyrillic_de XK_Cyrillic_ie XK_Cyrillic_ef + \ XK_Cyrillic_ghe XK_Cyrillic_ha XK_Cyrillic_i + \ XK_Cyrillic_shorti XK_Cyrillic_ka + \ XK_Cyrillic_el XK_Cyrillic_em XK_Cyrillic_en + \ XK_Cyrillic_o XK_Cyrillic_pe XK_Cyrillic_ya + \ XK_Cyrillic_er XK_Cyrillic_es XK_Cyrillic_te + \ XK_Cyrillic_u XK_Cyrillic_zhe XK_Cyrillic_ve + \ XK_Cyrillic_softsign XK_Cyrillic_yeru + \ XK_Cyrillic_ze XK_Cyrillic_sha XK_Cyrillic_e + \ XK_Cyrillic_shcha XK_Cyrillic_che + \ XK_Cyrillic_hardsign XK_Cyrillic_YU + \ XK_Cyrillic_A XK_Cyrillic_BE XK_Cyrillic_TSE + \ XK_Cyrillic_DE XK_Cyrillic_IE XK_Cyrillic_EF + \ XK_Cyrillic_GHE XK_Cyrillic_HA XK_Cyrillic_I + \ XK_Cyrillic_SHORTI XK_Cyrillic_KA + \ XK_Cyrillic_EL XK_Cyrillic_EM XK_Cyrillic_EN + \ XK_Cyrillic_O XK_Cyrillic_PE XK_Cyrillic_YA + \ XK_Cyrillic_ER XK_Cyrillic_ES XK_Cyrillic_TE + \ XK_Cyrillic_U XK_Cyrillic_ZHE XK_Cyrillic_VE + \ XK_Cyrillic_SOFTSIGN XK_Cyrillic_YERU + \ XK_Cyrillic_ZE XK_Cyrillic_SHA XK_Cyrillic_E + \ XK_Cyrillic_SHCHA XK_Cyrillic_CHE + \ XK_Cyrillic_HARDSIGN XK_Greek_ALPHAaccent + \ XK_Greek_EPSILONaccent XK_Greek_ETAaccent + \ XK_Greek_IOTAaccent XK_Greek_IOTAdieresis + \ XK_Greek_OMICRONaccent XK_Greek_UPSILONaccent + \ XK_Greek_UPSILONdieresis + \ XK_Greek_OMEGAaccent XK_Greek_accentdieresis + \ XK_Greek_horizbar XK_Greek_alphaaccent + \ XK_Greek_epsilonaccent XK_Greek_etaaccent + \ XK_Greek_iotaaccent XK_Greek_iotadieresis + \ XK_Greek_iotaaccentdieresis + \ XK_Greek_omicronaccent XK_Greek_upsilonaccent + \ XK_Greek_upsilondieresis + \ XK_Greek_upsilonaccentdieresis + \ XK_Greek_omegaaccent XK_Greek_ALPHA + \ XK_Greek_BETA XK_Greek_GAMMA XK_Greek_DELTA + \ XK_Greek_EPSILON XK_Greek_ZETA XK_Greek_ETA + \ XK_Greek_THETA XK_Greek_IOTA XK_Greek_KAPPA + \ XK_Greek_LAMDA XK_Greek_LAMBDA XK_Greek_MU + \ XK_Greek_NU XK_Greek_XI XK_Greek_OMICRON + \ XK_Greek_PI XK_Greek_RHO XK_Greek_SIGMA + \ XK_Greek_TAU XK_Greek_UPSILON XK_Greek_PHI + \ XK_Greek_CHI XK_Greek_PSI XK_Greek_OMEGA + \ XK_Greek_alpha XK_Greek_beta XK_Greek_gamma + \ XK_Greek_delta XK_Greek_epsilon XK_Greek_zeta + \ XK_Greek_eta XK_Greek_theta XK_Greek_iota + \ XK_Greek_kappa XK_Greek_lamda XK_Greek_lambda + \ XK_Greek_mu XK_Greek_nu XK_Greek_xi + \ XK_Greek_omicron XK_Greek_pi XK_Greek_rho + \ XK_Greek_sigma XK_Greek_finalsmallsigma + \ XK_Greek_tau XK_Greek_upsilon XK_Greek_phi + \ XK_Greek_chi XK_Greek_psi XK_Greek_omega + \ XK_Greek_switch XK_leftradical + \ XK_topleftradical XK_horizconnector + \ XK_topintegral XK_botintegral + \ XK_vertconnector XK_topleftsqbracket + \ XK_botleftsqbracket XK_toprightsqbracket + \ XK_botrightsqbracket XK_topleftparens + \ XK_botleftparens XK_toprightparens + \ XK_botrightparens XK_leftmiddlecurlybrace + \ XK_rightmiddlecurlybrace + \ XK_topleftsummation XK_botleftsummation + \ XK_topvertsummationconnector + \ XK_botvertsummationconnector + \ XK_toprightsummation XK_botrightsummation + \ XK_rightmiddlesummation XK_lessthanequal + \ XK_notequal XK_greaterthanequal XK_integral + \ XK_therefore XK_variation XK_infinity + \ XK_nabla XK_approximate XK_similarequal + \ XK_ifonlyif XK_implies XK_identical XK_radical + \ XK_includedin XK_includes XK_intersection + \ XK_union XK_logicaland XK_logicalor + \ XK_partialderivative XK_function XK_leftarrow + \ XK_uparrow XK_rightarrow XK_downarrow XK_blank + \ XK_soliddiamond XK_checkerboard XK_ht XK_ff + \ XK_cr XK_lf XK_nl XK_vt XK_lowrightcorner + \ XK_uprightcorner XK_upleftcorner + \ XK_lowleftcorner XK_crossinglines + \ XK_horizlinescan1 XK_horizlinescan3 + \ XK_horizlinescan5 XK_horizlinescan7 + \ XK_horizlinescan9 XK_leftt XK_rightt XK_bott + \ XK_topt XK_vertbar XK_emspace XK_enspace + \ XK_em3space XK_em4space XK_digitspace + \ XK_punctspace XK_thinspace XK_hairspace + \ XK_emdash XK_endash XK_signifblank XK_ellipsis + \ XK_doubbaselinedot XK_onethird XK_twothirds + \ XK_onefifth XK_twofifths XK_threefifths + \ XK_fourfifths XK_onesixth XK_fivesixths + \ XK_careof XK_figdash XK_leftanglebracket + \ XK_decimalpoint XK_rightanglebracket + \ XK_marker XK_oneeighth XK_threeeighths + \ XK_fiveeighths XK_seveneighths XK_trademark + \ XK_signaturemark XK_trademarkincircle + \ XK_leftopentriangle XK_rightopentriangle + \ XK_emopencircle XK_emopenrectangle + \ XK_leftsinglequotemark XK_rightsinglequotemark + \ XK_leftdoublequotemark XK_rightdoublequotemark + \ XK_prescription XK_minutes XK_seconds + \ XK_latincross XK_hexagram XK_filledrectbullet + \ XK_filledlefttribullet XK_filledrighttribullet + \ XK_emfilledcircle XK_emfilledrect + \ XK_enopencircbullet XK_enopensquarebullet + \ XK_openrectbullet XK_opentribulletup + \ XK_opentribulletdown XK_openstar + \ XK_enfilledcircbullet XK_enfilledsqbullet + \ XK_filledtribulletup XK_filledtribulletdown + \ XK_leftpointer XK_rightpointer XK_club + \ XK_diamond XK_heart XK_maltesecross + \ XK_dagger XK_doubledagger XK_checkmark + \ XK_ballotcross XK_musicalsharp XK_musicalflat + \ XK_malesymbol XK_femalesymbol XK_telephone + \ XK_telephonerecorder XK_phonographcopyright + \ XK_caret XK_singlelowquotemark + \ XK_doublelowquotemark XK_cursor + \ XK_leftcaret XK_rightcaret XK_downcaret + \ XK_upcaret XK_overbar XK_downtack XK_upshoe + \ XK_downstile XK_underbar XK_jot XK_quad + \ XK_uptack XK_circle XK_upstile XK_downshoe + \ XK_rightshoe XK_leftshoe XK_lefttack + \ XK_righttack XK_hebrew_doublelowline + \ XK_hebrew_aleph XK_hebrew_bet XK_hebrew_beth + \ XK_hebrew_gimel XK_hebrew_gimmel + \ XK_hebrew_dalet XK_hebrew_daleth + \ XK_hebrew_he XK_hebrew_waw XK_hebrew_zain + \ XK_hebrew_zayin XK_hebrew_chet XK_hebrew_het + \ XK_hebrew_tet XK_hebrew_teth XK_hebrew_yod + \ XK_hebrew_finalkaph XK_hebrew_kaph + \ XK_hebrew_lamed XK_hebrew_finalmem + \ XK_hebrew_mem XK_hebrew_finalnun XK_hebrew_nun + \ XK_hebrew_samech XK_hebrew_samekh + \ XK_hebrew_ayin XK_hebrew_finalpe XK_hebrew_pe + \ XK_hebrew_finalzade XK_hebrew_finalzadi + \ XK_hebrew_zade XK_hebrew_zadi XK_hebrew_qoph + \ XK_hebrew_kuf XK_hebrew_resh XK_hebrew_shin + \ XK_hebrew_taw XK_hebrew_taf XK_Hebrew_switch + \ XK_Thai_kokai XK_Thai_khokhai XK_Thai_khokhuat + \ XK_Thai_khokhwai XK_Thai_khokhon + \ XK_Thai_khorakhang XK_Thai_ngongu + \ XK_Thai_chochan XK_Thai_choching + \ XK_Thai_chochang XK_Thai_soso XK_Thai_chochoe + \ XK_Thai_yoying XK_Thai_dochada XK_Thai_topatak + \ XK_Thai_thothan XK_Thai_thonangmontho + \ XK_Thai_thophuthao XK_Thai_nonen + \ XK_Thai_dodek XK_Thai_totao XK_Thai_thothung + \ XK_Thai_thothahan XK_Thai_thothong + \ XK_Thai_nonu XK_Thai_bobaimai XK_Thai_popla + \ XK_Thai_phophung XK_Thai_fofa XK_Thai_phophan + \ XK_Thai_fofan XK_Thai_phosamphao XK_Thai_moma + \ XK_Thai_yoyak XK_Thai_rorua XK_Thai_ru + \ XK_Thai_loling XK_Thai_lu XK_Thai_wowaen + \ XK_Thai_sosala XK_Thai_sorusi XK_Thai_sosua + \ XK_Thai_hohip XK_Thai_lochula XK_Thai_oang + \ XK_Thai_honokhuk XK_Thai_paiyannoi + \ XK_Thai_saraa XK_Thai_maihanakat + \ XK_Thai_saraaa XK_Thai_saraam XK_Thai_sarai + \ XK_Thai_saraii XK_Thai_saraue XK_Thai_sarauee + \ XK_Thai_sarau XK_Thai_sarauu XK_Thai_phinthu + \ XK_Thai_maihanakat_maitho XK_Thai_baht + \ XK_Thai_sarae XK_Thai_saraae XK_Thai_sarao + \ XK_Thai_saraaimaimuan XK_Thai_saraaimaimalai + \ XK_Thai_lakkhangyao XK_Thai_maiyamok + \ XK_Thai_maitaikhu XK_Thai_maiek XK_Thai_maitho + \ XK_Thai_maitri XK_Thai_maichattawa + \ XK_Thai_thanthakhat XK_Thai_nikhahit + \ XK_Thai_leksun XK_Thai_leknung XK_Thai_leksong + \ XK_Thai_leksam XK_Thai_leksi XK_Thai_lekha + \ XK_Thai_lekhok XK_Thai_lekchet XK_Thai_lekpaet + \ XK_Thai_lekkao XK_Hangul XK_Hangul_Start + \ XK_Hangul_End XK_Hangul_Hanja XK_Hangul_Jamo + \ XK_Hangul_Romaja XK_Hangul_Codeinput + \ XK_Hangul_Jeonja XK_Hangul_Banja + \ XK_Hangul_PreHanja XK_Hangul_PostHanja + \ XK_Hangul_SingleCandidate + \ XK_Hangul_MultipleCandidate + \ XK_Hangul_PreviousCandidate XK_Hangul_Special + \ XK_Hangul_switch XK_Hangul_Kiyeog + \ XK_Hangul_SsangKiyeog XK_Hangul_KiyeogSios + \ XK_Hangul_Nieun XK_Hangul_NieunJieuj + \ XK_Hangul_NieunHieuh XK_Hangul_Dikeud + \ XK_Hangul_SsangDikeud XK_Hangul_Rieul + \ XK_Hangul_RieulKiyeog XK_Hangul_RieulMieum + \ XK_Hangul_RieulPieub XK_Hangul_RieulSios + \ XK_Hangul_RieulTieut XK_Hangul_RieulPhieuf + \ XK_Hangul_RieulHieuh XK_Hangul_Mieum + \ XK_Hangul_Pieub XK_Hangul_SsangPieub + \ XK_Hangul_PieubSios XK_Hangul_Sios + \ XK_Hangul_SsangSios XK_Hangul_Ieung + \ XK_Hangul_Jieuj XK_Hangul_SsangJieuj + \ XK_Hangul_Cieuc XK_Hangul_Khieuq + \ XK_Hangul_Tieut XK_Hangul_Phieuf + \ XK_Hangul_Hieuh XK_Hangul_A XK_Hangul_AE + \ XK_Hangul_YA XK_Hangul_YAE XK_Hangul_EO + \ XK_Hangul_E XK_Hangul_YEO XK_Hangul_YE + \ XK_Hangul_O XK_Hangul_WA XK_Hangul_WAE + \ XK_Hangul_OE XK_Hangul_YO XK_Hangul_U + \ XK_Hangul_WEO XK_Hangul_WE XK_Hangul_WI + \ XK_Hangul_YU XK_Hangul_EU XK_Hangul_YI + \ XK_Hangul_I XK_Hangul_J_Kiyeog + \ XK_Hangul_J_SsangKiyeog XK_Hangul_J_KiyeogSios + \ XK_Hangul_J_Nieun XK_Hangul_J_NieunJieuj + \ XK_Hangul_J_NieunHieuh XK_Hangul_J_Dikeud + \ XK_Hangul_J_Rieul XK_Hangul_J_RieulKiyeog + \ XK_Hangul_J_RieulMieum XK_Hangul_J_RieulPieub + \ XK_Hangul_J_RieulSios XK_Hangul_J_RieulTieut + \ XK_Hangul_J_RieulPhieuf XK_Hangul_J_RieulHieuh + \ XK_Hangul_J_Mieum XK_Hangul_J_Pieub + \ XK_Hangul_J_PieubSios XK_Hangul_J_Sios + \ XK_Hangul_J_SsangSios XK_Hangul_J_Ieung + \ XK_Hangul_J_Jieuj XK_Hangul_J_Cieuc + \ XK_Hangul_J_Khieuq XK_Hangul_J_Tieut + \ XK_Hangul_J_Phieuf XK_Hangul_J_Hieuh + \ XK_Hangul_RieulYeorinHieuh + \ XK_Hangul_SunkyeongeumMieum + \ XK_Hangul_SunkyeongeumPieub XK_Hangul_PanSios + \ XK_Hangul_KkogjiDalrinIeung + \ XK_Hangul_SunkyeongeumPhieuf + \ XK_Hangul_YeorinHieuh XK_Hangul_AraeA + \ XK_Hangul_AraeAE XK_Hangul_J_PanSios + \ XK_Hangul_J_KkogjiDalrinIeung + \ XK_Hangul_J_YeorinHieuh XK_Korean_Won + \ XK_Armenian_eternity XK_Armenian_ligature_ew + \ XK_Armenian_full_stop XK_Armenian_verjaket + \ XK_Armenian_parenright XK_Armenian_parenleft + \ XK_Armenian_guillemotright + \ XK_Armenian_guillemotleft XK_Armenian_em_dash + \ XK_Armenian_dot XK_Armenian_mijaket + \ XK_Armenian_separation_mark XK_Armenian_but + \ XK_Armenian_comma XK_Armenian_en_dash + \ XK_Armenian_hyphen XK_Armenian_yentamna + \ XK_Armenian_ellipsis XK_Armenian_exclam + \ XK_Armenian_amanak XK_Armenian_accent + \ XK_Armenian_shesht XK_Armenian_question + \ XK_Armenian_paruyk XK_Armenian_AYB + \ XK_Armenian_ayb XK_Armenian_BEN + \ XK_Armenian_ben XK_Armenian_GIM + \ XK_Armenian_gim XK_Armenian_DA XK_Armenian_da + \ XK_Armenian_YECH XK_Armenian_yech + \ XK_Armenian_ZA XK_Armenian_za XK_Armenian_E + \ XK_Armenian_e XK_Armenian_AT XK_Armenian_at + \ XK_Armenian_TO XK_Armenian_to + \ XK_Armenian_ZHE XK_Armenian_zhe + \ XK_Armenian_INI XK_Armenian_ini + \ XK_Armenian_LYUN XK_Armenian_lyun + \ XK_Armenian_KHE XK_Armenian_khe + \ XK_Armenian_TSA XK_Armenian_tsa + \ XK_Armenian_KEN XK_Armenian_ken XK_Armenian_HO + \ XK_Armenian_ho XK_Armenian_DZA XK_Armenian_dza + \ XK_Armenian_GHAT XK_Armenian_ghat + \ XK_Armenian_TCHE XK_Armenian_tche + \ XK_Armenian_MEN XK_Armenian_men XK_Armenian_HI + \ XK_Armenian_hi XK_Armenian_NU XK_Armenian_nu + \ XK_Armenian_SHA XK_Armenian_sha XK_Armenian_VO + \ XK_Armenian_vo XK_Armenian_CHA XK_Armenian_cha + \ XK_Armenian_PE XK_Armenian_pe XK_Armenian_JE + \ XK_Armenian_je XK_Armenian_RA XK_Armenian_ra + \ XK_Armenian_SE XK_Armenian_se XK_Armenian_VEV + \ XK_Armenian_vev XK_Armenian_TYUN + \ XK_Armenian_tyun XK_Armenian_RE + \ XK_Armenian_re XK_Armenian_TSO + \ XK_Armenian_tso XK_Armenian_VYUN + \ XK_Armenian_vyun XK_Armenian_PYUR + \ XK_Armenian_pyur XK_Armenian_KE XK_Armenian_ke + \ XK_Armenian_O XK_Armenian_o XK_Armenian_FE + \ XK_Armenian_fe XK_Armenian_apostrophe + \ XK_Armenian_section_sign XK_Georgian_an + \ XK_Georgian_ban XK_Georgian_gan + \ XK_Georgian_don XK_Georgian_en XK_Georgian_vin + \ XK_Georgian_zen XK_Georgian_tan + \ XK_Georgian_in XK_Georgian_kan XK_Georgian_las + \ XK_Georgian_man XK_Georgian_nar XK_Georgian_on + \ XK_Georgian_par XK_Georgian_zhar + \ XK_Georgian_rae XK_Georgian_san + \ XK_Georgian_tar XK_Georgian_un + \ XK_Georgian_phar XK_Georgian_khar + \ XK_Georgian_ghan XK_Georgian_qar + \ XK_Georgian_shin XK_Georgian_chin + \ XK_Georgian_can XK_Georgian_jil + \ XK_Georgian_cil XK_Georgian_char + \ XK_Georgian_xan XK_Georgian_jhan + \ XK_Georgian_hae XK_Georgian_he XK_Georgian_hie + \ XK_Georgian_we XK_Georgian_har XK_Georgian_hoe + \ XK_Georgian_fi XK_Ccedillaabovedot + \ XK_Xabovedot XK_Qabovedot XK_IE XK_UO + \ XK_Zstroke XK_ccedillaabovedot XK_xabovedot + \ XK_qabovedot XK_ie XK_uo XK_zstroke XK_SCHWA + \ XK_schwa XK_Lbelowdot XK_Lstrokebelowdot + \ XK_lbelowdot XK_lstrokebelowdot XK_Gtilde + \ XK_gtilde XK_Abelowdot XK_abelowdot + \ XK_Ahook XK_ahook XK_Acircumflexacute + \ XK_acircumflexacute XK_Acircumflexgrave + \ XK_acircumflexgrave XK_Acircumflexhook + \ XK_acircumflexhook XK_Acircumflextilde + \ XK_acircumflextilde XK_Acircumflexbelowdot + \ XK_acircumflexbelowdot XK_Abreveacute + \ XK_abreveacute XK_Abrevegrave XK_abrevegrave + \ XK_Abrevehook XK_abrevehook XK_Abrevetilde + \ XK_abrevetilde XK_Abrevebelowdot + \ XK_abrevebelowdot XK_Ebelowdot XK_ebelowdot + \ XK_Ehook XK_ehook XK_Etilde XK_etilde + \ XK_Ecircumflexacute XK_ecircumflexacute + \ XK_Ecircumflexgrave XK_ecircumflexgrave + \ XK_Ecircumflexhook XK_ecircumflexhook + \ XK_Ecircumflextilde XK_ecircumflextilde + \ XK_Ecircumflexbelowdot XK_ecircumflexbelowdot + \ XK_Ihook XK_ihook XK_Ibelowdot XK_ibelowdot + \ XK_Obelowdot XK_obelowdot XK_Ohook XK_ohook + \ XK_Ocircumflexacute XK_ocircumflexacute + \ XK_Ocircumflexgrave XK_ocircumflexgrave + \ XK_Ocircumflexhook XK_ocircumflexhook + \ XK_Ocircumflextilde XK_ocircumflextilde + \ XK_Ocircumflexbelowdot XK_ocircumflexbelowdot + \ XK_Ohornacute XK_ohornacute XK_Ohorngrave + \ XK_ohorngrave XK_Ohornhook XK_ohornhook + \ XK_Ohorntilde XK_ohorntilde XK_Ohornbelowdot + \ XK_ohornbelowdot XK_Ubelowdot XK_ubelowdot + \ XK_Uhook XK_uhook XK_Uhornacute XK_uhornacute + \ XK_Uhorngrave XK_uhorngrave XK_Uhornhook + \ XK_uhornhook XK_Uhorntilde XK_uhorntilde + \ XK_Uhornbelowdot XK_uhornbelowdot XK_Ybelowdot + \ XK_ybelowdot XK_Yhook XK_yhook XK_Ytilde + \ XK_ytilde XK_Ohorn XK_ohorn XK_Uhorn XK_uhorn + \ XK_combining_tilde XK_combining_grave + \ XK_combining_acute XK_combining_hook + \ XK_combining_belowdot XK_EcuSign XK_ColonSign + \ XK_CruzeiroSign XK_FFrancSign XK_LiraSign + \ XK_MillSign XK_NairaSign XK_PesetaSign + \ XK_RupeeSign XK_WonSign XK_NewSheqelSign + \ XK_DongSign XK_EuroSign + +" #include +syn keyword xmodmapKeySym SunXK_Sys_Req SunXK_Print_Screen SunXK_Compose + \ SunXK_AltGraph SunXK_PageUp SunXK_PageDown + \ SunXK_Undo SunXK_Again SunXK_Find SunXK_Stop + \ SunXK_Props SunXK_Front SunXK_Copy SunXK_Open + \ SunXK_Paste SunXK_Cut SunXK_PowerSwitch + \ SunXK_AudioLowerVolume SunXK_AudioMute + \ SunXK_AudioRaiseVolume SunXK_VideoDegauss + \ SunXK_VideoLowerBrightness + \ SunXK_VideoRaiseBrightness + \ SunXK_PowerSwitchShift + +" #include +syn keyword xmodmapKeySym XF86XK_ModeLock XF86XK_Standby + \ XF86XK_AudioLowerVolume XF86XK_AudioMute + \ XF86XK_AudioRaiseVolume XF86XK_AudioPlay + \ XF86XK_AudioStop XF86XK_AudioPrev + \ XF86XK_AudioNext XF86XK_HomePage + \ XF86XK_Mail XF86XK_Start XF86XK_Search + \ XF86XK_AudioRecord XF86XK_Calculator + \ XF86XK_Memo XF86XK_ToDoList XF86XK_Calendar + \ XF86XK_PowerDown XF86XK_ContrastAdjust + \ XF86XK_RockerUp XF86XK_RockerDown + \ XF86XK_RockerEnter XF86XK_Back XF86XK_Forward + \ XF86XK_Stop XF86XK_Refresh XF86XK_PowerOff + \ XF86XK_WakeUp XF86XK_Eject XF86XK_ScreenSaver + \ XF86XK_WWW XF86XK_Sleep XF86XK_Favorites + \ XF86XK_AudioPause XF86XK_AudioMedia + \ XF86XK_MyComputer XF86XK_VendorHome + \ XF86XK_LightBulb XF86XK_Shop XF86XK_History + \ XF86XK_OpenURL XF86XK_AddFavorite + \ XF86XK_HotLinks XF86XK_BrightnessAdjust + \ XF86XK_Finance XF86XK_Community + \ XF86XK_AudioRewind XF86XK_XF86BackForward + \ XF86XK_Launch0 XF86XK_Launch1 XF86XK_Launch2 + \ XF86XK_Launch3 XF86XK_Launch4 XF86XK_Launch5 + \ XF86XK_Launch6 XF86XK_Launch7 XF86XK_Launch8 + \ XF86XK_Launch9 XF86XK_LaunchA XF86XK_LaunchB + \ XF86XK_LaunchC XF86XK_LaunchD XF86XK_LaunchE + \ XF86XK_LaunchF XF86XK_ApplicationLeft + \ XF86XK_ApplicationRight XF86XK_Book + \ XF86XK_CD XF86XK_Calculater XF86XK_Clear + \ XF86XK_Close XF86XK_Copy XF86XK_Cut + \ XF86XK_Display XF86XK_DOS XF86XK_Documents + \ XF86XK_Excel XF86XK_Explorer XF86XK_Game + \ XF86XK_Go XF86XK_iTouch XF86XK_LogOff + \ XF86XK_Market XF86XK_Meeting XF86XK_MenuKB + \ XF86XK_MenuPB XF86XK_MySites XF86XK_New + \ XF86XK_News XF86XK_OfficeHome XF86XK_Open + \ XF86XK_Option XF86XK_Paste XF86XK_Phone + \ XF86XK_Q XF86XK_Reply XF86XK_Reload + \ XF86XK_RotateWindows XF86XK_RotationPB + \ XF86XK_RotationKB XF86XK_Save XF86XK_ScrollUp + \ XF86XK_ScrollDown XF86XK_ScrollClick + \ XF86XK_Send XF86XK_Spell XF86XK_SplitScreen + \ XF86XK_Support XF86XK_TaskPane XF86XK_Terminal + \ XF86XK_Tools XF86XK_Travel XF86XK_UserPB + \ XF86XK_User1KB XF86XK_User2KB XF86XK_Video + \ XF86XK_WheelButton XF86XK_Word XF86XK_Xfer + \ XF86XK_ZoomIn XF86XK_ZoomOut XF86XK_Away + \ XF86XK_Messenger XF86XK_WebCam + \ XF86XK_MailForward XF86XK_Pictures + \ XF86XK_Music XF86XK_Switch_VT_1 + \ XF86XK_Switch_VT_2 XF86XK_Switch_VT_3 + \ XF86XK_Switch_VT_4 XF86XK_Switch_VT_5 + \ XF86XK_Switch_VT_6 XF86XK_Switch_VT_7 + \ XF86XK_Switch_VT_8 XF86XK_Switch_VT_9 + \ XF86XK_Switch_VT_10 XF86XK_Switch_VT_11 + \ XF86XK_Switch_VT_12 XF86XK_Ungrab + \ XF86XK_ClearGrab XF86XK_Next_VMode + \ XF86XK_Prev_VMode + +syn keyword xmodmapKeyword keycode keysym clear add remove pointer + +hi def link xmodmapComment Comment +hi def link xmodmapTodo Todo +hi def link xmodmapInt Number +hi def link xmodmapHex Number +hi def link xmodmapOctal Number +hi def link xmodmapOctalError Error +hi def link xmodmapKeySym Constant +hi def link xmodmapKeyword Keyword + +let b:current_syntax = "xmodmap" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif diff --git a/syntax/xpm.vim b/syntax/xpm.vim new file mode 100644 index 0000000..7456967 --- /dev/null +++ b/syntax/xpm.vim @@ -0,0 +1,142 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: X Pixmap +" Maintainer: Ronald Schild +" Last Change: 2017 Feb 01 +" Version: 5.4n.1 +" Jemma Nelson added termguicolors support + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn keyword xpmType char +syn keyword xpmStorageClass static +syn keyword xpmTodo TODO FIXME XXX contained +syn region xpmComment start="/\*" end="\*/" contains=xpmTodo +syn region xpmPixelString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@xpmColors + +if has("gui_running") || has("termguicolors") && &termguicolors + +let color = "" +let chars = "" +let colors = 0 +let cpp = 0 +let n = 0 +let i = 1 + +while i <= line("$") " scanning all lines + + let s = matchstr(getline(i), '".\{-1,}"') + if s != "" " does line contain a string? + + if n == 0 " first string is the Values string + + " get the 3rd value: colors = number of colors + let colors = substitute(s, '"\s*\d\+\s\+\d\+\s\+\(\d\+\).*"', '\1', '') + " get the 4th value: cpp = number of character per pixel + let cpp = substitute(s, '"\s*\d\+\s\+\d\+\s\+\d\+\s\+\(\d\+\).*"', '\1', '') + if cpp =~ '[^0-9]' + break " if cpp is not made of digits there must be something wrong + endif + + " Highlight the Values string as normal string (no pixel string). + " Only when there is no slash, it would terminate the pattern. + if s !~ '/' + exe 'syn match xpmValues /' . s . '/' + endif + hi link xpmValues String + + let n = 1 " n = color index + + elseif n <= colors " string is a color specification + + " get chars = length string representing the pixels + " (first incl. the following whitespace) + let chars = substitute(s, '"\(.\{'.cpp.'}\s\).*"', '\1', '') + + " now get color, first try 'c' key if any (color visual) + let color = substitute(s, '".*\sc\s\+\(.\{-}\)\s*\(\(g4\=\|[ms]\)\s.*\)*\s*"', '\1', '') + if color == s + " no 'c' key, try 'g' key (grayscale with more than 4 levels) + let color = substitute(s, '".*\sg\s\+\(.\{-}\)\s*\(\(g4\|[ms]\)\s.*\)*\s*"', '\1', '') + if color == s + " next try: 'g4' key (4-level grayscale) + let color = substitute(s, '".*\sg4\s\+\(.\{-}\)\s*\([ms]\s.*\)*\s*"', '\1', '') + if color == s + " finally try 'm' key (mono visual) + let color = substitute(s, '".*\sm\s\+\(.\{-}\)\s*\(s\s.*\)*\s*"', '\1', '') + if color == s + let color = "" + endif + endif + endif + endif + + " Vim cannot handle RGB codes with more than 6 hex digits + if color =~ '#\x\{10,}$' + let color = substitute(color, '\(\x\x\)\x\x', '\1', 'g') + elseif color =~ '#\x\{7,}$' + let color = substitute(color, '\(\x\x\)\x', '\1', 'g') + " nor with 3 digits + elseif color =~ '#\x\{3}$' + let color = substitute(color, '\(\x\)\(\x\)\(\x\)', '0\10\20\3', '') + endif + + " escape meta characters in patterns + let s = escape(s, '/\*^$.~[]') + let chars = escape(chars, '/\*^$.~[]') + + " now create syntax items + " highlight the color string as normal string (no pixel string) + exe 'syn match xpmCol'.n.'Def /'.s.'/ contains=xpmCol'.n.'inDef' + exe 'hi link xpmCol'.n.'Def String' + + " but highlight the first whitespace after chars in its color + exe 'syn match xpmCol'.n.'inDef /"'.chars.'/hs=s+'.(cpp+1).' contained' + exe 'hi link xpmCol'.n.'inDef xpmColor'.n + + " remove the following whitespace from chars + let chars = substitute(chars, '.$', '', '') + + " and create the syntax item contained in the pixel strings + exe 'syn match xpmColor'.n.' /'.chars.'/ contained' + exe 'syn cluster xpmColors add=xpmColor'.n + + " if no color or color = "None" show background + if color == "" || substitute(color, '.*', '\L&', '') == 'none' + exe 'hi xpmColor'.n.' guifg=bg' + exe 'hi xpmColor'.n.' guibg=NONE' + elseif color !~ "'" + exe 'hi xpmColor'.n." guifg='".color."'" + exe 'hi xpmColor'.n." guibg='".color."'" + endif + let n = n + 1 + else + break " no more color string + endif + endif + let i = i + 1 +endwhile + +unlet color chars colors cpp n i s + +endif " has("gui_running") || has("termguicolors") && &termguicolors + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link xpmType Type +hi def link xpmStorageClass StorageClass +hi def link xpmTodo Todo +hi def link xpmComment Comment +hi def link xpmPixelString String + + +let b:current_syntax = "xpm" + +" vim: ts=8:sw=3:noet: + +endif diff --git a/syntax/xpm2.vim b/syntax/xpm2.vim new file mode 100644 index 0000000..a4496fe --- /dev/null +++ b/syntax/xpm2.vim @@ -0,0 +1,157 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: X Pixmap v2 +" Maintainer: Steve Wall (hitched97@velnet.com) +" Last Change: 2017 Feb 01 +" (Dominique Pelle added @Spell) +" Version: 5.8 +" Jemma Nelson added termguicolors support +" +" Made from xpm.vim by Ronald Schild + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +syn region xpm2PixelString start="^" end="$" contains=@xpm2Colors +syn keyword xpm2Todo TODO FIXME XXX contained +syn match xpm2Comment "\!.*$" contains=@Spell,xpm2Todo + + +command -nargs=+ Hi hi def + +if has("gui_running") || has("termguicolors") && &termguicolors + + let color = "" + let chars = "" + let colors = 0 + let cpp = 0 + let n = 0 + let i = 1 + + while i <= line("$") " scanning all lines + + let s = getline(i) + if match(s,"\!.*$") != -1 + let s = matchstr(s, "^[^\!]*") + endif + if s != "" " does line contain a string? + + if n == 0 " first string is the Values string + + " get the 3rd value: colors = number of colors + let colors = substitute(s, '\s*\d\+\s\+\d\+\s\+\(\d\+\).*', '\1', '') + " get the 4th value: cpp = number of character per pixel + let cpp = substitute(s, '\s*\d\+\s\+\d\+\s\+\d\+\s\+\(\d\+\).*', '\1', '') + if cpp =~ '[^0-9]' + break " if cpp is not made of digits there must be something wrong + endif + + " Highlight the Values string as normal string (no pixel string). + " Only when there is no slash, it would terminate the pattern. + if s !~ '/' + exe 'syn match xpm2Values /' . s . '/' + endif + hi def link xpm2Values Statement + + let n = 1 " n = color index + + elseif n <= colors " string is a color specification + + " get chars = length string representing the pixels + " (first incl. the following whitespace) + let chars = substitute(s, '\(.\{'.cpp.'}\s\+\).*', '\1', '') + + " now get color, first try 'c' key if any (color visual) + let color = substitute(s, '.*\sc\s\+\(.\{-}\)\s*\(\(g4\=\|[ms]\)\s.*\)*\s*', '\1', '') + if color == s + " no 'c' key, try 'g' key (grayscale with more than 4 levels) + let color = substitute(s, '.*\sg\s\+\(.\{-}\)\s*\(\(g4\|[ms]\)\s.*\)*\s*', '\1', '') + if color == s + " next try: 'g4' key (4-level grayscale) + let color = substitute(s, '.*\sg4\s\+\(.\{-}\)\s*\([ms]\s.*\)*\s*', '\1', '') + if color == s + " finally try 'm' key (mono visual) + let color = substitute(s, '.*\sm\s\+\(.\{-}\)\s*\(s\s.*\)*\s*', '\1', '') + if color == s + let color = "" + endif + endif + endif + endif + + " Vim cannot handle RGB codes with more than 6 hex digits + if color =~ '#\x\{10,}$' + let color = substitute(color, '\(\x\x\)\x\x', '\1', 'g') + elseif color =~ '#\x\{7,}$' + let color = substitute(color, '\(\x\x\)\x', '\1', 'g') + " nor with 3 digits + elseif color =~ '#\x\{3}$' + let color = substitute(color, '\(\x\)\(\x\)\(\x\)', '0\10\20\3', '') + endif + + " escape meta characters in patterns + let s = escape(s, '/\*^$.~[]') + let chars = escape(chars, '/\*^$.~[]') + + " change whitespace to "\s\+" + let s = substitute(s, "[ \t][ \t]*", "\\\\s\\\\+", "g") + let chars = substitute(chars, "[ \t][ \t]*", "\\\\s\\\\+", "g") + + " now create syntax items + " highlight the color string as normal string (no pixel string) + exe 'syn match xpm2Col'.n.'Def /'.s.'/ contains=xpm2Col'.n.'inDef' + exe 'hi def link xpm2Col'.n.'Def Constant' + + " but highlight the first whitespace after chars in its color + exe 'syn match xpm2Col'.n.'inDef /^'.chars.'/hs=s+'.(cpp).' contained' + exe 'hi def link xpm2Col'.n.'inDef xpm2Color'.n + + " remove the following whitespace from chars + let chars = substitute(chars, '\\s\\+$', '', '') + + " and create the syntax item contained in the pixel strings + exe 'syn match xpm2Color'.n.' /'.chars.'/ contained' + exe 'syn cluster xpm2Colors add=xpm2Color'.n + + " if no color or color = "None" show background + if color == "" || substitute(color, '.*', '\L&', '') == 'none' + exe 'Hi xpm2Color'.n.' guifg=bg guibg=NONE' + elseif color !~ "'" + exe 'Hi xpm2Color'.n." guifg='".color."' guibg='".color."'" + endif + let n = n + 1 + else + break " no more color string + endif + endif + let i = i + 1 + endwhile + + unlet color chars colors cpp n i s + +endif " has("gui_running") || has("termguicolors") && &termguicolors + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet +" The default highlighting. +hi def link xpm2Type Type +hi def link xpm2StorageClass StorageClass +hi def link xpm2Todo Todo +hi def link xpm2Comment Comment +hi def link xpm2PixelString String + +delcommand Hi + +let b:current_syntax = "xpm2" + +let &cpo = s:cpo_save +unlet s:cpo_save +" vim: ts=8:sw=2:noet: + +endif diff --git a/syntax/xquery.vim b/syntax/xquery.vim new file mode 100644 index 0000000..8a9c01a --- /dev/null +++ b/syntax/xquery.vim @@ -0,0 +1,86 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: XQuery +" Author: René Neumann +" Author: Steve Spigarelli +" Original Author: Jean-Marc Vanel +" Last Change: mar jui 12 18:04:05 CEST 2005 +" Filenames: *.xq +" URL: http://jmvanel.free.fr/vim/xquery.vim + +" REFERENCES: +" [1] http://www.w3.org/TR/xquery/ + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +" - is allowed in keywords +setlocal iskeyword+=- + +runtime syntax/xml.vim + +syn case match + +" From XQuery grammar: +syn keyword xqStatement ancestor ancestor-or-self and as ascending at attribute base-uri boundary-space by case cast castable child collation construction declare default descendant descendant-or-self descending div document element else empty encoding eq every except external following following-sibling for function ge greatest gt idiv if import in inherit-namespaces instance intersect is le least let lt mod module namespace ne no of or order ordered ordering parent preceding preceding-sibling preserve return satisfies schema self some stable strip then to treat typeswitch union unordered validate variable version where xmlspace xquery yes + +" TODO contains clashes with vim keyword +syn keyword xqFunction abs adjust-date-to-timezone adjust-date-to-timezone adjust-dateTime-to-timezone adjust-dateTime-to-timezone adjust-time-to-timezone adjust-time-to-timezone avg base-uri base-uri boolean ceiling codepoint-equal codepoints-to-string collection collection compare concat count current-date current-dateTime current-time data dateTime day-from-date day-from-dateTime days-from-duration deep-equal deep-equal default-collation distinct-values distinct-values doc doc-available document-uri empty ends-with ends-with error error error error escape-uri exactly-one exists false floor hours-from-dateTime hours-from-duration hours-from-time id id idref idref implicit-timezone in-scope-prefixes index-of index-of insert-before lang lang last local-name local-name local-name-from-QName lower-case matches matches max max min min minutes-from-dateTime minutes-from-duration minutes-from-time month-from-date month-from-dateTime months-from-duration name name namespace-uri namespace-uri namespace-uri-for-prefix namespace-uri-from-QName nilled node-name normalize-space normalize-space normalize-unicode normalize-unicode not number number one-or-more position prefix-from-QName QName remove replace replace resolve-QName resolve-uri resolve-uri reverse root root round round-half-to-even round-half-to-even seconds-from-dateTime seconds-from-duration seconds-from-time starts-with starts-with static-base-uri string string string-join string-length string-length string-to-codepoints subsequence subsequence substring substring substring-after substring-after substring-before substring-before sum sum timezone-from-date timezone-from-dateTime timezone-from-time tokenize tokenize trace translate true unordered upper-case year-from-date year-from-dateTime years-from-duration zero-or-one + +syn keyword xqOperator add-dayTimeDuration-to-date add-dayTimeDuration-to-dateTime add-dayTimeDuration-to-time add-dayTimeDurations add-yearMonthDuration-to-date add-yearMonthDuration-to-dateTime add-yearMonthDurations base64Binary-equal boolean-equal boolean-greater-than boolean-less-than concatenate date-equal date-greater-than date-less-than dateTime-equal dateTime-greater-than dateTime-less-than dayTimeDuration-equal dayTimeDuration-greater-than dayTimeDuration-less-than divide-dayTimeDuration divide-dayTimeDuration-by-dayTimeDuration divide-yearMonthDuration divide-yearMonthDuration-by-yearMonthDuration except gDay-equal gMonth-equal gMonthDay-equal gYear-equal gYearMonth-equal hexBinary-equal intersect is-same-node multiply-dayTimeDuration multiply-yearMonthDuration node-after node-before NOTATION-equal numeric-add numeric-divide numeric-equal numeric-greater-than numeric-integer-divide numeric-less-than numeric-mod numeric-multiply numeric-subtract numeric-unary-minus numeric-unary-plus QName-equal subtract-dates-yielding-dayTimeDuration subtract-dateTimes-yielding-dayTimeDuration subtract-dayTimeDuration-from-date subtract-dayTimeDuration-from-dateTime subtract-dayTimeDuration-from-time subtract-dayTimeDurations subtract-times subtract-yearMonthDuration-from-date subtract-yearMonthDuration-from-dateTime subtract-yearMonthDurations time-equal time-greater-than time-less-than to union yearMonthDuration-equal yearMonthDuration-greater-than yearMonthDuration-less-than + +syn match xqType "xs:\(\|Datatype\|primitive\|string\|boolean\|float\|double\|decimal\|duration\|dateTime\|time\|date\|gYearMonth\|gYear\|gMonthDay\|gDay\|gMonth\|hexBinary\|base64Binary\|anyURI\|QName\|NOTATION\|\|normalizedString\|token\|language\|IDREFS\|ENTITIES\|NMTOKEN\|NMTOKENS\|Name\|NCName\|ID\|IDREF\|ENTITY\|integer\|nonPositiveInteger\|negativeInteger\|long\|int\|short\|byte\|nonNegativeInteger\|unsignedLong\|unsignedInt\|unsignedShort\|unsignedByte\|positiveInteger\)" + + +" From XPath grammar: +syn keyword xqXPath some every in in satisfies if then else to div idiv mod union intersect except instance of treat castable cast eq ne lt le gt ge is child descendant attribute self descendant-or-self following-sibling following namespace parent ancestor preceding-sibling preceding ancestor-or-self void item node document-node text comment processing-instruction attribute schema-attribute schema-element + +" eXist extensions +syn match xqExist "&=" + +" XQdoc +syn match XQdoc contained "@\(param\|return\|author\)\>" + +" floating point number, with dot, optional exponent +syn match xqFloat "\d\+\.\d*\(e[-+]\=\d\+\)\=[fl]\=" +" floating point number, starting with a dot, optional exponent +syn match xqFloat "\.\d\+\(e[-+]\=\d\+\)\=[fl]\=\>" +" floating point number, without dot, with exponent +syn match xqFloat "\d\+e[-+]\=\d\+[fl]\=\>" +syn match xqNumber "0x\x\+\(u\=l\{0,2}\|ll\=u\)\>" +syn match xqNumber "\<\d\+\>" + +syn region xqString start=+\z(['"]\)+ skip=+\\.+ end=+\z1+ +syn region xqComment start='(:' excludenl end=':)' contains=XQdoc + +syn match xqVariable "$\<[a-zA-Z:_][-.0-9a-zA-Z0-9:_]*\>" +syn match xqSeparator ",\|;" +syn region xqCode transparent contained start='{' excludenl end='}' contains=xqFunction,xqCode,xmlRegionBis,xqComment,xqStatement,xmlString,xqSeparator,xqNumber,xqVariable,xqString keepend extend + +syn region xmlRegionBis start=+<\z([^ /!?<>"']\+\)+ skip=++ end=++ end=+/>+ fold contains=xmlTag,xmlEndTag,xmlCdata,xmlRegionBis,xmlComment,xmlEntity,xmlProcessing,xqCode keepend extend + +hi def link xqNumber Number +hi def link xqFloat Number +hi def link xqString String +hi def link xqVariable Identifier +hi def link xqComment Comment +hi def link xqSeparator Operator +hi def link xqStatement Statement +hi def link xqFunction Function +hi def link xqOperator Operator +hi def link xqType Type +hi def link xqXPath Operator +hi def link XQdoc Special +hi def link xqExist Operator + +" override the xml highlighting +"hi link xmlTag Structure +"hi link xmlTagName Structure +"hi link xmlEndTag Structure + +let b:current_syntax = "xquery" + +endif diff --git a/syntax/xs.vim b/syntax/xs.vim index 459a620..b2d0073 100644 --- a/syntax/xs.vim +++ b/syntax/xs.vim @@ -1,3 +1,3684 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: XS (Perl extension interface language) +" Author: Autogenerated from perl headers, on an original basis of Michael W. Dodge +" Maintainer: vim-perl +" Previous: Vincent Pit +" Last Change: 2017-09-12 + +if exists("b:current_syntax") + finish +endif + +runtime! syntax/c.vim + +" Configuration: +" let xs_superseded = 0 " mark C functions superseded by Perl replacements (ex. memcpy vs Copy) +" let xs_not_core = 0 " mark private core functions + +if get(g:, 'xs_superseded', 0) +syn keyword xsSuperseded atof atol calloc clearerr exit fclose feof ferror +syn keyword xsSuperseded fflush fgetc fgetpos fgets fopen fprintf fputc fputs +syn keyword xsSuperseded fread free freopen fseek fsetpos fwrite getc getenv +syn keyword xsSuperseded isalnum isalpha iscntrl isdigit isgraph islower +syn keyword xsSuperseded isprint ispunct isspace isupper isxdigit malloc +syn keyword xsSuperseded memcpy memmove memset printf putc rand realloc +syn keyword xsSuperseded rewind setenv sprintf srand stderr stdin stdout +syn keyword xsSuperseded strcat strcmp strcpy strdup strlen strncat strncmp +syn keyword xsSuperseded strncpy strstr strtod strtol strtoul system tolower +syn keyword xsSuperseded toupper ungetc +endif +if get(g:, 'xs_not_core', 0) +syn keyword xsPrivate F0convert Perl__add_range_to_invlist +syn keyword xsPrivate Perl__core_swash_init Perl__get_encoding +syn keyword xsPrivate Perl__get_swash_invlist Perl__invlist_contents +syn keyword xsPrivate Perl__invlist_dump +syn keyword xsPrivate Perl__invlist_intersection_maybe_complement_2nd +syn keyword xsPrivate Perl__invlist_invert Perl__invlist_populate_swatch +syn keyword xsPrivate Perl__invlist_search +syn keyword xsPrivate Perl__invlist_union_maybe_complement_2nd +syn keyword xsPrivate Perl__load_PL_utf8_foldclosures Perl__new_invlist +syn keyword xsPrivate Perl__setup_canned_invlist Perl__swash_inversion_hash +syn keyword xsPrivate Perl__swash_to_invlist Perl__to_fold_latin1 +syn keyword xsPrivate Perl__warn_problematic_locale Perl_av_reify +syn keyword xsPrivate Perl_current_re_engine Perl_cv_ckproto_len_flags +syn keyword xsPrivate Perl_emulate_cop_io Perl_find_rundefsvoffset +syn keyword xsPrivate Perl_get_re_arg Perl_grok_atoUV Perl_isALNUM_lazy +syn keyword xsPrivate Perl_isIDFIRST_lazy Perl_is_uni_alnum +syn keyword xsPrivate Perl_is_uni_alnum_lc Perl_is_uni_alnumc +syn keyword xsPrivate Perl_is_uni_alnumc_lc Perl_is_uni_alpha +syn keyword xsPrivate Perl_is_uni_alpha_lc Perl_is_uni_ascii +syn keyword xsPrivate Perl_is_uni_ascii_lc Perl_is_uni_blank +syn keyword xsPrivate Perl_is_uni_blank_lc Perl_is_uni_cntrl +syn keyword xsPrivate Perl_is_uni_cntrl_lc Perl_is_uni_digit +syn keyword xsPrivate Perl_is_uni_digit_lc Perl_is_uni_graph +syn keyword xsPrivate Perl_is_uni_graph_lc Perl_is_uni_idfirst +syn keyword xsPrivate Perl_is_uni_idfirst_lc Perl_is_uni_lower +syn keyword xsPrivate Perl_is_uni_lower_lc Perl_is_uni_print +syn keyword xsPrivate Perl_is_uni_print_lc Perl_is_uni_punct +syn keyword xsPrivate Perl_is_uni_punct_lc Perl_is_uni_space +syn keyword xsPrivate Perl_is_uni_space_lc Perl_is_uni_upper +syn keyword xsPrivate Perl_is_uni_upper_lc Perl_is_uni_xdigit +syn keyword xsPrivate Perl_is_uni_xdigit_lc Perl_is_utf8_alnum +syn keyword xsPrivate Perl_is_utf8_alnumc Perl_is_utf8_alpha +syn keyword xsPrivate Perl_is_utf8_ascii Perl_is_utf8_blank Perl_is_utf8_char +syn keyword xsPrivate Perl_is_utf8_cntrl Perl_is_utf8_digit +syn keyword xsPrivate Perl_is_utf8_graph Perl_is_utf8_idcont +syn keyword xsPrivate Perl_is_utf8_idfirst Perl_is_utf8_lower +syn keyword xsPrivate Perl_is_utf8_mark Perl_is_utf8_perl_space +syn keyword xsPrivate Perl_is_utf8_perl_word Perl_is_utf8_posix_digit +syn keyword xsPrivate Perl_is_utf8_print Perl_is_utf8_punct +syn keyword xsPrivate Perl_is_utf8_space Perl_is_utf8_upper +syn keyword xsPrivate Perl_is_utf8_xdigit Perl_is_utf8_xidcont +syn keyword xsPrivate Perl_is_utf8_xidfirst Perl_mg_find_mglob Perl_mg_length +syn keyword xsPrivate Perl_multideref_stringify Perl_new_warnings_bitfield +syn keyword xsPrivate Perl_op_clear Perl_ptr_table_clear Perl_qerror +syn keyword xsPrivate Perl_reg_named_buff Perl_reg_named_buff_iter +syn keyword xsPrivate Perl_reg_numbered_buff_fetch +syn keyword xsPrivate Perl_reg_numbered_buff_length +syn keyword xsPrivate Perl_reg_numbered_buff_store Perl_reg_qr_package +syn keyword xsPrivate Perl_reg_temp_copy Perl_regprop Perl_report_uninit +syn keyword xsPrivate Perl_sv_magicext_mglob Perl_sv_setsv_cow +syn keyword xsPrivate Perl_to_uni_lower_lc Perl_to_uni_title_lc +syn keyword xsPrivate Perl_to_uni_upper_lc Perl_try_amagic_bin +syn keyword xsPrivate Perl_try_amagic_un Perl_utf8_to_uvchr +syn keyword xsPrivate Perl_utf8_to_uvuni Perl_utf8_to_uvuni_buf +syn keyword xsPrivate Perl_valid_utf8_to_uvuni Perl_validate_proto +syn keyword xsPrivate Perl_vivify_defelem Perl_yylex S_F0convert +syn keyword xsPrivate S__append_range_to_invlist S__make_exactf_invlist +syn keyword xsPrivate S_add_above_Latin1_folds S_add_data S_add_multi_match +syn keyword xsPrivate S_add_utf16_textfilter S_adjust_size_and_find_bucket +syn keyword xsPrivate S_advance_one_SB S_advance_one_WB S_amagic_cmp +syn keyword xsPrivate S_amagic_cmp_locale S_amagic_i_ncmp S_amagic_ncmp +syn keyword xsPrivate S_anonymise_cv_maybe S_ao S_apply_attrs +syn keyword xsPrivate S_apply_attrs_my S_assert_uft8_cache_coherent +syn keyword xsPrivate S_assignment_type S_backup_one_SB S_backup_one_WB +syn keyword xsPrivate S_bad_type_gv S_bad_type_pv +syn keyword xsPrivate S_check_locale_boundary_crossing S_check_type_and_open +syn keyword xsPrivate S_check_uni S_checkcomma S_ckwarn_common +syn keyword xsPrivate S_clear_placeholders S_clear_special_blocks +syn keyword xsPrivate S_cntrl_to_mnemonic S_construct_ahocorasick_from_trie +syn keyword xsPrivate S_cop_free S_could_it_be_a_POSIX_class S_cr_textfilter +syn keyword xsPrivate S_curse S_cv_dump S_deb_curcv S_deb_stack_n S_debprof +syn keyword xsPrivate S_debug_start_match S_del_sv +syn keyword xsPrivate S_deprecate_commaless_var_list S_destroy_matcher +syn keyword xsPrivate S_div128 S_do_chomp S_do_delete_local S_do_oddball +syn keyword xsPrivate S_do_smartmatch S_do_trans_complex +syn keyword xsPrivate S_do_trans_complex_utf8 S_do_trans_count +syn keyword xsPrivate S_do_trans_count_utf8 S_do_trans_simple +syn keyword xsPrivate S_do_trans_simple_utf8 S_docatch S_doeval S_dofindlabel +syn keyword xsPrivate S_doform S_dooneliner S_doopen_pm S_doparseform +syn keyword xsPrivate S_dopoptoeval S_dopoptogiven S_dopoptolabel +syn keyword xsPrivate S_dopoptoloop S_dopoptosub_at S_dopoptowhen +syn keyword xsPrivate S_dump_exec_pos S_dump_trie S_dump_trie_interim_list +syn keyword xsPrivate S_dump_trie_interim_table S_dumpuntil S_dup_attrlist +syn keyword xsPrivate S_exec_failed S_expect_number S_filter_gets +syn keyword xsPrivate S_finalize_op S_find_and_forget_pmops +syn keyword xsPrivate S_find_array_subscript S_find_beginning S_find_byclass +syn keyword xsPrivate S_find_default_stash S_find_hash_subscript +syn keyword xsPrivate S_find_in_my_stash S_find_uninit_var S_first_symbol +syn keyword xsPrivate S_fixup_errno_string S_fold_constants S_forbid_setid +syn keyword xsPrivate S_force_ident S_force_ident_maybe_lex S_force_list +syn keyword xsPrivate S_force_next S_force_strict_version S_force_version +syn keyword xsPrivate S_force_word S_forget_pmop S_form_short_octal_warning +syn keyword xsPrivate S_gen_constant_list S_get_ANYOF_cp_list_for_ssc +syn keyword xsPrivate S_get_aux_mg S_get_num S_glob_2number +syn keyword xsPrivate S_glob_assign_glob S_grok_bslash_N S_grok_bslash_c +syn keyword xsPrivate S_grok_bslash_o S_group_end S_gv_init_svtype +syn keyword xsPrivate S_gv_is_in_main S_gv_magicalize S_gv_magicalize_isa +syn keyword xsPrivate S_handle_regex_sets S_hfreeentries S_hsplit +syn keyword xsPrivate S_hv_auxinit S_hv_auxinit_internal S_hv_delete_common +syn keyword xsPrivate S_hv_free_ent_ret S_hv_magic_check S_hv_notallowed +syn keyword xsPrivate S_incline S_incpush S_incpush_if_exists +syn keyword xsPrivate S_incpush_use_sep S_ingroup S_init_ids S_init_interp +syn keyword xsPrivate S_init_main_stash S_init_perllib +syn keyword xsPrivate S_init_postdump_symbols S_init_predump_symbols +syn keyword xsPrivate S_inplace_aassign S_intuit_method S_intuit_more +syn keyword xsPrivate S_invlist_extend S_invlist_iternext +syn keyword xsPrivate S_invoke_exception_hook S_isFOO_lc S_isFOO_utf8_lc +syn keyword xsPrivate S_isGCB S_isSB S_isWB S_is_an_int +syn keyword xsPrivate S_is_handle_constructor S_is_ssc_worth_it S_isa_lookup +syn keyword xsPrivate S_join_exact S_leave_common S_listkids +syn keyword xsPrivate S_looks_like_bool S_magic_methcall1 S_make_matcher +syn keyword xsPrivate S_make_trie S_matcher_matches_sv S_maybe_multimagic_gv +syn keyword xsPrivate S_mayberelocate S_measure_struct S_mem_log_common +syn keyword xsPrivate S_mess_alloc S_minus_v S_missingterm S_modkids +syn keyword xsPrivate S_more_sv S_move_proto_attr S_mro_clean_isarev +syn keyword xsPrivate S_mro_gather_and_rename S_mro_get_linear_isa_dfs +syn keyword xsPrivate S_mul128 S_mulexp10 S_my_bytes_to_utf8 S_my_exit_jump +syn keyword xsPrivate S_my_kid S_need_utf8 S_newGIVWHENOP S_new_constant +syn keyword xsPrivate S_new_he S_new_logop S_next_symbol S_nextchar +syn keyword xsPrivate S_no_bareword_allowed S_no_fh_allowed S_no_op +syn keyword xsPrivate S_not_a_number S_not_incrementable S_nuke_stacks +syn keyword xsPrivate S_num_overflow S_open_script S_openn_cleanup +syn keyword xsPrivate S_openn_setup S_pack_rec S_pad_alloc_name +syn keyword xsPrivate S_pad_check_dup S_pad_findlex S_pad_reset S_parse_body +syn keyword xsPrivate S_parse_gv_stash_name S_parse_ident +syn keyword xsPrivate S_parse_lparen_question_flags S_pending_ident S_pidgone +syn keyword xsPrivate S_pm_description S_pmtrans +syn keyword xsPrivate S_populate_ANYOF_from_invlist S_printbuf +syn keyword xsPrivate S_process_special_blocks S_ptr_table_find +syn keyword xsPrivate S_put_charclass_bitmap_innards S_put_code_point +syn keyword xsPrivate S_put_range S_qsortsvu S_re_croak2 S_ref_array_or_hash +syn keyword xsPrivate S_refcounted_he_value S_refkids S_refto S_reg +syn keyword xsPrivate S_reg2Lanode S_reg_check_named_buff_matched S_reg_node +syn keyword xsPrivate S_reg_recode S_reg_scan_name S_reganode S_regatom +syn keyword xsPrivate S_regbranch S_regclass S_regcppop S_regcppush +syn keyword xsPrivate S_regdump_extflags S_regdump_intflags +syn keyword xsPrivate S_regex_set_precedence S_reghop3 S_reghop4 +syn keyword xsPrivate S_reghopmaybe3 S_reginclass S_reginsert S_regmatch +syn keyword xsPrivate S_regnode_guts S_regpatws S_regpiece S_regrepeat +syn keyword xsPrivate S_regtail S_regtail_study S_regtry S_require_tie_mod +syn keyword xsPrivate S_restore_magic S_run_body S_run_user_filter +syn keyword xsPrivate S_rxres_free S_rxres_restore S_save_hek_flags +syn keyword xsPrivate S_save_lines S_save_magic_flags S_save_pushptri32ptr +syn keyword xsPrivate S_save_scalar_at S_scalar_mod_type S_scalarboolean +syn keyword xsPrivate S_scalarkids S_scalarseq S_scan_commit S_scan_const +syn keyword xsPrivate S_scan_formline S_scan_heredoc S_scan_ident +syn keyword xsPrivate S_scan_inputsymbol S_scan_pat S_scan_str S_scan_subst +syn keyword xsPrivate S_scan_trans S_scan_word S_search_const S_sequence_num +syn keyword xsPrivate S_set_ANYOF_arg S_share_hek_flags S_simplify_sort +syn keyword xsPrivate S_skipspace_flags S_sortcv S_sortcv_stacked +syn keyword xsPrivate S_sortcv_xsub S_space_join_names_mortal S_ssc_and +syn keyword xsPrivate S_ssc_anything S_ssc_finalize S_ssc_init +syn keyword xsPrivate S_ssc_is_anything S_ssc_is_cp_posixl_init S_ssc_or +syn keyword xsPrivate S_stdize_locale S_strip_return S_study_chunk +syn keyword xsPrivate S_sublex_done S_sublex_push S_sublex_start +syn keyword xsPrivate S_sv_2iuv_common S_sv_2iuv_non_preserve S_sv_add_arena +syn keyword xsPrivate S_sv_buf_to_rw S_sv_display S_sv_dup_common +syn keyword xsPrivate S_sv_dup_inc_multiple S_sv_exp_grow S_sv_i_ncmp +syn keyword xsPrivate S_sv_ncmp S_sv_pos_b2u_midway S_sv_pos_u2b_cached +syn keyword xsPrivate S_sv_pos_u2b_forwards S_sv_pos_u2b_midway +syn keyword xsPrivate S_sv_release_COW S_swallow_bom S_swash_scan_list_line +syn keyword xsPrivate S_swatch_get S_to_byte_substr S_to_lower_latin1 +syn keyword xsPrivate S_to_utf8_substr S_tokenize_use S_tokeq S_tokereport +syn keyword xsPrivate S_too_few_arguments_pv S_too_many_arguments_pv +syn keyword xsPrivate S_uiv_2buf S_unpack_rec S_unreferenced_to_tmp_stack +syn keyword xsPrivate S_unshare_hek_or_pvn S_unwind_handler_stack +syn keyword xsPrivate S_update_debugger_info S_usage S_utf16_textfilter +syn keyword xsPrivate S_utf8_mg_len_cache_update S_utf8_mg_pos_cache_update +syn keyword xsPrivate S_validate_suid S_visit S_with_queued_errors +syn keyword xsPrivate S_xs_version_bootcheck S_yywarn _add_range_to_invlist +syn keyword xsPrivate _append_range_to_invlist _core_swash_init _get_encoding +syn keyword xsPrivate _get_swash_invlist _invlist_array_init +syn keyword xsPrivate _invlist_contains_cp _invlist_contents _invlist_dump +syn keyword xsPrivate _invlist_intersection +syn keyword xsPrivate _invlist_intersection_maybe_complement_2nd +syn keyword xsPrivate _invlist_invert _invlist_len _invlist_populate_swatch +syn keyword xsPrivate _invlist_search _invlist_subtract _invlist_union +syn keyword xsPrivate _invlist_union_maybe_complement_2nd +syn keyword xsPrivate _load_PL_utf8_foldclosures _make_exactf_invlist +syn keyword xsPrivate _new_invlist _setup_canned_invlist +syn keyword xsPrivate _swash_inversion_hash _swash_to_invlist _to_fold_latin1 +syn keyword xsPrivate _warn_problematic_locale add_above_Latin1_folds +syn keyword xsPrivate add_cp_to_invlist add_data add_multi_match +syn keyword xsPrivate add_utf16_textfilter adjust_size_and_find_bucket +syn keyword xsPrivate advance_one_SB advance_one_WB +syn keyword xsPrivate alloc_maybe_populate_EXACT amagic_cmp amagic_cmp_locale +syn keyword xsPrivate amagic_i_ncmp amagic_ncmp anonymise_cv_maybe ao +syn keyword xsPrivate apply_attrs apply_attrs_my assert_uft8_cache_coherent +syn keyword xsPrivate assignment_type av_reify backup_one_SB backup_one_WB +syn keyword xsPrivate bad_type_gv bad_type_pv check_locale_boundary_crossing +syn keyword xsPrivate check_type_and_open check_uni checkcomma ckwarn_common +syn keyword xsPrivate clear_placeholders clear_special_blocks +syn keyword xsPrivate cntrl_to_mnemonic compute_EXACTish +syn keyword xsPrivate construct_ahocorasick_from_trie cop_free +syn keyword xsPrivate could_it_be_a_POSIX_class cr_textfilter +syn keyword xsPrivate current_re_engine curse cv_ckproto_len_flags cv_dump +syn keyword xsPrivate deb_curcv deb_stack_n debprof debug_start_match del_sv +syn keyword xsPrivate deprecate_commaless_var_list destroy_matcher div128 +syn keyword xsPrivate do_aexec do_chomp do_delete_local do_exec do_oddball +syn keyword xsPrivate do_smartmatch do_trans_complex do_trans_complex_utf8 +syn keyword xsPrivate do_trans_count do_trans_count_utf8 do_trans_simple +syn keyword xsPrivate do_trans_simple_utf8 docatch doeval dofindlabel doform +syn keyword xsPrivate dooneliner doopen_pm doparseform dopoptoeval +syn keyword xsPrivate dopoptogiven dopoptolabel dopoptoloop dopoptosub_at +syn keyword xsPrivate dopoptowhen dump_exec_pos dump_trie +syn keyword xsPrivate dump_trie_interim_list dump_trie_interim_table +syn keyword xsPrivate dumpuntil dup_attrlist exec_failed expect_number +syn keyword xsPrivate filter_gets finalize_op find_and_forget_pmops +syn keyword xsPrivate find_array_subscript find_beginning find_byclass +syn keyword xsPrivate find_default_stash find_hash_subscript find_in_my_stash +syn keyword xsPrivate find_rundefsvoffset find_uninit_var first_symbol +syn keyword xsPrivate fixup_errno_string fold_constants forbid_setid +syn keyword xsPrivate force_ident force_ident_maybe_lex force_list force_next +syn keyword xsPrivate force_strict_version force_version force_word +syn keyword xsPrivate forget_pmop form_short_octal_warning free_c_backtrace +syn keyword xsPrivate gen_constant_list get_ANYOF_cp_list_for_ssc get_aux_mg +syn keyword xsPrivate get_invlist_iter_addr get_invlist_offset_addr +syn keyword xsPrivate get_invlist_previous_index_addr get_num glob_2number +syn keyword xsPrivate glob_assign_glob grok_atoUV grok_bslash_N grok_bslash_c +syn keyword xsPrivate grok_bslash_o grok_bslash_x group_end gv_init_svtype +syn keyword xsPrivate gv_is_in_main gv_magicalize gv_magicalize_isa +syn keyword xsPrivate handle_regex_sets hfreeentries hsplit hv_auxinit +syn keyword xsPrivate hv_auxinit_internal hv_delete_common hv_free_ent_ret +syn keyword xsPrivate hv_magic_check hv_notallowed incline incpush +syn keyword xsPrivate incpush_if_exists incpush_use_sep ingroup init_ids +syn keyword xsPrivate init_interp init_main_stash init_perllib +syn keyword xsPrivate init_postdump_symbols init_predump_symbols +syn keyword xsPrivate inplace_aassign intuit_method intuit_more invlist_array +syn keyword xsPrivate invlist_clone invlist_extend invlist_highest +syn keyword xsPrivate invlist_is_iterating invlist_iterfinish +syn keyword xsPrivate invlist_iterinit invlist_iternext invlist_max +syn keyword xsPrivate invlist_previous_index invlist_set_len +syn keyword xsPrivate invlist_set_previous_index invlist_trim +syn keyword xsPrivate invoke_exception_hook isALNUM_lazy isFOO_lc +syn keyword xsPrivate isFOO_utf8_lc isGCB isIDFIRST_lazy isSB isWB is_an_int +syn keyword xsPrivate is_handle_constructor is_ssc_worth_it is_uni_alnum +syn keyword xsPrivate is_uni_alnum_lc is_uni_alnumc is_uni_alnumc_lc +syn keyword xsPrivate is_uni_alpha is_uni_alpha_lc is_uni_ascii +syn keyword xsPrivate is_uni_ascii_lc is_uni_blank is_uni_blank_lc +syn keyword xsPrivate is_uni_cntrl is_uni_cntrl_lc is_uni_digit +syn keyword xsPrivate is_uni_digit_lc is_uni_graph is_uni_graph_lc +syn keyword xsPrivate is_uni_idfirst is_uni_idfirst_lc is_uni_lower +syn keyword xsPrivate is_uni_lower_lc is_uni_print is_uni_print_lc +syn keyword xsPrivate is_uni_punct is_uni_punct_lc is_uni_space +syn keyword xsPrivate is_uni_space_lc is_uni_upper is_uni_upper_lc +syn keyword xsPrivate is_uni_xdigit is_uni_xdigit_lc is_utf8_alnum +syn keyword xsPrivate is_utf8_alnumc is_utf8_alpha is_utf8_ascii +syn keyword xsPrivate is_utf8_blank is_utf8_char is_utf8_cntrl is_utf8_digit +syn keyword xsPrivate is_utf8_graph is_utf8_idcont is_utf8_idfirst +syn keyword xsPrivate is_utf8_lower is_utf8_mark is_utf8_perl_space +syn keyword xsPrivate is_utf8_perl_word is_utf8_posix_digit is_utf8_print +syn keyword xsPrivate is_utf8_punct is_utf8_space is_utf8_upper +syn keyword xsPrivate is_utf8_xdigit is_utf8_xidcont is_utf8_xidfirst +syn keyword xsPrivate isa_lookup join_exact leave_common listkids +syn keyword xsPrivate looks_like_bool magic_methcall1 make_matcher make_trie +syn keyword xsPrivate matcher_matches_sv maybe_multimagic_gv mayberelocate +syn keyword xsPrivate measure_struct mem_log_common mess_alloc mg_find_mglob +syn keyword xsPrivate mg_length minus_v missingterm modkids more_sv +syn keyword xsPrivate move_proto_attr mro_clean_isarev mro_gather_and_rename +syn keyword xsPrivate mro_get_linear_isa_dfs mul128 mulexp10 +syn keyword xsPrivate multideref_stringify my_bytes_to_utf8 my_exit_jump +syn keyword xsPrivate my_kid need_utf8 newGIVWHENOP new_he new_logop +syn keyword xsPrivate next_symbol nextchar no_bareword_allowed no_fh_allowed +syn keyword xsPrivate no_op not_a_number not_incrementable nuke_stacks +syn keyword xsPrivate num_overflow op_clear open_script openn_cleanup +syn keyword xsPrivate openn_setup pack_rec pad_alloc_name pad_check_dup +syn keyword xsPrivate pad_findlex pad_reset parse_body parse_gv_stash_name +syn keyword xsPrivate parse_ident parse_lparen_question_flags pending_ident +syn keyword xsPrivate pidgone pm_description pmtrans +syn keyword xsPrivate populate_ANYOF_from_invlist printbuf +syn keyword xsPrivate process_special_blocks ptr_table_clear ptr_table_find +syn keyword xsPrivate put_charclass_bitmap_innards put_code_point put_range +syn keyword xsPrivate qerror qsortsvu re_croak2 ref_array_or_hash +syn keyword xsPrivate refcounted_he_value refkids refto reg reg2Lanode +syn keyword xsPrivate reg_check_named_buff_matched reg_named_buff +syn keyword xsPrivate reg_named_buff_iter reg_node reg_numbered_buff_fetch +syn keyword xsPrivate reg_numbered_buff_length reg_numbered_buff_store +syn keyword xsPrivate reg_qr_package reg_recode reg_scan_name reg_skipcomment +syn keyword xsPrivate reg_temp_copy reganode regatom regbranch regclass +syn keyword xsPrivate regcppop regcppush regcurly regdump_extflags +syn keyword xsPrivate regdump_intflags regex_set_precedence reghop3 reghop4 +syn keyword xsPrivate reghopmaybe3 reginclass reginsert regmatch regnode_guts +syn keyword xsPrivate regpatws regpiece regpposixcc regprop regrepeat regtail +syn keyword xsPrivate regtail_study regtry report_uninit require_tie_mod +syn keyword xsPrivate restore_magic run_body run_user_filter rxres_free +syn keyword xsPrivate rxres_restore save_hek_flags save_lines +syn keyword xsPrivate save_magic_flags save_pushptri32ptr save_scalar_at +syn keyword xsPrivate scalar_mod_type scalarboolean scalarkids scalarseq +syn keyword xsPrivate scan_commit scan_const scan_formline scan_heredoc +syn keyword xsPrivate scan_ident scan_inputsymbol scan_pat scan_str +syn keyword xsPrivate scan_subst scan_trans scan_word search_const +syn keyword xsPrivate sequence_num set_ANYOF_arg share_hek_flags +syn keyword xsPrivate simplify_sort skipspace_flags sortcv sortcv_stacked +syn keyword xsPrivate sortcv_xsub space_join_names_mortal ssc_add_range +syn keyword xsPrivate ssc_and ssc_anything ssc_clear_locale ssc_cp_and +syn keyword xsPrivate ssc_finalize ssc_init ssc_intersection ssc_is_anything +syn keyword xsPrivate ssc_is_cp_posixl_init ssc_or ssc_union stdize_locale +syn keyword xsPrivate strip_return study_chunk sublex_done sublex_push +syn keyword xsPrivate sublex_start sv_2iuv_common sv_2iuv_non_preserve +syn keyword xsPrivate sv_add_arena sv_buf_to_rw sv_copypv sv_display +syn keyword xsPrivate sv_dup_common sv_dup_inc_multiple sv_exp_grow sv_i_ncmp +syn keyword xsPrivate sv_magicext_mglob sv_ncmp sv_only_taint_gmagic +syn keyword xsPrivate sv_or_pv_pos_u2b sv_pos_b2u_midway sv_pos_u2b_cached +syn keyword xsPrivate sv_pos_u2b_forwards sv_pos_u2b_midway sv_release_COW +syn keyword xsPrivate sv_setsv_cow swallow_bom swash_scan_list_line +syn keyword xsPrivate swatch_get to_byte_substr to_lower_latin1 +syn keyword xsPrivate to_uni_lower_lc to_uni_title_lc to_uni_upper_lc +syn keyword xsPrivate to_utf8_substr tokenize_use tokeq tokereport +syn keyword xsPrivate too_few_arguments_pv too_many_arguments_pv uiv_2buf +syn keyword xsPrivate unpack_rec unreferenced_to_tmp_stack unshare_hek_or_pvn +syn keyword xsPrivate unwind_handler_stack update_debugger_info usage +syn keyword xsPrivate utf16_textfilter utf8_mg_len_cache_update +syn keyword xsPrivate utf8_mg_pos_cache_update utf8_to_uvchr utf8_to_uvuni +syn keyword xsPrivate utf8_to_uvuni_buf valid_utf8_to_uvuni validate_proto +syn keyword xsPrivate visit vivify_defelem with_queued_errors yylex yywarn +endif +syn keyword xsType AMT AMTS ANY AV BHK BINOP BLOCK CHECKPOINT CLONE_PARAMS +syn keyword xsType COP COPHH CV DB_Hash_t DB_Prefix_t DEBUG_t Direntry_t +syn keyword xsType Fpos_t Free_t GCB_enum GP GV Gid_t Groups_t HE HEK HV I16 +syn keyword xsType I32 I64 I8 IO IV Int64 JMPENV LISTOP LOGOP LOOP MAGIC +syn keyword xsType METHOP MGS MGVTBL Malloc_t Mmap_t Mode_t NV Netdb_hlen_t +syn keyword xsType Netdb_host_t Netdb_name_t Netdb_net_t OP OPCODE OPSLAB +syn keyword xsType OPSLOT Off_t Optype PAD PADLIST PADNAME PADNAMELIST +syn keyword xsType PADOFFSET PADOP PERL_CONTEXT PERL_DRAND48_T PERL_SI PMOP +syn keyword xsType PTR_TBL_ENT_t PTR_TBL_t PVOP PerlHandShakeInterpreter +syn keyword xsType PerlIO PerlIO_funcs PerlIO_list_s PerlIO_list_t PerlIOl +syn keyword xsType PerlInterpreter Pid_t Quad_t REGEXP RExC_state_t +syn keyword xsType Rand_seed_t SB_enum SSize_t STRLEN STRUCT_SV SUBLEXINFO SV +syn keyword xsType SVOP Select_fd_set_t Shmat_t Signal_t Sigsave_t Size_t +syn keyword xsType Sock_size_t Stat_t TM64 Time64_T Time_t U16 U32 U64 U8 +syn keyword xsType UNOP UNOP_AUX UV Uid_t Uquad_t WB_enum XINVLIST XOP XPV +syn keyword xsType XPVAV XPVBM XPVCV XPVFM XPVGV XPVHV XPVIO XPVIV XPVLV +syn keyword xsType XPVMG XPVNV XPVUV Year _PerlIO _PerlIO_funcs +syn keyword xsType _char_class_number _pMY_CXT _pTHX _reg_ac_data +syn keyword xsType _reg_trie_data _reg_trie_state _reg_trie_trans +syn keyword xsType _reg_trie_trans_list_elem _sublex_info _xhvnameu _xivu +syn keyword xsType _xmgu _xnvu am_table am_table_short block_eval +syn keyword xsType block_format block_givwhen block_hooks block_loop +syn keyword xsType block_sub bound_type clone_params custom_op cv_flags_t +syn keyword xsType expectation gccbug_semun line_t magic mem_log_type methop +syn keyword xsType mgvtbl mro_alg mro_meta my_cxt_t opcode opslab opslot p5rx +syn keyword xsType pMY_CXT pMY_CXT_ pTHX pTHX_ padlist padname +syn keyword xsType padname_with_str padnamelist padtidy_type perl_cond +syn keyword xsType perl_debug_pad perl_drand48_t perl_key +syn keyword xsType perl_memory_debug_header perl_mstats perl_mstats_t +syn keyword xsType perl_mutex perl_os_thread perl_phase perl_vars +syn keyword xsType pthread_addr_t ptr_tbl ptr_tbl_ent refcounted_he +syn keyword xsType reg_ac_data reg_code_block reg_data reg_substr_data +syn keyword xsType reg_substr_datum reg_trie_data reg_trie_state +syn keyword xsType reg_trie_trans reg_trie_trans_le regex_charset regnode +syn keyword xsType regnode_1 regnode_2 regnode_2L regnode_charclass +syn keyword xsType regnode_charclass_class regnode_charclass_posixl +syn keyword xsType regnode_ssc regnode_string semun shared_he svtype ufuncs +syn keyword xsType unop_aux xop_flags_enum xpv xpvav xpvcv xpvfm xpvgv xpvhv +syn keyword xsType xpvhv_aux xpvinvlist xpvio xpviv xpvlv xpvmg xpvnv xpvuv +syn keyword xsType yytokentype +syn keyword xsString IVdf NVef NVff NVgf SVf SVf256 SVf32 SVf_ UVof UVuf UVxf +syn keyword xsConstant CXt_BLOCK CXt_EVAL CXt_FORMAT CXt_GIVEN CXt_LOOP_FOR +syn keyword xsConstant CXt_LOOP_LAZYIV CXt_LOOP_LAZYSV CXt_LOOP_PLAIN +syn keyword xsConstant CXt_NULL CXt_SUB CXt_SUBST CXt_WHEN GCB_BOUND GCB_CR +syn keyword xsConstant GCB_Control GCB_EDGE GCB_Extend GCB_L GCB_LF GCB_LV +syn keyword xsConstant GCB_LVT GCB_Other GCB_Prepend GCB_Regional_Indicator +syn keyword xsConstant GCB_SpacingMark GCB_T GCB_V G_ARRAY G_DISCARD G_EVAL +syn keyword xsConstant G_FAKINGEVAL G_KEEPERR G_METHOD G_METHOD_NAMED +syn keyword xsConstant G_NOARGS G_NODEBUG G_RE_REPARSING G_SCALAR +syn keyword xsConstant G_UNDEF_FILL G_VOID G_WANT G_WARN_ALL_MASK +syn keyword xsConstant G_WARN_ALL_OFF G_WARN_ALL_ON G_WARN_OFF G_WARN_ON +syn keyword xsConstant G_WARN_ONCE G_WRITING_TO_STDERR OA_AVREF OA_BASEOP +syn keyword xsConstant OA_BASEOP_OR_UNOP OA_BINOP OA_CLASS_MASK OA_COP +syn keyword xsConstant OA_CVREF OA_DANGEROUS OA_DEFGV OA_FILEREF +syn keyword xsConstant OA_FILESTATOP OA_FOLDCONST OA_HVREF OA_LIST OA_LISTOP +syn keyword xsConstant OA_LOGOP OA_LOOP OA_LOOPEXOP OA_MARK OA_METHOP +syn keyword xsConstant OA_OPTIONAL OA_OTHERINT OA_PADOP OA_PMOP +syn keyword xsConstant OA_PVOP_OR_SVOP OA_RETSCALAR OA_SCALAR OA_SCALARREF +syn keyword xsConstant OA_SVOP OA_TARGET OA_TARGLEX OA_UNOP OA_UNOP_AUX +syn keyword xsConstant OP_AASSIGN OP_ABS OP_ACCEPT OP_ADD OP_AEACH OP_AELEM +syn keyword xsConstant OP_AELEMFAST OP_AELEMFAST_LEX OP_AKEYS OP_ALARM OP_AND +syn keyword xsConstant OP_ANDASSIGN OP_ANONCODE OP_ANONCONST OP_ANONHASH +syn keyword xsConstant OP_ANONLIST OP_ASLICE OP_ATAN2 OP_AV2ARYLEN OP_AVALUES +syn keyword xsConstant OP_BACKTICK OP_BIND OP_BINMODE OP_BIT_AND OP_BIT_OR +syn keyword xsConstant OP_BIT_XOR OP_BLESS OP_BREAK OP_CALLER OP_CHDIR +syn keyword xsConstant OP_CHMOD OP_CHOMP OP_CHOP OP_CHOWN OP_CHR OP_CHROOT +syn keyword xsConstant OP_CLONECV OP_CLOSE OP_CLOSEDIR OP_COMPLEMENT +syn keyword xsConstant OP_CONCAT OP_COND_EXPR OP_CONNECT OP_CONST OP_CONTINUE +syn keyword xsConstant OP_COREARGS OP_COS OP_CRYPT OP_CUSTOM OP_DBMCLOSE +syn keyword xsConstant OP_DBMOPEN OP_DBSTATE OP_DEFINED OP_DELETE OP_DIE +syn keyword xsConstant OP_DIVIDE OP_DOFILE OP_DOR OP_DORASSIGN OP_DUMP +syn keyword xsConstant OP_EACH OP_EGRENT OP_EHOSTENT OP_ENETENT OP_ENTER +syn keyword xsConstant OP_ENTEREVAL OP_ENTERGIVEN OP_ENTERITER OP_ENTERLOOP +syn keyword xsConstant OP_ENTERSUB OP_ENTERTRY OP_ENTERWHEN OP_ENTERWRITE +syn keyword xsConstant OP_EOF OP_EPROTOENT OP_EPWENT OP_EQ OP_ESERVENT +syn keyword xsConstant OP_EXEC OP_EXISTS OP_EXIT OP_EXP OP_FC OP_FCNTL +syn keyword xsConstant OP_FILENO OP_FLIP OP_FLOCK OP_FLOP OP_FORK OP_FORMLINE +syn keyword xsConstant OP_FTATIME OP_FTBINARY OP_FTBLK OP_FTCHR OP_FTCTIME +syn keyword xsConstant OP_FTDIR OP_FTEEXEC OP_FTEOWNED OP_FTEREAD OP_FTEWRITE +syn keyword xsConstant OP_FTFILE OP_FTIS OP_FTLINK OP_FTMTIME OP_FTPIPE +syn keyword xsConstant OP_FTREXEC OP_FTROWNED OP_FTRREAD OP_FTRWRITE +syn keyword xsConstant OP_FTSGID OP_FTSIZE OP_FTSOCK OP_FTSUID OP_FTSVTX +syn keyword xsConstant OP_FTTEXT OP_FTTTY OP_FTZERO OP_GE OP_GELEM OP_GETC +syn keyword xsConstant OP_GETLOGIN OP_GETPEERNAME OP_GETPGRP OP_GETPPID +syn keyword xsConstant OP_GETPRIORITY OP_GETSOCKNAME OP_GGRENT OP_GGRGID +syn keyword xsConstant OP_GGRNAM OP_GHBYADDR OP_GHBYNAME OP_GHOSTENT OP_GLOB +syn keyword xsConstant OP_GMTIME OP_GNBYADDR OP_GNBYNAME OP_GNETENT OP_GOTO +syn keyword xsConstant OP_GPBYNAME OP_GPBYNUMBER OP_GPROTOENT OP_GPWENT +syn keyword xsConstant OP_GPWNAM OP_GPWUID OP_GREPSTART OP_GREPWHILE +syn keyword xsConstant OP_GSBYNAME OP_GSBYPORT OP_GSERVENT OP_GSOCKOPT OP_GT +syn keyword xsConstant OP_GV OP_GVSV OP_HELEM OP_HEX OP_HINTSEVAL OP_HSLICE +syn keyword xsConstant OP_INDEX OP_INT OP_INTROCV OP_IOCTL OP_ITER OP_I_ADD +syn keyword xsConstant OP_I_DIVIDE OP_I_EQ OP_I_GE OP_I_GT OP_I_LE OP_I_LT +syn keyword xsConstant OP_I_MODULO OP_I_MULTIPLY OP_I_NCMP OP_I_NE +syn keyword xsConstant OP_I_NEGATE OP_I_POSTDEC OP_I_POSTINC OP_I_PREDEC +syn keyword xsConstant OP_I_PREINC OP_I_SUBTRACT OP_JOIN OP_KEYS OP_KILL +syn keyword xsConstant OP_KVASLICE OP_KVHSLICE OP_LAST OP_LC OP_LCFIRST OP_LE +syn keyword xsConstant OP_LEAVE OP_LEAVEEVAL OP_LEAVEGIVEN OP_LEAVELOOP +syn keyword xsConstant OP_LEAVESUB OP_LEAVESUBLV OP_LEAVETRY OP_LEAVEWHEN +syn keyword xsConstant OP_LEAVEWRITE OP_LEFT_SHIFT OP_LENGTH OP_LINESEQ +syn keyword xsConstant OP_LINK OP_LIST OP_LISTEN OP_LOCALTIME OP_LOCK OP_LOG +syn keyword xsConstant OP_LSLICE OP_LSTAT OP_LT OP_LVAVREF OP_LVREF +syn keyword xsConstant OP_LVREFSLICE OP_MAPSTART OP_MAPWHILE OP_MATCH +syn keyword xsConstant OP_METHOD OP_METHOD_NAMED OP_METHOD_REDIR +syn keyword xsConstant OP_METHOD_REDIR_SUPER OP_METHOD_SUPER OP_MKDIR +syn keyword xsConstant OP_MODULO OP_MSGCTL OP_MSGGET OP_MSGRCV OP_MSGSND +syn keyword xsConstant OP_MULTIDEREF OP_MULTIPLY OP_NBIT_AND OP_NBIT_OR +syn keyword xsConstant OP_NBIT_XOR OP_NCMP OP_NCOMPLEMENT OP_NE OP_NEGATE +syn keyword xsConstant OP_NEXT OP_NEXTSTATE OP_NOT OP_NULL OP_OCT OP_ONCE +syn keyword xsConstant OP_OPEN OP_OPEN_DIR OP_OR OP_ORASSIGN OP_ORD OP_PACK +syn keyword xsConstant OP_PADANY OP_PADAV OP_PADCV OP_PADHV OP_PADRANGE +syn keyword xsConstant OP_PADSV OP_PIPE_OP OP_POP OP_POS OP_POSTDEC +syn keyword xsConstant OP_POSTINC OP_POW OP_PREDEC OP_PREINC OP_PRINT +syn keyword xsConstant OP_PROTOTYPE OP_PRTF OP_PUSH OP_PUSHMARK OP_PUSHRE +syn keyword xsConstant OP_QR OP_QUOTEMETA OP_RAND OP_RANGE OP_RCATLINE +syn keyword xsConstant OP_REACH OP_READ OP_READDIR OP_READLINE OP_READLINK +syn keyword xsConstant OP_RECV OP_REDO OP_REF OP_REFASSIGN OP_REFGEN +syn keyword xsConstant OP_REGCMAYBE OP_REGCOMP OP_REGCRESET OP_RENAME +syn keyword xsConstant OP_REPEAT OP_REQUIRE OP_RESET OP_RETURN OP_REVERSE +syn keyword xsConstant OP_REWINDDIR OP_RIGHT_SHIFT OP_RINDEX OP_RKEYS +syn keyword xsConstant OP_RMDIR OP_RUNCV OP_RV2AV OP_RV2CV OP_RV2GV OP_RV2HV +syn keyword xsConstant OP_RV2SV OP_RVALUES OP_SASSIGN OP_SAY OP_SBIT_AND +syn keyword xsConstant OP_SBIT_OR OP_SBIT_XOR OP_SCALAR OP_SCHOMP OP_SCHOP +syn keyword xsConstant OP_SCMP OP_SCOMPLEMENT OP_SCOPE OP_SEEK OP_SEEKDIR +syn keyword xsConstant OP_SELECT OP_SEMCTL OP_SEMGET OP_SEMOP OP_SEND OP_SEQ +syn keyword xsConstant OP_SETPGRP OP_SETPRIORITY OP_SGE OP_SGRENT OP_SGT +syn keyword xsConstant OP_SHIFT OP_SHMCTL OP_SHMGET OP_SHMREAD OP_SHMWRITE +syn keyword xsConstant OP_SHOSTENT OP_SHUTDOWN OP_SIN OP_SLE OP_SLEEP OP_SLT +syn keyword xsConstant OP_SMARTMATCH OP_SNE OP_SNETENT OP_SOCKET OP_SOCKPAIR +syn keyword xsConstant OP_SORT OP_SPLICE OP_SPLIT OP_SPRINTF OP_SPROTOENT +syn keyword xsConstant OP_SPWENT OP_SQRT OP_SRAND OP_SREFGEN OP_SSELECT +syn keyword xsConstant OP_SSERVENT OP_SSOCKOPT OP_STAT OP_STRINGIFY OP_STUB +syn keyword xsConstant OP_STUDY OP_SUBST OP_SUBSTCONT OP_SUBSTR OP_SUBTRACT +syn keyword xsConstant OP_SYMLINK OP_SYSCALL OP_SYSOPEN OP_SYSREAD OP_SYSSEEK +syn keyword xsConstant OP_SYSTEM OP_SYSWRITE OP_TELL OP_TELLDIR OP_TIE +syn keyword xsConstant OP_TIED OP_TIME OP_TMS OP_TRANS OP_TRANSR OP_TRUNCATE +syn keyword xsConstant OP_UC OP_UCFIRST OP_UMASK OP_UNDEF OP_UNLINK OP_UNPACK +syn keyword xsConstant OP_UNSHIFT OP_UNSTACK OP_UNTIE OP_UTIME OP_VALUES +syn keyword xsConstant OP_VEC OP_WAIT OP_WAITPID OP_WANTARRAY OP_WARN OP_XOR +syn keyword xsConstant OP_max OPf_FOLDED OPf_KIDS OPf_KNOW OPf_LIST OPf_MOD +syn keyword xsConstant OPf_PARENS OPf_REF OPf_SPECIAL OPf_STACKED OPf_WANT +syn keyword xsConstant OPf_WANT_LIST OPf_WANT_SCALAR OPf_WANT_VOID +syn keyword xsConstant OPpALLOW_FAKE OPpARG1_MASK OPpARG2_MASK OPpARG3_MASK +syn keyword xsConstant OPpARG4_MASK OPpASSIGN_BACKWARDS OPpASSIGN_COMMON +syn keyword xsConstant OPpASSIGN_CV_TO_GV OPpCONST_BARE OPpCONST_ENTERED +syn keyword xsConstant OPpCONST_NOVER OPpCONST_SHORTCIRCUIT OPpCONST_STRICT +syn keyword xsConstant OPpCOREARGS_DEREF1 OPpCOREARGS_DEREF2 +syn keyword xsConstant OPpCOREARGS_PUSHMARK OPpCOREARGS_SCALARMOD OPpDEREF +syn keyword xsConstant OPpDEREF_AV OPpDEREF_HV OPpDEREF_SV OPpDONT_INIT_GV +syn keyword xsConstant OPpEARLY_CV OPpENTERSUB_AMPER OPpENTERSUB_DB +syn keyword xsConstant OPpENTERSUB_HASTARG OPpENTERSUB_INARGS +syn keyword xsConstant OPpENTERSUB_LVAL_MASK OPpENTERSUB_NOPAREN +syn keyword xsConstant OPpEVAL_BYTES OPpEVAL_COPHH OPpEVAL_HAS_HH +syn keyword xsConstant OPpEVAL_RE_REPARSING OPpEVAL_UNICODE OPpEXISTS_SUB +syn keyword xsConstant OPpFLIP_LINENUM OPpFT_ACCESS OPpFT_AFTER_t +syn keyword xsConstant OPpFT_STACKED OPpFT_STACKING OPpGREP_LEX +syn keyword xsConstant OPpHINT_STRICT_REFS OPpHUSH_VMSISH OPpITER_DEF +syn keyword xsConstant OPpITER_REVERSED OPpLIST_GUESSED OPpLVALUE +syn keyword xsConstant OPpLVAL_DEFER OPpLVAL_INTRO OPpLVREF_AV OPpLVREF_CV +syn keyword xsConstant OPpLVREF_ELEM OPpLVREF_HV OPpLVREF_ITER OPpLVREF_SV +syn keyword xsConstant OPpLVREF_TYPE OPpMAYBE_LVSUB OPpMAYBE_TRUEBOOL +syn keyword xsConstant OPpMAY_RETURN_CONSTANT OPpMULTIDEREF_DELETE +syn keyword xsConstant OPpMULTIDEREF_EXISTS OPpOFFBYONE OPpOPEN_IN_CRLF +syn keyword xsConstant OPpOPEN_IN_RAW OPpOPEN_OUT_CRLF OPpOPEN_OUT_RAW +syn keyword xsConstant OPpOUR_INTRO OPpPADRANGE_COUNTMASK +syn keyword xsConstant OPpPADRANGE_COUNTSHIFT OPpPAD_STATE OPpPV_IS_UTF8 +syn keyword xsConstant OPpREFCOUNTED OPpREPEAT_DOLIST OPpREVERSE_INPLACE +syn keyword xsConstant OPpRUNTIME OPpSLICE OPpSLICEWARNING OPpSORT_DESCEND +syn keyword xsConstant OPpSORT_INPLACE OPpSORT_INTEGER OPpSORT_NUMERIC +syn keyword xsConstant OPpSORT_QSORT OPpSORT_REVERSE OPpSORT_STABLE +syn keyword xsConstant OPpSPLIT_IMPLIM OPpSUBSTR_REPL_FIRST OPpTARGET_MY +syn keyword xsConstant OPpTRANS_ALL OPpTRANS_COMPLEMENT OPpTRANS_DELETE +syn keyword xsConstant OPpTRANS_FROM_UTF OPpTRANS_GROWS OPpTRANS_IDENTICAL +syn keyword xsConstant OPpTRANS_SQUASH OPpTRANS_TO_UTF OPpTRUEBOOL +syn keyword xsConstant PERL_MAGIC_READONLY_ACCEPTABLE +syn keyword xsConstant PERL_MAGIC_TYPE_IS_VALUE_MAGIC +syn keyword xsConstant PERL_MAGIC_TYPE_READONLY_ACCEPTABLE +syn keyword xsConstant PERL_MAGIC_UTF8_CACHESIZE PERL_MAGIC_VALUE_MAGIC +syn keyword xsConstant PERL_MAGIC_VTABLE_MASK PERL_MAGIC_arylen +syn keyword xsConstant PERL_MAGIC_arylen_p PERL_MAGIC_backref PERL_MAGIC_bm +syn keyword xsConstant PERL_MAGIC_checkcall PERL_MAGIC_collxfrm +syn keyword xsConstant PERL_MAGIC_dbfile PERL_MAGIC_dbline +syn keyword xsConstant PERL_MAGIC_debugvar PERL_MAGIC_defelem PERL_MAGIC_env +syn keyword xsConstant PERL_MAGIC_envelem PERL_MAGIC_ext PERL_MAGIC_fm +syn keyword xsConstant PERL_MAGIC_hints PERL_MAGIC_hintselem PERL_MAGIC_isa +syn keyword xsConstant PERL_MAGIC_isaelem PERL_MAGIC_lvref PERL_MAGIC_nkeys +syn keyword xsConstant PERL_MAGIC_overload_table PERL_MAGIC_pos PERL_MAGIC_qr +syn keyword xsConstant PERL_MAGIC_regdata PERL_MAGIC_regdatum +syn keyword xsConstant PERL_MAGIC_regex_global PERL_MAGIC_rhash +syn keyword xsConstant PERL_MAGIC_shared PERL_MAGIC_shared_scalar +syn keyword xsConstant PERL_MAGIC_sig PERL_MAGIC_sigelem PERL_MAGIC_substr +syn keyword xsConstant PERL_MAGIC_sv PERL_MAGIC_symtab PERL_MAGIC_taint +syn keyword xsConstant PERL_MAGIC_tied PERL_MAGIC_tiedelem +syn keyword xsConstant PERL_MAGIC_tiedscalar PERL_MAGIC_utf8 PERL_MAGIC_uvar +syn keyword xsConstant PERL_MAGIC_uvar_elem PERL_MAGIC_vec PERL_MAGIC_vstring +syn keyword xsConstant REGEX_ASCII_MORE_RESTRICTED_CHARSET +syn keyword xsConstant REGEX_ASCII_RESTRICTED_CHARSET REGEX_DEPENDS_CHARSET +syn keyword xsConstant REGEX_LOCALE_CHARSET REGEX_UNICODE_CHARSET SB_ATerm +syn keyword xsConstant SB_BOUND SB_CR SB_Close SB_EDGE SB_Extend SB_Format +syn keyword xsConstant SB_LF SB_Lower SB_Numeric SB_OLetter SB_Other +syn keyword xsConstant SB_SContinue SB_STerm SB_Sep SB_Sp SB_Upper SVfARG +syn keyword xsConstant SVf_AMAGIC SVf_BREAK SVf_FAKE SVf_IOK SVf_IVisUV +syn keyword xsConstant SVf_IsCOW SVf_NOK SVf_OK SVf_OOK SVf_POK SVf_PROTECT +syn keyword xsConstant SVf_READONLY SVf_ROK SVf_THINKFIRST SVf_UTF8 SVp_IOK +syn keyword xsConstant SVp_NOK SVp_POK SVp_SCREAM SVpad_OUR SVpad_STATE +syn keyword xsConstant SVpad_TYPED SVpav_REAL SVpav_REIFY SVpbm_TAIL +syn keyword xsConstant SVpbm_VALID SVpgv_GP SVphv_CLONEABLE SVphv_HASKFLAGS +syn keyword xsConstant SVphv_LAZYDEL SVphv_SHAREKEYS SVprv_PCS_IMPORTED +syn keyword xsConstant SVprv_WEAKREF SVs_GMG SVs_OBJECT SVs_PADMY +syn keyword xsConstant SVs_PADSTALE SVs_PADTMP SVs_RMG SVs_SMG SVs_TEMP +syn keyword xsConstant SVt_INVLIST SVt_IV SVt_LAST SVt_NULL SVt_NV SVt_PV +syn keyword xsConstant SVt_PVAV SVt_PVBM SVt_PVCV SVt_PVFM SVt_PVGV SVt_PVHV +syn keyword xsConstant SVt_PVIO SVt_PVIV SVt_PVLV SVt_PVMG SVt_PVNV +syn keyword xsConstant SVt_REGEXP SVt_RV TRADITIONAL_BOUND WB_ALetter +syn keyword xsConstant WB_BOUND WB_CR WB_Double_Quote WB_EDGE WB_Extend +syn keyword xsConstant WB_ExtendNumLet WB_Format WB_Hebrew_Letter WB_Katakana +syn keyword xsConstant WB_LF WB_MidLetter WB_MidNum WB_MidNumLet WB_Newline +syn keyword xsConstant WB_Numeric WB_Other WB_Regional_Indicator +syn keyword xsConstant WB_Single_Quote WB_UNKNOWN XATTRBLOCK XATTRTERM XBLOCK +syn keyword xsConstant XBLOCKTERM XOPERATOR XOPe_xop_class XOPe_xop_desc +syn keyword xsConstant XOPe_xop_name XOPe_xop_peep XOPe_xop_ptr XPOSTDEREF +syn keyword xsConstant XREF XSTATE XTERM XTERMBLOCK XTERMORDORDOR +syn keyword xsConstant _CC_ENUM_ALPHA _CC_ENUM_ALPHANUMERIC _CC_ENUM_ASCII +syn keyword xsConstant _CC_ENUM_BLANK _CC_ENUM_CASED _CC_ENUM_CNTRL +syn keyword xsConstant _CC_ENUM_DIGIT _CC_ENUM_GRAPH _CC_ENUM_LOWER +syn keyword xsConstant _CC_ENUM_PRINT _CC_ENUM_PUNCT _CC_ENUM_SPACE +syn keyword xsConstant _CC_ENUM_UPPER _CC_ENUM_VERTSPACE _CC_ENUM_WORDCHAR +syn keyword xsConstant _CC_ENUM_XDIGIT padtidy_FORMAT padtidy_SUB +syn keyword xsConstant padtidy_SUBCLONE +syn keyword xsException XCPT_CATCH XCPT_RETHROW XCPT_TRY_END XCPT_TRY_START +syn keyword xsException dXCPT +syn keyword xsKeyword ALIAS: BOOT: CASE: CLEANUP: CODE: C_ARGS: DISABLE +syn keyword xsKeyword ENABLE FALLBACK: IN INCLUDE: INIT: INPUT: INTERFACE: +syn keyword xsKeyword INTERFACE_MACRO: IN_OUT IN_OUTLIST MODULE NO_INIT: +syn keyword xsKeyword NO_OUTPUT: OUT OUTLIST OUTPUT: OVERLOAD: PACKAGE +syn keyword xsKeyword POSTCALL: PPCODE: PREFIX PREINIT: PROTOTYPE: +syn keyword xsKeyword PROTOTYPES: REQUIRE: SCOPE: VERSIONCHECK: length +syn keyword xsFunction GetVars Gv_AMupdate PerlIO_clearerr PerlIO_close +syn keyword xsFunction PerlIO_eof PerlIO_error PerlIO_fileno PerlIO_fill +syn keyword xsFunction PerlIO_flush PerlIO_get_base PerlIO_get_bufsiz +syn keyword xsFunction PerlIO_get_cnt PerlIO_get_ptr PerlIO_read PerlIO_seek +syn keyword xsFunction PerlIO_set_cnt PerlIO_set_ptrcnt PerlIO_setlinebuf +syn keyword xsFunction PerlIO_stderr PerlIO_stdin PerlIO_stdout PerlIO_tell +syn keyword xsFunction PerlIO_unread PerlIO_write Perl_GetVars +syn keyword xsFunction Perl_Gv_AMupdate Perl_PerlIO_clearerr +syn keyword xsFunction Perl_PerlIO_close Perl_PerlIO_context_layers +syn keyword xsFunction Perl_PerlIO_eof Perl_PerlIO_error Perl_PerlIO_fileno +syn keyword xsFunction Perl_PerlIO_fill Perl_PerlIO_flush +syn keyword xsFunction Perl_PerlIO_get_base Perl_PerlIO_get_bufsiz +syn keyword xsFunction Perl_PerlIO_get_cnt Perl_PerlIO_get_ptr +syn keyword xsFunction Perl_PerlIO_read Perl_PerlIO_seek Perl_PerlIO_set_cnt +syn keyword xsFunction Perl_PerlIO_set_ptrcnt Perl_PerlIO_setlinebuf +syn keyword xsFunction Perl_PerlIO_stderr Perl_PerlIO_stdin +syn keyword xsFunction Perl_PerlIO_stdout Perl_PerlIO_tell Perl_PerlIO_unread +syn keyword xsFunction Perl_PerlIO_write Perl__get_regclass_nonbitmap_data +syn keyword xsFunction Perl__is_cur_LC_category_utf8 +syn keyword xsFunction Perl__is_in_locale_category Perl__is_uni_FOO +syn keyword xsFunction Perl__is_uni_perl_idcont Perl__is_uni_perl_idstart +syn keyword xsFunction Perl__is_utf8_FOO Perl__is_utf8_idcont +syn keyword xsFunction Perl__is_utf8_idstart Perl__is_utf8_mark +syn keyword xsFunction Perl__is_utf8_perl_idcont Perl__is_utf8_perl_idstart +syn keyword xsFunction Perl__is_utf8_xidcont Perl__is_utf8_xidstart +syn keyword xsFunction Perl__new_invlist_C_array Perl__to_uni_fold_flags +syn keyword xsFunction Perl__to_utf8_fold_flags Perl__to_utf8_lower_flags +syn keyword xsFunction Perl__to_utf8_title_flags Perl__to_utf8_upper_flags +syn keyword xsFunction Perl_alloccopstash Perl_amagic_call +syn keyword xsFunction Perl_amagic_deref_call Perl_any_dup +syn keyword xsFunction Perl_apply_attrs_string Perl_atfork_lock +syn keyword xsFunction Perl_atfork_unlock Perl_av_arylen_p Perl_av_clear +syn keyword xsFunction Perl_av_create_and_push Perl_av_create_and_unshift_one +syn keyword xsFunction Perl_av_delete Perl_av_exists Perl_av_extend +syn keyword xsFunction Perl_av_fetch Perl_av_fill Perl_av_iter_p Perl_av_len +syn keyword xsFunction Perl_av_make Perl_av_pop Perl_av_push Perl_av_shift +syn keyword xsFunction Perl_av_store Perl_av_undef Perl_av_unshift +syn keyword xsFunction Perl_block_end Perl_block_gimme Perl_block_start +syn keyword xsFunction Perl_blockhook_register Perl_bytes_cmp_utf8 +syn keyword xsFunction Perl_bytes_from_utf8 Perl_bytes_to_utf8 Perl_call_argv +syn keyword xsFunction Perl_call_atexit Perl_call_list Perl_call_method +syn keyword xsFunction Perl_call_pv Perl_call_sv Perl_caller_cx Perl_calloc +syn keyword xsFunction Perl_cast_i32 Perl_cast_iv Perl_cast_ulong +syn keyword xsFunction Perl_cast_uv Perl_ck_entersub_args_list +syn keyword xsFunction Perl_ck_entersub_args_proto +syn keyword xsFunction Perl_ck_entersub_args_proto_or_list Perl_ck_warner +syn keyword xsFunction Perl_ck_warner_d Perl_ckwarn Perl_ckwarn_d +syn keyword xsFunction Perl_clone_params_del Perl_clone_params_new +syn keyword xsFunction Perl_cop_fetch_label Perl_cop_store_label Perl_croak +syn keyword xsFunction Perl_croak_no_modify Perl_croak_nocontext +syn keyword xsFunction Perl_croak_sv Perl_croak_xs_usage Perl_csighandler +syn keyword xsFunction Perl_custom_op_desc Perl_custom_op_name +syn keyword xsFunction Perl_custom_op_register Perl_cv_clone Perl_cv_const_sv +syn keyword xsFunction Perl_cv_get_call_checker Perl_cv_name +syn keyword xsFunction Perl_cv_set_call_checker +syn keyword xsFunction Perl_cv_set_call_checker_flags Perl_cv_undef +syn keyword xsFunction Perl_cx_dump Perl_cx_dup Perl_cxinc Perl_deb +syn keyword xsFunction Perl_deb_nocontext Perl_debop Perl_debprofdump +syn keyword xsFunction Perl_debstack Perl_debstackptrs Perl_delimcpy +syn keyword xsFunction Perl_despatch_signals Perl_die Perl_die_nocontext +syn keyword xsFunction Perl_die_sv Perl_dirp_dup Perl_do_aspawn +syn keyword xsFunction Perl_do_binmode Perl_do_close Perl_do_gv_dump +syn keyword xsFunction Perl_do_gvgv_dump Perl_do_hv_dump Perl_do_join +syn keyword xsFunction Perl_do_magic_dump Perl_do_op_dump Perl_do_open9 +syn keyword xsFunction Perl_do_openn Perl_do_pmop_dump Perl_do_spawn +syn keyword xsFunction Perl_do_spawn_nowait Perl_do_sprintf Perl_do_sv_dump +syn keyword xsFunction Perl_doing_taint Perl_doref Perl_dounwind +syn keyword xsFunction Perl_dowantarray Perl_dump_all Perl_dump_c_backtrace +syn keyword xsFunction Perl_dump_eval Perl_dump_form Perl_dump_indent +syn keyword xsFunction Perl_dump_mstats Perl_dump_packsubs Perl_dump_sub +syn keyword xsFunction Perl_dump_vindent Perl_eval_pv Perl_eval_sv +syn keyword xsFunction Perl_fbm_compile Perl_fbm_instr Perl_filter_add +syn keyword xsFunction Perl_filter_del Perl_filter_read Perl_find_runcv +syn keyword xsFunction Perl_find_rundefsv Perl_foldEQ Perl_foldEQ_latin1 +syn keyword xsFunction Perl_foldEQ_locale Perl_foldEQ_utf8_flags Perl_form +syn keyword xsFunction Perl_form_nocontext Perl_fp_dup Perl_fprintf_nocontext +syn keyword xsFunction Perl_free_global_struct Perl_free_tmps Perl_get_av +syn keyword xsFunction Perl_get_c_backtrace_dump Perl_get_context Perl_get_cv +syn keyword xsFunction Perl_get_cvn_flags Perl_get_hv Perl_get_mstats +syn keyword xsFunction Perl_get_op_descs Perl_get_op_names Perl_get_ppaddr +syn keyword xsFunction Perl_get_sv Perl_get_vtbl Perl_getcwd_sv Perl_gp_dup +syn keyword xsFunction Perl_gp_free Perl_gp_ref Perl_grok_bin Perl_grok_hex +syn keyword xsFunction Perl_grok_infnan Perl_grok_number +syn keyword xsFunction Perl_grok_number_flags Perl_grok_numeric_radix +syn keyword xsFunction Perl_grok_oct Perl_gv_add_by_type Perl_gv_autoload_pv +syn keyword xsFunction Perl_gv_autoload_pvn Perl_gv_autoload_sv Perl_gv_check +syn keyword xsFunction Perl_gv_const_sv Perl_gv_dump Perl_gv_efullname +syn keyword xsFunction Perl_gv_efullname4 Perl_gv_fetchfile +syn keyword xsFunction Perl_gv_fetchfile_flags Perl_gv_fetchmeth_pv +syn keyword xsFunction Perl_gv_fetchmeth_pv_autoload Perl_gv_fetchmeth_pvn +syn keyword xsFunction Perl_gv_fetchmeth_pvn_autoload Perl_gv_fetchmeth_sv +syn keyword xsFunction Perl_gv_fetchmeth_sv_autoload +syn keyword xsFunction Perl_gv_fetchmethod_autoload +syn keyword xsFunction Perl_gv_fetchmethod_pv_flags +syn keyword xsFunction Perl_gv_fetchmethod_pvn_flags +syn keyword xsFunction Perl_gv_fetchmethod_sv_flags Perl_gv_fetchpv +syn keyword xsFunction Perl_gv_fetchpvn_flags Perl_gv_fetchsv +syn keyword xsFunction Perl_gv_fullname Perl_gv_fullname4 Perl_gv_handler +syn keyword xsFunction Perl_gv_init_pv Perl_gv_init_pvn Perl_gv_init_sv +syn keyword xsFunction Perl_gv_name_set Perl_gv_stashpv Perl_gv_stashpvn +syn keyword xsFunction Perl_gv_stashsv Perl_he_dup Perl_hek_dup +syn keyword xsFunction Perl_hv_assert Perl_hv_clear +syn keyword xsFunction Perl_hv_clear_placeholders Perl_hv_common +syn keyword xsFunction Perl_hv_common_key_len Perl_hv_copy_hints_hv +syn keyword xsFunction Perl_hv_delayfree_ent Perl_hv_eiter_p +syn keyword xsFunction Perl_hv_eiter_set Perl_hv_fill Perl_hv_free_ent +syn keyword xsFunction Perl_hv_iterinit Perl_hv_iterkey Perl_hv_iterkeysv +syn keyword xsFunction Perl_hv_iternext_flags Perl_hv_iternextsv +syn keyword xsFunction Perl_hv_iterval Perl_hv_ksplit Perl_hv_name_set +syn keyword xsFunction Perl_hv_placeholders_get Perl_hv_placeholders_set +syn keyword xsFunction Perl_hv_rand_set Perl_hv_riter_p Perl_hv_riter_set +syn keyword xsFunction Perl_hv_scalar Perl_init_global_struct +syn keyword xsFunction Perl_init_i18nl10n Perl_init_i18nl14n Perl_init_stacks +syn keyword xsFunction Perl_init_tm Perl_instr Perl_intro_my +syn keyword xsFunction Perl_is_invariant_string Perl_is_lvalue_sub +syn keyword xsFunction Perl_is_utf8_string Perl_is_utf8_string_loclen +syn keyword xsFunction Perl_isinfnan Perl_leave_scope Perl_lex_bufutf8 +syn keyword xsFunction Perl_lex_discard_to Perl_lex_grow_linestr +syn keyword xsFunction Perl_lex_next_chunk Perl_lex_peek_unichar +syn keyword xsFunction Perl_lex_read_space Perl_lex_read_to +syn keyword xsFunction Perl_lex_read_unichar Perl_lex_start Perl_lex_stuff_pv +syn keyword xsFunction Perl_lex_stuff_pvn Perl_lex_stuff_sv Perl_lex_unstuff +syn keyword xsFunction Perl_load_module Perl_load_module_nocontext +syn keyword xsFunction Perl_looks_like_number Perl_magic_dump Perl_malloc +syn keyword xsFunction Perl_markstack_grow Perl_mess Perl_mess_nocontext +syn keyword xsFunction Perl_mess_sv Perl_mfree Perl_mg_clear Perl_mg_copy +syn keyword xsFunction Perl_mg_dup Perl_mg_find Perl_mg_findext Perl_mg_free +syn keyword xsFunction Perl_mg_free_type Perl_mg_get Perl_mg_magical +syn keyword xsFunction Perl_mg_set Perl_mg_size Perl_mini_mktime +syn keyword xsFunction Perl_moreswitches Perl_mro_get_from_name +syn keyword xsFunction Perl_mro_get_linear_isa Perl_mro_get_private_data +syn keyword xsFunction Perl_mro_method_changed_in Perl_mro_register +syn keyword xsFunction Perl_mro_set_mro Perl_mro_set_private_data +syn keyword xsFunction Perl_my_atof Perl_my_atof2 Perl_my_bcopy Perl_my_bzero +syn keyword xsFunction Perl_my_chsize Perl_my_cxt_index Perl_my_cxt_init +syn keyword xsFunction Perl_my_dirfd Perl_my_exit Perl_my_failure_exit +syn keyword xsFunction Perl_my_fflush_all Perl_my_fork Perl_my_memcmp +syn keyword xsFunction Perl_my_memset Perl_my_pclose Perl_my_popen +syn keyword xsFunction Perl_my_popen_list Perl_my_setenv Perl_my_setlocale +syn keyword xsFunction Perl_my_snprintf Perl_my_socketpair Perl_my_sprintf +syn keyword xsFunction Perl_my_strerror Perl_my_strftime Perl_my_strlcat +syn keyword xsFunction Perl_my_strlcpy Perl_my_vsnprintf Perl_newANONATTRSUB +syn keyword xsFunction Perl_newANONHASH Perl_newANONLIST Perl_newANONSUB +syn keyword xsFunction Perl_newASSIGNOP Perl_newAVREF Perl_newBINOP +syn keyword xsFunction Perl_newCONDOP Perl_newCONSTSUB Perl_newCONSTSUB_flags +syn keyword xsFunction Perl_newCVREF Perl_newDEFSVOP Perl_newFORM +syn keyword xsFunction Perl_newFOROP Perl_newGIVENOP Perl_newGVOP +syn keyword xsFunction Perl_newGVREF Perl_newGVgen_flags Perl_newHVREF +syn keyword xsFunction Perl_newHVhv Perl_newLISTOP Perl_newLOGOP +syn keyword xsFunction Perl_newLOOPEX Perl_newLOOPOP Perl_newMETHOP +syn keyword xsFunction Perl_newMETHOP_named Perl_newMYSUB Perl_newNULLLIST +syn keyword xsFunction Perl_newOP Perl_newPADNAMELIST Perl_newPADNAMEouter +syn keyword xsFunction Perl_newPADNAMEpvn Perl_newPADOP Perl_newPMOP +syn keyword xsFunction Perl_newPROG Perl_newPVOP Perl_newRANGE Perl_newRV +syn keyword xsFunction Perl_newRV_noinc Perl_newSLICEOP Perl_newSTATEOP +syn keyword xsFunction Perl_newSV Perl_newSVOP Perl_newSVREF Perl_newSV_type +syn keyword xsFunction Perl_newSVhek Perl_newSViv Perl_newSVnv Perl_newSVpv +syn keyword xsFunction Perl_newSVpv_share Perl_newSVpvf +syn keyword xsFunction Perl_newSVpvf_nocontext Perl_newSVpvn +syn keyword xsFunction Perl_newSVpvn_flags Perl_newSVpvn_share Perl_newSVrv +syn keyword xsFunction Perl_newSVsv Perl_newSVuv Perl_newUNOP +syn keyword xsFunction Perl_newUNOP_AUX Perl_newWHENOP Perl_newWHILEOP +syn keyword xsFunction Perl_newXS Perl_newXS_flags Perl_new_collate +syn keyword xsFunction Perl_new_ctype Perl_new_numeric Perl_new_stackinfo +syn keyword xsFunction Perl_new_version Perl_ninstr Perl_nothreadhook +syn keyword xsFunction Perl_op_append_elem Perl_op_append_list +syn keyword xsFunction Perl_op_contextualize Perl_op_convert_list +syn keyword xsFunction Perl_op_dump Perl_op_free Perl_op_linklist +syn keyword xsFunction Perl_op_null Perl_op_parent Perl_op_prepend_elem +syn keyword xsFunction Perl_op_refcnt_lock Perl_op_refcnt_unlock +syn keyword xsFunction Perl_op_scope Perl_op_sibling_splice Perl_pack_cat +syn keyword xsFunction Perl_packlist Perl_pad_add_anon Perl_pad_add_name_pv +syn keyword xsFunction Perl_pad_add_name_pvn Perl_pad_add_name_sv +syn keyword xsFunction Perl_pad_alloc Perl_pad_compname_type +syn keyword xsFunction Perl_pad_findmy_pv Perl_pad_findmy_pvn +syn keyword xsFunction Perl_pad_findmy_sv Perl_pad_new Perl_pad_setsv +syn keyword xsFunction Perl_pad_sv Perl_pad_tidy Perl_padnamelist_fetch +syn keyword xsFunction Perl_padnamelist_store Perl_parse_arithexpr +syn keyword xsFunction Perl_parse_barestmt Perl_parse_block +syn keyword xsFunction Perl_parse_fullexpr Perl_parse_fullstmt +syn keyword xsFunction Perl_parse_label Perl_parse_listexpr +syn keyword xsFunction Perl_parse_stmtseq Perl_parse_termexpr Perl_parser_dup +syn keyword xsFunction Perl_pmop_dump Perl_pop_scope Perl_pregcomp +syn keyword xsFunction Perl_pregexec Perl_pregfree Perl_pregfree2 +syn keyword xsFunction Perl_prescan_version Perl_printf_nocontext +syn keyword xsFunction Perl_ptr_table_fetch Perl_ptr_table_free +syn keyword xsFunction Perl_ptr_table_new Perl_ptr_table_split +syn keyword xsFunction Perl_ptr_table_store Perl_push_scope Perl_pv_display +syn keyword xsFunction Perl_pv_escape Perl_pv_pretty Perl_pv_uni_display +syn keyword xsFunction Perl_quadmath_format_needed +syn keyword xsFunction Perl_quadmath_format_single Perl_re_compile +syn keyword xsFunction Perl_re_dup_guts Perl_re_intuit_start +syn keyword xsFunction Perl_re_intuit_string Perl_realloc Perl_reentrant_free +syn keyword xsFunction Perl_reentrant_init Perl_reentrant_retry +syn keyword xsFunction Perl_reentrant_size Perl_reg_named_buff_all +syn keyword xsFunction Perl_reg_named_buff_exists Perl_reg_named_buff_fetch +syn keyword xsFunction Perl_reg_named_buff_firstkey +syn keyword xsFunction Perl_reg_named_buff_nextkey Perl_reg_named_buff_scalar +syn keyword xsFunction Perl_regclass_swash Perl_regdump Perl_regdupe_internal +syn keyword xsFunction Perl_regexec_flags Perl_regfree_internal +syn keyword xsFunction Perl_reginitcolors Perl_regnext Perl_repeatcpy +syn keyword xsFunction Perl_require_pv Perl_rninstr Perl_rsignal +syn keyword xsFunction Perl_rsignal_state Perl_runops_debug +syn keyword xsFunction Perl_runops_standard Perl_rv2cv_op_cv Perl_rvpv_dup +syn keyword xsFunction Perl_safesyscalloc Perl_safesysfree Perl_safesysmalloc +syn keyword xsFunction Perl_safesysrealloc Perl_save_I16 Perl_save_I32 +syn keyword xsFunction Perl_save_I8 Perl_save_adelete Perl_save_aelem_flags +syn keyword xsFunction Perl_save_alloc Perl_save_aptr Perl_save_ary +syn keyword xsFunction Perl_save_bool Perl_save_clearsv Perl_save_delete +syn keyword xsFunction Perl_save_destructor Perl_save_destructor_x +syn keyword xsFunction Perl_save_generic_pvref Perl_save_generic_svref +syn keyword xsFunction Perl_save_gp Perl_save_hash Perl_save_hdelete +syn keyword xsFunction Perl_save_helem_flags Perl_save_hints Perl_save_hptr +syn keyword xsFunction Perl_save_int Perl_save_item Perl_save_iv +syn keyword xsFunction Perl_save_list Perl_save_long Perl_save_nogv +syn keyword xsFunction Perl_save_padsv_and_mortalize Perl_save_pptr +syn keyword xsFunction Perl_save_pushi32ptr Perl_save_pushptr +syn keyword xsFunction Perl_save_pushptrptr Perl_save_re_context +syn keyword xsFunction Perl_save_scalar Perl_save_set_svflags +syn keyword xsFunction Perl_save_shared_pvref Perl_save_sptr Perl_save_svref +syn keyword xsFunction Perl_save_vptr Perl_savepv Perl_savepvn +syn keyword xsFunction Perl_savesharedpv Perl_savesharedpvn +syn keyword xsFunction Perl_savesharedsvpv Perl_savestack_grow +syn keyword xsFunction Perl_savestack_grow_cnt Perl_savesvpv Perl_scan_bin +syn keyword xsFunction Perl_scan_hex Perl_scan_num Perl_scan_oct +syn keyword xsFunction Perl_scan_version Perl_scan_vstring Perl_seed +syn keyword xsFunction Perl_set_context Perl_set_numeric_local +syn keyword xsFunction Perl_set_numeric_radix Perl_set_numeric_standard +syn keyword xsFunction Perl_setdefout Perl_share_hek Perl_si_dup Perl_sortsv +syn keyword xsFunction Perl_sortsv_flags Perl_ss_dup Perl_stack_grow +syn keyword xsFunction Perl_start_subparse Perl_str_to_version +syn keyword xsFunction Perl_sv_2bool_flags Perl_sv_2cv Perl_sv_2io +syn keyword xsFunction Perl_sv_2iv_flags Perl_sv_2mortal Perl_sv_2nv_flags +syn keyword xsFunction Perl_sv_2pv_flags Perl_sv_2pvbyte Perl_sv_2pvutf8 +syn keyword xsFunction Perl_sv_2uv_flags Perl_sv_backoff Perl_sv_bless +syn keyword xsFunction Perl_sv_cat_decode Perl_sv_catpv Perl_sv_catpv_flags +syn keyword xsFunction Perl_sv_catpv_mg Perl_sv_catpvf Perl_sv_catpvf_mg +syn keyword xsFunction Perl_sv_catpvf_mg_nocontext Perl_sv_catpvf_nocontext +syn keyword xsFunction Perl_sv_catpvn_flags Perl_sv_catsv_flags Perl_sv_chop +syn keyword xsFunction Perl_sv_clear Perl_sv_cmp Perl_sv_cmp_flags +syn keyword xsFunction Perl_sv_cmp_locale Perl_sv_cmp_locale_flags +syn keyword xsFunction Perl_sv_collxfrm_flags Perl_sv_copypv_flags +syn keyword xsFunction Perl_sv_dec Perl_sv_dec_nomg Perl_sv_derived_from +syn keyword xsFunction Perl_sv_derived_from_pv Perl_sv_derived_from_pvn +syn keyword xsFunction Perl_sv_derived_from_sv Perl_sv_destroyable +syn keyword xsFunction Perl_sv_does Perl_sv_does_pv Perl_sv_does_pvn +syn keyword xsFunction Perl_sv_does_sv Perl_sv_dump Perl_sv_dup +syn keyword xsFunction Perl_sv_dup_inc Perl_sv_eq_flags +syn keyword xsFunction Perl_sv_force_normal_flags Perl_sv_free +syn keyword xsFunction Perl_sv_get_backrefs Perl_sv_gets Perl_sv_grow +syn keyword xsFunction Perl_sv_inc Perl_sv_inc_nomg Perl_sv_insert_flags +syn keyword xsFunction Perl_sv_isa Perl_sv_isobject Perl_sv_iv Perl_sv_len +syn keyword xsFunction Perl_sv_len_utf8 Perl_sv_magic Perl_sv_magicext +syn keyword xsFunction Perl_sv_newmortal Perl_sv_newref Perl_sv_nosharing +syn keyword xsFunction Perl_sv_nounlocking Perl_sv_nv Perl_sv_peek +syn keyword xsFunction Perl_sv_pos_b2u Perl_sv_pos_b2u_flags Perl_sv_pos_u2b +syn keyword xsFunction Perl_sv_pos_u2b_flags Perl_sv_pvbyten +syn keyword xsFunction Perl_sv_pvbyten_force Perl_sv_pvn +syn keyword xsFunction Perl_sv_pvn_force_flags Perl_sv_pvn_nomg +syn keyword xsFunction Perl_sv_pvutf8n Perl_sv_pvutf8n_force +syn keyword xsFunction Perl_sv_recode_to_utf8 Perl_sv_reftype Perl_sv_replace +syn keyword xsFunction Perl_sv_report_used Perl_sv_reset Perl_sv_rvweaken +syn keyword xsFunction Perl_sv_setiv Perl_sv_setiv_mg Perl_sv_setnv +syn keyword xsFunction Perl_sv_setnv_mg Perl_sv_setpv Perl_sv_setpv_mg +syn keyword xsFunction Perl_sv_setpvf Perl_sv_setpvf_mg +syn keyword xsFunction Perl_sv_setpvf_mg_nocontext Perl_sv_setpvf_nocontext +syn keyword xsFunction Perl_sv_setpviv Perl_sv_setpviv_mg Perl_sv_setpvn +syn keyword xsFunction Perl_sv_setpvn_mg Perl_sv_setref_iv Perl_sv_setref_nv +syn keyword xsFunction Perl_sv_setref_pv Perl_sv_setref_pvn Perl_sv_setref_uv +syn keyword xsFunction Perl_sv_setsv_flags Perl_sv_setsv_mg Perl_sv_setuv +syn keyword xsFunction Perl_sv_setuv_mg Perl_sv_tainted Perl_sv_true +syn keyword xsFunction Perl_sv_uni_display Perl_sv_unmagic Perl_sv_unmagicext +syn keyword xsFunction Perl_sv_unref_flags Perl_sv_untaint Perl_sv_upgrade +syn keyword xsFunction Perl_sv_usepvn_flags Perl_sv_utf8_decode +syn keyword xsFunction Perl_sv_utf8_downgrade Perl_sv_utf8_encode +syn keyword xsFunction Perl_sv_utf8_upgrade_flags_grow Perl_sv_uv +syn keyword xsFunction Perl_sv_vcatpvf Perl_sv_vcatpvf_mg Perl_sv_vcatpvfn +syn keyword xsFunction Perl_sv_vcatpvfn_flags Perl_sv_vsetpvf +syn keyword xsFunction Perl_sv_vsetpvf_mg Perl_sv_vsetpvfn Perl_swash_fetch +syn keyword xsFunction Perl_swash_init Perl_sync_locale Perl_sys_init +syn keyword xsFunction Perl_sys_init3 Perl_sys_intern_clear +syn keyword xsFunction Perl_sys_intern_dup Perl_sys_intern_init Perl_sys_term +syn keyword xsFunction Perl_taint_env Perl_taint_proper Perl_to_uni_lower +syn keyword xsFunction Perl_to_uni_title Perl_to_uni_upper Perl_to_utf8_case +syn keyword xsFunction Perl_unlnk Perl_unpack_str Perl_unpackstring +syn keyword xsFunction Perl_unsharepvn Perl_upg_version Perl_utf16_to_utf8 +syn keyword xsFunction Perl_utf16_to_utf8_reversed Perl_utf8_distance +syn keyword xsFunction Perl_utf8_hop Perl_utf8_length Perl_utf8_to_bytes +syn keyword xsFunction Perl_utf8n_to_uvchr Perl_utf8n_to_uvuni +syn keyword xsFunction Perl_uvoffuni_to_utf8_flags Perl_uvuni_to_utf8 +syn keyword xsFunction Perl_uvuni_to_utf8_flags Perl_valid_utf8_to_uvchr +syn keyword xsFunction Perl_vcmp Perl_vcroak Perl_vdeb Perl_vform +syn keyword xsFunction Perl_vload_module Perl_vmess Perl_vnewSVpvf +syn keyword xsFunction Perl_vnormal Perl_vnumify Perl_vstringify Perl_vverify +syn keyword xsFunction Perl_vwarn Perl_vwarner Perl_warn Perl_warn_nocontext +syn keyword xsFunction Perl_warn_sv Perl_warner Perl_warner_nocontext +syn keyword xsFunction Perl_whichsig_pv Perl_whichsig_pvn Perl_whichsig_sv +syn keyword xsFunction Perl_wrap_op_checker _get_regclass_nonbitmap_data +syn keyword xsFunction _is_cur_LC_category_utf8 _is_in_locale_category +syn keyword xsFunction _is_uni_FOO _is_uni_perl_idcont _is_uni_perl_idstart +syn keyword xsFunction _is_utf8_FOO _is_utf8_char_slow _is_utf8_idcont +syn keyword xsFunction _is_utf8_idstart _is_utf8_mark _is_utf8_perl_idcont +syn keyword xsFunction _is_utf8_perl_idstart _is_utf8_xidcont +syn keyword xsFunction _is_utf8_xidstart _new_invlist_C_array +syn keyword xsFunction _to_uni_fold_flags _to_utf8_fold_flags +syn keyword xsFunction _to_utf8_lower_flags _to_utf8_title_flags +syn keyword xsFunction _to_utf8_upper_flags alloccopstash amagic_call +syn keyword xsFunction amagic_deref_call any_dup append_utf8_from_native_byte +syn keyword xsFunction apply_attrs_string atfork_lock atfork_unlock av_clear +syn keyword xsFunction av_delete av_exists av_extend av_fetch av_fill av_len +syn keyword xsFunction av_make av_pop av_push av_shift av_store av_top_index +syn keyword xsFunction av_undef av_unshift block_end block_gimme block_start +syn keyword xsFunction bytes_cmp_utf8 bytes_from_utf8 bytes_to_utf8 call_argv +syn keyword xsFunction call_atexit call_list call_method call_pv call_sv +syn keyword xsFunction caller_cx cast_i32 cast_iv cast_ulong cast_uv +syn keyword xsFunction ck_entersub_args_list ck_entersub_args_proto +syn keyword xsFunction ck_entersub_args_proto_or_list ck_warner ck_warner_d +syn keyword xsFunction croak croak_memory_wrap croak_no_modify +syn keyword xsFunction croak_nocontext croak_sv croak_xs_usage csighandler +syn keyword xsFunction custom_op_desc custom_op_name cv_clone cv_const_sv +syn keyword xsFunction cv_get_call_checker cv_name cv_set_call_checker +syn keyword xsFunction cv_set_call_checker_flags cv_undef cx_dump cx_dup +syn keyword xsFunction cxinc deb deb_nocontext debop debprofdump debstack +syn keyword xsFunction debstackptrs delimcpy despatch_signals die +syn keyword xsFunction die_nocontext die_sv dirp_dup do_aspawn do_binmode +syn keyword xsFunction do_close do_gv_dump do_gvgv_dump do_hv_dump do_join +syn keyword xsFunction do_magic_dump do_op_dump do_open9 do_openn +syn keyword xsFunction do_pmop_dump do_spawn do_spawn_nowait do_sprintf +syn keyword xsFunction do_sv_dump doing_taint doref dounwind dowantarray +syn keyword xsFunction dump_all dump_c_backtrace dump_eval dump_form +syn keyword xsFunction dump_indent dump_mstats dump_packsubs dump_sub +syn keyword xsFunction dump_vindent eval_pv eval_sv fbm_compile fbm_instr +syn keyword xsFunction filter_add filter_del filter_read find_runcv +syn keyword xsFunction find_rundefsv foldEQ foldEQ_latin1 foldEQ_locale +syn keyword xsFunction foldEQ_utf8_flags form form_nocontext fp_dup +syn keyword xsFunction fprintf_nocontext free_global_struct free_tmps get_av +syn keyword xsFunction get_c_backtrace_dump get_context get_cv get_cvn_flags +syn keyword xsFunction get_hv get_mstats get_op_descs get_op_names get_ppaddr +syn keyword xsFunction get_sv get_vtbl getcwd_sv gp_dup gp_free gp_ref +syn keyword xsFunction grok_bin grok_hex grok_infnan grok_number +syn keyword xsFunction grok_number_flags grok_numeric_radix grok_oct +syn keyword xsFunction gv_add_by_type gv_autoload_pv gv_autoload_pvn +syn keyword xsFunction gv_autoload_sv gv_check gv_const_sv gv_dump +syn keyword xsFunction gv_efullname gv_efullname4 gv_fetchfile +syn keyword xsFunction gv_fetchfile_flags gv_fetchmeth_pv +syn keyword xsFunction gv_fetchmeth_pv_autoload gv_fetchmeth_pvn +syn keyword xsFunction gv_fetchmeth_pvn_autoload gv_fetchmeth_sv +syn keyword xsFunction gv_fetchmeth_sv_autoload gv_fetchmethod_autoload +syn keyword xsFunction gv_fetchmethod_pv_flags gv_fetchmethod_pvn_flags +syn keyword xsFunction gv_fetchmethod_sv_flags gv_fetchpv gv_fetchpvn_flags +syn keyword xsFunction gv_fetchsv gv_fullname gv_fullname4 gv_handler +syn keyword xsFunction gv_init_pv gv_init_pvn gv_init_sv gv_name_set +syn keyword xsFunction gv_stashpv gv_stashpvn gv_stashsv he_dup hek_dup +syn keyword xsFunction hv_clear hv_clear_placeholders hv_common +syn keyword xsFunction hv_common_key_len hv_copy_hints_hv hv_delayfree_ent +syn keyword xsFunction hv_free_ent hv_iterinit hv_iterkey hv_iterkeysv +syn keyword xsFunction hv_iternext_flags hv_iternextsv hv_iterval hv_ksplit +syn keyword xsFunction hv_name_set hv_rand_set hv_scalar init_global_struct +syn keyword xsFunction init_i18nl10n init_i18nl14n init_stacks init_tm instr +syn keyword xsFunction intro_my is_invariant_string is_lvalue_sub +syn keyword xsFunction is_safe_syscall is_utf8_string is_utf8_string_loclen +syn keyword xsFunction isinfnan leave_scope lex_bufutf8 lex_discard_to +syn keyword xsFunction lex_grow_linestr lex_next_chunk lex_peek_unichar +syn keyword xsFunction lex_read_space lex_read_to lex_read_unichar lex_start +syn keyword xsFunction lex_stuff_pv lex_stuff_pvn lex_stuff_sv lex_unstuff +syn keyword xsFunction load_module load_module_nocontext looks_like_number +syn keyword xsFunction magic_dump markstack_grow mess mess_nocontext mess_sv +syn keyword xsFunction mg_clear mg_copy mg_dup mg_find mg_findext mg_free +syn keyword xsFunction mg_free_type mg_get mg_magical mg_set mg_size +syn keyword xsFunction mini_mktime moreswitches mro_get_linear_isa +syn keyword xsFunction mro_method_changed_in my_atof my_atof2 my_bcopy +syn keyword xsFunction my_bzero my_chsize my_dirfd my_exit my_failure_exit +syn keyword xsFunction my_fflush_all my_fork my_memcmp my_memset my_pclose +syn keyword xsFunction my_popen my_popen_list my_setenv my_setlocale +syn keyword xsFunction my_socketpair my_strerror my_strftime newANONATTRSUB +syn keyword xsFunction newANONHASH newANONLIST newANONSUB newASSIGNOP +syn keyword xsFunction newAVREF newBINOP newCONDOP newCONSTSUB +syn keyword xsFunction newCONSTSUB_flags newCVREF newDEFSVOP newFORM newFOROP +syn keyword xsFunction newGIVENOP newGVOP newGVREF newGVgen_flags newHVREF +syn keyword xsFunction newHVhv newLISTOP newLOGOP newLOOPEX newLOOPOP +syn keyword xsFunction newMETHOP newMETHOP_named newMYSUB newNULLLIST newOP +syn keyword xsFunction newPADNAMELIST newPADNAMEouter newPADNAMEpvn newPADOP +syn keyword xsFunction newPMOP newPROG newPVOP newRANGE newRV newRV_noinc +syn keyword xsFunction newSLICEOP newSTATEOP newSV newSVOP newSVREF +syn keyword xsFunction newSV_type newSVhek newSViv newSVnv newSVpv +syn keyword xsFunction newSVpv_share newSVpvf newSVpvf_nocontext newSVpvn +syn keyword xsFunction newSVpvn_flags newSVpvn_share newSVrv newSVsv newSVuv +syn keyword xsFunction newUNOP newUNOP_AUX newWHENOP newWHILEOP newXS +syn keyword xsFunction newXS_flags new_collate new_ctype new_numeric +syn keyword xsFunction new_stackinfo new_version ninstr nothreadhook +syn keyword xsFunction op_append_elem op_append_list op_contextualize +syn keyword xsFunction op_convert_list op_dump op_free op_linklist op_null +syn keyword xsFunction op_parent op_prepend_elem op_refcnt_lock +syn keyword xsFunction op_refcnt_unlock op_scope op_sibling_splice pack_cat +syn keyword xsFunction packlist pad_add_anon pad_add_name_pv pad_add_name_pvn +syn keyword xsFunction pad_add_name_sv pad_alloc pad_compname_type +syn keyword xsFunction pad_findmy_pv pad_findmy_pvn pad_findmy_sv pad_new +syn keyword xsFunction pad_setsv pad_sv pad_tidy padnamelist_fetch +syn keyword xsFunction padnamelist_store parse_arithexpr parse_barestmt +syn keyword xsFunction parse_block parse_fullexpr parse_fullstmt parse_label +syn keyword xsFunction parse_listexpr parse_stmtseq parse_termexpr parser_dup +syn keyword xsFunction pmop_dump pop_scope pregcomp pregexec pregfree +syn keyword xsFunction pregfree2 prescan_version printf_nocontext +syn keyword xsFunction ptr_table_fetch ptr_table_free ptr_table_new +syn keyword xsFunction ptr_table_split ptr_table_store push_scope pv_display +syn keyword xsFunction pv_escape pv_pretty pv_uni_display +syn keyword xsFunction quadmath_format_needed quadmath_format_single +syn keyword xsFunction re_compile re_dup_guts re_intuit_start +syn keyword xsFunction re_intuit_string reentrant_free reentrant_init +syn keyword xsFunction reentrant_retry reentrant_size reg_named_buff_all +syn keyword xsFunction reg_named_buff_exists reg_named_buff_fetch +syn keyword xsFunction reg_named_buff_firstkey reg_named_buff_nextkey +syn keyword xsFunction reg_named_buff_scalar regclass_swash regdump +syn keyword xsFunction regdupe_internal regexec_flags regfree_internal +syn keyword xsFunction reginitcolors regnext repeatcpy require_pv rninstr +syn keyword xsFunction rsignal rsignal_state runops_debug runops_standard +syn keyword xsFunction rv2cv_op_cv rvpv_dup safesyscalloc safesysfree +syn keyword xsFunction safesysmalloc safesysrealloc save_I16 save_I32 save_I8 +syn keyword xsFunction save_adelete save_aelem_flags save_alloc save_aptr +syn keyword xsFunction save_ary save_bool save_clearsv save_delete +syn keyword xsFunction save_destructor save_destructor_x save_generic_pvref +syn keyword xsFunction save_generic_svref save_gp save_hash save_hdelete +syn keyword xsFunction save_helem_flags save_hints save_hptr save_int +syn keyword xsFunction save_item save_iv save_list save_long save_nogv +syn keyword xsFunction save_padsv_and_mortalize save_pptr save_pushi32ptr +syn keyword xsFunction save_pushptr save_pushptrptr save_re_context +syn keyword xsFunction save_scalar save_set_svflags save_shared_pvref +syn keyword xsFunction save_sptr save_svref save_vptr savepv savepvn +syn keyword xsFunction savesharedpv savesharedpvn savesharedsvpv +syn keyword xsFunction savestack_grow savestack_grow_cnt savesvpv scan_bin +syn keyword xsFunction scan_hex scan_num scan_oct scan_version scan_vstring +syn keyword xsFunction seed set_context set_numeric_local set_numeric_radix +syn keyword xsFunction set_numeric_standard setdefout share_hek si_dup sortsv +syn keyword xsFunction sortsv_flags ss_dup stack_grow start_subparse +syn keyword xsFunction str_to_version sv_2bool_flags sv_2cv sv_2io +syn keyword xsFunction sv_2iv_flags sv_2mortal sv_2nv_flags sv_2pv_flags +syn keyword xsFunction sv_2pvbyte sv_2pvutf8 sv_2uv_flags sv_backoff sv_bless +syn keyword xsFunction sv_cat_decode sv_catpv sv_catpv_flags sv_catpv_mg +syn keyword xsFunction sv_catpvf sv_catpvf_mg sv_catpvf_mg_nocontext +syn keyword xsFunction sv_catpvf_nocontext sv_catpvn_flags sv_catsv_flags +syn keyword xsFunction sv_chop sv_clear sv_cmp_flags sv_cmp_locale_flags +syn keyword xsFunction sv_collxfrm_flags sv_copypv_flags sv_dec sv_dec_nomg +syn keyword xsFunction sv_derived_from sv_derived_from_pv sv_derived_from_pvn +syn keyword xsFunction sv_derived_from_sv sv_destroyable sv_does sv_does_pv +syn keyword xsFunction sv_does_pvn sv_does_sv sv_dump sv_dup sv_dup_inc +syn keyword xsFunction sv_eq_flags sv_force_normal_flags sv_free +syn keyword xsFunction sv_get_backrefs sv_gets sv_grow sv_inc sv_inc_nomg +syn keyword xsFunction sv_insert_flags sv_isa sv_isobject sv_iv sv_len +syn keyword xsFunction sv_len_utf8 sv_magic sv_magicext sv_newmortal +syn keyword xsFunction sv_newref sv_nosharing sv_nounlocking sv_nv sv_peek +syn keyword xsFunction sv_pos_b2u sv_pos_b2u_flags sv_pos_u2b +syn keyword xsFunction sv_pos_u2b_flags sv_pvbyten sv_pvbyten_force sv_pvn +syn keyword xsFunction sv_pvn_force_flags sv_pvn_nomg sv_pvutf8n +syn keyword xsFunction sv_pvutf8n_force sv_recode_to_utf8 sv_reftype +syn keyword xsFunction sv_replace sv_report_used sv_reset sv_rvweaken +syn keyword xsFunction sv_setiv sv_setiv_mg sv_setnv sv_setnv_mg sv_setpv +syn keyword xsFunction sv_setpv_mg sv_setpvf sv_setpvf_mg +syn keyword xsFunction sv_setpvf_mg_nocontext sv_setpvf_nocontext sv_setpviv +syn keyword xsFunction sv_setpviv_mg sv_setpvn sv_setpvn_mg sv_setref_iv +syn keyword xsFunction sv_setref_nv sv_setref_pv sv_setref_pvn sv_setref_uv +syn keyword xsFunction sv_setsv_flags sv_setsv_mg sv_setuv sv_setuv_mg +syn keyword xsFunction sv_tainted sv_true sv_uni_display sv_unmagic +syn keyword xsFunction sv_unmagicext sv_unref_flags sv_untaint sv_upgrade +syn keyword xsFunction sv_usepvn_flags sv_utf8_decode sv_utf8_downgrade +syn keyword xsFunction sv_utf8_encode sv_utf8_upgrade_flags_grow sv_uv +syn keyword xsFunction sv_vcatpvf sv_vcatpvf_mg sv_vcatpvfn sv_vcatpvfn_flags +syn keyword xsFunction sv_vsetpvf sv_vsetpvf_mg sv_vsetpvfn swash_fetch +syn keyword xsFunction swash_init sync_locale sys_intern_clear sys_intern_dup +syn keyword xsFunction sys_intern_init taint_env taint_proper to_uni_lower +syn keyword xsFunction to_uni_title to_uni_upper to_utf8_case unlnk +syn keyword xsFunction unpack_str unpackstring unsharepvn upg_version +syn keyword xsFunction utf16_to_utf8 utf16_to_utf8_reversed utf8_distance +syn keyword xsFunction utf8_hop utf8_length utf8_to_bytes utf8n_to_uvchr +syn keyword xsFunction utf8n_to_uvuni uvoffuni_to_utf8_flags uvuni_to_utf8 +syn keyword xsFunction uvuni_to_utf8_flags valid_utf8_to_uvchr vcmp vcroak +syn keyword xsFunction vdeb vform vload_module vmess vnewSVpvf vnormal +syn keyword xsFunction vnumify vstringify vverify vwarn vwarner warn +syn keyword xsFunction warn_nocontext warn_sv warner warner_nocontext +syn keyword xsFunction whichsig_pv whichsig_pvn whichsig_sv wrap_op_checker +syn keyword xsVariable MARK MY_CXT ORIGMARK PL_I PL_No PL_Vars PL_VarsPtr +syn keyword xsVariable PL_Yes PL_a2e PL_bincompat_options PL_bitcount +syn keyword xsVariable PL_block_type PL_bufend PL_bufptr PL_charclass +syn keyword xsVariable PL_check PL_copline PL_core_reg_engine PL_cshname +syn keyword xsVariable PL_e2a PL_e2utf PL_error_count PL_expect PL_fold +syn keyword xsVariable PL_fold_latin1 PL_fold_locale PL_force_link_funcs +syn keyword xsVariable PL_freq PL_global_struct_size PL_hexdigit PL_in_my +syn keyword xsVariable PL_in_my_stash PL_interp_size PL_interp_size_5_18_0 +syn keyword xsVariable PL_last_lop PL_last_lop_op PL_last_uni PL_latin1_lc +syn keyword xsVariable PL_lex_allbrackets PL_lex_brackets PL_lex_brackstack +syn keyword xsVariable PL_lex_casemods PL_lex_casestack PL_lex_defer +syn keyword xsVariable PL_lex_dojoin PL_lex_fakeeof PL_lex_formbrack +syn keyword xsVariable PL_lex_inpat PL_lex_inwhat PL_lex_op PL_lex_repl +syn keyword xsVariable PL_lex_starts PL_lex_state PL_lex_stuff PL_linestart +syn keyword xsVariable PL_linestr PL_magic_data PL_magic_vtable_names +syn keyword xsVariable PL_memory_wrap PL_mod_latin1_uc PL_multi_close +syn keyword xsVariable PL_multi_end PL_multi_open PL_multi_start PL_nexttoke +syn keyword xsVariable PL_nexttype PL_nextval PL_no_aelem PL_no_dir_func +syn keyword xsVariable PL_no_func PL_no_helem_sv PL_no_localize_ref PL_no_mem +syn keyword xsVariable PL_no_modify PL_no_myglob PL_no_security +syn keyword xsVariable PL_no_sock_func PL_no_symref PL_no_symref_sv +syn keyword xsVariable PL_no_usym PL_no_wrongref PL_oldbufptr PL_oldoldbufptr +syn keyword xsVariable PL_op_desc PL_op_name PL_op_private_bitdef_ix +syn keyword xsVariable PL_op_private_bitdefs PL_op_private_bitfields +syn keyword xsVariable PL_op_private_labels PL_op_private_valid PL_opargs +syn keyword xsVariable PL_phase_names PL_ppaddr PL_preambled +syn keyword xsVariable PL_reg_extflags_name PL_reg_intflags_name PL_reg_name +syn keyword xsVariable PL_regkind PL_revision PL_rsfp PL_rsfp_filters +syn keyword xsVariable PL_runops_dbg PL_runops_std PL_sh_path PL_sig_name +syn keyword xsVariable PL_sig_num PL_simple PL_simple_bitmask PL_sublex_info +syn keyword xsVariable PL_subversion PL_tokenbuf PL_utf2e PL_utf8skip +syn keyword xsVariable PL_uudmap PL_uuemap PL_valid_types_IVX +syn keyword xsVariable PL_valid_types_IV_set PL_valid_types_NVX +syn keyword xsVariable PL_valid_types_NV_set PL_valid_types_PVX +syn keyword xsVariable PL_valid_types_RV PL_varies PL_varies_bitmask +syn keyword xsVariable PL_version PL_warn_nl PL_warn_nosemi PL_warn_reserved +syn keyword xsVariable PL_warn_uninit PL_warn_uninit_sv RETVAL SP TARG +syn keyword xsVariable _aMY_CXT _aTHX aMY_CXT aMY_CXT_ aTHX aTHX_ items +syn keyword xsMacro ABORT ACCEPT ADDOP AHOCORASICK AHOCORASICKC +syn keyword xsMacro ALLOC_THREAD_KEY AMG_CALLun AMG_CALLunary AMGf_assign +syn keyword xsMacro AMGf_noleft AMGf_noright AMGf_numarg AMGf_numeric +syn keyword xsMacro AMGf_set AMGf_unary AMGf_want_list AMGfallNEVER AMGfallNO +syn keyword xsMacro AMGfallYES AMT_AMAGIC AMT_AMAGIC_off AMT_AMAGIC_on +syn keyword xsMacro AMTf_AMAGIC ANDAND ANDOP ANGSTROM_SIGN ANONSUB ANYOF +syn keyword xsMacro ANYOFL ANYOF_ALNUM ANYOF_ALNUML ANYOF_ALPHA +syn keyword xsMacro ANYOF_ALPHANUMERIC ANYOF_ASCII ANYOF_BIT ANYOF_BITMAP +syn keyword xsMacro ANYOF_BITMAP_BYTE ANYOF_BITMAP_CLEAR +syn keyword xsMacro ANYOF_BITMAP_CLEARALL ANYOF_BITMAP_SET +syn keyword xsMacro ANYOF_BITMAP_SETALL ANYOF_BITMAP_SIZE ANYOF_BITMAP_TEST +syn keyword xsMacro ANYOF_BITMAP_ZERO ANYOF_BLANK ANYOF_CASED +syn keyword xsMacro ANYOF_CLASS_CLEAR ANYOF_CLASS_OR ANYOF_CLASS_SET +syn keyword xsMacro ANYOF_CLASS_SETALL ANYOF_CLASS_TEST +syn keyword xsMacro ANYOF_CLASS_TEST_ANY_SET ANYOF_CLASS_ZERO ANYOF_CNTRL +syn keyword xsMacro ANYOF_COMMON_FLAGS ANYOF_DIGIT ANYOF_FLAGS +syn keyword xsMacro ANYOF_FLAGS_ALL ANYOF_FOLD_SHARP_S ANYOF_GRAPH +syn keyword xsMacro ANYOF_HAS_NONBITMAP_NON_UTF8_MATCHES +syn keyword xsMacro ANYOF_HAS_UTF8_NONBITMAP_MATCHES ANYOF_HORIZWS +syn keyword xsMacro ANYOF_INVERT ANYOF_LOCALE_FLAGS ANYOF_LOC_FOLD +syn keyword xsMacro ANYOF_LOWER ANYOF_MATCHES_ALL_ABOVE_BITMAP +syn keyword xsMacro ANYOF_MATCHES_ALL_NON_UTF8_NON_ASCII ANYOF_MATCHES_POSIXL +syn keyword xsMacro ANYOF_MAX ANYOF_NALNUM ANYOF_NALNUML ANYOF_NALPHA +syn keyword xsMacro ANYOF_NALPHANUMERIC ANYOF_NASCII ANYOF_NBLANK +syn keyword xsMacro ANYOF_NCASED ANYOF_NCNTRL ANYOF_NDIGIT ANYOF_NGRAPH +syn keyword xsMacro ANYOF_NHORIZWS ANYOF_NLOWER ANYOF_NPRINT ANYOF_NPUNCT +syn keyword xsMacro ANYOF_NSPACE ANYOF_NSPACEL ANYOF_NUPPER ANYOF_NVERTWS +syn keyword xsMacro ANYOF_NWORDCHAR ANYOF_NXDIGIT ANYOF_ONLY_HAS_BITMAP +syn keyword xsMacro ANYOF_POSIXL_AND ANYOF_POSIXL_CLEAR ANYOF_POSIXL_MAX +syn keyword xsMacro ANYOF_POSIXL_OR ANYOF_POSIXL_SET ANYOF_POSIXL_SETALL +syn keyword xsMacro ANYOF_POSIXL_SKIP ANYOF_POSIXL_SSC_TEST_ALL_SET +syn keyword xsMacro ANYOF_POSIXL_SSC_TEST_ANY_SET ANYOF_POSIXL_TEST +syn keyword xsMacro ANYOF_POSIXL_TEST_ALL_SET ANYOF_POSIXL_TEST_ANY_SET +syn keyword xsMacro ANYOF_POSIXL_ZERO ANYOF_PRINT ANYOF_PUNCT ANYOF_SKIP +syn keyword xsMacro ANYOF_SPACE ANYOF_SPACEL ANYOF_UNIPROP ANYOF_UPPER +syn keyword xsMacro ANYOF_VERTWS ANYOF_WARN_SUPER ANYOF_WORDCHAR ANYOF_XDIGIT +syn keyword xsMacro ARCHLIB ARCHLIB_EXP ARCHNAME ARG ARG1 ARG1_LOC ARG1_SET +syn keyword xsMacro ARG2 ARG2L ARG2L_LOC ARG2L_SET ARG2_LOC ARG2_SET ARGTARG +syn keyword xsMacro ARG_LOC ARG_SET ARG_VALUE ARG__SET ARROW +syn keyword xsMacro ASCII_MORE_RESTRICT_PAT_MODS ASCII_RESTRICT_PAT_MOD +syn keyword xsMacro ASCII_RESTRICT_PAT_MODS ASCII_TO_NATIVE ASCTIME_R_PROTO +syn keyword xsMacro ASSERT_CURPAD_ACTIVE ASSERT_CURPAD_LEGAL ASSIGNOP ASSUME +syn keyword xsMacro Atof Atol Atoul AvALLOC AvARRAY AvARYLEN AvFILL AvFILLp +syn keyword xsMacro AvMAX AvREAL AvREALISH AvREAL_off AvREAL_on AvREAL_only +syn keyword xsMacro AvREIFY AvREIFY_off AvREIFY_on AvREIFY_only BADVERSION +syn keyword xsMacro BASEOP BHKf_bhk_eval BHKf_bhk_post_end BHKf_bhk_pre_end +syn keyword xsMacro BHKf_bhk_start BIN BIN_EXP BITANDOP BITMAP_BYTE +syn keyword xsMacro BITMAP_TEST BITOROP BIT_BUCKET BIT_DIGITS BOL +syn keyword xsMacro BOM_UTF8_FIRST_BYTE BOM_UTF8_TAIL BOUND BOUNDA BOUNDL +syn keyword xsMacro BOUNDU BRANCH BRANCHJ BRANCH_next BRANCH_next_fail +syn keyword xsMacro BSD_GETPGRP BSD_SETPGRP BSDish BUFSIZ BYTEORDER +syn keyword xsMacro BhkDISABLE BhkENABLE BhkENTRY BhkENTRY_set BhkFLAGS Bit +syn keyword xsMacro BmFLAGS BmPREVIOUS BmRARE BmUSEFUL CALLREGCOMP +syn keyword xsMacro CALLREGCOMP_ENG CALLREGDUPE CALLREGDUPE_PVT CALLREGEXEC +syn keyword xsMacro CALLREGFREE CALLREGFREE_PVT CALLREG_INTUIT_START +syn keyword xsMacro CALLREG_INTUIT_STRING CALLREG_NAMED_BUFF_ALL +syn keyword xsMacro CALLREG_NAMED_BUFF_CLEAR CALLREG_NAMED_BUFF_COUNT +syn keyword xsMacro CALLREG_NAMED_BUFF_DELETE CALLREG_NAMED_BUFF_EXISTS +syn keyword xsMacro CALLREG_NAMED_BUFF_FETCH CALLREG_NAMED_BUFF_FIRSTKEY +syn keyword xsMacro CALLREG_NAMED_BUFF_NEXTKEY CALLREG_NAMED_BUFF_SCALAR +syn keyword xsMacro CALLREG_NAMED_BUFF_STORE CALLREG_NUMBUF_FETCH +syn keyword xsMacro CALLREG_NUMBUF_LENGTH CALLREG_NUMBUF_STORE +syn keyword xsMacro CALLREG_PACKAGE CALLRUNOPS CALL_BLOCK_HOOKS +syn keyword xsMacro CALL_CHECKER_REQUIRE_GV CALL_FPTR CANY CAN_COW_FLAGS +syn keyword xsMacro CAN_COW_MASK CAN_PROTOTYPE CAN_VAPROTO +syn keyword xsMacro CASE_STD_PMMOD_FLAGS_PARSE_SET CASTFLAGS CASTNEGFLOAT +syn keyword xsMacro CAT2 CATCH_GET CATCH_SET CHANGE_MULTICALL_FLAGS CHARBITS +syn keyword xsMacro CHARSET_PAT_MODS CHECK_MALLOC_TAINT +syn keyword xsMacro CHECK_MALLOC_TOO_LATE_FOR CHECK_MALLOC_TOO_LATE_FOR_ +syn keyword xsMacro CLEAR_ARGARRAY CLEAR_ERRSV CLONEf_CLONE_HOST +syn keyword xsMacro CLONEf_COPY_STACKS CLONEf_JOIN_IN CLONEf_KEEP_PTR_TABLE +syn keyword xsMacro CLOSE CLUMP CLUMP_2IV CLUMP_2UV COLONATTR +syn keyword xsMacro COMBINING_GRAVE_ACCENT_UTF8 COMMIT COMMIT_next +syn keyword xsMacro COMMIT_next_fail COND_BROADCAST COND_DESTROY COND_INIT +syn keyword xsMacro COND_SIGNAL COND_WAIT CONTINUE CONTINUE_PAT_MOD +syn keyword xsMacro COPHH_KEY_UTF8 COP_SEQMAX_INC COP_SEQ_RANGE_HIGH +syn keyword xsMacro COP_SEQ_RANGE_LOW CPERLarg CPERLarg_ CPERLscope CPPLAST +syn keyword xsMacro CPPMINUS CPPRUN CPPSTDIN CRYPT_R_PROTO CR_NATIVE CSH +syn keyword xsMacro CTERMID_R_PROTO CTIME_R_PROTO CTYPE256 CURLY CURLYM +syn keyword xsMacro CURLYM_A CURLYM_A_fail CURLYM_B CURLYM_B_fail CURLYN +syn keyword xsMacro CURLYX CURLYX_end CURLYX_end_fail CURLY_B_max +syn keyword xsMacro CURLY_B_max_fail CURLY_B_min CURLY_B_min_fail +syn keyword xsMacro CURLY_B_min_known CURLY_B_min_known_fail +syn keyword xsMacro CURRENT_FEATURE_BUNDLE CURRENT_HINTS CUTGROUP +syn keyword xsMacro CUTGROUP_next CUTGROUP_next_fail CV_NAME_NOTQUAL +syn keyword xsMacro CV_UNDEF_KEEP_NAME CVf_ANON CVf_ANONCONST CVf_AUTOLOAD +syn keyword xsMacro CVf_BUILTIN_ATTRS CVf_CLONE CVf_CLONED CVf_CONST +syn keyword xsMacro CVf_CVGV_RC CVf_DYNFILE CVf_HASEVAL CVf_ISXSUB +syn keyword xsMacro CVf_LEXICAL CVf_LVALUE CVf_METHOD CVf_NAMED CVf_NODEBUG +syn keyword xsMacro CVf_SLABBED CVf_UNIQUE CVf_WEAKOUTSIDE CXINC CXTYPEMASK +syn keyword xsMacro CX_CURPAD_SAVE CX_CURPAD_SV CXp_FOR_DEF CXp_FOR_LVREF +syn keyword xsMacro CXp_HASARGS CXp_MULTICALL CXp_ONCE CXp_REAL CXp_SUB_RE +syn keyword xsMacro CXp_SUB_RE_FAKE CXp_TRYBLOCK C_ARRAY_END C_ARRAY_LENGTH +syn keyword xsMacro C_FAC_POSIX CopFILE CopFILEAV CopFILEAVx CopFILEGV +syn keyword xsMacro CopFILEGV_set CopFILESV CopFILE_free CopFILE_set +syn keyword xsMacro CopFILE_setn CopHINTHASH_get CopHINTHASH_set CopHINTS_get +syn keyword xsMacro CopHINTS_set CopLABEL CopLABEL_alloc CopLABEL_len +syn keyword xsMacro CopLABEL_len_flags CopLINE CopLINE_dec CopLINE_inc +syn keyword xsMacro CopLINE_set CopSTASH CopSTASHPV CopSTASHPV_set +syn keyword xsMacro CopSTASH_eq CopSTASH_ne CopSTASH_set Copy CopyD CowREFCNT +syn keyword xsMacro Ctl CvANON CvANONCONST CvANONCONST_off CvANONCONST_on +syn keyword xsMacro CvANON_off CvANON_on CvAUTOLOAD CvAUTOLOAD_off +syn keyword xsMacro CvAUTOLOAD_on CvCLONE CvCLONED CvCLONED_off CvCLONED_on +syn keyword xsMacro CvCLONE_off CvCLONE_on CvCONST CvCONST_off CvCONST_on +syn keyword xsMacro CvCVGV_RC CvCVGV_RC_off CvCVGV_RC_on CvDEPTH +syn keyword xsMacro CvDEPTHunsafe CvDYNFILE CvDYNFILE_off CvDYNFILE_on CvEVAL +syn keyword xsMacro CvEVAL_off CvEVAL_on CvFILE CvFILEGV CvFILE_set_from_cop +syn keyword xsMacro CvFLAGS CvGV CvGV_set CvHASEVAL CvHASEVAL_off +syn keyword xsMacro CvHASEVAL_on CvHASGV CvHSCXT CvISXSUB CvISXSUB_off +syn keyword xsMacro CvISXSUB_on CvLEXICAL CvLEXICAL_off CvLEXICAL_on CvLVALUE +syn keyword xsMacro CvLVALUE_off CvLVALUE_on CvMETHOD CvMETHOD_off +syn keyword xsMacro CvMETHOD_on CvNAMED CvNAMED_off CvNAMED_on CvNAME_HEK_set +syn keyword xsMacro CvNODEBUG CvNODEBUG_off CvNODEBUG_on CvOUTSIDE +syn keyword xsMacro CvOUTSIDE_SEQ CvPADLIST CvPADLIST_set CvPROTO CvPROTOLEN +syn keyword xsMacro CvROOT CvSLABBED CvSLABBED_off CvSLABBED_on CvSPECIAL +syn keyword xsMacro CvSPECIAL_off CvSPECIAL_on CvSTART CvSTASH CvSTASH_set +syn keyword xsMacro CvUNIQUE CvUNIQUE_off CvUNIQUE_on CvWEAKOUTSIDE +syn keyword xsMacro CvWEAKOUTSIDE_off CvWEAKOUTSIDE_on CvXSUB CvXSUBANY +syn keyword xsMacro CxFOREACH CxFOREACHDEF CxHASARGS CxITERVAR +syn keyword xsMacro CxITERVAR_PADSV CxLABEL CxLABEL_len CxLABEL_len_flags +syn keyword xsMacro CxLVAL CxMULTICALL CxOLD_IN_EVAL CxOLD_OP_TYPE CxONCE +syn keyword xsMacro CxPADLOOP CxPOPSUB_DONE CxREALEVAL CxTRYBLOCK CxTYPE +syn keyword xsMacro CxTYPE_is_LOOP DBL_DIG DBL_MAX DBL_MIN DBM_ckFilter +syn keyword xsMacro DBM_setFilter DBVARMG_COUNT DBVARMG_SIGNAL DBVARMG_SINGLE +syn keyword xsMacro DBVARMG_TRACE DB_VERSION_MAJOR_CFG DB_VERSION_MINOR_CFG +syn keyword xsMacro DB_VERSION_PATCH_CFG DEBUG_A DEBUG_A_FLAG DEBUG_A_TEST +syn keyword xsMacro DEBUG_A_TEST_ DEBUG_B DEBUG_BUFFERS_r DEBUG_B_FLAG +syn keyword xsMacro DEBUG_B_TEST DEBUG_B_TEST_ DEBUG_C DEBUG_COMPILE_r +syn keyword xsMacro DEBUG_CX DEBUG_C_FLAG DEBUG_C_TEST DEBUG_C_TEST_ DEBUG_D +syn keyword xsMacro DEBUG_DB_RECURSE_FLAG DEBUG_DUMP_r DEBUG_D_FLAG +syn keyword xsMacro DEBUG_D_TEST DEBUG_D_TEST_ DEBUG_EXECUTE_r DEBUG_EXTRA_r +syn keyword xsMacro DEBUG_FLAGS_r DEBUG_GPOS_r DEBUG_H DEBUG_H_FLAG +syn keyword xsMacro DEBUG_H_TEST DEBUG_H_TEST_ DEBUG_INTUIT_r DEBUG_J_FLAG +syn keyword xsMacro DEBUG_J_TEST DEBUG_J_TEST_ DEBUG_L DEBUG_L_FLAG +syn keyword xsMacro DEBUG_L_TEST DEBUG_L_TEST_ DEBUG_M DEBUG_MASK +syn keyword xsMacro DEBUG_MATCH_r DEBUG_M_FLAG DEBUG_M_TEST DEBUG_M_TEST_ +syn keyword xsMacro DEBUG_OFFSETS_r DEBUG_OPTIMISE_MORE_r DEBUG_OPTIMISE_r +syn keyword xsMacro DEBUG_P DEBUG_PARSE_r DEBUG_P_FLAG DEBUG_P_TEST +syn keyword xsMacro DEBUG_P_TEST_ DEBUG_Pv DEBUG_Pv_TEST DEBUG_Pv_TEST_ +syn keyword xsMacro DEBUG_R DEBUG_R_FLAG DEBUG_R_TEST DEBUG_R_TEST_ DEBUG_S +syn keyword xsMacro DEBUG_SCOPE DEBUG_STACK_r DEBUG_STATE_r DEBUG_S_FLAG +syn keyword xsMacro DEBUG_S_TEST DEBUG_S_TEST_ DEBUG_T DEBUG_TEST_r +syn keyword xsMacro DEBUG_TOP_FLAG DEBUG_TRIE_COMPILE_MORE_r +syn keyword xsMacro DEBUG_TRIE_COMPILE_r DEBUG_TRIE_EXECUTE_MORE_r +syn keyword xsMacro DEBUG_TRIE_EXECUTE_r DEBUG_TRIE_r DEBUG_T_FLAG +syn keyword xsMacro DEBUG_T_TEST DEBUG_T_TEST_ DEBUG_U DEBUG_U_FLAG +syn keyword xsMacro DEBUG_U_TEST DEBUG_U_TEST_ DEBUG_Uv DEBUG_Uv_TEST +syn keyword xsMacro DEBUG_Uv_TEST_ DEBUG_X DEBUG_X_FLAG DEBUG_X_TEST +syn keyword xsMacro DEBUG_X_TEST_ DEBUG_Xv DEBUG_Xv_TEST DEBUG_Xv_TEST_ +syn keyword xsMacro DEBUG__ DEBUG_c DEBUG_c_FLAG DEBUG_c_TEST DEBUG_c_TEST_ +syn keyword xsMacro DEBUG_f DEBUG_f_FLAG DEBUG_f_TEST DEBUG_f_TEST_ DEBUG_l +syn keyword xsMacro DEBUG_l_FLAG DEBUG_l_TEST DEBUG_l_TEST_ DEBUG_m +syn keyword xsMacro DEBUG_m_FLAG DEBUG_m_TEST DEBUG_m_TEST_ DEBUG_o +syn keyword xsMacro DEBUG_o_FLAG DEBUG_o_TEST DEBUG_o_TEST_ DEBUG_p +syn keyword xsMacro DEBUG_p_FLAG DEBUG_p_TEST DEBUG_p_TEST_ DEBUG_q +syn keyword xsMacro DEBUG_q_FLAG DEBUG_q_TEST DEBUG_q_TEST_ DEBUG_r +syn keyword xsMacro DEBUG_r_FLAG DEBUG_r_TEST DEBUG_r_TEST_ DEBUG_s +syn keyword xsMacro DEBUG_s_FLAG DEBUG_s_TEST DEBUG_s_TEST_ DEBUG_t_FLAG +syn keyword xsMacro DEBUG_t_TEST DEBUG_t_TEST_ DEBUG_u DEBUG_u_FLAG +syn keyword xsMacro DEBUG_u_TEST DEBUG_u_TEST_ DEBUG_v DEBUG_v_FLAG +syn keyword xsMacro DEBUG_v_TEST DEBUG_v_TEST_ DEBUG_x DEBUG_x_FLAG +syn keyword xsMacro DEBUG_x_TEST DEBUG_x_TEST_ +syn keyword xsMacro DECLARATION_FOR_LC_NUMERIC_MANIPULATION +syn keyword xsMacro DECLARATION_FOR_STORE_LC_NUMERIC_SET_TO_NEEDED +syn keyword xsMacro DECLARE_STORE_LC_NUMERIC_SET_TO_NEEDED DEFAULT +syn keyword xsMacro DEFAULT_PAT_MOD DEFINEP DEFSV DEFSV_set DEL_NATIVE +syn keyword xsMacro DEPENDS_PAT_MOD DEPENDS_PAT_MODS DETACH DIE DM_ARRAY_ISA +syn keyword xsMacro DM_DELAY DM_EGID DM_EUID DM_GID DM_RGID DM_RUID DM_UID DO +syn keyword xsMacro DOINIT DOLSHARP DONT_DECLARE_STD DORDOR DOROP DOSISH +syn keyword xsMacro DOTDOT DOUBLEKIND DOUBLESIZE DOUBLE_BIG_ENDIAN +syn keyword xsMacro DOUBLE_IS_IEEE_754_128_BIT_BIG_ENDIAN +syn keyword xsMacro DOUBLE_IS_IEEE_754_128_BIT_LITTLE_ENDIAN +syn keyword xsMacro DOUBLE_IS_IEEE_754_32_BIT_BIG_ENDIAN +syn keyword xsMacro DOUBLE_IS_IEEE_754_32_BIT_LITTLE_ENDIAN +syn keyword xsMacro DOUBLE_IS_IEEE_754_64_BIT_BIG_ENDIAN +syn keyword xsMacro DOUBLE_IS_IEEE_754_64_BIT_LITTLE_ENDIAN +syn keyword xsMacro DOUBLE_IS_IEEE_754_64_BIT_MIXED_ENDIAN_BE_LE +syn keyword xsMacro DOUBLE_IS_IEEE_754_64_BIT_MIXED_ENDIAN_LE_BE +syn keyword xsMacro DOUBLE_IS_UNKNOWN_FORMAT DOUBLE_LITTLE_ENDIAN +syn keyword xsMacro DOUBLE_MIX_ENDIAN DO_UTF8 DPTR2FPTR DRAND48_R_PROTO +syn keyword xsMacro DUP_WARNINGS Drand01 ELSE ELSIF EMBEDMYMALLOC END +syn keyword xsMacro ENDGRENT_R_PROTO ENDHOSTENT_R_PROTO ENDLIKE +syn keyword xsMacro ENDNETENT_R_PROTO ENDPROTOENT_R_PROTO ENDPWENT_R_PROTO +syn keyword xsMacro ENDSERVENT_R_PROTO END_EXTERN_C ENTER ENTER_with_name +syn keyword xsMacro ENTRY_PROBE EOF EOL EOS EQOP ERRSV ESC_NATIVE EVAL +syn keyword xsMacro EVAL_AB EVAL_AB_fail EVAL_INEVAL EVAL_INREQUIRE +syn keyword xsMacro EVAL_KEEPERR EVAL_NULL EVAL_RE_REPARSING EVAL_WARNONLY +syn keyword xsMacro EXACT EXACTF EXACTFA EXACTFA_NO_TRIE EXACTFL EXACTFLU8 +syn keyword xsMacro EXACTFU EXACTFU_SS EXACTL EXEC_ARGV_CAST EXEC_PAT_MOD +syn keyword xsMacro EXEC_PAT_MODS EXPECT EXT EXTCONST EXTEND EXTEND_MORTAL +syn keyword xsMacro EXTERN_C EXTPERLIO EXTRA_SIZE EXTRA_STEP_2ARGS EXT_MGVTBL +syn keyword xsMacro EXT_PAT_MODS FAKE_BIT_BUCKET FAKE_DEFAULT_SIGNAL_HANDLERS +syn keyword xsMacro FAKE_PERSISTENT_SIGNAL_HANDLERS FALSE FBMcf_TAIL +syn keyword xsMacro FBMcf_TAIL_DOLLAR FBMcf_TAIL_DOLLARM FBMcf_TAIL_Z +syn keyword xsMacro FBMcf_TAIL_z FBMrf_MULTILINE FCNTL_CAN_LOCK FD_CLR +syn keyword xsMacro FD_ISSET FD_SET FD_ZERO FEATURE_ARYBASE_IS_ENABLED +syn keyword xsMacro FEATURE_BITWISE_IS_ENABLED FEATURE_BUNDLE_510 +syn keyword xsMacro FEATURE_BUNDLE_511 FEATURE_BUNDLE_515 +syn keyword xsMacro FEATURE_BUNDLE_CUSTOM FEATURE_BUNDLE_DEFAULT +syn keyword xsMacro FEATURE_EVALBYTES_IS_ENABLED FEATURE_FC_IS_ENABLED +syn keyword xsMacro FEATURE_IS_ENABLED FEATURE_LEXSUBS_IS_ENABLED +syn keyword xsMacro FEATURE_POSTDEREF_IS_ENABLED +syn keyword xsMacro FEATURE_POSTDEREF_QQ_IS_ENABLED +syn keyword xsMacro FEATURE_REFALIASING_IS_ENABLED FEATURE_SAY_IS_ENABLED +syn keyword xsMacro FEATURE_SIGNATURES_IS_ENABLED FEATURE_STATE_IS_ENABLED +syn keyword xsMacro FEATURE_SWITCH_IS_ENABLED FEATURE_UNICODE_IS_ENABLED +syn keyword xsMacro FEATURE_UNIEVAL_IS_ENABLED FEATURE___SUB___IS_ENABLED +syn keyword xsMacro FFLUSH_NULL FF_0DECIMAL FF_BLANK FF_CHECKCHOP FF_CHECKNL +syn keyword xsMacro FF_CHOP FF_DECIMAL FF_END FF_FETCH FF_HALFSPACE FF_ITEM +syn keyword xsMacro FF_LINEGLOB FF_LINEMARK FF_LINESNGL FF_LITERAL FF_MORE +syn keyword xsMacro FF_NEWLINE FF_SKIP FF_SPACE FILE FILE_base FILE_bufsiz +syn keyword xsMacro FILE_cnt FILE_ptr FILL_ADVANCE_NODE +syn keyword xsMacro FILL_ADVANCE_NODE_2L_ARG FILL_ADVANCE_NODE_ARG +syn keyword xsMacro FILTER_DATA FILTER_ISREADER FILTER_READ +syn keyword xsMacro FIND_RUNCV_level_eq FIND_RUNCV_padid_eq +syn keyword xsMacro FIRST_SURROGATE_UTF8_FIRST_BYTE FITS_IN_8_BITS FLAGS +syn keyword xsMacro FLEXFILENAMES FOLDEQ_LOCALE FOLDEQ_S1_ALREADY_FOLDED +syn keyword xsMacro FOLDEQ_S1_FOLDS_SANE FOLDEQ_S2_ALREADY_FOLDED +syn keyword xsMacro FOLDEQ_S2_FOLDS_SANE FOLDEQ_UTF8_NOMIX_ASCII +syn keyword xsMacro FOLD_FLAGS_FULL FOLD_FLAGS_LOCALE FOLD_FLAGS_NOMIX_ASCII +syn keyword xsMacro FOR FORMAT FORMLBRACK FORMRBRACK FPTR2DPTR FP_PINF +syn keyword xsMacro FP_QNAN FREETMPS FREE_THREAD_KEY FSEEKSIZE FUNC FUNC0 +syn keyword xsMacro FUNC0OP FUNC0SUB FUNC1 FUNCMETH FUNCTION__ F_atan2_amg +syn keyword xsMacro F_cos_amg F_exp_amg F_log_amg F_pow_amg F_sin_amg +syn keyword xsMacro F_sqrt_amg Fflush FmLINES FreeOp Fstat GCB_ENUM_COUNT +syn keyword xsMacro GCC_DIAG_IGNORE GCC_DIAG_PRAGMA GCC_DIAG_RESTORE +syn keyword xsMacro GDBMNDBM_H_USES_PROTOTYPES GETATARGET GETGRENT_R_PROTO +syn keyword xsMacro GETGRGID_R_PROTO GETGRNAM_R_PROTO GETHOSTBYADDR_R_PROTO +syn keyword xsMacro GETHOSTBYNAME_R_PROTO GETHOSTENT_R_PROTO GETLOGIN_R_PROTO +syn keyword xsMacro GETNETBYADDR_R_PROTO GETNETBYNAME_R_PROTO +syn keyword xsMacro GETNETENT_R_PROTO GETPROTOBYNAME_R_PROTO +syn keyword xsMacro GETPROTOBYNUMBER_R_PROTO GETPROTOENT_R_PROTO +syn keyword xsMacro GETPWENT_R_PROTO GETPWNAM_R_PROTO GETPWUID_R_PROTO +syn keyword xsMacro GETSERVBYNAME_R_PROTO GETSERVBYPORT_R_PROTO +syn keyword xsMacro GETSERVENT_R_PROTO GETSPNAM_R_PROTO GETTARGET +syn keyword xsMacro GETTARGETSTACKED GET_RE_DEBUG_FLAGS +syn keyword xsMacro GET_RE_DEBUG_FLAGS_DECL GIMME GIMME_V GIVEN +syn keyword xsMacro GLOBAL_PAT_MOD GMTIME_MAX GMTIME_MIN GMTIME_R +syn keyword xsMacro GMTIME_R_PROTO GOSTART GOSUB GPOS GPf_ALIASED_SV +syn keyword xsMacro GRAMBARESTMT GRAMBLOCK GRAMEXPR GRAMFULLSTMT GRAMPROG +syn keyword xsMacro GRAMSTMTSEQ GREEK_CAPITAL_LETTER_IOTA_UTF8 +syn keyword xsMacro GREEK_CAPITAL_LETTER_MU GREEK_SMALL_LETTER_MU +syn keyword xsMacro GREEK_SMALL_LETTER_MU_UTF8 GROK_NUMERIC_RADIX GROUPP +syn keyword xsMacro GRPASSWD GV_ADD GV_ADDMG GV_ADDMULTI GV_ADDWARN +syn keyword xsMacro GV_AUTOLOAD GV_AUTOLOAD_ISMETHOD GV_CACHE_ONLY GV_CROAK +syn keyword xsMacro GV_NOADD_MASK GV_NOADD_NOINIT GV_NOEXPAND GV_NOINIT +syn keyword xsMacro GV_NOTQUAL GV_NO_SVGMAGIC GV_SUPER GVf_ASSUMECV +syn keyword xsMacro GVf_IMPORTED GVf_IMPORTED_AV GVf_IMPORTED_CV +syn keyword xsMacro GVf_IMPORTED_HV GVf_IMPORTED_SV GVf_INTRO GVf_MULTI +syn keyword xsMacro Gconvert Gid_t_f Gid_t_sign Gid_t_size GvALIASED_SV +syn keyword xsMacro GvALIASED_SV_off GvALIASED_SV_on GvASSIGN_GENERATION +syn keyword xsMacro GvASSIGN_GENERATION_set GvASSUMECV GvASSUMECV_off +syn keyword xsMacro GvASSUMECV_on GvAV GvAVn GvCV GvCVGEN GvCV_set GvCVu +syn keyword xsMacro GvEGV GvEGVx GvENAME GvENAMELEN GvENAMEUTF8 GvENAME_HEK +syn keyword xsMacro GvESTASH GvFILE GvFILEGV GvFILE_HEK GvFILEx GvFLAGS +syn keyword xsMacro GvFORM GvGP GvGPFLAGS GvGP_set GvHV GvHVn GvIMPORTED +syn keyword xsMacro GvIMPORTED_AV GvIMPORTED_AV_off GvIMPORTED_AV_on +syn keyword xsMacro GvIMPORTED_CV GvIMPORTED_CV_off GvIMPORTED_CV_on +syn keyword xsMacro GvIMPORTED_HV GvIMPORTED_HV_off GvIMPORTED_HV_on +syn keyword xsMacro GvIMPORTED_SV GvIMPORTED_SV_off GvIMPORTED_SV_on +syn keyword xsMacro GvIMPORTED_off GvIMPORTED_on GvINTRO GvINTRO_off +syn keyword xsMacro GvINTRO_on GvIN_PAD GvIN_PAD_off GvIN_PAD_on GvIO GvIOn +syn keyword xsMacro GvIOp GvLINE GvMULTI GvMULTI_off GvMULTI_on GvNAME +syn keyword xsMacro GvNAMELEN GvNAMELEN_get GvNAMEUTF8 GvNAME_HEK GvNAME_get +syn keyword xsMacro GvREFCNT GvSTASH GvSV GvSVn GvXPVGV Gv_AMG HANDY_H +syn keyword xsMacro HASATTRIBUTE_DEPRECATED HASATTRIBUTE_FORMAT +syn keyword xsMacro HASATTRIBUTE_MALLOC HASATTRIBUTE_NONNULL +syn keyword xsMacro HASATTRIBUTE_NORETURN HASATTRIBUTE_PURE +syn keyword xsMacro HASATTRIBUTE_UNUSED HASATTRIBUTE_WARN_UNUSED_RESULT +syn keyword xsMacro HASCONST HASHBRACK HASVOLATILE HAS_ACCESS HAS_ACOSH +syn keyword xsMacro HAS_ALARM HAS_ASINH HAS_ATANH HAS_ATOLL HAS_BACKTRACE +syn keyword xsMacro HAS_BCMP HAS_BCOPY HAS_BOOL HAS_BUILTIN_CHOOSE_EXPR +syn keyword xsMacro HAS_BUILTIN_EXPECT HAS_BZERO HAS_C99 +syn keyword xsMacro HAS_C99_VARIADIC_MACROS HAS_CBRT HAS_CHOWN HAS_CHROOT +syn keyword xsMacro HAS_CLEARENV HAS_COPYSIGN HAS_COPYSIGNL HAS_CRYPT +syn keyword xsMacro HAS_CTERMID HAS_CUSERID HAS_DBL_DIG HAS_DBMINIT_PROTO +syn keyword xsMacro HAS_DIFFTIME HAS_DIRFD HAS_DLADDR HAS_DLERROR +syn keyword xsMacro HAS_DRAND48_PROTO HAS_DUP2 HAS_EACCESS HAS_ENDGRENT +syn keyword xsMacro HAS_ENDHOSTENT HAS_ENDNETENT HAS_ENDPROTOENT HAS_ENDPWENT +syn keyword xsMacro HAS_ENDSERVENT HAS_ERF HAS_ERFC HAS_EXP2 HAS_EXPM1 +syn keyword xsMacro HAS_FCHDIR HAS_FCHMOD HAS_FCHOWN HAS_FCNTL HAS_FDIM +syn keyword xsMacro HAS_FD_SET HAS_FEGETROUND HAS_FGETPOS HAS_FINITE +syn keyword xsMacro HAS_FINITEL HAS_FLOCK HAS_FLOCK_PROTO HAS_FMA HAS_FMAX +syn keyword xsMacro HAS_FMIN HAS_FORK HAS_FPATHCONF HAS_FPCLASSIFY HAS_FREXPL +syn keyword xsMacro HAS_FSEEKO HAS_FSETPOS HAS_FSTATFS HAS_FSTATVFS HAS_FSYNC +syn keyword xsMacro HAS_FTELLO HAS_FUTIMES HAS_GETADDRINFO HAS_GETCWD +syn keyword xsMacro HAS_GETGRENT HAS_GETGROUPS HAS_GETHOSTBYADDR +syn keyword xsMacro HAS_GETHOSTBYNAME HAS_GETHOSTENT HAS_GETHOSTNAME +syn keyword xsMacro HAS_GETHOST_PROTOS HAS_GETITIMER HAS_GETLOGIN +syn keyword xsMacro HAS_GETMNTENT HAS_GETNAMEINFO HAS_GETNETBYADDR +syn keyword xsMacro HAS_GETNETBYNAME HAS_GETNETENT HAS_GETNET_PROTOS +syn keyword xsMacro HAS_GETPAGESIZE HAS_GETPGID HAS_GETPGRP HAS_GETPPID +syn keyword xsMacro HAS_GETPRIORITY HAS_GETPROTOBYNAME HAS_GETPROTOBYNUMBER +syn keyword xsMacro HAS_GETPROTOENT HAS_GETPROTO_PROTOS HAS_GETPWENT +syn keyword xsMacro HAS_GETSERVBYNAME HAS_GETSERVBYPORT HAS_GETSERVENT +syn keyword xsMacro HAS_GETSERV_PROTOS HAS_GETSPNAM HAS_GETTIMEOFDAY +syn keyword xsMacro HAS_GNULIBC HAS_GROUP HAS_HASMNTOPT HAS_HTONL HAS_HTONS +syn keyword xsMacro HAS_HYPOT HAS_ILOGB HAS_ILOGBL HAS_INETNTOP HAS_INETPTON +syn keyword xsMacro HAS_INET_ATON HAS_INT64_T HAS_IOCTL HAS_IPV6_MREQ +syn keyword xsMacro HAS_IP_MREQ HAS_IP_MREQ_SOURCE HAS_ISASCII HAS_ISBLANK +syn keyword xsMacro HAS_ISFINITE HAS_ISINF HAS_ISINFL HAS_ISNAN HAS_ISNANL +syn keyword xsMacro HAS_ISNORMAL HAS_J0 HAS_J0L HAS_KILL HAS_KILLPG +syn keyword xsMacro HAS_LCHOWN HAS_LC_MONETARY_2008 HAS_LDBL_DIG HAS_LDEXPL +syn keyword xsMacro HAS_LGAMMA HAS_LGAMMA_R HAS_LINK HAS_LLRINT HAS_LLRINTL +syn keyword xsMacro HAS_LLROUND HAS_LLROUNDL HAS_LOCALECONV HAS_LOCKF +syn keyword xsMacro HAS_LOG1P HAS_LOG2 HAS_LOGB HAS_LONG_DOUBLE HAS_LONG_LONG +syn keyword xsMacro HAS_LRINT HAS_LRINTL HAS_LROUND HAS_LROUNDL +syn keyword xsMacro HAS_LSEEK_PROTO HAS_LSTAT HAS_MADVISE HAS_MBLEN +syn keyword xsMacro HAS_MBSTOWCS HAS_MBTOWC HAS_MEMCHR HAS_MEMCMP HAS_MEMCPY +syn keyword xsMacro HAS_MEMMOVE HAS_MEMSET HAS_MKDIR HAS_MKDTEMP HAS_MKFIFO +syn keyword xsMacro HAS_MKSTEMP HAS_MKSTEMPS HAS_MKTIME HAS_MMAP HAS_MODFL +syn keyword xsMacro HAS_MODFL_PROTO HAS_MPROTECT HAS_MSG HAS_MSG_CTRUNC +syn keyword xsMacro HAS_MSG_DONTROUTE HAS_MSG_OOB HAS_MSG_PEEK HAS_MSG_PROXY +syn keyword xsMacro HAS_MSYNC HAS_MUNMAP HAS_NAN HAS_NEARBYINT HAS_NEXTAFTER +syn keyword xsMacro HAS_NEXTTOWARD HAS_NICE HAS_NL_LANGINFO HAS_NTOHL +syn keyword xsMacro HAS_NTOHS HAS_OPEN3 HAS_PASSWD HAS_PATHCONF HAS_PAUSE +syn keyword xsMacro HAS_PIPE HAS_POLL HAS_PRCTL HAS_PRCTL_SET_NAME +syn keyword xsMacro HAS_PROCSELFEXE HAS_PTHREAD_ATFORK +syn keyword xsMacro HAS_PTHREAD_ATTR_SETSCOPE +syn keyword xsMacro HAS_PTHREAD_UNCHECKED_GETSPECIFIC_NP HAS_PTHREAD_YIELD +syn keyword xsMacro HAS_PTRDIFF_T HAS_READDIR HAS_READLINK HAS_READV +syn keyword xsMacro HAS_RECVMSG HAS_REGCOMP HAS_REMAINDER HAS_REMQUO +syn keyword xsMacro HAS_RENAME HAS_REWINDDIR HAS_RINT HAS_RMDIR HAS_ROUND +syn keyword xsMacro HAS_SANE_MEMCMP HAS_SBRK_PROTO HAS_SCALBN HAS_SCALBNL +syn keyword xsMacro HAS_SCHED_YIELD HAS_SCM_RIGHTS HAS_SEEKDIR HAS_SELECT +syn keyword xsMacro HAS_SEM HAS_SENDMSG HAS_SETEGID HAS_SETEUID HAS_SETGRENT +syn keyword xsMacro HAS_SETGROUPS HAS_SETHOSTENT HAS_SETITIMER HAS_SETLINEBUF +syn keyword xsMacro HAS_SETLOCALE HAS_SETNETENT HAS_SETPGID HAS_SETPGRP +syn keyword xsMacro HAS_SETPRIORITY HAS_SETPROTOENT HAS_SETPWENT HAS_SETREGID +syn keyword xsMacro HAS_SETRESGID HAS_SETRESUID HAS_SETREUID HAS_SETSERVENT +syn keyword xsMacro HAS_SETSID HAS_SETVBUF HAS_SHM HAS_SHMAT_PROTOTYPE +syn keyword xsMacro HAS_SIGACTION HAS_SIGNBIT HAS_SIGPROCMASK HAS_SIGSETJMP +syn keyword xsMacro HAS_SIN6_SCOPE_ID HAS_SKIP_LOCALE_INIT HAS_SNPRINTF +syn keyword xsMacro HAS_SOCKADDR_IN6 HAS_SOCKATMARK HAS_SOCKATMARK_PROTO +syn keyword xsMacro HAS_SOCKET HAS_SQRTL HAS_STAT HAS_STATIC_INLINE +syn keyword xsMacro HAS_STRCHR HAS_STRCOLL HAS_STRFTIME HAS_STRTOD HAS_STRTOL +syn keyword xsMacro HAS_STRTOLD HAS_STRTOLL HAS_STRTOQ HAS_STRTOUL +syn keyword xsMacro HAS_STRTOULL HAS_STRTOUQ HAS_STRUCT_CMSGHDR +syn keyword xsMacro HAS_STRUCT_MSGHDR HAS_STRUCT_STATFS +syn keyword xsMacro HAS_STRUCT_STATFS_F_FLAGS HAS_STRXFRM HAS_SYMLINK +syn keyword xsMacro HAS_SYSCALL HAS_SYSCALL_PROTO HAS_SYSCONF HAS_SYSTEM +syn keyword xsMacro HAS_SYS_ERRLIST HAS_TCGETPGRP HAS_TCSETPGRP HAS_TELLDIR +syn keyword xsMacro HAS_TELLDIR_PROTO HAS_TGAMMA HAS_TIME HAS_TIMEGM +syn keyword xsMacro HAS_TIMES HAS_TM_TM_GMTOFF HAS_TM_TM_ZONE HAS_TRUNC +syn keyword xsMacro HAS_TRUNCATE HAS_TRUNCL HAS_TZNAME HAS_UALARM HAS_UMASK +syn keyword xsMacro HAS_UNAME HAS_UNSETENV HAS_USLEEP HAS_USLEEP_PROTO +syn keyword xsMacro HAS_USTAT HAS_UTIME HAS_VPRINTF HAS_VSNPRINTF HAS_WAIT +syn keyword xsMacro HAS_WAIT4 HAS_WAITPID HAS_WCSCMP HAS_WCSTOMBS HAS_WCSXFRM +syn keyword xsMacro HAS_WCTOMB HAS_WRITEV HEK_BASESIZE HEK_FLAGS HEK_HASH +syn keyword xsMacro HEK_KEY HEK_LEN HEK_UTF8 HEK_UTF8_off HEK_UTF8_on +syn keyword xsMacro HEK_WASUTF8 HEK_WASUTF8_off HEK_WASUTF8_on HEKf HEKf256 +syn keyword xsMacro HEKfARG HE_SVSLOT HEf_SVKEY HINTS_REFCNT_INIT +syn keyword xsMacro HINTS_REFCNT_LOCK HINTS_REFCNT_TERM HINTS_REFCNT_UNLOCK +syn keyword xsMacro HINT_BLOCK_SCOPE HINT_BYTES HINT_EXPLICIT_STRICT_REFS +syn keyword xsMacro HINT_EXPLICIT_STRICT_SUBS HINT_EXPLICIT_STRICT_VARS +syn keyword xsMacro HINT_FEATURE_MASK HINT_FEATURE_SHIFT HINT_FILETEST_ACCESS +syn keyword xsMacro HINT_INTEGER HINT_LEXICAL_IO_IN HINT_LEXICAL_IO_OUT +syn keyword xsMacro HINT_LOCALE HINT_LOCALE_PARTIAL HINT_LOCALIZE_HH +syn keyword xsMacro HINT_NEW_BINARY HINT_NEW_FLOAT HINT_NEW_INTEGER +syn keyword xsMacro HINT_NEW_RE HINT_NEW_STRING HINT_NO_AMAGIC HINT_RE_EVAL +syn keyword xsMacro HINT_RE_FLAGS HINT_RE_TAINT HINT_SORT_MERGESORT +syn keyword xsMacro HINT_SORT_QUICKSORT HINT_SORT_SORT_BITS HINT_SORT_STABLE +syn keyword xsMacro HINT_STRICT_REFS HINT_STRICT_SUBS HINT_STRICT_VARS +syn keyword xsMacro HINT_UNI_8_BIT HINT_UTF8 HS_APIVERLEN_MAX HS_CXT +syn keyword xsMacro HS_GETAPIVERLEN HS_GETINTERPSIZE HS_GETXSVERLEN HS_KEY +syn keyword xsMacro HS_KEYp HS_XSVERLEN_MAX HSf_IMP_CXT HSf_NOCHK HSf_POPMARK +syn keyword xsMacro HSf_SETXSUBFN HSm_APIVERLEN HSm_INTRPSIZE HSm_KEY_MATCH +syn keyword xsMacro HSm_XSVERLEN HV_DELETE HV_DISABLE_UVAR_XKEY +syn keyword xsMacro HV_FETCH_EMPTY_HE HV_FETCH_ISEXISTS HV_FETCH_ISSTORE +syn keyword xsMacro HV_FETCH_JUST_SV HV_FETCH_LVALUE +syn keyword xsMacro HV_ITERNEXT_WANTPLACEHOLDERS HV_NAME_SETALL +syn keyword xsMacro HVhek_ENABLEHVKFLAGS HVhek_FREEKEY HVhek_KEYCANONICAL +syn keyword xsMacro HVhek_MASK HVhek_PLACEHOLD HVhek_UNSHARED HVhek_UTF8 +syn keyword xsMacro HVhek_WASUTF8 HVrhek_IV HVrhek_PV HVrhek_PV_UTF8 +syn keyword xsMacro HVrhek_UV HVrhek_delete HVrhek_typemask HVrhek_undef +syn keyword xsMacro HYPHEN_UTF8 H_EBCDIC_TABLES H_PERL H_REGCHARCLASS +syn keyword xsMacro H_UNICODE_CONSTANTS H_UTF8 HeHASH HeKEY HeKEY_hek +syn keyword xsMacro HeKEY_sv HeKFLAGS HeKLEN HeKLEN_UTF8 HeKUTF8 HeKWASUTF8 +syn keyword xsMacro HeNEXT HePV HeSVKEY HeSVKEY_force HeSVKEY_set HeUTF8 +syn keyword xsMacro HeVAL HvAMAGIC HvAMAGIC_off HvAMAGIC_on HvARRAY HvAUX +syn keyword xsMacro HvAUXf_NO_DEREF HvAUXf_SCAN_STASH HvEITER HvEITER_get +syn keyword xsMacro HvEITER_set HvENAME HvENAMELEN HvENAMELEN_get HvENAMEUTF8 +syn keyword xsMacro HvENAME_HEK HvENAME_HEK_NN HvENAME_get HvFILL HvHASKFLAGS +syn keyword xsMacro HvHASKFLAGS_off HvHASKFLAGS_on HvKEYS HvLASTRAND_get +syn keyword xsMacro HvLAZYDEL HvLAZYDEL_off HvLAZYDEL_on HvMAX HvMROMETA +syn keyword xsMacro HvNAME HvNAMELEN HvNAMELEN_get HvNAMEUTF8 HvNAME_HEK +syn keyword xsMacro HvNAME_HEK_NN HvNAME_get HvPLACEHOLDERS +syn keyword xsMacro HvPLACEHOLDERS_get HvPLACEHOLDERS_set HvRAND_get HvRITER +syn keyword xsMacro HvRITER_get HvRITER_set HvSHAREKEYS HvSHAREKEYS_off +syn keyword xsMacro HvSHAREKEYS_on HvTOTALKEYS HvUSEDKEYS I16SIZE I16TYPE +syn keyword xsMacro I16_MAX I16_MIN I32SIZE I32TYPE I32_MAX I32_MAX_P1 +syn keyword xsMacro I32_MIN I64SIZE I64TYPE I8SIZE I8TYPE I8_TO_NATIVE +syn keyword xsMacro I8_TO_NATIVE_UTF8 IF IFMATCH IFMATCH_A IFMATCH_A_fail +syn keyword xsMacro IFTHEN IGNORE_PAT_MOD ILLEGAL_UTF8_BYTE INIT INIT_THREADS +syn keyword xsMacro INIT_TRACK_MEMPOOL INSUBP INT2PTR INT32_MIN INT64_C +syn keyword xsMacro INT64_MIN INTSIZE INT_64_T INT_PAT_MODS IN_BYTES +syn keyword xsMacro IN_ENCODING IN_LC IN_LC_ALL_COMPILETIME IN_LC_ALL_RUNTIME +syn keyword xsMacro IN_LC_COMPILETIME IN_LC_PARTIAL_COMPILETIME +syn keyword xsMacro IN_LC_PARTIAL_RUNTIME IN_LC_RUNTIME IN_LOCALE +syn keyword xsMacro IN_LOCALE_COMPILETIME IN_LOCALE_RUNTIME +syn keyword xsMacro IN_PERL_COMPILETIME IN_PERL_RUNTIME IN_SOME_LOCALE_FORM +syn keyword xsMacro IN_SOME_LOCALE_FORM_COMPILETIME +syn keyword xsMacro IN_SOME_LOCALE_FORM_RUNTIME IN_UNI_8_BIT +syn keyword xsMacro IN_UTF8_CTYPE_LOCALE IOCPARM_LEN IOf_ARGV IOf_DIDTOP +syn keyword xsMacro IOf_FAKE_DIRP IOf_FLUSH IOf_NOLINE IOf_START IOf_UNTAINT +syn keyword xsMacro ISA_VERSION_OBJ IS_ANYOF_TRIE +syn keyword xsMacro IS_NUMBER_GREATER_THAN_UV_MAX IS_NUMBER_INFINITY +syn keyword xsMacro IS_NUMBER_IN_UV IS_NUMBER_NAN IS_NUMBER_NEG +syn keyword xsMacro IS_NUMBER_NOT_INT IS_NUMBER_TRAILING IS_NUMERIC_RADIX +syn keyword xsMacro IS_PADCONST IS_PADGV IS_SAFE_PATHNAME IS_SAFE_SYSCALL +syn keyword xsMacro IS_TRIE_AC IS_UTF8_CHAR IS_UTF8_CHAR_FAST IVSIZE IVTYPE +syn keyword xsMacro IV_DIG IV_MAX IV_MAX_P1 IV_MIN I_32 I_ARPA_INET I_ASSERT +syn keyword xsMacro I_BFD I_CRYPT I_DBM I_DIRENT I_DLFCN I_EXECINFO I_FENV +syn keyword xsMacro I_FLOAT I_GDBM I_GDBMNDBM I_GRP I_INTTYPES I_LANGINFO +syn keyword xsMacro I_LIMITS I_LOCALE I_MATH I_MNTENT I_NETDB I_NETINET_IN +syn keyword xsMacro I_NETINET_TCP I_POLL I_PTHREAD I_PWD I_QUADMATH I_SHADOW +syn keyword xsMacro I_STDARG I_STDBOOL I_STDDEF I_STDINT I_STDLIB I_STRING +syn keyword xsMacro I_SYSLOG I_SYSUIO I_SYSUTSNAME I_SYS_DIR I_SYS_FILE +syn keyword xsMacro I_SYS_IOCTL I_SYS_MOUNT I_SYS_PARAM I_SYS_POLL +syn keyword xsMacro I_SYS_RESOURCE I_SYS_SELECT I_SYS_STAT I_SYS_STATFS +syn keyword xsMacro I_SYS_STATVFS I_SYS_TIME I_SYS_TIMES I_SYS_TYPES I_SYS_UN +syn keyword xsMacro I_SYS_VFS I_SYS_WAIT I_TERMIOS I_TIME I_UNISTD I_USTAT +syn keyword xsMacro I_UTIME I_V I_VALUES IoANY IoBOTTOM_GV IoBOTTOM_NAME +syn keyword xsMacro IoDIRP IoFLAGS IoFMT_GV IoFMT_NAME IoIFP IoLINES +syn keyword xsMacro IoLINES_LEFT IoOFP IoPAGE IoPAGE_LEN IoTOP_GV IoTOP_NAME +syn keyword xsMacro IoTYPE IoTYPE_APPEND IoTYPE_CLOSED IoTYPE_IMPLICIT +syn keyword xsMacro IoTYPE_NUMERIC IoTYPE_PIPE IoTYPE_RDONLY IoTYPE_RDWR +syn keyword xsMacro IoTYPE_SOCKET IoTYPE_STD IoTYPE_WRONLY IsSet +syn keyword xsMacro JMPENV_BOOTSTRAP JMPENV_JUMP JMPENV_POP JMPENV_PUSH JOIN +syn keyword xsMacro KEEPCOPY_PAT_MOD KEEPCOPY_PAT_MODS KEEPS KEEPS_next +syn keyword xsMacro KEEPS_next_fail KELVIN_SIGN KEYWORD_PLUGIN_DECLINE +syn keyword xsMacro KEYWORD_PLUGIN_EXPR KEYWORD_PLUGIN_STMT KEY_AUTOLOAD +syn keyword xsMacro KEY_BEGIN KEY_CHECK KEY_DESTROY KEY_END KEY_INIT KEY_NULL +syn keyword xsMacro KEY_UNITCHECK KEY___DATA__ KEY___END__ KEY___FILE__ +syn keyword xsMacro KEY___LINE__ KEY___PACKAGE__ KEY___SUB__ KEY_abs +syn keyword xsMacro KEY_accept KEY_alarm KEY_and KEY_atan2 KEY_bind +syn keyword xsMacro KEY_binmode KEY_bless KEY_break KEY_caller KEY_chdir +syn keyword xsMacro KEY_chmod KEY_chomp KEY_chop KEY_chown KEY_chr KEY_chroot +syn keyword xsMacro KEY_close KEY_closedir KEY_cmp KEY_connect KEY_continue +syn keyword xsMacro KEY_cos KEY_crypt KEY_dbmclose KEY_dbmopen KEY_default +syn keyword xsMacro KEY_defined KEY_delete KEY_die KEY_do KEY_dump KEY_each +syn keyword xsMacro KEY_else KEY_elsif KEY_endgrent KEY_endhostent +syn keyword xsMacro KEY_endnetent KEY_endprotoent KEY_endpwent KEY_endservent +syn keyword xsMacro KEY_eof KEY_eq KEY_eval KEY_evalbytes KEY_exec KEY_exists +syn keyword xsMacro KEY_exit KEY_exp KEY_fc KEY_fcntl KEY_fileno KEY_flock +syn keyword xsMacro KEY_for KEY_foreach KEY_fork KEY_format KEY_formline +syn keyword xsMacro KEY_ge KEY_getc KEY_getgrent KEY_getgrgid KEY_getgrnam +syn keyword xsMacro KEY_gethostbyaddr KEY_gethostbyname KEY_gethostent +syn keyword xsMacro KEY_getlogin KEY_getnetbyaddr KEY_getnetbyname +syn keyword xsMacro KEY_getnetent KEY_getpeername KEY_getpgrp KEY_getppid +syn keyword xsMacro KEY_getpriority KEY_getprotobyname KEY_getprotobynumber +syn keyword xsMacro KEY_getprotoent KEY_getpwent KEY_getpwnam KEY_getpwuid +syn keyword xsMacro KEY_getservbyname KEY_getservbyport KEY_getservent +syn keyword xsMacro KEY_getsockname KEY_getsockopt KEY_given KEY_glob +syn keyword xsMacro KEY_gmtime KEY_goto KEY_grep KEY_gt KEY_hex KEY_if +syn keyword xsMacro KEY_index KEY_int KEY_ioctl KEY_join KEY_keys KEY_kill +syn keyword xsMacro KEY_last KEY_lc KEY_lcfirst KEY_le KEY_length KEY_link +syn keyword xsMacro KEY_listen KEY_local KEY_localtime KEY_lock KEY_log +syn keyword xsMacro KEY_lstat KEY_lt KEY_m KEY_map KEY_mkdir KEY_msgctl +syn keyword xsMacro KEY_msgget KEY_msgrcv KEY_msgsnd KEY_my KEY_ne KEY_next +syn keyword xsMacro KEY_no KEY_not KEY_oct KEY_open KEY_opendir KEY_or +syn keyword xsMacro KEY_ord KEY_our KEY_pack KEY_package KEY_pipe KEY_pop +syn keyword xsMacro KEY_pos KEY_print KEY_printf KEY_prototype KEY_push KEY_q +syn keyword xsMacro KEY_qq KEY_qr KEY_quotemeta KEY_qw KEY_qx KEY_rand +syn keyword xsMacro KEY_read KEY_readdir KEY_readline KEY_readlink +syn keyword xsMacro KEY_readpipe KEY_recv KEY_redo KEY_ref KEY_rename +syn keyword xsMacro KEY_require KEY_reset KEY_return KEY_reverse +syn keyword xsMacro KEY_rewinddir KEY_rindex KEY_rmdir KEY_s KEY_say +syn keyword xsMacro KEY_scalar KEY_seek KEY_seekdir KEY_select KEY_semctl +syn keyword xsMacro KEY_semget KEY_semop KEY_send KEY_setgrent KEY_sethostent +syn keyword xsMacro KEY_setnetent KEY_setpgrp KEY_setpriority KEY_setprotoent +syn keyword xsMacro KEY_setpwent KEY_setservent KEY_setsockopt KEY_shift +syn keyword xsMacro KEY_shmctl KEY_shmget KEY_shmread KEY_shmwrite +syn keyword xsMacro KEY_shutdown KEY_sin KEY_sleep KEY_socket KEY_socketpair +syn keyword xsMacro KEY_sort KEY_splice KEY_split KEY_sprintf KEY_sqrt +syn keyword xsMacro KEY_srand KEY_stat KEY_state KEY_study KEY_sub KEY_substr +syn keyword xsMacro KEY_symlink KEY_syscall KEY_sysopen KEY_sysread +syn keyword xsMacro KEY_sysseek KEY_system KEY_syswrite KEY_tell KEY_telldir +syn keyword xsMacro KEY_tie KEY_tied KEY_time KEY_times KEY_tr KEY_truncate +syn keyword xsMacro KEY_uc KEY_ucfirst KEY_umask KEY_undef KEY_unless +syn keyword xsMacro KEY_unlink KEY_unpack KEY_unshift KEY_untie KEY_until +syn keyword xsMacro KEY_use KEY_utime KEY_values KEY_vec KEY_wait KEY_waitpid +syn keyword xsMacro KEY_wantarray KEY_warn KEY_when KEY_while KEY_write KEY_x +syn keyword xsMacro KEY_xor KEY_y LABEL LATIN1_TO_NATIVE +syn keyword xsMacro LATIN_CAPITAL_LETTER_A_WITH_RING_ABOVE +syn keyword xsMacro LATIN_CAPITAL_LETTER_A_WITH_RING_ABOVE_NATIVE +syn keyword xsMacro LATIN_CAPITAL_LETTER_SHARP_S +syn keyword xsMacro LATIN_CAPITAL_LETTER_SHARP_S_UTF8 +syn keyword xsMacro LATIN_CAPITAL_LETTER_Y_WITH_DIAERESIS +syn keyword xsMacro LATIN_SMALL_LETTER_A_WITH_RING_ABOVE +syn keyword xsMacro LATIN_SMALL_LETTER_A_WITH_RING_ABOVE_NATIVE +syn keyword xsMacro LATIN_SMALL_LETTER_LONG_S LATIN_SMALL_LETTER_LONG_S_UTF8 +syn keyword xsMacro LATIN_SMALL_LETTER_SHARP_S +syn keyword xsMacro LATIN_SMALL_LETTER_SHARP_S_NATIVE +syn keyword xsMacro LATIN_SMALL_LETTER_Y_WITH_DIAERESIS +syn keyword xsMacro LATIN_SMALL_LETTER_Y_WITH_DIAERESIS_NATIVE +syn keyword xsMacro LATIN_SMALL_LIGATURE_LONG_S_T +syn keyword xsMacro LATIN_SMALL_LIGATURE_LONG_S_T_UTF8 +syn keyword xsMacro LATIN_SMALL_LIGATURE_ST LATIN_SMALL_LIGATURE_ST_UTF8 +syn keyword xsMacro LDBL_DIG LEAVE LEAVESUB LEAVE_SCOPE LEAVE_with_name +syn keyword xsMacro LEX_DONT_CLOSE_RSFP LEX_EVALBYTES LEX_IGNORE_UTF8_HINTS +syn keyword xsMacro LEX_KEEP_PREVIOUS LEX_NOTPARSING LEX_START_COPIED +syn keyword xsMacro LEX_START_FLAGS LEX_START_SAME_FILTER LEX_STUFF_UTF8 +syn keyword xsMacro LF_NATIVE LIBERAL LIBM_LIB_VERSION LIB_INVARG LIKELY +syn keyword xsMacro LINKLIST LNBREAK LOADED_FILE_PROBE LOADING_FILE_PROBE +syn keyword xsMacro LOCAL LOCALE_PAT_MOD LOCALE_PAT_MODS LOCALTIME_MAX +syn keyword xsMacro LOCALTIME_MIN LOCALTIME_R LOCALTIME_R_PROTO +syn keyword xsMacro LOCAL_PATCH_COUNT LOCK_DOLLARZERO_MUTEX +syn keyword xsMacro LOCK_LC_NUMERIC_STANDARD LOCK_NUMERIC_STANDARD LOC_SED +syn keyword xsMacro LOGICAL LONGDOUBLE_BIG_ENDIAN LONGDOUBLE_DOUBLEDOUBLE +syn keyword xsMacro LONGDOUBLE_LITTLE_ENDIAN LONGDOUBLE_X86_80_BIT LONGJMP +syn keyword xsMacro LONGLONGSIZE LONGSIZE LONG_DOUBLEKIND LONG_DOUBLESIZE +syn keyword xsMacro LONG_DOUBLE_EQUALS_DOUBLE LONG_DOUBLE_IS_DOUBLE +syn keyword xsMacro LONG_DOUBLE_IS_DOUBLEDOUBLE_128_BIT_BIG_ENDIAN +syn keyword xsMacro LONG_DOUBLE_IS_DOUBLEDOUBLE_128_BIT_LITTLE_ENDIAN +syn keyword xsMacro LONG_DOUBLE_IS_IEEE_754_128_BIT_BIG_ENDIAN +syn keyword xsMacro LONG_DOUBLE_IS_IEEE_754_128_BIT_LITTLE_ENDIAN +syn keyword xsMacro LONG_DOUBLE_IS_UNKNOWN_FORMAT +syn keyword xsMacro LONG_DOUBLE_IS_X86_80_BIT_BIG_ENDIAN +syn keyword xsMacro LONG_DOUBLE_IS_X86_80_BIT_LITTLE_ENDIAN LOOPEX +syn keyword xsMacro LOOP_PAT_MODS LSEEKSIZE LSTOP LSTOPSUB LVRET L_R_TZSET +syn keyword xsMacro LvFLAGS LvSTARGOFF LvTARG LvTARGLEN LvTARGOFF LvTYPE +syn keyword xsMacro MALLOC_CHECK_TAINT MALLOC_CHECK_TAINT2 MALLOC_CTL_H +syn keyword xsMacro MALLOC_INIT MALLOC_OVERHEAD MALLOC_TERM +syn keyword xsMacro MALLOC_TOO_LATE_FOR MARKPOINT MARKPOINT_next +syn keyword xsMacro MARKPOINT_next_fail MASK MATCHOP MAXARG MAXO MAXPATHLEN +syn keyword xsMacro MAXSYSFD MAX_CHARSET_NAME_LENGTH MAX_FEATURE_LEN +syn keyword xsMacro MAX_PORTABLE_UTF8_TWO_BYTE +syn keyword xsMacro MAX_PRINT_A_FOR_USE_ONLY_BY_REGCOMP_DOT_C +syn keyword xsMacro MAX_RECURSE_EVAL_NOCHANGE_DEPTH MAX_UTF8_TWO_BYTE +syn keyword xsMacro MAYBE_DEREF_GV MAYBE_DEREF_GV_flags MAYBE_DEREF_GV_nomg +syn keyword xsMacro MBOL MB_CUR_MAX MDEREF_ACTION_MASK MDEREF_AV_gvav_aelem +syn keyword xsMacro MDEREF_AV_gvsv_vivify_rv2av_aelem MDEREF_AV_padav_aelem +syn keyword xsMacro MDEREF_AV_padsv_vivify_rv2av_aelem +syn keyword xsMacro MDEREF_AV_pop_rv2av_aelem MDEREF_AV_vivify_rv2av_aelem +syn keyword xsMacro MDEREF_FLAG_last MDEREF_HV_gvhv_helem +syn keyword xsMacro MDEREF_HV_gvsv_vivify_rv2hv_helem MDEREF_HV_padhv_helem +syn keyword xsMacro MDEREF_HV_padsv_vivify_rv2hv_helem +syn keyword xsMacro MDEREF_HV_pop_rv2hv_helem MDEREF_HV_vivify_rv2hv_helem +syn keyword xsMacro MDEREF_INDEX_MASK MDEREF_INDEX_const MDEREF_INDEX_gvsv +syn keyword xsMacro MDEREF_INDEX_none MDEREF_INDEX_padsv MDEREF_MASK +syn keyword xsMacro MDEREF_SHIFT MDEREF_reload MEMBER_TO_FPTR MEM_ALIGNBYTES +syn keyword xsMacro MEM_LOG_ALLOC MEM_LOG_FREE MEM_LOG_REALLOC MEM_SIZE +syn keyword xsMacro MEM_SIZE_MAX MEM_WRAP_CHECK MEM_WRAP_CHECK_ +syn keyword xsMacro MEM_WRAP_CHECK_1 MEM_WRAP_CHECK_2 MEOL METHOD MEXTEND +syn keyword xsMacro MGf_BYTES MGf_COPY MGf_DUP MGf_GSKIP MGf_LOCAL +syn keyword xsMacro MGf_MINMATCH MGf_PERSIST MGf_REFCOUNTED MGf_REQUIRE_GV +syn keyword xsMacro MGf_TAINTEDDIR MICRO_SIGN MICRO_SIGN_NATIVE MINMOD +syn keyword xsMacro MJD_OFFSET_DEBUG MRO_GET_PRIVATE_DATA MSPAGAIN MULOP +syn keyword xsMacro MULTICALL MULTILINE_PAT_MOD MULTIPLICITY MURMUR_C1 +syn keyword xsMacro MURMUR_C2 MURMUR_C3 MURMUR_C4 MURMUR_C5 MURMUR_DOBLOCK +syn keyword xsMacro MURMUR_DOBYTES MUTABLE_AV MUTABLE_CV MUTABLE_GV +syn keyword xsMacro MUTABLE_HV MUTABLE_IO MUTABLE_PTR MUTABLE_SV +syn keyword xsMacro MUTEX_DESTROY MUTEX_INIT MUTEX_INIT_NEEDS_MUTEX_ZEROED +syn keyword xsMacro MUTEX_LOCK MUTEX_UNLOCK MY MY_CXT_CLONE MY_CXT_INDEX +syn keyword xsMacro MY_CXT_INIT MY_CXT_INIT_ARG MY_CXT_INIT_INTERP M_PAT_MODS +syn keyword xsMacro MgBYTEPOS MgBYTEPOS_set MgPV MgPV_const MgPV_nolen_const +syn keyword xsMacro MgTAINTEDDIR MgTAINTEDDIR_off MgTAINTEDDIR_on Mkdir Move +syn keyword xsMacro MoveD NAN_COMPARE_BROKEN NATIVE8_TO_UNI +syn keyword xsMacro NATIVE_BYTE_IS_INVARIANT NATIVE_SKIP NATIVE_TO_ASCII +syn keyword xsMacro NATIVE_TO_I8 NATIVE_TO_LATIN1 NATIVE_TO_UNI NATIVE_TO_UTF +syn keyword xsMacro NATIVE_UTF8_TO_I8 NBOUND NBOUNDA NBOUNDL NBOUNDU +syn keyword xsMacro NBSP_NATIVE NBSP_UTF8 NDBM_H_USES_PROTOTYPES NDEBUG +syn keyword xsMacro NEED_PTHREAD_INIT NEED_VA_COPY NEGATIVE_INDICES_VAR +syn keyword xsMacro NETDB_R_OBSOLETE NEWSV NEW_VERSION NEXTOPER +syn keyword xsMacro NEXT_LINE_CHAR NEXT_OFF NGROUPP NOAMP NOCAPTURE_PAT_MOD +syn keyword xsMacro NOCAPTURE_PAT_MODS NODE_ALIGN NODE_ALIGN_FILL NODE_STEP_B +syn keyword xsMacro NODE_STEP_REGNODE NODE_SZ_STR NOLINE NONDESTRUCT_PAT_MOD +syn keyword xsMacro NONDESTRUCT_PAT_MODS +syn keyword xsMacro NON_OTHER_COUNT_FOR_USE_ONLY_BY_REGCOMP_DOT_C NOOP +syn keyword xsMacro NORETURN_FUNCTION_END NORMAL NOTHING NOTOP NOT_IN_PAD +syn keyword xsMacro NOT_REACHED NO_ENV_ARRAY_IN_MAIN NO_LOCALE +syn keyword xsMacro NO_LOCALECONV_MON_THOUSANDS_SEP NO_TAINT_SUPPORT NPOSIXA +syn keyword xsMacro NPOSIXD NPOSIXL NPOSIXU NREF NREFF NREFFA NREFFL NREFFU +syn keyword xsMacro NSIG NUM2PTR NUM_ANYOF_CODE_POINTS NVSIZE NVTYPE +syn keyword xsMacro NV_BIG_ENDIAN NV_DIG NV_EPSILON NV_INF NV_LITTLE_ENDIAN +syn keyword xsMacro NV_MANT_DIG NV_MAX NV_MAX_10_EXP NV_MAX_EXP NV_MIN +syn keyword xsMacro NV_MIN_10_EXP NV_MIN_EXP NV_MIX_ENDIAN NV_NAN +syn keyword xsMacro NV_OVERFLOWS_INTEGERS_AT NV_PRESERVES_UV_BITS +syn keyword xsMacro NV_WITHIN_IV NV_WITHIN_UV New NewOp NewOpSz Newc Newx +syn keyword xsMacro Newxc Newxz Newz NofAMmeth Null Nullav Nullch Nullcv +syn keyword xsMacro Nullfp Nullgv Nullhe Nullhek Nullhv Nullop Nullsv OASHIFT +syn keyword xsMacro OCSHIFT OCTAL_VALUE OFFUNISKIP ONCE_PAT_MOD ONCE_PAT_MODS +syn keyword xsMacro OPEN OPERAND OPFAIL OPSLOT_HEADER OPSLOT_HEADER_P +syn keyword xsMacro OPTIMIZED OP_BINARY OP_CHECK_MUTEX_INIT +syn keyword xsMacro OP_CHECK_MUTEX_LOCK OP_CHECK_MUTEX_TERM +syn keyword xsMacro OP_CHECK_MUTEX_UNLOCK OP_CLASS OP_DESC OP_ENTRY_PROBE +syn keyword xsMacro OP_FREED OP_GIMME OP_GIMME_REVERSE OP_IS_DIRHOP +syn keyword xsMacro OP_IS_FILETEST OP_IS_FILETEST_ACCESS OP_IS_INFIX_BIT +syn keyword xsMacro OP_IS_NUMCOMPARE OP_IS_SOCKET OP_LVALUE_NO_CROAK OP_NAME +syn keyword xsMacro OP_REFCNT_INIT OP_REFCNT_LOCK OP_REFCNT_TERM +syn keyword xsMacro OP_REFCNT_UNLOCK OP_SIBLING OP_TYPE_IS OP_TYPE_ISNT +syn keyword xsMacro OP_TYPE_ISNT_AND_WASNT OP_TYPE_ISNT_AND_WASNT_NN +syn keyword xsMacro OP_TYPE_ISNT_NN OP_TYPE_IS_NN OP_TYPE_IS_OR_WAS +syn keyword xsMacro OP_TYPE_IS_OR_WAS_NN OROP OROR OSNAME OSVERS O_CREAT +syn keyword xsMacro O_RDONLY O_RDWR O_TEXT O_WRONLY Off Off_t_size +syn keyword xsMacro OpHAS_SIBLING OpLASTSIB_set OpMAYBESIB_set OpMORESIB_set +syn keyword xsMacro OpREFCNT_dec OpREFCNT_inc OpREFCNT_set OpSIBLING OpSLAB +syn keyword xsMacro OpSLOT OpslabREFCNT_dec OpslabREFCNT_dec_padok OutCopFILE +syn keyword xsMacro PADNAME_FROM_PV PADNAMEt_LVALUE PADNAMEt_OUR +syn keyword xsMacro PADNAMEt_OUTER PADNAMEt_STATE PADNAMEt_TYPED PAD_BASE_SV +syn keyword xsMacro PAD_CLONE_VARS PAD_COMPNAME PAD_COMPNAME_FLAGS +syn keyword xsMacro PAD_COMPNAME_FLAGS_isOUR PAD_COMPNAME_GEN +syn keyword xsMacro PAD_COMPNAME_GEN_set PAD_COMPNAME_OURSTASH +syn keyword xsMacro PAD_COMPNAME_PV PAD_COMPNAME_SV PAD_COMPNAME_TYPE +syn keyword xsMacro PAD_FAKELEX_ANON PAD_FAKELEX_MULTI PAD_RESTORE_LOCAL +syn keyword xsMacro PAD_SAVE_LOCAL PAD_SAVE_SETNULLPAD PAD_SETSV PAD_SET_CUR +syn keyword xsMacro PAD_SET_CUR_NOSAVE PAD_SV PAD_SVl PARENT_FAKELEX_FLAGS +syn keyword xsMacro PARENT_PAD_INDEX PARSE_OPTIONAL PASS1 PASS2 PATCHLEVEL +syn keyword xsMacro PERLDB_ALL PERLDB_GOTO PERLDB_INTER PERLDB_LINE +syn keyword xsMacro PERLDB_NAMEANON PERLDB_NAMEEVAL PERLDB_NOOPT +syn keyword xsMacro PERLDB_SAVESRC PERLDB_SAVESRC_INVALID +syn keyword xsMacro PERLDB_SAVESRC_NOSUBS PERLDB_SINGLE PERLDB_SUB +syn keyword xsMacro PERLDB_SUBLINE PERLDB_SUB_NN PERLDBf_GOTO PERLDBf_INTER +syn keyword xsMacro PERLDBf_LINE PERLDBf_NAMEANON PERLDBf_NAMEEVAL +syn keyword xsMacro PERLDBf_NONAME PERLDBf_NOOPT PERLDBf_SAVESRC +syn keyword xsMacro PERLDBf_SAVESRC_INVALID PERLDBf_SAVESRC_NOSUBS +syn keyword xsMacro PERLDBf_SINGLE PERLDBf_SUB PERLDBf_SUBLINE +syn keyword xsMacro PERLIOBUF_DEFAULT_BUFSIZ PERLIO_DUP_CLONE PERLIO_DUP_FD +syn keyword xsMacro PERLIO_FUNCS_CAST PERLIO_FUNCS_CONST PERLIO_FUNCS_DECL +syn keyword xsMacro PERLIO_F_APPEND PERLIO_F_CANREAD PERLIO_F_CANWRITE +syn keyword xsMacro PERLIO_F_CLEARED PERLIO_F_CRLF PERLIO_F_EOF +syn keyword xsMacro PERLIO_F_ERROR PERLIO_F_FASTGETS PERLIO_F_LINEBUF +syn keyword xsMacro PERLIO_F_NOTREG PERLIO_F_OPEN PERLIO_F_RDBUF +syn keyword xsMacro PERLIO_F_TEMP PERLIO_F_TRUNCATE PERLIO_F_TTY +syn keyword xsMacro PERLIO_F_UNBUF PERLIO_F_UTF8 PERLIO_F_WRBUF PERLIO_INIT +syn keyword xsMacro PERLIO_IS_STDIO PERLIO_K_BUFFERED PERLIO_K_CANCRLF +syn keyword xsMacro PERLIO_K_DESTRUCT PERLIO_K_DUMMY PERLIO_K_FASTGETS +syn keyword xsMacro PERLIO_K_MULTIARG PERLIO_K_RAW PERLIO_K_UTF8 +syn keyword xsMacro PERLIO_LAYERS PERLIO_NOT_STDIO PERLIO_STDTEXT PERLIO_TERM +syn keyword xsMacro PERLIO_USING_CRLF PERLSI_DESTROY PERLSI_DIEHOOK +syn keyword xsMacro PERLSI_MAGIC PERLSI_MAIN PERLSI_OVERLOAD PERLSI_REQUIRE +syn keyword xsMacro PERLSI_SIGNAL PERLSI_SORT PERLSI_UNDEF PERLSI_UNKNOWN +syn keyword xsMacro PERLSI_WARNHOOK PERL_ABS PERL_ALLOC_CHECK PERL_ANY_COW +syn keyword xsMacro PERL_API_REVISION PERL_API_SUBVERSION PERL_API_VERSION +syn keyword xsMacro PERL_API_VERSION_STRING PERL_ARENA_ROOTS_SIZE +syn keyword xsMacro PERL_ARENA_SIZE PERL_ARGS_ASSERT_ADD_ABOVE_LATIN1_FOLDS +syn keyword xsMacro PERL_ARGS_ASSERT_ADD_DATA +syn keyword xsMacro PERL_ARGS_ASSERT_ADD_MULTI_MATCH +syn keyword xsMacro PERL_ARGS_ASSERT_ADD_UTF16_TEXTFILTER +syn keyword xsMacro PERL_ARGS_ASSERT_ADJUST_SIZE_AND_FIND_BUCKET +syn keyword xsMacro PERL_ARGS_ASSERT_ADVANCE_ONE_SB +syn keyword xsMacro PERL_ARGS_ASSERT_ADVANCE_ONE_WB +syn keyword xsMacro PERL_ARGS_ASSERT_ALLOCCOPSTASH PERL_ARGS_ASSERT_ALLOCMY +syn keyword xsMacro PERL_ARGS_ASSERT_ALLOC_MAYBE_POPULATE_EXACT +syn keyword xsMacro PERL_ARGS_ASSERT_AMAGIC_CALL PERL_ARGS_ASSERT_AMAGIC_CMP +syn keyword xsMacro PERL_ARGS_ASSERT_AMAGIC_CMP_LOCALE +syn keyword xsMacro PERL_ARGS_ASSERT_AMAGIC_DEREF_CALL +syn keyword xsMacro PERL_ARGS_ASSERT_AMAGIC_I_NCMP +syn keyword xsMacro PERL_ARGS_ASSERT_AMAGIC_NCMP +syn keyword xsMacro PERL_ARGS_ASSERT_ANONYMISE_CV_MAYBE +syn keyword xsMacro PERL_ARGS_ASSERT_ANY_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_APPEND_UTF8_FROM_NATIVE_BYTE +syn keyword xsMacro PERL_ARGS_ASSERT_APPLY PERL_ARGS_ASSERT_APPLY_ATTRS +syn keyword xsMacro PERL_ARGS_ASSERT_APPLY_ATTRS_MY +syn keyword xsMacro PERL_ARGS_ASSERT_APPLY_ATTRS_STRING +syn keyword xsMacro PERL_ARGS_ASSERT_ASSERT_UFT8_CACHE_COHERENT +syn keyword xsMacro PERL_ARGS_ASSERT_AV_ARYLEN_P PERL_ARGS_ASSERT_AV_CLEAR +syn keyword xsMacro PERL_ARGS_ASSERT_AV_CREATE_AND_PUSH +syn keyword xsMacro PERL_ARGS_ASSERT_AV_CREATE_AND_UNSHIFT_ONE +syn keyword xsMacro PERL_ARGS_ASSERT_AV_DELETE PERL_ARGS_ASSERT_AV_EXISTS +syn keyword xsMacro PERL_ARGS_ASSERT_AV_EXTEND +syn keyword xsMacro PERL_ARGS_ASSERT_AV_EXTEND_GUTS PERL_ARGS_ASSERT_AV_FETCH +syn keyword xsMacro PERL_ARGS_ASSERT_AV_FILL PERL_ARGS_ASSERT_AV_ITER_P +syn keyword xsMacro PERL_ARGS_ASSERT_AV_LEN PERL_ARGS_ASSERT_AV_MAKE +syn keyword xsMacro PERL_ARGS_ASSERT_AV_POP PERL_ARGS_ASSERT_AV_PUSH +syn keyword xsMacro PERL_ARGS_ASSERT_AV_REIFY PERL_ARGS_ASSERT_AV_SHIFT +syn keyword xsMacro PERL_ARGS_ASSERT_AV_STORE PERL_ARGS_ASSERT_AV_TOP_INDEX +syn keyword xsMacro PERL_ARGS_ASSERT_AV_UNDEF PERL_ARGS_ASSERT_AV_UNSHIFT +syn keyword xsMacro PERL_ARGS_ASSERT_BACKUP_ONE_SB +syn keyword xsMacro PERL_ARGS_ASSERT_BACKUP_ONE_WB +syn keyword xsMacro PERL_ARGS_ASSERT_BAD_TYPE_GV PERL_ARGS_ASSERT_BAD_TYPE_PV +syn keyword xsMacro PERL_ARGS_ASSERT_BIND_MATCH +syn keyword xsMacro PERL_ARGS_ASSERT_BLOCKHOOK_REGISTER +syn keyword xsMacro PERL_ARGS_ASSERT_BYTES_CMP_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_BYTES_FROM_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_BYTES_TO_UTF8 PERL_ARGS_ASSERT_CALL_ARGV +syn keyword xsMacro PERL_ARGS_ASSERT_CALL_LIST PERL_ARGS_ASSERT_CALL_METHOD +syn keyword xsMacro PERL_ARGS_ASSERT_CALL_PV PERL_ARGS_ASSERT_CALL_SV +syn keyword xsMacro PERL_ARGS_ASSERT_CANDO PERL_ARGS_ASSERT_CHECKCOMMA +syn keyword xsMacro PERL_ARGS_ASSERT_CHECK_LOCALE_BOUNDARY_CROSSING +syn keyword xsMacro PERL_ARGS_ASSERT_CHECK_TYPE_AND_OPEN +syn keyword xsMacro PERL_ARGS_ASSERT_CHECK_UTF8_PRINT +syn keyword xsMacro PERL_ARGS_ASSERT_CK_ANONCODE PERL_ARGS_ASSERT_CK_BACKTICK +syn keyword xsMacro PERL_ARGS_ASSERT_CK_BITOP PERL_ARGS_ASSERT_CK_CMP +syn keyword xsMacro PERL_ARGS_ASSERT_CK_CONCAT PERL_ARGS_ASSERT_CK_DEFINED +syn keyword xsMacro PERL_ARGS_ASSERT_CK_DELETE PERL_ARGS_ASSERT_CK_EACH +syn keyword xsMacro PERL_ARGS_ASSERT_CK_ENTERSUB_ARGS_CORE +syn keyword xsMacro PERL_ARGS_ASSERT_CK_ENTERSUB_ARGS_LIST +syn keyword xsMacro PERL_ARGS_ASSERT_CK_ENTERSUB_ARGS_PROTO +syn keyword xsMacro PERL_ARGS_ASSERT_CK_ENTERSUB_ARGS_PROTO_OR_LIST +syn keyword xsMacro PERL_ARGS_ASSERT_CK_EOF PERL_ARGS_ASSERT_CK_EVAL +syn keyword xsMacro PERL_ARGS_ASSERT_CK_EXEC PERL_ARGS_ASSERT_CK_EXISTS +syn keyword xsMacro PERL_ARGS_ASSERT_CK_FTST PERL_ARGS_ASSERT_CK_FUN +syn keyword xsMacro PERL_ARGS_ASSERT_CK_GLOB PERL_ARGS_ASSERT_CK_GREP +syn keyword xsMacro PERL_ARGS_ASSERT_CK_INDEX PERL_ARGS_ASSERT_CK_JOIN +syn keyword xsMacro PERL_ARGS_ASSERT_CK_LENGTH PERL_ARGS_ASSERT_CK_LFUN +syn keyword xsMacro PERL_ARGS_ASSERT_CK_LISTIOB PERL_ARGS_ASSERT_CK_MATCH +syn keyword xsMacro PERL_ARGS_ASSERT_CK_METHOD PERL_ARGS_ASSERT_CK_NULL +syn keyword xsMacro PERL_ARGS_ASSERT_CK_OPEN PERL_ARGS_ASSERT_CK_PROTOTYPE +syn keyword xsMacro PERL_ARGS_ASSERT_CK_READLINE +syn keyword xsMacro PERL_ARGS_ASSERT_CK_REFASSIGN PERL_ARGS_ASSERT_CK_REPEAT +syn keyword xsMacro PERL_ARGS_ASSERT_CK_REQUIRE PERL_ARGS_ASSERT_CK_RETURN +syn keyword xsMacro PERL_ARGS_ASSERT_CK_RFUN PERL_ARGS_ASSERT_CK_RVCONST +syn keyword xsMacro PERL_ARGS_ASSERT_CK_SASSIGN PERL_ARGS_ASSERT_CK_SELECT +syn keyword xsMacro PERL_ARGS_ASSERT_CK_SHIFT PERL_ARGS_ASSERT_CK_SMARTMATCH +syn keyword xsMacro PERL_ARGS_ASSERT_CK_SORT PERL_ARGS_ASSERT_CK_SPAIR +syn keyword xsMacro PERL_ARGS_ASSERT_CK_SPLIT PERL_ARGS_ASSERT_CK_STRINGIFY +syn keyword xsMacro PERL_ARGS_ASSERT_CK_SUBR PERL_ARGS_ASSERT_CK_SUBSTR +syn keyword xsMacro PERL_ARGS_ASSERT_CK_SVCONST PERL_ARGS_ASSERT_CK_TELL +syn keyword xsMacro PERL_ARGS_ASSERT_CK_TRUNC PERL_ARGS_ASSERT_CK_WARNER +syn keyword xsMacro PERL_ARGS_ASSERT_CK_WARNER_D +syn keyword xsMacro PERL_ARGS_ASSERT_CLEAR_PLACEHOLDERS +syn keyword xsMacro PERL_ARGS_ASSERT_CLEAR_SPECIAL_BLOCKS +syn keyword xsMacro PERL_ARGS_ASSERT_CLONE_PARAMS_DEL +syn keyword xsMacro PERL_ARGS_ASSERT_CLONE_PARAMS_NEW +syn keyword xsMacro PERL_ARGS_ASSERT_CLOSEST_COP +syn keyword xsMacro PERL_ARGS_ASSERT_COMPUTE_EXACTISH +syn keyword xsMacro PERL_ARGS_ASSERT_CONSTRUCT_AHOCORASICK_FROM_TRIE +syn keyword xsMacro PERL_ARGS_ASSERT_COP_FETCH_LABEL +syn keyword xsMacro PERL_ARGS_ASSERT_COP_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_COP_STORE_LABEL +syn keyword xsMacro PERL_ARGS_ASSERT_CORESUB_OP +syn keyword xsMacro PERL_ARGS_ASSERT_CORE_PROTOTYPE +syn keyword xsMacro PERL_ARGS_ASSERT_COULD_IT_BE_A_POSIX_CLASS +syn keyword xsMacro PERL_ARGS_ASSERT_CROAK_SV PERL_ARGS_ASSERT_CROAK_XS_USAGE +syn keyword xsMacro PERL_ARGS_ASSERT_CURSE PERL_ARGS_ASSERT_CUSTOM_OP_DESC +syn keyword xsMacro PERL_ARGS_ASSERT_CUSTOM_OP_GET_FIELD +syn keyword xsMacro PERL_ARGS_ASSERT_CUSTOM_OP_NAME +syn keyword xsMacro PERL_ARGS_ASSERT_CUSTOM_OP_REGISTER +syn keyword xsMacro PERL_ARGS_ASSERT_CVGV_FROM_HEK PERL_ARGS_ASSERT_CVGV_SET +syn keyword xsMacro PERL_ARGS_ASSERT_CVSTASH_SET +syn keyword xsMacro PERL_ARGS_ASSERT_CV_CKPROTO_LEN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_CV_CLONE PERL_ARGS_ASSERT_CV_CLONE_INTO +syn keyword xsMacro PERL_ARGS_ASSERT_CV_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT_CV_GET_CALL_CHECKER +syn keyword xsMacro PERL_ARGS_ASSERT_CV_NAME +syn keyword xsMacro PERL_ARGS_ASSERT_CV_SET_CALL_CHECKER +syn keyword xsMacro PERL_ARGS_ASSERT_CV_SET_CALL_CHECKER_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_CV_UNDEF PERL_ARGS_ASSERT_CV_UNDEF_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_CX_DUMP PERL_ARGS_ASSERT_CX_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_DEB PERL_ARGS_ASSERT_DEBOP +syn keyword xsMacro PERL_ARGS_ASSERT_DEBPROF +syn keyword xsMacro PERL_ARGS_ASSERT_DEBUG_START_MATCH +syn keyword xsMacro PERL_ARGS_ASSERT_DEB_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_DEB_STACK_N +syn keyword xsMacro PERL_ARGS_ASSERT_DEFELEM_TARGET PERL_ARGS_ASSERT_DELIMCPY +syn keyword xsMacro PERL_ARGS_ASSERT_DEL_SV PERL_ARGS_ASSERT_DESTROY_MATCHER +syn keyword xsMacro PERL_ARGS_ASSERT_DIE_SV PERL_ARGS_ASSERT_DIE_UNWIND +syn keyword xsMacro PERL_ARGS_ASSERT_DIRP_DUP PERL_ARGS_ASSERT_DIV128 +syn keyword xsMacro PERL_ARGS_ASSERT_DOFILE PERL_ARGS_ASSERT_DOFINDLABEL +syn keyword xsMacro PERL_ARGS_ASSERT_DOFORM PERL_ARGS_ASSERT_DOONELINER +syn keyword xsMacro PERL_ARGS_ASSERT_DOOPEN_PM PERL_ARGS_ASSERT_DOPARSEFORM +syn keyword xsMacro PERL_ARGS_ASSERT_DOPOPTOLABEL +syn keyword xsMacro PERL_ARGS_ASSERT_DOPOPTOSUB_AT PERL_ARGS_ASSERT_DOREF +syn keyword xsMacro PERL_ARGS_ASSERT_DO_AEXEC PERL_ARGS_ASSERT_DO_AEXEC5 +syn keyword xsMacro PERL_ARGS_ASSERT_DO_ASPAWN PERL_ARGS_ASSERT_DO_BINMODE +syn keyword xsMacro PERL_ARGS_ASSERT_DO_CHOMP PERL_ARGS_ASSERT_DO_DUMP_PAD +syn keyword xsMacro PERL_ARGS_ASSERT_DO_EOF PERL_ARGS_ASSERT_DO_EXEC +syn keyword xsMacro PERL_ARGS_ASSERT_DO_EXEC3 PERL_ARGS_ASSERT_DO_GVGV_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT_DO_GV_DUMP PERL_ARGS_ASSERT_DO_HV_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT_DO_IPCCTL PERL_ARGS_ASSERT_DO_IPCGET +syn keyword xsMacro PERL_ARGS_ASSERT_DO_JOIN PERL_ARGS_ASSERT_DO_MAGIC_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT_DO_MSGRCV PERL_ARGS_ASSERT_DO_MSGSND +syn keyword xsMacro PERL_ARGS_ASSERT_DO_NCMP PERL_ARGS_ASSERT_DO_ODDBALL +syn keyword xsMacro PERL_ARGS_ASSERT_DO_OPEN PERL_ARGS_ASSERT_DO_OPEN6 +syn keyword xsMacro PERL_ARGS_ASSERT_DO_OPEN9 PERL_ARGS_ASSERT_DO_OPENN +syn keyword xsMacro PERL_ARGS_ASSERT_DO_OPEN_RAW PERL_ARGS_ASSERT_DO_OP_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT_DO_PMOP_DUMP PERL_ARGS_ASSERT_DO_PRINT +syn keyword xsMacro PERL_ARGS_ASSERT_DO_SEMOP PERL_ARGS_ASSERT_DO_SHMIO +syn keyword xsMacro PERL_ARGS_ASSERT_DO_SPAWN +syn keyword xsMacro PERL_ARGS_ASSERT_DO_SPAWN_NOWAIT +syn keyword xsMacro PERL_ARGS_ASSERT_DO_SPRINTF PERL_ARGS_ASSERT_DO_SV_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT_DO_SYSSEEK PERL_ARGS_ASSERT_DO_TELL +syn keyword xsMacro PERL_ARGS_ASSERT_DO_TRANS +syn keyword xsMacro PERL_ARGS_ASSERT_DO_TRANS_COMPLEX +syn keyword xsMacro PERL_ARGS_ASSERT_DO_TRANS_COMPLEX_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_DO_TRANS_COUNT +syn keyword xsMacro PERL_ARGS_ASSERT_DO_TRANS_COUNT_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_DO_TRANS_SIMPLE +syn keyword xsMacro PERL_ARGS_ASSERT_DO_TRANS_SIMPLE_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_DO_VECGET PERL_ARGS_ASSERT_DO_VECSET +syn keyword xsMacro PERL_ARGS_ASSERT_DO_VOP PERL_ARGS_ASSERT_DRAND48_INIT_R +syn keyword xsMacro PERL_ARGS_ASSERT_DRAND48_R PERL_ARGS_ASSERT_DUMPUNTIL +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_C_BACKTRACE +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_EXEC_POS PERL_ARGS_ASSERT_DUMP_FORM +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_INDENT PERL_ARGS_ASSERT_DUMP_MSTATS +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_PACKSUBS +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_PACKSUBS_PERL +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_SUB PERL_ARGS_ASSERT_DUMP_SUB_PERL +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_SV_CHILD PERL_ARGS_ASSERT_DUMP_TRIE +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_TRIE_INTERIM_LIST +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_TRIE_INTERIM_TABLE +syn keyword xsMacro PERL_ARGS_ASSERT_DUMP_VINDENT +syn keyword xsMacro PERL_ARGS_ASSERT_DUP_ATTRLIST +syn keyword xsMacro PERL_ARGS_ASSERT_EMULATE_COP_IO PERL_ARGS_ASSERT_EVAL_PV +syn keyword xsMacro PERL_ARGS_ASSERT_EVAL_SV PERL_ARGS_ASSERT_EXEC_FAILED +syn keyword xsMacro PERL_ARGS_ASSERT_EXPECT_NUMBER PERL_ARGS_ASSERT_F0CONVERT +syn keyword xsMacro PERL_ARGS_ASSERT_FBM_COMPILE PERL_ARGS_ASSERT_FBM_INSTR +syn keyword xsMacro PERL_ARGS_ASSERT_FEATURE_IS_ENABLED +syn keyword xsMacro PERL_ARGS_ASSERT_FILTER_DEL PERL_ARGS_ASSERT_FILTER_GETS +syn keyword xsMacro PERL_ARGS_ASSERT_FILTER_READ PERL_ARGS_ASSERT_FINALIZE_OP +syn keyword xsMacro PERL_ARGS_ASSERT_FINALIZE_OPTREE +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_AND_FORGET_PMOPS +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_ARRAY_SUBSCRIPT +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_BEGINNING +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_BYCLASS +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_DEFAULT_STASH +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_HASH_SUBSCRIPT +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_IN_MY_STASH +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_RUNDEFSV2 +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_SCRIPT +syn keyword xsMacro PERL_ARGS_ASSERT_FIND_UNINIT_VAR +syn keyword xsMacro PERL_ARGS_ASSERT_FIRST_SYMBOL +syn keyword xsMacro PERL_ARGS_ASSERT_FIXUP_ERRNO_STRING +syn keyword xsMacro PERL_ARGS_ASSERT_FOLDEQ PERL_ARGS_ASSERT_FOLDEQ_LATIN1 +syn keyword xsMacro PERL_ARGS_ASSERT_FOLDEQ_LOCALE +syn keyword xsMacro PERL_ARGS_ASSERT_FOLDEQ_UTF8_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_FOLD_CONSTANTS +syn keyword xsMacro PERL_ARGS_ASSERT_FORCE_IDENT +syn keyword xsMacro PERL_ARGS_ASSERT_FORCE_STRICT_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_FORCE_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_FORCE_WORD PERL_ARGS_ASSERT_FORGET_PMOP +syn keyword xsMacro PERL_ARGS_ASSERT_FORM PERL_ARGS_ASSERT_FORM_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_FORM_SHORT_OCTAL_WARNING +syn keyword xsMacro PERL_ARGS_ASSERT_FPRINTF_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_FP_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_FREE_GLOBAL_STRUCT +syn keyword xsMacro PERL_ARGS_ASSERT_GETCWD_SV PERL_ARGS_ASSERT_GETENV_LEN +syn keyword xsMacro PERL_ARGS_ASSERT_GET_AND_CHECK_BACKSLASH_N_NAME +syn keyword xsMacro PERL_ARGS_ASSERT_GET_ANYOF_CP_LIST_FOR_SSC +syn keyword xsMacro PERL_ARGS_ASSERT_GET_AUX_MG PERL_ARGS_ASSERT_GET_AV +syn keyword xsMacro PERL_ARGS_ASSERT_GET_CV PERL_ARGS_ASSERT_GET_CVN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_GET_DB_SUB +syn keyword xsMacro PERL_ARGS_ASSERT_GET_DEBUG_OPTS +syn keyword xsMacro PERL_ARGS_ASSERT_GET_HASH_SEED PERL_ARGS_ASSERT_GET_HV +syn keyword xsMacro PERL_ARGS_ASSERT_GET_INVLIST_ITER_ADDR +syn keyword xsMacro PERL_ARGS_ASSERT_GET_INVLIST_OFFSET_ADDR +syn keyword xsMacro PERL_ARGS_ASSERT_GET_INVLIST_PREVIOUS_INDEX_ADDR +syn keyword xsMacro PERL_ARGS_ASSERT_GET_MSTATS PERL_ARGS_ASSERT_GET_NUM +syn keyword xsMacro PERL_ARGS_ASSERT_GET_SV PERL_ARGS_ASSERT_GLOB_2NUMBER +syn keyword xsMacro PERL_ARGS_ASSERT_GLOB_ASSIGN_GLOB PERL_ARGS_ASSERT_GP_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_ATOUV PERL_ARGS_ASSERT_GROK_BIN +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_BSLASH_N +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_BSLASH_O +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_BSLASH_X PERL_ARGS_ASSERT_GROK_HEX +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_INFNAN PERL_ARGS_ASSERT_GROK_NUMBER +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_NUMBER_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_NUMERIC_RADIX +syn keyword xsMacro PERL_ARGS_ASSERT_GROK_OCT PERL_ARGS_ASSERT_GROUP_END +syn keyword xsMacro PERL_ARGS_ASSERT_GV_AMUPDATE +syn keyword xsMacro PERL_ARGS_ASSERT_GV_AUTOLOAD_PV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_AUTOLOAD_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_GV_AUTOLOAD_SV PERL_ARGS_ASSERT_GV_CHECK +syn keyword xsMacro PERL_ARGS_ASSERT_GV_CONST_SV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_EFULLNAME +syn keyword xsMacro PERL_ARGS_ASSERT_GV_EFULLNAME3 +syn keyword xsMacro PERL_ARGS_ASSERT_GV_EFULLNAME4 +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHFILE +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHFILE_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETHOD +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETHOD_AUTOLOAD +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETHOD_PVN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETHOD_PV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETHOD_SV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETH_PV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETH_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETH_PVN_AUTOLOAD +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETH_PV_AUTOLOAD +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETH_SV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHMETH_SV_AUTOLOAD +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHPV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHPVN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FETCHSV PERL_ARGS_ASSERT_GV_FULLNAME +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FULLNAME3 +syn keyword xsMacro PERL_ARGS_ASSERT_GV_FULLNAME4 PERL_ARGS_ASSERT_GV_INIT_PV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_INIT_PVN PERL_ARGS_ASSERT_GV_INIT_SV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_INIT_SVTYPE +syn keyword xsMacro PERL_ARGS_ASSERT_GV_IS_IN_MAIN +syn keyword xsMacro PERL_ARGS_ASSERT_GV_MAGICALIZE +syn keyword xsMacro PERL_ARGS_ASSERT_GV_MAGICALIZE_ISA +syn keyword xsMacro PERL_ARGS_ASSERT_GV_NAME_SET PERL_ARGS_ASSERT_GV_OVERRIDE +syn keyword xsMacro PERL_ARGS_ASSERT_GV_SETREF PERL_ARGS_ASSERT_GV_STASHPV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_STASHPVN +syn keyword xsMacro PERL_ARGS_ASSERT_GV_STASHPVN_INTERNAL +syn keyword xsMacro PERL_ARGS_ASSERT_GV_STASHSV +syn keyword xsMacro PERL_ARGS_ASSERT_GV_TRY_DOWNGRADE +syn keyword xsMacro PERL_ARGS_ASSERT_HANDLE_REGEX_SETS +syn keyword xsMacro PERL_ARGS_ASSERT_HEK_DUP PERL_ARGS_ASSERT_HE_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_HFREEENTRIES +syn keyword xsMacro PERL_ARGS_ASSERT_HFREE_NEXT_ENTRY PERL_ARGS_ASSERT_HSPLIT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ASSERT PERL_ARGS_ASSERT_HV_AUXINIT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_AUXINIT_INTERNAL +syn keyword xsMacro PERL_ARGS_ASSERT_HV_BACKREFERENCES_P +syn keyword xsMacro PERL_ARGS_ASSERT_HV_CLEAR_PLACEHOLDERS +syn keyword xsMacro PERL_ARGS_ASSERT_HV_COMMON_KEY_LEN +syn keyword xsMacro PERL_ARGS_ASSERT_HV_DELAYFREE_ENT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_DELETE PERL_ARGS_ASSERT_HV_DELETE_ENT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_EITER_P PERL_ARGS_ASSERT_HV_EITER_SET +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ENAME_ADD +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ENAME_DELETE +syn keyword xsMacro PERL_ARGS_ASSERT_HV_EXISTS PERL_ARGS_ASSERT_HV_EXISTS_ENT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_FETCH PERL_ARGS_ASSERT_HV_FETCH_ENT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_FILL PERL_ARGS_ASSERT_HV_FREE_ENT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_FREE_ENT_RET +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ITERINIT PERL_ARGS_ASSERT_HV_ITERKEY +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ITERKEYSV +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ITERNEXT +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ITERNEXTSV +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ITERNEXT_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_HV_ITERVAL +syn keyword xsMacro PERL_ARGS_ASSERT_HV_KILL_BACKREFS +syn keyword xsMacro PERL_ARGS_ASSERT_HV_KSPLIT PERL_ARGS_ASSERT_HV_MAGIC +syn keyword xsMacro PERL_ARGS_ASSERT_HV_MAGIC_CHECK +syn keyword xsMacro PERL_ARGS_ASSERT_HV_NAME_SET +syn keyword xsMacro PERL_ARGS_ASSERT_HV_NOTALLOWED +syn keyword xsMacro PERL_ARGS_ASSERT_HV_PLACEHOLDERS_GET +syn keyword xsMacro PERL_ARGS_ASSERT_HV_PLACEHOLDERS_P +syn keyword xsMacro PERL_ARGS_ASSERT_HV_PLACEHOLDERS_SET +syn keyword xsMacro PERL_ARGS_ASSERT_HV_RAND_SET PERL_ARGS_ASSERT_HV_RITER_P +syn keyword xsMacro PERL_ARGS_ASSERT_HV_RITER_SET PERL_ARGS_ASSERT_HV_SCALAR +syn keyword xsMacro PERL_ARGS_ASSERT_INCLINE PERL_ARGS_ASSERT_INCPUSH +syn keyword xsMacro PERL_ARGS_ASSERT_INCPUSH_IF_EXISTS +syn keyword xsMacro PERL_ARGS_ASSERT_INCPUSH_USE_SEP +syn keyword xsMacro PERL_ARGS_ASSERT_INIT_ARGV_SYMBOLS +syn keyword xsMacro PERL_ARGS_ASSERT_INIT_POSTDUMP_SYMBOLS +syn keyword xsMacro PERL_ARGS_ASSERT_INIT_TM PERL_ARGS_ASSERT_INPLACE_AASSIGN +syn keyword xsMacro PERL_ARGS_ASSERT_INSTR PERL_ARGS_ASSERT_INTUIT_METHOD +syn keyword xsMacro PERL_ARGS_ASSERT_INTUIT_MORE +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_ARRAY +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_CLONE +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_EXTEND +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_HIGHEST +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_IS_ITERATING +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_ITERFINISH +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_ITERINIT +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_ITERNEXT +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_MAX +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_PREVIOUS_INDEX +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_SET_LEN +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_SET_PREVIOUS_INDEX +syn keyword xsMacro PERL_ARGS_ASSERT_INVLIST_TRIM PERL_ARGS_ASSERT_IO_CLOSE +syn keyword xsMacro PERL_ARGS_ASSERT_ISALNUM_LAZY PERL_ARGS_ASSERT_ISA_LOOKUP +syn keyword xsMacro PERL_ARGS_ASSERT_ISFOO_UTF8_LC +syn keyword xsMacro PERL_ARGS_ASSERT_ISIDFIRST_LAZY +syn keyword xsMacro PERL_ARGS_ASSERT_ISINFNANSV PERL_ARGS_ASSERT_ISSB +syn keyword xsMacro PERL_ARGS_ASSERT_ISWB PERL_ARGS_ASSERT_IS_AN_INT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_HANDLE_CONSTRUCTOR +syn keyword xsMacro PERL_ARGS_ASSERT_IS_INVARIANT_STRING +syn keyword xsMacro PERL_ARGS_ASSERT_IS_SAFE_SYSCALL +syn keyword xsMacro PERL_ARGS_ASSERT_IS_SSC_WORTH_IT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_ALNUM +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_ALNUMC +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_ALPHA +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_ASCII +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_BLANK +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_CHAR +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_CHAR_BUF +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_CNTRL +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_COMMON +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_DIGIT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_GRAPH +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_IDCONT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_IDFIRST +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_LOWER +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_MARK +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_PERL_SPACE +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_PERL_WORD +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_POSIX_DIGIT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_PRINT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_PUNCT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_SPACE +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_STRING +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_STRING_LOC +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_STRING_LOCLEN +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_UPPER +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_XDIGIT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_XIDCONT +syn keyword xsMacro PERL_ARGS_ASSERT_IS_UTF8_XIDFIRST PERL_ARGS_ASSERT_JMAYBE +syn keyword xsMacro PERL_ARGS_ASSERT_JOIN_EXACT PERL_ARGS_ASSERT_KEYWORD +syn keyword xsMacro PERL_ARGS_ASSERT_KEYWORD_PLUGIN_STANDARD +syn keyword xsMacro PERL_ARGS_ASSERT_LEAVE_COMMON +syn keyword xsMacro PERL_ARGS_ASSERT_LEX_DISCARD_TO +syn keyword xsMacro PERL_ARGS_ASSERT_LEX_READ_TO +syn keyword xsMacro PERL_ARGS_ASSERT_LEX_STUFF_PV +syn keyword xsMacro PERL_ARGS_ASSERT_LEX_STUFF_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_LEX_STUFF_SV +syn keyword xsMacro PERL_ARGS_ASSERT_LEX_UNSTUFF PERL_ARGS_ASSERT_LOAD_MODULE +syn keyword xsMacro PERL_ARGS_ASSERT_LOAD_MODULE_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_LOCALIZE +syn keyword xsMacro PERL_ARGS_ASSERT_LOOKS_LIKE_BOOL +syn keyword xsMacro PERL_ARGS_ASSERT_LOOKS_LIKE_NUMBER PERL_ARGS_ASSERT_LOP +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEARARYLEN_P +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEARENV +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEARHINT +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEARHINTS +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEARISA +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEARPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEARSIG +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_CLEAR_ALL_ENV +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_COPYCALLCHECKER +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_EXISTSPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_FREEARYLEN_P +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_FREEOVRLD +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GET +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETARYLEN +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETDEBUGVAR +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETDEFELEM +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETNKEYS +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETPOS +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETSIG +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETSUBSTR +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETTAINT +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETUVAR +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_GETVEC +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_KILLBACKREFS +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_METHCALL +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_METHCALL1 +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_METHPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_NEXTPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_REGDATA_CNT +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_REGDATUM_GET +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_REGDATUM_SET +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SCALARPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SET +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETARYLEN +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETCOLLXFRM +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETDBLINE +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETDEBUGVAR +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETDEFELEM +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETENV +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETHINT +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETISA +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETLVREF +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETMGLOB +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETNKEYS +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETPOS +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETREGEXP +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETSIG +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETSUBSTR +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETTAINT +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETUTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETUVAR +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SETVEC +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SET_ALL_ENV +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_SIZEPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAGIC_WIPEPACK +syn keyword xsMacro PERL_ARGS_ASSERT_MAKE_MATCHER PERL_ARGS_ASSERT_MAKE_TRIE +syn keyword xsMacro PERL_ARGS_ASSERT_MALLOCED_SIZE +syn keyword xsMacro PERL_ARGS_ASSERT_MATCHER_MATCHES_SV +syn keyword xsMacro PERL_ARGS_ASSERT_MAYBERELOCATE +syn keyword xsMacro PERL_ARGS_ASSERT_MAYBE_MULTIMAGIC_GV +syn keyword xsMacro PERL_ARGS_ASSERT_MEASURE_STRUCT +syn keyword xsMacro PERL_ARGS_ASSERT_MEM_COLLXFRM +syn keyword xsMacro PERL_ARGS_ASSERT_MEM_LOG_COMMON PERL_ARGS_ASSERT_MESS +syn keyword xsMacro PERL_ARGS_ASSERT_MESS_NOCONTEXT PERL_ARGS_ASSERT_MESS_SV +syn keyword xsMacro PERL_ARGS_ASSERT_MG_CLEAR PERL_ARGS_ASSERT_MG_COPY +syn keyword xsMacro PERL_ARGS_ASSERT_MG_DUP PERL_ARGS_ASSERT_MG_FIND_MGLOB +syn keyword xsMacro PERL_ARGS_ASSERT_MG_FREE PERL_ARGS_ASSERT_MG_FREE_TYPE +syn keyword xsMacro PERL_ARGS_ASSERT_MG_GET PERL_ARGS_ASSERT_MG_LENGTH +syn keyword xsMacro PERL_ARGS_ASSERT_MG_LOCALIZE PERL_ARGS_ASSERT_MG_MAGICAL +syn keyword xsMacro PERL_ARGS_ASSERT_MG_SET PERL_ARGS_ASSERT_MG_SIZE +syn keyword xsMacro PERL_ARGS_ASSERT_MINI_MKTIME +syn keyword xsMacro PERL_ARGS_ASSERT_MORESWITCHES +syn keyword xsMacro PERL_ARGS_ASSERT_MOVE_PROTO_ATTR +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_CLEAN_ISAREV +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_GATHER_AND_RENAME +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_GET_FROM_NAME +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_GET_LINEAR_ISA +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_GET_LINEAR_ISA_DFS +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_GET_PRIVATE_DATA +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_ISA_CHANGED_IN +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_META_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_META_INIT +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_METHOD_CHANGED_IN +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_PACKAGE_MOVED +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_REGISTER +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_SET_MRO +syn keyword xsMacro PERL_ARGS_ASSERT_MRO_SET_PRIVATE_DATA +syn keyword xsMacro PERL_ARGS_ASSERT_MUL128 +syn keyword xsMacro PERL_ARGS_ASSERT_MULTIDEREF_STRINGIFY +syn keyword xsMacro PERL_ARGS_ASSERT_MY_ATOF PERL_ARGS_ASSERT_MY_ATOF2 +syn keyword xsMacro PERL_ARGS_ASSERT_MY_ATTRS PERL_ARGS_ASSERT_MY_BCOPY +syn keyword xsMacro PERL_ARGS_ASSERT_MY_BYTES_TO_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_MY_BZERO PERL_ARGS_ASSERT_MY_CXT_INDEX +syn keyword xsMacro PERL_ARGS_ASSERT_MY_CXT_INIT PERL_ARGS_ASSERT_MY_KID +syn keyword xsMacro PERL_ARGS_ASSERT_MY_MEMCMP PERL_ARGS_ASSERT_MY_MEMSET +syn keyword xsMacro PERL_ARGS_ASSERT_MY_POPEN PERL_ARGS_ASSERT_MY_POPEN_LIST +syn keyword xsMacro PERL_ARGS_ASSERT_MY_SNPRINTF PERL_ARGS_ASSERT_MY_SPRINTF +syn keyword xsMacro PERL_ARGS_ASSERT_MY_STRFTIME +syn keyword xsMacro PERL_ARGS_ASSERT_MY_VSNPRINTF PERL_ARGS_ASSERT_NEED_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_NEWAVREF PERL_ARGS_ASSERT_NEWCONDOP +syn keyword xsMacro PERL_ARGS_ASSERT_NEWFOROP PERL_ARGS_ASSERT_NEWGIVENOP +syn keyword xsMacro PERL_ARGS_ASSERT_NEWGIVWHENOP PERL_ARGS_ASSERT_NEWGP +syn keyword xsMacro PERL_ARGS_ASSERT_NEWGVGEN_FLAGS PERL_ARGS_ASSERT_NEWGVOP +syn keyword xsMacro PERL_ARGS_ASSERT_NEWHVREF PERL_ARGS_ASSERT_NEWLOGOP +syn keyword xsMacro PERL_ARGS_ASSERT_NEWLOOPEX PERL_ARGS_ASSERT_NEWMETHOP +syn keyword xsMacro PERL_ARGS_ASSERT_NEWMETHOP_NAMED +syn keyword xsMacro PERL_ARGS_ASSERT_NEWMYSUB +syn keyword xsMacro PERL_ARGS_ASSERT_NEWPADNAMEOUTER +syn keyword xsMacro PERL_ARGS_ASSERT_NEWPADNAMEPVN PERL_ARGS_ASSERT_NEWPADOP +syn keyword xsMacro PERL_ARGS_ASSERT_NEWPROG PERL_ARGS_ASSERT_NEWRANGE +syn keyword xsMacro PERL_ARGS_ASSERT_NEWRV PERL_ARGS_ASSERT_NEWRV_NOINC +syn keyword xsMacro PERL_ARGS_ASSERT_NEWSTUB PERL_ARGS_ASSERT_NEWSVAVDEFELEM +syn keyword xsMacro PERL_ARGS_ASSERT_NEWSVOP PERL_ARGS_ASSERT_NEWSVPVF +syn keyword xsMacro PERL_ARGS_ASSERT_NEWSVPVF_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_NEWSVREF PERL_ARGS_ASSERT_NEWSVRV +syn keyword xsMacro PERL_ARGS_ASSERT_NEWWHENOP PERL_ARGS_ASSERT_NEWXS +syn keyword xsMacro PERL_ARGS_ASSERT_NEWXS_DEFFILE +syn keyword xsMacro PERL_ARGS_ASSERT_NEWXS_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_NEWXS_LEN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_NEW_CONSTANT PERL_ARGS_ASSERT_NEW_CTYPE +syn keyword xsMacro PERL_ARGS_ASSERT_NEW_LOGOP PERL_ARGS_ASSERT_NEW_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_NEW_WARNINGS_BITFIELD +syn keyword xsMacro PERL_ARGS_ASSERT_NEXTARGV PERL_ARGS_ASSERT_NEXTCHAR +syn keyword xsMacro PERL_ARGS_ASSERT_NEXT_SYMBOL PERL_ARGS_ASSERT_NINSTR +syn keyword xsMacro PERL_ARGS_ASSERT_NOPERL_DIE PERL_ARGS_ASSERT_NOT_A_NUMBER +syn keyword xsMacro PERL_ARGS_ASSERT_NOT_INCREMENTABLE +syn keyword xsMacro PERL_ARGS_ASSERT_NO_BAREWORD_ALLOWED +syn keyword xsMacro PERL_ARGS_ASSERT_NO_FH_ALLOWED PERL_ARGS_ASSERT_NO_OP +syn keyword xsMacro PERL_ARGS_ASSERT_OOPSAV PERL_ARGS_ASSERT_OOPSHV +syn keyword xsMacro PERL_ARGS_ASSERT_OPENN_CLEANUP +syn keyword xsMacro PERL_ARGS_ASSERT_OPENN_SETUP PERL_ARGS_ASSERT_OPEN_SCRIPT +syn keyword xsMacro PERL_ARGS_ASSERT_OPMETHOD_STASH +syn keyword xsMacro PERL_ARGS_ASSERT_OPSLAB_FORCE_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_OPSLAB_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_OPSLAB_FREE_NOPAD +syn keyword xsMacro PERL_ARGS_ASSERT_OP_CLEAR +syn keyword xsMacro PERL_ARGS_ASSERT_OP_CONTEXTUALIZE +syn keyword xsMacro PERL_ARGS_ASSERT_OP_DUMP PERL_ARGS_ASSERT_OP_INTEGERIZE +syn keyword xsMacro PERL_ARGS_ASSERT_OP_LINKLIST PERL_ARGS_ASSERT_OP_NULL +syn keyword xsMacro PERL_ARGS_ASSERT_OP_PARENT PERL_ARGS_ASSERT_OP_REFCNT_DEC +syn keyword xsMacro PERL_ARGS_ASSERT_OP_RELOCATE_SV +syn keyword xsMacro PERL_ARGS_ASSERT_OP_STD_INIT PERL_ARGS_ASSERT_PACKAGE +syn keyword xsMacro PERL_ARGS_ASSERT_PACKAGE_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_PACKLIST PERL_ARGS_ASSERT_PACK_CAT +syn keyword xsMacro PERL_ARGS_ASSERT_PACK_REC PERL_ARGS_ASSERT_PADLIST_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_PADLIST_STORE +syn keyword xsMacro PERL_ARGS_ASSERT_PADNAMELIST_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_PADNAMELIST_FETCH +syn keyword xsMacro PERL_ARGS_ASSERT_PADNAMELIST_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_PADNAMELIST_STORE +syn keyword xsMacro PERL_ARGS_ASSERT_PADNAME_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_PADNAME_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_ADD_ANON +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_ADD_NAME_PV +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_ADD_NAME_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_ADD_NAME_SV +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_ADD_WEAKREF +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_ALLOC_NAME +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_CHECK_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_FINDLEX +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_FINDMY_PV +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_FINDMY_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_FINDMY_SV +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_FIXUP_INNER_ANONS +syn keyword xsMacro PERL_ARGS_ASSERT_PAD_PUSH PERL_ARGS_ASSERT_PAD_SETSV +syn keyword xsMacro PERL_ARGS_ASSERT_PARSER_DUP PERL_ARGS_ASSERT_PARSER_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_PARSER_FREE_NEXTTOKE_OPS +syn keyword xsMacro PERL_ARGS_ASSERT_PARSE_GV_STASH_NAME +syn keyword xsMacro PERL_ARGS_ASSERT_PARSE_IDENT +syn keyword xsMacro PERL_ARGS_ASSERT_PARSE_LPAREN_QUESTION_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_PARSE_UNICODE_OPTS +syn keyword xsMacro PERL_ARGS_ASSERT_PATH_IS_SEARCHABLE +syn keyword xsMacro PERL_ARGS_ASSERT_PERLIO_READ +syn keyword xsMacro PERL_ARGS_ASSERT_PERLIO_UNREAD +syn keyword xsMacro PERL_ARGS_ASSERT_PERLIO_WRITE +syn keyword xsMacro PERL_ARGS_ASSERT_PERL_ALLOC_USING +syn keyword xsMacro PERL_ARGS_ASSERT_PERL_CLONE +syn keyword xsMacro PERL_ARGS_ASSERT_PERL_CLONE_USING +syn keyword xsMacro PERL_ARGS_ASSERT_PERL_CONSTRUCT +syn keyword xsMacro PERL_ARGS_ASSERT_PERL_DESTRUCT PERL_ARGS_ASSERT_PERL_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_PERL_PARSE PERL_ARGS_ASSERT_PERL_RUN +syn keyword xsMacro PERL_ARGS_ASSERT_PMRUNTIME PERL_ARGS_ASSERT_PMTRANS +syn keyword xsMacro PERL_ARGS_ASSERT_PM_DESCRIPTION +syn keyword xsMacro PERL_ARGS_ASSERT_POPULATE_ANYOF_FROM_INVLIST +syn keyword xsMacro PERL_ARGS_ASSERT_POPULATE_ISA PERL_ARGS_ASSERT_PREGCOMP +syn keyword xsMacro PERL_ARGS_ASSERT_PREGEXEC PERL_ARGS_ASSERT_PREGFREE2 +syn keyword xsMacro PERL_ARGS_ASSERT_PRESCAN_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_PRINTBUF +syn keyword xsMacro PERL_ARGS_ASSERT_PRINTF_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_PROCESS_SPECIAL_BLOCKS +syn keyword xsMacro PERL_ARGS_ASSERT_PTR_TABLE_FETCH +syn keyword xsMacro PERL_ARGS_ASSERT_PTR_TABLE_FIND +syn keyword xsMacro PERL_ARGS_ASSERT_PTR_TABLE_SPLIT +syn keyword xsMacro PERL_ARGS_ASSERT_PTR_TABLE_STORE +syn keyword xsMacro PERL_ARGS_ASSERT_PUT_CHARCLASS_BITMAP_INNARDS +syn keyword xsMacro PERL_ARGS_ASSERT_PUT_CODE_POINT +syn keyword xsMacro PERL_ARGS_ASSERT_PUT_RANGE PERL_ARGS_ASSERT_PV_DISPLAY +syn keyword xsMacro PERL_ARGS_ASSERT_PV_ESCAPE PERL_ARGS_ASSERT_PV_PRETTY +syn keyword xsMacro PERL_ARGS_ASSERT_PV_UNI_DISPLAY PERL_ARGS_ASSERT_QERROR +syn keyword xsMacro PERL_ARGS_ASSERT_QSORTSVU +syn keyword xsMacro PERL_ARGS_ASSERT_QUADMATH_FORMAT_NEEDED +syn keyword xsMacro PERL_ARGS_ASSERT_QUADMATH_FORMAT_SINGLE +syn keyword xsMacro PERL_ARGS_ASSERT_REENTRANT_RETRY +syn keyword xsMacro PERL_ARGS_ASSERT_REFCOUNTED_HE_FETCH_PV +syn keyword xsMacro PERL_ARGS_ASSERT_REFCOUNTED_HE_FETCH_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_REFCOUNTED_HE_FETCH_SV +syn keyword xsMacro PERL_ARGS_ASSERT_REFCOUNTED_HE_NEW_PV +syn keyword xsMacro PERL_ARGS_ASSERT_REFCOUNTED_HE_NEW_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_REFCOUNTED_HE_NEW_SV +syn keyword xsMacro PERL_ARGS_ASSERT_REFCOUNTED_HE_VALUE +syn keyword xsMacro PERL_ARGS_ASSERT_REFTO PERL_ARGS_ASSERT_REG +syn keyword xsMacro PERL_ARGS_ASSERT_REG2LANODE PERL_ARGS_ASSERT_REGANODE +syn keyword xsMacro PERL_ARGS_ASSERT_REGATOM PERL_ARGS_ASSERT_REGBRANCH +syn keyword xsMacro PERL_ARGS_ASSERT_REGCLASS PERL_ARGS_ASSERT_REGCLASS_SWASH +syn keyword xsMacro PERL_ARGS_ASSERT_REGCPPOP PERL_ARGS_ASSERT_REGCPPUSH +syn keyword xsMacro PERL_ARGS_ASSERT_REGCURLY PERL_ARGS_ASSERT_REGDUMP +syn keyword xsMacro PERL_ARGS_ASSERT_REGDUPE_INTERNAL +syn keyword xsMacro PERL_ARGS_ASSERT_REGEXEC_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_REGFREE_INTERNAL +syn keyword xsMacro PERL_ARGS_ASSERT_REGHOP3 PERL_ARGS_ASSERT_REGHOP4 +syn keyword xsMacro PERL_ARGS_ASSERT_REGHOPMAYBE3 PERL_ARGS_ASSERT_REGINCLASS +syn keyword xsMacro PERL_ARGS_ASSERT_REGINSERT PERL_ARGS_ASSERT_REGMATCH +syn keyword xsMacro PERL_ARGS_ASSERT_REGNODE_GUTS PERL_ARGS_ASSERT_REGPATWS +syn keyword xsMacro PERL_ARGS_ASSERT_REGPIECE PERL_ARGS_ASSERT_REGPPOSIXCC +syn keyword xsMacro PERL_ARGS_ASSERT_REGPROP PERL_ARGS_ASSERT_REGREPEAT +syn keyword xsMacro PERL_ARGS_ASSERT_REGTAIL PERL_ARGS_ASSERT_REGTAIL_STUDY +syn keyword xsMacro PERL_ARGS_ASSERT_REGTRY +syn keyword xsMacro PERL_ARGS_ASSERT_REG_CHECK_NAMED_BUFF_MATCHED +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF_ALL +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF_EXISTS +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF_FETCH +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF_FIRSTKEY +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF_ITER +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF_NEXTKEY +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NAMED_BUFF_SCALAR +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NODE +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NUMBERED_BUFF_FETCH +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NUMBERED_BUFF_LENGTH +syn keyword xsMacro PERL_ARGS_ASSERT_REG_NUMBERED_BUFF_STORE +syn keyword xsMacro PERL_ARGS_ASSERT_REG_QR_PACKAGE +syn keyword xsMacro PERL_ARGS_ASSERT_REG_RECODE +syn keyword xsMacro PERL_ARGS_ASSERT_REG_SCAN_NAME +syn keyword xsMacro PERL_ARGS_ASSERT_REG_SKIPCOMMENT +syn keyword xsMacro PERL_ARGS_ASSERT_REG_TEMP_COPY PERL_ARGS_ASSERT_REPEATCPY +syn keyword xsMacro PERL_ARGS_ASSERT_REPORT_REDEFINED_CV +syn keyword xsMacro PERL_ARGS_ASSERT_REQUIRE_PV +syn keyword xsMacro PERL_ARGS_ASSERT_REQUIRE_TIE_MOD +syn keyword xsMacro PERL_ARGS_ASSERT_RE_COMPILE PERL_ARGS_ASSERT_RE_CROAK2 +syn keyword xsMacro PERL_ARGS_ASSERT_RE_DUP_GUTS +syn keyword xsMacro PERL_ARGS_ASSERT_RE_INTUIT_START +syn keyword xsMacro PERL_ARGS_ASSERT_RE_INTUIT_STRING +syn keyword xsMacro PERL_ARGS_ASSERT_RE_OP_COMPILE PERL_ARGS_ASSERT_RNINSTR +syn keyword xsMacro PERL_ARGS_ASSERT_RSIGNAL_SAVE +syn keyword xsMacro PERL_ARGS_ASSERT_RUN_USER_FILTER +syn keyword xsMacro PERL_ARGS_ASSERT_RV2CV_OP_CV PERL_ARGS_ASSERT_RVPV_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_RXRES_FREE +syn keyword xsMacro PERL_ARGS_ASSERT_RXRES_RESTORE +syn keyword xsMacro PERL_ARGS_ASSERT_RXRES_SAVE PERL_ARGS_ASSERT_SAME_DIRENT +syn keyword xsMacro PERL_ARGS_ASSERT_SAVESHAREDSVPV PERL_ARGS_ASSERT_SAVESVPV +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_ADELETE +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_AELEM_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_ALIASED_SV +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_APTR PERL_ARGS_ASSERT_SAVE_ARY +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_BOOL PERL_ARGS_ASSERT_SAVE_CLEARSV +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_DELETE +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_DESTRUCTOR +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_GENERIC_PVREF +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_GENERIC_SVREF +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_GP PERL_ARGS_ASSERT_SAVE_HASH +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_HDELETE +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_HEK_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_HELEM_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_HPTR PERL_ARGS_ASSERT_SAVE_I16 +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_I32 PERL_ARGS_ASSERT_SAVE_I8 +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_INT PERL_ARGS_ASSERT_SAVE_ITEM +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_IV PERL_ARGS_ASSERT_SAVE_LINES +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_LIST PERL_ARGS_ASSERT_SAVE_LONG +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_MAGIC_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_MORTALIZESV +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_NOGV PERL_ARGS_ASSERT_SAVE_PPTR +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_SCALAR +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_SCALAR_AT +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_SET_SVFLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_SHARED_PVREF +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_SPTR PERL_ARGS_ASSERT_SAVE_STRLEN +syn keyword xsMacro PERL_ARGS_ASSERT_SAVE_SVREF PERL_ARGS_ASSERT_SAVE_VPTR +syn keyword xsMacro PERL_ARGS_ASSERT_SCALARBOOLEAN +syn keyword xsMacro PERL_ARGS_ASSERT_SCALARVOID PERL_ARGS_ASSERT_SCAN_BIN +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_COMMIT PERL_ARGS_ASSERT_SCAN_CONST +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_FORMLINE +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_HEREDOC PERL_ARGS_ASSERT_SCAN_HEX +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_IDENT +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_INPUTSYMBOL +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_NUM PERL_ARGS_ASSERT_SCAN_OCT +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_PAT PERL_ARGS_ASSERT_SCAN_STR +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_SUBST PERL_ARGS_ASSERT_SCAN_TRANS +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_SCAN_VSTRING PERL_ARGS_ASSERT_SCAN_WORD +syn keyword xsMacro PERL_ARGS_ASSERT_SEARCH_CONST PERL_ARGS_ASSERT_SETDEFOUT +syn keyword xsMacro PERL_ARGS_ASSERT_SET_ANYOF_ARG +syn keyword xsMacro PERL_ARGS_ASSERT_SET_CONTEXT PERL_ARGS_ASSERT_SET_PADLIST +syn keyword xsMacro PERL_ARGS_ASSERT_SHARE_HEK +syn keyword xsMacro PERL_ARGS_ASSERT_SHARE_HEK_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SHOULD_WARN_NL +syn keyword xsMacro PERL_ARGS_ASSERT_SIMPLIFY_SORT PERL_ARGS_ASSERT_SI_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_SKIPSPACE_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SLAB_FREE PERL_ARGS_ASSERT_SLAB_TO_RO +syn keyword xsMacro PERL_ARGS_ASSERT_SLAB_TO_RW PERL_ARGS_ASSERT_SOFTREF2XV +syn keyword xsMacro PERL_ARGS_ASSERT_SORTCV PERL_ARGS_ASSERT_SORTCV_STACKED +syn keyword xsMacro PERL_ARGS_ASSERT_SORTCV_XSUB PERL_ARGS_ASSERT_SORTSV +syn keyword xsMacro PERL_ARGS_ASSERT_SORTSV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SPACE_JOIN_NAMES_MORTAL +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_ADD_RANGE PERL_ARGS_ASSERT_SSC_AND +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_ANYTHING +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_CLEAR_LOCALE +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_CP_AND PERL_ARGS_ASSERT_SSC_FINALIZE +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_INIT +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_INTERSECTION +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_IS_ANYTHING +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_IS_CP_POSIXL_INIT +syn keyword xsMacro PERL_ARGS_ASSERT_SSC_OR PERL_ARGS_ASSERT_SSC_UNION +syn keyword xsMacro PERL_ARGS_ASSERT_SS_DUP PERL_ARGS_ASSERT_STACK_GROW +syn keyword xsMacro PERL_ARGS_ASSERT_START_GLOB +syn keyword xsMacro PERL_ARGS_ASSERT_STDIZE_LOCALE +syn keyword xsMacro PERL_ARGS_ASSERT_STRIP_RETURN +syn keyword xsMacro PERL_ARGS_ASSERT_STR_TO_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_STUDY_CHUNK +syn keyword xsMacro PERL_ARGS_ASSERT_SUB_CRUSH_DEPTH +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2BOOL_FLAGS PERL_ARGS_ASSERT_SV_2CV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2IO PERL_ARGS_ASSERT_SV_2IUV_COMMON +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2IUV_NON_PRESERVE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2IV PERL_ARGS_ASSERT_SV_2IV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2NUM PERL_ARGS_ASSERT_SV_2NV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2PV PERL_ARGS_ASSERT_SV_2PVBYTE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2PVBYTE_NOLEN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2PVUTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2PVUTF8_NOLEN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2PV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2PV_NOLEN PERL_ARGS_ASSERT_SV_2UV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_2UV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_ADD_ARENA +syn keyword xsMacro PERL_ARGS_ASSERT_SV_ADD_BACKREF +syn keyword xsMacro PERL_ARGS_ASSERT_SV_BACKOFF PERL_ARGS_ASSERT_SV_BLESS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_BUF_TO_RO +syn keyword xsMacro PERL_ARGS_ASSERT_SV_BUF_TO_RW PERL_ARGS_ASSERT_SV_CATPV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPVF PERL_ARGS_ASSERT_SV_CATPVF_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPVF_MG_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPVF_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPVN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPVN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPVN_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATPV_MG PERL_ARGS_ASSERT_SV_CATSV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATSV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CATSV_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CAT_DECODE PERL_ARGS_ASSERT_SV_CHOP +syn keyword xsMacro PERL_ARGS_ASSERT_SV_CLEAR +syn keyword xsMacro PERL_ARGS_ASSERT_SV_COLLXFRM_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_COPYPV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_COPYPV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DEL_BACKREF +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DERIVED_FROM +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DERIVED_FROM_PV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DERIVED_FROM_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DERIVED_FROM_SV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DISPLAY PERL_ARGS_ASSERT_SV_DOES +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DOES_PV PERL_ARGS_ASSERT_SV_DOES_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DOES_SV PERL_ARGS_ASSERT_SV_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DUP PERL_ARGS_ASSERT_SV_DUP_COMMON +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DUP_INC +syn keyword xsMacro PERL_ARGS_ASSERT_SV_DUP_INC_MULTIPLE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_EXP_GROW +syn keyword xsMacro PERL_ARGS_ASSERT_SV_FORCE_NORMAL +syn keyword xsMacro PERL_ARGS_ASSERT_SV_FORCE_NORMAL_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_FREE2 PERL_ARGS_ASSERT_SV_GETS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_GET_BACKREFS PERL_ARGS_ASSERT_SV_GROW +syn keyword xsMacro PERL_ARGS_ASSERT_SV_INSERT +syn keyword xsMacro PERL_ARGS_ASSERT_SV_INSERT_FLAGS PERL_ARGS_ASSERT_SV_ISA +syn keyword xsMacro PERL_ARGS_ASSERT_SV_IV PERL_ARGS_ASSERT_SV_I_NCMP +syn keyword xsMacro PERL_ARGS_ASSERT_SV_KILL_BACKREFS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_LEN_UTF8_NOMG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_MAGIC PERL_ARGS_ASSERT_SV_MAGICEXT +syn keyword xsMacro PERL_ARGS_ASSERT_SV_MAGICEXT_MGLOB +syn keyword xsMacro PERL_ARGS_ASSERT_SV_NCMP PERL_ARGS_ASSERT_SV_NV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_ONLY_TAINT_GMAGIC +syn keyword xsMacro PERL_ARGS_ASSERT_SV_OR_PV_POS_U2B +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_B2U +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_B2U_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_B2U_MIDWAY +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_U2B +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_U2B_CACHED +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_U2B_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_U2B_FORWARDS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_POS_U2B_MIDWAY PERL_ARGS_ASSERT_SV_PV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_PVBYTE PERL_ARGS_ASSERT_SV_PVBYTEN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_PVBYTEN_FORCE PERL_ARGS_ASSERT_SV_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_PVN_FORCE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_PVN_FORCE_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_PVN_NOMG PERL_ARGS_ASSERT_SV_PVUTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_SV_PVUTF8N +syn keyword xsMacro PERL_ARGS_ASSERT_SV_PVUTF8N_FORCE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_RECODE_TO_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_SV_REF PERL_ARGS_ASSERT_SV_REFTYPE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_RELEASE_COW +syn keyword xsMacro PERL_ARGS_ASSERT_SV_REPLACE PERL_ARGS_ASSERT_SV_RESET +syn keyword xsMacro PERL_ARGS_ASSERT_SV_RVWEAKEN PERL_ARGS_ASSERT_SV_SETHEK +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETIV PERL_ARGS_ASSERT_SV_SETIV_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETNV PERL_ARGS_ASSERT_SV_SETNV_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPV PERL_ARGS_ASSERT_SV_SETPVF +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPVF_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPVF_MG_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPVF_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPVIV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPVIV_MG PERL_ARGS_ASSERT_SV_SETPVN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPVN_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETPV_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETREF_IV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETREF_NV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETREF_PV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETREF_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETREF_UV PERL_ARGS_ASSERT_SV_SETSV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETSV_COW +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETSV_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETSV_MG PERL_ARGS_ASSERT_SV_SETUV +syn keyword xsMacro PERL_ARGS_ASSERT_SV_SETUV_MG PERL_ARGS_ASSERT_SV_TAINT +syn keyword xsMacro PERL_ARGS_ASSERT_SV_TAINTED PERL_ARGS_ASSERT_SV_UNGLOB +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UNI_DISPLAY +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UNMAGIC +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UNMAGICEXT PERL_ARGS_ASSERT_SV_UNREF +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UNREF_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UNTAINT PERL_ARGS_ASSERT_SV_UPGRADE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_USEPVN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_USEPVN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_USEPVN_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UTF8_DECODE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UTF8_DOWNGRADE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UTF8_ENCODE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UTF8_UPGRADE +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UTF8_UPGRADE_FLAGS_GROW +syn keyword xsMacro PERL_ARGS_ASSERT_SV_UV PERL_ARGS_ASSERT_SV_VCATPVF +syn keyword xsMacro PERL_ARGS_ASSERT_SV_VCATPVFN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_VCATPVFN_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_SV_VCATPVF_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SV_VSETPVF PERL_ARGS_ASSERT_SV_VSETPVFN +syn keyword xsMacro PERL_ARGS_ASSERT_SV_VSETPVF_MG +syn keyword xsMacro PERL_ARGS_ASSERT_SWALLOW_BOM PERL_ARGS_ASSERT_SWASH_FETCH +syn keyword xsMacro PERL_ARGS_ASSERT_SWASH_INIT +syn keyword xsMacro PERL_ARGS_ASSERT_SWASH_SCAN_LIST_LINE +syn keyword xsMacro PERL_ARGS_ASSERT_SWATCH_GET PERL_ARGS_ASSERT_SYS_INIT +syn keyword xsMacro PERL_ARGS_ASSERT_SYS_INIT3 +syn keyword xsMacro PERL_ARGS_ASSERT_SYS_INTERN_DUP +syn keyword xsMacro PERL_ARGS_ASSERT_TAINT_PROPER +syn keyword xsMacro PERL_ARGS_ASSERT_TIED_METHOD +syn keyword xsMacro PERL_ARGS_ASSERT_TOKENIZE_USE PERL_ARGS_ASSERT_TOKEQ +syn keyword xsMacro PERL_ARGS_ASSERT_TOKEREPORT +syn keyword xsMacro PERL_ARGS_ASSERT_TOO_FEW_ARGUMENTS_PV +syn keyword xsMacro PERL_ARGS_ASSERT_TOO_MANY_ARGUMENTS_PV +syn keyword xsMacro PERL_ARGS_ASSERT_TO_BYTE_SUBSTR +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UNI_LOWER +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UNI_TITLE +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UNI_UPPER +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UTF8_CASE +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UTF8_FOLD +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UTF8_LOWER +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UTF8_SUBSTR +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UTF8_TITLE +syn keyword xsMacro PERL_ARGS_ASSERT_TO_UTF8_UPPER +syn keyword xsMacro PERL_ARGS_ASSERT_TRANSLATE_SUBSTR_OFFSETS +syn keyword xsMacro PERL_ARGS_ASSERT_UIV_2BUF PERL_ARGS_ASSERT_UNLNK +syn keyword xsMacro PERL_ARGS_ASSERT_UNPACKSTRING PERL_ARGS_ASSERT_UNPACK_REC +syn keyword xsMacro PERL_ARGS_ASSERT_UNPACK_STR +syn keyword xsMacro PERL_ARGS_ASSERT_UNREFERENCED_TO_TMP_STACK +syn keyword xsMacro PERL_ARGS_ASSERT_UPG_VERSION +syn keyword xsMacro PERL_ARGS_ASSERT_UTF16_TEXTFILTER +syn keyword xsMacro PERL_ARGS_ASSERT_UTF16_TO_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_UTF16_TO_UTF8_REVERSED +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8N_TO_UVCHR +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8N_TO_UVUNI +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_DISTANCE PERL_ARGS_ASSERT_UTF8_HOP +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_LENGTH +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_MG_LEN_CACHE_UPDATE +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_MG_POS_CACHE_UPDATE +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_TO_BYTES +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_TO_UVCHR +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_TO_UVUNI +syn keyword xsMacro PERL_ARGS_ASSERT_UTF8_TO_UVUNI_BUF +syn keyword xsMacro PERL_ARGS_ASSERT_UTILIZE +syn keyword xsMacro PERL_ARGS_ASSERT_UVOFFUNI_TO_UTF8_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_UVUNI_TO_UTF8 +syn keyword xsMacro PERL_ARGS_ASSERT_UVUNI_TO_UTF8_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT_VALIDATE_PROTO +syn keyword xsMacro PERL_ARGS_ASSERT_VALIDATE_SUID +syn keyword xsMacro PERL_ARGS_ASSERT_VALID_UTF8_TO_UVCHR +syn keyword xsMacro PERL_ARGS_ASSERT_VALID_UTF8_TO_UVUNI +syn keyword xsMacro PERL_ARGS_ASSERT_VCMP PERL_ARGS_ASSERT_VDEB +syn keyword xsMacro PERL_ARGS_ASSERT_VFORM PERL_ARGS_ASSERT_VISIT +syn keyword xsMacro PERL_ARGS_ASSERT_VIVIFY_DEFELEM +syn keyword xsMacro PERL_ARGS_ASSERT_VIVIFY_REF PERL_ARGS_ASSERT_VLOAD_MODULE +syn keyword xsMacro PERL_ARGS_ASSERT_VMESS PERL_ARGS_ASSERT_VNEWSVPVF +syn keyword xsMacro PERL_ARGS_ASSERT_VNORMAL PERL_ARGS_ASSERT_VNUMIFY +syn keyword xsMacro PERL_ARGS_ASSERT_VSTRINGIFY PERL_ARGS_ASSERT_VVERIFY +syn keyword xsMacro PERL_ARGS_ASSERT_VWARN PERL_ARGS_ASSERT_VWARNER +syn keyword xsMacro PERL_ARGS_ASSERT_WAIT4PID PERL_ARGS_ASSERT_WARN +syn keyword xsMacro PERL_ARGS_ASSERT_WARNER PERL_ARGS_ASSERT_WARNER_NOCONTEXT +syn keyword xsMacro PERL_ARGS_ASSERT_WARN_NOCONTEXT PERL_ARGS_ASSERT_WARN_SV +syn keyword xsMacro PERL_ARGS_ASSERT_WATCH PERL_ARGS_ASSERT_WHICHSIG_PV +syn keyword xsMacro PERL_ARGS_ASSERT_WHICHSIG_PVN +syn keyword xsMacro PERL_ARGS_ASSERT_WHICHSIG_SV +syn keyword xsMacro PERL_ARGS_ASSERT_WIN32_CROAK_NOT_IMPLEMENTED +syn keyword xsMacro PERL_ARGS_ASSERT_WITH_QUEUED_ERRORS +syn keyword xsMacro PERL_ARGS_ASSERT_WRAP_OP_CHECKER +syn keyword xsMacro PERL_ARGS_ASSERT_WRITE_TO_STDERR +syn keyword xsMacro PERL_ARGS_ASSERT_XS_HANDSHAKE +syn keyword xsMacro PERL_ARGS_ASSERT_XS_VERSION_BOOTCHECK +syn keyword xsMacro PERL_ARGS_ASSERT_YYERROR PERL_ARGS_ASSERT_YYERROR_PV +syn keyword xsMacro PERL_ARGS_ASSERT_YYERROR_PVN PERL_ARGS_ASSERT_YYWARN +syn keyword xsMacro PERL_ARGS_ASSERT__APPEND_RANGE_TO_INVLIST +syn keyword xsMacro PERL_ARGS_ASSERT__CORE_SWASH_INIT +syn keyword xsMacro PERL_ARGS_ASSERT__GET_REGCLASS_NONBITMAP_DATA +syn keyword xsMacro PERL_ARGS_ASSERT__GET_SWASH_INVLIST +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_ARRAY_INIT +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_CONTAINS_CP +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_CONTENTS +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_DUMP +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_INTERSECTION_MAYBE_COMPLEMENT_2ND +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_INVERT +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_LEN +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_POPULATE_SWATCH +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_SEARCH +syn keyword xsMacro PERL_ARGS_ASSERT__INVLIST_UNION_MAYBE_COMPLEMENT_2ND +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_CHAR_SLOW +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_FOO +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_IDCONT +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_IDSTART +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_MARK +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_PERL_IDCONT +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_PERL_IDSTART +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_XIDCONT +syn keyword xsMacro PERL_ARGS_ASSERT__IS_UTF8_XIDSTART +syn keyword xsMacro PERL_ARGS_ASSERT__MAKE_EXACTF_INVLIST +syn keyword xsMacro PERL_ARGS_ASSERT__NEW_INVLIST_C_ARRAY +syn keyword xsMacro PERL_ARGS_ASSERT__SETUP_CANNED_INVLIST +syn keyword xsMacro PERL_ARGS_ASSERT__SWASH_INVERSION_HASH +syn keyword xsMacro PERL_ARGS_ASSERT__SWASH_TO_INVLIST +syn keyword xsMacro PERL_ARGS_ASSERT__TO_FOLD_LATIN1 +syn keyword xsMacro PERL_ARGS_ASSERT__TO_UNI_FOLD_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT__TO_UPPER_TITLE_LATIN1 +syn keyword xsMacro PERL_ARGS_ASSERT__TO_UTF8_FOLD_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT__TO_UTF8_LOWER_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT__TO_UTF8_TITLE_FLAGS +syn keyword xsMacro PERL_ARGS_ASSERT__TO_UTF8_UPPER_FLAGS PERL_ASYNC_CHECK +syn keyword xsMacro PERL_BITFIELD16 PERL_BITFIELD32 PERL_BITFIELD8 +syn keyword xsMacro PERL_CALLCONV PERL_CALLCONV_NO_RET PERL_CHECK_INITED +syn keyword xsMacro PERL_CKDEF PERL_DEB PERL_DEB2 PERL_DEBUG PERL_DEBUG_PAD +syn keyword xsMacro PERL_DEBUG_PAD_ZERO PERL_DECIMAL_VERSION +syn keyword xsMacro PERL_DEFAULT_DO_EXEC3_IMPLEMENTATION +syn keyword xsMacro PERL_DONT_CREATE_GVSV PERL_DRAND48_QUAD +syn keyword xsMacro PERL_ENABLE_EXPERIMENTAL_REGEX_OPTIMISATIONS +syn keyword xsMacro PERL_ENABLE_EXTENDED_TRIE_OPTIMISATION +syn keyword xsMacro PERL_ENABLE_POSITIVE_ASSERTION_STUDY +syn keyword xsMacro PERL_ENABLE_TRIE_OPTIMISATION PERL_EXIT_ABORT +syn keyword xsMacro PERL_EXIT_DESTRUCT_END PERL_EXIT_EXPECTED PERL_EXIT_WARN +syn keyword xsMacro PERL_EXPORT_C PERL_FILE_IS_ABSOLUTE PERL_FILTER_EXISTS +syn keyword xsMacro PERL_FLUSHALL_FOR_CHILD PERL_FPU_INIT PERL_FPU_POST_EXEC +syn keyword xsMacro PERL_FPU_PRE_EXEC PERL_FS_VERSION PERL_FS_VER_FMT +syn keyword xsMacro PERL_GCC_BRACE_GROUPS_FORBIDDEN PERL_GET_CONTEXT +syn keyword xsMacro PERL_GET_INTERP PERL_GET_THX PERL_GET_VARS +syn keyword xsMacro PERL_GIT_UNPUSHED_COMMITS PERL_GLOBAL_STRUCT +syn keyword xsMacro PERL_GPROF_MONCONTROL PERL_HASH PERL_HASH_DEFAULT_HvMAX +syn keyword xsMacro PERL_HASH_FUNC PERL_HASH_FUNC_ONE_AT_A_TIME_HARD +syn keyword xsMacro PERL_HASH_INTERNAL PERL_HASH_ITER_BUCKET +syn keyword xsMacro PERL_HASH_RANDOMIZE_KEYS PERL_HASH_SEED +syn keyword xsMacro PERL_HASH_SEED_BYTES PERL_HASH_WITH_SEED +syn keyword xsMacro PERL_HV_ALLOC_AUX_SIZE PERL_HV_ARRAY_ALLOC_BYTES +syn keyword xsMacro PERL_IMPLICIT_CONTEXT PERL_INTERPRETER_SIZE_UPTO_MEMBER +syn keyword xsMacro PERL_INT_MAX PERL_INT_MIN PERL_LOADMOD_DENY +syn keyword xsMacro PERL_LOADMOD_IMPORT_OPS PERL_LOADMOD_NOIMPORT +syn keyword xsMacro PERL_LONG_MAX PERL_LONG_MIN PERL_MALLOC_WRAP +syn keyword xsMacro PERL_MEMORY_DEBUG_HEADER_SIZE PERL_MG_UFUNC +syn keyword xsMacro PERL_MY_SNPRINTF_GUARDED PERL_MY_SNPRINTF_POST_GUARD +syn keyword xsMacro PERL_MY_VSNPRINTF_GUARDED PERL_MY_VSNPRINTF_POST_GUARD +syn keyword xsMacro PERL_NEW_COPY_ON_WRITE PERL_NO_DEV_RANDOM +syn keyword xsMacro PERL_OBJECT_THIS PERL_OBJECT_THIS_ PERL_PADNAME_MINIMAL +syn keyword xsMacro PERL_PADSEQ_INTRO PERL_PATCHNUM PERL_POISON_EXPR +syn keyword xsMacro PERL_PPADDR_INITED PERL_PPDEF PERL_PRESERVE_IVUV +syn keyword xsMacro PERL_PRIeldbl PERL_PRIfldbl PERL_PRIgldbl +syn keyword xsMacro PERL_PV_ESCAPE_ALL PERL_PV_ESCAPE_DWIM +syn keyword xsMacro PERL_PV_ESCAPE_FIRSTCHAR PERL_PV_ESCAPE_NOBACKSLASH +syn keyword xsMacro PERL_PV_ESCAPE_NOCLEAR PERL_PV_ESCAPE_NONASCII +syn keyword xsMacro PERL_PV_ESCAPE_QUOTE PERL_PV_ESCAPE_RE PERL_PV_ESCAPE_UNI +syn keyword xsMacro PERL_PV_ESCAPE_UNI_DETECT PERL_PV_PRETTY_DUMP +syn keyword xsMacro PERL_PV_PRETTY_ELLIPSES PERL_PV_PRETTY_EXACTSIZE +syn keyword xsMacro PERL_PV_PRETTY_LTGT PERL_PV_PRETTY_NOCLEAR +syn keyword xsMacro PERL_PV_PRETTY_QUOTE PERL_PV_PRETTY_REGPROP PERL_QUAD_MAX +syn keyword xsMacro PERL_QUAD_MIN PERL_REENTR_API PERL_REGMATCH_SLAB_SLOTS +syn keyword xsMacro PERL_RELOCATABLE_INC PERL_REVISION PERL_SAWAMPERSAND +syn keyword xsMacro PERL_SCAN_ALLOW_UNDERSCORES PERL_SCAN_DISALLOW_PREFIX +syn keyword xsMacro PERL_SCAN_GREATER_THAN_UV_MAX PERL_SCAN_SILENT_ILLDIGIT +syn keyword xsMacro PERL_SCAN_SILENT_NON_PORTABLE PERL_SCAN_TRAILING +syn keyword xsMacro PERL_SCNfldbl PERL_SCRIPT_MODE PERL_SEEN_HV_FUNC_H +syn keyword xsMacro PERL_SET_CONTEXT PERL_SET_INTERP PERL_SET_PHASE +syn keyword xsMacro PERL_SET_THX PERL_SHORT_MAX PERL_SHORT_MIN +syn keyword xsMacro PERL_SIGNALS_UNSAFE_FLAG PERL_SNPRINTF_CHECK +syn keyword xsMacro PERL_STACK_OVERFLOW_CHECK PERL_STATIC_INLINE +syn keyword xsMacro PERL_STATIC_INLINE_NO_RET PERL_STATIC_NO_RET +syn keyword xsMacro PERL_STRLEN_EXPAND_SHIFT PERL_STRLEN_ROUNDUP +syn keyword xsMacro PERL_STRLEN_ROUNDUP_QUANTUM PERL_SUBVERSION +syn keyword xsMacro PERL_SUB_DEPTH_WARN PERL_SYS_FPU_INIT PERL_SYS_INIT +syn keyword xsMacro PERL_SYS_INIT3 PERL_SYS_INIT3_BODY PERL_SYS_INIT_BODY +syn keyword xsMacro PERL_SYS_TERM PERL_SYS_TERM_BODY PERL_TARGETARCH +syn keyword xsMacro PERL_UCHAR_MAX PERL_UCHAR_MIN PERL_UINT_MAX PERL_UINT_MIN +syn keyword xsMacro PERL_ULONG_MAX PERL_ULONG_MIN PERL_UNICODE_ALL_FLAGS +syn keyword xsMacro PERL_UNICODE_ARGV PERL_UNICODE_ARGV_FLAG +syn keyword xsMacro PERL_UNICODE_DEFAULT_FLAGS PERL_UNICODE_IN +syn keyword xsMacro PERL_UNICODE_INOUT PERL_UNICODE_INOUT_FLAG +syn keyword xsMacro PERL_UNICODE_IN_FLAG PERL_UNICODE_LOCALE +syn keyword xsMacro PERL_UNICODE_LOCALE_FLAG PERL_UNICODE_MAX +syn keyword xsMacro PERL_UNICODE_OUT PERL_UNICODE_OUT_FLAG PERL_UNICODE_STD +syn keyword xsMacro PERL_UNICODE_STDERR PERL_UNICODE_STDERR_FLAG +syn keyword xsMacro PERL_UNICODE_STDIN PERL_UNICODE_STDIN_FLAG +syn keyword xsMacro PERL_UNICODE_STDOUT PERL_UNICODE_STDOUT_FLAG +syn keyword xsMacro PERL_UNICODE_STD_FLAG PERL_UNICODE_UTF8CACHEASSERT +syn keyword xsMacro PERL_UNICODE_UTF8CACHEASSERT_FLAG +syn keyword xsMacro PERL_UNICODE_WIDESYSCALLS PERL_UNICODE_WIDESYSCALLS_FLAG +syn keyword xsMacro PERL_UNUSED_ARG PERL_UNUSED_CONTEXT PERL_UNUSED_DECL +syn keyword xsMacro PERL_UNUSED_RESULT PERL_UNUSED_VAR PERL_UQUAD_MAX +syn keyword xsMacro PERL_UQUAD_MIN PERL_USES_PL_PIDSTATUS +syn keyword xsMacro PERL_USE_GCC_BRACE_GROUPS PERL_USHORT_MAX PERL_USHORT_MIN +syn keyword xsMacro PERL_VERSION PERL_VERSION_DECIMAL PERL_VERSION_GE +syn keyword xsMacro PERL_VERSION_LT PERL_VERSION_STRING +syn keyword xsMacro PERL_WAIT_FOR_CHILDREN PERL_WARNHOOK_FATAL +syn keyword xsMacro PERL_WRITE_MSG_TO_CONSOLE PERL_XS_EXPORT_C +syn keyword xsMacro PHASE_CHANGE_PROBE PHOSTNAME PIPESOCK_MODE PIPE_OPEN_MODE +syn keyword xsMacro PLUGEXPR PLUGSTMT PLUS PL_AboveLatin1 PL_Argv PL_Cmd +syn keyword xsMacro PL_DBcontrol PL_DBcv PL_DBgv PL_DBline PL_DBsignal +syn keyword xsMacro PL_DBsignal_iv PL_DBsingle PL_DBsingle_iv PL_DBsub +syn keyword xsMacro PL_DBtrace PL_DBtrace_iv PL_Dir PL_Env PL_GCB_invlist +syn keyword xsMacro PL_Gappctx PL_Gcheck PL_Gcheck_mutex PL_Gcsighandlerp +syn keyword xsMacro PL_Gcurinterp PL_Gdo_undump PL_Gdollarzero_mutex +syn keyword xsMacro PL_Gfold_locale PL_Ghash_seed PL_Ghash_seed_set +syn keyword xsMacro PL_Ghints_mutex PL_Gkeyword_plugin PL_Gmalloc_mutex +syn keyword xsMacro PL_Gmmap_page_size PL_Gmy_ctx_mutex PL_Gmy_cxt_index +syn keyword xsMacro PL_Gop_mutex PL_Gop_seq PL_Gop_sequence +syn keyword xsMacro PL_Gperlio_debug_fd PL_Gperlio_fd_refcnt +syn keyword xsMacro PL_Gperlio_fd_refcnt_size PL_Gperlio_mutex PL_Gppaddr +syn keyword xsMacro PL_Gsh_path PL_Gsig_defaulting PL_Gsig_handlers_initted +syn keyword xsMacro PL_Gsig_ignoring PL_Gsig_trapped PL_Gsigfpe_saved +syn keyword xsMacro PL_Gsv_placeholder PL_Gthr_key PL_Gtimesbase +syn keyword xsMacro PL_Guse_safe_putenv PL_Gveto_cleanup PL_Gwatch_pvx +syn keyword xsMacro PL_HASH_RAND_BITS_ENABLED PL_HasMultiCharFold PL_InBitmap +syn keyword xsMacro PL_LIO PL_Latin1 PL_Mem PL_MemParse PL_MemShared +syn keyword xsMacro PL_NonL1NonFinalFold PL_Posix_ptrs PL_Proc +syn keyword xsMacro PL_RANDOM_STATE_TYPE PL_SB_invlist PL_Sock PL_StdIO PL_Sv +syn keyword xsMacro PL_UpperLatin1 PL_WB_invlist PL_XPosix_ptrs PL_Xpv +syn keyword xsMacro PL_amagic_generation PL_an PL_appctx PL_argvgv +syn keyword xsMacro PL_argvout_stack PL_argvoutgv PL_basetime PL_beginav +syn keyword xsMacro PL_beginav_save PL_blockhooks PL_body_arenas +syn keyword xsMacro PL_body_roots PL_bodytarget PL_breakable_sub_gen +syn keyword xsMacro PL_check_mutex PL_checkav PL_checkav_save PL_chopset +syn keyword xsMacro PL_clocktick PL_collation_ix PL_collation_name +syn keyword xsMacro PL_collation_standard PL_collxfrm_base PL_collxfrm_mult +syn keyword xsMacro PL_colors PL_colorset PL_compcv PL_compiling PL_comppad +syn keyword xsMacro PL_comppad_name PL_comppad_name_fill +syn keyword xsMacro PL_comppad_name_floor PL_constpadix PL_cop_seqmax +syn keyword xsMacro PL_cryptseen PL_cshlen PL_csighandlerp PL_curcop +syn keyword xsMacro PL_curcopdb PL_curinterp PL_curpad PL_curpm PL_curstack +syn keyword xsMacro PL_curstackinfo PL_curstash PL_curstname +syn keyword xsMacro PL_custom_op_descs PL_custom_op_names PL_custom_ops +syn keyword xsMacro PL_cv_has_eval PL_dbargs PL_debstash PL_debug +syn keyword xsMacro PL_debug_pad PL_def_layerlist PL_defgv PL_defoutgv +syn keyword xsMacro PL_defstash PL_delaymagic PL_delaymagic_egid +syn keyword xsMacro PL_delaymagic_euid PL_delaymagic_gid PL_delaymagic_uid +syn keyword xsMacro PL_destroyhook PL_diehook PL_dirty PL_do_undump +syn keyword xsMacro PL_dollarzero_mutex PL_doswitches PL_dowarn PL_dumper_fd +syn keyword xsMacro PL_dumpindent PL_e_script PL_efloatbuf PL_efloatsize +syn keyword xsMacro PL_encoding PL_endav PL_envgv PL_errgv PL_errors +syn keyword xsMacro PL_eval_root PL_eval_start PL_evalseq PL_exit_flags +syn keyword xsMacro PL_exitlist PL_exitlistlen PL_fdpid PL_filemode +syn keyword xsMacro PL_firstgv PL_forkprocess PL_formtarget PL_generation +syn keyword xsMacro PL_gensym PL_globalstash PL_globhook PL_hash_rand_bits +syn keyword xsMacro PL_hash_rand_bits_enabled PL_hash_seed PL_hash_seed_set +syn keyword xsMacro PL_hintgv PL_hints PL_hints_mutex PL_hv_fetch_ent_mh +syn keyword xsMacro PL_in_clean_all PL_in_clean_objs PL_in_eval +syn keyword xsMacro PL_in_load_module PL_in_utf8_CTYPE_locale PL_incgv +syn keyword xsMacro PL_initav PL_inplace PL_isarev PL_keyword_plugin +syn keyword xsMacro PL_known_layers PL_last_in_gv PL_last_swash_hv +syn keyword xsMacro PL_last_swash_key PL_last_swash_klen PL_last_swash_slen +syn keyword xsMacro PL_last_swash_tmps PL_lastfd PL_lastgotoprobe +syn keyword xsMacro PL_laststatval PL_laststype PL_lex_encoding PL_localizing +syn keyword xsMacro PL_localpatches PL_lockhook PL_main_cv PL_main_root +syn keyword xsMacro PL_main_start PL_mainstack PL_malloc_mutex PL_markstack +syn keyword xsMacro PL_markstack_max PL_markstack_ptr PL_max_intro_pending +syn keyword xsMacro PL_maxo PL_maxsysfd PL_memory_debug_header PL_mess_sv +syn keyword xsMacro PL_min_intro_pending PL_minus_E PL_minus_F PL_minus_a +syn keyword xsMacro PL_minus_c PL_minus_l PL_minus_n PL_minus_p +syn keyword xsMacro PL_mmap_page_size PL_modcount PL_modglobal +syn keyword xsMacro PL_multideref_pc PL_my_ctx_mutex PL_my_cxt_index +syn keyword xsMacro PL_my_cxt_keys PL_my_cxt_list PL_my_cxt_size PL_nomemok +syn keyword xsMacro PL_numeric_local PL_numeric_name PL_numeric_radix_sv +syn keyword xsMacro PL_numeric_standard PL_ofsgv PL_oldname PL_op +syn keyword xsMacro PL_op_exec_cnt PL_op_mask PL_op_mutex PL_op_seq +syn keyword xsMacro PL_op_sequence PL_opfreehook PL_origalen PL_origargc +syn keyword xsMacro PL_origargv PL_origenviron PL_origfilename PL_ors_sv +syn keyword xsMacro PL_osname PL_pad_reset_pending PL_padix PL_padix_floor +syn keyword xsMacro PL_padlist_generation PL_padname_const PL_padname_undef +syn keyword xsMacro PL_parser PL_patchlevel PL_peepp PL_perl_destruct_level +syn keyword xsMacro PL_perldb PL_perlio PL_perlio_debug_fd +syn keyword xsMacro PL_perlio_fd_refcnt PL_perlio_fd_refcnt_size +syn keyword xsMacro PL_perlio_mutex PL_phase PL_pidstatus PL_preambleav +syn keyword xsMacro PL_profiledata PL_psig_name PL_psig_pend PL_psig_ptr +syn keyword xsMacro PL_ptr_table PL_random_state PL_reentrant_buffer +syn keyword xsMacro PL_reentrant_retint PL_reg_curpm PL_regex_pad +syn keyword xsMacro PL_regex_padav PL_registered_mros PL_regmatch_slab +syn keyword xsMacro PL_regmatch_state PL_replgv PL_restartjmpenv PL_restartop +syn keyword xsMacro PL_rpeepp PL_rs PL_runops PL_savebegin PL_savestack +syn keyword xsMacro PL_savestack_ix PL_savestack_max PL_sawalias +syn keyword xsMacro PL_sawampersand PL_scopestack PL_scopestack_ix +syn keyword xsMacro PL_scopestack_max PL_scopestack_name PL_secondgv +syn keyword xsMacro PL_sharehook PL_sig_defaulting PL_sig_handlers_initted +syn keyword xsMacro PL_sig_ignoring PL_sig_pending PL_sig_trapped +syn keyword xsMacro PL_sigfpe_saved PL_sighandlerp PL_signalhook PL_signals +syn keyword xsMacro PL_sort_RealCmp PL_sortcop PL_sortstash PL_splitstr +syn keyword xsMacro PL_srand_called PL_stack_base PL_stack_max PL_stack_sp +syn keyword xsMacro PL_start_env PL_stashcache PL_stashpad PL_stashpadix +syn keyword xsMacro PL_stashpadmax PL_statbuf PL_statcache PL_statgv +syn keyword xsMacro PL_statname PL_statusvalue PL_statusvalue_posix +syn keyword xsMacro PL_statusvalue_vms PL_stderrgv PL_stdingv PL_strtab +syn keyword xsMacro PL_sub_generation PL_subline PL_subname PL_sv_arenaroot +syn keyword xsMacro PL_sv_consts PL_sv_count PL_sv_no PL_sv_placeholder +syn keyword xsMacro PL_sv_root PL_sv_serial PL_sv_undef PL_sv_yes +syn keyword xsMacro PL_sys_intern PL_taint_warn PL_tainted PL_tainting +syn keyword xsMacro PL_thr_key PL_threadhook PL_timesbase PL_timesbuf +syn keyword xsMacro PL_tmps_floor PL_tmps_ix PL_tmps_max PL_tmps_stack +syn keyword xsMacro PL_top_env PL_toptarget PL_unicode PL_unitcheckav +syn keyword xsMacro PL_unitcheckav_save PL_unlockhook PL_unsafe +syn keyword xsMacro PL_use_safe_putenv PL_utf8_charname_begin +syn keyword xsMacro PL_utf8_charname_continue PL_utf8_foldable +syn keyword xsMacro PL_utf8_foldclosures PL_utf8_idcont PL_utf8_idstart +syn keyword xsMacro PL_utf8_mark PL_utf8_perl_idcont PL_utf8_perl_idstart +syn keyword xsMacro PL_utf8_swash_ptrs PL_utf8_tofold PL_utf8_tolower +syn keyword xsMacro PL_utf8_totitle PL_utf8_toupper PL_utf8_xidcont +syn keyword xsMacro PL_utf8_xidstart PL_utf8cache PL_utf8locale +syn keyword xsMacro PL_veto_cleanup PL_vtbl_arylen PL_vtbl_arylen_p +syn keyword xsMacro PL_vtbl_backref PL_vtbl_bm PL_vtbl_checkcall +syn keyword xsMacro PL_vtbl_collxfrm PL_vtbl_dbline PL_vtbl_debugvar +syn keyword xsMacro PL_vtbl_defelem PL_vtbl_env PL_vtbl_envelem PL_vtbl_fm +syn keyword xsMacro PL_vtbl_hints PL_vtbl_hintselem PL_vtbl_isa +syn keyword xsMacro PL_vtbl_isaelem PL_vtbl_lvref PL_vtbl_mglob PL_vtbl_nkeys +syn keyword xsMacro PL_vtbl_ovrld PL_vtbl_pack PL_vtbl_packelem PL_vtbl_pos +syn keyword xsMacro PL_vtbl_regdata PL_vtbl_regdatum PL_vtbl_regexp +syn keyword xsMacro PL_vtbl_sigelem PL_vtbl_substr PL_vtbl_sv PL_vtbl_taint +syn keyword xsMacro PL_vtbl_utf8 PL_vtbl_uvar PL_vtbl_vec PL_warn_locale +syn keyword xsMacro PL_warnhook PL_watch_pvx PL_watchaddr PL_watchok +syn keyword xsMacro PL_xsubfilename PMFUNC PM_GETRE PM_SETRE PMf_BASE_SHIFT +syn keyword xsMacro PMf_CHARSET PMf_CODELIST_PRIVATE PMf_CONST PMf_CONTINUE +syn keyword xsMacro PMf_EVAL PMf_EXTENDED PMf_EXTENDED_MORE PMf_FOLD +syn keyword xsMacro PMf_GLOBAL PMf_HAS_CV PMf_IS_QR PMf_KEEP PMf_KEEPCOPY +syn keyword xsMacro PMf_MULTILINE PMf_NOCAPTURE PMf_NONDESTRUCT PMf_ONCE +syn keyword xsMacro PMf_RETAINT PMf_SINGLELINE PMf_SPLIT PMf_STRICT PMf_USED +syn keyword xsMacro PMf_USE_RE_EVAL PNf PNfARG POPBLOCK POPEVAL POPFORMAT +syn keyword xsMacro POPLOOP POPMARK POPSTACK POPSTACK_TO POPSUB POPSUBST +syn keyword xsMacro POP_MULTICALL POP_SAVEARRAY POPi POPl POPn POPp POPpbytex +syn keyword xsMacro POPpconstx POPpx POPs POPu POPul POSIXA POSIXD POSIXL +syn keyword xsMacro POSIXU POSIX_CC_COUNT POSIX_SWASH_COUNT POSTDEC POSTINC +syn keyword xsMacro POSTJOIN POWOP PP PREC_LOW PREDEC PREGf_ANCH +syn keyword xsMacro PREGf_ANCH_GPOS PREGf_ANCH_MBOL PREGf_ANCH_SBOL +syn keyword xsMacro PREGf_CANY_SEEN PREGf_CUTGROUP_SEEN PREGf_GPOS_FLOAT +syn keyword xsMacro PREGf_GPOS_SEEN PREGf_IMPLICIT PREGf_NAUGHTY PREGf_NOSCAN +syn keyword xsMacro PREGf_SKIP PREGf_USE_RE_EVAL PREGf_VERBARG_SEEN PREINC +syn keyword xsMacro PRESCAN_VERSION PREVOPER PRINTF_FORMAT_NULL_OK PRIVATEREF +syn keyword xsMacro PRIVLIB PRIVLIB_EXP PRIVSHIFT PROCSELFEXE_PATH PRUNE +syn keyword xsMacro PSEUDO PTHREAD_ATFORK PTHREAD_ATTR_SETDETACHSTATE +syn keyword xsMacro PTHREAD_CREATE PTHREAD_CREATE_JOINABLE +syn keyword xsMacro PTHREAD_GETSPECIFIC PTHREAD_GETSPECIFIC_INT PTR2IV PTR2NV +syn keyword xsMacro PTR2UV PTR2nat PTR2ul PTRSIZE PTRV PUSHBLOCK PUSHEVAL +syn keyword xsMacro PUSHFORMAT PUSHGIVEN PUSHLOOP_FOR PUSHLOOP_PLAIN PUSHMARK +syn keyword xsMacro PUSHSTACK PUSHSTACKi PUSHSUB PUSHSUBST PUSHSUB_BASE +syn keyword xsMacro PUSHSUB_DB PUSHSUB_GET_LVALUE_MASK PUSHTARG PUSHWHEN +syn keyword xsMacro PUSH_MULTICALL PUSH_MULTICALL_FLAGS PUSHi PUSHmortal +syn keyword xsMacro PUSHn PUSHp PUSHs PUSHu PUTBACK PWGECOS PWPASSWD PadARRAY +syn keyword xsMacro PadMAX PadlistARRAY PadlistMAX PadlistNAMES +syn keyword xsMacro PadlistNAMESARRAY PadlistNAMESMAX PadlistREFCNT +syn keyword xsMacro PadnameFLAGS PadnameIsOUR PadnameIsSTATE +syn keyword xsMacro PadnameIsSTATE_on PadnameLEN PadnameLVALUE +syn keyword xsMacro PadnameLVALUE_on PadnameOURSTASH PadnameOURSTASH_set +syn keyword xsMacro PadnameOUTER PadnamePROTOCV PadnamePV PadnameREFCNT +syn keyword xsMacro PadnameREFCNT_dec PadnameSV PadnameTYPE PadnameTYPE_set +syn keyword xsMacro PadnameUTF8 PadnamelistARRAY PadnamelistMAX +syn keyword xsMacro PadnamelistMAXNAMED PadnamelistREFCNT +syn keyword xsMacro PadnamelistREFCNT_dec Pause PeRl_CaTiFy PeRl_INT64_C +syn keyword xsMacro PeRl_StGiFy PeRl_UINT64_C PerlDir_chdir PerlDir_close +syn keyword xsMacro PerlDir_mapA PerlDir_mapW PerlDir_mkdir PerlDir_open +syn keyword xsMacro PerlDir_read PerlDir_rewind PerlDir_rmdir PerlDir_seek +syn keyword xsMacro PerlDir_tell PerlEnv_ENVgetenv PerlEnv_ENVgetenv_len +syn keyword xsMacro PerlEnv_clearenv PerlEnv_free_childdir +syn keyword xsMacro PerlEnv_free_childenv PerlEnv_get_child_IO +syn keyword xsMacro PerlEnv_get_childdir PerlEnv_get_childenv PerlEnv_getenv +syn keyword xsMacro PerlEnv_getenv_len PerlEnv_lib_path PerlEnv_os_id +syn keyword xsMacro PerlEnv_putenv PerlEnv_sitelib_path PerlEnv_uname +syn keyword xsMacro PerlEnv_vendorlib_path PerlIOArg PerlIOBase PerlIONext +syn keyword xsMacro PerlIOSelf PerlIOValid PerlIO_canset_cnt +syn keyword xsMacro PerlIO_exportFILE PerlIO_fast_gets PerlIO_fdopen +syn keyword xsMacro PerlIO_findFILE PerlIO_getc PerlIO_getname +syn keyword xsMacro PerlIO_has_base PerlIO_has_cntptr PerlIO_importFILE +syn keyword xsMacro PerlIO_isutf8 PerlIO_open PerlIO_printf PerlIO_putc +syn keyword xsMacro PerlIO_puts PerlIO_releaseFILE PerlIO_reopen +syn keyword xsMacro PerlIO_rewind PerlIO_stdoutf PerlIO_tmpfile PerlIO_ungetc +syn keyword xsMacro PerlIO_vprintf PerlLIO_access PerlLIO_chmod PerlLIO_chown +syn keyword xsMacro PerlLIO_chsize PerlLIO_close PerlLIO_dup PerlLIO_dup2 +syn keyword xsMacro PerlLIO_flock PerlLIO_fstat PerlLIO_ioctl PerlLIO_isatty +syn keyword xsMacro PerlLIO_link PerlLIO_lseek PerlLIO_lstat PerlLIO_mkstemp +syn keyword xsMacro PerlLIO_mktemp PerlLIO_open PerlLIO_open3 PerlLIO_read +syn keyword xsMacro PerlLIO_rename PerlLIO_setmode PerlLIO_stat +syn keyword xsMacro PerlLIO_tmpnam PerlLIO_umask PerlLIO_unlink PerlLIO_utime +syn keyword xsMacro PerlLIO_write PerlMemParse_calloc PerlMemParse_free +syn keyword xsMacro PerlMemParse_free_lock PerlMemParse_get_lock +syn keyword xsMacro PerlMemParse_is_locked PerlMemParse_malloc +syn keyword xsMacro PerlMemParse_realloc PerlMemShared_calloc +syn keyword xsMacro PerlMemShared_free PerlMemShared_free_lock +syn keyword xsMacro PerlMemShared_get_lock PerlMemShared_is_locked +syn keyword xsMacro PerlMemShared_malloc PerlMemShared_realloc PerlMem_calloc +syn keyword xsMacro PerlMem_free PerlMem_free_lock PerlMem_get_lock +syn keyword xsMacro PerlMem_is_locked PerlMem_malloc PerlMem_realloc +syn keyword xsMacro PerlProc_DynaLoad PerlProc_GetOSError PerlProc__exit +syn keyword xsMacro PerlProc_abort PerlProc_crypt PerlProc_execl +syn keyword xsMacro PerlProc_execv PerlProc_execvp PerlProc_exit +syn keyword xsMacro PerlProc_fork PerlProc_getegid PerlProc_geteuid +syn keyword xsMacro PerlProc_getgid PerlProc_getlogin PerlProc_getpid +syn keyword xsMacro PerlProc_gettimeofday PerlProc_getuid PerlProc_kill +syn keyword xsMacro PerlProc_killpg PerlProc_lasthost PerlProc_longjmp +syn keyword xsMacro PerlProc_pause PerlProc_pclose PerlProc_pipe +syn keyword xsMacro PerlProc_popen PerlProc_popen_list PerlProc_setgid +syn keyword xsMacro PerlProc_setjmp PerlProc_setuid PerlProc_signal +syn keyword xsMacro PerlProc_sleep PerlProc_spawnvp PerlProc_times +syn keyword xsMacro PerlProc_wait PerlProc_waitpid PerlSIO_canset_cnt +syn keyword xsMacro PerlSIO_clearerr PerlSIO_fast_gets PerlSIO_fclose +syn keyword xsMacro PerlSIO_fdopen PerlSIO_fdupopen PerlSIO_feof +syn keyword xsMacro PerlSIO_ferror PerlSIO_fflush PerlSIO_fgetc +syn keyword xsMacro PerlSIO_fgetpos PerlSIO_fgets PerlSIO_fileno +syn keyword xsMacro PerlSIO_fopen PerlSIO_fputc PerlSIO_fputs PerlSIO_fread +syn keyword xsMacro PerlSIO_freopen PerlSIO_fseek PerlSIO_fsetpos +syn keyword xsMacro PerlSIO_ftell PerlSIO_fwrite PerlSIO_get_base +syn keyword xsMacro PerlSIO_get_bufsiz PerlSIO_get_cnt PerlSIO_get_ptr +syn keyword xsMacro PerlSIO_has_base PerlSIO_has_cntptr PerlSIO_init +syn keyword xsMacro PerlSIO_printf PerlSIO_rewind PerlSIO_set_cnt +syn keyword xsMacro PerlSIO_set_ptr PerlSIO_setbuf PerlSIO_setlinebuf +syn keyword xsMacro PerlSIO_setvbuf PerlSIO_stderr PerlSIO_stdin +syn keyword xsMacro PerlSIO_stdout PerlSIO_stdoutf PerlSIO_tmpfile +syn keyword xsMacro PerlSIO_ungetc PerlSIO_vprintf PerlSock_accept +syn keyword xsMacro PerlSock_bind PerlSock_closesocket PerlSock_connect +syn keyword xsMacro PerlSock_endhostent PerlSock_endnetent +syn keyword xsMacro PerlSock_endprotoent PerlSock_endservent +syn keyword xsMacro PerlSock_gethostbyaddr PerlSock_gethostbyname +syn keyword xsMacro PerlSock_gethostent PerlSock_gethostname +syn keyword xsMacro PerlSock_getnetbyaddr PerlSock_getnetbyname +syn keyword xsMacro PerlSock_getnetent PerlSock_getpeername +syn keyword xsMacro PerlSock_getprotobyname PerlSock_getprotobynumber +syn keyword xsMacro PerlSock_getprotoent PerlSock_getservbyname +syn keyword xsMacro PerlSock_getservbyport PerlSock_getservent +syn keyword xsMacro PerlSock_getsockname PerlSock_getsockopt PerlSock_htonl +syn keyword xsMacro PerlSock_htons PerlSock_inet_addr PerlSock_inet_ntoa +syn keyword xsMacro PerlSock_listen PerlSock_ntohl PerlSock_ntohs +syn keyword xsMacro PerlSock_recv PerlSock_recvfrom PerlSock_select +syn keyword xsMacro PerlSock_send PerlSock_sendto PerlSock_sethostent +syn keyword xsMacro PerlSock_setnetent PerlSock_setprotoent +syn keyword xsMacro PerlSock_setservent PerlSock_setsockopt PerlSock_shutdown +syn keyword xsMacro PerlSock_socket PerlSock_socketpair Perl_acos Perl_asin +syn keyword xsMacro Perl_assert Perl_atan Perl_atan2 Perl_atof Perl_atof2 +syn keyword xsMacro Perl_ceil Perl_cos Perl_cosh Perl_custom_op_xop +syn keyword xsMacro Perl_debug_log Perl_drand48 Perl_drand48_init +syn keyword xsMacro Perl_error_log Perl_exp Perl_floor Perl_fmod +syn keyword xsMacro Perl_fp_class_denorm Perl_fp_class_inf Perl_fp_class_nan +syn keyword xsMacro Perl_fp_class_ndenorm Perl_fp_class_ninf +syn keyword xsMacro Perl_fp_class_nnorm Perl_fp_class_norm +syn keyword xsMacro Perl_fp_class_nzero Perl_fp_class_pdenorm +syn keyword xsMacro Perl_fp_class_pinf Perl_fp_class_pnorm +syn keyword xsMacro Perl_fp_class_pzero Perl_fp_class_qnan Perl_fp_class_snan +syn keyword xsMacro Perl_fp_class_zero Perl_free_c_backtrace Perl_frexp +syn keyword xsMacro Perl_isfinite Perl_isfinitel Perl_isinf Perl_isnan +syn keyword xsMacro Perl_ldexp Perl_log Perl_log10 Perl_malloc_good_size +syn keyword xsMacro Perl_modf Perl_pow Perl_pp_accept Perl_pp_aelemfast_lex +syn keyword xsMacro Perl_pp_andassign Perl_pp_avalues Perl_pp_bind +syn keyword xsMacro Perl_pp_bit_xor Perl_pp_chmod Perl_pp_chomp +syn keyword xsMacro Perl_pp_connect Perl_pp_cos Perl_pp_custom +syn keyword xsMacro Perl_pp_dbmclose Perl_pp_dofile Perl_pp_dor +syn keyword xsMacro Perl_pp_dorassign Perl_pp_dump Perl_pp_egrent +syn keyword xsMacro Perl_pp_enetent Perl_pp_eprotoent Perl_pp_epwent +syn keyword xsMacro Perl_pp_eservent Perl_pp_exp Perl_pp_fcntl +syn keyword xsMacro Perl_pp_ftatime Perl_pp_ftbinary Perl_pp_ftblk +syn keyword xsMacro Perl_pp_ftchr Perl_pp_ftctime Perl_pp_ftdir +syn keyword xsMacro Perl_pp_fteexec Perl_pp_fteowned Perl_pp_fteread +syn keyword xsMacro Perl_pp_ftewrite Perl_pp_ftfile Perl_pp_ftmtime +syn keyword xsMacro Perl_pp_ftpipe Perl_pp_ftrexec Perl_pp_ftrwrite +syn keyword xsMacro Perl_pp_ftsgid Perl_pp_ftsize Perl_pp_ftsock +syn keyword xsMacro Perl_pp_ftsuid Perl_pp_ftsvtx Perl_pp_ftzero +syn keyword xsMacro Perl_pp_getpeername Perl_pp_getsockname Perl_pp_ggrgid +syn keyword xsMacro Perl_pp_ggrnam Perl_pp_ghbyaddr Perl_pp_ghbyname +syn keyword xsMacro Perl_pp_gnbyaddr Perl_pp_gnbyname Perl_pp_gpbyname +syn keyword xsMacro Perl_pp_gpbynumber Perl_pp_gpwnam Perl_pp_gpwuid +syn keyword xsMacro Perl_pp_gsbyname Perl_pp_gsbyport Perl_pp_gsockopt +syn keyword xsMacro Perl_pp_hex Perl_pp_i_postdec Perl_pp_i_postinc +syn keyword xsMacro Perl_pp_i_predec Perl_pp_i_preinc Perl_pp_keys +syn keyword xsMacro Perl_pp_kill Perl_pp_lcfirst Perl_pp_lineseq +syn keyword xsMacro Perl_pp_listen Perl_pp_localtime Perl_pp_log +syn keyword xsMacro Perl_pp_lstat Perl_pp_mapstart Perl_pp_msgctl +syn keyword xsMacro Perl_pp_msgget Perl_pp_msgrcv Perl_pp_msgsnd +syn keyword xsMacro Perl_pp_nbit_xor Perl_pp_orassign Perl_pp_padany +syn keyword xsMacro Perl_pp_pop Perl_pp_postdec Perl_pp_predec Perl_pp_reach +syn keyword xsMacro Perl_pp_read Perl_pp_recv Perl_pp_regcmaybe +syn keyword xsMacro Perl_pp_rindex Perl_pp_rv2hv Perl_pp_rvalues Perl_pp_say +syn keyword xsMacro Perl_pp_sbit_xor Perl_pp_scalar Perl_pp_schomp +syn keyword xsMacro Perl_pp_scope Perl_pp_seek Perl_pp_semop Perl_pp_send +syn keyword xsMacro Perl_pp_sge Perl_pp_sgrent Perl_pp_sgt Perl_pp_shmctl +syn keyword xsMacro Perl_pp_shmget Perl_pp_shmread Perl_pp_shutdown +syn keyword xsMacro Perl_pp_slt Perl_pp_snetent Perl_pp_socket +syn keyword xsMacro Perl_pp_sprotoent Perl_pp_spwent Perl_pp_sqrt +syn keyword xsMacro Perl_pp_sservent Perl_pp_ssockopt Perl_pp_symlink +syn keyword xsMacro Perl_pp_transr Perl_pp_unlink Perl_pp_utime +syn keyword xsMacro Perl_pp_values Perl_safesysmalloc_size Perl_sharepvn +syn keyword xsMacro Perl_signbit Perl_sin Perl_sinh Perl_sqrt Perl_strtod +syn keyword xsMacro Perl_tan Perl_tanh Perl_va_copy PmopSTASH PmopSTASHPV +syn keyword xsMacro PmopSTASHPV_set PmopSTASH_set Poison PoisonFree PoisonNew +syn keyword xsMacro PoisonPADLIST PoisonWith QR_PAT_MODS QUADKIND QUAD_IS_INT +syn keyword xsMacro QUAD_IS_INT64_T QUAD_IS_LONG QUAD_IS_LONG_LONG +syn keyword xsMacro QUAD_IS___INT64 QUESTION_MARK_CTRL QWLIST RANDBITS +syn keyword xsMacro RANDOM_R_PROTO RD_NODATA READDIR64_R_PROTO +syn keyword xsMacro READDIR_R_PROTO READ_XDIGIT REENTRANT_PROTO_B_B +syn keyword xsMacro REENTRANT_PROTO_B_BI REENTRANT_PROTO_B_BW +syn keyword xsMacro REENTRANT_PROTO_B_CCD REENTRANT_PROTO_B_CCS +syn keyword xsMacro REENTRANT_PROTO_B_IBI REENTRANT_PROTO_B_IBW +syn keyword xsMacro REENTRANT_PROTO_B_SB REENTRANT_PROTO_B_SBI +syn keyword xsMacro REENTRANT_PROTO_I_BI REENTRANT_PROTO_I_BW +syn keyword xsMacro REENTRANT_PROTO_I_CCSBWR REENTRANT_PROTO_I_CCSD +syn keyword xsMacro REENTRANT_PROTO_I_CII REENTRANT_PROTO_I_CIISD +syn keyword xsMacro REENTRANT_PROTO_I_CSBI REENTRANT_PROTO_I_CSBIR +syn keyword xsMacro REENTRANT_PROTO_I_CSBWR REENTRANT_PROTO_I_CSBWRE +syn keyword xsMacro REENTRANT_PROTO_I_CSD REENTRANT_PROTO_I_CWISBWRE +syn keyword xsMacro REENTRANT_PROTO_I_CWISD REENTRANT_PROTO_I_D +syn keyword xsMacro REENTRANT_PROTO_I_H REENTRANT_PROTO_I_IBI +syn keyword xsMacro REENTRANT_PROTO_I_IBW REENTRANT_PROTO_I_ICBI +syn keyword xsMacro REENTRANT_PROTO_I_ICSBWR REENTRANT_PROTO_I_ICSD +syn keyword xsMacro REENTRANT_PROTO_I_ID REENTRANT_PROTO_I_IISD +syn keyword xsMacro REENTRANT_PROTO_I_ISBWR REENTRANT_PROTO_I_ISD +syn keyword xsMacro REENTRANT_PROTO_I_LISBI REENTRANT_PROTO_I_LISD +syn keyword xsMacro REENTRANT_PROTO_I_SB REENTRANT_PROTO_I_SBI +syn keyword xsMacro REENTRANT_PROTO_I_SBIE REENTRANT_PROTO_I_SBIH +syn keyword xsMacro REENTRANT_PROTO_I_SBIR REENTRANT_PROTO_I_SBWR +syn keyword xsMacro REENTRANT_PROTO_I_SBWRE REENTRANT_PROTO_I_SD +syn keyword xsMacro REENTRANT_PROTO_I_TISD REENTRANT_PROTO_I_TS +syn keyword xsMacro REENTRANT_PROTO_I_TSBI REENTRANT_PROTO_I_TSBIR +syn keyword xsMacro REENTRANT_PROTO_I_TSBWR REENTRANT_PROTO_I_TSR +syn keyword xsMacro REENTRANT_PROTO_I_TsISBWRE REENTRANT_PROTO_I_UISBWRE +syn keyword xsMacro REENTRANT_PROTO_I_uISBWRE REENTRANT_PROTO_S_CBI +syn keyword xsMacro REENTRANT_PROTO_S_CCSBI REENTRANT_PROTO_S_CIISBIE +syn keyword xsMacro REENTRANT_PROTO_S_CSBI REENTRANT_PROTO_S_CSBIE +syn keyword xsMacro REENTRANT_PROTO_S_CWISBIE REENTRANT_PROTO_S_CWISBWIE +syn keyword xsMacro REENTRANT_PROTO_S_ICSBI REENTRANT_PROTO_S_ISBI +syn keyword xsMacro REENTRANT_PROTO_S_LISBI REENTRANT_PROTO_S_SBI +syn keyword xsMacro REENTRANT_PROTO_S_SBIE REENTRANT_PROTO_S_SBW +syn keyword xsMacro REENTRANT_PROTO_S_TISBI REENTRANT_PROTO_S_TSBI +syn keyword xsMacro REENTRANT_PROTO_S_TSBIE REENTRANT_PROTO_S_TWISBIE +syn keyword xsMacro REENTRANT_PROTO_V_D REENTRANT_PROTO_V_H +syn keyword xsMacro REENTRANT_PROTO_V_ID REENTR_H REENTR_MEMZERO REF +syn keyword xsMacro REFCOUNTED_HE_EXISTS REFCOUNTED_HE_KEY_UTF8 REFF REFFA +syn keyword xsMacro REFFL REFFU REFGEN REF_HE_KEY REGMATCH_STATE_MAX +syn keyword xsMacro REGNODE_MAX REGNODE_SIMPLE REGNODE_VARIES REG_ANY +syn keyword xsMacro REG_CANY_SEEN REG_CUTGROUP_SEEN REG_EXTFLAGS_NAME_SIZE +syn keyword xsMacro REG_GOSTART_SEEN REG_GPOS_SEEN REG_INFTY +syn keyword xsMacro REG_INTFLAGS_NAME_SIZE REG_LOOKBEHIND_SEEN REG_MAGIC +syn keyword xsMacro REG_RECURSE_SEEN REG_RUN_ON_COMMENT_SEEN +syn keyword xsMacro REG_TOP_LEVEL_BRANCHES_SEEN REG_UNBOUNDED_QUANTIFIER_SEEN +syn keyword xsMacro REG_UNFOLDED_MULTI_SEEN REG_VERBARG_SEEN +syn keyword xsMacro REG_ZERO_LEN_SEEN RELOP RENUM REQUIRE RESTORE_ERRNO +syn keyword xsMacro RESTORE_LC_NUMERIC RESTORE_LC_NUMERIC_STANDARD +syn keyword xsMacro RESTORE_LC_NUMERIC_UNDERLYING RESTORE_NUMERIC_LOCAL +syn keyword xsMacro RESTORE_NUMERIC_STANDARD RETPUSHNO RETPUSHUNDEF +syn keyword xsMacro RETPUSHYES RETSETNO RETSETTARG RETSETUNDEF RETSETYES +syn keyword xsMacro RETURN RETURNOP RETURNX RETURN_PROBE REXEC_CHECKED +syn keyword xsMacro REXEC_COPY_SKIP_POST REXEC_COPY_SKIP_PRE REXEC_COPY_STR +syn keyword xsMacro REXEC_FAIL_ON_UNDERFLOW REXEC_IGNOREPOS REXEC_NOT_FIRST +syn keyword xsMacro REXEC_SCREAM RE_DEBUG_COMPILE_DUMP RE_DEBUG_COMPILE_FLAGS +syn keyword xsMacro RE_DEBUG_COMPILE_MASK RE_DEBUG_COMPILE_OPTIMISE +syn keyword xsMacro RE_DEBUG_COMPILE_PARSE RE_DEBUG_COMPILE_TEST +syn keyword xsMacro RE_DEBUG_COMPILE_TRIE RE_DEBUG_EXECUTE_INTUIT +syn keyword xsMacro RE_DEBUG_EXECUTE_MASK RE_DEBUG_EXECUTE_MATCH +syn keyword xsMacro RE_DEBUG_EXECUTE_TRIE RE_DEBUG_EXTRA_BUFFERS +syn keyword xsMacro RE_DEBUG_EXTRA_GPOS RE_DEBUG_EXTRA_MASK +syn keyword xsMacro RE_DEBUG_EXTRA_OFFDEBUG RE_DEBUG_EXTRA_OFFSETS +syn keyword xsMacro RE_DEBUG_EXTRA_OPTIMISE RE_DEBUG_EXTRA_STACK +syn keyword xsMacro RE_DEBUG_EXTRA_STATE RE_DEBUG_EXTRA_TRIE RE_DEBUG_FLAG +syn keyword xsMacro RE_DEBUG_FLAGS RE_PV_COLOR_DECL RE_PV_QUOTED_DECL +syn keyword xsMacro RE_SV_DUMPLEN RE_SV_ESCAPE RE_SV_TAIL +syn keyword xsMacro RE_TRACK_PATTERN_OFFSETS RE_TRIE_MAXBUF_INIT +syn keyword xsMacro RE_TRIE_MAXBUF_NAME RMS_DIR RMS_FAC RMS_FEX RMS_FNF +syn keyword xsMacro RMS_IFI RMS_ISI RMS_PRV ROTL32 ROTL64 ROTL_UV +syn keyword xsMacro RUNOPS_DEFAULT RV2CVOPCV_FLAG_MASK RV2CVOPCV_MARK_EARLY +syn keyword xsMacro RV2CVOPCV_MAYBE_NAME_GV RV2CVOPCV_RETURN_NAME_GV +syn keyword xsMacro RV2CVOPCV_RETURN_STUB RX_ANCHORED_SUBSTR RX_ANCHORED_UTF8 +syn keyword xsMacro RX_BUFF_IDX_CARET_FULLMATCH RX_BUFF_IDX_CARET_POSTMATCH +syn keyword xsMacro RX_BUFF_IDX_CARET_PREMATCH RX_BUFF_IDX_FULLMATCH +syn keyword xsMacro RX_BUFF_IDX_POSTMATCH RX_BUFF_IDX_PREMATCH +syn keyword xsMacro RX_CHECK_SUBSTR RX_COMPFLAGS RX_ENGINE RX_EXTFLAGS +syn keyword xsMacro RX_FLOAT_SUBSTR RX_FLOAT_UTF8 RX_GOFS RX_HAS_CUTGROUP +syn keyword xsMacro RX_INTFLAGS RX_ISTAINTED RX_LASTCLOSEPAREN RX_LASTPAREN +syn keyword xsMacro RX_MATCH_COPIED RX_MATCH_COPIED_off RX_MATCH_COPIED_on +syn keyword xsMacro RX_MATCH_COPIED_set RX_MATCH_COPY_FREE RX_MATCH_TAINTED +syn keyword xsMacro RX_MATCH_TAINTED_off RX_MATCH_TAINTED_on +syn keyword xsMacro RX_MATCH_TAINTED_set RX_MATCH_UTF8 RX_MATCH_UTF8_off +syn keyword xsMacro RX_MATCH_UTF8_on RX_MATCH_UTF8_set RX_MINLEN RX_MINLENRET +syn keyword xsMacro RX_NPARENS RX_OFFS RX_PRECOMP RX_PRECOMP_const RX_PRELEN +syn keyword xsMacro RX_REFCNT RX_SAVED_COPY RX_SUBBEG RX_SUBCOFFSET RX_SUBLEN +syn keyword xsMacro RX_SUBOFFSET RX_TAINT_on RX_UTF8 RX_WRAPLEN RX_WRAPPED +syn keyword xsMacro RX_WRAPPED_const RX_ZERO_LEN RXapif_ALL RXapif_CLEAR +syn keyword xsMacro RXapif_DELETE RXapif_EXISTS RXapif_FETCH RXapif_FIRSTKEY +syn keyword xsMacro RXapif_NEXTKEY RXapif_ONE RXapif_REGNAME RXapif_REGNAMES +syn keyword xsMacro RXapif_REGNAMES_COUNT RXapif_SCALAR RXapif_STORE +syn keyword xsMacro RXf_BASE_SHIFT RXf_CHECK_ALL RXf_COPY_DONE RXf_EVAL_SEEN +syn keyword xsMacro RXf_INTUIT_TAIL RXf_IS_ANCHORED RXf_MATCH_UTF8 +syn keyword xsMacro RXf_NO_INPLACE_SUBST RXf_NULL RXf_PMf_CHARSET +syn keyword xsMacro RXf_PMf_COMPILETIME RXf_PMf_EXTENDED +syn keyword xsMacro RXf_PMf_EXTENDED_MORE RXf_PMf_FLAGCOPYMASK RXf_PMf_FOLD +syn keyword xsMacro RXf_PMf_KEEPCOPY RXf_PMf_MULTILINE RXf_PMf_NOCAPTURE +syn keyword xsMacro RXf_PMf_SINGLELINE RXf_PMf_SPLIT RXf_PMf_STD_PMMOD +syn keyword xsMacro RXf_PMf_STD_PMMOD_SHIFT RXf_PMf_STRICT RXf_SKIPWHITE +syn keyword xsMacro RXf_SPLIT RXf_START_ONLY RXf_TAINTED RXf_TAINTED_SEEN +syn keyword xsMacro RXf_UNBOUNDED_QUANTIFIER_SEEN RXf_USE_INTUIT +syn keyword xsMacro RXf_USE_INTUIT_ML RXf_USE_INTUIT_NOML RXf_WHITE RXi_GET +syn keyword xsMacro RXi_GET_DECL RXi_SET RXp_COMPFLAGS RXp_EXTFLAGS +syn keyword xsMacro RXp_INTFLAGS RXp_MATCH_COPIED RXp_MATCH_COPIED_off +syn keyword xsMacro RXp_MATCH_COPIED_on RXp_MATCH_TAINTED +syn keyword xsMacro RXp_MATCH_TAINTED_on RXp_MATCH_UTF8 RXp_PAREN_NAMES ReANY +syn keyword xsMacro ReREFCNT_dec ReREFCNT_inc Renew Renewc RsPARA RsRECORD +syn keyword xsMacro RsSIMPLE RsSNARF SAFE_TRIE_NODENUM SANY SAVEADELETE +syn keyword xsMacro SAVEBOOL SAVECLEARSV SAVECOMPILEWARNINGS SAVECOMPPAD +syn keyword xsMacro SAVECOPFILE SAVECOPFILE_FREE SAVECOPLINE +syn keyword xsMacro SAVECOPSTASH_FREE SAVEDELETE SAVEDESTRUCTOR +syn keyword xsMacro SAVEDESTRUCTOR_X SAVEFREECOPHH SAVEFREEOP SAVEFREEPADNAME +syn keyword xsMacro SAVEFREEPV SAVEFREESV SAVEGENERICPV SAVEGENERICSV +syn keyword xsMacro SAVEHDELETE SAVEHINTS SAVEI16 SAVEI32 SAVEI8 SAVEINT +syn keyword xsMacro SAVEIV SAVELONG SAVEMORTALIZESV SAVEOP +syn keyword xsMacro SAVEPADSVANDMORTALIZE SAVEPARSER SAVEPPTR SAVESETSVFLAGS +syn keyword xsMacro SAVESHAREDPV SAVESPTR SAVESTACK_POS SAVESWITCHSTACK +syn keyword xsMacro SAVETMPS SAVEVPTR SAVE_DEFSV SAVE_ERRNO SAVE_MASK +syn keyword xsMacro SAVE_TIGHT_SHIFT SAVEf_KEEPOLDELEM SAVEf_SETMAGIC +syn keyword xsMacro SAVEt_ADELETE SAVEt_AELEM SAVEt_ALLOC SAVEt_APTR +syn keyword xsMacro SAVEt_ARG0_MAX SAVEt_ARG1_MAX SAVEt_ARG2_MAX SAVEt_AV +syn keyword xsMacro SAVEt_BOOL SAVEt_CLEARPADRANGE SAVEt_CLEARSV +syn keyword xsMacro SAVEt_COMPILE_WARNINGS SAVEt_COMPPAD SAVEt_DELETE +syn keyword xsMacro SAVEt_DESTRUCTOR SAVEt_DESTRUCTOR_X SAVEt_FREECOPHH +syn keyword xsMacro SAVEt_FREEOP SAVEt_FREEPADNAME SAVEt_FREEPV SAVEt_FREESV +syn keyword xsMacro SAVEt_GENERIC_PVREF SAVEt_GENERIC_SVREF SAVEt_GP +syn keyword xsMacro SAVEt_GP_ALIASED_SV SAVEt_GVSLOT SAVEt_GVSV SAVEt_HELEM +syn keyword xsMacro SAVEt_HINTS SAVEt_HPTR SAVEt_HV SAVEt_I16 SAVEt_I32 +syn keyword xsMacro SAVEt_I32_SMALL SAVEt_I8 SAVEt_INT SAVEt_INT_SMALL +syn keyword xsMacro SAVEt_ITEM SAVEt_IV SAVEt_LONG SAVEt_MORTALIZESV +syn keyword xsMacro SAVEt_NSTAB SAVEt_OP SAVEt_PADSV_AND_MORTALIZE +syn keyword xsMacro SAVEt_PARSER SAVEt_PPTR SAVEt_READONLY_OFF +syn keyword xsMacro SAVEt_REGCONTEXT SAVEt_SAVESWITCHSTACK SAVEt_SET_SVFLAGS +syn keyword xsMacro SAVEt_SHARED_PVREF SAVEt_SPTR SAVEt_STACK_POS +syn keyword xsMacro SAVEt_STRLEN SAVEt_SV SAVEt_SVREF SAVEt_VPTR +syn keyword xsMacro SAWAMPERSAND_LEFT SAWAMPERSAND_MIDDLE SAWAMPERSAND_RIGHT +syn keyword xsMacro SBOL SB_ENUM_COUNT SCAN_DEF SCAN_REPL SCAN_TR +syn keyword xsMacro SCAN_VERSION SCHED_YIELD SCOPE_SAVES_SIGNAL_MASK SEEK_CUR +syn keyword xsMacro SEEK_END SEEK_SET SELECT_MIN_BITS SEOL SETERRNO +syn keyword xsMacro SETGRENT_R_PROTO SETHOSTENT_R_PROTO SETLOCALE_R_PROTO +syn keyword xsMacro SETNETENT_R_PROTO SETPROTOENT_R_PROTO SETPWENT_R_PROTO +syn keyword xsMacro SETSERVENT_R_PROTO SETTARG SET_MARK_OFFSET +syn keyword xsMacro SET_NUMERIC_LOCAL SET_NUMERIC_STANDARD +syn keyword xsMacro SET_NUMERIC_UNDERLYING SET_THR SET_THREAD_SELF SETi SETn +syn keyword xsMacro SETp SETs SETu SHARP_S_SKIP SHIFTOP SHORTSIZE SH_PATH +syn keyword xsMacro SIGABRT SIGILL SIG_NAME SIG_NUM SIG_SIZE SINGLE_PAT_MOD +syn keyword xsMacro SIPROUND SITEARCH SITEARCH_EXP SITELIB SITELIB_EXP +syn keyword xsMacro SITELIB_STEM SIZE_ALIGN SIZE_ONLY SKIP SKIP_next +syn keyword xsMacro SKIP_next_fail SLOPPYDIVIDE SOCKET_OPEN_MODE SPAGAIN +syn keyword xsMacro SPRINTF_RETURNS_STRLEN SRAND48_R_PROTO SRANDOM_R_PROTO +syn keyword xsMacro SSCHECK SSC_MATCHES_EMPTY_STRING SSGROW SSNEW SSNEWa +syn keyword xsMacro SSNEWat SSNEWt SSPOPBOOL SSPOPDPTR SSPOPDXPTR SSPOPINT +syn keyword xsMacro SSPOPIV SSPOPLONG SSPOPPTR SSPOPUV SSPTR SSPTRt +syn keyword xsMacro SSPUSHBOOL SSPUSHDPTR SSPUSHDXPTR SSPUSHINT SSPUSHIV +syn keyword xsMacro SSPUSHLONG SSPUSHPTR SSPUSHUV SS_ACCVIO SS_ADD_BOOL +syn keyword xsMacro SS_ADD_DPTR SS_ADD_DXPTR SS_ADD_END SS_ADD_INT SS_ADD_IV +syn keyword xsMacro SS_ADD_LONG SS_ADD_PTR SS_ADD_UV SS_BUFFEROVF +syn keyword xsMacro SS_DEVOFFLINE SS_IVCHAN SS_MAXPUSH SS_NOPRIV SS_NORMAL +syn keyword xsMacro SSize_t_MAX ST STANDARD_C STAR STARTPERL START_EXTERN_C +syn keyword xsMacro START_MY_CXT STATIC STATIC_ASSERT_1 STATIC_ASSERT_2 +syn keyword xsMacro STATIC_ASSERT_GLOBAL STATIC_ASSERT_STMT +syn keyword xsMacro STATUS_ALL_FAILURE STATUS_ALL_SUCCESS STATUS_CURRENT +syn keyword xsMacro STATUS_EXIT STATUS_EXIT_SET STATUS_NATIVE +syn keyword xsMacro STATUS_NATIVE_CHILD_SET STATUS_UNIX STATUS_UNIX_EXIT_SET +syn keyword xsMacro STATUS_UNIX_SET STDCHAR STDIO_STREAM_ARRAY STD_PAT_MODS +syn keyword xsMacro STD_PMMOD_FLAGS_CLEAR STD_PMMOD_FLAGS_PARSE_X_WARN +syn keyword xsMacro STMT_END STMT_START STORE_LC_NUMERIC_FORCE_TO_UNDERLYING +syn keyword xsMacro STORE_LC_NUMERIC_SET_TO_NEEDED +syn keyword xsMacro STORE_LC_NUMERIC_STANDARD_SET_UNDERLYING +syn keyword xsMacro STORE_LC_NUMERIC_UNDERLYING_SET_STANDARD +syn keyword xsMacro STORE_NUMERIC_LOCAL_SET_STANDARD +syn keyword xsMacro STORE_NUMERIC_STANDARD_FORCE_LOCAL +syn keyword xsMacro STORE_NUMERIC_STANDARD_SET_LOCAL STRERROR_R_PROTO STRING +syn keyword xsMacro STRINGIFY STRUCT_OFFSET STRUCT_SV STR_LEN STR_SZ +syn keyword xsMacro STR_WITH_LEN ST_INO_SIGN ST_INO_SIZE SUB +syn keyword xsMacro SUBST_TAINT_BOOLRET SUBST_TAINT_PAT SUBST_TAINT_REPL +syn keyword xsMacro SUBST_TAINT_RETAINT SUBST_TAINT_STR SUBVERSION SUCCEED +syn keyword xsMacro SUSPEND SVTYPEMASK SV_CATBYTES SV_CATUTF8 +syn keyword xsMacro SV_CHECK_THINKFIRST SV_CHECK_THINKFIRST_COW_DROP SV_CONST +syn keyword xsMacro SV_CONSTS_COUNT SV_CONST_BINMODE SV_CONST_CLEAR +syn keyword xsMacro SV_CONST_CLOSE SV_CONST_DELETE SV_CONST_DESTROY +syn keyword xsMacro SV_CONST_EOF SV_CONST_EXISTS SV_CONST_EXTEND +syn keyword xsMacro SV_CONST_FETCH SV_CONST_FETCHSIZE SV_CONST_FILENO +syn keyword xsMacro SV_CONST_FIRSTKEY SV_CONST_GETC SV_CONST_NEXTKEY +syn keyword xsMacro SV_CONST_OPEN SV_CONST_POP SV_CONST_PRINT SV_CONST_PRINTF +syn keyword xsMacro SV_CONST_PUSH SV_CONST_READ SV_CONST_READLINE +syn keyword xsMacro SV_CONST_RETURN SV_CONST_SCALAR SV_CONST_SEEK +syn keyword xsMacro SV_CONST_SHIFT SV_CONST_SPLICE SV_CONST_STORE +syn keyword xsMacro SV_CONST_STORESIZE SV_CONST_TELL SV_CONST_TIEARRAY +syn keyword xsMacro SV_CONST_TIEHANDLE SV_CONST_TIEHASH SV_CONST_TIESCALAR +syn keyword xsMacro SV_CONST_UNSHIFT SV_CONST_UNTIE SV_CONST_WRITE +syn keyword xsMacro SV_COW_DROP_PV SV_COW_OTHER_PVS SV_COW_REFCNT_MAX +syn keyword xsMacro SV_COW_SHARED_HASH_KEYS SV_DO_COW_SVSETSV +syn keyword xsMacro SV_FORCE_UTF8_UPGRADE SV_GMAGIC SV_HAS_TRAILING_NUL +syn keyword xsMacro SV_IMMEDIATE_UNREF SV_MUTABLE_RETURN SV_NOSTEAL +syn keyword xsMacro SV_SAVED_COPY SV_SKIP_OVERLOAD SV_SMAGIC +syn keyword xsMacro SV_UNDEF_RETURNS_NULL SV_UTF8_NO_ENCODING SVrepl_EVAL +syn keyword xsMacro SVt_FIRST SVt_MASK SWITCHSTACK SYMBIAN SYSTEM_GMTIME_MAX +syn keyword xsMacro SYSTEM_GMTIME_MIN SYSTEM_LOCALTIME_MAX +syn keyword xsMacro SYSTEM_LOCALTIME_MIN S_IEXEC S_IFIFO S_IFMT S_IREAD +syn keyword xsMacro S_IRGRP S_IROTH S_IRUSR S_IRWXG S_IRWXO S_IRWXU S_ISBLK +syn keyword xsMacro S_ISCHR S_ISDIR S_ISFIFO S_ISGID S_ISLNK S_ISREG S_ISSOCK +syn keyword xsMacro S_ISUID S_IWGRP S_IWOTH S_IWRITE S_IWUSR S_IXGRP S_IXOTH +syn keyword xsMacro S_IXUSR S_PAT_MODS Safefree Semctl Sigjmp_buf Siglongjmp +syn keyword xsMacro Sigsetjmp Size_t_MAX Size_t_size StGiFy StashHANDLER Stat +syn keyword xsMacro Strerror Strtol Strtoul StructCopy SvAMAGIC SvANY +syn keyword xsMacro SvCANCOW SvCANEXISTDELETE SvCOMPILED SvCOMPILED_off +syn keyword xsMacro SvCOMPILED_on SvCUR SvCUR_set SvDESTROYABLE SvEND +syn keyword xsMacro SvEND_set SvENDx SvEVALED SvEVALED_off SvEVALED_on SvFAKE +syn keyword xsMacro SvFAKE_off SvFAKE_on SvFLAGS SvGAMAGIC SvGETMAGIC SvGID +syn keyword xsMacro SvGMAGICAL SvGMAGICAL_off SvGMAGICAL_on SvGROW +syn keyword xsMacro SvGROW_mutable SvIMMORTAL SvIOK SvIOK_UV SvIOK_nog +syn keyword xsMacro SvIOK_nogthink SvIOK_notUV SvIOK_off SvIOK_on SvIOK_only +syn keyword xsMacro SvIOK_only_UV SvIOKp SvIOKp_on SvIS_FREED SvIV SvIVX +syn keyword xsMacro SvIVXx SvIV_nomg SvIV_please SvIV_please_nomg SvIV_set +syn keyword xsMacro SvIVx SvIsCOW SvIsCOW_normal SvIsCOW_off SvIsCOW_on +syn keyword xsMacro SvIsCOW_shared_hash SvIsUV SvIsUV_off SvIsUV_on SvLEN +syn keyword xsMacro SvLEN_set SvLENx SvLOCK SvMAGIC SvMAGICAL SvMAGICAL_off +syn keyword xsMacro SvMAGICAL_on SvMAGIC_set SvNIOK SvNIOK_nog +syn keyword xsMacro SvNIOK_nogthink SvNIOK_off SvNIOKp SvNOK SvNOK_nog +syn keyword xsMacro SvNOK_nogthink SvNOK_off SvNOK_on SvNOK_only SvNOKp +syn keyword xsMacro SvNOKp_on SvNV SvNVX SvNVXx SvNV_nomg SvNV_set SvNVx +syn keyword xsMacro SvOBJECT SvOBJECT_off SvOBJECT_on SvOK SvOK_off +syn keyword xsMacro SvOK_off_exc_UV SvOKp SvOOK SvOOK_off SvOOK_offset +syn keyword xsMacro SvOOK_on SvOURSTASH SvOURSTASH_set SvPADMY SvPADMY_on +syn keyword xsMacro SvPADSTALE SvPADSTALE_off SvPADSTALE_on SvPADTMP +syn keyword xsMacro SvPADTMP_off SvPADTMP_on SvPAD_OUR SvPAD_OUR_on +syn keyword xsMacro SvPAD_STATE SvPAD_STATE_on SvPAD_TYPED SvPAD_TYPED_on +syn keyword xsMacro SvPCS_IMPORTED SvPCS_IMPORTED_off SvPCS_IMPORTED_on +syn keyword xsMacro SvPEEK SvPOK SvPOK_byte_nog SvPOK_byte_nogthink +syn keyword xsMacro SvPOK_byte_pure_nogthink SvPOK_nog SvPOK_nogthink +syn keyword xsMacro SvPOK_off SvPOK_on SvPOK_only SvPOK_only_UTF8 +syn keyword xsMacro SvPOK_pure_nogthink SvPOK_utf8_nog SvPOK_utf8_nogthink +syn keyword xsMacro SvPOK_utf8_pure_nogthink SvPOKp SvPOKp_on SvPV SvPVX +syn keyword xsMacro SvPVX_const SvPVX_mutable SvPVXtrue SvPVXx SvPV_const +syn keyword xsMacro SvPV_flags SvPV_flags_const SvPV_flags_const_nolen +syn keyword xsMacro SvPV_flags_mutable SvPV_force SvPV_force_flags +syn keyword xsMacro SvPV_force_flags_mutable SvPV_force_flags_nolen +syn keyword xsMacro SvPV_force_mutable SvPV_force_nolen SvPV_force_nomg +syn keyword xsMacro SvPV_force_nomg_nolen SvPV_free SvPV_mutable SvPV_nolen +syn keyword xsMacro SvPV_nolen_const SvPV_nomg SvPV_nomg_const +syn keyword xsMacro SvPV_nomg_const_nolen SvPV_nomg_nolen SvPV_renew SvPV_set +syn keyword xsMacro SvPV_shrink_to_cur SvPVbyte SvPVbyte_force SvPVbyte_nolen +syn keyword xsMacro SvPVbytex SvPVbytex_force SvPVbytex_nolen SvPVutf8 +syn keyword xsMacro SvPVutf8_force SvPVutf8_nolen SvPVutf8x SvPVutf8x_force +syn keyword xsMacro SvPVx SvPVx_const SvPVx_force SvPVx_nolen +syn keyword xsMacro SvPVx_nolen_const SvREADONLY SvREADONLY_off SvREADONLY_on +syn keyword xsMacro SvREFCNT SvREFCNT_IMMORTAL SvREFCNT_dec SvREFCNT_dec_NN +syn keyword xsMacro SvREFCNT_inc SvREFCNT_inc_NN SvREFCNT_inc_simple +syn keyword xsMacro SvREFCNT_inc_simple_NN SvREFCNT_inc_simple_void +syn keyword xsMacro SvREFCNT_inc_simple_void_NN SvREFCNT_inc_void +syn keyword xsMacro SvREFCNT_inc_void_NN SvRELEASE_IVX SvRELEASE_IVX_ +syn keyword xsMacro SvRMAGICAL SvRMAGICAL_off SvRMAGICAL_on SvROK SvROK_off +syn keyword xsMacro SvROK_on SvRV SvRV_const SvRV_set SvRVx SvRX SvRXOK +syn keyword xsMacro SvSCREAM SvSCREAM_off SvSCREAM_on SvSETMAGIC SvSHARE +syn keyword xsMacro SvSHARED_HASH SvSHARED_HEK_FROM_PV SvSMAGICAL +syn keyword xsMacro SvSMAGICAL_off SvSMAGICAL_on SvSTASH SvSTASH_set +syn keyword xsMacro SvSetMagicSV SvSetMagicSV_nosteal SvSetSV SvSetSV_and +syn keyword xsMacro SvSetSV_nosteal SvSetSV_nosteal_and SvTAIL SvTAIL_off +syn keyword xsMacro SvTAIL_on SvTAINT SvTAINTED SvTAINTED_off SvTAINTED_on +syn keyword xsMacro SvTEMP SvTEMP_off SvTEMP_on SvTHINKFIRST SvTIED_mg +syn keyword xsMacro SvTIED_obj SvTRUE SvTRUE_NN SvTRUE_common SvTRUE_nomg +syn keyword xsMacro SvTRUE_nomg_NN SvTRUEx SvTRUEx_nomg SvTYPE SvUID SvUNLOCK +syn keyword xsMacro SvUOK SvUOK_nog SvUOK_nogthink SvUPGRADE SvUTF8 +syn keyword xsMacro SvUTF8_off SvUTF8_on SvUV SvUVX SvUVXx SvUV_nomg SvUV_set +syn keyword xsMacro SvUVx SvVALID SvVALID_off SvVALID_on SvVOK SvVSTRING_mg +syn keyword xsMacro SvWEAKREF SvWEAKREF_off SvWEAKREF_on Sv_Grow TAIL TAINT +syn keyword xsMacro TAINTING_get TAINTING_set TAINT_ENV TAINT_IF TAINT_NOT +syn keyword xsMacro TAINT_PROPER TAINT_WARN_get TAINT_WARN_set TAINT_get +syn keyword xsMacro TAINT_set THING THR THREAD_CREATE +syn keyword xsMacro THREAD_CREATE_NEEDS_STACK THREAD_POST_CREATE +syn keyword xsMacro THREAD_RET_CAST THREAD_RET_TYPE +syn keyword xsMacro TIED_METHOD_ARGUMENTS_ON_STACK +syn keyword xsMacro TIED_METHOD_MORTALIZE_NOT_NEEDED TIED_METHOD_SAY +syn keyword xsMacro TIME64_CONFIG_H TIME64_H TM TMPNAM_R_PROTO TOO_LATE_FOR +syn keyword xsMacro TOO_LATE_FOR_ TOPBLOCK TOPMARK TOPi TOPl TOPm1s TOPn TOPp +syn keyword xsMacro TOPp1s TOPpx TOPs TOPu TOPul TRIE TRIEC TRIE_BITMAP +syn keyword xsMacro TRIE_BITMAP_BYTE TRIE_BITMAP_CLEAR TRIE_BITMAP_SET +syn keyword xsMacro TRIE_BITMAP_TEST TRIE_CHARCOUNT TRIE_NODEIDX TRIE_NODENUM +syn keyword xsMacro TRIE_WORDS_OFFSET TRIE_next TRIE_next_fail TRUE +syn keyword xsMacro TTYNAME_R_PROTO TWO_BYTE_UTF8_TO_NATIVE +syn keyword xsMacro TWO_BYTE_UTF8_TO_UNI TYPE_CHARS TYPE_DIGITS Timeval +syn keyword xsMacro U16SIZE U16TYPE U16_CONST U16_MAX U16_MIN U32SIZE U32TYPE +syn keyword xsMacro U32_ALIGNMENT_REQUIRED U32_CONST U32_MAX U32_MAX_P1 +syn keyword xsMacro U32_MAX_P1_HALF U32_MIN U64SIZE U64TYPE U64_CONST U8SIZE +syn keyword xsMacro U8TO16_LE U8TO32_LE U8TO64_LE U8TYPE U8_MAX U8_MIN +syn keyword xsMacro UCHARAT UINT32_MIN UINT64_C UINT64_MIN UMINUS +syn keyword xsMacro UNALIGNED_SAFE UNDERBAR UNICODE_ALLOW_ANY +syn keyword xsMacro UNICODE_ALLOW_SUPER UNICODE_ALLOW_SURROGATE +syn keyword xsMacro UNICODE_BYTE_ORDER_MARK UNICODE_DISALLOW_FE_FF +syn keyword xsMacro UNICODE_DISALLOW_ILLEGAL_INTERCHANGE +syn keyword xsMacro UNICODE_DISALLOW_NONCHAR UNICODE_DISALLOW_SUPER +syn keyword xsMacro UNICODE_DISALLOW_SURROGATE +syn keyword xsMacro UNICODE_GREEK_CAPITAL_LETTER_SIGMA +syn keyword xsMacro UNICODE_GREEK_SMALL_LETTER_FINAL_SIGMA +syn keyword xsMacro UNICODE_GREEK_SMALL_LETTER_SIGMA +syn keyword xsMacro UNICODE_IS_BYTE_ORDER_MARK UNICODE_IS_FE_FF +syn keyword xsMacro UNICODE_IS_NONCHAR UNICODE_IS_REPLACEMENT +syn keyword xsMacro UNICODE_IS_SUPER UNICODE_IS_SURROGATE UNICODE_LINE_SEPA_0 +syn keyword xsMacro UNICODE_LINE_SEPA_1 UNICODE_LINE_SEPA_2 +syn keyword xsMacro UNICODE_PARA_SEPA_0 UNICODE_PARA_SEPA_1 +syn keyword xsMacro UNICODE_PARA_SEPA_2 UNICODE_PAT_MOD UNICODE_PAT_MODS +syn keyword xsMacro UNICODE_REPLACEMENT UNICODE_SURROGATE_FIRST +syn keyword xsMacro UNICODE_SURROGATE_LAST UNICODE_WARN_FE_FF +syn keyword xsMacro UNICODE_WARN_ILLEGAL_INTERCHANGE UNICODE_WARN_NONCHAR +syn keyword xsMacro UNICODE_WARN_SUPER UNICODE_WARN_SURROGATE UNIOP UNIOPSUB +syn keyword xsMacro UNISKIP UNI_DISPLAY_BACKSLASH UNI_DISPLAY_ISPRINT +syn keyword xsMacro UNI_DISPLAY_QQ UNI_DISPLAY_REGEX UNI_IS_INVARIANT +syn keyword xsMacro UNI_TO_NATIVE UNKNOWN_ERRNO_MSG UNLESS UNLESSM UNLIKELY +syn keyword xsMacro UNLINK UNLOCK_DOLLARZERO_MUTEX UNLOCK_LC_NUMERIC_STANDARD +syn keyword xsMacro UNLOCK_NUMERIC_STANDARD UNOP_AUX_item_sv UNTIL +syn keyword xsMacro UPG_VERSION USE USE_64_BIT_ALL USE_64_BIT_INT +syn keyword xsMacro USE_64_BIT_RAWIO USE_64_BIT_STDIO USE_BSDPGRP +syn keyword xsMacro USE_DYNAMIC_LOADING USE_ENVIRON_ARRAY USE_HASH_SEED +syn keyword xsMacro USE_HEAP_INSTEAD_OF_STACK USE_LARGE_FILES USE_LEFT +syn keyword xsMacro USE_LOCALE USE_LOCALE_COLLATE USE_LOCALE_CTYPE +syn keyword xsMacro USE_LOCALE_MESSAGES USE_LOCALE_MONETARY +syn keyword xsMacro USE_LOCALE_NUMERIC USE_LOCALE_TIME USE_PERLIO +syn keyword xsMacro USE_PERL_PERTURB_KEYS USE_REENTRANT_API +syn keyword xsMacro USE_SEMCTL_SEMID_DS USE_SEMCTL_SEMUN USE_STAT_BLOCKS +syn keyword xsMacro USE_STAT_RDEV USE_STDIO USE_STRUCT_COPY USE_SYSTEM_GMTIME +syn keyword xsMacro USE_SYSTEM_LOCALTIME USE_THREADS USE_TM64 +syn keyword xsMacro USE_UTF8_IN_NAMES USING_MSVC6 UTF8SKIP UTF8_ACCUMULATE +syn keyword xsMacro UTF8_ALLOW_ANY UTF8_ALLOW_ANYUV UTF8_ALLOW_CONTINUATION +syn keyword xsMacro UTF8_ALLOW_DEFAULT UTF8_ALLOW_EMPTY UTF8_ALLOW_FFFF +syn keyword xsMacro UTF8_ALLOW_LONG UTF8_ALLOW_NON_CONTINUATION +syn keyword xsMacro UTF8_ALLOW_SHORT UTF8_ALLOW_SURROGATE UTF8_CHECK_ONLY +syn keyword xsMacro UTF8_DISALLOW_FE_FF UTF8_DISALLOW_ILLEGAL_INTERCHANGE +syn keyword xsMacro UTF8_DISALLOW_NONCHAR UTF8_DISALLOW_SUPER +syn keyword xsMacro UTF8_DISALLOW_SURROGATE UTF8_EIGHT_BIT_HI +syn keyword xsMacro UTF8_EIGHT_BIT_LO +syn keyword xsMacro UTF8_FIRST_PROBLEMATIC_CODE_POINT_FIRST_BYTE +syn keyword xsMacro UTF8_IS_ABOVE_LATIN1 UTF8_IS_CONTINUATION +syn keyword xsMacro UTF8_IS_CONTINUED UTF8_IS_DOWNGRADEABLE_START +syn keyword xsMacro UTF8_IS_INVARIANT UTF8_IS_NEXT_CHAR_DOWNGRADEABLE +syn keyword xsMacro UTF8_IS_NONCHAR_ +syn keyword xsMacro UTF8_IS_NONCHAR_GIVEN_THAT_NON_SUPER_AND_GE_PROBLEMATIC +syn keyword xsMacro UTF8_IS_REPLACEMENT UTF8_IS_START UTF8_IS_SUPER +syn keyword xsMacro UTF8_IS_SURROGATE UTF8_MAXBYTES UTF8_MAXBYTES_CASE +syn keyword xsMacro UTF8_MAXLEN UTF8_MAX_FOLD_CHAR_EXPAND UTF8_QUAD_MAX +syn keyword xsMacro UTF8_TWO_BYTE_HI UTF8_TWO_BYTE_HI_nocast UTF8_TWO_BYTE_LO +syn keyword xsMacro UTF8_TWO_BYTE_LO_nocast UTF8_WARN_FE_FF +syn keyword xsMacro UTF8_WARN_ILLEGAL_INTERCHANGE UTF8_WARN_NONCHAR +syn keyword xsMacro UTF8_WARN_SUPER UTF8_WARN_SURROGATE UTF8f UTF8fARG +syn keyword xsMacro UTF_ACCUMULATION_OVERFLOW_MASK UTF_ACCUMULATION_SHIFT +syn keyword xsMacro UTF_CONTINUATION_MARK UTF_CONTINUATION_MASK +syn keyword xsMacro UTF_START_MARK UTF_START_MASK UTF_TO_NATIVE +syn keyword xsMacro UVCHR_IS_INVARIANT UVCHR_SKIP UVSIZE UVTYPE UVXf UV_DIG +syn keyword xsMacro UV_MAX UV_MAX_P1 UV_MAX_P1_HALF UV_MIN UVf U_32 U_I U_L +syn keyword xsMacro U_S U_V Uid_t_f Uid_t_sign Uid_t_size VAL_EAGAIN +syn keyword xsMacro VAL_O_NONBLOCK VCMP VERB VNORMAL VNUMIFY VOL VSTRINGIFY +syn keyword xsMacro VTBL_amagic VTBL_amagicelem VTBL_arylen VTBL_bm +syn keyword xsMacro VTBL_collxfrm VTBL_dbline VTBL_defelem VTBL_env +syn keyword xsMacro VTBL_envelem VTBL_fm VTBL_glob VTBL_isa VTBL_isaelem +syn keyword xsMacro VTBL_mglob VTBL_nkeys VTBL_pack VTBL_packelem VTBL_pos +syn keyword xsMacro VTBL_regdata VTBL_regdatum VTBL_regexp VTBL_sigelem +syn keyword xsMacro VTBL_substr VTBL_sv VTBL_taint VTBL_uvar VTBL_vec +syn keyword xsMacro VT_NATIVE VUTIL_REPLACE_CORE VVERIFY WARN_ALL +syn keyword xsMacro WARN_ALLstring WARN_AMBIGUOUS WARN_BAREWORD WARN_CLOSED +syn keyword xsMacro WARN_CLOSURE WARN_DEBUGGING WARN_DEPRECATED WARN_DIGIT +syn keyword xsMacro WARN_EXEC WARN_EXITING WARN_EXPERIMENTAL +syn keyword xsMacro WARN_EXPERIMENTAL__AUTODEREF WARN_EXPERIMENTAL__BITWISE +syn keyword xsMacro WARN_EXPERIMENTAL__CONST_ATTR +syn keyword xsMacro WARN_EXPERIMENTAL__LEXICAL_SUBS +syn keyword xsMacro WARN_EXPERIMENTAL__LEXICAL_TOPIC +syn keyword xsMacro WARN_EXPERIMENTAL__POSTDEREF +syn keyword xsMacro WARN_EXPERIMENTAL__REFALIASING +syn keyword xsMacro WARN_EXPERIMENTAL__REGEX_SETS +syn keyword xsMacro WARN_EXPERIMENTAL__RE_STRICT +syn keyword xsMacro WARN_EXPERIMENTAL__SIGNATURES +syn keyword xsMacro WARN_EXPERIMENTAL__SMARTMATCH +syn keyword xsMacro WARN_EXPERIMENTAL__WIN32_PERLIO WARN_GLOB +syn keyword xsMacro WARN_ILLEGALPROTO WARN_IMPRECISION WARN_INPLACE +syn keyword xsMacro WARN_INTERNAL WARN_IO WARN_LAYER WARN_LOCALE WARN_MALLOC +syn keyword xsMacro WARN_MISC WARN_MISSING WARN_NEWLINE WARN_NONCHAR +syn keyword xsMacro WARN_NONEstring WARN_NON_UNICODE WARN_NUMERIC WARN_ONCE +syn keyword xsMacro WARN_OVERFLOW WARN_PACK WARN_PARENTHESIS WARN_PIPE +syn keyword xsMacro WARN_PORTABLE WARN_PRECEDENCE WARN_PRINTF WARN_PROTOTYPE +syn keyword xsMacro WARN_QW WARN_RECURSION WARN_REDEFINE WARN_REDUNDANT +syn keyword xsMacro WARN_REGEXP WARN_RESERVED WARN_SEMICOLON WARN_SEVERE +syn keyword xsMacro WARN_SIGNAL WARN_SUBSTR WARN_SURROGATE WARN_SYNTAX +syn keyword xsMacro WARN_SYSCALLS WARN_TAINT WARN_THREADS WARN_UNINITIALIZED +syn keyword xsMacro WARN_UNOPENED WARN_UNPACK WARN_UNTIE WARN_UTF8 WARN_VOID +syn keyword xsMacro WARNshift WARNsize WB_ENUM_COUNT WEXITSTATUS WHEN WHILE +syn keyword xsMacro WHILEM WHILEM_A_max WHILEM_A_max_fail WHILEM_A_min +syn keyword xsMacro WHILEM_A_min_fail WHILEM_A_pre WHILEM_A_pre_fail +syn keyword xsMacro WHILEM_B_max WHILEM_B_max_fail WHILEM_B_min +syn keyword xsMacro WHILEM_B_min_fail WIDEST_UTYPE WIFEXITED WIFSIGNALED +syn keyword xsMacro WIFSTOPPED WIN32SCK_IS_STDSCK WNOHANG WORD WSTOPSIG +syn keyword xsMacro WTERMSIG WUNTRACED XDIGIT_VALUE XHvTOTALKEYS +syn keyword xsMacro XOPd_xop_class XOPd_xop_desc XOPd_xop_name XOPd_xop_peep +syn keyword xsMacro XOPf_xop_class XOPf_xop_desc XOPf_xop_name XOPf_xop_peep +syn keyword xsMacro XPUSHTARG XPUSHi XPUSHmortal XPUSHn XPUSHp XPUSHs XPUSHu +syn keyword xsMacro XPUSHundef XS XSANY XSINTERFACE_CVT XSINTERFACE_CVT_ANON +syn keyword xsMacro XSINTERFACE_FUNC XSINTERFACE_FUNC_SET XSPROTO XSRETURN +syn keyword xsMacro XSRETURN_EMPTY XSRETURN_IV XSRETURN_NO XSRETURN_NV +syn keyword xsMacro XSRETURN_PV XSRETURN_PVN XSRETURN_UNDEF XSRETURN_UV +syn keyword xsMacro XSRETURN_YES XST_mIV XST_mNO XST_mNV XST_mPV XST_mPVN +syn keyword xsMacro XST_mUNDEF XST_mUV XST_mYES XS_APIVERSION_BOOTCHECK +syn keyword xsMacro XS_APIVERSION_POPMARK_BOOTCHECK +syn keyword xsMacro XS_APIVERSION_SETXSUBFN_POPMARK_BOOTCHECK +syn keyword xsMacro XS_BOTHVERSION_BOOTCHECK XS_BOTHVERSION_POPMARK_BOOTCHECK +syn keyword xsMacro XS_BOTHVERSION_SETXSUBFN_POPMARK_BOOTCHECK +syn keyword xsMacro XS_DYNAMIC_FILENAME XS_EXTERNAL XS_INTERNAL +syn keyword xsMacro XS_SETXSUBFN_POPMARK XS_VERSION_BOOTCHECK XSprePUSH +syn keyword xsMacro XTENDED_PAT_MOD XopDISABLE XopENABLE XopENTRY +syn keyword xsMacro XopENTRYCUSTOM XopENTRY_set XopFLAGS YADAYADA YIELD +syn keyword xsMacro YYEMPTY YYSTYPE_IS_DECLARED YYSTYPE_IS_TRIVIAL +syn keyword xsMacro YYTOKENTYPE Zero ZeroD _ _CANNOT _CC_ALPHA +syn keyword xsMacro _CC_ALPHANUMERIC _CC_ASCII _CC_BLANK _CC_CASED +syn keyword xsMacro _CC_CHARNAME_CONT _CC_CNTRL _CC_DIGIT _CC_GRAPH +syn keyword xsMacro _CC_IDFIRST _CC_IS_IN_SOME_FOLD _CC_LOWER +syn keyword xsMacro _CC_MNEMONIC_CNTRL _CC_NONLATIN1_FOLD +syn keyword xsMacro _CC_NONLATIN1_SIMPLE_FOLD _CC_NON_FINAL_FOLD _CC_PRINT +syn keyword xsMacro _CC_PUNCT _CC_QUOTEMETA _CC_SPACE _CC_UPPER _CC_VERTSPACE +syn keyword xsMacro _CC_WORDCHAR _CC_XDIGIT _CC_mask _CC_mask_A +syn keyword xsMacro _CHECK_AND_OUTPUT_WIDE_LOCALE_CP_MSG +syn keyword xsMacro _CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG +syn keyword xsMacro _CHECK_AND_WARN_PROBLEMATIC_LOCALE +syn keyword xsMacro _CORE_SWASH_INIT_ACCEPT_INVLIST +syn keyword xsMacro _CORE_SWASH_INIT_RETURN_IF_UNDEF +syn keyword xsMacro _CORE_SWASH_INIT_USER_DEFINED_PROPERTY _CPERLarg +syn keyword xsMacro _FIRST_NON_SWASH_CC _GNU_SOURCE +syn keyword xsMacro _HAS_NONLATIN1_FOLD_CLOSURE_ONLY_FOR_USE_BY_REGCOMP_DOT_C_AND_REGEXEC_DOT_C +syn keyword xsMacro _HAS_NONLATIN1_SIMPLE_FOLD_CLOSURE_ONLY_FOR_USE_BY_REGCOMP_DOT_C_AND_REGEXEC_DOT_C +syn keyword xsMacro _HIGHEST_REGCOMP_DOT_H_SYNC _INC_PERL_XSUB_H +syn keyword xsMacro _IS_IN_SOME_FOLD_ONLY_FOR_USE_BY_REGCOMP_DOT_C +syn keyword xsMacro _IS_MNEMONIC_CNTRL_ONLY_FOR_USE_BY_REGCOMP_DOT_C +syn keyword xsMacro _IS_NON_FINAL_FOLD_ONLY_FOR_USE_BY_REGCOMP_DOT_C _LC_CAST +syn keyword xsMacro _MEM_WRAP_NEEDS_RUNTIME_CHECK _MEM_WRAP_WILL_WRAP +syn keyword xsMacro _NOT_IN_NUMERIC_STANDARD _NOT_IN_NUMERIC_UNDERLYING +syn keyword xsMacro _NV_BODYLESS_UNION _OP_SIBPARENT_FIELDNAME _PERLIOL_H +syn keyword xsMacro _PERLIO_H _PERL_OBJECT_THIS _REGEXP_COMMON +syn keyword xsMacro _RXf_PMf_CHARSET_SHIFT _RXf_PMf_SHIFT_COMPILETIME +syn keyword xsMacro _RXf_PMf_SHIFT_NEXT _STDIO_H _STDIO_INCLUDED _V +syn keyword xsMacro _XPVCV_COMMON _XPV_HEAD __ASSERT_ __BASE_TWO_BYTE_HI +syn keyword xsMacro __BASE_TWO_BYTE_LO __Inc__IPerl___ +syn keyword xsMacro __PATCHLEVEL_H_INCLUDED__ __PL_inf_float_int32 +syn keyword xsMacro __PL_nan_float_int32 __STDIO_LOADED +syn keyword xsMacro __attribute__deprecated__ __attribute__format__ +syn keyword xsMacro __attribute__format__null_ok__ __attribute__malloc__ +syn keyword xsMacro __attribute__nonnull__ __attribute__noreturn__ +syn keyword xsMacro __attribute__pure__ __attribute__unused__ +syn keyword xsMacro __attribute__warn_unused_result__ __filbuf __flsbuf +syn keyword xsMacro __has_builtin __perlapi_h__ _config_h_ _exit _filbuf +syn keyword xsMacro _flsbuf _generic_LC _generic_LC_base +syn keyword xsMacro _generic_LC_func_utf8 _generic_LC_swash_utf8 +syn keyword xsMacro _generic_LC_swash_uvchr _generic_LC_underscore +syn keyword xsMacro _generic_LC_utf8 _generic_LC_uvchr _generic_func_utf8 +syn keyword xsMacro _generic_isCC _generic_isCC_A _generic_swash_uni +syn keyword xsMacro _generic_swash_utf8 _generic_toFOLD_LC +syn keyword xsMacro _generic_toLOWER_LC _generic_toUPPER_LC _generic_uni +syn keyword xsMacro _generic_utf8 _generic_utf8_no_upper_latin1 _isQMC +syn keyword xsMacro _isQUOTEMETA _swab_16_ _swab_32_ _swab_64_ aTHXa aTHXo +syn keyword xsMacro aTHXo_ aTHXx aTHXx_ abort accept access +syn keyword xsMacro anchored_end_shift anchored_offset anchored_substr +syn keyword xsMacro anchored_utf8 asctime assert assert_ assert_not_ROK +syn keyword xsMacro assert_not_glob atoll av_tindex bcmp bind blk_eval +syn keyword xsMacro blk_format blk_gimme blk_givwhen blk_loop blk_oldcop +syn keyword xsMacro blk_oldmarksp blk_oldpm blk_oldscopesp blk_oldsp blk_sub +syn keyword xsMacro blk_u16 bool boolSV cBINOP cBINOPo cBINOPx cBOOL cCOP +syn keyword xsMacro cCOPo cCOPx cGVOP_gv cGVOPo_gv cGVOPx_gv cLISTOP cLISTOPo +syn keyword xsMacro cLISTOPx cLOGOP cLOGOPo cLOGOPx cLOOP cLOOPo cLOOPx +syn keyword xsMacro cMETHOPx cMETHOPx_meth cMETHOPx_rclass cPADOP cPADOPo +syn keyword xsMacro cPADOPx cPMOP cPMOPo cPMOPx cPVOP cPVOPo cPVOPx cSVOP +syn keyword xsMacro cSVOP_sv cSVOPo cSVOPo_sv cSVOPx cSVOPx_sv cSVOPx_svp +syn keyword xsMacro cUNOP cUNOP_AUX cUNOP_AUXo cUNOP_AUXx cUNOPo cUNOPx chdir +syn keyword xsMacro check_end_shift check_offset_max check_offset_min +syn keyword xsMacro check_substr check_utf8 child_offset_bits chmod chsize +syn keyword xsMacro ckDEAD ckWARN ckWARN2 ckWARN2_d ckWARN3 ckWARN3_d ckWARN4 +syn keyword xsMacro ckWARN4_d ckWARN_d close closedir connect cop_hints_2hv +syn keyword xsMacro cop_hints_fetch_pv cop_hints_fetch_pvn +syn keyword xsMacro cop_hints_fetch_pvs cop_hints_fetch_sv cophh_2hv +syn keyword xsMacro cophh_copy cophh_delete_pv cophh_delete_pvn +syn keyword xsMacro cophh_delete_pvs cophh_delete_sv cophh_fetch_pv +syn keyword xsMacro cophh_fetch_pvn cophh_fetch_pvs cophh_fetch_sv cophh_free +syn keyword xsMacro cophh_new_empty cophh_store_pv cophh_store_pvn +syn keyword xsMacro cophh_store_pvs cophh_store_sv crypt ctermid ctime +syn keyword xsMacro cv_ckproto cx_type cxstack cxstack_ix cxstack_max +syn keyword xsMacro dATARGET dAX dAXMARK dEXT dEXTCONST dITEMS dJMPENV dMARK +syn keyword xsMacro dMULTICALL dMY_CXT dMY_CXT_INTERP dMY_CXT_SV dNOOP +syn keyword xsMacro dORIGMARK dPOPPOPiirl dPOPPOPnnrl dPOPPOPssrl dPOPTOPiirl +syn keyword xsMacro dPOPTOPiirl_nomg dPOPTOPiirl_ul_nomg dPOPTOPnnrl +syn keyword xsMacro dPOPTOPnnrl_nomg dPOPTOPssrl dPOPXiirl dPOPXiirl_ul_nomg +syn keyword xsMacro dPOPXnnrl dPOPXssrl dPOPiv dPOPnv dPOPnv_nomg dPOPss +syn keyword xsMacro dPOPuv dSAVEDERRNO dSAVE_ERRNO dSP dSS_ADD dTARG dTARGET +syn keyword xsMacro dTARGETSTACKED dTHR dTHX dTHXa dTHXo dTHXoa dTHXs dTHXx +syn keyword xsMacro dTOPiv dTOPnv dTOPss dTOPuv dUNDERBAR dVAR dXSARGS +syn keyword xsMacro dXSBOOTARGSAPIVERCHK dXSBOOTARGSNOVERCHK +syn keyword xsMacro dXSBOOTARGSXSAPIVERCHK dXSFUNCTION dXSI32 dXSTARG +syn keyword xsMacro dXSUB_SYS deprecate djSP do_open dup dup2 endgrent +syn keyword xsMacro endhostent endnetent endprotoent endpwent endservent +syn keyword xsMacro environ execl execv execvp fcntl fd_set fdopen fileno +syn keyword xsMacro float_end_shift float_max_offset float_min_offset +syn keyword xsMacro float_substr float_utf8 flock flockfile foldEQ_utf8 +syn keyword xsMacro frewind fscanf fstat ftell ftruncate ftrylockfile +syn keyword xsMacro funlockfile fwrite1 get_cvs getc_unlocked getegid geteuid +syn keyword xsMacro getgid getgrent getgrgid getgrnam gethostbyaddr +syn keyword xsMacro gethostbyname gethostent gethostname getlogin +syn keyword xsMacro getnetbyaddr getnetbyname getnetent getpeername getpid +syn keyword xsMacro getprotobyname getprotobynumber getprotoent getpwent +syn keyword xsMacro getpwnam getpwuid getservbyname getservbyport getservent +syn keyword xsMacro getsockname getsockopt getspnam gettimeofday getuid getw +syn keyword xsMacro gv_AVadd gv_HVadd gv_IOadd gv_SVadd gv_autoload4 +syn keyword xsMacro gv_efullname3 gv_fetchmeth gv_fetchmeth_autoload +syn keyword xsMacro gv_fetchmethod gv_fetchmethod_flags gv_fetchpvn +syn keyword xsMacro gv_fetchpvs gv_fetchsv_nomg gv_fullname3 gv_init +syn keyword xsMacro gv_method_changed gv_stashpvs htoni htonl htons htovl +syn keyword xsMacro htovs hv_delete hv_delete_ent hv_deletehek hv_exists +syn keyword xsMacro hv_exists_ent hv_fetch hv_fetch_ent hv_fetchhek hv_fetchs +syn keyword xsMacro hv_iternext hv_magic hv_store hv_store_ent hv_store_flags +syn keyword xsMacro hv_storehek hv_stores hv_undef ibcmp ibcmp_locale +syn keyword xsMacro ibcmp_utf8 inet_addr inet_ntoa init_os_extras ioctl +syn keyword xsMacro isALNUM isALNUMC isALNUMC_A isALNUMC_L1 isALNUMC_LC +syn keyword xsMacro isALNUMC_LC_utf8 isALNUMC_LC_uvchr isALNUMC_uni +syn keyword xsMacro isALNUMC_utf8 isALNUMU isALNUM_LC isALNUM_LC_utf8 +syn keyword xsMacro isALNUM_LC_uvchr isALNUM_lazy_if isALNUM_uni isALNUM_utf8 +syn keyword xsMacro isALPHA isALPHANUMERIC isALPHANUMERIC_A isALPHANUMERIC_L1 +syn keyword xsMacro isALPHANUMERIC_LC isALPHANUMERIC_LC_utf8 +syn keyword xsMacro isALPHANUMERIC_LC_uvchr isALPHANUMERIC_uni +syn keyword xsMacro isALPHANUMERIC_utf8 isALPHAU isALPHA_A isALPHA_FOLD_EQ +syn keyword xsMacro isALPHA_FOLD_NE isALPHA_L1 isALPHA_LC isALPHA_LC_utf8 +syn keyword xsMacro isALPHA_LC_uvchr isALPHA_uni isALPHA_utf8 isASCII +syn keyword xsMacro isASCII_A isASCII_L1 isASCII_LC isASCII_LC_utf8 +syn keyword xsMacro isASCII_LC_uvchr isASCII_uni isASCII_utf8 isBLANK +syn keyword xsMacro isBLANK_A isBLANK_L1 isBLANK_LC isBLANK_LC_uni +syn keyword xsMacro isBLANK_LC_utf8 isBLANK_LC_uvchr isBLANK_uni isBLANK_utf8 +syn keyword xsMacro isCHARNAME_CONT isCNTRL isCNTRL_A isCNTRL_L1 isCNTRL_LC +syn keyword xsMacro isCNTRL_LC_utf8 isCNTRL_LC_uvchr isCNTRL_uni isCNTRL_utf8 +syn keyword xsMacro isDIGIT isDIGIT_A isDIGIT_L1 isDIGIT_LC isDIGIT_LC_utf8 +syn keyword xsMacro isDIGIT_LC_uvchr isDIGIT_uni isDIGIT_utf8 isGRAPH +syn keyword xsMacro isGRAPH_A isGRAPH_L1 isGRAPH_LC isGRAPH_LC_utf8 +syn keyword xsMacro isGRAPH_LC_uvchr isGRAPH_uni isGRAPH_utf8 isGV +syn keyword xsMacro isGV_with_GP isGV_with_GP_off isGV_with_GP_on isIDCONT +syn keyword xsMacro isIDCONT_A isIDCONT_L1 isIDCONT_LC isIDCONT_LC_utf8 +syn keyword xsMacro isIDCONT_LC_uvchr isIDCONT_uni isIDCONT_utf8 isIDFIRST +syn keyword xsMacro isIDFIRST_A isIDFIRST_L1 isIDFIRST_LC isIDFIRST_LC_utf8 +syn keyword xsMacro isIDFIRST_LC_uvchr isIDFIRST_lazy_if isIDFIRST_uni +syn keyword xsMacro isIDFIRST_utf8 isLEXWARN_off isLEXWARN_on isLOWER +syn keyword xsMacro isLOWER_A isLOWER_L1 isLOWER_LC isLOWER_LC_utf8 +syn keyword xsMacro isLOWER_LC_uvchr isLOWER_uni isLOWER_utf8 isOCTAL +syn keyword xsMacro isOCTAL_A isOCTAL_L1 isPRINT isPRINT_A isPRINT_L1 +syn keyword xsMacro isPRINT_LC isPRINT_LC_utf8 isPRINT_LC_uvchr isPRINT_uni +syn keyword xsMacro isPRINT_utf8 isPSXSPC isPSXSPC_A isPSXSPC_L1 isPSXSPC_LC +syn keyword xsMacro isPSXSPC_LC_utf8 isPSXSPC_LC_uvchr isPSXSPC_uni +syn keyword xsMacro isPSXSPC_utf8 isPUNCT isPUNCT_A isPUNCT_L1 isPUNCT_LC +syn keyword xsMacro isPUNCT_LC_utf8 isPUNCT_LC_uvchr isPUNCT_uni isPUNCT_utf8 +syn keyword xsMacro isREGEXP isSPACE isSPACE_A isSPACE_L1 isSPACE_LC +syn keyword xsMacro isSPACE_LC_utf8 isSPACE_LC_uvchr isSPACE_uni isSPACE_utf8 +syn keyword xsMacro isUPPER isUPPER_A isUPPER_L1 isUPPER_LC isUPPER_LC_utf8 +syn keyword xsMacro isUPPER_LC_uvchr isUPPER_uni isUPPER_utf8 isUTF8_CHAR +syn keyword xsMacro isVERTWS_uni isVERTWS_utf8 isWARN_ONCE isWARN_on +syn keyword xsMacro isWARNf_on isWORDCHAR isWORDCHAR_A isWORDCHAR_L1 +syn keyword xsMacro isWORDCHAR_LC isWORDCHAR_LC_utf8 isWORDCHAR_LC_uvchr +syn keyword xsMacro isWORDCHAR_lazy_if isWORDCHAR_uni isWORDCHAR_utf8 +syn keyword xsMacro isXDIGIT isXDIGIT_A isXDIGIT_L1 isXDIGIT_LC +syn keyword xsMacro isXDIGIT_LC_utf8 isXDIGIT_LC_uvchr isXDIGIT_uni +syn keyword xsMacro isXDIGIT_utf8 is_ANYOF_SYNTHETIC is_FOLDS_TO_MULTI_utf8 +syn keyword xsMacro is_HORIZWS_cp_high is_HORIZWS_high is_LAX_VERSION +syn keyword xsMacro is_LNBREAK_latin1_safe is_LNBREAK_safe +syn keyword xsMacro is_LNBREAK_utf8_safe is_MULTI_CHAR_FOLD_latin1_safe +syn keyword xsMacro is_MULTI_CHAR_FOLD_utf8_safe +syn keyword xsMacro is_MULTI_CHAR_FOLD_utf8_safe_part0 +syn keyword xsMacro is_MULTI_CHAR_FOLD_utf8_safe_part1 is_NONCHAR_utf8 +syn keyword xsMacro is_PATWS_cp is_PATWS_safe +syn keyword xsMacro is_PROBLEMATIC_LOCALE_FOLDEDS_START_cp +syn keyword xsMacro is_PROBLEMATIC_LOCALE_FOLDEDS_START_utf8 +syn keyword xsMacro is_PROBLEMATIC_LOCALE_FOLD_cp +syn keyword xsMacro is_PROBLEMATIC_LOCALE_FOLD_utf8 is_QUOTEMETA_high +syn keyword xsMacro is_QUOTEMETA_high_part0 is_QUOTEMETA_high_part1 +syn keyword xsMacro is_REPLACEMENT_utf8_safe is_STRICT_VERSION +syn keyword xsMacro is_SURROGATE_utf8 is_UTF8_CHAR_utf8_no_length_checks +syn keyword xsMacro is_VERTWS_cp_high is_VERTWS_high is_XDIGIT_cp_high +syn keyword xsMacro is_XDIGIT_high is_XPERLSPACE_cp_high is_XPERLSPACE_high +syn keyword xsMacro is_ascii_string is_utf8_char_buf is_utf8_string_loc +syn keyword xsMacro isatty isnormal kBINOP kCOP kGVOP_gv kLISTOP kLOGOP kLOOP +syn keyword xsMacro kPADOP kPMOP kPVOP kSVOP kSVOP_sv kUNOP kUNOP_AUX kill +syn keyword xsMacro killpg lex_stuff_pvs link listen lockf longjmp lseek +syn keyword xsMacro lstat mPUSHi mPUSHn mPUSHp mPUSHs mPUSHu mXPUSHi mXPUSHn +syn keyword xsMacro mXPUSHp mXPUSHs mXPUSHu memEQ memEQs memNE memNEs memchr +syn keyword xsMacro memcmp memzero mkdir mktemp my my_binmode my_lstat +syn keyword xsMacro my_setlocale my_snprintf my_sprintf my_stat my_strlcat +syn keyword xsMacro my_strlcpy my_vsnprintf newATTRSUB newAV newGVgen newHV +syn keyword xsMacro newIO newRV_inc newSUB newSVpadname newSVpvn_utf8 +syn keyword xsMacro newSVpvs newSVpvs_flags newSVpvs_share newXSproto ntohi +syn keyword xsMacro ntohl ntohs opASSIGN op_lvalue open opendir pTHX_1 +syn keyword xsMacro pTHX_12 pTHX_2 pTHX_3 pTHX_4 pTHX_5 pTHX_6 pTHX_7 pTHX_8 +syn keyword xsMacro pTHX_9 pTHX_FORMAT pTHX_VALUE pTHX_VALUE_ pTHX__FORMAT +syn keyword xsMacro pTHX__VALUE pTHX__VALUE_ pTHXo pTHXo_ pTHXx pTHXx_ pVAR +syn keyword xsMacro pWARN_ALL pWARN_NONE pWARN_STD packWARN packWARN2 +syn keyword xsMacro packWARN3 packWARN4 pad_add_name_pvs pad_findmy_pvs +syn keyword xsMacro pad_peg padadd_NO_DUP_CHECK padadd_OUR padadd_STALEOK +syn keyword xsMacro padadd_STATE padnew_CLONE padnew_SAVE padnew_SAVESUB +syn keyword xsMacro panic_write2 pause pclose pipe popen prepare_SV_for_RV +syn keyword xsMacro pthread_attr_init pthread_condattr_default pthread_create +syn keyword xsMacro pthread_key_create pthread_keycreate +syn keyword xsMacro pthread_mutexattr_default pthread_mutexattr_init +syn keyword xsMacro pthread_mutexattr_settype putc_unlocked putenv putw read +syn keyword xsMacro readdir readdir64 recv recvfrom ref +syn keyword xsMacro refcounted_he_fetch_pvs refcounted_he_new_pvs rename +syn keyword xsMacro rewinddir rmdir safecalloc safefree safemalloc +syn keyword xsMacro saferealloc save_aelem save_freeop save_freepv +syn keyword xsMacro save_freesv save_helem save_mortalizesv save_op savepvs +syn keyword xsMacro savesharedpvs sb_dstr sb_iters sb_m sb_maxiters +syn keyword xsMacro sb_oldsave sb_orig sb_rflags sb_rx sb_rxres sb_rxtainted +syn keyword xsMacro sb_s sb_strend sb_targ seedDrand01 seekdir select send +syn keyword xsMacro sendto set_ANYOF_SYNTHETIC setbuf setgid setgrent +syn keyword xsMacro sethostent setjmp setlinebuf setlocale setmode setnetent +syn keyword xsMacro setprotoent setpwent setregid setreuid setservent +syn keyword xsMacro setsockopt setuid setvbuf share_hek_hek sharepvn shutdown +syn keyword xsMacro signal sleep socket socketpair specialWARN stat stdoutf +syn keyword xsMacro strEQ strGE strGT strLE strLT strNE strchr strerror +syn keyword xsMacro strnEQ strnNE strrchr strtoll strtoull sv_2bool +syn keyword xsMacro sv_2bool_nomg sv_2iv sv_2nv sv_2pv sv_2pv_nolen +syn keyword xsMacro sv_2pv_nomg sv_2pvbyte_nolen sv_2pvutf8_nolen sv_2uv +syn keyword xsMacro sv_cathek sv_catpv_nomg sv_catpvn sv_catpvn_mg +syn keyword xsMacro sv_catpvn_nomg sv_catpvn_nomg_maybeutf8 +syn keyword xsMacro sv_catpvn_nomg_utf8_upgrade sv_catpvs sv_catpvs_flags +syn keyword xsMacro sv_catpvs_mg sv_catpvs_nomg sv_catsv sv_catsv_mg +syn keyword xsMacro sv_catsv_nomg sv_catxmlpvs sv_cmp sv_cmp_locale +syn keyword xsMacro sv_collxfrm sv_copypv_nomg sv_eq sv_force_normal +syn keyword xsMacro sv_insert sv_mortalcopy sv_nolocking sv_nounlocking +syn keyword xsMacro sv_or_pv_len_utf8 sv_pv sv_pvbyte sv_pvn_force +syn keyword xsMacro sv_pvn_force_nomg sv_pvutf8 sv_setgid sv_setpvs +syn keyword xsMacro sv_setpvs_mg sv_setref_pvs sv_setsv sv_setsv_nomg +syn keyword xsMacro sv_setuid sv_taint sv_unref sv_usepvn sv_usepvn_mg +syn keyword xsMacro sv_utf8_upgrade sv_utf8_upgrade_flags +syn keyword xsMacro sv_utf8_upgrade_nomg tTHX telldir times tmpfile tmpnam +syn keyword xsMacro toCTRL toFOLD toFOLD_A toFOLD_LC toFOLD_uni toFOLD_utf8 +syn keyword xsMacro toLOWER toLOWER_A toLOWER_L1 toLOWER_LATIN1 toLOWER_LC +syn keyword xsMacro toLOWER_uni toLOWER_utf8 toTITLE toTITLE_A toTITLE_uni +syn keyword xsMacro toTITLE_utf8 toUPPER toUPPER_A toUPPER_LATIN1_MOD +syn keyword xsMacro toUPPER_LC toUPPER_uni toUPPER_utf8 to_uni_fold +syn keyword xsMacro to_utf8_fold to_utf8_lower to_utf8_title to_utf8_upper +syn keyword xsMacro truncate tryAMAGICbin_MG tryAMAGICunDEREF +syn keyword xsMacro tryAMAGICunTARGETlist tryAMAGICun_MG ttyname umask uname +syn keyword xsMacro unlink unpackWARN1 unpackWARN2 unpackWARN3 unpackWARN4 +syn keyword xsMacro utf8_to_uvchr_buf utime uvchr_to_utf8 uvchr_to_utf8_flags +syn keyword xsMacro vTHX vfprintf vtohl vtohs wait want_vtbl_bm want_vtbl_fm +syn keyword xsMacro whichsig write xio_any xio_dirp xiv_iv xlv_targoff +syn keyword xsMacro xpv_len xuv_uv yystype + +" Define the default highlighting. +hi def link xsPrivate Error +hi def link xsSuperseded Error +hi def link xsType Type +hi def link xsString String +hi def link xsConstant Constant +hi def link xsException Exception +hi def link xsKeyword Keyword +hi def link xsFunction Function +hi def link xsVariable Identifier +hi def link xsMacro Macro + +let b:current_syntax = "xs" + +" vim: ts=8 + +endif if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'perl') == -1 " Vim syntax file diff --git a/syntax/xsd.vim b/syntax/xsd.vim new file mode 100644 index 0000000..9f89061 --- /dev/null +++ b/syntax/xsd.vim @@ -0,0 +1,65 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: XSD (XML Schema) +" Maintainer: Johannes Zellner +" Last Change: Tue, 27 Apr 2004 14:54:59 CEST +" Filenames: *.xsd +" $Id: xsd.vim,v 1.1 2004/06/13 18:20:48 vimboss Exp $ + +" REFERENCES: +" [1] http://www.w3.org/TR/xmlschema-0 +" + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +runtime syntax/xml.vim + +syn cluster xmlTagHook add=xsdElement +syn case match + +syn match xsdElement '\%(xsd:\)\@<=all' +syn match xsdElement '\%(xsd:\)\@<=annotation' +syn match xsdElement '\%(xsd:\)\@<=any' +syn match xsdElement '\%(xsd:\)\@<=anyAttribute' +syn match xsdElement '\%(xsd:\)\@<=appInfo' +syn match xsdElement '\%(xsd:\)\@<=attribute' +syn match xsdElement '\%(xsd:\)\@<=attributeGroup' +syn match xsdElement '\%(xsd:\)\@<=choice' +syn match xsdElement '\%(xsd:\)\@<=complexContent' +syn match xsdElement '\%(xsd:\)\@<=complexType' +syn match xsdElement '\%(xsd:\)\@<=documentation' +syn match xsdElement '\%(xsd:\)\@<=element' +syn match xsdElement '\%(xsd:\)\@<=enumeration' +syn match xsdElement '\%(xsd:\)\@<=extension' +syn match xsdElement '\%(xsd:\)\@<=field' +syn match xsdElement '\%(xsd:\)\@<=group' +syn match xsdElement '\%(xsd:\)\@<=import' +syn match xsdElement '\%(xsd:\)\@<=include' +syn match xsdElement '\%(xsd:\)\@<=key' +syn match xsdElement '\%(xsd:\)\@<=keyref' +syn match xsdElement '\%(xsd:\)\@<=length' +syn match xsdElement '\%(xsd:\)\@<=list' +syn match xsdElement '\%(xsd:\)\@<=maxInclusive' +syn match xsdElement '\%(xsd:\)\@<=maxLength' +syn match xsdElement '\%(xsd:\)\@<=minInclusive' +syn match xsdElement '\%(xsd:\)\@<=minLength' +syn match xsdElement '\%(xsd:\)\@<=pattern' +syn match xsdElement '\%(xsd:\)\@<=redefine' +syn match xsdElement '\%(xsd:\)\@<=restriction' +syn match xsdElement '\%(xsd:\)\@<=schema' +syn match xsdElement '\%(xsd:\)\@<=selector' +syn match xsdElement '\%(xsd:\)\@<=sequence' +syn match xsdElement '\%(xsd:\)\@<=simpleContent' +syn match xsdElement '\%(xsd:\)\@<=simpleType' +syn match xsdElement '\%(xsd:\)\@<=union' +syn match xsdElement '\%(xsd:\)\@<=unique' + +hi def link xsdElement Statement + +" vim: ts=8 + +endif diff --git a/syntax/xslt.vim b/syntax/xslt.vim new file mode 100644 index 0000000..15020f4 --- /dev/null +++ b/syntax/xslt.vim @@ -0,0 +1,66 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: XSLT +" Maintainer: Johannes Zellner +" Last Change: Sun, 28 Oct 2001 21:22:24 +0100 +" Filenames: *.xsl +" $Id: xslt.vim,v 1.1 2004/06/13 15:52:10 vimboss Exp $ + +" REFERENCES: +" [1] http://www.w3.org/TR/xslt +" + +" Quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +runtime syntax/xml.vim + +syn cluster xmlTagHook add=xslElement +syn case match + +syn match xslElement '\%(xsl:\)\@<=apply-imports' +syn match xslElement '\%(xsl:\)\@<=apply-templates' +syn match xslElement '\%(xsl:\)\@<=attribute' +syn match xslElement '\%(xsl:\)\@<=attribute-set' +syn match xslElement '\%(xsl:\)\@<=call-template' +syn match xslElement '\%(xsl:\)\@<=choose' +syn match xslElement '\%(xsl:\)\@<=comment' +syn match xslElement '\%(xsl:\)\@<=copy' +syn match xslElement '\%(xsl:\)\@<=copy-of' +syn match xslElement '\%(xsl:\)\@<=decimal-format' +syn match xslElement '\%(xsl:\)\@<=document' +syn match xslElement '\%(xsl:\)\@<=element' +syn match xslElement '\%(xsl:\)\@<=fallback' +syn match xslElement '\%(xsl:\)\@<=for-each' +syn match xslElement '\%(xsl:\)\@<=if' +syn match xslElement '\%(xsl:\)\@<=include' +syn match xslElement '\%(xsl:\)\@<=import' +syn match xslElement '\%(xsl:\)\@<=key' +syn match xslElement '\%(xsl:\)\@<=message' +syn match xslElement '\%(xsl:\)\@<=namespace-alias' +syn match xslElement '\%(xsl:\)\@<=number' +syn match xslElement '\%(xsl:\)\@<=otherwise' +syn match xslElement '\%(xsl:\)\@<=output' +syn match xslElement '\%(xsl:\)\@<=param' +syn match xslElement '\%(xsl:\)\@<=processing-instruction' +syn match xslElement '\%(xsl:\)\@<=preserve-space' +syn match xslElement '\%(xsl:\)\@<=script' +syn match xslElement '\%(xsl:\)\@<=sort' +syn match xslElement '\%(xsl:\)\@<=strip-space' +syn match xslElement '\%(xsl:\)\@<=stylesheet' +syn match xslElement '\%(xsl:\)\@<=template' +syn match xslElement '\%(xsl:\)\@<=transform' +syn match xslElement '\%(xsl:\)\@<=text' +syn match xslElement '\%(xsl:\)\@<=value-of' +syn match xslElement '\%(xsl:\)\@<=variable' +syn match xslElement '\%(xsl:\)\@<=when' +syn match xslElement '\%(xsl:\)\@<=with-param' + +hi def link xslElement Statement + +" vim: ts=8 + +endif diff --git a/syntax/xxd.vim b/syntax/xxd.vim new file mode 100644 index 0000000..453f5fd --- /dev/null +++ b/syntax/xxd.vim @@ -0,0 +1,34 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: bin using xxd +" Maintainer: Charles E. Campbell +" Last Change: Aug 31, 2016 +" Version: 10 +" Notes: use :help xxd to see how to invoke it +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_XXD + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn match xxdAddress "^[0-9a-f]\+:" contains=xxdSep +syn match xxdSep contained ":" +syn match xxdAscii " .\{,16\}\r\=$"hs=s+2 contains=xxdDot +syn match xxdDot contained "[.\r]" + +" Define the default highlighting. +if !exists("skip_xxd_syntax_inits") + + hi def link xxdAddress Constant + hi def link xxdSep Identifier + hi def link xxdAscii Statement + +endif + +let b:current_syntax = "xxd" + +" vim: ts=4 + +endif diff --git a/syntax/yacc.vim b/syntax/yacc.vim new file mode 100644 index 0000000..052995d --- /dev/null +++ b/syntax/yacc.vim @@ -0,0 +1,123 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Yacc +" Maintainer: Charles E. Campbell +" Last Change: Aug 31, 2016 +" Version: 15 +" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_YACC +" +" Options: {{{1 +" g:yacc_uses_cpp : if this variable exists, then C++ is loaded rather than C + +" --------------------------------------------------------------------- +" this version of syntax/yacc.vim requires 6.0 or later +if exists("b:current_syntax") + syntax clear +endif + +" --------------------------------------------------------------------- +" Folding Support {{{1 +if has("folding") + com! -nargs=+ SynFold fold +else + com! -nargs=+ SynFold +endif + +" --------------------------------------------------------------------- +" Read the C syntax to start with {{{1 +" Read the C/C++ syntax to start with +let s:Cpath= fnameescape(expand(":p:h").(exists("g:yacc_uses_cpp")? "/cpp.vim" : "/c.vim")) +if !filereadable(s:Cpath) + for s:Cpath in split(globpath(&rtp,(exists("g:yacc_uses_cpp")? "syntax/cpp.vim" : "syntax/c.vim")),"\n") + if filereadable(fnameescape(s:Cpath)) + let s:Cpath= fnameescape(s:Cpath) + break + endif + endfor +endif +exe "syn include @yaccCode ".s:Cpath + +" --------------------------------------------------------------------- +" Yacc Clusters: {{{1 +syn cluster yaccInitCluster contains=yaccKey,yaccKeyActn,yaccBrkt,yaccType,yaccString,yaccUnionStart,yaccHeader2,yaccComment,yaccDefines,yaccParseParam,yaccParseOption +syn cluster yaccRulesCluster contains=yaccNonterminal,yaccString,yaccComment + +" --------------------------------------------------------------------- +" Yacc Sections: {{{1 +SynFold syn region yaccInit start='.'ms=s-1,rs=s-1 matchgroup=yaccSectionSep end='^%%$'me=e-2,re=e-2 contains=@yaccInitCluster nextgroup=yaccRules skipwhite skipempty contained +SynFold syn region yaccInit2 start='\%^.'ms=s-1,rs=s-1 matchgroup=yaccSectionSep end='^%%$'me=e-2,re=e-2 contains=@yaccInitCluster nextgroup=yaccRules skipwhite skipempty +SynFold syn region yaccHeader2 matchgroup=yaccSep start="^\s*\zs%{" end="^\s*%}" contains=@yaccCode nextgroup=yaccInit skipwhite skipempty contained +SynFold syn region yaccHeader matchgroup=yaccSep start="^\s*\zs%{" end="^\s*%}" contains=@yaccCode nextgroup=yaccInit skipwhite skipempty +SynFold syn region yaccRules matchgroup=yaccSectionSep start='^%%$' end='^%%$'me=e-2,re=e-2 contains=@yaccRulesCluster nextgroup=yaccEndCode skipwhite skipempty contained +SynFold syn region yaccEndCode matchgroup=yaccSectionSep start='^%%$' end='\%$' contains=@yaccCode contained + +" --------------------------------------------------------------------- +" Yacc Commands: {{{1 +syn match yaccDefines '^%define\s\+.*$' +syn match yaccParseParam '%\(parse\|lex\)-param\>' skipwhite nextgroup=yaccParseParamStr +syn match yaccParseOption '%\%(api\.pure\|pure-parser\|locations\|error-verbose\)\>' +syn region yaccParseParamStr contained matchgroup=Delimiter start='{' end='}' contains=cStructure + +syn match yaccDelim "[:|]" contained +syn match yaccOper "@\d\+" contained + +syn match yaccKey "^\s*%\(token\|type\|left\|right\|start\|ident\|nonassoc\)\>" contained +syn match yaccKey "\s%\(prec\|expect\)\>" contained +syn match yaccKey "\$\(<[a-zA-Z_][a-zA-Z_0-9]*>\)\=[\$0-9]\+" contained +syn keyword yaccKeyActn yyerrok yyclearin contained + +syn match yaccUnionStart "^%union" skipwhite skipnl nextgroup=yaccUnion contained +SynFold syn region yaccUnion matchgroup=yaccCurly start="{" matchgroup=yaccCurly end="}" contains=@yaccCode contained +syn match yaccBrkt "[<>]" contained +syn match yaccType "<[a-zA-Z_][a-zA-Z0-9_]*>" contains=yaccBrkt contained + +SynFold syn region yaccNonterminal start="^\s*\a\w*\ze\_s*\(/\*\_.\{-}\*/\)\=\_s*:" matchgroup=yaccDelim end=";" matchgroup=yaccSectionSep end='^%%$'me=e-2,re=e-2 contains=yaccAction,yaccDelim,yaccString,yaccComment contained +syn region yaccComment start="/\*" end="\*/" +syn match yaccString "'[^']*'" contained + + +" --------------------------------------------------------------------- +" I'd really like to highlight just the outer {}. Any suggestions??? {{{1 +syn match yaccCurlyError "[{}]" +SynFold syn region yaccAction matchgroup=yaccCurly start="{" end="}" contains=@yaccCode,yaccVar contained +syn match yaccVar '\$\d\+\|\$\$\|\$<\I\i*>\$\|\$<\I\i*>\d\+' containedin=cParen,cPreProc,cMulti contained + +" --------------------------------------------------------------------- +" Yacc synchronization: {{{1 +syn sync fromstart + +" --------------------------------------------------------------------- +" Define the default highlighting. {{{1 +if !exists("skip_yacc_syn_inits") + hi def link yaccBrkt yaccStmt + hi def link yaccComment Comment + hi def link yaccCurly Delimiter + hi def link yaccCurlyError Error + hi def link yaccDefines cDefine + hi def link yaccDelim Delimiter + hi def link yaccKeyActn Special + hi def link yaccKey yaccStmt + hi def link yaccNonterminal Function + hi def link yaccOper yaccStmt + hi def link yaccParseOption cDefine + hi def link yaccParseParam yaccParseOption + hi def link yaccSectionSep Todo + hi def link yaccSep Delimiter + hi def link yaccStmt Statement + hi def link yaccString String + hi def link yaccType Type + hi def link yaccUnionStart yaccKey + hi def link yaccVar Special +endif + +" --------------------------------------------------------------------- +" Cleanup: {{{1 +delcommand SynFold +let b:current_syntax = "yacc" + +" --------------------------------------------------------------------- +" Modelines: {{{1 +" vim: ts=15 fdm=marker + +endif diff --git a/syntax/yaml.vim b/syntax/yaml.vim new file mode 100644 index 0000000..febd514 --- /dev/null +++ b/syntax/yaml.vim @@ -0,0 +1,247 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: YAML (YAML Ain't Markup Language) 1.2 +" Maintainer: Nikolai Pavlov +" First author: Nikolai Weibull +" Latest Revision: 2015-03-28 + +if exists('b:current_syntax') + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +" Choose the schema to use +" TODO: Validate schema +if !exists('b:yaml_schema') + if exists('g:yaml_schema') + let b:yaml_schema = g:yaml_schema + else + let b:yaml_schema = 'core' + endif +endif + +let s:ns_char = '\%([\n\r\uFEFF \t]\@!\p\)' +let s:ns_word_char = '[[:alnum:]_\-]' +let s:ns_uri_char = '\%(%\x\x\|'.s:ns_word_char.'\|[#/;?:@&=+$,.!~*''()[\]]\)' +let s:ns_tag_char = '\%(%\x\x\|'.s:ns_word_char.'\|[#/;?:@&=+$.~*''()]\)' +let s:c_ns_anchor_char = '\%([\n\r\uFEFF \t,[\]{}]\@!\p\)' +let s:c_indicator = '[\-?:,[\]{}#&*!|>''"%@`]' +let s:c_flow_indicator = '[,[\]{}]' + +let s:ns_char_without_c_indicator = substitute(s:ns_char, '\v\C[\zs', '\=s:c_indicator[1:-2]', '') + +let s:_collection = '[^\@!\(\%(\\\.\|\[^\\\]]\)\+\)]' +let s:_neg_collection = '[^\(\%(\\\.\|\[^\\\]]\)\+\)]' +function s:SimplifyToAssumeAllPrintable(p) + return substitute(a:p, '\V\C\\%('.s:_collection.'\\@!\\p\\)', '[^\1]', '') +endfunction +let s:ns_char = s:SimplifyToAssumeAllPrintable(s:ns_char) +let s:ns_char_without_c_indicator = s:SimplifyToAssumeAllPrintable(s:ns_char_without_c_indicator) +let s:c_ns_anchor_char = s:SimplifyToAssumeAllPrintable(s:c_ns_anchor_char) + +function s:SimplifyAdjacentCollections(p) + return substitute(a:p, '\V\C'.s:_collection.'\\|'.s:_collection, '[\1\2]', 'g') +endfunction +let s:ns_uri_char = s:SimplifyAdjacentCollections(s:ns_uri_char) +let s:ns_tag_char = s:SimplifyAdjacentCollections(s:ns_tag_char) + +let s:c_verbatim_tag = '!<'.s:ns_uri_char.'\+>' +let s:c_named_tag_handle = '!'.s:ns_word_char.'\+!' +let s:c_secondary_tag_handle = '!!' +let s:c_primary_tag_handle = '!' +let s:c_tag_handle = '\%('.s:c_named_tag_handle. + \ '\|'.s:c_secondary_tag_handle. + \ '\|'.s:c_primary_tag_handle.'\)' +let s:c_ns_shorthand_tag = s:c_tag_handle . s:ns_tag_char.'\+' +let s:c_non_specific_tag = '!' +let s:c_ns_tag_property = s:c_verbatim_tag. + \ '\|'.s:c_ns_shorthand_tag. + \ '\|'.s:c_non_specific_tag + +let s:c_ns_anchor_name = s:c_ns_anchor_char.'\+' +let s:c_ns_anchor_property = '&'.s:c_ns_anchor_name +let s:c_ns_alias_node = '\*'.s:c_ns_anchor_name + +let s:ns_directive_name = s:ns_char.'\+' + +let s:ns_local_tag_prefix = '!'.s:ns_uri_char.'*' +let s:ns_global_tag_prefix = s:ns_tag_char.s:ns_uri_char.'*' +let s:ns_tag_prefix = s:ns_local_tag_prefix. + \ '\|'.s:ns_global_tag_prefix + +let s:ns_plain_safe_out = s:ns_char +let s:ns_plain_safe_in = '\%('.s:c_flow_indicator.'\@!'.s:ns_char.'\)' + +let s:ns_plain_safe_in = substitute(s:ns_plain_safe_in, '\V\C\\%('.s:_collection.'\\@!'.s:_neg_collection.'\\)', '[^\1\2]', '') +let s:ns_plain_safe_in_without_colhash = substitute(s:ns_plain_safe_in, '\V\C'.s:_neg_collection, '[^\1:#]', '') +let s:ns_plain_safe_out_without_colhash = substitute(s:ns_plain_safe_out, '\V\C'.s:_neg_collection, '[^\1:#]', '') + +let s:ns_plain_first_in = '\%('.s:ns_char_without_c_indicator.'\|[?:\-]\%('.s:ns_plain_safe_in.'\)\@=\)' +let s:ns_plain_first_out = '\%('.s:ns_char_without_c_indicator.'\|[?:\-]\%('.s:ns_plain_safe_out.'\)\@=\)' + +let s:ns_plain_char_in = '\%('.s:ns_char.'#\|:'.s:ns_plain_safe_in.'\|'.s:ns_plain_safe_in_without_colhash.'\)' +let s:ns_plain_char_out = '\%('.s:ns_char.'#\|:'.s:ns_plain_safe_out.'\|'.s:ns_plain_safe_out_without_colhash.'\)' + +let s:ns_plain_out = s:ns_plain_first_out . s:ns_plain_char_out.'*' +let s:ns_plain_in = s:ns_plain_first_in . s:ns_plain_char_in.'*' + + +syn keyword yamlTodo contained TODO FIXME XXX NOTE + +syn region yamlComment display oneline start='\%\(^\|\s\)#' end='$' + \ contains=yamlTodo + +execute 'syn region yamlDirective oneline start='.string('^\ze%'.s:ns_directive_name.'\s\+').' '. + \ 'end="$" '. + \ 'contains=yamlTAGDirective,'. + \ 'yamlYAMLDirective,'. + \ 'yamlReservedDirective '. + \ 'keepend' + +syn match yamlTAGDirective '%TAG\s\+' contained nextgroup=yamlTagHandle +execute 'syn match yamlTagHandle contained nextgroup=yamlTagPrefix '.string(s:c_tag_handle.'\s\+') +execute 'syn match yamlTagPrefix contained nextgroup=yamlComment ' . string(s:ns_tag_prefix) + +syn match yamlYAMLDirective '%YAML\s\+' contained nextgroup=yamlYAMLVersion +syn match yamlYAMLVersion '\d\+\.\d\+' contained nextgroup=yamlComment + +execute 'syn match yamlReservedDirective contained nextgroup=yamlComment '. + \string('%\%(\%(TAG\|YAML\)\s\)\@!'.s:ns_directive_name) + +syn region yamlFlowString matchgroup=yamlFlowStringDelimiter start='"' skip='\\"' end='"' + \ contains=yamlEscape + \ nextgroup=yamlKeyValueDelimiter +syn region yamlFlowString matchgroup=yamlFlowStringDelimiter start="'" skip="''" end="'" + \ contains=yamlSingleEscape + \ nextgroup=yamlKeyValueDelimiter +syn match yamlEscape contained '\\\%([\\"abefnrtv\^0_ NLP\n]\|x\x\x\|u\x\{4}\|U\x\{8}\)' +syn match yamlSingleEscape contained "''" + +syn match yamlBlockScalarHeader contained '\s\+\zs[|>]\%([+-]\=[1-9]\|[1-9]\=[+-]\)\=' + +syn cluster yamlConstant contains=yamlBool,yamlNull + +syn cluster yamlFlow contains=yamlFlowString,yamlFlowMapping,yamlFlowCollection +syn cluster yamlFlow add=yamlFlowMappingKey,yamlFlowMappingMerge +syn cluster yamlFlow add=@yamlConstant,yamlPlainScalar,yamlFloat +syn cluster yamlFlow add=yamlTimestamp,yamlInteger,yamlMappingKeyStart +syn cluster yamlFlow add=yamlComment +syn region yamlFlowMapping matchgroup=yamlFlowIndicator start='{' end='}' contains=@yamlFlow +syn region yamlFlowCollection matchgroup=yamlFlowIndicator start='\[' end='\]' contains=@yamlFlow + +execute 'syn match yamlPlainScalar /'.s:ns_plain_out.'/' +execute 'syn match yamlPlainScalar contained /'.s:ns_plain_in.'/' + +syn match yamlMappingKeyStart '?\ze\s' +syn match yamlMappingKeyStart '?' contained + +execute 'syn match yamlFlowMappingKey /\%#=1'.s:ns_plain_in.'\%(\s\+'.s:ns_plain_in.'\)*\ze\s*:/ contained '. + \'nextgroup=yamlKeyValueDelimiter' +syn match yamlFlowMappingMerge /<<\ze\s*:/ contained nextgroup=yamlKeyValueDelimiter + +syn match yamlBlockCollectionItemStart '^\s*\zs-\%(\s\+-\)*\s' nextgroup=yamlBlockMappingKey,yamlBlockMappingMerge +" Use the old regexp engine, the NFA engine doesn't like all the \@ items. +execute 'syn match yamlBlockMappingKey /\%#=1^\s*\zs'.s:ns_plain_out.'\%(\s\+'.s:ns_plain_out.'\)*\ze\s*:\%(\s\|$\)/ '. + \'nextgroup=yamlKeyValueDelimiter' +execute 'syn match yamlBlockMappingKey /\%#=1\s*\zs'.s:ns_plain_out.'\%(\s\+'.s:ns_plain_out.'\)*\ze\s*:\%(\s\|$\)/ contained '. + \'nextgroup=yamlKeyValueDelimiter' +syn match yamlBlockMappingMerge /^\s*\zs<<\ze:\%(\s\|$\)/ nextgroup=yamlKeyValueDelimiter +syn match yamlBlockMappingMerge /<<\ze\s*:\%(\s\|$\)/ nextgroup=yamlKeyValueDelimiter contained + +syn match yamlKeyValueDelimiter /\s*:/ contained +syn match yamlKeyValueDelimiter /\s*:/ contained + +syn cluster yamlScalarWithSpecials contains=yamlPlainScalar,yamlBlockMappingKey,yamlFlowMappingKey + +let s:_bounder = s:SimplifyToAssumeAllPrintable('\%([[\]{}, \t]\@!\p\)') +if b:yaml_schema is# 'json' + syn keyword yamlNull null contained containedin=@yamlScalarWithSpecials + syn keyword yamlBool true false + exe 'syn match yamlInteger /'.s:_bounder.'\@1 +" Last Change: 2003 May 11 + +" quit when a syntax file was already loaded +if exists("b:current_syntax") + finish +endif + +syn case ignore + +" Common Z80 Assembly instructions +syn keyword z8aInstruction adc add and bit ccf cp cpd cpdr cpi cpir cpl +syn keyword z8aInstruction daa di djnz ei exx halt im in +syn keyword z8aInstruction ind ini indr inir jp jr ld ldd lddr ldi ldir +syn keyword z8aInstruction neg nop or otdr otir out outd outi +syn keyword z8aInstruction res rl rla rlc rlca rld +syn keyword z8aInstruction rr rra rrc rrca rrd sbc scf set sla sra +syn keyword z8aInstruction srl sub xor +" syn keyword z8aInstruction push pop call ret reti retn inc dec ex rst + +" Any other stuff +syn match z8aIdentifier "[a-z_][a-z0-9_]*" + +" Instructions changing stack +syn keyword z8aSpecInst push pop call ret reti retn rst +syn match z8aInstruction "\" +syn match z8aInstruction "\" +syn match z8aInstruction "\" +syn match z8aSpecInst "\"me=s+3 +syn match z8aSpecInst "\"me=s+3 +syn match z8aSpecInst "\"me=s+2 + +"Labels +syn match z8aLabel "[a-z_][a-z0-9_]*:" +syn match z8aSpecialLabel "[a-z_][a-z0-9_]*::" + +" PreProcessor commands +syn match z8aPreProc "\.org" +syn match z8aPreProc "\.globl" +syn match z8aPreProc "\.db" +syn match z8aPreProc "\.dw" +syn match z8aPreProc "\.ds" +syn match z8aPreProc "\.byte" +syn match z8aPreProc "\.word" +syn match z8aPreProc "\.blkb" +syn match z8aPreProc "\.blkw" +syn match z8aPreProc "\.ascii" +syn match z8aPreProc "\.asciz" +syn match z8aPreProc "\.module" +syn match z8aPreProc "\.title" +syn match z8aPreProc "\.sbttl" +syn match z8aPreProc "\.even" +syn match z8aPreProc "\.odd" +syn match z8aPreProc "\.area" +syn match z8aPreProc "\.page" +syn match z8aPreProc "\.setdp" +syn match z8aPreProc "\.radix" +syn match z8aInclude "\.include" +syn match z8aPreCondit "\.if" +syn match z8aPreCondit "\.else" +syn match z8aPreCondit "\.endif" + +" Common strings +syn match z8aString "\".*\"" +syn match z8aString "\'.*\'" + +" Numbers +syn match z8aNumber "[0-9]\+" +syn match z8aNumber "0[xXhH][0-9a-fA-F]\+" +syn match z8aNumber "0[bB][0-1]*" +syn match z8aNumber "0[oO\@qQ][0-7]\+" +syn match z8aNumber "0[dD][0-9]\+" + +" Character constant +syn match z8aString "\#\'."hs=s+1 + +" Comments +syn match z8aComment ";.*" + +syn case match + +" Define the default highlighting. +" Only when an item doesn't have highlighting yet + +hi def link z8aSection Special +hi def link z8aLabel Label +hi def link z8aSpecialLabel Label +hi def link z8aComment Comment +hi def link z8aInstruction Statement +hi def link z8aSpecInst Statement +hi def link z8aInclude Include +hi def link z8aPreCondit PreCondit +hi def link z8aPreProc PreProc +hi def link z8aNumber Number +hi def link z8aString String + + +let b:current_syntax = "z8a" +" vim: ts=8 + +endif diff --git a/syntax/zimbu.vim b/syntax/zimbu.vim new file mode 100644 index 0000000..47778a7 --- /dev/null +++ b/syntax/zimbu.vim @@ -0,0 +1,164 @@ +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vim') == -1 + +" Vim syntax file +" Language: Zimbu +" Maintainer: Bram Moolenaar +" Last Change: 2014 Nov 23 + +if exists("b:current_syntax") + finish +endif + +syn include @Ccode syntax/c.vim + +syn keyword zimbuTodo TODO FIXME XXX contained +syn match zimbuNoBar "|" contained +syn match zimbuParam "|[^| ]\+|" contained contains=zimbuNoBar +syn match zimbuNoBacktick "`" contained +syn match zimbuCode "`[^`]\+`" contained contains=zimbuNoBacktick +syn match zimbuComment "#.*$" contains=zimbuTodo,zimbuParam,zimbuCode,@Spell +syn match zimbuComment "/\*.\{-}\*/" contains=zimbuTodo,zimbuParam,zimbuCode,@Spell + +syn match zimbuChar "'\\\=.'" + +syn keyword zimbuBasicType bool status +syn keyword zimbuBasicType int1 int2 int3 int4 int5 int6 int7 +syn keyword zimbuBasicType int9 int10 int11 int12 int13 int14 int15 +syn keyword zimbuBasicType int int8 int16 int32 int64 bigInt +syn keyword zimbuBasicType nat nat8 byte nat16 nat32 nat64 bigNat +syn keyword zimbuBasicType nat1 nat2 nat3 nat4 nat5 nat6 nat7 +syn keyword zimbuBasicType nat9 nat10 nat11 nat12 nat13 nat14 nat15 +syn keyword zimbuBasicType float float32 float64 float80 float128 +syn keyword zimbuBasicType fixed1 fixed2 fixed3 fixed4 fixed5 fixed6 +syn keyword zimbuBasicType fixed7 fixed8 fixed9 fixed10 fixed11 fixed12 +syn keyword zimbuBasicType fixed13 fixed14 fixed15 + +syn keyword zimbuCompType string varString +syn keyword zimbuCompType byteString varByteString +syn keyword zimbuCompType tuple array list dict dictList set callback +syn keyword zimbuCompType sortedList multiDict multiDictList multiSet +syn keyword zimbuCompType complex complex32 complex64 complex80 complex128 +syn keyword zimbuCompType proc func def thread evalThread lock cond pipe + +syn keyword zimbuType VAR dyn type USE GET +syn match zimbuType "IO.File" +syn match zimbuType "IO.Stat" + +syn keyword zimbuStatement IF ELSE ELSEIF IFNIL WHILE REPEAT FOR IN TO STEP +syn keyword zimbuStatement DO UNTIL SWITCH WITH +syn keyword zimbuStatement TRY CATCH FINALLY +syn keyword zimbuStatement GENERATE_IF GENERATE_ELSE GENERATE_ELSEIF +syn keyword zimbuStatement GENERATE_ERROR +syn keyword zimbuStatement BUILD_IF BUILD_ELSE BUILD_ELSEIF +syn keyword zimbuStatement CASE DEFAULT FINAL ABSTRACT VIRTUAL DEFINE REPLACE +syn keyword zimbuStatement IMPLEMENTS EXTENDS PARENT LOCAL +syn keyword zimbuStatement PART ALIAS TYPE CONNECT WRAP +syn keyword zimbuStatement BREAK CONTINUE PROCEED +syn keyword zimbuStatement RETURN EXIT THROW DEFER +syn keyword zimbuStatement IMPORT AS OPTIONS MAIN +syn keyword zimbuStatement INTERFACE PIECE INCLUDE MODULE ENUM BITS +syn keyword zimbuStatement SHARED STATIC +syn keyword zimbuStatement LAMBDA +syn match zimbuStatement "\<\(FUNC\|PROC\|DEF\)\>" +syn match zimbuStatement "\" +syn match zimbuStatement "}" + +syn match zimbuAttribute "@backtrace=no\>" +syn match zimbuAttribute "@backtrace=yes\>" +syn match zimbuAttribute "@abstract\>" +syn match zimbuAttribute "@earlyInit\>" +syn match zimbuAttribute "@default\>" +syn match zimbuAttribute "@define\>" +syn match zimbuAttribute "@replace\>" +syn match zimbuAttribute "@final\>" +syn match zimbuAttribute "@primitive\>" +syn match zimbuAttribute "@notOnExit\>" + +syn match zimbuAttribute "@private\>" +syn match zimbuAttribute "@protected\>" +syn match zimbuAttribute "@public\>" +syn match zimbuAttribute "@local\>" +syn match zimbuAttribute "@file\>" +syn match zimbuAttribute "@directory\>" +syn match zimbuAttribute "@read=private\>" +syn match zimbuAttribute "@read=protected\>" +syn match zimbuAttribute "@read=public\>" +syn match zimbuAttribute "@read=file\>" +syn match zimbuAttribute "@read=directory\>" +syn match zimbuAttribute "@items=private\>" +syn match zimbuAttribute "@items=protected\>" +syn match zimbuAttribute "@items=public\>" +syn match zimbuAttribute "@items=file\>" +syn match zimbuAttribute "@items=directory\>" + +syn keyword zimbuMethod NEW EQUAL COPY COMPARE SIZE GET SET INIT EARLYINIT + +syn keyword zimbuOperator IS ISNOT ISA ISNOTA + +syn keyword zimbuModule ARG CHECK E GC IO LOG PROTO SYS HTTP ZC ZWT T TIME THREAD + +syn match zimbuImport "\.\zsPROTO" +syn match zimbuImport "\.\zsCHEADER" + +"syn match zimbuString +"\([^"\\]\|\\.\)*\("\|$\)+ contains=zimbuStringExpr +syn region zimbuString start=+"+ skip=+[^"\\]\|\\.+ end=+"\|$+ contains=zimbuStringExpr +syn match zimbuString +R"\([^"]\|""\)*\("\|$\)+ +syn region zimbuLongString start=+''"+ end=+"''+ +syn match zimbuStringExpr +\\([^)]*)+hs=s+2,he=e-1 contained contains=zimbuString,zimbuParenPairOuter +syn region zimbuParenPairOuter start=+(+ms=s+1 end=+)+me=e-1 contained contains=zimbuString,zimbuParenPair +syn region zimbuParenPair start=+(+ end=+)+ contained contains=zimbuString,zimbuParenPair + +syn keyword zimbuFixed TRUE FALSE NIL THIS THISTYPE FAIL OK +syn keyword zimbuError NULL + +" trailing whitespace +syn match zimbuSpaceError display excludenl "\S\s\+$"ms=s+1 +" mixed tabs and spaces +syn match zimbuSpaceError display " \+\t" +syn match zimbuSpaceError display "\t\+ " + +syn match zimbuUses contained "\ +" Previous Maintainer: Nikolai Weibull +" Latest Revision: 2017-07-11 +" License: Vim (see :h license) +" Repository: https://github.com/chrisbra/vim-zsh + +if exists("b:current_syntax") + finish +endif + +let s:cpo_save = &cpo +set cpo&vim + +if v:version > 704 || (v:version == 704 && has("patch1142")) + syn iskeyword @,48-57,_,192-255,#,- +else + setlocal iskeyword+=- +endif +if get(g:, 'zsh_fold_enable', 0) + setlocal foldmethod=syntax +endif + +syn keyword zshTodo contained TODO FIXME XXX NOTE + +syn region zshComment oneline start='\%(^\|\s\+\)#' end='$' + \ contains=zshTodo,@Spell fold + +syn region zshComment start='^\s*#' end='^\%(\s*#\)\@!' + \ contains=zshTodo,@Spell fold + +syn match zshPreProc '^\%1l#\%(!\|compdef\|autoload\).*$' + +syn match zshQuoted '\\.' +syn region zshString matchgroup=zshStringDelimiter start=+"+ end=+"+ + \ contains=zshQuoted,@zshDerefs,@zshSubst fold +syn region zshString matchgroup=zshStringDelimiter start=+'+ end=+'+ fold +" XXX: This should probably be more precise, but Zsh seems a bit confused about it itself +syn region zshPOSIXString matchgroup=zshStringDelimiter start=+\$'+ + \ end=+'+ contains=zshQuoted +syn match zshJobSpec '%\(\d\+\|?\=\w\+\|[%+-]\)' + +syn keyword zshPrecommand noglob nocorrect exec command builtin - time + +syn keyword zshDelimiter do done end + +syn keyword zshConditional if then elif else fi case in esac select + +syn keyword zshRepeat while until repeat + +syn keyword zshRepeat for foreach nextgroup=zshVariable skipwhite + +syn keyword zshException always + +syn keyword zshKeyword function nextgroup=zshKSHFunction skipwhite + +syn match zshKSHFunction contained '\w\S\+' +syn match zshFunction '^\s*\k\+\ze\s*()' + +syn match zshOperator '||\|&&\|;\|&!\=' + +syn match zshRedir '\d\=\(<\|<>\|<<<\|<&\s*[0-9p-]\=\)' +syn match zshRedir '\d\=\(>\|>>\|>&\s*[0-9p-]\=\|&>\|>>&\|&>>\)[|!]\=' +syn match zshRedir '|&\=' + +syn region zshHereDoc matchgroup=zshRedir + \ start='<\@' + \ contains=@zshSubst +syn region zshHereDoc matchgroup=zshRedir + \ start='<\@' + \ contains=@zshSubst +syn region zshHereDoc matchgroup=zshRedir + \ start='<\@' + \ contains=@zshSubst +syn region zshHereDoc matchgroup=zshRedir + \ start=+<\@' +syn region zshHereDoc matchgroup=zshRedir + \ start=+<\@' + +syn match zshVariable '\<\h\w*' contained + +syn match zshVariableDef '\<\h\w*\ze+\==' +" XXX: how safe is this? +syn region zshVariableDef oneline + \ start='\$\@' + +syn match zshLongDeref '\$\%(ARGC\|argv\|status\|pipestatus\|CPUTYPE\|EGID\|EUID\|ERRNO\|GID\|HOST\|LINENO\|LOGNAME\)' +syn match zshLongDeref '\$\%(MACHTYPE\|OLDPWD OPTARG\|OPTIND\|OSTYPE\|PPID\|PWD\|RANDOM\|SECONDS\|SHLVL\|signals\)' +syn match zshLongDeref '\$\%(TRY_BLOCK_ERROR\|TTY\|TTYIDLE\|UID\|USERNAME\|VENDOR\|ZSH_NAME\|ZSH_VERSION\|REPLY\|reply\|TERM\)' + +syn match zshDollarVar '\$\h\w*' +syn match zshDeref '\$[=^~]*[#+]*\h\w*\>' + +syn match zshCommands '\%(^\|\s\)[.:]\ze\s' +syn keyword zshCommands alias autoload bg bindkey break bye cap cd + \ chdir clone comparguments compcall compctl + \ compdescribe compfiles compgroups compquote + \ comptags comptry compvalues continue dirs + \ disable disown echo echotc echoti emulate + \ enable eval exec exit export false fc fg + \ functions getcap getln getopts hash history + \ jobs kill let limit log logout popd print + \ printf pushd pushln pwd r read readonly + \ rehash return sched set setcap shift + \ source stat suspend test times trap true + \ ttyctl type ulimit umask unalias unfunction + \ unhash unlimit unset vared wait + \ whence where which zcompile zformat zftp zle + \ zmodload zparseopts zprof zpty zregexparse + \ zsocket zstyle ztcp + +" Options, generated by: echo ${(j:\n:)options[(I)*]} | sort +" Create a list of option names from zsh source dir: +" #!/bin/zsh +" topdir=/path/to/zsh-xxx +" grep '^pindex([A-Za-z_]*)$' $topdir/Src/Doc/Zsh/optionsyo | +" while read opt +" do +" echo ${${(L)opt#pindex\(}%\)} +" done + +syn case ignore + +syn match zshOptStart /^\s*\%(\%(\%(un\)\?setopt\)\|set\s+[-+]o\)/ nextgroup=zshOption skipwhite +syn match zshOption / + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?all_export\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?always_last_prompt\>\)\|\%(\%(no_\?\)\?always_lastprompt\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?always_to_end\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?append_create\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?append_history\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_cd\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_continue\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_list\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_menu\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_name_dirs\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_param_keys\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_param_slash\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_pushd\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_remove_slash\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?auto_resume\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?bad_pattern\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?bang_hist\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?bare_glob_qual\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?bash_auto_list\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?bash_rematch\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?bg_nice\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?brace_ccl\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?brace_expand\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?bsd_echo\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?case_glob\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?case_match\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?c_bases\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?cdable_vars\>\)\|\%(\%(no_\?\)\?cd_able_vars\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?chase_dots\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?chase_links\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?check_jobs\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?combining_chars\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?complete_aliases\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?complete_in_word\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?continue_on_error\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?correct_all\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?c_precedences\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?csh_junkie_history\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?csh_junkie_loops\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?csh_junkie_quotes\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?csh_null_cmd\>\)\|\%(\%(no_\?\)\?cshnullcmd\>\)\|\%(\%(no_\?\)\?csh_null_cmd\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?csh_null_glob\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?debug_before_cmd\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?dot_glob\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?err_exit\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?err_return\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?extended_glob\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?extended_history\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?flow_control\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?force_float\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?function_argzero\>\)\|\%(\%(no_\?\)\?function_arg_zero\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?global_export\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?global_rcs\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?glob_assign\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?glob_complete\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?glob_dots\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?globsubst\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?glob_star_short\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hash_all\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hash_cmds\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hash_dirs\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hash_executables_only\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hash_list_all\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_allow_clobber\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_append\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_beep\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?histexpand\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?histexpiredupsfirst\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_fcntl_lock\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_find_no_dups\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_ignore_all_dups\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_ignore_dups\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_ignore_space\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_lex_words\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_no_functions\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_no_store\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_reduce_blanks\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_save_by_copy\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_save_no_dups\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_subst_pattern\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?hist_verify\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ignore_braces\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ignore_close_braces\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ignore_eof\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?inc_append_history\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?inc_append_history_time\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?interactive_comments\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ksh_arrays\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ksh_autoload\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ksh_glob\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ksh_option_print\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ksh_typeset\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?ksh_zero_subscript\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?list_ambiguous\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?list_beep\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?list_packed\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?list_rows_first\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?list_types\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?local_loops\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?local_options\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?local_patterns\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?local_traps\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?long_list_jobs\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?magic_equal_subst\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?mail_warn\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?mail_warning\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?menu_complete\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?multi_byte\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?multi_func_def\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?multi_os\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?no_match\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?null_glob\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?numeric_glob_sort\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?octal_zeroes\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?one_cmd\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?over_strike\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?path_dirs\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?path_script\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?pipe_fail\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_aliases\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_arg_zero\>\)\|\%(\%(no_\?\)\?posix_argzero\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_builtins\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_cd\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_identifiers\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_jobs\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_strings\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?posix_traps\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?print_eight_bit\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?print_exit_value\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?prompt_bang\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?prompt_cr\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?prompt_percent\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?prompt_sp\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?prompt_subst\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?prompt_vars\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?pushd_ignore_dups\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?pushd_minus\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?pushd_silent\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?pushd_to_home\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?rc_expandparam\>\)\|\%(\%(no_\?\)\?rc_expand_param\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?rc_quotes\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?rec_exact\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?re_match_pcre\>\)\|\%(\%(no_\?\)\?rematch_pcre\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?rm_star_silent\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?rm_star_wait\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?share_history\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?sh_file_expansion\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?sh_glob\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?shin_stdin\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?sh_nullcmd\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?sh_option_letters\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?short_loops\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?sh_word_split\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?single_command\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?single_line_zle\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?source_trace\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?sun_keyboard_hack\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?track_all\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?transient_rprompt\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?traps_async\>\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?type_set_silent\>\)\|\%(\%(no_\?\)\?typeset_silent\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)\|\%(\%(no_\?\)\?warn_create_global\>\)\| + \ \%(\%(\\)\| + \ \%(\%(\\)/ nextgroup=zshOption skipwhite contained + +syn keyword zshTypes float integer local typeset declare private + +" XXX: this may be too much +" syn match zshSwitches '\s\zs--\=[a-zA-Z0-9-]\+' + +syn match zshNumber '[+-]\=\<\d\+\>' +syn match zshNumber '[+-]\=\<0x\x\+\>' +syn match zshNumber '[+-]\=\<0\o\+\>' +syn match zshNumber '[+-]\=\d\+#[-+]\=\w\+\>' +syn match zshNumber '[+-]\=\d\+\.\d\+\>' + +" TODO: $[...] is the same as $((...)), so add that as well. +syn cluster zshSubst contains=zshSubst,zshOldSubst,zshMathSubst +syn region zshSubst matchgroup=zshSubstDelim transparent + \ start='\$(' skip='\\)' end=')' contains=TOP fold +syn region zshParentheses transparent start='(' skip='\\)' end=')' fold +syn region zshGlob start='(#' end=')' +syn region zshMathSubst matchgroup=zshSubstDelim transparent + \ start='\$((' skip='\\)' end='))' + \ contains=zshParentheses,@zshSubst,zshNumber, + \ @zshDerefs,zshString keepend fold +syn region zshBrackets contained transparent start='{' skip='\\}' + \ end='}' fold +syn region zshBrackets transparent start='{' skip='\\}' + \ end='}' contains=TOP fold +syn region zshSubst matchgroup=zshSubstDelim start='\${' skip='\\}' + \ end='}' contains=@zshSubst,zshBrackets,zshQuoted,zshString fold +syn region zshOldSubst matchgroup=zshSubstDelim start=+`+ skip=+\\`+ + \ end=+`+ contains=TOP,zshOldSubst fold + +syn sync minlines=50 maxlines=90 +syn sync match zshHereDocSync grouphere NONE '<<-\=\s*\%(\\\=\S\+\|\(["']\)\S\+\1\)' +syn sync match zshHereDocEndSync groupthere NONE '^\s*EO\a\+\>' + +hi def link zshTodo Todo +hi def link zshComment Comment +hi def link zshPreProc PreProc +hi def link zshQuoted SpecialChar +hi def link zshString String +hi def link zshStringDelimiter zshString +hi def link zshPOSIXString zshString +hi def link zshJobSpec Special +hi def link zshPrecommand Special +hi def link zshDelimiter Keyword +hi def link zshConditional Conditional +hi def link zshException Exception +hi def link zshRepeat Repeat +hi def link zshKeyword Keyword +hi def link zshFunction None +hi def link zshKSHFunction zshFunction +hi def link zshHereDoc String +hi def link zshOperator None +hi def link zshRedir Operator +hi def link zshVariable None +hi def link zshVariableDef zshVariable +hi def link zshDereferencing PreProc +hi def link zshShortDeref zshDereferencing +hi def link zshLongDeref zshDereferencing +hi def link zshDeref zshDereferencing +hi def link zshDollarVar zshDereferencing +hi def link zshCommands Keyword +hi def link zshOptStart Keyword +hi def link zshOption Constant +hi def link zshTypes Type +hi def link zshSwitches Special +hi def link zshNumber Number +hi def link zshSubst PreProc +hi def link zshMathSubst zshSubst +hi def link zshOldSubst zshSubst +hi def link zshSubstDelim zshSubst +hi def link zshGlob zshSubst + +let b:current_syntax = "zsh" + +let &cpo = s:cpo_save +unlet s:cpo_save + +endif