mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
Updated runtime files and translations.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
" Vim syntax support file
|
||||
" Maintainer: Ben Fritz <fritzophrenic@gmail.com>
|
||||
" Last Change: 2012 Jun 30
|
||||
" Last Change: 2013 May 31
|
||||
"
|
||||
" Additional contributors:
|
||||
"
|
||||
@@ -214,17 +214,21 @@ endif
|
||||
|
||||
if !s:settings.use_css
|
||||
" Return opening HTML tag for given highlight id
|
||||
function! s:HtmlOpening(id)
|
||||
function! s:HtmlOpening(id, extra_attrs)
|
||||
let a = ""
|
||||
if synIDattr(a:id, "inverse")
|
||||
" For inverse, we always must set both colors (and exchange them)
|
||||
let x = s:HtmlColor(synIDattr(a:id, "fg#", s:whatterm))
|
||||
let a = a . '<span style="background-color: ' . ( x != "" ? x : s:fgc ) . '">'
|
||||
let a = a . '<span '.a:extra_attrs.'style="background-color: ' . ( x != "" ? x : s:fgc ) . '">'
|
||||
let x = s:HtmlColor(synIDattr(a:id, "bg#", s:whatterm))
|
||||
let a = a . '<font color="' . ( x != "" ? x : s:bgc ) . '">'
|
||||
else
|
||||
let x = s:HtmlColor(synIDattr(a:id, "bg#", s:whatterm))
|
||||
if x != "" | let a = a . '<span style="background-color: ' . x . '">' | endif
|
||||
if x != ""
|
||||
let a = a . '<span '.a:extra_attrs.'style="background-color: ' . x . '">'
|
||||
elseif !empty(a:extra_attrs)
|
||||
let a = a . '<span '.a:extra_attrs.'>'
|
||||
endif
|
||||
let x = s:HtmlColor(synIDattr(a:id, "fg#", s:whatterm))
|
||||
if x != "" | let a = a . '<font color="' . x . '">' | endif
|
||||
endif
|
||||
@@ -235,7 +239,7 @@ if !s:settings.use_css
|
||||
endfun
|
||||
|
||||
" Return closing HTML tag for given highlight id
|
||||
function! s:HtmlClosing(id)
|
||||
function! s:HtmlClosing(id, has_extra_attrs)
|
||||
let a = ""
|
||||
if synIDattr(a:id, "underline") | let a = a . "</u>" | endif
|
||||
if synIDattr(a:id, "italic") | let a = a . "</i>" | endif
|
||||
@@ -246,7 +250,7 @@ if !s:settings.use_css
|
||||
let x = s:HtmlColor(synIDattr(a:id, "fg#", s:whatterm))
|
||||
if x != "" | let a = a . '</font>' | endif
|
||||
let x = s:HtmlColor(synIDattr(a:id, "bg#", s:whatterm))
|
||||
if x != "" | let a = a . '</span>' | endif
|
||||
if x != "" || a:has_extra_attrs | let a = a . '</span>' | endif
|
||||
endif
|
||||
return a
|
||||
endfun
|
||||
@@ -265,7 +269,7 @@ if s:settings.use_css
|
||||
|
||||
" first, get the style names we need
|
||||
let wrapperfunc_lines = [
|
||||
\ 'function! s:BuildStyleWrapper(style_id, diff_style_id, text, make_unselectable, unformatted)',
|
||||
\ 'function! s:BuildStyleWrapper(style_id, diff_style_id, extra_attrs, text, make_unselectable, unformatted)',
|
||||
\ '',
|
||||
\ ' let l:style_name = synIDattr(a:style_id, "name", s:whatterm)'
|
||||
\ ]
|
||||
@@ -308,7 +312,7 @@ if s:settings.use_css
|
||||
|
||||
let wrapperfunc_lines += [
|
||||
\ '',
|
||||
\ ' if l:saved_style == ""'
|
||||
\ ' if l:saved_style == "" && empty(a:extra_attrs)'
|
||||
\ ]
|
||||
if &diff
|
||||
let wrapperfunc_lines += [
|
||||
@@ -340,7 +344,7 @@ if s:settings.use_css
|
||||
\ : "")
|
||||
if s:settings.prevent_copy == ""
|
||||
let wrapperfunc_lines += [
|
||||
\ ' return "<span class=\"" . l:style_name .'.diffstyle.'"\">".a:text."</span>"'
|
||||
\ ' return "<span ".a:extra_attrs."class=\"" . l:style_name .'.diffstyle.'"\">".a:text."</span>"'
|
||||
\ ]
|
||||
else
|
||||
|
||||
@@ -362,7 +366,7 @@ if s:settings.use_css
|
||||
" uses the number of unique codepoints for its limit.
|
||||
let wrapperfunc_lines += [
|
||||
\ ' if a:make_unselectable',
|
||||
\ ' return "<span class=\"" . l:style_name .'.diffstyle.'"\">'.
|
||||
\ ' return "<span ".a:extra_attrs."class=\"" . l:style_name .'.diffstyle.'"\">'.
|
||||
\ '<input'.s:unselInputType.' class=\"" . l:style_name .'.diffstyle.'"\"'.
|
||||
\ ' value=\"".substitute(a:unformatted,''\s\+$'',"","")."\"'.
|
||||
\ ' onselect=''this.blur(); return false;'''.
|
||||
@@ -372,17 +376,9 @@ if s:settings.use_css
|
||||
\ ' size=\"".strwidth(a:unformatted)."\"'.
|
||||
\ (s:settings.use_xhtml ? '/' : '').'></span>"',
|
||||
\ ' else',
|
||||
\ ' return "<span class=\"" . l:style_name .'. diffstyle .'"\">".a:text."</span>"'
|
||||
\ ' return "<span ".a:extra_attrs."class=\"" . l:style_name .'. diffstyle .'"\">".a:text."</span>"'
|
||||
\ ]
|
||||
endif
|
||||
" close off tag for non-empty primary style
|
||||
if s:settings.prevent_copy == ""
|
||||
let wrapperfunc_lines[-1] .=
|
||||
\ ' "\">".a:text."</span>"'
|
||||
else
|
||||
let wrapperfunc_lines[-1] .=
|
||||
\ ' "\">".a:text."</span>"'
|
||||
endif
|
||||
let wrapperfunc_lines += [
|
||||
\ ' endif',
|
||||
\ 'endfun'
|
||||
@@ -394,16 +390,16 @@ else
|
||||
" no styles exist.
|
||||
if &diff
|
||||
let wrapperfunc_lines = [
|
||||
\ 'function! s:BuildStyleWrapper(style_id, diff_style_id, text, unusedarg, unusedarg2)',
|
||||
\ ' return s:HtmlOpening(a:style_id).(a:diff_style_id <= 0 ? "" :'.
|
||||
\ 's:HtmlOpening(a:diff_style_id)).a:text.'.
|
||||
\ '(a:diff_style_id <= 0 ? "" : s:HtmlClosing(a:diff_style_id)).s:HtmlClosing(a:style_id)',
|
||||
\ 'function! s:BuildStyleWrapper(style_id, diff_style_id, extra_attrs, text, unusedarg, unusedarg2)',
|
||||
\ ' return s:HtmlOpening(a:style_id, a:extra_attrs).(a:diff_style_id <= 0 ? "" :'.
|
||||
\ 's:HtmlOpening(a:diff_style_id, "")).a:text.'.
|
||||
\ '(a:diff_style_id <= 0 ? "" : s:HtmlClosing(a:diff_style_id, 0)).s:HtmlClosing(a:style_id, !empty(a:extra_attrs))',
|
||||
\ 'endfun'
|
||||
\ ]
|
||||
else
|
||||
let wrapperfunc_lines = [
|
||||
\ 'function! s:BuildStyleWrapper(style_id, diff_style_id, text, unusedarg, unusedarg2)',
|
||||
\ ' return s:HtmlOpening(a:style_id).a:text.s:HtmlClosing(a:style_id)',
|
||||
\ 'function! s:BuildStyleWrapper(style_id, diff_style_id, extra_attrs, text, unusedarg, unusedarg2)',
|
||||
\ ' return s:HtmlOpening(a:style_id, a:extra_attrs).a:text.s:HtmlClosing(a:style_id, !empty(a:extra_attrs))',
|
||||
\ 'endfun'
|
||||
\ ]
|
||||
endif
|
||||
@@ -418,7 +414,7 @@ let s:diff_mode = &diff
|
||||
" unprintable characters expanded and double spaces replaced as necessary.
|
||||
"
|
||||
" TODO: eliminate unneeded logic like done for BuildStyleWrapper
|
||||
function! s:HtmlFormat(text, style_id, diff_style_id, make_unselectable)
|
||||
function! s:HtmlFormat(text, style_id, diff_style_id, extra_attrs, make_unselectable)
|
||||
" Replace unprintable characters
|
||||
let unformatted = strtrans(a:text)
|
||||
|
||||
@@ -447,27 +443,45 @@ function! s:HtmlFormat(text, style_id, diff_style_id, make_unselectable)
|
||||
endif
|
||||
|
||||
" Enclose in the correct format
|
||||
return s:BuildStyleWrapper(a:style_id, a:diff_style_id, formatted, a:make_unselectable, unformatted)
|
||||
return s:BuildStyleWrapper(a:style_id, a:diff_style_id, a:extra_attrs, formatted, a:make_unselectable, unformatted)
|
||||
endfun
|
||||
|
||||
" set up functions to call HtmlFormat in certain ways based on whether the
|
||||
" element is supposed to be unselectable or not
|
||||
if s:settings.prevent_copy =~# 'n'
|
||||
function! s:HtmlFormat_n(text, style_id, diff_style_id)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 1)
|
||||
endfun
|
||||
if s:settings.number_lines
|
||||
function! s:HtmlFormat_n(text, style_id, diff_style_id, lnr)
|
||||
if a:lnr > 0
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 'id="'.(exists('g:html_diff_win_num') ? 'W'.g:html_diff_win_num : "").'L'.a:lnr.'" ', 1)
|
||||
else
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, "", 1)
|
||||
endif
|
||||
endfun
|
||||
else
|
||||
" if lines are not being numbered the only reason this function gets called
|
||||
" is to put the line IDs on each line; "text" will be emtpy but lnr will
|
||||
" always be non-zero, however we don't want to use the <input> because that
|
||||
" won't work as nice for empty text
|
||||
function! s:HtmlFormat_n(text, style_id, diff_style_id, lnr)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 'id="'.(exists('g:html_diff_win_num') ? 'W'.g:html_diff_win_num : "").'L'.a:lnr.'" ', 0)
|
||||
endfun
|
||||
endif
|
||||
else
|
||||
function! s:HtmlFormat_n(text, style_id, diff_style_id)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 0)
|
||||
function! s:HtmlFormat_n(text, style_id, diff_style_id, lnr)
|
||||
if a:lnr > 0
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 'id="'.(exists('g:html_diff_win_num') ? 'W'.g:html_diff_win_num : "").'L'.a:lnr.'" ', 0)
|
||||
else
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, "", 0)
|
||||
endif
|
||||
endfun
|
||||
endif
|
||||
if s:settings.prevent_copy =~# 'd'
|
||||
function! s:HtmlFormat_d(text, style_id, diff_style_id)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 1)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, "", 1)
|
||||
endfun
|
||||
else
|
||||
function! s:HtmlFormat_d(text, style_id, diff_style_id)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 0)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, "", 0)
|
||||
endfun
|
||||
endif
|
||||
if s:settings.prevent_copy =~# 'f'
|
||||
@@ -501,7 +515,7 @@ else
|
||||
\ "</a>"
|
||||
endfun
|
||||
function! s:FoldColumn_fill()
|
||||
return s:HtmlFormat(repeat(' ', s:foldcolumn), s:FOLD_C_ID, 0, 0)
|
||||
return s:HtmlFormat(repeat(' ', s:foldcolumn), s:FOLD_C_ID, 0, "", 0)
|
||||
endfun
|
||||
endif
|
||||
if s:settings.prevent_copy =~# 't'
|
||||
@@ -512,17 +526,17 @@ if s:settings.prevent_copy =~# 't'
|
||||
" substitute later?
|
||||
if s:settings.dynamic_folds
|
||||
function! s:HtmlFormat_t(text, style_id, diff_style_id)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 1) .
|
||||
\ s:HtmlFormat("", a:style_id, 0, 0)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, "", 1) .
|
||||
\ s:HtmlFormat("", a:style_id, 0, "", 0)
|
||||
endfun
|
||||
else
|
||||
function! s:HtmlFormat_t(text, style_id, diff_style_id)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 1)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, "", 1)
|
||||
endfun
|
||||
endif
|
||||
else
|
||||
function! s:HtmlFormat_t(text, style_id, diff_style_id)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, 0)
|
||||
return s:HtmlFormat(a:text, a:style_id, a:diff_style_id, "", 0)
|
||||
endfun
|
||||
endif
|
||||
|
||||
@@ -607,7 +621,11 @@ endif
|
||||
let s:orgbufnr = winbufnr(0)
|
||||
let s:origwin_stl = &l:stl
|
||||
if expand("%") == ""
|
||||
exec 'new Untitled.'.(s:settings.use_xhtml ? 'x' : '').'html'
|
||||
if exists('g:html_diff_win_num')
|
||||
exec 'new Untitled_win'.g:html_diff_win_num.'.'.(s:settings.use_xhtml ? 'x' : '').'html'
|
||||
else
|
||||
exec 'new Untitled.'.(s:settings.use_xhtml ? 'x' : '').'html'
|
||||
endif
|
||||
else
|
||||
exec 'new %.'.(s:settings.use_xhtml ? 'x' : '').'html'
|
||||
endif
|
||||
@@ -625,7 +643,6 @@ setlocal winfixheight
|
||||
let s:newwin_stl = &l:stl
|
||||
|
||||
" on the new window, set the least time-consuming fold method
|
||||
let s:old_fdm = &foldmethod
|
||||
let s:old_fen = &foldenable
|
||||
setlocal foldmethod=manual
|
||||
setlocal nofoldenable
|
||||
@@ -671,7 +688,7 @@ let s:LeadingSpace = ' '
|
||||
let s:HtmlEndline = ''
|
||||
if s:settings.no_pre
|
||||
let s:HtmlEndline = '<br' . s:tag_close
|
||||
let s:LeadingSpace = ' '
|
||||
let s:LeadingSpace = s:settings.use_xhtml ? ' ' : ' '
|
||||
let s:HtmlSpace = '\' . s:LeadingSpace
|
||||
endif
|
||||
|
||||
@@ -774,13 +791,12 @@ if s:settings.use_css
|
||||
endif
|
||||
endif
|
||||
|
||||
" insert script tag if any javascript is needed
|
||||
if s:settings.dynamic_folds || s:settings.prevent_copy != ""
|
||||
call extend(s:lines, [
|
||||
\ "",
|
||||
\ "<script type='text/javascript'>",
|
||||
\ s:settings.use_xhtml ? '//<![CDATA[' : "<!--"])
|
||||
endif
|
||||
" insert script tag; javascript is always needed for the line number
|
||||
" normalization for URL hashes
|
||||
call extend(s:lines, [
|
||||
\ "",
|
||||
\ "<script type='text/javascript'>",
|
||||
\ s:settings.use_xhtml ? '//<![CDATA[' : "<!--"])
|
||||
|
||||
" insert javascript to toggle folds open and closed
|
||||
if s:settings.dynamic_folds
|
||||
@@ -799,9 +815,54 @@ if s:settings.dynamic_folds
|
||||
\ " fold.className = 'closed-fold';",
|
||||
\ " }",
|
||||
\ "}"
|
||||
\])
|
||||
\ ])
|
||||
endif
|
||||
|
||||
" insert javascript to get IDs from line numbers, and to open a fold before
|
||||
" jumping to any lines contained therein
|
||||
call extend(s:lines, [
|
||||
\ "",
|
||||
\ "/* 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;",
|
||||
\ " }",
|
||||
\ " lineElem = document.getElementById(lineNum);"
|
||||
\ ])
|
||||
if s:settings.dynamic_folds
|
||||
call extend(s:lines, [
|
||||
\ "",
|
||||
\ " /* navigate upwards in the DOM tree to open all folds containing the line */",
|
||||
\ " var node = lineElem;",
|
||||
\ " while (node && node.id != 'vimCodeElement')",
|
||||
\ " {",
|
||||
\ " if (node.className == 'closed-fold')",
|
||||
\ " {",
|
||||
\ " node.className = 'open-fold';",
|
||||
\ " }",
|
||||
\ " node = node.parentNode;",
|
||||
\ " }",
|
||||
\ ])
|
||||
endif
|
||||
call extend(s:lines, [
|
||||
\ " /* 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;",
|
||||
\ "}"
|
||||
\ ])
|
||||
|
||||
" Small text columns like the foldcolumn and line number column need a weird
|
||||
" hack to work around Webkit's and (in versions prior to 9) IE's lack of support
|
||||
" for the 'ch' unit without messing up Opera, which also doesn't support it but
|
||||
@@ -861,26 +922,24 @@ if !empty(s:settings.prevent_copy)
|
||||
\ ])
|
||||
endif
|
||||
|
||||
" insert script closing tag if any javascript is needed
|
||||
if s:settings.dynamic_folds || s:settings.prevent_copy != ""
|
||||
call extend(s:lines, [
|
||||
\ '',
|
||||
\ s:settings.use_xhtml ? '//]]>' : '-->',
|
||||
\ "</script>"
|
||||
\ ])
|
||||
endif
|
||||
" insert script closing tag
|
||||
call extend(s:lines, [
|
||||
\ '',
|
||||
\ s:settings.use_xhtml ? '//]]>' : '-->',
|
||||
\ "</script>"
|
||||
\ ])
|
||||
|
||||
call extend(s:lines, ["</head>"])
|
||||
if !empty(s:settings.prevent_copy)
|
||||
call extend(s:lines,
|
||||
\ ["<body onload='FixCharWidth();'>",
|
||||
\ ["<body onload='FixCharWidth(); JumpToLine();'>",
|
||||
\ "<!-- hidden divs used by javascript to get the width of a char -->",
|
||||
\ "<div id='oneCharWidth'>0</div>",
|
||||
\ "<div id='oneInputWidth'><input size='1' value='0'".s:tag_close."</div>",
|
||||
\ "<div id='oneEmWidth' style='width: 1em;'></div>"
|
||||
\ ])
|
||||
else
|
||||
call extend(s:lines, ["<body>"])
|
||||
call extend(s:lines, ["<body onload='JumpToLine();'>"])
|
||||
endif
|
||||
if s:settings.no_pre
|
||||
" if we're not using CSS we use a font tag which can't have a div inside
|
||||
@@ -1242,7 +1301,7 @@ while s:lnum <= s:end
|
||||
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) . s:new
|
||||
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
|
||||
@@ -1274,7 +1333,7 @@ while s:lnum <= s:end
|
||||
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:HtmlFormat_t(s:new, s:FOLDED_ID, 0)
|
||||
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)
|
||||
@@ -1355,7 +1414,7 @@ while s:lnum <= s:end
|
||||
" 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) : "") . substitute(s:HtmlFormat_t(foldtextresult(s:lnum), s:FOLDED_ID, 0), '</span>', s:HtmlEndline.'\n\0', '')
|
||||
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), '</span>', s:HtmlEndline.'\n\0', '')
|
||||
let s:new = s:new . "<span class='fulltext'>"
|
||||
|
||||
" open the fold now that we have the fold text to allow retrieval of
|
||||
@@ -1389,7 +1448,9 @@ while s:lnum <= s:end
|
||||
|
||||
" 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)
|
||||
let s:new = s:new . s:HtmlFormat_n(s:numcol, s:LINENR_ID, 0, s:lnum)
|
||||
else
|
||||
let s:new = s:new . s:HtmlFormat_n("", s:LINENR_ID, 0, s:lnum)
|
||||
endif
|
||||
|
||||
" Get the diff attribute, if any.
|
||||
@@ -1479,7 +1540,7 @@ while s:lnum <= s:end
|
||||
" 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)
|
||||
let s:new = s:new . s:HtmlFormat(s:expandedtab, s:id, s:diff_id, "", 0)
|
||||
endif
|
||||
endwhile
|
||||
endif
|
||||
@@ -1531,6 +1592,11 @@ unlet s:lines
|
||||
" stripped from the final output.
|
||||
%s!\v(%(^|\s+)%(vim?|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('$'), "<!-- vim: set foldmethod=manual : -->")
|
||||
|
||||
" Now, when we finally know which, we define the colors and styles
|
||||
if s:settings.use_css
|
||||
1;/<style type="text/+1
|
||||
@@ -1616,7 +1682,7 @@ if s:settings.use_css
|
||||
endif
|
||||
endif
|
||||
else
|
||||
execute '%s:<body>:<body bgcolor="' . s:bgc . '" text="' . s:fgc . '">\r<font face="'. s:htmlfont .'">'
|
||||
execute '%s:<body\([^>]*\):<body bgcolor="' . s:bgc . '" text="' . s:fgc . '"\1>\r<font face="'. s:htmlfont .'"'
|
||||
endif
|
||||
|
||||
" Gather attributes for all other classes. Do diff first so that normal
|
||||
@@ -1652,8 +1718,10 @@ endif
|
||||
%s:\s\+$::e
|
||||
|
||||
" Restore old settings (new window first)
|
||||
"
|
||||
" Don't bother restoring foldmethod in case it was syntax because the markup is
|
||||
" so weirdly formatted it can take a LONG time.
|
||||
let &l:foldenable = s:old_fen
|
||||
let &l:foldmethod = s:old_fdm
|
||||
let &report = s:old_report
|
||||
let &title = s:old_title
|
||||
let &icon = s:old_icon
|
||||
@@ -1684,7 +1752,7 @@ let &ls=s:ls
|
||||
" Save a little bit of memory (worth doing?)
|
||||
unlet s:htmlfont s:whitespace
|
||||
unlet s:old_et s:old_paste s:old_icon s:old_report s:old_title s:old_search
|
||||
unlet s:old_magic s:old_more s:old_fdm s:old_fen s:old_winheight
|
||||
unlet s:old_magic s:old_more s:old_fen s:old_winheight
|
||||
unlet! s:old_isprint
|
||||
unlet s:whatterm s:stylelist s:diffstylelist s:lnum s:end s:margin s:fgc s:bgc s:old_winfixheight
|
||||
unlet! s:col s:id s:attr s:len s:line s:new s:expandedtab s:concealinfo s:diff_mode
|
||||
|
@@ -21,7 +21,7 @@ syn keyword cTodo contained TODO FIXME XXX
|
||||
|
||||
" It's easy to accidentally add a space after a backslash that was intended
|
||||
" for line continuation. Some compilers allow it, which makes it
|
||||
" unpredicatable and should be avoided.
|
||||
" unpredictable and should be avoided.
|
||||
syn match cBadContinuation contained "\\\s\+$"
|
||||
|
||||
" cCommentGroup allows adding matches for special things in comments
|
||||
@@ -341,12 +341,12 @@ syn region cPreCondit start="^\s*\(%:\|#\)\s*\(if\|ifdef\|ifndef\|elif\)\>" skip
|
||||
syn match cPreConditMatch display "^\s*\(%:\|#\)\s*\(else\|endif\)\>"
|
||||
if !exists("c_no_if0")
|
||||
syn cluster cCppOutInGroup contains=cCppInIf,cCppInElse,cCppInElse2,cCppOutIf,cCppOutIf2,cCppOutElse,cCppInSkip,cCppOutSkip
|
||||
syn region cCppOutWrapper start="^\s*\(%:\|#\)\s*if\s\+0\+\s*\($\|//\|/\*\|&\)" end=".\@=\|$" contains=cCppOutIf,cCppOutElse fold
|
||||
syn region cCppOutWrapper start="^\s*\(%:\|#\)\s*if\s\+0\+\s*\($\|//\|/\*\|&\)" end=".\@=\|$" contains=cCppOutIf,cCppOutElse,@NoSpell fold
|
||||
syn region cCppOutIf contained start="0\+" matchgroup=cCppOutWrapper end="^\s*\(%:\|#\)\s*endif\>" contains=cCppOutIf2,cCppOutElse
|
||||
if !exists("c_no_if0_fold")
|
||||
syn region cCppOutIf2 contained matchgroup=cCppOutWrapper start="0\+" end="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0\+\s*\($\|//\|/\*\|&\)\)\@!\|endif\>\)"me=s-1 contains=cSpaceError,cCppOutSkip fold
|
||||
syn region cCppOutIf2 contained matchgroup=cCppOutWrapper start="0\+" end="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0\+\s*\($\|//\|/\*\|&\)\)\@!\|endif\>\)"me=s-1 contains=cSpaceError,cCppOutSkip,@Spell fold
|
||||
else
|
||||
syn region cCppOutIf2 contained matchgroup=cCppOutWrapper start="0\+" end="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0\+\s*\($\|//\|/\*\|&\)\)\@!\|endif\>\)"me=s-1 contains=cSpaceError,cCppOutSkip
|
||||
syn region cCppOutIf2 contained matchgroup=cCppOutWrapper start="0\+" end="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0\+\s*\($\|//\|/\*\|&\)\)\@!\|endif\>\)"me=s-1 contains=cSpaceError,cCppOutSkip,@Spell
|
||||
endif
|
||||
syn region cCppOutElse contained matchgroup=cCppOutWrapper start="^\s*\(%:\|#\)\s*\(else\|elif\)" end="^\s*\(%:\|#\)\s*endif\>"me=s-1 contains=TOP,cPreCondit
|
||||
syn region cCppInWrapper start="^\s*\(%:\|#\)\s*if\s\+0*[1-9]\d*\s*\($\|//\|/\*\||\)" end=".\@=\|$" contains=cCppInIf,cCppInElse fold
|
||||
@@ -356,7 +356,7 @@ if !exists("c_no_if0")
|
||||
else
|
||||
syn region cCppInElse contained start="^\s*\(%:\|#\)\s*\(else\>\|elif\s\+\(0*[1-9]\d*\s*\($\|//\|/\*\||\)\)\@!\)" end=".\@=\|$" containedin=cCppInIf contains=cCppInElse2
|
||||
endif
|
||||
syn region cCppInElse2 contained matchgroup=cCppInWrapper start="^\s*\(%:\|#\)\s*\(else\|elif\)\([^/]\|/[^/*]\)*" end="^\s*\(%:\|#\)\s*endif\>"me=s-1 contains=cSpaceError,cCppOutSkip
|
||||
syn region cCppInElse2 contained matchgroup=cCppInWrapper start="^\s*\(%:\|#\)\s*\(else\|elif\)\([^/]\|/[^/*]\)*" end="^\s*\(%:\|#\)\s*endif\>"me=s-1 contains=cSpaceError,cCppOutSkip,@Spell
|
||||
syn region cCppOutSkip contained start="^\s*\(%:\|#\)\s*\(if\>\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*\(%:\|#\)\s*endif\>" contains=cSpaceError,cCppOutSkip
|
||||
syn region cCppInSkip contained matchgroup=cCppInWrapper start="^\s*\(%:\|#\)\s*\(if\s\+\(\d\+\s*\($\|//\|/\*\||\|&\)\)\@!\|ifdef\>\|ifndef\>\)" skip="\\$" end="^\s*\(%:\|#\)\s*endif\>" containedin=cCppOutElse,cCppInIf,cCppInSkip contains=TOP,cPreProc
|
||||
endif
|
||||
|
@@ -2,7 +2,7 @@
|
||||
" Language: Cucumber
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Filenames: *.feature
|
||||
" Last Change: 2012 Apr 30
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
@@ -14,50 +14,60 @@ syn case match
|
||||
syn sync minlines=20
|
||||
|
||||
let g:cucumber_languages = {
|
||||
\"en": {"and": "And\\>", "background": "Background\\>", "but": "But\\>", "examples": "Scenarios\\>\\|Examples\\>", "feature": "Feature\\>", "given": "Given\\>", "scenario": "Scenario\\>", "scenario_outline": "Scenario Outline\\>", "then": "Then\\>", "when": "When\\>"},
|
||||
\"en": {"and": "And\\>", "background": "Background\\>", "but": "But\\>", "examples": "Scenarios\\>\\|Examples\\>", "feature": "Business Need\\>\\|Feature\\>\\|Ability\\>", "given": "Given\\>", "scenario": "Scenario\\>", "scenario_outline": "Scenario Template\\>\\|Scenario Outline\\>", "then": "Then\\>", "when": "When\\>"},
|
||||
\"ar": {"and": "\\%u0648\\>", "background": "\\%u0627\\%u0644\\%u062e\\%u0644\\%u0641\\%u064a\\%u0629\\>", "but": "\\%u0644\\%u0643\\%u0646\\>", "examples": "\\%u0627\\%u0645\\%u062b\\%u0644\\%u0629\\>", "feature": "\\%u062e\\%u0627\\%u0635\\%u064a\\%u0629\\>", "given": "\\%u0628\\%u0641\\%u0631\\%u0636\\>", "scenario": "\\%u0633\\%u064a\\%u0646\\%u0627\\%u0631\\%u064a\\%u0648\\>", "scenario_outline": "\\%u0633\\%u064a\\%u0646\\%u0627\\%u0631\\%u064a\\%u0648 \\%u0645\\%u062e\\%u0637\\%u0637\\>", "then": "\\%u0627\\%u0630\\%u0627\\%u064b\\>\\|\\%u062b\\%u0645\\>", "when": "\\%u0639\\%u0646\\%u062f\\%u0645\\%u0627\\>\\|\\%u0645\\%u062a\\%u0649\\>"},
|
||||
\"bg": {"and": "\\%u0418\\>", "background": "\\%u041f\\%u0440\\%u0435\\%u0434\\%u0438\\%u0441\\%u0442\\%u043e\\%u0440\\%u0438\\%u044f\\>", "but": "\\%u041d\\%u043e\\>", "examples": "\\%u041f\\%u0440\\%u0438\\%u043c\\%u0435\\%u0440\\%u0438\\>", "feature": "\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0438\\%u043e\\%u043d\\%u0430\\%u043b\\%u043d\\%u043e\\%u0441\\%u0442\\>", "given": "\\%u0414\\%u0430\\%u0434\\%u0435\\%u043d\\%u043e\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439\\>", "scenario_outline": "\\%u0420\\%u0430\\%u043c\\%u043a\\%u0430 \\%u043d\\%u0430 \\%u0441\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439\\>", "then": "\\%u0422\\%u043e\\>", "when": "\\%u041a\\%u043e\\%u0433\\%u0430\\%u0442\\%u043e\\>"},
|
||||
\"bm": {"and": "Dan\\>", "background": "Latar Belakang\\>", "but": "Tetapi\\>", "examples": "Contoh \\>", "feature": "Fungsi\\>", "given": "Bagi\\>", "scenario": "Senario\\>", "scenario_outline": "Menggariskan Senario \\>", "then": "Kemudian\\>", "when": "Apabila\\>"},
|
||||
\"ca": {"and": "I\\>", "background": "Antecedents\\>\\|Rerefons\\>", "but": "Per\\%u00f2\\>", "examples": "Exemples\\>", "feature": "Caracter\\%u00edstica\\>\\|Funcionalitat\\>", "given": "At\\%u00e8s\\>\\|Donada\\>\\|Donat\\>\\|Atesa\\>", "scenario": "Escenari\\>", "scenario_outline": "Esquema de l'escenari\\>", "then": "Aleshores\\>\\|Cal\\>", "when": "Quan\\>"},
|
||||
\"cs": {"and": "A tak\\%u00e9\\>\\|A\\>", "background": "Pozad\\%u00ed\\>\\|Kontext\\>", "but": "Ale\\>", "examples": "P\\%u0159\\%u00edklady\\>", "feature": "Po\\%u017eadavek\\>", "given": "Pokud\\>", "scenario": "Sc\\%u00e9n\\%u00e1\\%u0159\\>", "scenario_outline": "N\\%u00e1\\%u010drt Sc\\%u00e9n\\%u00e1\\%u0159e\\>\\|Osnova sc\\%u00e9n\\%u00e1\\%u0159e\\>", "then": "Pak\\>", "when": "Kdy\\%u017e\\>"},
|
||||
\"cs": {"and": "A tak\\%u00e9\\>\\|A\\>", "background": "Pozad\\%u00ed\\>\\|Kontext\\>", "but": "Ale\\>", "examples": "P\\%u0159\\%u00edklady\\>", "feature": "Po\\%u017eadavek\\>", "given": "Za p\\%u0159edpokladu\\>\\|Pokud\\>", "scenario": "Sc\\%u00e9n\\%u00e1\\%u0159\\>", "scenario_outline": "N\\%u00e1\\%u010drt Sc\\%u00e9n\\%u00e1\\%u0159e\\>\\|Osnova sc\\%u00e9n\\%u00e1\\%u0159e\\>", "then": "Pak\\>", "when": "Kdy\\%u017e\\>"},
|
||||
\"cy-GB": {"and": "A\\>", "background": "Cefndir\\>", "but": "Ond\\>", "examples": "Enghreifftiau\\>", "feature": "Arwedd\\>", "given": "Anrhegedig a\\>", "scenario": "Scenario\\>", "scenario_outline": "Scenario Amlinellol\\>", "then": "Yna\\>", "when": "Pryd\\>"},
|
||||
\"da": {"and": "Og\\>", "background": "Baggrund\\>", "but": "Men\\>", "examples": "Eksempler\\>", "feature": "Egenskab\\>", "given": "Givet\\>", "scenario": "Scenarie\\>", "scenario_outline": "Abstrakt Scenario\\>", "then": "S\\%u00e5\\>", "when": "N\\%u00e5r\\>"},
|
||||
\"de": {"and": "Und\\>", "background": "Grundlage\\>", "but": "Aber\\>", "examples": "Beispiele\\>", "feature": "Funktionalit\\%u00e4t\\>", "given": "Gegeben sei\\>\\|Angenommen\\>", "scenario": "Szenario\\>", "scenario_outline": "Szenariogrundriss\\>", "then": "Dann\\>", "when": "Wenn\\>"},
|
||||
\"el": {"and": "\\%u039a\\%u03b1\\%u03b9\\>", "background": "\\%u03a5\\%u03c0\\%u03cc\\%u03b2\\%u03b1\\%u03b8\\%u03c1\\%u03bf\\>", "but": "\\%u0391\\%u03bb\\%u03bb\\%u03ac\\>", "examples": "\\%u03a0\\%u03b1\\%u03c1\\%u03b1\\%u03b4\\%u03b5\\%u03af\\%u03b3\\%u03bc\\%u03b1\\%u03c4\\%u03b1\\>\\|\\%u03a3\\%u03b5\\%u03bd\\%u03ac\\%u03c1\\%u03b9\\%u03b1\\>", "feature": "\\%u0394\\%u03c5\\%u03bd\\%u03b1\\%u03c4\\%u03cc\\%u03c4\\%u03b7\\%u03c4\\%u03b1\\>\\|\\%u039b\\%u03b5\\%u03b9\\%u03c4\\%u03bf\\%u03c5\\%u03c1\\%u03b3\\%u03af\\%u03b1\\>", "given": "\\%u0394\\%u03b5\\%u03b4\\%u03bf\\%u03bc\\%u03ad\\%u03bd\\%u03bf\\%u03c5 \\%u03cc\\%u03c4\\%u03b9\\>\\|\\%u0394\\%u03b5\\%u03b4\\%u03bf\\%u03bc\\%u03ad\\%u03bd\\%u03bf\\%u03c5\\>", "scenario": "\\%u03a3\\%u03b5\\%u03bd\\%u03ac\\%u03c1\\%u03b9\\%u03bf\\>", "scenario_outline": "\\%u03a0\\%u03b5\\%u03c1\\%u03b9\\%u03b3\\%u03c1\\%u03b1\\%u03c6\\%u03ae \\%u03a3\\%u03b5\\%u03bd\\%u03b1\\%u03c1\\%u03af\\%u03bf\\%u03c5\\>", "then": "\\%u03a4\\%u03cc\\%u03c4\\%u03b5\\>", "when": "\\%u038c\\%u03c4\\%u03b1\\%u03bd\\>"},
|
||||
\"en-Scouse": {"and": "An\\>", "background": "Dis is what went down\\>", "but": "Buh\\>", "examples": "Examples\\>", "feature": "Feature\\>", "given": "Youse know when youse got\\>\\|Givun\\>", "scenario": "The thing of it is\\>", "scenario_outline": "Wharrimean is\\>", "then": "Den youse gotta\\>\\|Dun\\>", "when": "Youse know like when\\>\\|Wun\\>"},
|
||||
\"en-au": {"and": "N\\>", "background": "Background\\>", "but": "Cept\\>", "examples": "Cobber\\>", "feature": "Crikey\\>", "given": "Ya know how\\>", "scenario": "Mate\\>", "scenario_outline": "Blokes\\>", "then": "Ya gotta\\>", "when": "When\\>"},
|
||||
\"en-au": {"and": "Too right\\>", "background": "First off\\>", "but": "Yeah nah\\>", "examples": "You'll wanna\\>", "feature": "Pretty much\\>", "given": "Y'know\\>", "scenario": "Awww, look mate\\>", "scenario_outline": "Reckon it's like\\>", "then": "But at the end of the day I reckon\\>", "when": "It's just unbelievable\\>"},
|
||||
\"en-lol": {"and": "AN\\>", "background": "B4\\>", "but": "BUT\\>", "examples": "EXAMPLZ\\>", "feature": "OH HAI\\>", "given": "I CAN HAZ\\>", "scenario": "MISHUN\\>", "scenario_outline": "MISHUN SRSLY\\>", "then": "DEN\\>", "when": "WEN\\>"},
|
||||
\"en-old": {"and": "Ond\\>\\|7\\>", "background": "\\%u00c6r\\>\\|Aer\\>", "but": "Ac\\>", "examples": "Se \\%u00f0e\\>\\|Se \\%u00fee\\>\\|Se the\\>", "feature": "Hw\\%u00e6t\\>\\|Hwaet\\>", "given": "\\%u00d0urh\\>\\|\\%u00deurh\\>\\|Thurh\\>", "scenario": "Swa\\>", "scenario_outline": "Swa hw\\%u00e6r swa\\>\\|Swa hwaer swa\\>", "then": "\\%u00d0a \\%u00f0e\\>\\|\\%u00dea \\%u00fee\\>\\|\\%u00dea\\>\\|\\%u00d0a\\>\\|Tha the\\>\\|Tha\\>", "when": "\\%u00d0a\\>\\|\\%u00dea\\>\\|Tha\\>"},
|
||||
\"en-pirate": {"and": "Aye\\>", "background": "Yo-ho-ho\\>", "but": "Avast!\\>", "examples": "Dead men tell no tales\\>", "feature": "Ahoy matey!\\>", "given": "Gangway!\\>", "scenario": "Heave to\\>", "scenario_outline": "Shiver me timbers\\>", "then": "Let go and haul\\>", "when": "Blimey!\\>"},
|
||||
\"en-tx": {"and": "And y'all\\>", "background": "Background\\>", "but": "But y'all\\>", "examples": "Examples\\>", "feature": "Feature\\>", "given": "Given y'all\\>", "scenario": "Scenario\\>", "scenario_outline": "All y'all\\>", "then": "Then y'all\\>", "when": "When y'all\\>"},
|
||||
\"eo": {"and": "Kaj\\>", "background": "Fono\\>", "but": "Sed\\>", "examples": "Ekzemploj\\>", "feature": "Trajto\\>", "given": "Donita\\%u0135o\\>", "scenario": "Scenaro\\>", "scenario_outline": "Konturo de la scenaro\\>", "then": "Do\\>", "when": "Se\\>"},
|
||||
\"es": {"and": "Y\\>", "background": "Antecedentes\\>", "but": "Pero\\>", "examples": "Ejemplos\\>", "feature": "Caracter\\%u00edstica\\>", "given": "Dado\\>", "scenario": "Escenario\\>", "scenario_outline": "Esquema del escenario\\>", "then": "Entonces\\>", "when": "Cuando\\>"},
|
||||
\"es": {"and": "Y\\>", "background": "Antecedentes\\>", "but": "Pero\\>", "examples": "Ejemplos\\>", "feature": "Caracter\\%u00edstica\\>", "given": "Dadas\\>\\|Dados\\>\\|Dada\\>\\|Dado\\>", "scenario": "Escenario\\>", "scenario_outline": "Esquema del escenario\\>", "then": "Entonces\\>", "when": "Cuando\\>"},
|
||||
\"et": {"and": "Ja\\>", "background": "Taust\\>", "but": "Kuid\\>", "examples": "Juhtumid\\>", "feature": "Omadus\\>", "given": "Eeldades\\>", "scenario": "Stsenaarium\\>", "scenario_outline": "Raamstsenaarium\\>", "then": "Siis\\>", "when": "Kui\\>"},
|
||||
\"fa": {"and": "\\%u0648\\>", "background": "\\%u0632\\%u0645\\%u06cc\\%u0646\\%u0647\\>", "but": "\\%u0627\\%u0645\\%u0627\\>", "examples": "\\%u0646\\%u0645\\%u0648\\%u0646\\%u0647 \\%u0647\\%u0627\\>", "feature": "\\%u0648\\%u0650\\%u06cc\\%u0698\\%u06af\\%u06cc\\>", "given": "\\%u0628\\%u0627 \\%u0641\\%u0631\\%u0636\\>", "scenario": "\\%u0633\\%u0646\\%u0627\\%u0631\\%u06cc\\%u0648\\>", "scenario_outline": "\\%u0627\\%u0644\\%u06af\\%u0648\\%u06cc \\%u0633\\%u0646\\%u0627\\%u0631\\%u06cc\\%u0648\\>", "then": "\\%u0622\\%u0646\\%u06af\\%u0627\\%u0647\\>", "when": "\\%u0647\\%u0646\\%u06af\\%u0627\\%u0645\\%u06cc\\>"},
|
||||
\"fi": {"and": "Ja\\>", "background": "Tausta\\>", "but": "Mutta\\>", "examples": "Tapaukset\\>", "feature": "Ominaisuus\\>", "given": "Oletetaan\\>", "scenario": "Tapaus\\>", "scenario_outline": "Tapausaihio\\>", "then": "Niin\\>", "when": "Kun\\>"},
|
||||
\"fr": {"and": "Et\\>", "background": "Contexte\\>", "but": "Mais\\>", "examples": "Exemples\\>", "feature": "Fonctionnalit\\%u00e9\\>", "given": "Etant donn\\%u00e9\\>\\|Soit\\>", "scenario": "Sc\\%u00e9nario\\>", "scenario_outline": "Plan du sc\\%u00e9nario\\>\\|Plan du Sc\\%u00e9nario\\>", "then": "Alors\\>", "when": "Lorsqu'\\|Lorsque\\>\\|Quand\\>"},
|
||||
\"fr": {"and": "Et\\>", "background": "Contexte\\>", "but": "Mais\\>", "examples": "Exemples\\>", "feature": "Fonctionnalit\\%u00e9\\>", "given": "\\%u00c9tant donn\\%u00e9es\\>\\|\\%u00c9tant donn\\%u00e9s\\>\\|\\%u00c9tant donn\\%u00e9e\\>\\|\\%u00c9tant donn\\%u00e9\\>\\|Etant donn\\%u00e9es\\>\\|Etant donn\\%u00e9s\\>\\|Etant donn\\%u00e9e\\>\\|Etant donn\\%u00e9\\>\\|Soit\\>", "scenario": "Sc\\%u00e9nario\\>", "scenario_outline": "Plan du sc\\%u00e9nario\\>\\|Plan du Sc\\%u00e9nario\\>", "then": "Alors\\>", "when": "Lorsqu'\\|Lorsque\\>\\|Quand\\>"},
|
||||
\"gl": {"and": "E\\>", "background": "Contexto\\>", "but": "Mais\\>\\|Pero\\>", "examples": "Exemplos\\>", "feature": "Caracter\\%u00edstica\\>", "given": "Dadas\\>\\|Dados\\>\\|Dada\\>\\|Dado\\>", "scenario": "Escenario\\>", "scenario_outline": "Esbozo do escenario\\>", "then": "Ent\\%u00f3n\\>\\|Logo\\>", "when": "Cando\\>"},
|
||||
\"he": {"and": "\\%u05d5\\%u05d2\\%u05dd\\>", "background": "\\%u05e8\\%u05e7\\%u05e2\\>", "but": "\\%u05d0\\%u05d1\\%u05dc\\>", "examples": "\\%u05d3\\%u05d5\\%u05d2\\%u05de\\%u05d0\\%u05d5\\%u05ea\\>", "feature": "\\%u05ea\\%u05db\\%u05d5\\%u05e0\\%u05d4\\>", "given": "\\%u05d1\\%u05d4\\%u05d9\\%u05e0\\%u05ea\\%u05df\\>", "scenario": "\\%u05ea\\%u05e8\\%u05d7\\%u05d9\\%u05e9\\>", "scenario_outline": "\\%u05ea\\%u05d1\\%u05e0\\%u05d9\\%u05ea \\%u05ea\\%u05e8\\%u05d7\\%u05d9\\%u05e9\\>", "then": "\\%u05d0\\%u05d6\\%u05d9\\>\\|\\%u05d0\\%u05d6\\>", "when": "\\%u05db\\%u05d0\\%u05e9\\%u05e8\\>"},
|
||||
\"hi": {"and": "\\%u0924\\%u0925\\%u093e\\>\\|\\%u0914\\%u0930\\>", "background": "\\%u092a\\%u0943\\%u0937\\%u094d\\%u0920\\%u092d\\%u0942\\%u092e\\%u093f\\>", "but": "\\%u092a\\%u0930\\>", "examples": "\\%u0909\\%u0926\\%u093e\\%u0939\\%u0930\\%u0923\\>", "feature": "\\%u0930\\%u0942\\%u092a \\%u0932\\%u0947\\%u0916\\>", "given": "\\%u091a\\%u0942\\%u0902\\%u0915\\%u093f\\>\\|\\%u092f\\%u0926\\%u093f\\>\\|\\%u0905\\%u0917\\%u0930\\>", "scenario": "\\%u092a\\%u0930\\%u093f\\%u0926\\%u0943\\%u0936\\%u094d\\%u092f\\>", "scenario_outline": "\\%u092a\\%u0930\\%u093f\\%u0926\\%u0943\\%u0936\\%u094d\\%u092f \\%u0930\\%u0942\\%u092a\\%u0930\\%u0947\\%u0916\\%u093e\\>", "then": "\\%u0924\\%u092c\\>", "when": "\\%u091c\\%u092c\\>"},
|
||||
\"hr": {"and": "I\\>", "background": "Pozadina\\>", "but": "Ali\\>", "examples": "Scenariji\\>\\|Primjeri\\>", "feature": "Mogu\\%u0107nost\\>\\|Mogucnost\\>\\|Osobina\\>", "given": "Zadano\\>\\|Zadani\\>\\|Zadan\\>", "scenario": "Scenarij\\>", "scenario_outline": "Koncept\\>\\|Skica\\>", "then": "Onda\\>", "when": "Kada\\>\\|Kad\\>"},
|
||||
\"hu": {"and": "\\%u00c9s\\>", "background": "H\\%u00e1tt\\%u00e9r\\>", "but": "De\\>", "examples": "P\\%u00e9ld\\%u00e1k\\>", "feature": "Jellemz\\%u0151\\>", "given": "Ha\\>", "scenario": "Forgat\\%u00f3k\\%u00f6nyv\\>", "scenario_outline": "Forgat\\%u00f3k\\%u00f6nyv v\\%u00e1zlat\\>", "then": "Akkor\\>", "when": "Majd\\>"},
|
||||
\"hu": {"and": "\\%u00c9s\\>", "background": "H\\%u00e1tt\\%u00e9r\\>", "but": "De\\>", "examples": "P\\%u00e9ld\\%u00e1k\\>", "feature": "Jellemz\\%u0151\\>", "given": "Amennyiben\\>\\|Adott\\>", "scenario": "Forgat\\%u00f3k\\%u00f6nyv\\>", "scenario_outline": "Forgat\\%u00f3k\\%u00f6nyv v\\%u00e1zlat\\>", "then": "Akkor\\>", "when": "Amikor\\>\\|Majd\\>\\|Ha\\>"},
|
||||
\"id": {"and": "Dan\\>", "background": "Dasar\\>", "but": "Tapi\\>", "examples": "Contoh\\>", "feature": "Fitur\\>", "given": "Dengan\\>", "scenario": "Skenario\\>", "scenario_outline": "Skenario konsep\\>", "then": "Maka\\>", "when": "Ketika\\>"},
|
||||
\"it": {"and": "E\\>", "background": "Contesto\\>", "but": "Ma\\>", "examples": "Esempi\\>", "feature": "Funzionalit\\%u00e0\\>", "given": "Dato\\>", "scenario": "Scenario\\>", "scenario_outline": "Schema dello scenario\\>", "then": "Allora\\>", "when": "Quando\\>"},
|
||||
\"is": {"and": "Og\\>", "background": "Bakgrunnur\\>", "but": "En\\>", "examples": "Atbur\\%u00f0ar\\%u00e1sir\\>\\|D\\%u00e6mi\\>", "feature": "Eiginleiki\\>", "given": "Ef\\>", "scenario": "Atbur\\%u00f0ar\\%u00e1s\\>", "scenario_outline": "L\\%u00fdsing Atbur\\%u00f0ar\\%u00e1sar\\>\\|L\\%u00fdsing D\\%u00e6ma\\>", "then": "\\%u00de\\%u00e1\\>", "when": "\\%u00deegar\\>"},
|
||||
\"it": {"and": "E\\>", "background": "Contesto\\>", "but": "Ma\\>", "examples": "Esempi\\>", "feature": "Funzionalit\\%u00e0\\>", "given": "Dato\\>\\|Data\\>\\|Dati\\>\\|Date\\>", "scenario": "Scenario\\>", "scenario_outline": "Schema dello scenario\\>", "then": "Allora\\>", "when": "Quando\\>"},
|
||||
\"ja": {"and": "\\%u304b\\%u3064", "background": "\\%u80cc\\%u666f\\>", "but": "\\%u3057\\%u304b\\%u3057\\|\\%u305f\\%u3060\\%u3057\\|\\%u4f46\\%u3057", "examples": "\\%u30b5\\%u30f3\\%u30d7\\%u30eb\\>\\|\\%u4f8b\\>", "feature": "\\%u30d5\\%u30a3\\%u30fc\\%u30c1\\%u30e3\\>\\|\\%u6a5f\\%u80fd\\>", "given": "\\%u524d\\%u63d0", "scenario": "\\%u30b7\\%u30ca\\%u30ea\\%u30aa\\>", "scenario_outline": "\\%u30b7\\%u30ca\\%u30ea\\%u30aa\\%u30a2\\%u30a6\\%u30c8\\%u30e9\\%u30a4\\%u30f3\\>\\|\\%u30b7\\%u30ca\\%u30ea\\%u30aa\\%u30c6\\%u30f3\\%u30d7\\%u30ec\\%u30fc\\%u30c8\\>\\|\\%u30b7\\%u30ca\\%u30ea\\%u30aa\\%u30c6\\%u30f3\\%u30d7\\%u30ec\\>\\|\\%u30c6\\%u30f3\\%u30d7\\%u30ec\\>", "then": "\\%u306a\\%u3089\\%u3070", "when": "\\%u3082\\%u3057"},
|
||||
\"ko": {"and": "\\%uadf8\\%ub9ac\\%uace0", "background": "\\%ubc30\\%uacbd\\>", "but": "\\%ud558\\%uc9c0\\%ub9cc\\|\\%ub2e8", "examples": "\\%uc608\\>", "feature": "\\%uae30\\%ub2a5\\>", "given": "\\%uc870\\%uac74\\|\\%uba3c\\%uc800", "scenario": "\\%uc2dc\\%ub098\\%ub9ac\\%uc624\\>", "scenario_outline": "\\%uc2dc\\%ub098\\%ub9ac\\%uc624 \\%uac1c\\%uc694\\>", "then": "\\%uadf8\\%ub7ec\\%uba74", "when": "\\%ub9cc\\%uc77c\\|\\%ub9cc\\%uc57d"},
|
||||
\"lt": {"and": "Ir\\>", "background": "Kontekstas\\>", "but": "Bet\\>", "examples": "Pavyzd\\%u017eiai\\>\\|Scenarijai\\>\\|Variantai\\>", "feature": "Savyb\\%u0117\\>", "given": "Duota\\>", "scenario": "Scenarijus\\>", "scenario_outline": "Scenarijaus \\%u0161ablonas\\>", "then": "Tada\\>", "when": "Kai\\>"},
|
||||
\"lu": {"and": "an\\>\\|a\\>", "background": "Hannergrond\\>", "but": "m\\%u00e4\\>\\|awer\\>", "examples": "Beispiller\\>", "feature": "Funktionalit\\%u00e9it\\>", "given": "ugeholl\\>", "scenario": "Szenario\\>", "scenario_outline": "Plang vum Szenario\\>", "then": "dann\\>", "when": "wann\\>"},
|
||||
\"lv": {"and": "Un\\>", "background": "Situ\\%u0101cija\\>\\|Konteksts\\>", "but": "Bet\\>", "examples": "Piem\\%u0113ri\\>\\|Paraugs\\>", "feature": "Funkcionalit\\%u0101te\\>\\|F\\%u012b\\%u010da\\>", "given": "Kad\\>", "scenario": "Scen\\%u0101rijs\\>", "scenario_outline": "Scen\\%u0101rijs p\\%u0113c parauga\\>", "then": "Tad\\>", "when": "Ja\\>"},
|
||||
\"nl": {"and": "En\\>", "background": "Achtergrond\\>", "but": "Maar\\>", "examples": "Voorbeelden\\>", "feature": "Functionaliteit\\>", "given": "Gegeven\\>\\|Stel\\>", "scenario": "Scenario\\>", "scenario_outline": "Abstract Scenario\\>", "then": "Dan\\>", "when": "Als\\>"},
|
||||
\"no": {"and": "Og\\>", "background": "Bakgrunn\\>", "but": "Men\\>", "examples": "Eksempler\\>", "feature": "Egenskap\\>", "given": "Gitt\\>", "scenario": "Scenario\\>", "scenario_outline": "Abstrakt Scenario\\>", "then": "S\\%u00e5\\>", "when": "N\\%u00e5r\\>"},
|
||||
\"pl": {"and": "Oraz\\>", "background": "Za\\%u0142o\\%u017cenia\\>", "but": "Ale\\>", "examples": "Przyk\\%u0142ady\\>", "feature": "W\\%u0142a\\%u015bciwo\\%u015b\\%u0107\\>", "given": "Zak\\%u0142adaj\\%u0105c\\>", "scenario": "Scenariusz\\>", "scenario_outline": "Szablon scenariusza\\>", "then": "Wtedy\\>", "when": "Je\\%u017celi\\>"},
|
||||
\"pt": {"and": "E\\>", "background": "Contexto\\>", "but": "Mas\\>", "examples": "Exemplos\\>", "feature": "Funcionalidade\\>", "given": "Dado\\>", "scenario": "Cen\\%u00e1rio\\>\\|Cenario\\>", "scenario_outline": "Esquema do Cen\\%u00e1rio\\>\\|Esquema do Cenario\\>", "then": "Ent\\%u00e3o\\>\\|Entao\\>", "when": "Quando\\>"},
|
||||
\"ro": {"and": "Si\\>", "background": "Conditii\\>", "but": "Dar\\>", "examples": "Exemplele\\>", "feature": "Functionalitate\\>", "given": "Daca\\>", "scenario": "Scenariu\\>", "scenario_outline": "Scenariul de sablon\\>", "then": "Atunci\\>", "when": "Cand\\>"},
|
||||
\"ro-RO": {"and": "\\%u0218i\\>", "background": "Condi\\%u0163ii\\>", "but": "Dar\\>", "examples": "Exemplele\\>", "feature": "Func\\%u021bionalitate\\>", "given": "Dac\\%u0103\\>", "scenario": "Scenariu\\>", "scenario_outline": "Scenariul de \\%u015fablon\\>", "then": "Atunci\\>", "when": "C\\%u00e2nd\\>"},
|
||||
\"ru": {"and": "\\%u041a \\%u0442\\%u043e\\%u043c\\%u0443 \\%u0436\\%u0435\\>\\|\\%u0418\\>", "background": "\\%u041f\\%u0440\\%u0435\\%u0434\\%u044b\\%u0441\\%u0442\\%u043e\\%u0440\\%u0438\\%u044f\\>", "but": "\\%u041d\\%u043e\\>\\|\\%u0410\\>", "examples": "\\%u0417\\%u043d\\%u0430\\%u0447\\%u0435\\%u043d\\%u0438\\%u044f\\>", "feature": "\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0438\\%u043e\\%u043d\\%u0430\\%u043b\\>\\|\\%u0424\\%u0438\\%u0447\\%u0430\\>", "given": "\\%u0414\\%u043e\\%u043f\\%u0443\\%u0441\\%u0442\\%u0438\\%u043c\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439\\>", "scenario_outline": "\\%u0421\\%u0442\\%u0440\\%u0443\\%u043a\\%u0442\\%u0443\\%u0440\\%u0430 \\%u0441\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u044f\\>", "then": "\\%u0422\\%u043e\\>", "when": "\\%u0415\\%u0441\\%u043b\\%u0438\\>"},
|
||||
\"sk": {"and": "A\\>", "background": "Pozadie\\>", "but": "Ale\\>", "examples": "Pr\\%u00edklady\\>", "feature": "Po\\%u017eiadavka\\>", "given": "Pokia\\%u013e\\>", "scenario": "Scen\\%u00e1r\\>", "scenario_outline": "N\\%u00e1\\%u010drt Scen\\%u00e1ru\\>", "then": "Tak\\>", "when": "Ke\\%u010f\\>"},
|
||||
\"no": {"and": "Og\\>", "background": "Bakgrunn\\>", "but": "Men\\>", "examples": "Eksempler\\>", "feature": "Egenskap\\>", "given": "Gitt\\>", "scenario": "Scenario\\>", "scenario_outline": "Abstrakt Scenario\\>\\|Scenariomal\\>", "then": "S\\%u00e5\\>", "when": "N\\%u00e5r\\>"},
|
||||
\"pl": {"and": "Oraz\\>\\|I\\>", "background": "Za\\%u0142o\\%u017cenia\\>", "but": "Ale\\>", "examples": "Przyk\\%u0142ady\\>", "feature": "W\\%u0142a\\%u015bciwo\\%u015b\\%u0107\\>\\|Potrzeba biznesowa\\>\\|Funkcja\\>\\|Aspekt\\>", "given": "Zak\\%u0142adaj\\%u0105c\\>\\|Maj\\%u0105c\\>", "scenario": "Scenariusz\\>", "scenario_outline": "Szablon scenariusza\\>", "then": "Wtedy\\>", "when": "Je\\%u017celi\\>\\|Je\\%u015bli\\>\\|Kiedy\\>\\|Gdy\\>"},
|
||||
\"pt": {"and": "E\\>", "background": "Cen\\%u00e1rio de Fundo\\>\\|Cenario de Fundo\\>\\|Contexto\\>\\|Fundo\\>", "but": "Mas\\>", "examples": "Cen\\%u00e1rios\\>\\|Exemplos\\>\\|Cenarios\\>", "feature": "Caracter\\%u00edstica\\>\\|Funcionalidade\\>\\|Caracteristica\\>", "given": "Dadas\\>\\|Dados\\>\\|Dada\\>\\|Dado\\>", "scenario": "Cen\\%u00e1rio\\>\\|Cenario\\>", "scenario_outline": "Delinea\\%u00e7\\%u00e3o do Cen\\%u00e1rio\\>\\|Esquema do Cen\\%u00e1rio\\>\\|Delineacao do Cenario\\>\\|Esquema do Cenario\\>", "then": "Ent\\%u00e3o\\>\\|Entao\\>", "when": "Quando\\>"},
|
||||
\"ro": {"and": "\\%u015ei\\>\\|\\%u0218i\\>\\|Si\\>", "background": "Context\\>", "but": "Dar\\>", "examples": "Exemple\\>", "feature": "Func\\%u0163ionalitate\\>\\|Func\\%u021bionalitate\\>\\|Functionalitate\\>", "given": "Da\\%u0163i fiind\\>\\|Da\\%u021bi fiind\\>\\|Dati fiind\\>\\|Date fiind\\>\\|Dat fiind\\>", "scenario": "Scenariu\\>", "scenario_outline": "Structur\\%u0103 scenariu\\>\\|Structura scenariu\\>", "then": "Atunci\\>", "when": "C\\%u00e2nd\\>\\|Cand\\>"},
|
||||
\"ru": {"and": "\\%u041a \\%u0442\\%u043e\\%u043c\\%u0443 \\%u0436\\%u0435\\>\\|\\%u0422\\%u0430\\%u043a\\%u0436\\%u0435\\>\\|\\%u0418\\>", "background": "\\%u041f\\%u0440\\%u0435\\%u0434\\%u044b\\%u0441\\%u0442\\%u043e\\%u0440\\%u0438\\%u044f\\>\\|\\%u041a\\%u043e\\%u043d\\%u0442\\%u0435\\%u043a\\%u0441\\%u0442\\>", "but": "\\%u041d\\%u043e\\>\\|\\%u0410\\>", "examples": "\\%u041f\\%u0440\\%u0438\\%u043c\\%u0435\\%u0440\\%u044b\\>", "feature": "\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0438\\%u043e\\%u043d\\%u0430\\%u043b\\>\\|\\%u0421\\%u0432\\%u043e\\%u0439\\%u0441\\%u0442\\%u0432\\%u043e\\>\\|\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0438\\%u044f\\>", "given": "\\%u0414\\%u043e\\%u043f\\%u0443\\%u0441\\%u0442\\%u0438\\%u043c\\>\\|\\%u041f\\%u0443\\%u0441\\%u0442\\%u044c\\>\\|\\%u0414\\%u0430\\%u043d\\%u043e\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439\\>", "scenario_outline": "\\%u0421\\%u0442\\%u0440\\%u0443\\%u043a\\%u0442\\%u0443\\%u0440\\%u0430 \\%u0441\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u044f\\>", "then": "\\%u0422\\%u043e\\%u0433\\%u0434\\%u0430\\>\\|\\%u0422\\%u043e\\>", "when": "\\%u041a\\%u043e\\%u0433\\%u0434\\%u0430\\>\\|\\%u0415\\%u0441\\%u043b\\%u0438\\>"},
|
||||
\"sk": {"and": "A z\\%u00e1rove\\%u0148\\>\\|A taktie\\%u017e\\>\\|A tie\\%u017e\\>\\|A\\>", "background": "Pozadie\\>", "but": "Ale\\>", "examples": "Pr\\%u00edklady\\>", "feature": "Po\\%u017eiadavka\\>\\|Vlastnos\\%u0165\\>\\|Funkcia\\>", "given": "Za predpokladu\\>\\|Pokia\\%u013e\\>", "scenario": "Scen\\%u00e1r\\>", "scenario_outline": "N\\%u00e1\\%u010drt Scen\\%u00e1ru\\>\\|N\\%u00e1\\%u010drt Scen\\%u00e1ra\\>\\|Osnova Scen\\%u00e1ra\\>", "then": "Potom\\>\\|Tak\\>", "when": "Ke\\%u010f\\>\\|Ak\\>"},
|
||||
\"sr-Cyrl": {"and": "\\%u0418\\>", "background": "\\%u041a\\%u043e\\%u043d\\%u0442\\%u0435\\%u043a\\%u0441\\%u0442\\>\\|\\%u041f\\%u043e\\%u0437\\%u0430\\%u0434\\%u0438\\%u043d\\%u0430\\>\\|\\%u041e\\%u0441\\%u043d\\%u043e\\%u0432\\%u0430\\>", "but": "\\%u0410\\%u043b\\%u0438\\>", "examples": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0458\\%u0438\\>\\|\\%u041f\\%u0440\\%u0438\\%u043c\\%u0435\\%u0440\\%u0438\\>", "feature": "\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0438\\%u043e\\%u043d\\%u0430\\%u043b\\%u043d\\%u043e\\%u0441\\%u0442\\>\\|\\%u041c\\%u043e\\%u0433\\%u0443\\%u045b\\%u043d\\%u043e\\%u0441\\%u0442\\>\\|\\%u041e\\%u0441\\%u043e\\%u0431\\%u0438\\%u043d\\%u0430\\>", "given": "\\%u0417\\%u0430\\%u0434\\%u0430\\%u0442\\%u043e\\>\\|\\%u0417\\%u0430\\%u0434\\%u0430\\%u0442\\%u0435\\>\\|\\%u0417\\%u0430\\%u0434\\%u0430\\%u0442\\%u0438\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u043e\\>\\|\\%u041f\\%u0440\\%u0438\\%u043c\\%u0435\\%u0440\\>", "scenario_outline": "\\%u0421\\%u0442\\%u0440\\%u0443\\%u043a\\%u0442\\%u0443\\%u0440\\%u0430 \\%u0441\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0458\\%u0430\\>\\|\\%u041a\\%u043e\\%u043d\\%u0446\\%u0435\\%u043f\\%u0442\\>\\|\\%u0421\\%u043a\\%u0438\\%u0446\\%u0430\\>", "then": "\\%u041e\\%u043d\\%u0434\\%u0430\\>", "when": "\\%u041a\\%u0430\\%u0434\\%u0430\\>\\|\\%u041a\\%u0430\\%u0434\\>"},
|
||||
\"sr-Latn": {"and": "I\\>", "background": "Kontekst\\>\\|Pozadina\\>\\|Osnova\\>", "but": "Ali\\>", "examples": "Scenariji\\>\\|Primeri\\>", "feature": "Mogu\\%u0107nost\\>\\|Funkcionalnost\\>\\|Mogucnost\\>\\|Osobina\\>", "given": "Zadato\\>\\|Zadate\\>\\|Zatati\\>", "scenario": "Scenario\\>\\|Primer\\>", "scenario_outline": "Struktura scenarija\\>\\|Koncept\\>\\|Skica\\>", "then": "Onda\\>", "when": "Kada\\>\\|Kad\\>"},
|
||||
\"sv": {"and": "Och\\>", "background": "Bakgrund\\>", "but": "Men\\>", "examples": "Exempel\\>", "feature": "Egenskap\\>", "given": "Givet\\>", "scenario": "Scenario\\>", "scenario_outline": "Abstrakt Scenario\\>", "then": "S\\%u00e5\\>", "when": "N\\%u00e4r\\>"},
|
||||
\"sv": {"and": "Och\\>", "background": "Bakgrund\\>", "but": "Men\\>", "examples": "Exempel\\>", "feature": "Egenskap\\>", "given": "Givet\\>", "scenario": "Scenario\\>", "scenario_outline": "Abstrakt Scenario\\>\\|Scenariomall\\>", "then": "S\\%u00e5\\>", "when": "N\\%u00e4r\\>"},
|
||||
\"th": {"and": "\\%u0e41\\%u0e25\\%u0e30\\>", "background": "\\%u0e41\\%u0e19\\%u0e27\\%u0e04\\%u0e34\\%u0e14\\>", "but": "\\%u0e41\\%u0e15\\%u0e48\\>", "examples": "\\%u0e0a\\%u0e38\\%u0e14\\%u0e02\\%u0e2d\\%u0e07\\%u0e40\\%u0e2b\\%u0e15\\%u0e38\\%u0e01\\%u0e32\\%u0e23\\%u0e13\\%u0e4c\\>\\|\\%u0e0a\\%u0e38\\%u0e14\\%u0e02\\%u0e2d\\%u0e07\\%u0e15\\%u0e31\\%u0e27\\%u0e2d\\%u0e22\\%u0e48\\%u0e32\\%u0e07\\>", "feature": "\\%u0e04\\%u0e27\\%u0e32\\%u0e21\\%u0e15\\%u0e49\\%u0e2d\\%u0e07\\%u0e01\\%u0e32\\%u0e23\\%u0e17\\%u0e32\\%u0e07\\%u0e18\\%u0e38\\%u0e23\\%u0e01\\%u0e34\\%u0e08\\>\\|\\%u0e04\\%u0e27\\%u0e32\\%u0e21\\%u0e2a\\%u0e32\\%u0e21\\%u0e32\\%u0e23\\%u0e16\\>\\|\\%u0e42\\%u0e04\\%u0e23\\%u0e07\\%u0e2b\\%u0e25\\%u0e31\\%u0e01\\>", "given": "\\%u0e01\\%u0e33\\%u0e2b\\%u0e19\\%u0e14\\%u0e43\\%u0e2b\\%u0e49\\>", "scenario": "\\%u0e40\\%u0e2b\\%u0e15\\%u0e38\\%u0e01\\%u0e32\\%u0e23\\%u0e13\\%u0e4c\\>", "scenario_outline": "\\%u0e42\\%u0e04\\%u0e23\\%u0e07\\%u0e2a\\%u0e23\\%u0e49\\%u0e32\\%u0e07\\%u0e02\\%u0e2d\\%u0e07\\%u0e40\\%u0e2b\\%u0e15\\%u0e38\\%u0e01\\%u0e32\\%u0e23\\%u0e13\\%u0e4c\\>\\|\\%u0e2a\\%u0e23\\%u0e38\\%u0e1b\\%u0e40\\%u0e2b\\%u0e15\\%u0e38\\%u0e01\\%u0e32\\%u0e23\\%u0e13\\%u0e4c\\>", "then": "\\%u0e14\\%u0e31\\%u0e07\\%u0e19\\%u0e31\\%u0e49\\%u0e19\\>", "when": "\\%u0e40\\%u0e21\\%u0e37\\%u0e48\\%u0e2d\\>"},
|
||||
\"tl": {"and": "\\%u0c2e\\%u0c30\\%u0c3f\\%u0c2f\\%u0c41\\>", "background": "\\%u0c28\\%u0c47\\%u0c2a\\%u0c25\\%u0c4d\\%u0c2f\\%u0c02\\>", "but": "\\%u0c15\\%u0c3e\\%u0c28\\%u0c3f\\>", "examples": "\\%u0c09\\%u0c26\\%u0c3e\\%u0c39\\%u0c30\\%u0c23\\%u0c32\\%u0c41\\>", "feature": "\\%u0c17\\%u0c41\\%u0c23\\%u0c2e\\%u0c41\\>", "given": "\\%u0c1a\\%u0c46\\%u0c2a\\%u0c4d\\%u0c2a\\%u0c2c\\%u0c21\\%u0c3f\\%u0c28\\%u0c26\\%u0c3f\\>", "scenario": "\\%u0c38\\%u0c28\\%u0c4d\\%u0c28\\%u0c3f\\%u0c35\\%u0c47\\%u0c36\\%u0c02\\>", "scenario_outline": "\\%u0c15\\%u0c25\\%u0c28\\%u0c02\\>", "then": "\\%u0c05\\%u0c2a\\%u0c4d\\%u0c2a\\%u0c41\\%u0c21\\%u0c41\\>", "when": "\\%u0c08 \\%u0c2a\\%u0c30\\%u0c3f\\%u0c38\\%u0c4d\\%u0c25\\%u0c3f\\%u0c24\\%u0c3f\\%u0c32\\%u0c4b\\>"},
|
||||
\"tr": {"and": "Ve\\>", "background": "Ge\\%u00e7mi\\%u015f\\>", "but": "Fakat\\>\\|Ama\\>", "examples": "\\%u00d6rnekler\\>", "feature": "\\%u00d6zellik\\>", "given": "Diyelim ki\\>", "scenario": "Senaryo\\>", "scenario_outline": "Senaryo tasla\\%u011f\\%u0131\\>", "then": "O zaman\\>", "when": "E\\%u011fer ki\\>"},
|
||||
\"uk": {"and": "\\%u0406\\>", "background": "\\%u041f\\%u0435\\%u0440\\%u0435\\%u0434\\%u0443\\%u043c\\%u043e\\%u0432\\%u0430\\>", "but": "\\%u0410\\%u043b\\%u0435\\>", "examples": "\\%u041f\\%u0440\\%u0438\\%u043a\\%u043b\\%u0430\\%u0434\\%u0438\\>", "feature": "\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0456\\%u043e\\%u043d\\%u0430\\%u043b\\>", "given": "\\%u041f\\%u0440\\%u0438\\%u043f\\%u0443\\%u0441\\%u0442\\%u0438\\%u043c\\%u043e, \\%u0449\\%u043e\\>\\|\\%u041f\\%u0440\\%u0438\\%u043f\\%u0443\\%u0441\\%u0442\\%u0438\\%u043c\\%u043e\\>\\|\\%u041d\\%u0435\\%u0445\\%u0430\\%u0439\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0456\\%u0439\\>", "scenario_outline": "\\%u0421\\%u0442\\%u0440\\%u0443\\%u043a\\%u0442\\%u0443\\%u0440\\%u0430 \\%u0441\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0456\\%u044e\\>", "then": "\\%u0422\\%u043e\\>", "when": "\\%u042f\\%u043a\\%u0449\\%u043e\\>"},
|
||||
\"tt": {"and": "\\%u04ba\\%u04d9\\%u043c\\>\\|\\%u0412\\%u04d9\\>", "background": "\\%u041a\\%u0435\\%u0440\\%u0435\\%u0448\\>", "but": "\\%u041b\\%u04d9\\%u043a\\%u0438\\%u043d\\>\\|\\%u04d8\\%u043c\\%u043c\\%u0430\\>", "examples": "\\%u04ae\\%u0440\\%u043d\\%u04d9\\%u043a\\%u043b\\%u04d9\\%u0440\\>\\|\\%u041c\\%u0438\\%u0441\\%u0430\\%u043b\\%u043b\\%u0430\\%u0440\\>", "feature": "\\%u04ae\\%u0437\\%u0435\\%u043d\\%u0447\\%u04d9\\%u043b\\%u0435\\%u043a\\%u043b\\%u0435\\%u043b\\%u0435\\%u043a\\>\\|\\%u041c\\%u04e9\\%u043c\\%u043a\\%u0438\\%u043d\\%u043b\\%u0435\\%u043a\\>", "given": "\\%u04d8\\%u0439\\%u0442\\%u0438\\%u043a\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439\\>", "scenario_outline": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439\\%u043d\\%u044b\\%u04a3 \\%u0442\\%u04e9\\%u0437\\%u0435\\%u043b\\%u0435\\%u0448\\%u0435\\>", "then": "\\%u041d\\%u04d9\\%u0442\\%u0438\\%u0497\\%u04d9\\%u0434\\%u04d9\\>", "when": "\\%u04d8\\%u0433\\%u04d9\\%u0440\\>"},
|
||||
\"uk": {"and": "\\%u0410 \\%u0442\\%u0430\\%u043a\\%u043e\\%u0436\\>\\|\\%u0422\\%u0430\\>\\|\\%u0406\\>", "background": "\\%u041f\\%u0435\\%u0440\\%u0435\\%u0434\\%u0443\\%u043c\\%u043e\\%u0432\\%u0430\\>", "but": "\\%u0410\\%u043b\\%u0435\\>", "examples": "\\%u041f\\%u0440\\%u0438\\%u043a\\%u043b\\%u0430\\%u0434\\%u0438\\>", "feature": "\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0456\\%u043e\\%u043d\\%u0430\\%u043b\\>", "given": "\\%u041f\\%u0440\\%u0438\\%u043f\\%u0443\\%u0441\\%u0442\\%u0438\\%u043c\\%u043e, \\%u0449\\%u043e\\>\\|\\%u041f\\%u0440\\%u0438\\%u043f\\%u0443\\%u0441\\%u0442\\%u0438\\%u043c\\%u043e\\>\\|\\%u041d\\%u0435\\%u0445\\%u0430\\%u0439\\>\\|\\%u0414\\%u0430\\%u043d\\%u043e\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0456\\%u0439\\>", "scenario_outline": "\\%u0421\\%u0442\\%u0440\\%u0443\\%u043a\\%u0442\\%u0443\\%u0440\\%u0430 \\%u0441\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0456\\%u044e\\>", "then": "\\%u0422\\%u043e\\%u0434\\%u0456\\>\\|\\%u0422\\%u043e\\>", "when": "\\%u042f\\%u043a\\%u0449\\%u043e\\>\\|\\%u041a\\%u043e\\%u043b\\%u0438\\>"},
|
||||
\"uz": {"and": "\\%u0412\\%u0430\\>", "background": "\\%u0422\\%u0430\\%u0440\\%u0438\\%u0445\\>", "but": "\\%u041b\\%u0435\\%u043a\\%u0438\\%u043d\\>\\|\\%u0411\\%u0438\\%u0440\\%u043e\\%u043a\\>\\|\\%u0410\\%u043c\\%u043c\\%u043e\\>", "examples": "\\%u041c\\%u0438\\%u0441\\%u043e\\%u043b\\%u043b\\%u0430\\%u0440\\>", "feature": "\\%u0424\\%u0443\\%u043d\\%u043a\\%u0446\\%u0438\\%u043e\\%u043d\\%u0430\\%u043b\\>", "given": "\\%u0410\\%u0433\\%u0430\\%u0440\\>", "scenario": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439\\>", "scenario_outline": "\\%u0421\\%u0446\\%u0435\\%u043d\\%u0430\\%u0440\\%u0438\\%u0439 \\%u0441\\%u0442\\%u0440\\%u0443\\%u043a\\%u0442\\%u0443\\%u0440\\%u0430\\%u0441\\%u0438\\>", "then": "\\%u0423\\%u043d\\%u0434\\%u0430\\>", "when": "\\%u0410\\%u0433\\%u0430\\%u0440\\>"},
|
||||
\"vi": {"and": "V\\%u00e0\\>", "background": "B\\%u1ed1i c\\%u1ea3nh\\>", "but": "Nh\\%u01b0ng\\>", "examples": "D\\%u1eef li\\%u1ec7u\\>", "feature": "T\\%u00ednh n\\%u0103ng\\>", "given": "Bi\\%u1ebft\\>\\|Cho\\>", "scenario": "T\\%u00ecnh hu\\%u1ed1ng\\>\\|K\\%u1ecbch b\\%u1ea3n\\>", "scenario_outline": "Khung t\\%u00ecnh hu\\%u1ed1ng\\>\\|Khung k\\%u1ecbch b\\%u1ea3n\\>", "then": "Th\\%u00ec\\>", "when": "Khi\\>"},
|
||||
\"zh-CN": {"and": "\\%u800c\\%u4e14", "background": "\\%u80cc\\%u666f\\>", "but": "\\%u4f46\\%u662f", "examples": "\\%u4f8b\\%u5b50\\>", "feature": "\\%u529f\\%u80fd\\>", "given": "\\%u5047\\%u5982", "scenario": "\\%u573a\\%u666f\\>", "scenario_outline": "\\%u573a\\%u666f\\%u5927\\%u7eb2\\>", "then": "\\%u90a3\\%u4e48", "when": "\\%u5f53"},
|
||||
\"zh-TW": {"and": "\\%u800c\\%u4e14\\|\\%u4e26\\%u4e14", "background": "\\%u80cc\\%u666f\\>", "but": "\\%u4f46\\%u662f", "examples": "\\%u4f8b\\%u5b50\\>", "feature": "\\%u529f\\%u80fd\\>", "given": "\\%u5047\\%u8a2d", "scenario": "\\%u5834\\%u666f\\>\\|\\%u5287\\%u672c\\>", "scenario_outline": "\\%u5834\\%u666f\\%u5927\\%u7db1\\>\\|\\%u5287\\%u672c\\%u5927\\%u7db1\\>", "then": "\\%u90a3\\%u9ebc", "when": "\\%u7576"}}
|
||||
\"zh-CN": {"and": "\\%u800c\\%u4e14\\|\\%u5e76\\%u4e14\\|\\%u540c\\%u65f6", "background": "\\%u80cc\\%u666f\\>", "but": "\\%u4f46\\%u662f", "examples": "\\%u4f8b\\%u5b50\\>", "feature": "\\%u529f\\%u80fd\\>", "given": "\\%u5047\\%u5982\\|\\%u5047\\%u8bbe\\|\\%u5047\\%u5b9a", "scenario": "\\%u573a\\%u666f\\>\\|\\%u5267\\%u672c\\>", "scenario_outline": "\\%u573a\\%u666f\\%u5927\\%u7eb2\\>\\|\\%u5267\\%u672c\\%u5927\\%u7eb2\\>", "then": "\\%u90a3\\%u4e48", "when": "\\%u5f53"},
|
||||
\"zh-TW": {"and": "\\%u800c\\%u4e14\\|\\%u4e26\\%u4e14\\|\\%u540c\\%u6642", "background": "\\%u80cc\\%u666f\\>", "but": "\\%u4f46\\%u662f", "examples": "\\%u4f8b\\%u5b50\\>", "feature": "\\%u529f\\%u80fd\\>", "given": "\\%u5047\\%u5982\\|\\%u5047\\%u8a2d\\|\\%u5047\\%u5b9a", "scenario": "\\%u5834\\%u666f\\>\\|\\%u5287\\%u672c\\>", "scenario_outline": "\\%u5834\\%u666f\\%u5927\\%u7db1\\>\\|\\%u5287\\%u672c\\%u5927\\%u7db1\\>", "then": "\\%u90a3\\%u9ebc", "when": "\\%u7576"}}
|
||||
|
||||
function! s:pattern(key)
|
||||
let language = matchstr(getline(1),'#\s*language:\s*\zs\S\+')
|
||||
@@ -73,13 +83,15 @@ function! s:pattern(key)
|
||||
endfunction
|
||||
|
||||
function! s:Add(name)
|
||||
let next = " skipempty skipwhite nextgroup=".join(map(["Region","AndRegion","ButRegion","Comment","Table"],'"cucumber".a:name.v:val'),",")
|
||||
let next = " skipempty skipwhite nextgroup=".join(map(["Region","AndRegion","ButRegion","Comment","String","Table"],'"cucumber".a:name.v:val'),",")
|
||||
exe "syn region cucumber".a:name.'Region matchgroup=cucumber'.a:name.' start="\%(^\s*\)\@<=\%('.s:pattern(tolower(a:name)).'\)" end="$"'.next
|
||||
exe 'syn region cucumber'.a:name.'AndRegion matchgroup=cucumber'.a:name.'And start="\%(^\s*\)\@<='.s:pattern('and').'" end="$" contained'.next
|
||||
exe 'syn region cucumber'.a:name.'ButRegion matchgroup=cucumber'.a:name.'But start="\%(^\s*\)\@<='.s:pattern('but').'" end="$" contained'.next
|
||||
exe 'syn match cucumber'.a:name.'Comment "\%(^\s*\)\@<=#.*" contained'.next
|
||||
exe 'syn region cucumber'.a:name.'String start=+\%(^\s*\)\@<="""+ end=+"""+ contained'.next
|
||||
exe 'syn match cucumber'.a:name.'Table "\%(^\s*\)\@<=|.*" contained contains=cucumberDelimiter'.next
|
||||
exe 'hi def link cucumber'.a:name.'Comment cucumberComment'
|
||||
exe 'hi def link cucumber'.a:name.'String cucumberString'
|
||||
exe 'hi def link cucumber'.a:name.'But cucumber'.a:name.'And'
|
||||
exe 'hi def link cucumber'.a:name.'And cucumber'.a:name
|
||||
exe 'syn cluster cucumberStepRegions add=cucumber'.a:name.'Region,cucumber'.a:name.'AndRegion,cucumber'.a:name.'ButRegion'
|
||||
@@ -99,9 +111,8 @@ exe 'syn match cucumberExamples "\%(^\s*\)\@<='.s:pattern('examples').':" nextgr
|
||||
|
||||
syn match cucumberPlaceholder "<[^<>]*>" contained containedin=@cucumberStepRegions
|
||||
syn match cucumberExampleTable "\%(^\s*\)\@<=|.*" contains=cucumberDelimiter
|
||||
syn match cucumberDelimiter "|" contained
|
||||
syn match cucumberTags "\%(^\s*\)\@<=\%(@[^@[:space:]]\+\s\+\)*@[^@[:space:]]\+\s*$"
|
||||
syn region cucumberString start=+\%(^\s*\)\@<="""+ end=+"""+
|
||||
syn match cucumberDelimiter "\\\@<!\%(\\\\\)*\zs|" contained
|
||||
syn match cucumberTags "\%(^\s*\)\@<=\%(@[^@[:space:]]\+\s\+\)*@[^@[:space:]]\+\s*$" contains=@NoSpell
|
||||
|
||||
call s:Add('Then')
|
||||
call s:Add('When')
|
||||
|
@@ -1,22 +1,23 @@
|
||||
" Vim syntax file for the D programming language (version 1.053 and 2.047).
|
||||
" Vim syntax file for the D programming language (version 1.076 and 2.063).
|
||||
"
|
||||
" Language: D
|
||||
" Maintainer: Jesse Phillips <Jesse.K.Phillips+D@gmail.com>
|
||||
" Last Change: 2012 Jan 11
|
||||
" Version: 0.24
|
||||
" Last Change: 2013 May 21
|
||||
" Version: 0.25
|
||||
"
|
||||
" Contributors:
|
||||
" - Jason Mills <jasonmills@nf.sympatico.ca>: original Maintainer
|
||||
" - Jason Mills: original Maintainer
|
||||
" - Kirk McDonald
|
||||
" - Tim Keating
|
||||
" - Frank Benoit
|
||||
" - Shougo Matsushita <Shougo.Matsu@gmail.com>
|
||||
" - Shougo Matsushita
|
||||
" - Ellery Newcomer
|
||||
" - Steven N. Oliver
|
||||
" - Sohgo Takeuchi
|
||||
" - Robert Clipsham
|
||||
"
|
||||
" Please submit bugs/comments/suggestions to the github repo:
|
||||
" https://github.com/he-the-great/d.vim
|
||||
" https://github.com/JesseKPhillips/d.vim
|
||||
"
|
||||
" Options:
|
||||
" d_comment_strings - Set to highlight strings and numbers in comments.
|
||||
@@ -40,7 +41,8 @@ let b:current_syntax = "d"
|
||||
|
||||
" Keyword definitions
|
||||
"
|
||||
syn keyword dExternal import module
|
||||
syn keyword dExternal contained import module
|
||||
syn keyword dAssert assert
|
||||
syn keyword dConditional if else switch
|
||||
syn keyword dBranch goto break continue
|
||||
syn keyword dRepeat while for do foreach foreach_reverse
|
||||
@@ -48,6 +50,7 @@ syn keyword dBoolean true false
|
||||
syn keyword dConstant null
|
||||
syn keyword dConstant __FILE__ __LINE__ __EOF__ __VERSION__
|
||||
syn keyword dConstant __DATE__ __TIME__ __TIMESTAMP__ __VENDOR__
|
||||
syn keyword dConstant __MODULE__ __FUNCTION__ __PRETTY_FUNCTION__
|
||||
syn keyword dTypedef alias typedef
|
||||
syn keyword dStructure template interface class struct union
|
||||
syn keyword dEnum enum
|
||||
@@ -58,7 +61,7 @@ if exists("d_hl_operator_overload")
|
||||
syn keyword dOpOverload opSub opSub_r opMul opDiv opDiv_r opMod
|
||||
syn keyword dOpOverload opMod_r opAnd opOr opXor opShl opShl_r opShr
|
||||
syn keyword dOpOverload opShr_r opUShr opUShr_r opCat
|
||||
syn keyword dOpOverload opCat_r opEquals opEquals opCmp
|
||||
syn keyword dOpOverload opCat_r opEquals opCmp
|
||||
syn keyword dOpOverload opAssign opAddAssign opSubAssign opMulAssign
|
||||
syn keyword dOpOverload opDivAssign opModAssign opAndAssign
|
||||
syn keyword dOpOverload opOrAssign opXorAssign opShlAssign
|
||||
@@ -73,7 +76,7 @@ if exists("d_hl_operator_overload")
|
||||
endif
|
||||
|
||||
syn keyword dType byte ubyte short ushort int uint long ulong cent ucent
|
||||
syn keyword dType void bool bit
|
||||
syn keyword dType void bool Object
|
||||
syn keyword dType float double real
|
||||
syn keyword dType ushort int uint long ulong float
|
||||
syn keyword dType char wchar dchar string wstring dstring
|
||||
@@ -94,22 +97,31 @@ syn keyword dDebug deprecated unittest invariant
|
||||
syn keyword dExceptions throw try catch finally
|
||||
syn keyword dScopeDecl public protected private export package
|
||||
syn keyword dStatement debug return with
|
||||
syn keyword dStatement function delegate __ctfe mixin macro
|
||||
syn keyword dStorageClass in out inout ref lazy body
|
||||
syn keyword dStorageClass pure nothrow
|
||||
syn keyword dStatement function delegate __ctfe mixin macro __simd
|
||||
syn keyword dStatement in out body
|
||||
syn keyword dStorageClass contained in out scope
|
||||
syn keyword dStorageClass inout ref lazy pure nothrow
|
||||
syn keyword dStorageClass auto static override final abstract volatile
|
||||
syn keyword dStorageClass __gshared __thread
|
||||
syn keyword dStorageClass __gshared __vector
|
||||
syn keyword dStorageClass synchronized shared immutable const lazy
|
||||
syn keyword dPragma pragma
|
||||
syn keyword dIdentifier _arguments _argptr __vptr __monitor _ctor _dtor
|
||||
syn keyword dIdentifier _arguments _argptr __vptr __monitor
|
||||
syn keyword dIdentifier _ctor _dtor __argTypes __overloadset
|
||||
syn keyword dScopeIdentifier contained exit success failure
|
||||
syn keyword dTraitsIdentifier contained isAbstractClass isArithmetic isAssociativeArray
|
||||
syn keyword dTraitsIdentifier contained isFinalClass isFloating isIntegral isScalar
|
||||
syn keyword dTraitsIdentifier contained isStaticArray isUnsigned isVirtualFunction
|
||||
syn keyword dTraitsIdentifier contained isAbstractFunction isFinalFunction isStaticFunction
|
||||
syn keyword dTraitsIdentifier contained isRef isOut isLazy hasMember identifier getMember
|
||||
syn keyword dTraitsIdentifier contained getOverloads getVirtualFunctions parent compiles
|
||||
syn keyword dTraitsIdentifier contained classInstanceSize allMembers derivedMembers isSame
|
||||
syn keyword dTraitsIdentifier contained isAbstractClass isArithmetic
|
||||
syn keyword dTraitsIdentifier contained isAssociativeArray isFinalClass
|
||||
syn keyword dTraitsIdentifier contained isPOD isNested isFloating
|
||||
syn keyword dTraitsIdentifier contained isIntegral isScalar isStaticArray
|
||||
syn keyword dTraitsIdentifier contained isUnsigned isVirtualFunction
|
||||
syn keyword dTraitsIdentifier contained isVirtualMethod isAbstractFunction
|
||||
syn keyword dTraitsIdentifier contained isFinalFunction isStaticFunction
|
||||
syn keyword dTraitsIdentifier contained isRef isOut isLazy hasMember
|
||||
syn keyword dTraitsIdentifier contained identifier getAttributes getMember
|
||||
syn keyword dTraitsIdentifier contained getOverloads getProtection
|
||||
syn keyword dTraitsIdentifier contained getVirtualFunctions
|
||||
syn keyword dTraitsIdentifier contained getVirtualMethods parent
|
||||
syn keyword dTraitsIdentifier contained classInstanceSize allMembers
|
||||
syn keyword dTraitsIdentifier contained derivedMembers isSame compiles
|
||||
syn keyword dPragmaIdentifier contained lib msg startaddress GNU_asm
|
||||
syn keyword dExternIdentifier contained Windows Pascal Java System D
|
||||
syn keyword dAttribute contained safe trusted system
|
||||
syn keyword dAttribute contained property disable
|
||||
@@ -124,6 +136,8 @@ syn keyword dVersionIdentifier contained D_InlineAsm_X86 D_InlineAsm_X86_64
|
||||
syn keyword dVersionIdentifier contained D_Version2 D_Coverage D_Ddoc D_LP64 D_PIC
|
||||
syn keyword dVersionIdentifier contained unittest none all
|
||||
|
||||
syn cluster dComment contains=dNestedComment,dBlockComment,dLineComment
|
||||
|
||||
" Highlight the sharpbang
|
||||
syn match dSharpBang "\%^#!.*" display
|
||||
|
||||
@@ -131,45 +145,42 @@ syn match dSharpBang "\%^#!.*" display
|
||||
syn match dAnnotation "@[_$a-zA-Z][_$a-zA-Z0-9_]*\>" contains=dAttribute
|
||||
|
||||
" Version Identifiers
|
||||
syn match dVersion "[^.]\<version\>"hs=s+1 nextgroup=dVersionInside
|
||||
syn match dVersion "^\<version\>" nextgroup=dVersionInside
|
||||
syn match dVersionInside "\s*([_a-zA-Z][_a-zA-Z0-9]*\>" transparent contained contains=dVersionIdentifier
|
||||
|
||||
" Scope StorageClass
|
||||
syn match dStorageClass "\<scope\>"
|
||||
|
||||
" Traits Expression
|
||||
syn match dStatement "\<__traits\>"
|
||||
|
||||
" Extern Modifier
|
||||
syn match dExternal "\<extern\>"
|
||||
syn match dVersion "\<version\>"
|
||||
syn match dVersion "\<version\s*([_a-zA-Z][_a-zA-Z0-9]*\>"he=s+7 contains=dVersionIdentifier
|
||||
|
||||
" Scope Identifiers
|
||||
syn match dScope "\<scope\s*([_a-zA-Z][_a-zA-Z0-9]*\>"he=s+5 contains=dScopeIdentifier
|
||||
syn match dStatement "\<scope\>"
|
||||
syn match dStatement "\<scope\s*([_a-zA-Z][_a-zA-Z0-9]*\>"he=s+5 contains=dScopeIdentifier
|
||||
|
||||
" Traits Identifiers
|
||||
syn match dTraits "\<__traits\s*([_a-zA-Z][_a-zA-Z0-9]*\>"he=s+8 contains=dTraitsIdentifier
|
||||
" Traits Statement
|
||||
syn match dStatement "\<__traits\>"
|
||||
syn match dStatement "\<__traits\s*([_a-zA-Z][_a-zA-Z0-9]*\>"he=s+8 contains=dTraitsIdentifier
|
||||
|
||||
" Pragma Statement
|
||||
syn match dPragma "\<pragma\>"
|
||||
syn match dPragma "\<pragma\s*([_a-zA-Z][_a-zA-Z0-9]*\>"he=s+8 contains=dPragmaIdentifier
|
||||
|
||||
" Necessary to highlight C++ in extern modifiers.
|
||||
syn match dExternIdentifier "C\(++\)\?" contained
|
||||
|
||||
" Extern Identifiers
|
||||
syn match dExternal "\<extern\>"
|
||||
syn match dExtern "\<extern\s*([_a-zA-Z][_a-zA-Z0-9\+]*\>"he=s+6 contains=dExternIdentifier
|
||||
|
||||
" String is a statement and a module name.
|
||||
syn match dType "[^.]\<string\>"ms=s+1
|
||||
syn match dType "^\<string\>"
|
||||
" Make import a region to prevent highlighting keywords
|
||||
syn region dImport start="import" end=";" contains=dExternal,@dComment
|
||||
|
||||
" Assert is a statement and a module name.
|
||||
syn match dAssert "[^.]\<assert\>"ms=s+1
|
||||
syn match dAssert "^\<assert\>"
|
||||
" Make module a region to prevent highlighting keywords
|
||||
syn region dImport start="module" end=";" contains=dExternal,@dComment
|
||||
|
||||
" dTokens is used by the token string highlighting
|
||||
syn cluster dTokens contains=dExternal,dConditional,dBranch,dRepeat,dBoolean
|
||||
syn cluster dTokens add=dConstant,dTypedef,dStructure,dOperator,dOpOverload
|
||||
syn cluster dTokens add=dType,dDebug,dExceptions,dScopeDecl,dStatement
|
||||
syn cluster dTokens add=dStorageClass,dPragma,dAssert,dAnnotation
|
||||
syn cluster dTokens add=dStorageClass,dPragma,dAssert,dAnnotation,dEnum
|
||||
|
||||
" Create a match for parameter lists to identify storage class
|
||||
syn region paramlist start="(" end=")" contains=@dTokens
|
||||
|
||||
" Labels
|
||||
"
|
||||
@@ -358,146 +369,192 @@ hi def link dLineComment Comment
|
||||
hi def link dBlockComment Comment
|
||||
hi def link dNestedComment Comment
|
||||
hi def link dExternal Include
|
||||
hi def link dPragma PreProc
|
||||
hi def link dAnnotation PreProc
|
||||
hi def link dSharpBang PreProc
|
||||
hi def link dAttribute StorageClass
|
||||
hi def link dIdentifier Identifier
|
||||
hi def link dVersion dStatement
|
||||
hi def link dVersionIdentifier Identifier
|
||||
hi def link dScope dStorageClass
|
||||
hi def link dScopeIdentifier Identifier
|
||||
hi def link dTraits dStatement
|
||||
hi def link dTraitsIdentifier Identifier
|
||||
hi def link dPragma PreProc
|
||||
hi def link dPragmaIdentifier Identifier
|
||||
hi def link dExtern dExternal
|
||||
hi def link dExternIdentifier Identifier
|
||||
|
||||
" Marks contents of the asm statment body as special
|
||||
|
||||
syn match dAsmStatement "\<asm\>"
|
||||
syn region dAsmBody start="asm[\n]*\s*{"hs=e+1 end="}"he=e-1 contains=dAsmStatement,dAsmOpCode
|
||||
syn region dAsmBody start="asm[\n]*\s*{"hs=e+1 end="}"he=e-1 contains=dAsmStatement,dAsmOpCode,@dComment,DUserLabel
|
||||
|
||||
hi def link dAsmBody dUnicode
|
||||
hi def link dAsmStatement dStatement
|
||||
hi def link dAsmOpCode Identifier
|
||||
|
||||
syn keyword dAsmOpCode contained aaa aad aam aas adc
|
||||
syn keyword dAsmOpCode contained add addpd addps addsd addss
|
||||
syn keyword dAsmOpCode contained and andnpd andnps andpd andps
|
||||
syn keyword dAsmOpCode contained arpl bound bsf bsr bswap
|
||||
syn keyword dAsmOpCode contained bt btc btr bts call
|
||||
syn keyword dAsmOpCode contained cbw cdq clc cld clflush
|
||||
syn keyword dAsmOpCode contained cli clts cmc cmova cmovae
|
||||
syn keyword dAsmOpCode contained cmovb cmovbe cmovc cmove cmovg
|
||||
syn keyword dAsmOpCode contained cmovge cmovl cmovle cmovna cmovnae
|
||||
syn keyword dAsmOpCode contained cmovnb cmovnbe cmovnc cmovne cmovng
|
||||
syn keyword dAsmOpCode contained cmovnge cmovnl cmovnle cmovno cmovnp
|
||||
syn keyword dAsmOpCode contained cmovns cmovnz cmovo cmovp cmovpe
|
||||
syn keyword dAsmOpCode contained cmovpo cmovs cmovz cmp cmppd
|
||||
syn keyword dAsmOpCode contained cmpps cmps cmpsb cmpsd cmpss
|
||||
syn keyword dAsmOpCode contained cmpsw cmpxch8b cmpxchg comisd comiss
|
||||
syn keyword dAsmOpCode contained cpuid cvtdq2pd cvtdq2ps cvtpd2dq cvtpd2pi
|
||||
syn keyword dAsmOpCode contained cvtpd2ps cvtpi2pd cvtpi2ps cvtps2dq cvtps2pd
|
||||
syn keyword dAsmOpCode contained cvtps2pi cvtsd2si cvtsd2ss cvtsi2sd cvtsi2ss
|
||||
syn keyword dAsmOpCode contained cvtss2sd cvtss2si cvttpd2dq cvttpd2pi cvttps2dq
|
||||
syn keyword dAsmOpCode contained cvttps2pi cvttsd2si cvttss2si cwd cwde
|
||||
syn keyword dAsmOpCode contained da daa das db dd
|
||||
syn keyword dAsmOpCode contained de dec df di div
|
||||
syn keyword dAsmOpCode contained divpd divps divsd divss dl
|
||||
syn keyword dAsmOpCode contained dq ds dt dw emms
|
||||
syn keyword dAsmOpCode contained enter f2xm1 fabs fadd faddp
|
||||
syn keyword dAsmOpCode contained fbld fbstp fchs fclex fcmovb
|
||||
syn keyword dAsmOpCode contained fcmovbe fcmove fcmovnb fcmovnbe fcmovne
|
||||
syn keyword dAsmOpCode contained fcmovnu fcmovu fcom fcomi fcomip
|
||||
syn keyword dAsmOpCode contained fcomp fcompp fcos fdecstp fdisi
|
||||
syn keyword dAsmOpCode contained fdiv fdivp fdivr fdivrp feni
|
||||
syn keyword dAsmOpCode contained ffree fiadd ficom ficomp fidiv
|
||||
syn keyword dAsmOpCode contained fidivr fild fimul fincstp finit
|
||||
syn keyword dAsmOpCode contained fist fistp fisub fisubr fld
|
||||
syn keyword dAsmOpCode contained fld1 fldcw fldenv fldl2e fldl2t
|
||||
syn keyword dAsmOpCode contained fldlg2 fldln2 fldpi fldz fmul
|
||||
syn keyword dAsmOpCode contained fmulp fnclex fndisi fneni fninit
|
||||
syn keyword dAsmOpCode contained fnop fnsave fnstcw fnstenv fnstsw
|
||||
syn keyword dAsmOpCode contained fpatan fprem fprem1 fptan frndint
|
||||
syn keyword dAsmOpCode contained frstor fsave fscale fsetpm fsin
|
||||
syn keyword dAsmOpCode contained fsincos fsqrt fst fstcw fstenv
|
||||
syn keyword dAsmOpCode contained fstp fstsw fsub fsubp fsubr
|
||||
syn keyword dAsmOpCode contained fsubrp ftst fucom fucomi fucomip
|
||||
syn keyword dAsmOpCode contained fucomp fucompp fwait fxam fxch
|
||||
syn keyword dAsmOpCode contained fxrstor fxsave fxtract fyl2x fyl2xp1
|
||||
syn keyword dAsmOpCode contained hlt idiv imul in inc
|
||||
syn keyword dAsmOpCode contained ins insb insd insw int
|
||||
syn keyword dAsmOpCode contained into invd invlpg iret iretd
|
||||
syn keyword dAsmOpCode contained ja jae jb jbe jc
|
||||
syn keyword dAsmOpCode contained jcxz je jecxz jg jge
|
||||
syn keyword dAsmOpCode contained jl jle jmp jna jnae
|
||||
syn keyword dAsmOpCode contained jnb jnbe jnc jne jng
|
||||
syn keyword dAsmOpCode contained jnge jnl jnle jno jnp
|
||||
syn keyword dAsmOpCode contained jns jnz jo jp jpe
|
||||
syn keyword dAsmOpCode contained jpo js jz lahf lar
|
||||
syn keyword dAsmOpCode contained ldmxcsr lds lea leave les
|
||||
syn keyword dAsmOpCode contained lfence lfs lgdt lgs lidt
|
||||
syn keyword dAsmOpCode contained lldt lmsw lock lods lodsb
|
||||
syn keyword dAsmOpCode contained lodsd lodsw loop loope loopne
|
||||
syn keyword dAsmOpCode contained loopnz loopz lsl lss ltr
|
||||
syn keyword dAsmOpCode contained maskmovdqu maskmovq maxpd maxps maxsd
|
||||
syn keyword dAsmOpCode contained maxss mfence minpd minps minsd
|
||||
syn keyword dAsmOpCode contained minss mov movapd movaps movd
|
||||
syn keyword dAsmOpCode contained movdq2q movdqa movdqu movhlps movhpd
|
||||
syn keyword dAsmOpCode contained movhps movlhps movlpd movlps movmskpd
|
||||
syn keyword dAsmOpCode contained movmskps movntdq movnti movntpd movntps
|
||||
syn keyword dAsmOpCode contained movntq movq movq2dq movs movsb
|
||||
syn keyword dAsmOpCode contained movsd movss movsw movsx movupd
|
||||
syn keyword dAsmOpCode contained movups movzx mul mulpd mulps
|
||||
syn keyword dAsmOpCode contained mulsd mulss neg nop not
|
||||
syn keyword dAsmOpCode contained or orpd orps out outs
|
||||
syn keyword dAsmOpCode contained outsb outsd outsw packssdw packsswb
|
||||
syn keyword dAsmOpCode contained packuswb paddb paddd paddq paddsb
|
||||
syn keyword dAsmOpCode contained paddsw paddusb paddusw paddw pand
|
||||
syn keyword dAsmOpCode contained pandn pavgb pavgw pcmpeqb pcmpeqd
|
||||
syn keyword dAsmOpCode contained pcmpeqw pcmpgtb pcmpgtd pcmpgtw pextrw
|
||||
syn keyword dAsmOpCode contained pinsrw pmaddwd pmaxsw pmaxub pminsw
|
||||
syn keyword dAsmOpCode contained pminub pmovmskb pmulhuw pmulhw pmullw
|
||||
syn keyword dAsmOpCode contained pmuludq pop popa popad popf
|
||||
syn keyword dAsmOpCode contained popfd por prefetchnta prefetcht0 prefetcht1
|
||||
syn keyword dAsmOpCode contained prefetcht2 psadbw pshufd pshufhw pshuflw
|
||||
syn keyword dAsmOpCode contained pshufw pslld pslldq psllq psllw
|
||||
syn keyword dAsmOpCode contained psrad psraw psrld psrldq psrlq
|
||||
syn keyword dAsmOpCode contained psrlw psubb psubd psubq psubsb
|
||||
syn keyword dAsmOpCode contained psubsw psubusb psubusw psubw punpckhbw
|
||||
syn keyword dAsmOpCode contained punpckhdq punpckhqdq punpckhwd punpcklbw punpckldq
|
||||
syn keyword dAsmOpCode contained punpcklqdq punpcklwd push pusha pushad
|
||||
syn keyword dAsmOpCode contained pushf pushfd pxor rcl rcpps
|
||||
syn keyword dAsmOpCode contained rcpss rcr rdmsr rdpmc rdtsc
|
||||
syn keyword dAsmOpCode contained rep repe repne repnz repz
|
||||
syn keyword dAsmOpCode contained ret retf rol ror rsm
|
||||
syn keyword dAsmOpCode contained rsqrtps rsqrtss sahf sal sar
|
||||
syn keyword dAsmOpCode contained sbb scas scasb scasd scasw
|
||||
syn keyword dAsmOpCode contained seta setae setb setbe setc
|
||||
syn keyword dAsmOpCode contained sete setg setge setl setle
|
||||
syn keyword dAsmOpCode contained setna setnae setnb setnbe setnc
|
||||
syn keyword dAsmOpCode contained setne setng setnge setnl setnle
|
||||
syn keyword dAsmOpCode contained setno setnp setns setnz seto
|
||||
syn keyword dAsmOpCode contained setp setpe setpo sets setz
|
||||
syn keyword dAsmOpCode contained sfence sgdt shl shld shr
|
||||
syn keyword dAsmOpCode contained shrd shufpd shufps sidt sldt
|
||||
syn keyword dAsmOpCode contained smsw sqrtpd sqrtps sqrtsd sqrtss
|
||||
syn keyword dAsmOpCode contained stc std sti stmxcsr stos
|
||||
syn keyword dAsmOpCode contained stosb stosd stosw str sub
|
||||
syn keyword dAsmOpCode contained subpd subps subsd subss sysenter
|
||||
syn keyword dAsmOpCode contained sysexit test ucomisd ucomiss ud2
|
||||
syn keyword dAsmOpCode contained unpckhpd unpckhps unpcklpd unpcklps verr
|
||||
syn keyword dAsmOpCode contained verw wait wbinvd wrmsr xadd
|
||||
syn keyword dAsmOpCode contained xchg xlat xlatb xor xorpd
|
||||
syn keyword dAsmOpCode contained xorps
|
||||
syn keyword dAsmOpCode contained addsubpd addsubps fisttp haddpd haddps
|
||||
syn keyword dAsmOpCode contained hsubpd hsubps lddqu monitor movddup
|
||||
syn keyword dAsmOpCode contained movshdup movsldup mwait
|
||||
syn keyword dAsmOpCode contained pavgusb pf2id pfacc pfadd pfcmpeq
|
||||
syn keyword dAsmOpCode contained pfcmpge pfcmpgt pfmax pfmin pfmul
|
||||
syn keyword dAsmOpCode contained pfnacc pfpnacc pfrcp pfrcpit1 pfrcpit2
|
||||
syn keyword dAsmOpCode contained pfrsqit1 pfrsqrt pfsub pfsubr pi2fd
|
||||
syn keyword dAsmOpCode contained pmulhrw pswapd
|
||||
syn keyword dAsmOpCode contained aaa aad aam aas
|
||||
syn keyword dAsmOpCode contained add addpd addps addsd
|
||||
syn keyword dAsmOpCode contained and andnpd andnps andpd
|
||||
syn keyword dAsmOpCode contained arpl bound bsf bsr
|
||||
syn keyword dAsmOpCode contained bt btc btr bts
|
||||
syn keyword dAsmOpCode contained call bswap andps addss
|
||||
syn keyword dAsmOpCode contained cbw cdq clc cld
|
||||
syn keyword dAsmOpCode contained cli clts cmc cmova
|
||||
syn keyword dAsmOpCode contained cmovb cmovbe cmovc cmove
|
||||
syn keyword dAsmOpCode contained cmovge cmovl cmovle cmovna
|
||||
syn keyword dAsmOpCode contained cmovnae cmovg cmovae clflush
|
||||
syn keyword dAsmOpCode contained cmovnb cmovnbe cmovnc cmovne
|
||||
syn keyword dAsmOpCode contained cmovnge cmovnl cmovnle cmovno
|
||||
syn keyword dAsmOpCode contained cmovns cmovnz cmovo cmovp
|
||||
syn keyword dAsmOpCode contained cmovpo cmovs cmovz cmp
|
||||
syn keyword dAsmOpCode contained cmppd cmovpe cmovnp cmovng
|
||||
syn keyword dAsmOpCode contained cmpps cmps cmpsb cmpsd
|
||||
syn keyword dAsmOpCode contained cmpsw cmpxch8b cmpxchg comisd
|
||||
syn keyword dAsmOpCode contained cpuid cvtdq2pd cvtdq2ps cvtpd2dq
|
||||
syn keyword dAsmOpCode contained cvtpd2ps cvtpi2pd cvtpi2ps cvtps2dq
|
||||
syn keyword dAsmOpCode contained cvtps2pd cvtpd2pi comiss cmpss
|
||||
syn keyword dAsmOpCode contained cvtps2pi cvtsd2si cvtsd2ss cvtsi2sd
|
||||
syn keyword dAsmOpCode contained cvtss2sd cvtss2si cvttpd2dq cvttpd2pi
|
||||
syn keyword dAsmOpCode contained cvttps2pi cvttsd2si cvttss2si cwd
|
||||
syn keyword dAsmOpCode contained da daa das db
|
||||
syn keyword dAsmOpCode contained dd cwde cvttps2dq cvtsi2ss
|
||||
syn keyword dAsmOpCode contained de dec df di
|
||||
syn keyword dAsmOpCode contained divpd divps divsd divss
|
||||
syn keyword dAsmOpCode contained dq ds dt dw
|
||||
syn keyword dAsmOpCode contained enter f2xm1 fabs fadd
|
||||
syn keyword dAsmOpCode contained faddp emms dl div
|
||||
syn keyword dAsmOpCode contained fbld fbstp fchs fclex
|
||||
syn keyword dAsmOpCode contained fcmovbe fcmove fcmovnb fcmovnbe
|
||||
syn keyword dAsmOpCode contained fcmovnu fcmovu fcom fcomi
|
||||
syn keyword dAsmOpCode contained fcomp fcompp fcos fdecstp
|
||||
syn keyword dAsmOpCode contained fdisi fcomip fcmovne fcmovb
|
||||
syn keyword dAsmOpCode contained fdiv fdivp fdivr fdivrp
|
||||
syn keyword dAsmOpCode contained ffree fiadd ficom ficomp
|
||||
syn keyword dAsmOpCode contained fidivr fild fimul fincstp
|
||||
syn keyword dAsmOpCode contained fist fistp fisub fisubr
|
||||
syn keyword dAsmOpCode contained fld finit fidiv feni
|
||||
syn keyword dAsmOpCode contained fld1 fldcw fldenv fldl2e
|
||||
syn keyword dAsmOpCode contained fldlg2 fldln2 fldpi fldz
|
||||
syn keyword dAsmOpCode contained fmulp fnclex fndisi fneni
|
||||
syn keyword dAsmOpCode contained fnop fnsave fnstcw fnstenv
|
||||
syn keyword dAsmOpCode contained fnstsw fninit fmul fldl2t
|
||||
syn keyword dAsmOpCode contained fpatan fprem fprem1 fptan
|
||||
syn keyword dAsmOpCode contained frstor fsave fscale fsetpm
|
||||
syn keyword dAsmOpCode contained fsincos fsqrt fst fstcw
|
||||
syn keyword dAsmOpCode contained fstp fstsw fsub fsubp
|
||||
syn keyword dAsmOpCode contained fsubr fstenv fsin frndint
|
||||
syn keyword dAsmOpCode contained fsubrp ftst fucom fucomi
|
||||
syn keyword dAsmOpCode contained fucomp fucompp fwait fxam
|
||||
syn keyword dAsmOpCode contained fxrstor fxsave fxtract fyl2x
|
||||
syn keyword dAsmOpCode contained hlt idiv imul in
|
||||
syn keyword dAsmOpCode contained inc fyl2xp1 fxch fucomip
|
||||
syn keyword dAsmOpCode contained ins insb insd insw
|
||||
syn keyword dAsmOpCode contained into invd invlpg iret
|
||||
syn keyword dAsmOpCode contained ja jae jb jbe
|
||||
syn keyword dAsmOpCode contained jcxz je jecxz jg
|
||||
syn keyword dAsmOpCode contained jge jc iretd int
|
||||
syn keyword dAsmOpCode contained jl jle jmp jna
|
||||
syn keyword dAsmOpCode contained jnb jnbe jnc jne
|
||||
syn keyword dAsmOpCode contained jnge jnl jnle jno
|
||||
syn keyword dAsmOpCode contained jns jnz jo jp
|
||||
syn keyword dAsmOpCode contained jpe jnp jng jnae
|
||||
syn keyword dAsmOpCode contained jpo js jz lahf
|
||||
syn keyword dAsmOpCode contained ldmxcsr lds lea leave
|
||||
syn keyword dAsmOpCode contained lfence lfs lgdt lgs
|
||||
syn keyword dAsmOpCode contained lldt lmsw lock lods
|
||||
syn keyword dAsmOpCode contained lodsb lidt les lar
|
||||
syn keyword dAsmOpCode contained lodsd lodsw loop loope
|
||||
syn keyword dAsmOpCode contained loopnz loopz lsl lss
|
||||
syn keyword dAsmOpCode contained maskmovdqu maskmovq maxpd maxps
|
||||
syn keyword dAsmOpCode contained maxss mfence minpd minps
|
||||
syn keyword dAsmOpCode contained minsd maxsd ltr loopne
|
||||
syn keyword dAsmOpCode contained minss mov movapd movaps
|
||||
syn keyword dAsmOpCode contained movdq2q movdqa movdqu movhlps
|
||||
syn keyword dAsmOpCode contained movhps movlhps movlpd movlps
|
||||
syn keyword dAsmOpCode contained movmskps movntdq movnti movntpd
|
||||
syn keyword dAsmOpCode contained movntps movmskpd movhpd movd
|
||||
syn keyword dAsmOpCode contained movntq movq movq2dq movs
|
||||
syn keyword dAsmOpCode contained movsd movss movsw movsx
|
||||
syn keyword dAsmOpCode contained movups movzx mul mulpd
|
||||
syn keyword dAsmOpCode contained mulsd mulss neg nop
|
||||
syn keyword dAsmOpCode contained not mulps movupd movsb
|
||||
syn keyword dAsmOpCode contained or orpd orps out
|
||||
syn keyword dAsmOpCode contained outsb outsd outsw packssdw
|
||||
syn keyword dAsmOpCode contained packuswb paddb paddd paddq
|
||||
syn keyword dAsmOpCode contained paddsw paddusb paddusw paddw
|
||||
syn keyword dAsmOpCode contained pand paddsb packsswb outs
|
||||
syn keyword dAsmOpCode contained pandn pavgb pavgw pcmpeqb
|
||||
syn keyword dAsmOpCode contained pcmpeqw pcmpgtb pcmpgtd pcmpgtw
|
||||
syn keyword dAsmOpCode contained pinsrw pmaddwd pmaxsw pmaxub
|
||||
syn keyword dAsmOpCode contained pminub pmovmskb pmulhuw pmulhw
|
||||
syn keyword dAsmOpCode contained pmullw pminsw pextrw pcmpeqd
|
||||
syn keyword dAsmOpCode contained pmuludq pop popa popad
|
||||
syn keyword dAsmOpCode contained popfd por prefetchnta prefetcht0
|
||||
syn keyword dAsmOpCode contained prefetcht2 psadbw pshufd pshufhw
|
||||
syn keyword dAsmOpCode contained pshufw pslld pslldq psllq
|
||||
syn keyword dAsmOpCode contained psllw pshuflw prefetcht1 popf
|
||||
syn keyword dAsmOpCode contained psrad psraw psrld psrldq
|
||||
syn keyword dAsmOpCode contained psrlw psubb psubd psubq
|
||||
syn keyword dAsmOpCode contained psubsw psubusb psubusw psubw
|
||||
syn keyword dAsmOpCode contained punpckhdq punpckhqdq punpckhwd punpcklbw
|
||||
syn keyword dAsmOpCode contained punpckldq punpckhbw psubsb psrlq
|
||||
syn keyword dAsmOpCode contained punpcklqdq punpcklwd push pusha
|
||||
syn keyword dAsmOpCode contained pushf pushfd pxor rcl
|
||||
syn keyword dAsmOpCode contained rcpss rcr rdmsr rdpmc
|
||||
syn keyword dAsmOpCode contained rep repe repne repnz
|
||||
syn keyword dAsmOpCode contained repz rdtsc rcpps pushad
|
||||
syn keyword dAsmOpCode contained ret retf rol ror
|
||||
syn keyword dAsmOpCode contained rsqrtps rsqrtss sahf sal
|
||||
syn keyword dAsmOpCode contained sbb scas scasb scasd
|
||||
syn keyword dAsmOpCode contained seta setae setb setbe
|
||||
syn keyword dAsmOpCode contained setc scasw sar rsm
|
||||
syn keyword dAsmOpCode contained sete setg setge setl
|
||||
syn keyword dAsmOpCode contained setna setnae setnb setnbe
|
||||
syn keyword dAsmOpCode contained setne setng setnge setnl
|
||||
syn keyword dAsmOpCode contained setno setnp setns setnz
|
||||
syn keyword dAsmOpCode contained seto setnle setnc setle
|
||||
syn keyword dAsmOpCode contained setp setpe setpo sets
|
||||
syn keyword dAsmOpCode contained sfence sgdt shl shld
|
||||
syn keyword dAsmOpCode contained shrd shufpd shufps sidt
|
||||
syn keyword dAsmOpCode contained smsw sqrtpd sqrtps sqrtsd
|
||||
syn keyword dAsmOpCode contained sqrtss sldt shr setz
|
||||
syn keyword dAsmOpCode contained stc std sti stmxcsr
|
||||
syn keyword dAsmOpCode contained stosb stosd stosw str
|
||||
syn keyword dAsmOpCode contained subpd subps subsd subss
|
||||
syn keyword dAsmOpCode contained sysexit test ucomisd ucomiss
|
||||
syn keyword dAsmOpCode contained ud2 sysenter sub stos
|
||||
syn keyword dAsmOpCode contained unpckhpd unpckhps unpcklpd unpcklps
|
||||
syn keyword dAsmOpCode contained verw wbinvd wrmsr xadd
|
||||
syn keyword dAsmOpCode contained xchg xlatb xor xorpd
|
||||
syn keyword dAsmOpCode contained xorps pfrcpit1 pfmin movddup
|
||||
syn keyword dAsmOpCode contained addsubpd addsubps fisttp haddps
|
||||
syn keyword dAsmOpCode contained hsubpd hsubps lddqu monitor
|
||||
syn keyword dAsmOpCode contained haddpd xlat wait verr
|
||||
syn keyword dAsmOpCode contained movshdup movsldup mwait pfcmpeq
|
||||
syn keyword dAsmOpCode contained pavgusb pf2id pfacc pfadd
|
||||
syn keyword dAsmOpCode contained pfcmpge pfcmpgt pfmax pfmul
|
||||
syn keyword dAsmOpCode contained pfnacc pfpnacc pfrcp pfrcpit1
|
||||
syn keyword dAsmOpCode contained pfrsqit1 pfrsqrt pfsub pfsubr
|
||||
syn keyword dAsmOpCode contained pmulhrw pswapd syscall sysret
|
||||
syn keyword dAsmOpCode contained vpmuldq xgetbv cmpxchg8b cmpxchg16b
|
||||
syn keyword dAsmOpCode contained pabsb pabsd pabsw palignr
|
||||
syn keyword dAsmOpCode contained phaddd phaddsw phaddw phsubd
|
||||
syn keyword dAsmOpCode contained phsubsw phsubw pmaddubsw pmulhrsw
|
||||
syn keyword dAsmOpCode contained pshufb psignb psignd psignw
|
||||
syn keyword dAsmOpCode contained popfq pushfq blendpd blendps
|
||||
syn keyword dAsmOpCode contained blendvpd blendvps extractps insertps
|
||||
syn keyword dAsmOpCode contained movntdqa mpsadbw packusdw pblendvb
|
||||
syn keyword dAsmOpCode contained pblendw pcmpeqq pextrb pextrd
|
||||
syn keyword dAsmOpCode contained pextrq phminposuw pinsrb pinsrd
|
||||
syn keyword dAsmOpCode contained pinsrq pmaxsb pmaxsd pmaxud
|
||||
syn keyword dAsmOpCode contained pmaxuw pminsb pminsd pminud
|
||||
syn keyword dAsmOpCode contained pminuw pmulld ptest roundpd
|
||||
syn keyword dAsmOpCode contained roundps roundsd roundss pmuldq
|
||||
syn keyword dAsmOpCode contained pmovsxbd pmovsxdq pmovzxbq pmovzxdq
|
||||
syn keyword dAsmOpCode contained pmovsxbq pmovsxwd pmovzxbq pmovzxwd
|
||||
syn keyword dAsmOpCode contained pmovsxbw pmovsxwq pmovzxbw pmovzxwq
|
||||
syn keyword dAsmOpCode contained crc32 pcmpestri pcmpestrm pcmpgtq
|
||||
syn keyword dAsmOpCode contained pcmpistri pcmpistrm popcnt pi2fd
|
||||
syn keyword dAsmOpCode contained adc
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
|
@@ -2,7 +2,7 @@
|
||||
" Language: git commit file
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Filenames: *.git/COMMIT_EDITMSG
|
||||
" Last Change: 2012 April 7
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
|
@@ -2,7 +2,7 @@
|
||||
" Language: git rebase --interactive
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Filenames: git-rebase-todo
|
||||
" Last Change: 2012 April 7
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
|
69
runtime/syntax/gprof.vim
Normal file
69
runtime/syntax/gprof.vim
Normal file
@@ -0,0 +1,69 @@
|
||||
" Vim syntax file
|
||||
" Language: Syntax for Gprof Output
|
||||
" Maintainer: Dominique Pelle <dominique.pelle@gmail.com>
|
||||
" Last Change: 2012 May 20
|
||||
|
||||
" Quit when a syntax file was already loaded
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
endif
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
|
||||
syn case match
|
||||
syn sync minlines=100
|
||||
|
||||
" Flat profile
|
||||
syn match gprofFlatProfileTitle
|
||||
\ "^Flat profile:$"
|
||||
syn region gprofFlatProfileHeader
|
||||
\ start="^Each sample counts as.*"
|
||||
\ end="^ time.*name\s*$"
|
||||
syn region gprofFlatProfileTrailer
|
||||
\ start="^\s*%\s\+the percentage of the total running time.*"
|
||||
\ end="^\s*the gprof listing if it were to be printed\."
|
||||
|
||||
" Call graph
|
||||
syn match gprofCallGraphTitle "Call graph (explanation follows)"
|
||||
syn region gprofCallGraphHeader
|
||||
\ start="^granularity: each sample hit covers.*"
|
||||
\ end="^\s*index % time\s\+self\s\+children\s\+called\s\+name$"
|
||||
syn match gprofCallGraphFunction "\s\+\(\d\+\.\d\+\s\+\)\{3}\([0-9+]\+\)\?\s\+[a-zA-Z_<].*\ze\["
|
||||
syn match gprofCallGraphSeparator "^-\+$"
|
||||
syn region gprofCallGraphTrailer
|
||||
\ start="This table describes the call tree of the program"
|
||||
\ end="^\s*the cycle.$"
|
||||
|
||||
" Index
|
||||
syn region gprofIndex
|
||||
\ start="^Index by function name$"
|
||||
\ end="\%$"
|
||||
|
||||
syn match gprofIndexFunctionTitle "^Index by function name$"
|
||||
|
||||
syn match gprofNumbers "^\s\+[0-9 ./+]\+"
|
||||
syn match gprofFunctionIndex "\[\d\+\]"
|
||||
syn match gprofSpecial "<\(spontaneous\|cycle \d\+\)>"
|
||||
|
||||
hi def link gprofFlatProfileTitle Title
|
||||
hi def link gprofFlatProfileHeader Comment
|
||||
hi def link gprofFlatProfileFunction Number
|
||||
hi def link gprofFlatProfileTrailer Comment
|
||||
|
||||
hi def link gprofCallGraphTitle Title
|
||||
hi def link gprofCallGraphHeader Comment
|
||||
hi def link gprofFlatProfileFunction Number
|
||||
hi def link gprofCallGraphFunction Special
|
||||
hi def link gprofCallGraphTrailer Comment
|
||||
hi def link gprofCallGraphSeparator Label
|
||||
|
||||
hi def link gprofFunctionIndex Label
|
||||
hi def link gprofSpecial SpecialKey
|
||||
hi def link gprofNumbers Number
|
||||
|
||||
hi def link gprofIndexFunctionTitle Title
|
||||
|
||||
let b:current_syntax = "gprof"
|
||||
|
||||
let &cpo = s:keepcpo
|
||||
unlet s:keepcpo
|
@@ -2,7 +2,7 @@
|
||||
" Language: Liquid
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Filenames: *.liquid
|
||||
" Last Change: 2010 May 21
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
if exists('b:current_syntax')
|
||||
finish
|
||||
@@ -71,8 +71,9 @@ 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,@liquidStatement,liquidYamlHead
|
||||
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
|
||||
|
||||
|
@@ -2,50 +2,66 @@
|
||||
" Language: Markdown
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Filenames: *.markdown
|
||||
" Last Change: 2010 May 21
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
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 '[<>]\S\@!'
|
||||
syn match markdownValid '[<>]\c[a-z/$!]\@!'
|
||||
syn match markdownValid '&\%(#\=\w*;\)\@!'
|
||||
|
||||
syn match markdownLineStart "^[<@]\@!" nextgroup=@markdownBlock
|
||||
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
|
||||
syn cluster markdownInline contains=markdownLineBreak,markdownLinkText,markdownItalic,markdownBold,markdownCode,markdownEscape,@htmlTop,markdownError
|
||||
|
||||
syn match markdownH1 ".\+\n=\+$" contained contains=@markdownInline,markdownHeadingRule
|
||||
syn match markdownH2 ".\+\n-\+$" contained contains=@markdownInline,markdownHeadingRule
|
||||
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 contained
|
||||
syn region markdownH2 matchgroup=markdownHeadingDelimiter start="###\@!" end="#*\s*$" keepend oneline contains=@markdownInline contained
|
||||
syn region markdownH3 matchgroup=markdownHeadingDelimiter start="####\@!" end="#*\s*$" keepend oneline contains=@markdownInline contained
|
||||
syn region markdownH4 matchgroup=markdownHeadingDelimiter start="#####\@!" end="#*\s*$" keepend oneline contains=@markdownInline contained
|
||||
syn region markdownH5 matchgroup=markdownHeadingDelimiter start="######\@!" end="#*\s*$" keepend oneline contains=@markdownInline contained
|
||||
syn region markdownH6 matchgroup=markdownHeadingDelimiter start="#######\@!" end="#*\s*$" keepend oneline contains=@markdownInline 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 match markdownBlockquote ">\%(\s\|$\)" contained nextgroup=@markdownBlock
|
||||
|
||||
syn region markdownCodeBlock start=" \|\t" end="$" contained
|
||||
|
||||
" TODO: real nesting
|
||||
syn match markdownListMarker " \{0,4\}[-*+]\%(\s\+\S\)\@=" contained
|
||||
syn match markdownOrderedListMarker " \{0,4}\<\d\+\.\%(\s*\S\)\@=" contained
|
||||
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 "\s\{2,\}$"
|
||||
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
|
||||
@@ -61,14 +77,23 @@ syn region markdownAutomaticLink matchgroup=markdownUrlDelimiter start="<\%(\w\+
|
||||
|
||||
syn region markdownItalic start="\S\@<=\*\|\*\S\@=" end="\S\@<=\*\|\*\S\@=" keepend contains=markdownLineStart
|
||||
syn region markdownItalic start="\S\@<=_\|_\S\@=" end="\S\@<=_\|_\S\@=" keepend contains=markdownLineStart
|
||||
syn region markdownBold start="\S\@<=\*\*\|\*\*\S\@=" end="\S\@<=\*\*\|\*\*\S\@=" keepend contains=markdownLineStart
|
||||
syn region markdownBold start="\S\@<=__\|__\S\@=" end="\S\@<=__\|__\S\@=" keepend contains=markdownLineStart
|
||||
syn region markdownBold start="\S\@<=\*\*\|\*\*\S\@=" end="\S\@<=\*\*\|\*\*\S\@=" keepend contains=markdownLineStart,markdownItalic
|
||||
syn region markdownBold start="\S\@<=__\|__\S\@=" end="\S\@<=__\|__\S\@=" keepend contains=markdownLineStart,markdownItalic
|
||||
syn region markdownBoldItalic start="\S\@<=\*\*\*\|\*\*\*\S\@=" end="\S\@<=\*\*\*\|\*\*\*\S\@=" keepend contains=markdownLineStart
|
||||
syn region markdownBoldItalic start="\S\@<=___\|___\S\@=" end="\S\@<=___\|___\S\@=" keepend contains=markdownLineStart
|
||||
syn region markdownCode matchgroup=markdownCodeDelimiter start="`" end="`" transparent keepend contains=markdownLineStart
|
||||
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
|
||||
|
||||
if main_syntax ==# 'markdown'
|
||||
for s:type in g:markdown_fenced_languages
|
||||
exe 'syn region markdownHighlight'.substitute(matchstr(s:type,'[^=]*$'),'\..*','','').' matchgroup=markdownCodeDelimiter start="^\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
|
||||
@@ -99,7 +124,11 @@ hi def link markdownBoldItalic htmlBoldItalic
|
||||
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:
|
||||
|
@@ -1,22 +1,24 @@
|
||||
" Vim syntax file
|
||||
" Language: Perl 5
|
||||
" Maintainer: Andy Lester <andy@petdance.com>
|
||||
" URL: http://github.com/petdance/vim-perl/tree/master
|
||||
" Last Change: 2010-08-10
|
||||
" Contributors: Andy Lester <andy@petdance.com>
|
||||
" Hinrik Örn Sigurðsson <hinrik.sig@gmail.com>
|
||||
" Lukas Mai <l.mai.web.de>
|
||||
" Nick Hibma <nick@van-laarhoven.org>
|
||||
" Sonia Heimann <niania@netsurf.org>
|
||||
" and many others.
|
||||
" Language: Perl 5
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" Homepage: http://github.com/vim-perl/vim-perl/tree/master
|
||||
" Bugs/requests: http://github.com/vim-perl/vim-perl/issues
|
||||
" Last Change: 2013-05-11
|
||||
" Contributors: Andy Lester <andy@petdance.com>
|
||||
" Hinrik Örn Sigurðsson <hinrik.sig@gmail.com>
|
||||
" Lukas Mai <l.mai.web.de>
|
||||
" Nick Hibma <nick@van-laarhoven.org>
|
||||
" Sonia Heimann <niania@netsurf.org>
|
||||
" Rob Hoelz <rob@hoelz.ro>
|
||||
" and many others.
|
||||
"
|
||||
" Please download most recent version first before mailing
|
||||
" 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:
|
||||
"
|
||||
" unlet perl_include_pod
|
||||
" let perl_include_pod = 1
|
||||
" unlet perl_no_scope_in_variables
|
||||
" unlet perl_no_extended_vars
|
||||
" unlet perl_string_as_statement
|
||||
@@ -27,21 +29,29 @@
|
||||
" unlet perl_fold_blocks
|
||||
" let perl_nofold_packages = 1
|
||||
" let perl_nofold_subs = 1
|
||||
" unlet perl_fold_anonymous_subs
|
||||
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
endif
|
||||
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
|
||||
if exists('®expengine')
|
||||
let s:regexpengine=®expengine
|
||||
set regexpengine=1
|
||||
endif
|
||||
|
||||
" POD starts with ^=<word> and ends with ^=cut
|
||||
|
||||
if exists("perl_include_pod")
|
||||
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
|
||||
syn region perlPOD start="^=cut" end="^=cut" contains=perlTodo keepend 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
|
||||
@@ -63,10 +73,13 @@ syn region perlGenericBlock matchgroup=perlGenericBlock start="{" end="}" conta
|
||||
" All keywords
|
||||
"
|
||||
syn match perlConditional "\<\%(if\|elsif\|unless\|given\|when\|default\)\>"
|
||||
syn match perlConditional "\<else\>" nextgroup=perlElseIfError skipwhite skipnl skipempty
|
||||
syn match perlConditional "\<else\%(\%(\_s\*if\>\)\|\>\)" 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\)\>"
|
||||
syn match perlControl "\<\%(BEGIN\|CHECK\|INIT\|END\|UNITCHECK\)\>"
|
||||
" 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\)\>"
|
||||
@@ -93,9 +106,9 @@ syn match perlStatementTime "\<\%(gmtime\|localtime\|time\)\>"
|
||||
|
||||
syn match perlStatementMisc "\<\%(warn\|formline\|reset\|scalar\|prototype\|lock\|tied\=\|untie\)\>"
|
||||
|
||||
syn keyword perlTodo TODO TBD FIXME XXX NOTE contained
|
||||
syn keyword perlTodo TODO TODO: TBD TBD: FIXME FIXME: XXX XXX: NOTE NOTE: contained
|
||||
|
||||
syn region perlStatementIndirObjWrap matchgroup=perlStatementIndirObj start="\<\%(map\|grep\|sort\|print\|system\|exec\)\>\s*{" end="}" contains=@perlTop,perlGenericBlock
|
||||
syn region perlStatementIndirObjWrap matchgroup=perlStatementIndirObj start="\<\%(map\|grep\|sort\|printf\=\|say\|system\|exec\)\>\s*{" end="}" contains=@perlTop,perlGenericBlock extend
|
||||
|
||||
syn match perlLabel "^\s*\h\w*\s*::\@!\%(\<v\d\+\s*:\)\@<!"
|
||||
|
||||
@@ -146,14 +159,14 @@ if !exists("perl_no_extended_vars")
|
||||
syn region perlArrow matchgroup=perlArrow start="->\s*{" end="}" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod contained
|
||||
syn match perlArrow "->\s*{\s*\I\i*\s*}" contains=perlVarSimpleMemberName nextgroup=perlVarMember,perlVarSimpleMember,perlMethod contained
|
||||
syn region perlArrow matchgroup=perlArrow start="->\s*\$*\I\i*\s*(" end=")" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod contained
|
||||
syn region perlVarBlock matchgroup=perlVarPlain start="\%($#\|[$@]\)\$*{" skip="\\}" end="}" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod
|
||||
syn region perlVarBlock2 matchgroup=perlVarPlain start="[%&*]\$*{" skip="\\}" end="}" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod
|
||||
syn region perlVarBlock matchgroup=perlVarPlain start="\%($#\|[$@]\)\$*{" skip="\\}" end=+}\|\%(\%(<<\%('\|"\)\?\)\@=\)+ contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod extend
|
||||
syn region perlVarBlock2 matchgroup=perlVarPlain start="[%&*]\$*{" skip="\\}" end=+}\|\%(\%(<<\%('\|"\)\?\)\@=\)+ contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod extend
|
||||
syn match perlVarPlain2 "[%&*]\$*{\I\i*}" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod
|
||||
syn match perlVarPlain "\%(\$#\|[@$]\)\$*{\I\i*}" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod
|
||||
syn region perlVarMember matchgroup=perlVarPlain start="\%(->\)\={" skip="\\}" end="}" contained contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod
|
||||
syn match perlVarSimpleMember "\%(->\)\={\s*\I\i*\s*}" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod contains=perlVarSimpleMemberName contained
|
||||
syn region perlVarMember matchgroup=perlVarPlain start="\%(->\)\={" skip="\\}" end="}" contained contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod extend
|
||||
syn match perlVarSimpleMember "\%(->\)\={\s*\I\i*\s*}" nextgroup=perlVarMember,perlVarSimpleMember,perlMethod 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
|
||||
syn region perlVarMember matchgroup=perlVarPlain start="\%(->\)\=\[" skip="\\]" end="]" contained contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember,perlMethod extend
|
||||
syn match perlPackageConst "__PACKAGE__" nextgroup=perlMethod
|
||||
syn match perlMethod "->\$*\I\i*" contained nextgroup=perlVarSimpleMember,perlVarMember,perlMethod
|
||||
endif
|
||||
@@ -168,13 +181,13 @@ 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 transparent contains=NONE
|
||||
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
|
||||
syn match perlSpecialMatch "\[[]-]\=[^\[\]]*[]-]\=\]" contained extend
|
||||
syn match perlSpecialMatch "[+*()?.]" contained
|
||||
syn match perlSpecialMatch "(?[#:=!]" contained
|
||||
syn match perlSpecialMatch "(?[impsx]*\%(-[imsx]\+\)\=)" contained
|
||||
@@ -186,10 +199,9 @@ syn match perlSpecialMatch "(\*\%(\%(PRUNE\|SKIP\|THEN\)\%(:[^)]*\)\=\|\%(MARK\
|
||||
"
|
||||
" 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 "\s\+if" contained
|
||||
syn keyword perlElseIfError elseif
|
||||
" 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
|
||||
"
|
||||
@@ -217,32 +229,32 @@ syn match perlString "\<\%(v\d\+\%(\.\d\+\)*\|\d\+\%(\.\d\+\)\{2,}\)\>" contain
|
||||
syn match perlVStringV "\<v" contained
|
||||
|
||||
|
||||
syn region perlParensSQ start=+(+ end=+)+ extend contained transparent contains=perlParensSQ,@perlInterpSQ keepend
|
||||
syn region perlBracketsSQ start=+\[+ end=+\]+ extend contained transparent contains=perlBracketsSQ,@perlInterpSQ keepend
|
||||
syn region perlBracesSQ start=+{+ end=+}+ extend contained transparent contains=perlBracesSQ,@perlInterpSQ keepend
|
||||
syn region perlAnglesSQ start=+<+ end=+>+ extend contained transparent contains=perlAnglesSQ,@perlInterpSQ keepend
|
||||
syn region perlParensSQ start=+(+ end=+)+ extend contained contains=perlParensSQ,@perlInterpSQ keepend
|
||||
syn region perlBracketsSQ start=+\[+ end=+\]+ extend contained contains=perlBracketsSQ,@perlInterpSQ keepend
|
||||
syn region perlBracesSQ start=+{+ end=+}+ extend contained contains=perlBracesSQ,@perlInterpSQ keepend
|
||||
syn region perlAnglesSQ start=+<+ end=+>+ extend contained contains=perlAnglesSQ,@perlInterpSQ keepend
|
||||
|
||||
syn region perlParensDQ start=+(+ end=+)+ extend contained transparent contains=perlParensDQ,@perlInterpDQ keepend
|
||||
syn region perlBracketsDQ start=+\[+ end=+\]+ extend contained transparent contains=perlBracketsDQ,@perlInterpDQ keepend
|
||||
syn region perlBracesDQ start=+{+ end=+}+ extend contained transparent contains=perlBracesDQ,@perlInterpDQ keepend
|
||||
syn region perlAnglesDQ start=+<+ end=+>+ extend contained transparent contains=perlAnglesDQ,@perlInterpDQ 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=+\<\%(::\|'\|->\)\@<!m\>\s*\z([^[:space:]'([{<#]\)+ end=+\z1[cgimopsx]*+ contains=@perlInterpMatch keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m#+ end=+#[cgimopsx]*+ contains=@perlInterpMatch keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*'+ end=+'[cgimopsx]*+ contains=@perlInterpSQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*/+ end=+/[cgimopsx]*+ contains=@perlInterpSlash keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*(+ end=+)[cgimopsx]*+ contains=@perlInterpMatch,perlParensDQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\>\s*\z([^[:space:]'([{<#]\)+ end=+\z1[msixpodualgc]*+ contains=@perlInterpMatch keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m#+ end=+#[msixpodualgc]*+ contains=@perlInterpMatch keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*'+ end=+'[msixpodualgc]*+ contains=@perlInterpSQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*/+ end=+/[msixpodualgc]*+ contains=@perlInterpSlash keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*(+ end=+)[msixpodualgc]*+ contains=@perlInterpMatch,perlParensDQ keepend
|
||||
|
||||
" A special case for m{}, m<> and m[] which allows for comments and extra whitespace in the pattern
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*{+ end=+}[cgimopsx]*+ contains=@perlInterpMatch,perlComment,perlBracesDQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*<+ end=+>[cgimopsx]*+ contains=@perlInterpMatch,perlAnglesDQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*\[+ end=+\][cgimopsx]*+ contains=@perlInterpMatch,perlComment,perlBracketsDQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*{+ end=+}[msixpodualgc]*+ contains=@perlInterpMatch,perlComment,perlBracesDQ
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*<+ end=+>[msixpodualgc]*+ contains=@perlInterpMatch,perlAnglesDQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!m\s*\[+ end=+\][msixpodualgc]*+ contains=@perlInterpMatch,perlComment,perlBracketsDQ keepend
|
||||
|
||||
" Below some hacks to recognise the // variant. This is virtually impossible to catch in all
|
||||
" cases as the / is used in so many other ways, but these should be the most obvious ones.
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start="\%([$@%&*]\@<!\%(\<split\|\<while\|\<if\|\<unless\|\.\.\|[-+*!~(\[{=]\)\s*\)\@<=/\%(/=\)\@!" start=+^/\%(/=\)\@!+ start=+\s\@<=/\%(/=\)\@![^[:space:][:digit:]$@%=]\@=\%(/\_s*\%([([{$@%&*[:digit:]"'`]\|\_s\w\|[[:upper:]_abd-fhjklnqrt-wyz]\)\)\@!+ skip=+\\/+ end=+/[cgimopsx]*+ contains=@perlInterpSlash
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start="\%([$@%&*]\@<!\%(\<split\|\<while\|\<if\|\<unless\|\.\.\|[-+*!~(\[{=]\)\s*\)\@<=/\%(/=\)\@!" start=+^/\%(/=\)\@!+ start=+\s\@<=/\%(/=\)\@![^[:space:][:digit:]$@%=]\@=\%(/\_s*\%([([{$@%&*[:digit:]"'`]\|\_s\w\|[[:upper:]_abd-fhjklnqrt-wyz]\)\)\@!+ skip=+\\/+ end=+/[msixpodualgc]*+ contains=@perlInterpSlash
|
||||
|
||||
|
||||
" Substitutions
|
||||
@@ -254,13 +266,13 @@ syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!s#+
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!s\s*(+ end=+)+ contains=@perlInterpMatch,perlParensDQ nextgroup=perlSubstitutionGQQ skipwhite skipempty skipnl keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!s\s*<+ end=+>+ contains=@perlInterpMatch,perlAnglesDQ nextgroup=perlSubstitutionGQQ skipwhite skipempty skipnl keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!s\s*\[+ end=+\]+ contains=@perlInterpMatch,perlBracketsDQ nextgroup=perlSubstitutionGQQ skipwhite skipempty skipnl keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!s\s*{+ end=+}+ contains=@perlInterpMatch,perlBracesDQ nextgroup=perlSubstitutionGQQ skipwhite skipempty skipnl keepend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+\z([^[:space:]'([{<]\)+ end=+\z1[ecgimopsx]*+ keepend contained contains=@perlInterpDQ
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+(+ end=+)[ecgimopsx]*+ contained contains=@perlInterpDQ,perlParensDQ keepend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+\[+ end=+\][ecgimopsx]*+ contained contains=@perlInterpDQ,perlBracketsDQ keepend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+{+ end=+}[ecgimopsx]*+ contained contains=@perlInterpDQ,perlBracesDQ keepend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+<+ end=+>[ecgimopsx]*+ contained contains=@perlInterpDQ,perlAnglesDQ keepend
|
||||
syn region perlSubstitutionSQ matchgroup=perlMatchStartEnd start=+'+ end=+'[ecgimopsx]*+ contained contains=@perlInterpSQ keepend
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!s\s*{+ end=+}+ contains=@perlInterpMatch,perlBracesDQ nextgroup=perlSubstitutionGQQ skipwhite skipempty skipnl keepend extend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+\z([^[:space:]'([{<]\)+ end=+\z1[msixpodualgcer]*+ keepend contained contains=@perlInterpDQ
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+(+ end=+)[msixpodualgcer]*+ contained contains=@perlInterpDQ,perlParensDQ keepend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+\[+ end=+\][msixpodualgcer]*+ contained contains=@perlInterpDQ,perlBracketsDQ keepend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+{+ end=+}[msixpodualgcer]*+ contained contains=@perlInterpDQ,perlBracesDQ keepend extend
|
||||
syn region perlSubstitutionGQQ matchgroup=perlMatchStartEnd start=+<+ end=+>[msixpodualgcer]*+ contained contains=@perlInterpDQ,perlAnglesDQ keepend
|
||||
syn region perlSubstitutionSQ matchgroup=perlMatchStartEnd start=+'+ end=+'[msixpodualgcer]*+ contained contains=@perlInterpSQ keepend
|
||||
|
||||
" Translations
|
||||
" perlMatch is the first part, perlTranslation* is the second, translator part.
|
||||
@@ -270,48 +282,48 @@ syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!\%(
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!\%(tr\|y\)\s*(+ end=+)+ contains=@perlInterpSQ,perlParensSQ nextgroup=perlTranslationGQ skipwhite skipempty skipnl
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!\%(tr\|y\)\s*<+ end=+>+ contains=@perlInterpSQ,perlAnglesSQ nextgroup=perlTranslationGQ skipwhite skipempty skipnl
|
||||
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<\%(::\|'\|->\)\@<!\%(tr\|y\)\s*{+ end=+}+ contains=@perlInterpSQ,perlBracesSQ nextgroup=perlTranslationGQ skipwhite skipempty skipnl
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+\z([^[:space:]([{<]\)+ end=+\z1[cds]*+ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+(+ end=+)[cds]*+ contains=perlParensSQ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+\[+ end=+\][cds]*+ contains=perlBracketsSQ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+{+ end=+}[cds]*+ contains=perlBracesSQ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+<+ end=+>[cds]*+ contains=perlAnglesSQ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+\z([^[:space:]([{<]\)+ end=+\z1[cdsr]*+ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+(+ end=+)[cdsr]*+ contains=perlParensSQ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+\[+ end=+\][cdsr]*+ contains=perlBracketsSQ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+{+ end=+}[cdsr]*+ contains=perlBracesSQ contained
|
||||
syn region perlTranslationGQ matchgroup=perlMatchStartEnd start=+<+ end=+>[cdsr]*+ contains=perlAnglesSQ contained
|
||||
|
||||
|
||||
" Strings and q, qq, qw and qr expressions
|
||||
|
||||
syn region perlStringUnexpanded matchgroup=perlStringStartEnd start="'" end="'" contains=@perlInterpSQ keepend
|
||||
syn region perlString matchgroup=perlStringStartEnd start=+"+ end=+"+ contains=@perlInterpDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\>\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q#+ end=+#+ contains=@perlInterpSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*(+ end=+)+ contains=@perlInterpSQ,perlParensSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*\[+ end=+\]+ contains=@perlInterpSQ,perlBracketsSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*{+ end=+}+ contains=@perlInterpSQ,perlBracesSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*<+ end=+>+ contains=@perlInterpSQ,perlAnglesSQ keepend
|
||||
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=+\<\%(::\|'\|->\)\@<!q\>\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q#+ end=+#+ contains=@perlInterpSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*(+ end=+)+ contains=@perlInterpSQ,perlParensSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*\[+ end=+\]+ contains=@perlInterpSQ,perlBracketsSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*{+ end=+}+ contains=@perlInterpSQ,perlBracesSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q\s*<+ end=+>+ contains=@perlInterpSQ,perlAnglesSQ keepend extend
|
||||
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\>\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]#+ end=+#+ contains=@perlInterpDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*(+ end=+)+ contains=@perlInterpDQ,perlParensDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*\[+ end=+\]+ contains=@perlInterpDQ,perlBracketsDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*{+ end=+}+ contains=@perlInterpDQ,perlBracesDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*<+ end=+>+ contains=@perlInterpDQ,perlAnglesDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\>\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpDQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]#+ end=+#+ contains=@perlInterpDQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*(+ end=+)+ contains=@perlInterpDQ,perlParensDQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*\[+ end=+\]+ contains=@perlInterpDQ,perlBracketsDQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*{+ end=+}+ contains=@perlInterpDQ,perlBracesDQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!q[qx]\s*<+ end=+>+ contains=@perlInterpDQ,perlAnglesDQ keepend extend
|
||||
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw#+ end=+#+ contains=@perlInterpSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*(+ end=+)+ contains=@perlInterpSQ,perlParensSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*\[+ end=+\]+ contains=@perlInterpSQ,perlBracketsSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*{+ end=+}+ contains=@perlInterpSQ,perlBracesSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*<+ end=+>+ contains=@perlInterpSQ,perlAnglesSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*\z([^[:space:]#([{<]\)+ end=+\z1+ contains=@perlInterpSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw#+ end=+#+ contains=@perlInterpSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*(+ end=+)+ contains=@perlInterpSQ,perlParensSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*\[+ end=+\]+ contains=@perlInterpSQ,perlBracketsSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*{+ end=+}+ contains=@perlInterpSQ,perlBracesSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qw\s*<+ end=+>+ contains=@perlInterpSQ,perlAnglesSQ keepend extend
|
||||
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\>\s*\z([^[:space:]#([{<'/]\)+ end=+\z1[imosx]*+ contains=@perlInterpMatch keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*/+ end=+/[imosx]*+ contains=@perlInterpSlash keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr#+ end=+#[imosx]*+ contains=@perlInterpMatch keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*'+ end=+'[imosx]*+ contains=@perlInterpSQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*(+ end=+)[imosx]*+ contains=@perlInterpMatch,perlParensDQ keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\>\s*\z([^[:space:]#([{<'/]\)+ end=+\z1[imosx]*+ contains=@perlInterpMatch keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*/+ end=+/[imosx]*+ contains=@perlInterpSlash keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr#+ end=+#[imosx]*+ contains=@perlInterpMatch keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*'+ end=+'[imosx]*+ contains=@perlInterpSQ keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*(+ end=+)[imosx]*+ contains=@perlInterpMatch,perlParensDQ keepend extend
|
||||
|
||||
" A special case for qr{}, qr<> and qr[] which allows for comments and extra whitespace in the pattern
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*{+ end=+}[imosx]*+ contains=@perlInterpMatch,perlBracesDQ,perlComment keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*<+ end=+>[imosx]*+ contains=@perlInterpMatch,perlAnglesDQ,perlComment keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*\[+ end=+\][imosx]*+ contains=@perlInterpMatch,perlBracketsDQ,perlComment keepend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*{+ end=+}[imosx]*+ contains=@perlInterpMatch,perlBracesDQ,perlComment keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*<+ end=+>[imosx]*+ contains=@perlInterpMatch,perlAnglesDQ,perlComment keepend extend
|
||||
syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s*\[+ end=+\][imosx]*+ contains=@perlInterpMatch,perlBracketsDQ,perlComment keepend extend
|
||||
|
||||
" Constructs such as print <<EOF [...] EOF, 'here' documents
|
||||
"
|
||||
@@ -319,14 +331,14 @@ syn region perlQQ matchgroup=perlStringStartEnd start=+\<\%(::\|'\|->\)\@<!qr\s
|
||||
" 'if $a' in 'print <<EOF if $a'). This is almost impossible to get right it
|
||||
" seems due to the 'auto-extending nature' of regions.
|
||||
if exists("perl_fold")
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\z(\I\i*\).*+ end=+^\z1$+ contains=@perlInterpDQ fold
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*"\z([^\\"]*\%(\\.[^\\"]*\)*\)"+ end=+^\z1$+ contains=@perlInterpDQ fold
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*'\z([^\\']*\%(\\.[^\\']*\)*\)'+ end=+^\z1$+ contains=@perlInterpSQ fold
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*""+ end=+^$+ contains=@perlInterpDQ,perlNotEmptyLine fold
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*''+ end=+^$+ contains=@perlInterpSQ,perlNotEmptyLine fold
|
||||
syn region perlAutoload matchgroup=perlStringStartEnd start=+<<\s*\(['"]\=\)\z(END_\%(SUB\|OF_FUNC\|OF_AUTOLOAD\)\)\1+ end=+^\z1$+ contains=ALL fold
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\z(\I\i*\).*+ end=+^\z1$+ contains=@perlInterpDQ fold extend
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*"\z([^\\"]*\%(\\.[^\\"]*\)*\)"+ end=+^\z1$+ contains=@perlInterpDQ fold extend
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*'\z([^\\']*\%(\\.[^\\']*\)*\)'+ end=+^\z1$+ contains=@perlInterpSQ fold extend
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*""+ end=+^$+ contains=@perlInterpDQ,perlNotEmptyLine fold extend
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*''+ end=+^$+ contains=@perlInterpSQ,perlNotEmptyLine fold extend
|
||||
syn region perlAutoload matchgroup=perlStringStartEnd start=+<<\s*\(['"]\=\)\z(END_\%(SUB\|OF_FUNC\|OF_AUTOLOAD\)\)\1+ end=+^\z1$+ contains=ALL fold extend
|
||||
else
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\z(\I\i*\)+ end=+^\z1$+ contains=@perlInterpDQ
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\z(\I\i*\).*+ end=+^\z1$+ contains=@perlInterpDQ
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*"\z([^\\"]*\%(\\.[^\\"]*\)*\)"+ end=+^\z1$+ contains=@perlInterpDQ
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*'\z([^\\']*\%(\\.[^\\']*\)*\)'+ end=+^\z1$+ contains=@perlInterpSQ
|
||||
syn region perlHereDoc matchgroup=perlStringStartEnd start=+<<\s*""+ end=+^$+ contains=@perlInterpDQ,perlNotEmptyLine
|
||||
@@ -349,13 +361,13 @@ if v:version == 701 && !has('patch221') " XXX I hope that's the right one
|
||||
else
|
||||
syn match perlSubAttributesCont "\h\w*\_s*\%(:\_s*\)\=" nextgroup=@perlSubAttrMaybe contained
|
||||
syn region perlSubAttributesCont matchgroup=perlSubAttributesCont start="\h\w*(" end=")\_s*\%(:\_s*\)\=" nextgroup=@perlSubAttrMaybe contained contains=@perlInterpSQ,perlParensSQ
|
||||
syn cluster perlSubAttrMaybe contains=perlSubAttributesCont,perlSubError
|
||||
syn cluster perlSubAttrMaybe contains=perlSubAttributesCont,perlSubError,perlFakeGroup
|
||||
syn match perlSubAttributes "" contained nextgroup=perlSubError
|
||||
syn match perlSubAttributes ":\_s*" contained nextgroup=@perlSubAttrMaybe
|
||||
endif
|
||||
syn match perlSubPrototypeError "(\%(\_s*\%(\%(\\\%([$@%&*]\|\[[$@%&*]\+\]\)\|[$&*]\|[@%]\%(\_s*)\)\@=\|;\%(\_s*[)$@%&*\\]\)\@=\|_\%(\_s*[);]\)\@=\)\_s*\)*\)\@>\zs\_[^)]\+" contained
|
||||
syn match perlSubPrototype +(\_[^)]*)\_s*\|+ nextgroup=perlSubAttributes contained contains=perlSubPrototypeError
|
||||
syn match perlSubName +\%(\h\|::\|'\w\)\%(\w\|::\|'\w\)*\_s*\|+ contained nextgroup=perlSubPrototype
|
||||
syn match perlSubPrototype +(\_[^)]*)\_s*\|+ nextgroup=perlSubAttributes,perlComment contained contains=perlSubPrototypeError
|
||||
syn match perlSubName +\%(\h\|::\|'\w\)\%(\w\|::\|'\w\)*\_s*\|+ contained nextgroup=perlSubPrototype,perlComment
|
||||
|
||||
syn match perlFunction +\<sub\>\_s*+ nextgroup=perlSubName
|
||||
|
||||
@@ -371,7 +383,7 @@ endif
|
||||
syn match perlString "\I\@<!-\?\I\i*\%(\s*=>\)\@="
|
||||
|
||||
" All other # are comments, except ^#!
|
||||
syn match perlComment "#.*" contains=perlTodo,@Spell
|
||||
syn match perlComment "#.*" contains=perlTodo,@Spell extend
|
||||
syn match perlSharpBang "^#!.*"
|
||||
|
||||
" Formats
|
||||
@@ -385,9 +397,11 @@ syn match perlFormatField "@$" contained
|
||||
|
||||
" __END__ and __DATA__ clauses
|
||||
if exists("perl_fold")
|
||||
syntax region perlDATA start="^__\%(DATA\|END\)__$" skip="." end="." contains=perlPOD,@perlDATA fold
|
||||
syntax region perlDATA start="^__DATA__$" skip="." end="." fold
|
||||
syntax region perlDATA start="^__END__$" skip="." end="." contains=perlPOD,@perlDATA fold
|
||||
else
|
||||
syntax region perlDATA start="^__\%(DATA\|END\)__$" skip="." end="." contains=perlPOD,@perlDATA
|
||||
syntax region perlDATA start="^__DATA__$" skip="." end="."
|
||||
syntax region perlDATA start="^__END__$" skip="." end="." contains=perlPOD,@perlDATA
|
||||
endif
|
||||
|
||||
"
|
||||
@@ -400,8 +414,15 @@ if exists("perl_fold")
|
||||
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")
|
||||
syn region perlSubFold start="^\z(\s*\)\<sub\>.*[^};]$" end="^\z1}\s*\%(#.*\)\=$" transparent fold keepend
|
||||
syn region perlSubFold start="^\z(\s*\)\<\%(BEGIN\|END\|CHECK\|INIT\|UNITCHECK\)\>.*[^};]$" end="^\z1}\s*$" transparent fold keepend
|
||||
if exists("perl_fold_anonymous_subs") && perl_fold_anonymous_subs
|
||||
syn region perlSubFold start="\<sub\>[^\n;]*{" end="}" transparent fold keepend extend
|
||||
syn region perlSubFold start="\<\%(BEGIN\|END\|CHECK\|INIT\)\>\s*{" end="}" transparent fold keepend
|
||||
|
||||
syn region perlBraces start="{" end="}" transparent extend
|
||||
else
|
||||
syn region perlSubFold start="^\z(\s*\)\<sub\>.*[^};]$" 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")
|
||||
@@ -418,6 +439,9 @@ endif
|
||||
|
||||
command -nargs=+ HiLink hi def link <args>
|
||||
|
||||
" 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.
|
||||
HiLink perlSharpBang PreProc
|
||||
HiLink perlControl PreProc
|
||||
@@ -505,6 +529,22 @@ HiLink perlSpecialStringU perlSpecial
|
||||
HiLink perlSpecialMatch perlSpecial
|
||||
HiLink 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.
|
||||
HiLink perlParensSQ perlString
|
||||
HiLink perlBracketsSQ perlString
|
||||
HiLink perlBracesSQ perlString
|
||||
HiLink perlAnglesSQ perlString
|
||||
|
||||
HiLink perlParensDQ perlString
|
||||
HiLink perlBracketsDQ perlString
|
||||
HiLink perlBracesDQ perlString
|
||||
HiLink perlAnglesDQ perlString
|
||||
|
||||
HiLink perlSpecialStringU2 perlString
|
||||
|
||||
" Possible errors
|
||||
HiLink perlNotEmptyLine Error
|
||||
HiLink perlElseIfError Error
|
||||
@@ -539,5 +579,13 @@ syn sync match perlSyncPOD grouphere NONE "^=cut"
|
||||
|
||||
let b:current_syntax = "perl"
|
||||
|
||||
if exists('®expengine')
|
||||
let ®expengine=s:regexpengine
|
||||
unlet s:regexpengine
|
||||
endif
|
||||
|
||||
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
|
||||
|
@@ -1,12 +1,13 @@
|
||||
" Vim syntax file
|
||||
" Language: Perl 6
|
||||
" Maintainer: Andy Lester <andy@petdance.com>
|
||||
" Homepage: http://github.com/petdance/vim-perl/tree/master
|
||||
" Last Change: 2012 Apr 30
|
||||
" Language: Perl 6
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" Homepage: http://github.com/vim-perl/vim-perl/tree/master
|
||||
" Bugs/requests: http://github.com/vim-perl/vim-perl/issues
|
||||
" Last Change: 2009-07-04
|
||||
|
||||
" Contributors: Luke Palmer <fibonaci@babylonia.flatirons.org>
|
||||
" Moritz Lenz <moritz@faui2k3.org>
|
||||
" Hinrik Örn Sigurðsson <hinrik.sig@gmail.com>
|
||||
" Contributors: Luke Palmer <fibonaci@babylonia.flatirons.org>
|
||||
" Moritz Lenz <moritz@faui2k3.org>
|
||||
" Hinrik Örn Sigurðsson <hinrik.sig@gmail.com>
|
||||
"
|
||||
" 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.
|
||||
@@ -1023,7 +1024,7 @@ syn match p6PackageScope display "\%(\K\%(\k\|[-']\K\@=\)*\)\?::" nextgroup=p6Pa
|
||||
" TODO: mostly stolen from perl.vim, might need more work
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%([$@%&*]\@<!\%(\<\%(split\|while\|until\|if\|unless\)\|\.\.\|[-+*!~(\[{=]\)\s*\)\@<=//\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\%(\<\%(split\|while\|until\|if\|unless\)\|\.\.\|[-+*!~(\[{=]\)\s*\)\@<=//\@!"
|
||||
\ start="^//\@!"
|
||||
\ start=+\s\@<=/[^[:space:][:digit:]$@%=]\@=\%(/\_s*\%([([{$@%&*[:digit:]"'`]\|\_s\w\|[[:upper:]_abd-fhjklnqrt-wyz]\)\)\@!/\@!+
|
||||
\ skip="\\/"
|
||||
@@ -1033,7 +1034,7 @@ syn region p6Match
|
||||
" m/foo/, mm/foo/, rx/foo/
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=//\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=//\@!"
|
||||
\ skip="\\/"
|
||||
\ end="/"
|
||||
\ keepend
|
||||
@@ -1042,7 +1043,7 @@ syn region p6Match
|
||||
" m!foo!, mm!foo!, rx!foo!
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=!!\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=!!\@!"
|
||||
\ skip="\\!"
|
||||
\ end="!"
|
||||
\ keepend
|
||||
@@ -1051,7 +1052,7 @@ syn region p6Match
|
||||
" m$foo$, mm$foo$, rx$foo$, m|foo|, mm|foo|, rx|foo|, etc
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\z([\"'`|,$]\)\$\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\z([\"'`|,$]\)\$\@!"
|
||||
\ skip="\\\z1"
|
||||
\ end="\z1"
|
||||
\ keepend
|
||||
@@ -1060,7 +1061,7 @@ syn region p6Match
|
||||
" m (foo), mm (foo), rx (foo)
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s\+\)\@<=()\@!)\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s\+\)\@<=()\@!)\@!"
|
||||
\ skip="\\)"
|
||||
\ end=")"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1068,7 +1069,7 @@ syn region p6Match
|
||||
" m[foo], mm[foo], rx[foo]
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\[]\@!]\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\[]\@!]\@!"
|
||||
\ skip="\\]"
|
||||
\ end="]"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1076,7 +1077,7 @@ syn region p6Match
|
||||
" m{foo}, mm{foo}, rx{foo}
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<={}\@!}\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<={}\@!}\@!"
|
||||
\ skip="\\}"
|
||||
\ end="}"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1084,7 +1085,7 @@ syn region p6Match
|
||||
" m<foo>, mm<foo>, rx<foo>
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=<>\@!>\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=<>\@!>\@!"
|
||||
\ skip="\\>"
|
||||
\ end=">"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1092,7 +1093,7 @@ syn region p6Match
|
||||
" m«foo», mm«foo», rx«foo»
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=«»\@!»\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<\%(mm\?\|rx\)\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=«»\@!»\@!"
|
||||
\ skip="\\»"
|
||||
\ end="»"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1102,7 +1103,7 @@ syn region p6Match
|
||||
" s/foo/bar/
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=/"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=/"
|
||||
\ skip="\\/"
|
||||
\ end="/"me=e-1
|
||||
\ keepend
|
||||
@@ -1121,7 +1122,7 @@ syn region p6Substitution
|
||||
" s!foo!bar!
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=!"
|
||||
\ skip="\\!"
|
||||
\ end="!"me=e-1
|
||||
\ keepend
|
||||
@@ -1140,7 +1141,7 @@ syn region p6Substitution
|
||||
" s$foo$bar$, s|foo|bar, etc
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\z([\"'`|,$]\)"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\z([\"'`|,$]\)"
|
||||
\ skip="\\\z1"
|
||||
\ end="\z1"me=e-1
|
||||
\ keepend
|
||||
@@ -1159,7 +1160,7 @@ syn region p6Substitution
|
||||
" s{foo}
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<={}\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<={}\@!"
|
||||
\ skip="\\}"
|
||||
\ end="}"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1167,7 +1168,7 @@ syn region p6Match
|
||||
" s[foo]
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\[]\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\[]\@!"
|
||||
\ skip="\\]"
|
||||
\ end="]"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1175,7 +1176,7 @@ syn region p6Match
|
||||
" s<foo>
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=<>\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=<>\@!"
|
||||
\ skip="\\>"
|
||||
\ end=">"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1183,7 +1184,7 @@ syn region p6Match
|
||||
" s«foo»
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=«»\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=«»\@!"
|
||||
\ skip="\\»"
|
||||
\ end="»"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1191,7 +1192,7 @@ syn region p6Match
|
||||
" s (foo)
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s\+\)\@<=()\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<s\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s\+\)\@<=()\@!"
|
||||
\ skip="\\)"
|
||||
\ end=")"
|
||||
\ contains=@p6Regexen,@p6Variables
|
||||
@@ -1201,7 +1202,7 @@ syn region p6Match
|
||||
" m:P5//
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s*\)\@<=/"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s*\)\@<=/"
|
||||
\ skip="\\/"
|
||||
\ end="/"
|
||||
\ contains=@p6RegexP5,p6Variable,p6VarExclam,p6VarMatch,p6VarNum
|
||||
@@ -1209,7 +1210,7 @@ syn region p6Match
|
||||
" m:P5!!
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s*\)\@<=!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s*\)\@<=!"
|
||||
\ skip="\\!"
|
||||
\ end="!"
|
||||
\ contains=@p6RegexP5,p6Variable,p6VarSlash,p6VarMatch,p6VarNum
|
||||
@@ -1217,7 +1218,7 @@ syn region p6Match
|
||||
" m:P5$$, m:P5||, etc
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s*\)\@<=\z([\"'`|,$]\)"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s*\)\@<=\z([\"'`|,$]\)"
|
||||
\ skip="\\\z1"
|
||||
\ end="\z1"
|
||||
\ contains=@p6RegexP5,@p6Variables
|
||||
@@ -1225,7 +1226,7 @@ syn region p6Match
|
||||
" m:P5 ()
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s\+\)\@<=()\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s\+\)\@<=()\@!"
|
||||
\ skip="\\)"
|
||||
\ end=")"
|
||||
\ contains=@p6RegexP5,@p6Variables
|
||||
@@ -1233,7 +1234,7 @@ syn region p6Match
|
||||
" m:P5[]
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s*\)\@<=[]\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s*\)\@<=[]\@!"
|
||||
\ skip="\\]"
|
||||
\ end="]"
|
||||
\ contains=@p6RegexP5,@p6Variables
|
||||
@@ -1241,7 +1242,7 @@ syn region p6Match
|
||||
" m:P5{}
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s*\)\@<={}\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s*\)\@<={}\@!"
|
||||
\ skip="\\}"
|
||||
\ end="}"
|
||||
\ contains=@p6RegexP5,p6Variables
|
||||
@@ -1249,7 +1250,7 @@ syn region p6Match
|
||||
" m:P5<>
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s*\)\@<=<>\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s*\)\@<=<>\@!"
|
||||
\ skip="\\>"
|
||||
\ end=">"
|
||||
\ contains=@p6RegexP5,p6Variables
|
||||
@@ -1257,7 +1258,7 @@ syn region p6Match
|
||||
" m:P5«»
|
||||
syn region p6Match
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<m\s*:P\%(erl\)\?5\s*\)\@<=«»\@!"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<m\s*:P\%(erl\)\?5\s*\)\@<=«»\@!"
|
||||
\ skip="\\»"
|
||||
\ end="»"
|
||||
\ contains=@p6RegexP5,p6Variables
|
||||
@@ -1267,7 +1268,7 @@ syn region p6Match
|
||||
" tr/foo/bar/, tr|foo|bar, etc
|
||||
syn region p6String
|
||||
\ matchgroup=p6Quote
|
||||
\ start="\%(\<tr\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\z([/\"'`|!,$]\)"
|
||||
\ start="\%(\%(::\|[$@%&][.!^:*?]\?\|\.\)\@<!\<tr\%(\s*:!\?\k\%(\k\|[-']\K\@=\)*\%(([^)]*)\)\?\)*\s*\)\@<=\z([/\"'`|!,$]\)"
|
||||
\ skip="\\\z1"
|
||||
\ end="\z1"me=e-1
|
||||
\ contains=p6RxRange
|
||||
|
@@ -1,9 +1,10 @@
|
||||
" Vim syntax file
|
||||
" Language: Perl POD format
|
||||
" Maintainer: Andy Lester <andy@petdance.com>
|
||||
" Previously: Scott Bigham <dsb@killerbunnies.org>
|
||||
" URL: http://github.com/petdance/vim-perl
|
||||
" Last Change: 2009-08-14
|
||||
" Language: Perl POD format
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" Previously: Scott Bigham <dsb@killerbunnies.org>
|
||||
" Homepage: http://github.com/vim-perl/vim-perl
|
||||
" Bugs/requests: http://github.com/vim-perl/vim-perl/issues
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
" To add embedded POD documentation highlighting to your syntax file, add
|
||||
" the commands:
|
||||
@@ -26,7 +27,11 @@ elseif 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
|
||||
@@ -85,6 +90,100 @@ if version >= 508 || !exists("did_pod_syntax_inits")
|
||||
delcommand HiLink
|
||||
endif
|
||||
|
||||
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
|
||||
|
@@ -1,8 +1,8 @@
|
||||
" Vim syntax file
|
||||
" Language: PROLOG
|
||||
" Maintainers: Thomas Koehler <jean-luc@picard.franken.de>
|
||||
" Last Change: 2009 Dec 04
|
||||
" URL: http://gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/vim/syntax/prolog.vim
|
||||
" Last Change: 2013 May 23
|
||||
" 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.
|
||||
@@ -21,14 +21,14 @@ 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 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 prologClauseHead start=+^[a-z][^(]*(+ skip=+\.[^ ]+ end=+:-\|\.$\|\.[ ]\|-->+ contains=prologComment,prologCComment,prologString
|
||||
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")
|
||||
|
||||
@@ -40,12 +40,12 @@ if !exists("prolog_highlighting_clean")
|
||||
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 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 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
|
||||
@@ -54,7 +54,7 @@ if !exists("prolog_highlighting_clean")
|
||||
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 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
|
||||
@@ -63,11 +63,13 @@ if !exists("prolog_highlighting_clean")
|
||||
syn match prologOperator "=\\=\|=:=\|\\==\|=<\|==\|>=\|\\=\|\\+\|<\|>\|="
|
||||
syn match prologAsIs "===\|\\===\|<=\|=>"
|
||||
|
||||
syn match prologNumber "\<[0123456789]*\>'\@!"
|
||||
syn match prologNumber "\<[0123456789]*\>'\@!"
|
||||
syn match prologCommentError "\*/"
|
||||
syn match prologSpecialCharacter ";"
|
||||
syn match prologSpecialCharacter "!"
|
||||
syn match prologQuestion "?-.*\." contains=prologNumber
|
||||
syn match prologSpecialCharacter ":-"
|
||||
syn match prologSpecialCharacter "-->"
|
||||
syn match prologQuestion "?-.*\." contains=prologNumber
|
||||
|
||||
|
||||
endif
|
||||
@@ -87,27 +89,29 @@ if version >= 508 || !exists("did_prolog_syn_inits")
|
||||
endif
|
||||
|
||||
" The default highlighting.
|
||||
HiLink prologComment Comment
|
||||
HiLink prologCComment Comment
|
||||
HiLink prologCharCode Special
|
||||
HiLink prologComment Comment
|
||||
HiLink prologCComment Comment
|
||||
HiLink prologCharCode Special
|
||||
|
||||
if exists ("prolog_highlighting_clean")
|
||||
|
||||
HiLink prologKeyword Statement
|
||||
HiLink prologClauseHead Statement
|
||||
HiLink prologKeyword Statement
|
||||
HiLink prologClauseHead Statement
|
||||
HiLink prologClause Normal
|
||||
|
||||
else
|
||||
|
||||
HiLink prologKeyword Keyword
|
||||
HiLink prologClauseHead Constant
|
||||
HiLink prologQuestion PreProc
|
||||
HiLink prologKeyword Keyword
|
||||
HiLink prologClauseHead Constant
|
||||
HiLink prologClause Normal
|
||||
HiLink prologQuestion PreProc
|
||||
HiLink prologSpecialCharacter Special
|
||||
HiLink prologNumber Number
|
||||
HiLink prologAsIs Normal
|
||||
HiLink prologCommentError Error
|
||||
HiLink prologAtom String
|
||||
HiLink prologString String
|
||||
HiLink prologOperator Operator
|
||||
HiLink prologNumber Number
|
||||
HiLink prologAsIs Normal
|
||||
HiLink prologCommentError Error
|
||||
HiLink prologAtom String
|
||||
HiLink prologString String
|
||||
HiLink prologOperator Operator
|
||||
|
||||
endif
|
||||
|
||||
|
@@ -2,7 +2,7 @@
|
||||
" Language: Sass
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Filenames: *.sass
|
||||
" Last Change: 2010 Aug 9
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
@@ -17,8 +17,8 @@ syn cluster sassCssAttributes contains=css.*Attr,scssComment,cssValue.*,cssColor
|
||||
|
||||
syn region sassDefinition matchgroup=cssBraces start="{" end="}" contains=TOP
|
||||
|
||||
syn match sassProperty "\%([{};]\s*\|^\)\@<=\%([[:alnum:]-]\|#{[^{}]*}\)\+:" contains=css.*Prop skipwhite nextgroup=sassCssAttribute contained containedin=sassDefinition
|
||||
syn match sassProperty "^\s*\zs\s\%(\%([[:alnum:]-]\|#{[^{}]*}\)\+:\|:[[:alnum:]-]\+\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=sassCssAttribute
|
||||
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
|
||||
@@ -34,14 +34,19 @@ 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,sassProperty
|
||||
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
|
||||
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
|
||||
@@ -53,11 +58,11 @@ syn match sassAmpersand "&"
|
||||
" TODO: Attribute namespaces
|
||||
" TODO: Arithmetic (including strings and concatenation)
|
||||
|
||||
syn region sassInclude start="@import" end=";\|$" contains=scssComment,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\)\>" end="[{};]\@=\|$" contains=sassFor,@sassCssAttributes,sassVariable,sassFunction
|
||||
syn keyword sassFor from to through contained
|
||||
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
|
||||
@@ -70,7 +75,10 @@ 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 sassInclude Include
|
||||
hi def link sassDebug sassControl
|
||||
|
@@ -2,7 +2,7 @@
|
||||
" Language: TeX
|
||||
" Maintainer: Charles E. Campbell <NdrchipO@ScampbellPfamily.AbizM>
|
||||
" Last Change: Mar 11, 2013
|
||||
" Version: 77
|
||||
" Version: 78
|
||||
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_TEX
|
||||
"
|
||||
" Notes: {{{1
|
||||
@@ -55,11 +55,20 @@ endif
|
||||
if exists("g:tex_no_error") && g:tex_no_error
|
||||
let s:tex_no_error= 1
|
||||
endif
|
||||
if exists("g:tex_fast") && g:tex_fast
|
||||
let s:tex_no_error= 1
|
||||
endif
|
||||
if exists("g:tex_tex") && !exists("g:tex_no_error")
|
||||
|
||||
" 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
|
||||
let s:tex_no_error= 1
|
||||
else
|
||||
let s:tex_fast= "bcmMprsSvV"
|
||||
endif
|
||||
|
||||
" let user determine which classes of concealment will be supported
|
||||
@@ -159,7 +168,7 @@ if !exists("tex_no_math")
|
||||
endif
|
||||
|
||||
" Try to flag {} and () mismatches: {{{1
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'm'
|
||||
if s:tex_fast =~ 'm'
|
||||
if !exists("s:tex_no_error")
|
||||
syn region texMatcher matchgroup=Delimiter start="{" skip="\\\\\|\\[{}]" end="}" contains=@texMatchGroup,texError
|
||||
syn region texMatcher matchgroup=Delimiter start="\[" end="]" contains=@texMatchGroup,texError,@NoSpell
|
||||
@@ -176,7 +185,7 @@ endif
|
||||
if !exists("s:tex_no_error")
|
||||
syn match texError "[}\])]"
|
||||
endif
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'M'
|
||||
if s:tex_fast =~ 'M'
|
||||
if !exists("tex_no_math")
|
||||
if !exists("s:tex_no_error")
|
||||
syn match texMathError "}" contained
|
||||
@@ -220,14 +229,14 @@ syn match texLigature "\\\([ijolL]\|ae\|oe\|ss\|AA\|AE\|OE\)$"
|
||||
|
||||
" \begin{}/\end{} section markers: {{{1
|
||||
syn match texBeginEnd "\\begin\>\|\\end\>" nextgroup=texBeginEndName
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'm'
|
||||
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,@NoSpell
|
||||
endif
|
||||
|
||||
" \documentclass, \documentstyle, \usepackage: {{{1
|
||||
syn match texDocType "\\documentclass\>\|\\documentstyle\>\|\\usepackage\>" nextgroup=texBeginEndName,texDocTypeArgs
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'm'
|
||||
if s:tex_fast =~ 'm'
|
||||
syn region texDocTypeArgs matchgroup=Delimiter start="\[" end="]" contained nextgroup=texBeginEndName contains=texComment,@NoSpell
|
||||
endif
|
||||
|
||||
@@ -241,7 +250,7 @@ syn match texInput "\\input\s\+[a-zA-Z/.0-9_^]\+"hs=s+7 contains=texStatemen
|
||||
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 !exists("g:tex_fast") || g:tex_fast =~ 'm'
|
||||
if s:tex_fast =~ 'm'
|
||||
syn region texInputFileOpt matchgroup=Delimiter start="\[" end="\]" contained contains=texComment
|
||||
endif
|
||||
|
||||
@@ -309,7 +318,7 @@ syn match texSpaceCode "\\\(math\|cat\|del\|lc\|sf\|uc\)code`"me=e-1 nextgroup=
|
||||
syn match texSpaceCodeChar "`\\\=.\(\^.\)\==\(\d\|\"\x\{1,6}\|`.\)" contained
|
||||
|
||||
" Sections, subsections, etc: {{{1
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'p'
|
||||
if s:tex_fast =~ 'p'
|
||||
if !exists("g:tex_nospell") || !g:tex_nospell
|
||||
if g:tex_fold_enabled && has("folding")
|
||||
syn region texDocZone matchgroup=texSection start='\\begin\s*{\s*document\s*}' end='\\end\s*{\s*document\s*}' fold contains=@texFoldGroup,@texDocGroup,@Spell
|
||||
@@ -362,7 +371,7 @@ if !exists("g:tex_fast") || g:tex_fast =~ 'p'
|
||||
endif
|
||||
|
||||
" particular support for bold and italic {{{1
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'b'
|
||||
if s:tex_fast =~ 'b'
|
||||
if s:tex_conceal =~ 'b'
|
||||
syn region texBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" end="}" concealends contains=@texBoldGroup
|
||||
syn region texBoldItalStyle matchgroup=texTypeStyle start="\\textit\s*{" end="}" concealends contains=@texItalGroup
|
||||
@@ -372,7 +381,7 @@ if !exists("g:tex_fast") || g:tex_fast =~ 'b'
|
||||
endif
|
||||
|
||||
" Bad Math (mismatched): {{{1
|
||||
if !exists("tex_no_math")
|
||||
if !exists("g:tex_no_math") && !exists("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 "\\[\])]"
|
||||
@@ -393,7 +402,7 @@ if !exists("tex_no_math")
|
||||
let foldcmd= ""
|
||||
endif
|
||||
exe "syn cluster texMathZones add=".grpname
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'M'
|
||||
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*}"'
|
||||
@@ -403,7 +412,7 @@ if !exists("tex_no_math")
|
||||
let grpname = "texMathZone".a:sfx.'S'
|
||||
let syncname = "texSyncMathZone".a:sfx.'S'
|
||||
exe "syn cluster texMathZones add=".grpname
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'M'
|
||||
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*}"'
|
||||
@@ -427,7 +436,7 @@ if !exists("tex_no_math")
|
||||
call TexNewMathZone("L","xxalignat",0)
|
||||
|
||||
" Inline Math Zones: {{{2
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'M'
|
||||
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
|
||||
@@ -445,7 +454,7 @@ if !exists("tex_no_math")
|
||||
syn match texMathOper "[_^=]" contained
|
||||
|
||||
" Text Inside Math Zones: {{{2
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'M'
|
||||
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
|
||||
@@ -540,13 +549,13 @@ else
|
||||
" allows syntax-folding of 2 or more contiguous comment lines
|
||||
" single-line comments are not folded
|
||||
syn match texComment "%.*$" contains=@texCommentGroup
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'c'
|
||||
if s:tex_fast =~ 'c'
|
||||
syn region texComment start="^\zs\s*%.*\_s*%" skip="^\s*%" end='^\ze\s*[^%]' fold
|
||||
syn region texNoSpell contained fold matchgroup=texComment start="%\s*nospell\s*{" end="%\s*nospell\s*}" contains=@texFoldGroup,@NoSpell
|
||||
endif
|
||||
else
|
||||
syn match texComment "%.*$" contains=@texCommentGroup
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'c'
|
||||
if s:tex_fast =~ 'c'
|
||||
syn region texNoSpell contained matchgroup=texComment start="%\s*nospell\s*{" end="%\s*nospell\s*}" contains=@texFoldGroup,@NoSpell
|
||||
endif
|
||||
endif
|
||||
@@ -555,7 +564,7 @@ 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 !exists("g:tex_fast") || g:tex_fast =~ 'v'
|
||||
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
|
||||
" listings package:
|
||||
@@ -586,7 +595,7 @@ if !exists("g:tex_fast") || g:tex_fast =~ 'v'
|
||||
endif
|
||||
|
||||
" Tex Reference Zones: {{{1
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'r'
|
||||
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
|
||||
@@ -600,13 +609,13 @@ syn match texRefZone '\\cite\%([tp]\*\=\)\=' nextgroup=texRefOption,texCite
|
||||
|
||||
" Handle newcommand, newenvironment : {{{1
|
||||
syn match texNewCmd "\\newcommand\>" nextgroup=texCmdName skipwhite skipnl
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'V'
|
||||
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 !exists("g:tex_fast") || g:tex_fast =~ 'V'
|
||||
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
|
||||
@@ -632,11 +641,11 @@ syn match texString "\(``\|''\|,,\)"
|
||||
|
||||
" makeatletter -- makeatother sections
|
||||
if !exists("s:tex_no_error")
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ 'S'
|
||||
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 !exists("g:tex_fast") || g:tex_fast =~ 'S'
|
||||
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
|
||||
@@ -1014,7 +1023,7 @@ if has("conceal") && &enc == 'utf-8'
|
||||
|
||||
" Superscripts/Subscripts {{{2
|
||||
if s:tex_conceal =~ 's'
|
||||
if !exists("g:tex_fast") || g:tex_fast =~ '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
|
||||
@@ -1227,7 +1236,7 @@ if did_tex_syntax_inits == 1
|
||||
let did_tex_syntax_inits= 2
|
||||
" TeX highlighting groups which should share similar highlighting
|
||||
if !exists("s:tex_no_error")
|
||||
if !exists("tex_no_math")
|
||||
if !exists("g:tex_no_math")
|
||||
HiLink texBadMath texError
|
||||
HiLink texMathDelimBad texError
|
||||
HiLink texMathError texError
|
||||
|
210
runtime/syntax/tt2.vim
Normal file
210
runtime/syntax/tt2.vim
Normal file
@@ -0,0 +1,210 @@
|
||||
" Language: TT2 (Perl Template Toolkit)
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" 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-05-12
|
||||
"
|
||||
" Instration:
|
||||
" put tt2.vim and tt2html.vim in to your syntax diretory.
|
||||
"
|
||||
" 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) =~ '<!DOCTYPE HTML' |
|
||||
" \ setf tt2html |
|
||||
" \ else |
|
||||
" \ setf tt2 |
|
||||
" \ endif
|
||||
"
|
||||
" define START_TAG, END_TAG
|
||||
" "ASP"
|
||||
" :let b:tt2_syn_tags = '<% %>'
|
||||
" "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
|
20
runtime/syntax/tt2html.vim
Normal file
20
runtime/syntax/tt2html.vim
Normal file
@@ -0,0 +1,20 @@
|
||||
" Language: TT2 embedded with HTML
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" 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: 2010-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"
|
20
runtime/syntax/tt2js.vim
Normal file
20
runtime/syntax/tt2js.vim
Normal file
@@ -0,0 +1,20 @@
|
||||
" Language: TT2 embedded with Javascript
|
||||
" Maintainer: Andy Lester <andy@petdance.com>
|
||||
" Author: Yates, Peter <pd.yates@gmail.com>
|
||||
" Homepage: http://github.com/vim-perl/vim-perl
|
||||
" Bugs/requests: http://github.com/vim-perl/vim-perl/issues
|
||||
" Last Change: 2013-04-10
|
||||
|
||||
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"
|
@@ -1,7 +1,7 @@
|
||||
" Vim syntax file
|
||||
" Language: Motif UIL (User Interface Language)
|
||||
" Maintainer: Thomas Koehler <jean-luc@picard.franken.de>
|
||||
" Last Change: 2012 May 14
|
||||
" Last Change: 2013 May 23
|
||||
" URL: http://gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/vim/syntax/uil.vim
|
||||
|
||||
" Quit when a syntax file was already loaded
|
||||
@@ -25,11 +25,11 @@ syn keyword uilTodo contained TODO
|
||||
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 region uilString start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@Spell,uilSpecial
|
||||
syn match uilSpecialCharacter "'\\.'"
|
||||
syn match uilSpecialStatement "Xm[^ =(){}]*"
|
||||
syn match uilSpecialStatement "Xm[^ =(){}:;]*"
|
||||
syn match uilSpecialFunction "MrmNcreateCallback"
|
||||
syn match uilRessource "XmN[^ =(){}]*"
|
||||
syn match uilRessource "XmN[^ =(){}:;]*"
|
||||
|
||||
syn match uilNumber "-\=\<\d*\.\=\d\+\(e\=f\=\|[uU]\=[lL]\=\)\>"
|
||||
syn match uilNumber "0[xX]\x\+\>"
|
||||
|
@@ -1,8 +1,8 @@
|
||||
" Vim syntax file
|
||||
" Language: Vim 7.3 script
|
||||
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
|
||||
" Last Change: February 15, 2013
|
||||
" Version: 7.3-24
|
||||
" Last Change: May 29, 2013
|
||||
" Version: 7.3-25
|
||||
" Automatically generated keyword lists: {{{1
|
||||
|
||||
" Quit when a syntax file was already loaded {{{2
|
||||
@@ -18,12 +18,12 @@ syn keyword vimTodo contained COMBAK FIXME TODO XXX
|
||||
syn cluster vimCommentGroup contains=vimTodo,@Spell
|
||||
|
||||
" regular vim commands {{{2
|
||||
syn keyword vimCommand contained a arga[dd] ar[gs] 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 el[se] endfo[r] ene[w] filename fin[d] folddoc[losed] fu[nction] 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] n new noautocmd on[ly] pc[lose] popu p[rint] promptr[epl] ptn pts[elect] py[thon] quote redi[r] res[ize] ru rv[iminfo] sbf[irst] sbr[ewind] scscope sfir[st] sim[alt] sme snoreme spe spellw[rong] star stj[ump] sunme sy t tabe[dit] tabN tabp[revious] tc[l] th[row] tn to[pleft] ts[elect] una[bbreviate] unl ve vie[w] vmapc[lear] wh[ile] win[size] wqa[ll] x xmenu xterm
|
||||
syn keyword vimCommand contained ab argd[elete] 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 elsei[f] endfun ex files fini[sh] foldd[oopen] g 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] N n[ext] noh[lsearch] o[pen] pe popu[p] P[rint] ps[earch] ptN pu[t] python3 r red[o] ret[ab] rub[y] sal[l] sbl[ast] sb[uffer] se[t] sh[ell] sl smenu snoremenu spelld[ump] sp[lit] start st[op] sunmenu syn ta tabf[ind] tabnew tabr[ewind] tcld[o] tj[ump] tN tp[revious] tu u[ndo] unlo[ckvar] verb[ose] vim[grep] vne[w] win wn[ext] w[rite] xa[ll] XMLent xunme
|
||||
syn keyword vimCommand contained abc[lear] argdo 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] em[enu] endf[unction] exi[t] filet fir[st] foldo[pen] get 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 nbc[lose] N[ext] nu[mber] opt[ions] ped[it] pp[op] pro pta[g] ptn[ext] pw[d] q re redr[aw] retu[rn] rubyd[o] san[dbox] sbm[odified] scrip setf[iletype] si sla[st] sn[ext] s@\n@\=\r" spe[llgood] spr[evious] startg[replace] stopi[nsert] sus[pend] sync tab tabfir[st] tabn[ext] tabs tclf[ile] tl[ast] tn[ext] tr tu[nmenu] undoj[oin] uns[ilent] ve[rsion] vimgrepa[dd] vs[plit] winc[md] wN[ext] ws[verb] x[it] XMLns xunmenu
|
||||
syn keyword vimCommand contained abo[veleft] arge[dit] 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] emenu* en[dif] exu[sage] filetype fix[del] for go[to] 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] mz nb[key] nkf o ownsyntax pe[rl] pr profd[el] ptf[irst] ptN[ext] py qa[ll] r[ead] redraws[tatus] rew[ind] rubyf[ile] sa[rgument] sbn[ext] scripte[ncoding] setg[lobal] sig sl[eep] sN[ext] so spelli[nfo] sre[wind] star[tinsert] sts[elect] sv[iew] syncbind tabc[lose] tabl[ast] tabN[ext] ta[g] te[aroff] tm tN[ext] tr[ewind] u undol[ist] up[date] vert[ical] vi[sual] w windo wp[revious] wundo xmapc[lear] xnoreme xwininfo
|
||||
syn keyword vimCommand contained al[l] argg[lobal] 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 en endt[ry] f fin fo[ld] fu gr[ep] 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] mzf[ile] nbs[tart] nmapc[lear] ol[dfiles] p perld[o] pre[serve] prof[ile] ptj[ump] ptp[revious] py3 q[uit] rec[over] reg[isters] ri[ght] rundo sav[eas] sbN[ext] scrip[tnames] setl[ocal] sign sm[agic] sni[ff] sor[t] spellr[epall] st startr[eplace] sun[hide] sw[apname] synlist tabd[o] tabm[ove] tabo[nly] tags tf[irst] tm[enu] TOhtml try un unh[ide] v vi viu[sage] wa[ll] winp[os] wq wv[iminfo] xme xnoremenu y[ank]
|
||||
syn keyword vimCommand contained ar argl[ocal] 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] endf endw[hile] f[ile] fina[lly] foldc[lose] fun grepa[dd] 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[scheme] ne noa omapc[lear] P po[p] prev[ious] promptf[ind] ptl[ast] ptr[ewind] pyf[ile] quita[ll] red Ren rightb[elow] ru[ntime] sba[ll] sbp[revious] scs sf[ind] sil[ent] sm[ap] sno[magic] so[urce] spellu[ndo] sta[g]
|
||||
syn keyword vimCommand contained a arga[dd] ar[gs] 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 el[se] endfo[r] ene[w] filename fin[d] folddoc[losed] fu[nction] 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] n new noautocmd on[ly] pc[lose] popu p[rint] promptr[epl] ptn pts[elect] py[thon] quote redi[r] res[ize] ru rv[iminfo] sbf[irst] sbr[ewind] scscope sfir[st] sim[alt] sme snoreme spe spellw[rong] star st[op] sunmenu syn ta tabf[ind] tabnew tabr[ewind] tcld[o] tj[ump] tN tp[revious] tu u[ndo] unlo[ckvar] verb[ose] vim[grep] vne[w] win wn[ext] w[rite] xa[ll] XMLent xunme
|
||||
syn keyword vimCommand contained ab argd[elete] 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 elsei[f] endfun ex files fini[sh] foldd[oopen] g 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] N n[ext] noh[lsearch] o[pen] pe popu[p] P[rint] ps[earch] ptN pu[t] python3 r red[o] ret[ab] rub[y] sal[l] sbl[ast] sb[uffer] se[t] sh[ell] sl smenu snoremenu spelld[ump] sp[lit] start stopi[nsert] sus[pend] sync tab tabfir[st] tabn[ext] tabs tclf[ile] tl[ast] tn[ext] tr tu[nmenu] undoj[oin] uns[ilent] ve[rsion] vimgrepa[dd] vs[plit] winc[md] wN[ext] ws[verb] x[it] XMLns xunmenu
|
||||
syn keyword vimCommand contained abc[lear] argdo 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] em[enu] endf[unction] exi[t] filet fir[st] foldo[pen] get 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 nbc[lose] N[ext] nu[mber] opt[ions] ped[it] pp[op] pro pta[g] ptn[ext] pw[d] q re redr[aw] retu[rn] rubyd[o] san[dbox] sbm[odified] scrip setf[iletype] si sla[st] sn[ext] s@\n@\=\r" spe[llgood] spr[evious] startg[replace] sts[elect] sv[iew] syncbind tabc[lose] tabl[ast] tabN[ext] ta[g] te[aroff] tm tN[ext] tr[ewind] u undol[ist] up[date] vert[ical] vi[sual] w windo wp[revious] wundo xmapc[lear] xnoreme xwininfo
|
||||
syn keyword vimCommand contained abo[veleft] arge[dit] 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] emenu* en[dif] exu[sage] filetype fix[del] for go[to] 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] mz nb[key] nkf o ownsyntax pe[rl] pr profd[el] ptf[irst] ptN[ext] py qa[ll] r[ead] redraws[tatus] rew[ind] rubyf[ile] sa[rgument] sbn[ext] scripte[ncoding] setg[lobal] sig sl[eep] sN[ext] so spelli[nfo] sre[wind] star[tinsert] sun[hide] sw[apname] synlist tabd[o] tabm[ove] tabo[nly] tags tf[irst] tm[enu] TOhtml try un unh[ide] v vi viu[sage] wa[ll] winp[os] wq wv[iminfo] xme xnoremenu y[ank]
|
||||
syn keyword vimCommand contained al[l] argg[lobal] 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 en endt[ry] f fin fo[ld] fu gr[ep] 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] mzf[ile] nbs[tart] nmapc[lear] ol[dfiles] p perld[o] pre[serve] prof[ile] ptj[ump] ptp[revious] py3 q[uit] rec[over] reg[isters] ri[ght] rundo sav[eas] sbN[ext] scrip[tnames] setl[ocal] sign sm[agic] sni[ff] sor[t] spellr[epall] st startr[eplace] sunme sy t tabe[dit] tabN tabp[revious] tc[l] th[row] tn to[pleft] ts[elect] una[bbreviate] unl ve vie[w] vmapc[lear] wh[ile] win[size] wqa[ll] x xmenu xterm errormsg
|
||||
syn keyword vimCommand contained ar argl[ocal] 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] endf endw[hile] f[ile] fina[lly] foldc[lose] fun grepa[dd] 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[scheme] ne noa omapc[lear] P po[p] prev[ious] promptf[ind] ptl[ast] ptr[ewind] pyf[ile] quita[ll] red Ren rightb[elow] ru[ntime] sba[ll] sbp[revious] scs sf[ind] sil[ent] sm[ap] sno[magic] so[urce] spellu[ndo] sta[g] stj[ump]
|
||||
syn match vimCommand contained "\<z[-+^.=]\="
|
||||
|
||||
" vimOptions are caught only when contained in a vimSet {{{2
|
||||
@@ -96,8 +96,8 @@ endif
|
||||
|
||||
" Numbers {{{2
|
||||
" =======
|
||||
syn match vimNumber "\<\d\+\([lL]\|\.\d\+\)\=" skipwhite nextgroup=vimGlobal,vimSubst,vimCommand
|
||||
syn match vimNumber "-\d\+\([lL]\|\.\d\+\)\=" skipwhite nextgroup=vimGlobal,vimSubst,vimCommand
|
||||
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 "#\x\{6}"
|
||||
|
||||
|
@@ -3,7 +3,7 @@
|
||||
" Maintainer: Johannes Zellner <johannes@zellner.org>
|
||||
" Author and previous maintainer:
|
||||
" Paul Siegmann <pauls@euronet.nl>
|
||||
" Last Change: 2009-07-13 21:26:55
|
||||
" Last Change: 2013 May 29
|
||||
" Filenames: *.xml
|
||||
" $Id: xml.vim,v 1.3 2006/04/11 21:32:00 vimboss Exp $
|
||||
|
||||
@@ -81,7 +81,7 @@ syn match xmlEqual +=+ display
|
||||
" ^^^^^^^^^^^^^
|
||||
"
|
||||
syn match xmlAttrib
|
||||
\ +[-'"<]\@<!\<[a-zA-Z:_][-.0-9a-zA-Z0-9:_]*\>\(['">]\@!\|$\)+
|
||||
\ +[-'"<]\@2<!\<[a-zA-Z:_][-.0-9a-zA-Z0-9:_]*\>\(['">]\@!\|$\)+
|
||||
\ contained
|
||||
\ contains=xmlAttribPunct,@xmlAttribHook
|
||||
\ display
|
||||
@@ -98,14 +98,14 @@ syn match xmlAttrib
|
||||
"
|
||||
if exists("g:xml_namespace_transparent")
|
||||
syn match xmlNamespace
|
||||
\ +\(<\|</\)\@<=[^ /!?<>"':]\+[:]\@=+
|
||||
\ +\(<\|</\)\@2<=[^ /!?<>"':]\+[:]\@=+
|
||||
\ contained
|
||||
\ contains=@xmlNamespaceHook
|
||||
\ transparent
|
||||
\ display
|
||||
else
|
||||
syn match xmlNamespace
|
||||
\ +\(<\|</\)\@<=[^ /!?<>"':]\+[:]\@=+
|
||||
\ +\(<\|</\)\@2<=[^ /!?<>"':]\+[:]\@=+
|
||||
\ contained
|
||||
\ contains=@xmlNamespaceHook
|
||||
\ display
|
||||
@@ -122,7 +122,7 @@ endif
|
||||
" ^^^
|
||||
"
|
||||
syn match xmlTagName
|
||||
\ +[<]\@<=[^ /!?<>"']\++
|
||||
\ +[<]\@2<=[^ /!?<>"']\++
|
||||
\ contained
|
||||
\ contains=xmlNamespace,xmlAttribPunct,@xmlTagHook
|
||||
\ display
|
||||
|
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user