1071d4279SBram Moolenaar" Vim syntax file 2b2c0350cSBram Moolenaar" Language: Vim 7.3 script 3071d4279SBram Moolenaar" Maintainer: Dr. Charles E. Campbell, Jr. <[email protected]> 4*d960d76dSBram Moolenaar" Last Change: Jul 18, 2011 5*d960d76dSBram Moolenaar" Version: 7.3-08 6071d4279SBram Moolenaar" Automatically generated keyword lists: {{{1 7071d4279SBram Moolenaar 8071d4279SBram Moolenaar" Quit when a syntax file was already loaded {{{2 9071d4279SBram Moolenaarif exists("b:current_syntax") 10071d4279SBram Moolenaar finish 11071d4279SBram Moolenaarendif 12071d4279SBram Moolenaar 13071d4279SBram Moolenaar" vimTodo: contains common special-notices for comments {{{2 14071d4279SBram Moolenaar" Use the vimCommentGroup cluster to add your own. 1518144c84SBram Moolenaarsyn keyword vimTodo contained COMBAK FIXME TODO XXX 16217ad920SBram Moolenaarsyn cluster vimCommentGroup contains=vimTodo,@Spell 17071d4279SBram Moolenaar 18071d4279SBram Moolenaar" regular vim commands {{{2 1981af9250SBram Moolenaarsyn keyword vimCommand contained a arga[dd] argu[ment] bd[elete] bN[ext] breakd[el] buf c cal[l] ce[nter] cg[etfile] cl cn cNf comc[lear] cope[n] cr[ewind] d d[elete] diffo diffsplit di[splay] ds[earch] ec e:e:e en endt[ry] exu[sage] filetype fix[del] for go[to] h hi if intro k la lan[guage] lch[dir] let@ lg[etfile] lla[st] lnew[er] lNf[ile] loc[kmarks] lr[ewind] lv[imgrep] ma[rk] messages mkv mv n new noautocmd on[ly] p:~ perld[o] popu[p] p[rint] promptr[epl] ptl[ast] ptr[ewind] py3file q[uit] r[ead] redraws[tatus] ret[ab] r:r:r ru[ntime] sba[ll] sbp[revious] scs sf[ind] sil[ent] sm[ap] sno[magic] so[urce] spellr[epall] st startr[eplace] sunme sw[apname] t tabf[ind] tabn[ext] ta[g] tf[irst] tn tp[revious] tu undoj[oin] up[date] vi vmapc[lear] win wN[ext] wundo xmapc[lear] xnoremenu 2081af9250SBram Moolenaarsyn keyword vimCommand contained ab argd[elete] as[cii] bel[owright] bo[tright] breakl[ist] bufdo cabc[lear] cat[ch] cex[pr] c[hange] cla[st] cN cnf[ile] comment co[py] cs de delf diffoff difft dj[ump] dsp[lit] echoe[rr] e:e:r endf endw[hile] f fin fo[ld] fu gr[ep] ha[rdcopy] hid[e] ij[ump] is[earch] keepa lad la[st] lcl[ose] lex[pr] lgr[ep] lli[st] lne[xt] lo lockv[ar] ls lvimgrepa[dd] marks mk mkvie[w] Mycmd N n[ext] noh[lsearch] o[pen] P p:gs? pp[op] P[rint] ps[earch] ptn pts[elect] pyf[ile] quita[ll] rec[over] reg[isters] retu[rn] ru rv[iminfo] sbf[irst] sbr[ewind] scscope sfir[st] sim[alt] sme snoreme s?pat?sub? spellu[ndo] sta[g] stj[ump] sunmenu sy ta tabfir[st] tabN[ext] tags th[row] tN tr tu[nmenu] undol[ist] v vie[w] vne[w] winc[md] wp[revious] wv[iminfo] xme xterm 2181af9250SBram Moolenaarsyn keyword vimCommand contained abc[lear] argdo au bf[irst] bp[revious] br[ewind] b[uffer] cad cb[uffer] cf[ile] changes cl[ist] cnew[er] cNf[ile] comp[iler] count cscope debug delf[unction] DiffOrig diffthis dl[ist] dwim echom[sg] el[se] endfo[r] ene[w] f[ile] fina[lly] foldc[lose] fun grepa[dd] h[elp] his[tory] il[ist] isp[lit] keepalt laddb[uffer] lat lcs lf[ile] lgrepa[dd] lmak[e] lN[ext] loadk lol[der] lt[ag] lw[indow] mat[ch] mkdir mkv[imrc] MyCommand nbc[lose] N[ext] nu[mber] opt[ions] pc[lose] p:h pr pro p:t ptN pu[t] py[thon] quote red Ren rew[ind] rub[y] sal[l] sbl[ast] sb[uffer] se[t] sh[ell] sl smenu snoremenu spe spellw[rong] star st[op] sus[pend] syn tab tabl[ast] tabo[nly] tc[l] tj[ump] tn[ext] t:r u unh[ide] ve vim[grep] vs[plit] windo wq x xmenu xunme 2281af9250SBram Moolenaarsyn keyword vimCommand contained abo[veleft] arge[dit] bad[d] bl[ast] br bro[wse] buffers caddb[uffer] cc cfir[st] chd[ir] clo[se] cn[ext] col[der] con cpf[ile] cstag debugg[reedy] delm[arks] diffp diffu[pdate] do e echon elsei[f] endfun Error filename fin[d] folddoc[losed] fu[nction] gs?pat?sub? helpf[ind] i imapc[lear] iuna[bbrev] keepj[umps] lad[dexpr] later lcscope lfir[st] lh[elpgrep] lmapc[lear] lnf loadkeymap lop[en] lua ma menut mk[exrc] mo mz nb[key] nkf o ownsyntax pe p:h:h p:r profd[el] pta[g] ptn[ext] pw[d] python3 r redi[r] Rena ri[ght] rubyd[o] san[dbox] sbm[odified] scrip setf[iletype] si sla[st] sn[ext] s@\n@\=\r" spelld[ump] sp[lit] start stopi[nsert] s?version?main? sync tabc[lose] tabm[ove] tabp[revious] tcld[o] tl[ast] tN[ext] tr[ewind] un unl verb[ose] vimgrepa[dd] w winp[os] wqa[ll] X XMLent xunmenu 2381af9250SBram Moolenaarsyn keyword vimCommand contained al[l] argg[lobal] ba[ll] bm[odified] brea[k] browseset bun[load] cad[dexpr] ccl[ose] cgetb[uffer] che[ckpath] cmapc[lear] cN[ext] colo[rscheme] conf[irm] cp[revious] cuna[bbrev] del di diffpatch dig doau ea e[dit] em[enu] endf[unction] ex files fini[sh] foldd[oopen] g gui helpg[rep] ia in j[oin] kee[pmarks] laddf[ile] lb[uffer] le[ft] lgetb[uffer] l[ist] lN lNf lo[adview] lpf[ile] luado mak[e] menut[ranslate] mks[ession] mod[e] mzf[ile] nbs[tart] nmapc[lear] ol[dfiles] p ped[it] po[p] pre[serve] prof[ile] ptf[irst] ptN[ext] py q re red[o] Renu rightb[elow] rubyf[ile] sa[rgument] sbn[ext] scripte[ncoding] setg[lobal] sig sl[eep] sN[ext] so spe[llgood] spr[evious] startg[replace] sts[elect] s?version?main?:p syncbind tabd[o] tabN tabr[ewind] tclf[ile] tm TOhtml try una[bbreviate] unlo[ckvar] ve[rsion] vi[sual] wa[ll] win[size] w[rite] xa[ll] XMLns xwininfo 2481af9250SBram Moolenaarsyn keyword vimCommand contained Allargs argl[ocal] bar bn[ext] breaka[dd] bu bw[ipeout] caddf[ile] cd cgete[xpr] checkt[ime] cmdname cnf com con[tinue] cq[uit] cw[indow] delc[ommand] diffg[et] diffpu[t] dig[raphs] dr[op] earlier e:e emenu* en[dif] exi[t] filet fir[st] foldo[pen] get gvim helpt[ags] iabc[lear] index ju[mps] l lan lc[d] lefta[bove] lgete[xpr] ll lne lnf[ile] locale lp[revious] luafile Man mes mksp[ell] m[ove] mz[scheme] ne noa omapc[lear] p: pe[rl] popu prev[ious] promptf[ind] ptj[ump] ptp[revious] py3 qa[ll] r:e redr[aw] res[ize] r:r rundo sav[eas] sbN[ext] scrip[tnames] setl[ocal] sign sm[agic] sni[ff] sor[t] spelli[nfo] sre[wind] star[tinsert] sun[hide] sv[iew] synlist tabe[dit] tabnew tabs te[aroff] tm[enu] to[pleft] ts[elect] u[ndo] uns[ilent] vert[ical] viu[sage] wh[ile] wn[ext] ws[verb] x[it] xnoreme y[ank] 2581af9250SBram Moolenaarsyn keyword vimCommand contained ar ar[gs] 2681af9250SBram Moolenaarsyn match vimCommand contained "\<z[-+^.=]\=" 27071d4279SBram Moolenaar 28071d4279SBram Moolenaar" vimOptions are caught only when contained in a vimSet {{{2 29*d960d76dSBram Moolenaarsyn keyword vimOption contained acd ambiwidth arabicshape autowriteall backupdir bdlay binary breakat bufhidden cd ci cinw co commentstring confirm cpoptions cscoperelative csre cursorcolumn delcombine diffopt ea efm ep et fdc fdo ffs fk foldcolumn foldmethod formatoptions gd go guifont guitabtooltip hid hkp iconstring imd include inex isi js kp linebreak lm lz matchpairs maxmemtot mkspellmem mod mousef mouset nf oft pa path pheader previewheight printmbcharset pvw remap rl ruf sc scrollopt selectmode shellpipe shiftround showfulltag sidescrolloff smarttab sp spf srr startofline suffixes switchbuf tabline tags tbs textmode timeout tl tpm ttimeoutlen ttymouse udf undoreload vbs vi vop wcm whichwrap wildignore winaltkeys winminwidth wmnu write 30*d960d76dSBram Moolenaarsyn keyword vimOption contained ai ambw ari aw backupext beval biosk brk buflisted cdpath cin cinwords cocu compatible consk cpt cscopetag cst cursorline dex digraph ead ei equalalways eventignore fde fdt fileencoding fkmap foldenable foldminlines formatprg gdefault gp guifontset helpfile hidden hl ignorecase imdisable includeexpr inf isident key langmap lines lmap ma matchtime mco ml modeline mousefocus mousetime nrformats ofu para pdev pi previewwindow printmbfont qe report rlc ruler scb scs sessionoptions shellquote shiftwidth showmatch siso smc spc spl ss statusline suffixesadd sws tabpagemax tagstack tenc textwidth timeoutlen tm tr ttm ttyscroll udir updatecount vdir viewdir wa wd wi wildignorecase window winwidth wmw writeany 31*d960d76dSBram Moolenaarsyn keyword vimOption contained akm anti arshape awa backupskip bex bioskey browsedir buftype cedit cindent clipboard cole complete conskey crb cscopetagorder csto cwh dg dip eadirection ek equalprg ex fdi fen fileencodings flp foldexpr foldnestmax fp gfm grepformat guifontwide helpheight highlight hlg im imi incsearch infercase isk keymap langmenu linespace loadplugins macatsui maxcombine mef mls modelines mousehide mp nu omnifunc paragraphs penc pm printdevice printoptions quoteescape restorescreen rnu rulerformat scr sect sft shellredir shm showmode sj smd spell splitbelow ssl stl sw sxq tabstop tal term tf title to ts tty ttytype ul updatetime ve viewoptions wak weirdinvert wic wildmenu winfixheight wiv wop writebackup 32*d960d76dSBram Moolenaarsyn keyword vimOption contained al antialias autochdir background balloondelay bexpr bk bs casemap cf cink cmdheight colorcolumn completefunc copyindent cryptmethod cscopeverbose csverb debug dict dir eb enc errorbells expandtab fdl fenc fileformat fml foldignore foldopen fs gfn grepprg guiheadroom helplang history hls imactivatekey iminsert inde insertmode iskeyword keymodel laststatus lisp lpl magic maxfuncdepth menuitems mm modifiable mousem mps number opendevice paste pex pmbcs printencoding prompt rdt revins ro runtimepath scroll sections sh shellslash shortmess showtabline slm sn spellcapcheck splitright ssop stmp swapfile syn tag tb termbidi tgst titlelen toolbar tsl ttybuiltin tw undodir ur verbose viminfo warn wfh wig wildmode winfixwidth wiw wrap writedelay 33*d960d76dSBram Moolenaarsyn keyword vimOption contained aleph ar autoindent backspace ballooneval bg bkc bsdir cb cfu cinkeys cmdwinheight columns completeopt cot cscopepathcomp cspc cuc deco dictionary directory ed encoding errorfile exrc fdls fencs fileformats fmr foldlevel foldtext fsync gfs gtl guioptions hf hk hlsearch imak ims indentexpr is isp keywordprg lazyredraw lispwords ls makeef maxmapdepth mfd mmd modified mousemodel msm numberwidth operatorfunc pastetoggle pexpr pmbfn printexpr pt readonly ri rs sb scrollbind secure shcf shelltemp shortname shq sm so spellfile spr st sts swapsync synmaxcol tagbsearch tbi termencoding thesaurus titleold toolbariconsize tsr ttyfast tx undofile ut verbosefile virtualedit wb wfw wildchar wildoptions winheight wm wrapmargin ws 34*d960d76dSBram Moolenaarsyn keyword vimOption contained allowrevins arab autoread backup balloonexpr bh bl bsk cc ch cino cmp com concealcursor cp cscopeprg csprg cul def diff display edcompatible endofline errorformat fcl fdm fex filetype fo foldlevelstart formatexpr ft gfw gtt guipty hh hkmap ic imc imsearch indentkeys isf isprint km lbr list lsp makeprg maxmem mh mmp more mouses mzq nuw opfunc patchexpr pfn popt printfont pumheight redrawtime rightleft rtp sbo scrolljump sel shell shelltype showbreak si smartcase softtabstop spelllang sps sta su swb syntax taglength tbidi terse tildeop titlestring top ttimeout ttym uc undolevels vb vfile visualbell wc wh wildcharm wim winminheight wmh wrapscan ww 35*d960d76dSBram Moolenaarsyn keyword vimOption contained altkeymap arabic autowrite backupcopy bdir bin bomb bt ccv charconvert cinoptions cms comments conceallevel cpo cscopequickfix csqf cursorbind define diffexpr dy ef eol esckeys fcs fdn ff fillchars foldclose foldmarker formatlistpat gcr ghr guicursor guitablabel hi hkmapp icon imcmdline inc indk isfname joinspaces kmp lcs listchars lw mat maxmempattern mis mmt mouse mouseshape mzquantum odev osfiletype patchmode ph preserveindent printheader pvh relativenumber rightleftcmd ru sbr scrolloff selection shellcmdflag shellxquote showcmd sidescroll smartindent sol spellsuggest sr stal sua swf ta tagrelative tbis textauto 36071d4279SBram Moolenaar 37071d4279SBram Moolenaar" vimOptions: These are the turn-off setting variants {{{2 38*d960d76dSBram Moolenaarsyn keyword vimOption contained noacd noallowrevins noantialias noarabic noarshape noautoread noaw noballooneval nobinary nobk nobuflisted nocin noconfirm nocopyindent nocscopetag nocsverb nocursorbind nodeco nodiff noeb noek noequalalways noesckeys noex noexrc nofk nofoldenable nogdefault nohid nohk nohkmapp nohls noic noignorecase noimc noimd noincsearch noinfercase nois nojs nolbr nolisp noloadplugins 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 novb nowa nowb nowfh nowildignorecase* * nowinfixheight nowiv nowrap nowrite nowritebackup 39*d960d76dSBram Moolenaarsyn keyword vimOption contained noai noaltkeymap noar noarabicshape noautochdir noautowrite noawa nobeval nobiosk nobl nocf nocindent noconsk nocp nocscopeverbose nocuc nocursorcolumn nodelcombine nodigraph noed noendofline noerrorbells noet noexpandtab nofen nofkmap nogd noguipty nohidden nohkmap nohkp nohlsearch noicon noim noimcmdline noimdisable noinf noinsertmode nojoinspaces nolazyredraw nolinebreak nolist nolpl 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 novisualbell nowarn noweirdinvert nowfw nowildmenu nowinfixwidth nowmnu nowrapscan nowriteany nows 40*d960d76dSBram Moolenaarsyn keyword vimOption contained noakm noanti noarab noari noautoindent noautowriteall nobackup nobin nobioskey nobomb noci nocompatible noconskey nocrb nocst nocul nocursorline nodg noea noedcompatible noeol 41071d4279SBram Moolenaar 42071d4279SBram Moolenaar" vimOptions: These are the invertible variants {{{2 43*d960d76dSBram Moolenaarsyn keyword vimOption contained invacd invallowrevins invantialias invarabic invarshape invautoread invaw invballooneval invbinary invbk invbuflisted invcin invconfirm invcopyindent invcscopetag invcsverb invcursorbind invdeco invdiff inveb invek invequalalways invesckeys invex invexrc invfk invfoldenable invgdefault invhid invhk invhkmapp invhls invic invignorecase invimc invimd invincsearch invinfercase invis invjs invlbr invlisp invloadplugins 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 invvb invwa invwb invwfh invwildignorecase* * invwinfixheight invwiv invwrap invwrite invwritebackup 44*d960d76dSBram Moolenaarsyn keyword vimOption contained invai invaltkeymap invar invarabicshape invautochdir invautowrite invawa invbeval invbiosk invbl invcf invcindent invconsk invcp invcscopeverbose invcuc invcursorcolumn invdelcombine invdigraph inved invendofline inverrorbells invet invexpandtab invfen invfkmap invgd invguipty invhidden invhkmap invhkp invhlsearch invicon invim invimcmdline invimdisable invinf invinsertmode invjoinspaces invlazyredraw invlinebreak invlist invlpl 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 invvisualbell invwarn invweirdinvert invwfw invwildmenu invwinfixwidth invwmnu invwrapscan invwriteany invws 45*d960d76dSBram Moolenaarsyn keyword vimOption contained invakm invanti invarab invari invautoindent invautowriteall invbackup invbin invbioskey invbomb invci invcompatible invconskey invcrb invcst invcul invcursorline invdg invea invedcompatible inveol 46071d4279SBram Moolenaar 47071d4279SBram Moolenaar" termcap codes (which can also be set) {{{2 483577c6faSBram Moolenaarsyn keyword vimOption contained t_AB t_al t_bc t_ce t_cl t_Co t_cs t_Cs t_CS t_CV t_da t_db t_dl t_DL t_EI t_F1 t_F2 t_F3 t_F4 t_F5 t_F6 t_F7 t_F8 t_F9 t_fs t_IE t_IS t_k1 t_K1 t_k2 t_k3 t_K3 t_k4 t_K4 t_k5 t_K5 t_k6 t_K6 t_k7 t_K7 t_k8 t_K8 t_k9 t_K9 t_KA t_kb t_kB t_KB t_KC t_kd t_kD t_KD t_ke t_KE t_KF t_KG t_kh t_KH t_kI t_KI t_KJ t_KK t_kl t_KL t_kN t_kP t_kr t_ks t_ku t_le t_mb t_md t_me t_mr t_ms t_nd t_op t_RI t_RV t_Sb t_se t_Sf t_SI t_so t_sr t_te t_ti t_ts t_ue t_us t_ut t_vb t_ve t_vi t_vs t_WP t_WS t_xs t_ZH t_ZR 493577c6faSBram Moolenaarsyn keyword vimOption contained t_AF t_AL t_cd t_Ce t_cm 50071d4279SBram Moolenaarsyn match vimOption contained "t_%1" 51071d4279SBram Moolenaarsyn match vimOption contained "t_#2" 52071d4279SBram Moolenaarsyn match vimOption contained "t_#4" 53071d4279SBram Moolenaarsyn match vimOption contained "t_@7" 54071d4279SBram Moolenaarsyn match vimOption contained "t_*7" 55071d4279SBram Moolenaarsyn match vimOption contained "t_&8" 56071d4279SBram Moolenaarsyn match vimOption contained "t_%i" 57071d4279SBram Moolenaarsyn match vimOption contained "t_k;" 58071d4279SBram Moolenaar 59071d4279SBram Moolenaar" unsupported settings: these are supported by vi but don't do anything in vim {{{2 60cd71fa3cSBram Moolenaarsyn keyword vimErrSetting contained hardtabs ht w1200 w300 w9600 61071d4279SBram Moolenaar 6280a94a58SBram Moolenaar" AutoCmd Events {{{2 63071d4279SBram Moolenaarsyn case ignore 64*d960d76dSBram Moolenaarsyn 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 Cmd-event CmdwinEnter CmdwinLeave ColorScheme 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 QuickFixCmdPost QuickFixCmdPre RemoteReply SessionLoadPost ShellCmdPost ShellFilterPost SourceCmd SourcePre SpellFileMissing StdinReadPost StdinReadPre SwapExists Syntax TabEnter TabLeave TermChanged TermResponse User UserGettingBored VimEnter VimLeave VimLeavePre VimResized WinEnter WinLeave 65071d4279SBram Moolenaar 66071d4279SBram Moolenaar" Highlight commonly used Groupnames {{{2 67b2c0350cSBram Moolenaarsyn 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 68071d4279SBram Moolenaar 69071d4279SBram Moolenaar" Default highlighting groups {{{2 70fa01c39dSBram Moolenaarsyn keyword vimHLGroup contained ColorColumn Cursor CursorColumn CursorIM CursorLine DiffAdd DiffChange DiffDelete DiffText Directory 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 71293ee4d4SBram Moolenaarsyn match vimHLGroup contained "Conceal" 72071d4279SBram Moolenaarsyn case match 73071d4279SBram Moolenaar 74071d4279SBram Moolenaar" Function Names {{{2 7574cbdf03SBram Moolenaarsyn keyword vimFuncName contained abs append argv atan2 bufexists bufname byte2line ceil cindent complete confirm cosh cursor did_filetype empty eventhandler exp extend filewritable findfile fmod foldclosed foldtext function getbufline getcharmod getcmdtype getfperm getftype getmatches getqflist gettabvar getwinposy globpath haslocaldir histdel hlexists iconv input inputrestore insert items len line localtime map match matchdelete matchstr min mode nextnonblank pathshorten prevnonblank pumvisible readfile reltimestr remote_foreground remote_read remove repeat reverse search searchpair searchpos serverlist setcmdpos setloclist setpos setreg settabwinvar shellescape sin sort spellbadword split str2float strchars strftime string strpart strtrans submatch synconcealed synIDattr synstack tabpagebuflist tabpagewinnr taglist tanh tolower tr type undotree virtcol winbufnr winheight winnr winrestview winwidth 7674cbdf03SBram Moolenaarsyn keyword vimFuncName contained acos argc asin browse buflisted bufnr byteidx changenr clearmatches complete_add copy count deepcopy diff_filler escape executable expand feedkeys filter float2nr fnameescape foldclosedend foldtextresult garbagecollect getbufvar getcmdline getcwd getfsize getline getpid getreg gettabwinvar getwinvar has hasmapto histget hlID indent inputdialog inputsave isdirectory join libcall line2byte log maparg matchadd matchend max mkdir mzeval nr2char pow printf range reltime remote_expr remote_peek remote_send rename resolve round searchdecl searchpairpos server2client setbufvar setline setmatches setqflist settabvar setwinvar simplify sinh soundfold spellsuggest sqrt str2nr strdisplaywidth stridx strlen strridx strwidth substitute synID synIDtrans system tabpagenr tagfiles tan tempname toupper trunc undofile values visualmode wincol winline winrestcmd winsaveview writefile 7774cbdf03SBram Moolenaarsyn keyword vimFuncName contained add argidx atan browsedir bufloaded bufwinnr call char2nr col complete_check cos cscope_connection delete diff_hlID eval exists expr8 filereadable finddir floor fnamemodify foldlevel foreground get getchar getcmdpos getfontname getftime getloclist getpos getregtype getwinposx glob has_key histadd histnr hostname index inputlist inputsecret islocked keys libcallnr lispindent log10 mapcheck matcharg matchlist 78071d4279SBram Moolenaar 79071d4279SBram Moolenaar"--- syntax above generated by mkvimvim --- 80cfbc5ee4SBram Moolenaar" Special Vim Highlighting (not automatic) {{{1 81071d4279SBram Moolenaar 82fa01c39dSBram Moolenaar" commands not picked up by the generator (due to non-standard format) 83fa01c39dSBram Moolenaarsyn keyword vimCommand contained py3 84fa01c39dSBram Moolenaar 853577c6faSBram Moolenaar" Deprecated variable options {{{2 863577c6faSBram Moolenaarif exists("g:vim_minlines") 873577c6faSBram Moolenaar let g:vimsyn_minlines= g:vim_minlines 883577c6faSBram Moolenaarendif 893577c6faSBram Moolenaarif exists("g:vim_maxlines") 903577c6faSBram Moolenaar let g:vimsyn_maxlines= g:vim_maxlines 913577c6faSBram Moolenaarendif 923577c6faSBram Moolenaarif exists("g:vimsyntax_noerror") 933577c6faSBram Moolenaar let g:vimsyn_noerror= g:vimsyntax_noerror 943577c6faSBram Moolenaarendif 953577c6faSBram Moolenaar 96cfbc5ee4SBram Moolenaar" Numbers {{{2 97071d4279SBram Moolenaar" ======= 98071d4279SBram Moolenaarsyn match vimNumber "\<\d\+\([lL]\|\.\d\+\)\=" 99071d4279SBram Moolenaarsyn match vimNumber "-\d\+\([lL]\|\.\d\+\)\=" 100071d4279SBram Moolenaarsyn match vimNumber "\<0[xX]\x\+" 101071d4279SBram Moolenaarsyn match vimNumber "#\x\{6}" 102071d4279SBram Moolenaar 103cfbc5ee4SBram Moolenaar" All vimCommands are contained by vimIsCommands. {{{2 104071d4279SBram Moolenaarsyn match vimCmdSep "[:|]\+" skipwhite nextgroup=vimAddress,vimAutoCmd,vimCommand,vimExtCmd,vimFilter,vimLet,vimMap,vimMark,vimSet,vimSyntax,vimUserCmd 105293ee4d4SBram Moolenaarsyn match vimIsCommand "\<\h\w*\>" contains=vimCommand 106071d4279SBram Moolenaarsyn match vimVar "\<[bwglsav]:\K\k*\>" 107071d4279SBram Moolenaarsyn match vimVar contained "\<\K\k*\>" 1085c73622aSBram Moolenaarsyn match vimFBVar contained "\<[bwglsav]:\K\k*\>" 1093b1ddfedSBram Moolenaarsyn keyword vimCommand contained in 110071d4279SBram Moolenaar 111cfbc5ee4SBram Moolenaar" Insertions And Appends: insert append {{{2 112071d4279SBram Moolenaar" ======================= 113071d4279SBram Moolenaarsyn region vimInsert matchgroup=vimCommand start="^[: \t]*\(\d\+\(,\d\+\)\=\)\=a\%[ppend]$" matchgroup=vimCommand end="^\.$"" 114071d4279SBram Moolenaarsyn region vimInsert matchgroup=vimCommand start="^[: \t]*\(\d\+\(,\d\+\)\=\)\=c\%[hange]$" matchgroup=vimCommand end="^\.$"" 115071d4279SBram Moolenaarsyn region vimInsert matchgroup=vimCommand start="^[: \t]*\(\d\+\(,\d\+\)\=\)\=i\%[nsert]$" matchgroup=vimCommand end="^\.$"" 116071d4279SBram Moolenaar 117cfbc5ee4SBram Moolenaar" Behave! {{{2 118071d4279SBram Moolenaar" ======= 119071d4279SBram Moolenaarsyn match vimBehave "\<be\%[have]\>" skipwhite nextgroup=vimBehaveModel,vimBehaveError 120071d4279SBram Moolenaarsyn keyword vimBehaveModel contained mswin xterm 1213577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 122071d4279SBram Moolenaar syn match vimBehaveError contained "[^ ]\+" 123cfbc5ee4SBram Moolenaarendif 124071d4279SBram Moolenaar 125cfbc5ee4SBram Moolenaar" Filetypes {{{2 126071d4279SBram Moolenaar" ========= 127293ee4d4SBram Moolenaarsyn match vimFiletype "\<filet\%[ype]\(\s\+\I\i*\)*" skipwhite contains=vimFTCmd,vimFTOption,vimFTError 1283577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 129071d4279SBram Moolenaar syn match vimFTError contained "\I\i*" 130cfbc5ee4SBram Moolenaarendif 131071d4279SBram Moolenaarsyn keyword vimFTCmd contained filet[ype] 132071d4279SBram Moolenaarsyn keyword vimFTOption contained detect indent off on plugin 133071d4279SBram Moolenaar 134cfbc5ee4SBram Moolenaar" Augroup : vimAugroupError removed because long augroups caused sync'ing problems. {{{2 135071d4279SBram Moolenaar" ======= : Trade-off: Increasing synclines with slower editing vs augroup END error checking. 136*d960d76dSBram Moolenaarsyn cluster vimAugroupList contains=vimIsCommand,vimCommand,vimUserCmd,vimExecute,vimNotFunc,vimFuncName,vimFunction,vimFunctionError,vimLineComment,vimSpecFile,vimOper,vimNumber,vimOperParen,vimComment,vimString,vimSubst,vimMark,vimRegister,vimAddress,vimFilter,vimCmplxRepeat,vimComment,vimLet,vimSet,vimAutoCmd,vimRegion,vimSynLine,vimNotation,vimCtrlChar,vimFuncVar,vimContinue 1373577c6faSBram Moolenaarif exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'a' 1383577c6faSBram Moolenaar syn region vimAugroup fold start="\<aug\%[roup]\>\s\+\K\k*" end="\<aug\%[roup]\>\s\+[eE][nN][dD]\>" contains=vimAugroupKey,vimAutoCmd,@vimAugroupList keepend 1393577c6faSBram Moolenaarelse 140071d4279SBram Moolenaar syn region vimAugroup start="\<aug\%[roup]\>\s\+\K\k*" end="\<aug\%[roup]\>\s\+[eE][nN][dD]\>" contains=vimAugroupKey,vimAutoCmd,@vimAugroupList keepend 1413577c6faSBram Moolenaarendif 1423b1ddfedSBram Moolenaarsyn match vimAugroup "aug\%[roup]!" contains=vimAugroupKey 1433577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 144071d4279SBram Moolenaar syn match vimAugroupError "\<aug\%[roup]\>\s\+[eE][nN][dD]\>" 145cfbc5ee4SBram Moolenaarendif 146071d4279SBram Moolenaarsyn keyword vimAugroupKey contained aug[roup] 147071d4279SBram Moolenaar 148cfbc5ee4SBram Moolenaar" Operators: {{{2 149071d4279SBram Moolenaar" ========= 1505c73622aSBram Moolenaarsyn cluster vimOperGroup contains=vimFunc,vimFuncVar,vimOper,vimOperParen,vimNumber,vimString,vimRegister,vimContinue 151071d4279SBram Moolenaarsyn match vimOper "\(==\|!=\|>=\|<=\|=\~\|!\~\|>\|<\|=\)[?#]\{0,2}" skipwhite nextgroup=vimString,vimSpecFile 152071d4279SBram Moolenaarsyn match vimOper "||\|&&\|[-+.]" skipwhite nextgroup=vimString,vimSpecFile 1535c73622aSBram Moolenaarsyn region vimOperParen oneline matchgroup=vimParenSep start="(" end=")" contains=@vimOperGroup 1545c73622aSBram Moolenaarsyn region vimOperParen oneline matchgroup=vimSep start="{" end="}" contains=@vimOperGroup nextgroup=vimVar,vimFuncVar 1553577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 156071d4279SBram Moolenaar syn match vimOperError ")" 157cfbc5ee4SBram Moolenaarendif 158071d4279SBram Moolenaar 1593577c6faSBram Moolenaar" Functions : Tag is provided for those who wish to highlight tagged functions {{{2 1603577c6faSBram Moolenaar" ========= 1615c73622aSBram Moolenaarsyn cluster vimFuncList contains=vimCommand,vimFunctionError,vimFuncKey,Tag,vimFuncSID 1625c73622aSBram Moolenaarsyn cluster vimFuncBodyList contains=vimAbb,vimAddress,vimAugroupKey,vimAutoCmd,vimCmplxRepeat,vimComment,vimComment,vimContinue,vimCtrlChar,vimEcho,vimEchoHL,vimExecute,vimIf,vimIsCommand,vimFBVar,vimFunc,vimFunction,vimFuncVar,vimHighlight,vimIsCommand,vimLet,vimLineComment,vimMap,vimMark,vimNorm,vimNotation,vimNotFunc,vimNumber,vimOper,vimOperParen,vimRegion,vimRegister,vimSet,vimSpecFile,vimString,vimSubst,vimSynLine,vimUserCommand 1635c73622aSBram Moolenaarsyn match vimFunction "\<fu\%[nction]!\=\s\+\%(<[sS][iI][dD]>\|[sSgGbBwWtTlL]:\)\=\%(\i\|[#.]\|{.\{-1,}}\)*\ze\s*(" contains=@vimFuncList nextgroup=vimFuncBody 1645c73622aSBram Moolenaar 1653577c6faSBram Moolenaarif exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'f' 1663577c6faSBram Moolenaar syn region vimFuncBody contained fold start="\ze(" matchgroup=vimCommand end="\<\(endf\>\|endfu\%[nction]\>\)" contains=@vimFuncBodyList 1673577c6faSBram Moolenaarelse 1683577c6faSBram Moolenaar syn region vimFuncBody contained start="\ze(" matchgroup=vimCommand end="\<\(endf\>\|endfu\%[nction]\>\)" contains=@vimFuncBodyList 1693577c6faSBram Moolenaarendif 1705c73622aSBram Moolenaarsyn match vimFuncVar contained "a:\(\K\k*\|\d\+\)" 1713577c6faSBram Moolenaarsyn match vimFuncSID contained "\c<sid>\|\<s:" 1723577c6faSBram Moolenaarsyn keyword vimFuncKey contained fu[nction] 1733577c6faSBram Moolenaarsyn match vimFuncBlank contained "\s\+" 1743577c6faSBram Moolenaar 1753577c6faSBram Moolenaarsyn keyword vimPattern contained start skip end 1763577c6faSBram Moolenaar 177cfbc5ee4SBram Moolenaar" Special Filenames, Modifiers, Extension Removal: {{{2 178071d4279SBram Moolenaar" =============================================== 179071d4279SBram Moolenaarsyn match vimSpecFile "<c\(word\|WORD\)>" nextgroup=vimSpecFileMod,vimSubst 180071d4279SBram Moolenaarsyn match vimSpecFile "<\([acs]file\|amatch\|abuf\)>" nextgroup=vimSpecFileMod,vimSubst 181071d4279SBram Moolenaarsyn match vimSpecFile "\s%[ \t:]"ms=s+1,me=e-1 nextgroup=vimSpecFileMod,vimSubst 182071d4279SBram Moolenaarsyn match vimSpecFile "\s%$"ms=s+1 nextgroup=vimSpecFileMod,vimSubst 183071d4279SBram Moolenaarsyn match vimSpecFile "\s%<"ms=s+1,me=e-1 nextgroup=vimSpecFileMod,vimSubst 184071d4279SBram Moolenaarsyn match vimSpecFile "#\d\+\|[#%]<\>" nextgroup=vimSpecFileMod,vimSubst 185071d4279SBram Moolenaarsyn match vimSpecFileMod "\(:[phtre]\)\+" contained 186071d4279SBram Moolenaar 187cfbc5ee4SBram Moolenaar" User-Specified Commands: {{{2 188071d4279SBram Moolenaar" ======================= 1895c73622aSBram Moolenaarsyn 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 190071d4279SBram Moolenaarsyn keyword vimUserCommand contained com[mand] 191071d4279SBram Moolenaarsyn match vimUserCmd "\<com\%[mand]!\=\>.*$" contains=vimUserAttrb,vimUserCommand,@vimUserCmdList 192071d4279SBram Moolenaarsyn match vimUserAttrb contained "-n\%[args]=[01*?+]" contains=vimUserAttrbKey,vimOper 193071d4279SBram Moolenaarsyn match vimUserAttrb contained "-com\%[plete]=" contains=vimUserAttrbKey,vimOper nextgroup=vimUserAttrbCmplt,vimUserCmdError 194071d4279SBram Moolenaarsyn match vimUserAttrb contained "-ra\%[nge]\(=%\|=\d\+\)\=" contains=vimNumber,vimOper,vimUserAttrbKey 195071d4279SBram Moolenaarsyn match vimUserAttrb contained "-cou\%[nt]=\d\+" contains=vimNumber,vimOper,vimUserAttrbKey 196071d4279SBram Moolenaarsyn match vimUserAttrb contained "-bang\=\>" contains=vimOper,vimUserAttrbKey 197071d4279SBram Moolenaarsyn match vimUserAttrb contained "-bar\>" contains=vimOper,vimUserAttrbKey 198071d4279SBram Moolenaarsyn match vimUserAttrb contained "-re\%[gister]\>" contains=vimOper,vimUserAttrbKey 1993577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 200071d4279SBram Moolenaar syn match vimUserCmdError contained "\S\+\>" 201cfbc5ee4SBram Moolenaarendif 202071d4279SBram Moolenaarsyn case ignore 203071d4279SBram Moolenaarsyn keyword vimUserAttrbKey contained bar ban[g] cou[nt] ra[nge] com[plete] n[args] re[gister] 2045c73622aSBram Moolenaarsyn keyword vimUserAttrbCmplt contained augroup buffer command dir environment event expression file function help highlight mapping menu option shellcmd something tag tag_listfiles var 205a93fa7eeSBram Moolenaarsyn keyword vimUserAttrbCmplt contained custom customlist nextgroup=vimUserAttrbCmpltFunc,vimUserCmdError 2069964e468SBram Moolenaarsyn match vimUserAttrbCmpltFunc contained ",\%([sS]:\|<[sS][iI][dD]>\)\=\%(\h\w*\%(#\u\w*\)\+\|\u\w*\)"hs=s+1 nextgroup=vimUserCmdError 207a93fa7eeSBram Moolenaar 208071d4279SBram Moolenaarsyn case match 209071d4279SBram Moolenaarsyn match vimUserAttrbCmplt contained "custom,\u\w*" 210071d4279SBram Moolenaar 211cfbc5ee4SBram Moolenaar" Lower Priority Comments: after some vim commands... {{{2 212071d4279SBram Moolenaar" ======================= 213071d4279SBram Moolenaarsyn match vimComment excludenl +\s"[^\-:.%#=*].*$+lc=1 contains=@vimCommentGroup,vimCommentString 214071d4279SBram Moolenaarsyn match vimComment +\<endif\s\+".*$+lc=5 contains=@vimCommentGroup,vimCommentString 215071d4279SBram Moolenaarsyn match vimComment +\<else\s\+".*$+lc=4 contains=@vimCommentGroup,vimCommentString 2164770d09aSBram Moolenaarsyn region vimCommentString contained oneline start='\S\s\+"'ms=e end='"' 217071d4279SBram Moolenaar 218cfbc5ee4SBram Moolenaar" Environment Variables: {{{2 219071d4279SBram Moolenaar" ===================== 220071d4279SBram Moolenaarsyn match vimEnvvar "\$\I\i*" 221071d4279SBram Moolenaarsyn match vimEnvvar "\${\I\i*}" 222071d4279SBram Moolenaar 223cfbc5ee4SBram Moolenaar" In-String Specials: {{{2 224071d4279SBram Moolenaar" Try to catch strings, if nothing else matches (therefore it must precede the others!) 225071d4279SBram Moolenaar" vimEscapeBrace handles ["] []"] (ie. "s don't terminate string inside []) 226d68071d8SBram Moolenaarsyn region vimEscapeBrace oneline contained transparent start="[^\\]\(\\\\\)*\[\zs\^\=\]\=" skip="\\\\\|\\\]" end="]"me=e-1 227071d4279SBram Moolenaarsyn match vimPatSepErr contained "\\)" 228071d4279SBram Moolenaarsyn match vimPatSep contained "\\|" 229383f9bc3SBram Moolenaarsyn region vimPatSepZone oneline contained matchgroup=vimPatSepZ start="\\%\=\ze(" skip="\\\\" end="\\)\|[^\]['"]" contains=@vimStringGroup 230383f9bc3SBram Moolenaarsyn region vimPatRegion contained transparent matchgroup=vimPatSepR start="\\[z%]\=(" end="\\)" contains=@vimSubstList oneline 231071d4279SBram Moolenaarsyn match vimNotPatSep contained "\\\\" 2329964e468SBram Moolenaarsyn cluster vimStringGroup contains=vimEscapeBrace,vimPatSep,vimNotPatSep,vimPatSepErr,vimPatSepZone,@Spell 2335b8d8fdbSBram Moolenaarsyn region vimString oneline keepend start=+[^:a-zA-Z>!\\@]"+lc=1 skip=+\\\\\|\\"+ end=+"+ contains=@vimStringGroup 2348b6144bdSBram Moolenaarsyn region vimString oneline keepend start=+[^:a-zA-Z>!\\@]'+lc=1 end=+'+ 235071d4279SBram Moolenaarsyn region vimString oneline start=+=!+lc=1 skip=+\\\\\|\\!+ end=+!+ contains=@vimStringGroup 236071d4279SBram Moolenaarsyn region vimString oneline start="=+"lc=1 skip="\\\\\|\\+" end="+" contains=@vimStringGroup 237071d4279SBram Moolenaarsyn region vimString oneline start="\s/\s*\A"lc=1 skip="\\\\\|\\+" end="/" contains=@vimStringGroup 238071d4279SBram Moolenaarsyn match vimString contained +"[^"]*\\$+ skipnl nextgroup=vimStringCont 239071d4279SBram Moolenaarsyn match vimStringCont contained +\(\\\\\|.\)\{-}[^\\]"+ 240071d4279SBram Moolenaar 241cfbc5ee4SBram Moolenaar" Substitutions: {{{2 242071d4279SBram Moolenaar" ============= 243071d4279SBram Moolenaarsyn cluster vimSubstList contains=vimPatSep,vimPatRegion,vimPatSepErr,vimSubstTwoBS,vimSubstRange,vimNotation 244071d4279SBram Moolenaarsyn cluster vimSubstRepList contains=vimSubstSubstr,vimSubstTwoBS,vimNotation 245071d4279SBram Moolenaarsyn cluster vimSubstList add=vimCollection 246071d4279SBram Moolenaarsyn match vimSubst "\(:\+\s*\|^\s*\||\s*\)\<s\%[ubstitute][:[:alpha:]]\@!" nextgroup=vimSubstPat 2475c73622aSBram Moolenaarsyn match vimSubst "s\%[ubstitute][:#[:alpha:]]\@!" nextgroup=vimSubstPat contained 248071d4279SBram Moolenaarsyn match vimSubst "/\zss\%[ubstitute]\ze/" nextgroup=vimSubstPat 249071d4279SBram Moolenaarsyn match vimSubst1 contained "s\%[ubstitute]\>" nextgroup=vimSubstPat 250071d4279SBram Moolenaarsyn 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 251071d4279SBram Moolenaarsyn region vimSubstRep4 contained matchgroup=vimSubstDelim start="\z(.\)" skip="\\\\\|\\\z1" end="\z1" matchgroup=vimNotation end="<[cC][rR]>" contains=@vimSubstRepList nextgroup=vimSubstFlagErr oneline 252071d4279SBram Moolenaarsyn region vimCollection contained transparent start="\\\@<!\[" skip="\\\[" end="\]" contains=vimCollClass 253071d4279SBram Moolenaarsyn match vimCollClassErr contained "\[:.\{-\}:\]" 254071d4279SBram Moolenaarsyn match vimCollClass contained transparent "\[:\(alnum\|alpha\|blank\|cntrl\|digit\|graph\|lower\|print\|punct\|space\|upper\|xdigit\|return\|tab\|escape\|backspace\):\]" 255071d4279SBram Moolenaarsyn match vimSubstSubstr contained "\\z\=\d" 256071d4279SBram Moolenaarsyn match vimSubstTwoBS contained "\\\\" 257a5792f58SBram Moolenaarsyn match vimSubstFlagErr contained "[^< \t\r|]\+" contains=vimSubstFlags 258071d4279SBram Moolenaarsyn match vimSubstFlags contained "[&cegiIpr]\+" 259071d4279SBram Moolenaar 260cfbc5ee4SBram Moolenaar" 'String': {{{2 2618b6144bdSBram Moolenaarsyn match vimString "[^(,]'[^']\{-}\zs'" 262071d4279SBram Moolenaar 263cfbc5ee4SBram Moolenaar" Marks, Registers, Addresses, Filters: {{{2 264071d4279SBram Moolenaarsyn match vimMark "'[a-zA-Z0-9]\ze[-+,!]" nextgroup=vimOper,vimMarkNumber,vimSubst 265071d4279SBram Moolenaarsyn match vimMark "'[<>]\ze[-+,!]" nextgroup=vimOper,vimMarkNumber,vimSubst 266071d4279SBram Moolenaarsyn match vimMark ",\zs'[<>]\ze" nextgroup=vimOper,vimMarkNumber,vimSubst 267071d4279SBram Moolenaarsyn match vimMark "[!,:]\zs'[a-zA-Z0-9]" nextgroup=vimOper,vimMarkNumber,vimSubst 268071d4279SBram Moolenaarsyn match vimMark "\<norm\%[al]\s\zs'[a-zA-Z0-9]" nextgroup=vimOper,vimMarkNumber,vimSubst 269071d4279SBram Moolenaarsyn match vimMarkNumber "[-+]\d\+" nextgroup=vimSubst contained contains=vimOper 270071d4279SBram Moolenaarsyn match vimPlainMark contained "'[a-zA-Z0-9]" 271071d4279SBram Moolenaar 2725c73622aSBram Moolenaarsyn match vimRegister '[^,;[{]\zs"[a-zA-Z0-9.%#:_\-/]\ze[^a-zA-Z_":]' 2735b8d8fdbSBram Moolenaarsyn match vimRegister '\<norm\s\+\zs"[a-zA-Z0-9]' 2745b8d8fdbSBram Moolenaarsyn match vimRegister '\<normal\s\+\zs"[a-zA-Z0-9]' 275cfbc5ee4SBram Moolenaarsyn match vimRegister '@"' 276071d4279SBram Moolenaarsyn match vimPlainRegister contained '"[a-zA-Z0-9\-:.%#*+=]' 277071d4279SBram Moolenaar 2785b8d8fdbSBram Moolenaarsyn match vimAddress ",\zs[.$]" skipwhite nextgroup=vimSubst1 2795b8d8fdbSBram Moolenaarsyn match vimAddress "%\ze\a" skipwhite nextgroup=vimString,vimSubst1 280071d4279SBram Moolenaar 281071d4279SBram Moolenaarsyn match vimFilter contained "^!.\{-}\(|\|$\)" contains=vimSpecFile 282*d960d76dSBram Moolenaarsyn match vimFilter contained "\A!.\{-}\(|\|$\)"ms=s+1 contains=vimSpecFile,vimFunction,vimFuncName,vimOperParen 283071d4279SBram Moolenaar 284cfbc5ee4SBram Moolenaar" Complex repeats (:h complex-repeat) {{{2 2855c73622aSBram Moolenaarsyn match vimCmplxRepeat '[^a-zA-Z_/\\()]q[0-9a-zA-Z"]'lc=1 2865c73622aSBram Moolenaarsyn match vimCmplxRepeat '@[0-9a-z".=@:]\ze\($\|[^a-zA-Z]\)' 287071d4279SBram Moolenaar 288cfbc5ee4SBram Moolenaar" Set command and associated set-options (vimOptions) with comment {{{2 28974cbdf03SBram Moolenaarsyn 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 2905c73622aSBram Moolenaarsyn region vimSetEqual contained start="[=:]\|[-+^]=" skip="\\\\\|\\\s" end="[| \t]\|$"me=e-1 contains=vimCtrlChar,vimSetSep,vimNotation oneline 291071d4279SBram Moolenaarsyn region vimSetString contained start=+="+hs=s+1 skip=+\\\\\|\\"+ end=+"+ contains=vimCtrlChar 292071d4279SBram Moolenaarsyn match vimSetSep contained "[,:]" 2935c73622aSBram Moolenaarsyn match vimSetMod contained "&vim\=\|[!&?<]\|all&" 294071d4279SBram Moolenaar 295cfbc5ee4SBram Moolenaar" Let {{{2 296071d4279SBram Moolenaar" === 2975c73622aSBram Moolenaarsyn keyword vimLet let unl[et] skipwhite nextgroup=vimVar,vimFuncVar 298071d4279SBram Moolenaar 299e37d50a5SBram Moolenaar" Abbreviations {{{2 300e37d50a5SBram Moolenaar" ============= 301e37d50a5SBram Moolenaarsyn keyword vimAbb ab[breviate] ca[bbrev] inorea[bbrev] cnorea[bbrev] norea[bbrev] ia[bbrev] skipwhite nextgroup=vimMapMod,vimMapLhs 302e37d50a5SBram Moolenaar 303cfbc5ee4SBram Moolenaar" Autocmd {{{2 304071d4279SBram Moolenaar" ======= 305071d4279SBram Moolenaarsyn match vimAutoEventList contained "\(!\s\+\)\=\(\a\+,\)*\a\+" contains=vimAutoEvent nextgroup=vimAutoCmdSpace 306071d4279SBram Moolenaarsyn match vimAutoCmdSpace contained "\s\+" nextgroup=vimAutoCmdSfxList 307071d4279SBram Moolenaarsyn match vimAutoCmdSfxList contained "\S*" 308071d4279SBram Moolenaarsyn keyword vimAutoCmd au[tocmd] do[autocmd] doautoa[ll] skipwhite nextgroup=vimAutoEventList 309071d4279SBram Moolenaar 310cfbc5ee4SBram Moolenaar" Echo and Execute -- prefer strings! {{{2 311071d4279SBram Moolenaar" ================ 3125c73622aSBram Moolenaarsyn region vimEcho oneline excludenl matchgroup=vimCommand start="\<ec\%[ho]\>" skip="\(\\\\\)*\\|" end="$\||" contains=vimFunc,vimFuncVar,vimString,vimVar 3135c73622aSBram Moolenaarsyn region vimExecute oneline excludenl matchgroup=vimCommand start="\<exe\%[cute]\>" skip="\(\\\\\)*\\|" end="$\||\|<[cC][rR]>" contains=vimFuncVar,vimIsCommand,vimOper,vimNotation,vimOperParen,vimString,vimVar 314071d4279SBram Moolenaarsyn match vimEchoHL "echohl\=" skipwhite nextgroup=vimGroup,vimHLGroup,vimEchoHLNone 315071d4279SBram Moolenaarsyn case ignore 316071d4279SBram Moolenaarsyn keyword vimEchoHLNone none 317071d4279SBram Moolenaarsyn case match 318071d4279SBram Moolenaar 319cfbc5ee4SBram Moolenaar" Maps {{{2 320071d4279SBram Moolenaar" ==== 3213577c6faSBram Moolenaarsyn match vimMap "\<map\>!\=\ze\s*[^(]" skipwhite nextgroup=vimMapMod,vimMapLhs 3225c73622aSBram Moolenaarsyn 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 32381af9250SBram Moolenaarsyn keyword vimMap mapc[lear] smapc[lear] 3245c73622aSBram Moolenaarsyn 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 325b8a7b560SBram Moolenaarsyn match vimMapLhs contained "\S\+" contains=vimNotation,vimCtrlChar skipwhite nextgroup=vimMapRhs 326b8a7b560SBram Moolenaarsyn match vimMapBang contained "!" skipwhite nextgroup=vimMapMod,vimMapLhs 32725e2c9e3SBram Moolenaarsyn match vimMapMod contained "\c<\(buffer\|expr\|\(local\)\=leader\|plug\|script\|sid\|unique\|silent\)\+>" contains=vimMapModKey,vimMapModErr skipwhite nextgroup=vimMapMod,vimMapLhs 328b8a7b560SBram Moolenaarsyn match vimMapRhs contained ".*" contains=vimNotation,vimCtrlChar skipnl nextgroup=vimMapRhsExtend 329b8a7b560SBram Moolenaarsyn match vimMapRhsExtend contained "^\s*\\.*$" contains=vimContinue 330071d4279SBram Moolenaarsyn case ignore 33125e2c9e3SBram Moolenaarsyn keyword vimMapModKey contained buffer expr leader localleader plug script sid silent unique 332071d4279SBram Moolenaarsyn case match 333071d4279SBram Moolenaar 334cfbc5ee4SBram Moolenaar" Menus {{{2 335071d4279SBram Moolenaar" ===== 336071d4279SBram Moolenaarsyn cluster vimMenuList contains=vimMenuBang,vimMenuPriority,vimMenuName,vimMenuMod 337071d4279SBram Moolenaarsyn 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 338071d4279SBram Moolenaarsyn match vimMenuName "[^ \t\\<]\+" contained nextgroup=vimMenuNameMore,vimMenuMap 339071d4279SBram Moolenaarsyn match vimMenuPriority "\d\+\(\.\d\+\)*" contained skipwhite nextgroup=vimMenuName 340071d4279SBram Moolenaarsyn match vimMenuNameMore "\c\\\s\|<tab>\|\\\." contained nextgroup=vimMenuName,vimMenuNameMore contains=vimNotation 341071d4279SBram Moolenaarsyn match vimMenuMod contained "\c<\(script\|silent\)\+>" skipwhite contains=vimMapModKey,vimMapModErr nextgroup=@vimMenuList 342071d4279SBram Moolenaarsyn match vimMenuMap "\s" contained skipwhite nextgroup=vimMenuRhs 343071d4279SBram Moolenaarsyn match vimMenuRhs ".*$" contained contains=vimString,vimComment,vimIsCommand 344071d4279SBram Moolenaarsyn match vimMenuBang "!" contained skipwhite nextgroup=@vimMenuList 345071d4279SBram Moolenaar 346cfbc5ee4SBram Moolenaar" Angle-Bracket Notation (tnx to Michael Geddes) {{{2 347071d4279SBram Moolenaar" ====================== 348071d4279SBram Moolenaarsyn case ignore 3499964e468SBram Moolenaarsyn match vimNotation "\(\\\|<lt>\)\=<\([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\|space\|k\=\(page\)\=\(\|down\|up\)\)>" contains=vimBracket 350071d4279SBram Moolenaarsyn match vimNotation "\(\\\|<lt>\)\=<\([scam2-4]-\)\{0,4}\(right\|left\|middle\)\(mouse\)\=\(drag\|release\)\=>" contains=vimBracket 351071d4279SBram Moolenaarsyn match vimNotation "\(\\\|<lt>\)\=<\(bslash\|plug\|sid\|space\|bar\|nop\|nul\|lt\)>" contains=vimBracket 352071d4279SBram Moolenaarsyn match vimNotation '\(\\\|<lt>\)\=<C-R>[0-9a-z"%#:.\-=]'he=e-1 contains=vimBracket 353d68071d8SBram Moolenaarsyn match vimNotation '\(\\\|<lt>\)\=<\%(q-\)\=\(line[12]\|count\|bang\|reg\|args\|f-args\|lt\)>' contains=vimBracket 354071d4279SBram Moolenaarsyn match vimNotation "\(\\\|<lt>\)\=<\([cas]file\|abuf\|amatch\|cword\|cWORD\|client\)>" contains=vimBracket 355071d4279SBram Moolenaarsyn match vimBracket contained "[\\<>]" 356071d4279SBram Moolenaarsyn case match 357071d4279SBram Moolenaar 3583577c6faSBram Moolenaar" User Function Highlighting {{{2 3593577c6faSBram Moolenaar" (following Gautam Iyer's suggestion) 360071d4279SBram Moolenaar" ========================== 3615c73622aSBram Moolenaarsyn match vimFunc "\%(\%([sSgGbBwWtTlL]:\|<[sS][iI][dD]>\)\=\%([a-zA-Z0-9_.]\+\.\)*\I[a-zA-Z0-9_.]*\)\ze\s*(" contains=vimFuncName,vimUserFunc,vimExecute 3625c73622aSBram Moolenaarsyn match vimUserFunc contained "\%(\%([sSgGbBwWtTlL]:\|<[sS][iI][dD]>\)\=\%([a-zA-Z0-9_.]\+\.\)*\I[a-zA-Z0-9_.]*\)\|\<\u[a-zA-Z0-9.]*\>\|\<if\>" contains=vimNotation 3635c73622aSBram Moolenaarsyn match vimNotFunc "\<if\>\|\<el\%[seif]\>\|\<return\>\|\<while\>" 364071d4279SBram Moolenaar 3653577c6faSBram Moolenaar" Errors And Warnings: {{{2 3663577c6faSBram Moolenaar" ==================== 3673577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 3685c73622aSBram Moolenaar syn match vimFunctionError "\s\zs[a-z0-9]\i\{-}\ze\s*(" contained contains=vimFuncKey,vimFuncBlank 3695c73622aSBram Moolenaar" syn match vimFunctionError "\s\zs\%(<[sS][iI][dD]>\|[sSgGbBwWtTlL]:\)[0-9]\i\{-}\ze\s*(" contained contains=vimFuncKey,vimFuncBlank 3703577c6faSBram Moolenaar syn match vimElseIfErr "\<else\s\+if\>" 3713577c6faSBram Moolenaar syn match vimBufnrWarn /\<bufnr\s*(\s*["']\.['"]\s*)/ 3723577c6faSBram Moolenaarendif 3733577c6faSBram Moolenaar 3743577c6faSBram Moolenaar" Norm {{{2 37505159a0cSBram Moolenaar" ==== 37605159a0cSBram Moolenaarsyn match vimNorm "\<norm\%[al]!\=" skipwhite nextgroup=vimNormCmds 37705159a0cSBram Moolenaarsyn match vimNormCmds contained ".*$" 37805159a0cSBram Moolenaar 379cfbc5ee4SBram Moolenaar" Syntax {{{2 380071d4279SBram Moolenaar"======= 381071d4279SBram Moolenaarsyn match vimGroupList contained "@\=[^ \t,]*" contains=vimGroupSpecial,vimPatSep 382071d4279SBram Moolenaarsyn match vimGroupList contained "@\=[^ \t,]*," nextgroup=vimGroupList contains=vimGroupSpecial,vimPatSep 3835c73622aSBram Moolenaarsyn keyword vimGroupSpecial contained ALL ALLBUT CONTAINED TOP 3843577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 385071d4279SBram Moolenaar syn match vimSynError contained "\i\+" 386071d4279SBram Moolenaar syn match vimSynError contained "\i\+=" nextgroup=vimGroupList 387cfbc5ee4SBram Moolenaarendif 388071d4279SBram Moolenaarsyn match vimSynContains contained "\<contain\(s\|edin\)=" nextgroup=vimGroupList 389071d4279SBram Moolenaarsyn match vimSynKeyContainedin contained "\<containedin=" nextgroup=vimGroupList 390071d4279SBram Moolenaarsyn match vimSynNextgroup contained "nextgroup=" nextgroup=vimGroupList 391071d4279SBram Moolenaar 392071d4279SBram Moolenaarsyn match vimSyntax "\<sy\%[ntax]\>" contains=vimCommand skipwhite nextgroup=vimSynType,vimComment 393071d4279SBram Moolenaarsyn match vimAuSyntax contained "\s+sy\%[ntax]" contains=vimCommand skipwhite nextgroup=vimSynType,vimComment 394*d960d76dSBram Moolenaarsyn cluster vimFuncBodyList add=vimSyntax 395071d4279SBram Moolenaar 396cfbc5ee4SBram Moolenaar" Syntax: case {{{2 397071d4279SBram Moolenaarsyn keyword vimSynType contained case skipwhite nextgroup=vimSynCase,vimSynCaseError 3983577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 399071d4279SBram Moolenaar syn match vimSynCaseError contained "\i\+" 400cfbc5ee4SBram Moolenaarendif 401071d4279SBram Moolenaarsyn keyword vimSynCase contained ignore match 402071d4279SBram Moolenaar 403cfbc5ee4SBram Moolenaar" Syntax: clear {{{2 404071d4279SBram Moolenaarsyn keyword vimSynType contained clear skipwhite nextgroup=vimGroupList 405071d4279SBram Moolenaar 406cfbc5ee4SBram Moolenaar" Syntax: cluster {{{2 407071d4279SBram Moolenaarsyn keyword vimSynType contained cluster skipwhite nextgroup=vimClusterName 408071d4279SBram Moolenaarsyn region vimClusterName contained matchgroup=vimGroupName start="\k\+" skip="\\\\\|\\|" matchgroup=vimSep end="$\||" contains=vimGroupAdd,vimGroupRem,vimSynContains,vimSynError 409071d4279SBram Moolenaarsyn match vimGroupAdd contained "add=" nextgroup=vimGroupList 410071d4279SBram Moolenaarsyn match vimGroupRem contained "remove=" nextgroup=vimGroupList 411*d960d76dSBram Moolenaarsyn cluster vimFuncBodyList add=vimSynType,vimGroupAdd,vimGroupRem 412071d4279SBram Moolenaar 413cfbc5ee4SBram Moolenaar" Syntax: include {{{2 414071d4279SBram Moolenaarsyn keyword vimSynType contained include skipwhite nextgroup=vimGroupList 415*d960d76dSBram Moolenaarsyn cluster vimFuncBodyList add=vimSynType 416071d4279SBram Moolenaar 417cfbc5ee4SBram Moolenaar" Syntax: keyword {{{2 418071d4279SBram Moolenaarsyn cluster vimSynKeyGroup contains=vimSynNextgroup,vimSynKeyOpt,vimSynKeyContainedin 419071d4279SBram Moolenaarsyn keyword vimSynType contained keyword skipwhite nextgroup=vimSynKeyRegion 4203577c6faSBram Moolenaarsyn region vimSynKeyRegion contained oneline keepend matchgroup=vimGroupName start="\k\+" skip="\\\\\|\\|" matchgroup=vimSep end="|\|$" contains=@vimSynKeyGroup 421071d4279SBram Moolenaarsyn match vimSynKeyOpt contained "\<\(conceal\|contained\|transparent\|skipempty\|skipwhite\|skipnl\)\>" 422*d960d76dSBram Moolenaarsyn cluster vimFuncBodyList add=vimSynType 423071d4279SBram Moolenaar 424cfbc5ee4SBram Moolenaar" Syntax: match {{{2 425071d4279SBram Moolenaarsyn cluster vimSynMtchGroup contains=vimMtchComment,vimSynContains,vimSynError,vimSynMtchOpt,vimSynNextgroup,vimSynRegPat,vimNotation 426071d4279SBram Moolenaarsyn keyword vimSynType contained match skipwhite nextgroup=vimSynMatchRegion 427071d4279SBram Moolenaarsyn region vimSynMatchRegion contained keepend matchgroup=vimGroupName start="\k\+" matchgroup=vimSep end="|\|$" contains=@vimSynMtchGroup 428071d4279SBram Moolenaarsyn match vimSynMtchOpt contained "\<\(conceal\|transparent\|contained\|excludenl\|skipempty\|skipwhite\|display\|extend\|skipnl\|fold\)\>" 429071d4279SBram Moolenaarif has("conceal") 430071d4279SBram Moolenaar syn match vimSynMtchOpt contained "\<cchar=" nextgroup=VimSynMtchCchar 4315c73622aSBram Moolenaar syn match vimSynMtchCchar contained "\S" 432071d4279SBram Moolenaarendif 433*d960d76dSBram Moolenaarsyn cluster vimFuncBodyList add=vimSynMtchGroup 434071d4279SBram Moolenaar 435cfbc5ee4SBram Moolenaar" Syntax: off and on {{{2 436071d4279SBram Moolenaarsyn keyword vimSynType contained enable list manual off on reset 437071d4279SBram Moolenaar 438cfbc5ee4SBram Moolenaar" Syntax: region {{{2 439071d4279SBram Moolenaarsyn cluster vimSynRegPatGroup contains=vimPatSep,vimNotPatSep,vimSynPatRange,vimSynNotPatRange,vimSubstSubstr,vimPatRegion,vimPatSepErr,vimNotation 440071d4279SBram Moolenaarsyn cluster vimSynRegGroup contains=vimSynContains,vimSynNextgroup,vimSynRegOpt,vimSynReg,vimSynMtchGrp 441071d4279SBram Moolenaarsyn keyword vimSynType contained region skipwhite nextgroup=vimSynRegion 442071d4279SBram Moolenaarsyn region vimSynRegion contained keepend matchgroup=vimGroupName start="\k\+" skip="\\\\\|\\|" end="|\|$" contains=@vimSynRegGroup 443071d4279SBram Moolenaarsyn match vimSynRegOpt contained "\<\(conceal\(ends\)\=\|transparent\|contained\|excludenl\|skipempty\|skipwhite\|display\|keepend\|oneline\|extend\|skipnl\|fold\)\>" 444071d4279SBram Moolenaarsyn match vimSynReg contained "\(start\|skip\|end\)="he=e-1 nextgroup=vimSynRegPat 445071d4279SBram Moolenaarsyn match vimSynMtchGrp contained "matchgroup=" nextgroup=vimGroup,vimHLGroup 446071d4279SBram Moolenaarsyn region vimSynRegPat contained extend start="\z([-`~!@#$%^&*_=+;:'",./?]\)" skip="\\\\\|\\\z1" end="\z1" contains=@vimSynRegPatGroup skipwhite nextgroup=vimSynPatMod,vimSynReg 447071d4279SBram Moolenaarsyn match vimSynPatMod contained "\(hs\|ms\|me\|hs\|he\|rs\|re\)=[se]\([-+]\d\+\)\=" 448071d4279SBram Moolenaarsyn match vimSynPatMod contained "\(hs\|ms\|me\|hs\|he\|rs\|re\)=[se]\([-+]\d\+\)\=," nextgroup=vimSynPatMod 449071d4279SBram Moolenaarsyn match vimSynPatMod contained "lc=\d\+" 450071d4279SBram Moolenaarsyn match vimSynPatMod contained "lc=\d\+," nextgroup=vimSynPatMod 451071d4279SBram Moolenaarsyn region vimSynPatRange contained start="\[" skip="\\\\\|\\]" end="]" 452071d4279SBram Moolenaarsyn match vimSynNotPatRange contained "\\\\\|\\\[" 453071d4279SBram Moolenaarsyn match vimMtchComment contained '"[^"]\+$' 454*d960d76dSBram Moolenaarsyn cluster vimFuncBodyList add=vimSynType 455071d4279SBram Moolenaar 456cfbc5ee4SBram Moolenaar" Syntax: sync {{{2 457071d4279SBram Moolenaar" ============ 458df177f67SBram Moolenaarsyn keyword vimSynType contained sync skipwhite nextgroup=vimSyncC,vimSyncLines,vimSyncMatch,vimSyncError,vimSyncLinebreak,vimSyncLinecont,vimSyncRegion 4593577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 460071d4279SBram Moolenaar syn match vimSyncError contained "\i\+" 461cfbc5ee4SBram Moolenaarendif 462071d4279SBram Moolenaarsyn keyword vimSyncC contained ccomment clear fromstart 463071d4279SBram Moolenaarsyn keyword vimSyncMatch contained match skipwhite nextgroup=vimSyncGroupName 464071d4279SBram Moolenaarsyn keyword vimSyncRegion contained region skipwhite nextgroup=vimSynReg 465df177f67SBram Moolenaarsyn match vimSyncLinebreak contained "\<linebreaks=" skipwhite nextgroup=vimNumber 466071d4279SBram Moolenaarsyn keyword vimSyncLinecont contained linecont skipwhite nextgroup=vimSynRegPat 467071d4279SBram Moolenaarsyn match vimSyncLines contained "\(min\|max\)\=lines=" nextgroup=vimNumber 468071d4279SBram Moolenaarsyn match vimSyncGroupName contained "\k\+" skipwhite nextgroup=vimSyncKey 469071d4279SBram Moolenaarsyn match vimSyncKey contained "\<groupthere\|grouphere\>" skipwhite nextgroup=vimSyncGroup 470071d4279SBram Moolenaarsyn match vimSyncGroup contained "\k\+" skipwhite nextgroup=vimSynRegPat,vimSyncNone 471071d4279SBram Moolenaarsyn keyword vimSyncNone contained NONE 472071d4279SBram Moolenaar 473cfbc5ee4SBram Moolenaar" Additional IsCommand, here by reasons of precedence {{{2 474071d4279SBram Moolenaar" ==================== 475071d4279SBram Moolenaarsyn match vimIsCommand "<Bar>\s*\a\+" transparent contains=vimCommand,vimNotation 476071d4279SBram Moolenaar 477cfbc5ee4SBram Moolenaar" Highlighting {{{2 478071d4279SBram Moolenaar" ============ 479071d4279SBram Moolenaarsyn cluster vimHighlightCluster contains=vimHiLink,vimHiClear,vimHiKeyList,vimComment 480071d4279SBram Moolenaarsyn match vimHighlight "\<hi\%[ghlight]\>" skipwhite nextgroup=vimHiBang,@vimHighlightCluster 481071d4279SBram Moolenaarsyn match vimHiBang contained "!" skipwhite nextgroup=@vimHighlightCluster 482071d4279SBram Moolenaar 483071d4279SBram Moolenaarsyn match vimHiGroup contained "\i\+" 484071d4279SBram Moolenaarsyn case ignore 4854770d09aSBram Moolenaarsyn keyword vimHiAttrib contained none bold inverse italic reverse standout underline undercurl 486071d4279SBram Moolenaarsyn keyword vimFgBgAttrib contained none bg background fg foreground 487071d4279SBram Moolenaarsyn case match 488071d4279SBram Moolenaarsyn match vimHiAttribList contained "\i\+" contains=vimHiAttrib 489071d4279SBram Moolenaarsyn match vimHiAttribList contained "\i\+,"he=e-1 contains=vimHiAttrib nextgroup=vimHiAttribList 490071d4279SBram Moolenaarsyn case ignore 491071d4279SBram Moolenaarsyn 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 492071d4279SBram Moolenaar 493071d4279SBram Moolenaarsyn case match 494071d4279SBram Moolenaarsyn match vimHiFontname contained "[a-zA-Z\-*]\+" 495071d4279SBram Moolenaarsyn match vimHiGuiFontname contained "'[a-zA-Z\-* ]\+'" 496071d4279SBram Moolenaarsyn match vimHiGuiRgb contained "#\x\{6}" 4973577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 498071d4279SBram Moolenaar syn match vimHiCtermError contained "[^0-9]\i*" 499cfbc5ee4SBram Moolenaarendif 500071d4279SBram Moolenaar 501cfbc5ee4SBram Moolenaar" Highlighting: hi group key=arg ... {{{2 5025c73622aSBram Moolenaarsyn cluster vimHiCluster contains=vimGroup,vimHiGroup,vimHiTerm,vimHiCTerm,vimHiStartStop,vimHiCtermFgBg,vimHiGui,vimHiGuiFont,vimHiGuiFgBg,vimHiKeyError,vimNotation 503071d4279SBram Moolenaarsyn region vimHiKeyList contained oneline start="\i\+" skip="\\\\\|\\|" end="$\||" contains=@vimHiCluster 5043577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 505071d4279SBram Moolenaar syn match vimHiKeyError contained "\i\+="he=e-1 506cfbc5ee4SBram Moolenaarendif 507071d4279SBram Moolenaarsyn match vimHiTerm contained "\cterm="he=e-1 nextgroup=vimHiAttribList 508071d4279SBram Moolenaarsyn match vimHiStartStop contained "\c\(start\|stop\)="he=e-1 nextgroup=vimHiTermcap,vimOption 509071d4279SBram Moolenaarsyn match vimHiCTerm contained "\ccterm="he=e-1 nextgroup=vimHiAttribList 510071d4279SBram Moolenaarsyn match vimHiCtermFgBg contained "\ccterm[fb]g="he=e-1 nextgroup=vimNumber,vimHiCtermColor,vimFgBgAttrib,vimHiCtermError 511071d4279SBram Moolenaarsyn match vimHiGui contained "\cgui="he=e-1 nextgroup=vimHiAttribList 512071d4279SBram Moolenaarsyn match vimHiGuiFont contained "\cfont="he=e-1 nextgroup=vimHiFontname 5134770d09aSBram Moolenaarsyn match vimHiGuiFgBg contained "\cgui\%([fb]g\|sp\)="he=e-1 nextgroup=vimHiGroup,vimHiGuiFontname,vimHiGuiRgb,vimFgBgAttrib 514071d4279SBram Moolenaarsyn match vimHiTermcap contained "\S\+" contains=vimNotation 515071d4279SBram Moolenaar 516cfbc5ee4SBram Moolenaar" Highlight: clear {{{2 517071d4279SBram Moolenaarsyn keyword vimHiClear contained clear nextgroup=vimHiGroup 518071d4279SBram Moolenaar 519cfbc5ee4SBram Moolenaar" Highlight: link {{{2 520*d960d76dSBram Moolenaarsyn region vimHiLink contained oneline matchgroup=vimCommand start="\<\(def\%[ault]\s\+\)\=link\>\|\<def\>" end="$" contains=vimHiGroup,vimGroup,vimHLGroup,vimNotation 521*d960d76dSBram Moolenaarsyn cluster vimFuncBodyList add=vimHiLink 522071d4279SBram Moolenaar 523cfbc5ee4SBram Moolenaar" Control Characters {{{2 524071d4279SBram Moolenaar" ================== 525071d4279SBram Moolenaarsyn match vimCtrlChar "[--]" 526071d4279SBram Moolenaar 527cfbc5ee4SBram Moolenaar" Beginners - Patterns that involve ^ {{{2 528071d4279SBram Moolenaar" ========= 529071d4279SBram Moolenaarsyn match vimLineComment +^[ \t:]*".*$+ contains=@vimCommentGroup,vimCommentString,vimCommentTitle 530ff1d0d4cSBram Moolenaarsyn match vimCommentTitle '"\s*\%([sS]:\|\h\w*#\)\=\u\w*\(\s\+\u\w*\)*:'hs=s+1 contained contains=vimCommentTitleLeader,vimTodo,@vimCommentGroup 531071d4279SBram Moolenaarsyn match vimContinue "^\s*\\" 532071d4279SBram Moolenaarsyn region vimString start="^\s*\\\z(['"]\)" skip='\\\\\|\\\z1' end="\z1" oneline keepend contains=@vimStringGroup,vimContinue 533071d4279SBram Moolenaarsyn match vimCommentTitleLeader '"\s\+'ms=s+1 contained 534071d4279SBram Moolenaar 53518144c84SBram Moolenaar" Searches And Globals: {{{2 53618144c84SBram Moolenaar" ==================== 537e2f98b95SBram Moolenaarsyn match vimSearch '^\s*[/?].*' contains=vimSearchDelim 538e2f98b95SBram Moolenaarsyn match vimSearchDelim '^\s*\zs[/?]\|[/?]$' contained 53918144c84SBram Moolenaarsyn region vimGlobal matchgroup=Statement start='\<g\%[lobal]!\=/' skip='\\.' end='/' 54018144c84SBram Moolenaarsyn region vimGlobal matchgroup=Statement start='\<v\%[global]!\=/' skip='\\.' end='/' 541e2f98b95SBram Moolenaar 542cfbc5ee4SBram Moolenaar" Scripts : perl,ruby : Benoit Cerrina {{{2 543071d4279SBram Moolenaar" ======= python,tcl: Johannes Zellner 5444b22cdb0SBram Moolenaar" lua 545071d4279SBram Moolenaar 5463577c6faSBram Moolenaar" Allows users to specify the type of embedded script highlighting 5473577c6faSBram Moolenaar" they want: (perl/python/ruby/tcl support) 5483577c6faSBram Moolenaar" g:vimsyn_embed == 0 : don't embed any scripts 5494b22cdb0SBram Moolenaar" g:vimsyn_embed ~= 'l' : embed lua (but only if vim supports it) 5503577c6faSBram Moolenaar" g:vimsyn_embed ~= 'm' : embed mzscheme (but only if vim supports it) 5513577c6faSBram Moolenaar" g:vimsyn_embed ~= 'p' : embed perl (but only if vim supports it) 5523577c6faSBram Moolenaar" g:vimsyn_embed ~= 'P' : embed python (but only if vim supports it) 5533577c6faSBram Moolenaar" g:vimsyn_embed ~= 'r' : embed ruby (but only if vim supports it) 5543577c6faSBram Moolenaar" g:vimsyn_embed ~= 't' : embed tcl (but only if vim supports it) 5553577c6faSBram Moolenaarif !exists("g:vimsyn_embed") 5564b22cdb0SBram Moolenaar let g:vimsyn_embed= "lmpPr" 557071d4279SBram Moolenaarendif 558071d4279SBram Moolenaar 5594b22cdb0SBram Moolenaar" [-- lua --] {{{3 560adc2182cSBram Moolenaarlet s:luapath= fnameescape(expand("<sfile>:p:h")."/lua.vim") 5614b22cdb0SBram Moolenaarif !filereadable(s:luapath) 562adc2182cSBram Moolenaar let s:luapath= fnameescape(globpath(&rtp,"syntax/lua.vim")) 5634b22cdb0SBram Moolenaarendif 56481af9250SBram Moolenaarif (g:vimsyn_embed =~ 'l' && has("lua")) && filereadable(s:luapath) 5654b22cdb0SBram Moolenaar unlet! b:current_syntax 5664b22cdb0SBram Moolenaar exe "syn include @vimLuaScript ".s:luapath 5674b22cdb0SBram Moolenaar if exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'l' 5684b22cdb0SBram Moolenaar syn region vimLuaRegion fold matchgroup=vimScriptDelim start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimLuaScript 5694b22cdb0SBram Moolenaar syn region vimLuaRegion fold matchgroup=vimScriptDelim start=+lua\s*<<\s*$+ end=+\.$+ contains=@vimLuaScript 5704b22cdb0SBram Moolenaar else 5714b22cdb0SBram Moolenaar syn region vimLuaRegion matchgroup=vimScriptDelim start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimLuaScript 5724b22cdb0SBram Moolenaar syn region vimLuaRegion matchgroup=vimScriptDelim start=+lua\s*<<\s*$+ end=+\.$+ contains=@vimLuaScript 5734b22cdb0SBram Moolenaar endif 5744b22cdb0SBram Moolenaar syn cluster vimFuncBodyList add=vimLuaRegion 5754b22cdb0SBram Moolenaarelse 5764b22cdb0SBram Moolenaar syn region vimEmbedError start=+lua\s*<<\s*\z(.*\)$+ end=+^\z1$+ 5774b22cdb0SBram Moolenaar syn region vimEmbedError start=+lua\s*<<\s*$+ end=+\.$+ 5784b22cdb0SBram Moolenaarendif 5794b22cdb0SBram Moolenaarunlet s:luapath 5804b22cdb0SBram Moolenaar 581cfbc5ee4SBram Moolenaar" [-- perl --] {{{3 582adc2182cSBram Moolenaarlet s:perlpath= fnameescape(expand("<sfile>:p:h")."/perl.vim") 5835c73622aSBram Moolenaarif !filereadable(s:perlpath) 584adc2182cSBram Moolenaar let s:perlpath= fnameescape(globpath(&rtp,"syntax/perl.vim")) 5855c73622aSBram Moolenaarendif 5865c73622aSBram Moolenaarif (g:vimsyn_embed =~ 'p' && has("perl")) && filereadable(s:perlpath) 587071d4279SBram Moolenaar unlet! b:current_syntax 5885c73622aSBram Moolenaar exe "syn include @vimPerlScript ".s:perlpath 5893577c6faSBram Moolenaar if exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'p' 5903577c6faSBram Moolenaar syn region vimPerlRegion fold matchgroup=vimScriptDelim start=+pe\%[rl]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimPerlScript 5913577c6faSBram Moolenaar syn region vimPerlRegion fold matchgroup=vimScriptDelim start=+pe\%[rl]\s*<<\s*$+ end=+\.$+ contains=@vimPerlScript 5923577c6faSBram Moolenaar else 593071d4279SBram Moolenaar syn region vimPerlRegion matchgroup=vimScriptDelim start=+pe\%[rl]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimPerlScript 594071d4279SBram Moolenaar syn region vimPerlRegion matchgroup=vimScriptDelim start=+pe\%[rl]\s*<<\s*$+ end=+\.$+ contains=@vimPerlScript 595071d4279SBram Moolenaar endif 5965c73622aSBram Moolenaar syn cluster vimFuncBodyList add=vimPerlRegion 597c236c16dSBram Moolenaarelse 598c236c16dSBram Moolenaar syn region vimEmbedError start=+pe\%[rl]\s*<<\s*\z(.*\)$+ end=+^\z1$+ 599c236c16dSBram Moolenaar syn region vimEmbedError start=+pe\%[rl]\s*<<\s*$+ end=+\.$+ 6003577c6faSBram Moolenaarendif 6015c73622aSBram Moolenaarunlet s:perlpath 602071d4279SBram Moolenaar 603cfbc5ee4SBram Moolenaar" [-- ruby --] {{{3 604adc2182cSBram Moolenaarlet s:rubypath= fnameescape(expand("<sfile>:p:h")."/ruby.vim") 6055c73622aSBram Moolenaarif !filereadable(s:rubypath) 606adc2182cSBram Moolenaar let s:rubypath= fnameescape(globpath(&rtp,"syntax/ruby.vim")) 6075c73622aSBram Moolenaarendif 6085c73622aSBram Moolenaarif (g:vimsyn_embed =~ 'r' && has("ruby")) && filereadable(s:rubypath) 609071d4279SBram Moolenaar unlet! b:current_syntax 6105c73622aSBram Moolenaar exe "syn include @vimRubyScript ".s:rubypath 6113577c6faSBram Moolenaar if exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'r' 6123577c6faSBram Moolenaar syn region vimRubyRegion fold matchgroup=vimScriptDelim start=+rub[y]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimRubyScript 6133577c6faSBram Moolenaar else 614c236c16dSBram Moolenaar syn region vimRubyRegion matchgroup=vimScriptDelim start=+rub[y]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimRubyScript 6153577c6faSBram Moolenaar endif 616071d4279SBram Moolenaar syn region vimRubyRegion matchgroup=vimScriptDelim start=+rub[y]\s*<<\s*$+ end=+\.$+ contains=@vimRubyScript 6175c73622aSBram Moolenaar syn cluster vimFuncBodyList add=vimRubyRegion 618c236c16dSBram Moolenaarelse 619c236c16dSBram Moolenaar syn region vimEmbedError start=+rub[y]\s*<<\s*\z(.*\)$+ end=+^\z1$+ 620c236c16dSBram Moolenaar syn region vimEmbedError start=+rub[y]\s*<<\s*$+ end=+\.$+ 621071d4279SBram Moolenaarendif 6225c73622aSBram Moolenaarunlet s:rubypath 623071d4279SBram Moolenaar 624cfbc5ee4SBram Moolenaar" [-- python --] {{{3 625adc2182cSBram Moolenaarlet s:pythonpath= fnameescape(expand("<sfile>:p:h")."/python.vim") 6265c73622aSBram Moolenaarif !filereadable(s:pythonpath) 627adc2182cSBram Moolenaar let s:pythonpath= fnameescape(globpath(&rtp,"syntax/python.vim")) 6285c73622aSBram Moolenaarendif 6295c73622aSBram Moolenaarif (g:vimsyn_embed =~ 'P' && has("python")) && filereadable(s:pythonpath) 630071d4279SBram Moolenaar unlet! b:current_syntax 6315c73622aSBram Moolenaar exe "syn include @vimPythonScript ".s:pythonpath 6323577c6faSBram Moolenaar if exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'P' 633fa01c39dSBram Moolenaar syn region vimPythonRegion fold matchgroup=vimScriptDelim start=+py\%[thon]3\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimPythonScript 634fa01c39dSBram Moolenaar syn region vimPythonRegion fold matchgroup=vimScriptDelim start=+py\%[thon]3\=\s*<<\s*$+ end=+\.$+ contains=@vimPythonScript 6353577c6faSBram Moolenaar else 636fa01c39dSBram Moolenaar syn region vimPythonRegion matchgroup=vimScriptDelim start=+py\%[thon]3\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimPythonScript 637fa01c39dSBram Moolenaar syn region vimPythonRegion matchgroup=vimScriptDelim start=+py\%[thon]3\=\s*<<\s*$+ end=+\.$+ contains=@vimPythonScript 638071d4279SBram Moolenaar endif 6395c73622aSBram Moolenaar syn cluster vimFuncBodyList add=vimPythonRegion 640c236c16dSBram Moolenaarelse 641fa01c39dSBram Moolenaar syn region vimEmbedError start=+py\%[thon]3\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ 642fa01c39dSBram Moolenaar syn region vimEmbedError start=+py\%[thon]3\=\s*<<\s*$+ end=+\.$+ 6433577c6faSBram Moolenaarendif 6445c73622aSBram Moolenaarunlet s:pythonpath 645071d4279SBram Moolenaar 646cfbc5ee4SBram Moolenaar" [-- tcl --] {{{3 6479964e468SBram Moolenaarif has("win32") || has("win95") || has("win64") || has("win16") 6489964e468SBram Moolenaar " apparently has("tcl") has been hanging vim on some windows systems with cygwin 6495c73622aSBram Moolenaar let s:trytcl= (&shell !~ '\<\%(bash\>\|4[nN][tT]\|\<zsh\)\>\%(\.exe\)\=$') 6509964e468SBram Moolenaarelse 6515c73622aSBram Moolenaar let s:trytcl= 1 6529964e468SBram Moolenaarendif 6535c73622aSBram Moolenaarif s:trytcl 654adc2182cSBram Moolenaar let s:tclpath= fnameescape(expand("<sfile>:p:h")."/tcl.vim") 6555c73622aSBram Moolenaar if !filereadable(s:tclpath) 656adc2182cSBram Moolenaar let s:tclpath= fnameescape(globpath(&rtp,"syntax/tcl.vim")) 6575c73622aSBram Moolenaar endif 6585c73622aSBram Moolenaar if (g:vimsyn_embed =~ 't' && has("tcl")) && filereadable(s:tclpath) 659071d4279SBram Moolenaar unlet! b:current_syntax 6605c73622aSBram Moolenaar exe "syn include @vimTclScript ".s:tclpath 6613577c6faSBram Moolenaar if exists("g:vimsyn_folding") && g:vimsyn_folding =~ 't' 6623577c6faSBram Moolenaar syn region vimTclRegion fold matchgroup=vimScriptDelim start=+tc[l]\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimTclScript 6633577c6faSBram Moolenaar syn region vimTclRegion fold matchgroup=vimScriptDelim start=+tc[l]\=\s*<<\s*$+ end=+\.$+ contains=@vimTclScript 6643577c6faSBram Moolenaar else 665071d4279SBram Moolenaar syn region vimTclRegion matchgroup=vimScriptDelim start=+tc[l]\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimTclScript 666071d4279SBram Moolenaar syn region vimTclRegion matchgroup=vimScriptDelim start=+tc[l]\=\s*<<\s*$+ end=+\.$+ contains=@vimTclScript 667071d4279SBram Moolenaar endif 6685c73622aSBram Moolenaar syn cluster vimFuncBodyList add=vimTclScript 669c236c16dSBram Moolenaar else 670c236c16dSBram Moolenaar syn region vimEmbedError start=+tc[l]\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ 671c236c16dSBram Moolenaar syn region vimEmbedError start=+tc[l]\=\s*<<\s*$+ end=+\.$+ 6723577c6faSBram Moolenaar endif 6735c73622aSBram Moolenaar unlet s:tclpath 6745c73622aSBram Moolenaarelse 6755c73622aSBram Moolenaar syn region vimEmbedError start=+tc[l]\=\s*<<\s*\z(.*\)$+ end=+^\z1$+ 6765c73622aSBram Moolenaar syn region vimEmbedError start=+tc[l]\=\s*<<\s*$+ end=+\.$+ 6775c73622aSBram Moolenaarendif 6785c73622aSBram Moolenaarunlet s:trytcl 679071d4279SBram Moolenaar 6808299df96SBram Moolenaar" [-- mzscheme --] {{{3 681adc2182cSBram Moolenaarlet s:mzschemepath= fnameescape(expand("<sfile>:p:h")."/scheme.vim") 6825c73622aSBram Moolenaarif !filereadable(s:mzschemepath) 683adc2182cSBram Moolenaar let s:mzschemepath= fnameescape(globpath(&rtp,"syntax/scheme.vim")) 6845c73622aSBram Moolenaarendif 6855c73622aSBram Moolenaarif (g:vimsyn_embed =~ 'm' && has("mzscheme")) && filereadable(s:mzschemepath) 6868299df96SBram Moolenaar unlet! b:current_syntax 6878299df96SBram Moolenaar let iskKeep= &isk 6885c73622aSBram Moolenaar exe "syn include @vimMzSchemeScript ".s:mzschemepath 6898299df96SBram Moolenaar let &isk= iskKeep 690c236c16dSBram Moolenaar if exists("g:vimsyn_folding") && g:vimsyn_folding =~ 'm' 6913577c6faSBram Moolenaar syn region vimMzSchemeRegion fold matchgroup=vimScriptDelim start=+mz\%[scheme]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimMzSchemeScript 6923577c6faSBram Moolenaar syn region vimMzSchemeRegion fold matchgroup=vimScriptDelim start=+mz\%[scheme]\s*<<\s*$+ end=+\.$+ contains=@vimMzSchemeScript 6933577c6faSBram Moolenaar else 6948299df96SBram Moolenaar syn region vimMzSchemeRegion matchgroup=vimScriptDelim start=+mz\%[scheme]\s*<<\s*\z(.*\)$+ end=+^\z1$+ contains=@vimMzSchemeScript 6958299df96SBram Moolenaar syn region vimMzSchemeRegion matchgroup=vimScriptDelim start=+mz\%[scheme]\s*<<\s*$+ end=+\.$+ contains=@vimMzSchemeScript 6968299df96SBram Moolenaar endif 6975c73622aSBram Moolenaar syn cluster vimFuncBodyList add=vimMzSchemeRegion 698c236c16dSBram Moolenaarelse 699c236c16dSBram Moolenaar syn region vimEmbedError start=+mz\%[scheme]\s*<<\s*\z(.*\)$+ end=+^\z1$+ 700c236c16dSBram Moolenaar syn region vimEmbedError start=+mz\%[scheme]\s*<<\s*$+ end=+\.$+ 7013577c6faSBram Moolenaarendif 7025c73622aSBram Moolenaarunlet s:mzschemepath 7038299df96SBram Moolenaar 704cfbc5ee4SBram Moolenaar" Synchronize (speed) {{{2 705071d4279SBram Moolenaar"============ 7063577c6faSBram Moolenaarif exists("g:vimsyn_minlines") 7073577c6faSBram Moolenaar exe "syn sync minlines=".g:vimsyn_minlines 708071d4279SBram Moolenaarendif 7093577c6faSBram Moolenaarif exists("g:vimsyn_maxlines") 7103577c6faSBram Moolenaar exe "syn sync maxlines=".g:vimsyn_maxlines 711071d4279SBram Moolenaarelse 712071d4279SBram Moolenaar syn sync maxlines=60 713071d4279SBram Moolenaarendif 714071d4279SBram Moolenaarsyn sync linecont "^\s\+\\" 715071d4279SBram Moolenaarsyn sync match vimAugroupSyncA groupthere NONE "\<aug\%[roup]\>\s\+[eE][nN][dD]" 716071d4279SBram Moolenaar 7175c73622aSBram Moolenaar" ==================== 718cfbc5ee4SBram Moolenaar" Highlighting Settings {{{2 719071d4279SBram Moolenaar" ==================== 720071d4279SBram Moolenaar 721071d4279SBram Moolenaarhi def link vimAuHighlight vimHighlight 722071d4279SBram Moolenaarhi def link vimSubst1 vimSubst 723071d4279SBram Moolenaarhi def link vimBehaveModel vimBehave 724071d4279SBram Moolenaar 7253577c6faSBram Moolenaarif !exists("g:vimsyn_noerror") 726cfbc5ee4SBram Moolenaar hi def link vimBehaveError vimError 727cfbc5ee4SBram Moolenaar hi def link vimCollClassErr vimError 728cfbc5ee4SBram Moolenaar hi def link vimErrSetting vimError 729c236c16dSBram Moolenaar hi def link vimEmbedError vimError 730cfbc5ee4SBram Moolenaar hi def link vimFTError vimError 731cfbc5ee4SBram Moolenaar hi def link vimFunctionError vimError 7328299df96SBram Moolenaar hi def link vimFunc vimError 733cfbc5ee4SBram Moolenaar hi def link vimHiAttribList vimError 734cfbc5ee4SBram Moolenaar hi def link vimHiCtermError vimError 735cfbc5ee4SBram Moolenaar hi def link vimHiKeyError vimError 736cfbc5ee4SBram Moolenaar hi def link vimKeyCodeError vimError 737cfbc5ee4SBram Moolenaar hi def link vimMapModErr vimError 738cfbc5ee4SBram Moolenaar hi def link vimSubstFlagErr vimError 739cfbc5ee4SBram Moolenaar hi def link vimSynCaseError vimError 7403577c6faSBram Moolenaar hi def link vimBufnrWarn vimWarn 741cfbc5ee4SBram Moolenaarendif 742cfbc5ee4SBram Moolenaar 743e37d50a5SBram Moolenaarhi def link vimAbb vimCommand 744cfbc5ee4SBram Moolenaarhi def link vimAddress vimMark 745071d4279SBram Moolenaarhi def link vimAugroupKey vimCommand 746071d4279SBram Moolenaarhi def link vimAutoCmdOpt vimOption 747071d4279SBram Moolenaarhi def link vimAutoCmd vimCommand 748071d4279SBram Moolenaarhi def link vimAutoSet vimCommand 749071d4279SBram Moolenaarhi def link vimBehave vimCommand 750071d4279SBram Moolenaarhi def link vimCommentString vimString 751071d4279SBram Moolenaarhi def link vimCondHL vimCommand 752071d4279SBram Moolenaarhi def link vimEchoHLNone vimGroup 753071d4279SBram Moolenaarhi def link vimEchoHL vimCommand 754071d4279SBram Moolenaarhi def link vimElseif vimCondHL 755071d4279SBram Moolenaarhi def link vimFgBgAttrib vimHiAttrib 756071d4279SBram Moolenaarhi def link vimFTCmd vimCommand 757071d4279SBram Moolenaarhi def link vimFTOption vimSynType 758071d4279SBram Moolenaarhi def link vimFuncKey vimCommand 759071d4279SBram Moolenaarhi def link vimGroupAdd vimSynOption 760071d4279SBram Moolenaarhi def link vimGroupRem vimSynOption 761071d4279SBram Moolenaarhi def link vimHiCtermFgBg vimHiTerm 762071d4279SBram Moolenaarhi def link vimHiCTerm vimHiTerm 763071d4279SBram Moolenaarhi def link vimHighlight vimCommand 764071d4279SBram Moolenaarhi def link vimHiGroup vimGroupName 765071d4279SBram Moolenaarhi def link vimHiGuiFgBg vimHiTerm 766071d4279SBram Moolenaarhi def link vimHiGuiFont vimHiTerm 767071d4279SBram Moolenaarhi def link vimHiGuiRgb vimNumber 768071d4279SBram Moolenaarhi def link vimHiGui vimHiTerm 769071d4279SBram Moolenaarhi def link vimHiStartStop vimHiTerm 770071d4279SBram Moolenaarhi def link vimHLGroup vimGroup 771071d4279SBram Moolenaarhi def link vimInsert vimString 772071d4279SBram Moolenaarhi def link vimKeyCode vimSpecFile 773071d4279SBram Moolenaarhi def link vimLet vimCommand 774071d4279SBram Moolenaarhi def link vimLineComment vimComment 775071d4279SBram Moolenaarhi def link vimMapBang vimCommand 776071d4279SBram Moolenaarhi def link vimMapModKey vimFuncSID 777071d4279SBram Moolenaarhi def link vimMapMod vimBracket 778071d4279SBram Moolenaarhi def link vimMap vimCommand 779071d4279SBram Moolenaarhi def link vimMarkNumber vimNumber 780071d4279SBram Moolenaarhi def link vimMenuMod vimMapMod 781071d4279SBram Moolenaarhi def link vimMenuNameMore vimMenuName 782071d4279SBram Moolenaarhi def link vimMtchComment vimComment 78305159a0cSBram Moolenaarhi def link vimNorm vimCommand 7845c73622aSBram Moolenaarhi def link vimNotFunc vimCommand 785071d4279SBram Moolenaarhi def link vimNotPatSep vimString 786071d4279SBram Moolenaarhi def link vimPatSepErr vimPatSep 7875c73622aSBram Moolenaarhi def link vimPatSepR vimPatSep 788071d4279SBram Moolenaarhi def link vimPatSepZone vimString 7895c73622aSBram Moolenaarhi def link vimPatSepZ vimPatSep 790071d4279SBram Moolenaarhi def link vimPlainMark vimMark 791071d4279SBram Moolenaarhi def link vimPlainRegister vimRegister 792e2f98b95SBram Moolenaarhi def link vimSearch vimString 793071d4279SBram Moolenaarhi def link vimSetMod vimOption 794071d4279SBram Moolenaarhi def link vimSetString vimString 795071d4279SBram Moolenaarhi def link vimSpecFileMod vimSpecFile 796071d4279SBram Moolenaarhi def link vimStringCont vimString 797071d4279SBram Moolenaarhi def link vimSubstTwoBS vimString 798071d4279SBram Moolenaarhi def link vimSubst vimCommand 799071d4279SBram Moolenaarhi def link vimSyncGroupName vimGroupName 800071d4279SBram Moolenaarhi def link vimSyncGroup vimGroupName 801071d4279SBram Moolenaarhi def link vimSynContains vimSynOption 802071d4279SBram Moolenaarhi def link vimSynKeyContainedin vimSynContains 803071d4279SBram Moolenaarhi def link vimSynKeyOpt vimSynOption 804071d4279SBram Moolenaarhi def link vimSynMtchGrp vimSynOption 805071d4279SBram Moolenaarhi def link vimSynMtchOpt vimSynOption 806071d4279SBram Moolenaarhi def link vimSynNextgroup vimSynOption 807071d4279SBram Moolenaarhi def link vimSynNotPatRange vimSynRegPat 808071d4279SBram Moolenaarhi def link vimSynPatRange vimString 809071d4279SBram Moolenaarhi def link vimSynRegOpt vimSynOption 810071d4279SBram Moolenaarhi def link vimSynRegPat vimString 811071d4279SBram Moolenaarhi def link vimSyntax vimCommand 812071d4279SBram Moolenaarhi def link vimSynType vimSpecial 8135c73622aSBram Moolenaarhi def link vimUnmap vimMap 814071d4279SBram Moolenaarhi def link vimUserAttrbCmplt vimSpecial 815071d4279SBram Moolenaarhi def link vimUserAttrbKey vimOption 816071d4279SBram Moolenaarhi def link vimUserAttrb vimSpecial 817071d4279SBram Moolenaarhi def link vimUserCommand vimCommand 818071d4279SBram Moolenaar 819071d4279SBram Moolenaarhi def link vimAutoEvent Type 820071d4279SBram Moolenaarhi def link vimBracket Delimiter 821071d4279SBram Moolenaarhi def link vimCmplxRepeat SpecialChar 822071d4279SBram Moolenaarhi def link vimCommand Statement 823071d4279SBram Moolenaarhi def link vimComment Comment 824071d4279SBram Moolenaarhi def link vimCommentTitle PreProc 825071d4279SBram Moolenaarhi def link vimContinue Special 826071d4279SBram Moolenaarhi def link vimCtrlChar SpecialChar 827071d4279SBram Moolenaarhi def link vimElseIfErr Error 828071d4279SBram Moolenaarhi def link vimEnvvar PreProc 829071d4279SBram Moolenaarhi def link vimError Error 830071d4279SBram Moolenaarhi def link vimFold Folded 831071d4279SBram Moolenaarhi def link vimFuncName Function 832071d4279SBram Moolenaarhi def link vimFuncSID Special 833071d4279SBram Moolenaarhi def link vimFuncVar Identifier 834071d4279SBram Moolenaarhi def link vimGroupSpecial Special 8355c73622aSBram Moolenaarhi def link vimGroup Type 836071d4279SBram Moolenaarhi def link vimHiAttrib PreProc 837071d4279SBram Moolenaarhi def link vimHiTerm Type 8385c73622aSBram Moolenaarhi def link vimHLMod PreProc 839071d4279SBram Moolenaarhi def link vimKeyword Statement 840071d4279SBram Moolenaarhi def link vimMark Number 841071d4279SBram Moolenaarhi def link vimMenuName PreProc 842071d4279SBram Moolenaarhi def link vimNotation Special 843071d4279SBram Moolenaarhi def link vimNumber Number 8445c73622aSBram Moolenaarhi def link vimOperError Error 845071d4279SBram Moolenaarhi def link vimOper Operator 846071d4279SBram Moolenaarhi def link vimOption PreProc 8475c73622aSBram Moolenaarhi def link vimParenSep Delimiter 848071d4279SBram Moolenaarhi def link vimPatSep SpecialChar 849071d4279SBram Moolenaarhi def link vimPattern Type 850071d4279SBram Moolenaarhi def link vimRegister SpecialChar 851071d4279SBram Moolenaarhi def link vimScriptDelim Comment 8525c73622aSBram Moolenaarhi def link vimSearchDelim Statement 853071d4279SBram Moolenaarhi def link vimSep Delimiter 854071d4279SBram Moolenaarhi def link vimSetSep Statement 855071d4279SBram Moolenaarhi def link vimSpecFile Identifier 856071d4279SBram Moolenaarhi def link vimSpecial Type 857071d4279SBram Moolenaarhi def link vimStatement Statement 858071d4279SBram Moolenaarhi def link vimString String 859071d4279SBram Moolenaarhi def link vimSubstDelim Delimiter 860071d4279SBram Moolenaarhi def link vimSubstFlags Special 861071d4279SBram Moolenaarhi def link vimSubstSubstr SpecialChar 862071d4279SBram Moolenaarhi def link vimSynCaseError Error 8635c73622aSBram Moolenaarhi def link vimSynCase Type 864071d4279SBram Moolenaarhi def link vimSyncC Type 865071d4279SBram Moolenaarhi def link vimSyncError Error 866071d4279SBram Moolenaarhi def link vimSyncKey Type 867071d4279SBram Moolenaarhi def link vimSyncNone Type 8685c73622aSBram Moolenaarhi def link vimSynError Error 8695c73622aSBram Moolenaarhi def link vimSynOption Special 8705c73622aSBram Moolenaarhi def link vimSynReg Type 871071d4279SBram Moolenaarhi def link vimTodo Todo 872a93fa7eeSBram Moolenaarhi def link vimUserAttrbCmpltFunc Special 8735c73622aSBram Moolenaarhi def link vimUserCmdError Error 8745c73622aSBram Moolenaarhi def link vimUserFunc Normal 8753577c6faSBram Moolenaarhi def link vimWarn WarningMsg 876071d4279SBram Moolenaar 877cfbc5ee4SBram Moolenaar" Current Syntax Variable: {{{2 878071d4279SBram Moolenaarlet b:current_syntax = "vim" 879071d4279SBram Moolenaar" vim:ts=18 fdm=marker 880