* DONE: vimwiki default markup to HTML conversion improved.
* DONE: Added basic `GoogleWiki` and `MediaWiki` markup languages.
* DONE: Chinese `[[complex wiki words]]`.
"" use max highlighting - could be quite slow if there are too many wikifiles
if g:vimwiki_maxhi
" Every WikiWord is nonexistent
execute 'syntax match wikiNoExistsWord /'.g:vimwiki_word1.'/'
execute 'syntax match wikiNoExistsWord /'.g:vimwiki_word2.'/'
" till we find them in g:vimwiki_home
call vimwiki#WikiHighlightWords()
else
" A WikiWord (unqualifiedWikiName)
execute 'syntax match wikiWord /'.g:vimwiki_word1.'/'
" A [[bracketed wiki word]]
execute 'syntax match wikiWord /'.g:vimwiki_word2.'/'
endif
" text: "this is a link (optional tooltip)":http://www.microsoft.com
" TODO: check URL syntax against RFC
let g:vimwiki_rxWeblink = '\("[^"(]\+\((\([^)]\+\))\)\?":\)\?\(https\?\|ftp\|gopher\|telnet\|file\|notes\|ms-help\):\(\(\(//\)\|\(\\\\\)\)\+[A-Za-z0-9:#@%/;$~_?+-=.&\-\\\\]*\)'
execute 'syntax match wikiLink `'.g:vimwiki_rxWeblink.'`'
" Emoticons: must come after the Textilisms, as later rules take precedence
" over earlier ones. This match is an approximation for the ~70 distinct
syntax match wikiEmoticons /\((.)\|:[()|$@]\|:-[DOPS()\]|$@]\|;)\|:'(\)/
let g:vimwiki_rxTodo = '\(TODO:\|DONE:\|FIXME:\|FIXED:\)'
execute 'syntax match wikiTodo /'. g:vimwiki_rxTodo .'/'
execute 'syntax match wikiH1 /'.g:vimwiki_rxH1.'/'
execute 'syntax match wikiH2 /'.g:vimwiki_rxH2.'/'
execute 'syntax match wikiH3 /'.g:vimwiki_rxH3.'/'
execute 'syntax match wikiH4 /'.g:vimwiki_rxH4.'/'
execute 'syntax match wikiH5 /'.g:vimwiki_rxH5.'/'
execute 'syntax match wikiH6 /'.g:vimwiki_rxH6.'/'
" <hr>, horizontal rule
execute 'syntax match wikiHR /'.g:vimwiki_rxHR.'/'
" Tables. Each line starts and ends with '||'; each cell is separated by '||'
execute 'syntax match wikiTable /'.g:vimwiki_rxTable.'/'
" Bulleted list items start with whitespace(s), then '*'
" syntax match wikiList /^\s\+\(\*\|[1-9]\+0*\.\).*$/ contains=@wikiText
" highlight only bullets and digits.
execute 'syntax match wikiList /'.g:vimwiki_rxListBullet.'/'
execute 'syntax match wikiList /'.g:vimwiki_rxListNumber.'/'
" Treat all other lines that start with spaces as PRE-formatted text.
execute 'syntax match wikiPre /'.g:vimwiki_rxPre1.'/'
hi def link wikiH1 Title
hi def link wikiH2 wikiH1
hi def link wikiH3 wikiH2
hi def link wikiH4 wikiH3
hi def link wikiH5 wikiH4
hi def link wikiH6 wikiH5
hi def link wikiHR wikiH6
hi def wikiBold term=bold cterm=bold gui=bold
hi def wikiItalic term=italic cterm=italic gui=italic
hi def link wikiCode PreProc
hi def link wikiWord Underlined
hi def link wikiNoExistsWord Error
hi def link wikiPre PreProc
hi def link wikiLink Underlined
hi def link wikiList Type
hi def link wikiTable PreProc
hi def link wikiEmoticons Constant
hi def link wikiDelText Comment
hi def link wikiInsText Constant
hi def link wikiSuperScript Constant
hi def link wikiSubScript Constant
hi def link wikiTodo Todo
let b:current_syntax="vimwiki"
syntax\vimwiki_default.vim [[[1
54
" Vim syntax file
" Language: Wiki (vimwiki default)
" Author: Maxim Kim (habamax at gmail dot com)
" Home: http://code.google.com/p/vimwiki/
" Filenames: *.wiki
" Last Change: [15.09.2008 - 12:07]
" Version: 0.5
" text: *strong*
let g:vimwiki_rxBold = '\*[^*]\+\*'
" text: _emphasis_
let g:vimwiki_rxItalic = '_[^_]\+_'
" text: `code`
let g:vimwiki_rxCode = '`[^`]\+`'
" text: ~~deleted text~~
let g:vimwiki_rxDelText = '\~\~[^~]\+\~\~'
" text: ^superscript^
let g:vimwiki_rxSuperScript = '\^[^^]\+\^'
" text: ,,subscript,,
let g:vimwiki_rxSubScript = ',,[^,]\+,,'
" Header levels, 1-6
let g:vimwiki_rxH1 = '^!\{1}.*$'
let g:vimwiki_rxH2 = '^!\{2}.*$'
let g:vimwiki_rxH3 = '^!\{3}.*$'
let g:vimwiki_rxH4 = '^!\{4}.*$'
let g:vimwiki_rxH5 = '^!\{5}.*$'
let g:vimwiki_rxH6 = '^!\{6}.*$'
" <hr>, horizontal rule
let g:vimwiki_rxHR = '^----.*$'
" Tables. Each line starts and ends with '||'; each cell is separated by '||'
let g:vimwiki_rxTable = '||'
" Bulleted list items start with whitespace(s), then '*'
" syntax match wikiList /^\s\+\(\*\|[1-9]\+0*\.\).*$/ contains=@wikiText
" highlight only bullets and digits.
" let g:vimwiki_rxList = '^\s\+\(\*\|#\)'
let g:vimwiki_rxListBullet = '^\s\+\*'
let g:vimwiki_rxListNumber = '^\s\+#'
" Treat all other lines that start with spaces as PRE-formatted text.
let g:vimwiki_rxPre1 = '^\s\+[^[:blank:]*#].*$'
syntax region wikiPre start=/^{{{\s*$/ end=/^}}}\s*$/
syntax sync match wikiPreSync grouphere wikiPre /^{{{\s*$/
" vim:tw=0:
syntax\vimwiki_google.vim [[[1
53
" Vim syntax file
" Language: Wiki
" Author: Maxim Kim (habamax at gmail dot com)
" Home: http://code.google.com/p/vimwiki/
" Filenames: *.wiki
" Last Change: [15.09.2008 - 12:07]
" Version: 0.5
" text: *strong*
let g:vimwiki_rxBold = '\*[^*]\+\*'
" text: _emphasis_
let g:vimwiki_rxItalic = '_[^_]\+_'
" text: `code`
let g:vimwiki_rxCode = '`[^`]\+`'
" text: ~~deleted text~~
let g:vimwiki_rxDelText = '\~\~[^~]\+\~\~'
" text: ^superscript^
let g:vimwiki_rxSuperScript = '\^[^^]\+\^'
" text: ,,subscript,,
let g:vimwiki_rxSubScript = ',,[^,]\+,,'
" Header levels, 1-6
let g:vimwiki_rxH1 = '^\s*=\{1}.*=\{1}\s*$'
let g:vimwiki_rxH2 = '^\s*=\{2}.*=\{2}\s*$'
let g:vimwiki_rxH3 = '^\s*=\{3}.*=\{3}\s*$'
let g:vimwiki_rxH4 = '^\s*=\{4}.*=\{4}\s*$'
let g:vimwiki_rxH5 = '^\s*=\{5}.*=\{5}\s*$'
let g:vimwiki_rxH6 = '^\s*=\{6}.*=\{6}\s*$'
" <hr>, horizontal rule
let g:vimwiki_rxHR = '^----.*$'
" Tables. Each line starts and ends with '||'; each cell is separated by '||'
let g:vimwiki_rxTable = '||'
" Bulleted list items start with whitespace(s), then '*'
" syntax match wikiList /^\s\+\(\*\|[1-9]\+0*\.\).*$/ contains=@wikiText
" highlight only bullets and digits.
let g:vimwiki_rxListBullet = '^\s\+\*'
let g:vimwiki_rxListNumber = '^\s\+#'
" Treat all other lines that start with spaces as PRE-formatted text.
let g:vimwiki_rxPre1 = '^\s\+[^[:blank:]*#].*$'
syntax region wikiPre start=/^{{{\s*$/ end=/^}}}\s*$/
syntax sync match wikiPreSync grouphere wikiPre /^{{{\s*$/
" vim:tw=0:
syntax\vimwiki_media.vim [[[1
52
" Vim syntax file
" Language: Wiki (MediaWiki)
" Author: Maxim Kim (habamax at gmail dot com)
" Home: http://code.google.com/p/vimwiki/
" Filenames: *.wiki
" Last Change: [15.09.2008 - 12:07]
" Version: 0.5
" text: '''strong'''
let g:vimwiki_rxBold = "'''[^']\\+'''"
" text: ''emphasis''
let g:vimwiki_rxItalic = "''[^']\\+''"
" text: `code`
let g:vimwiki_rxCode = '`[^`]\+`'
" text: ~~deleted text~~
let g:vimwiki_rxDelText = '\~\~[^~]\+\~\~'
" text: ^superscript^
let g:vimwiki_rxSuperScript = '\^[^^]\+\^'
" text: ,,subscript,,
let g:vimwiki_rxSubScript = ',,[^,]\+,,'
" Header levels, 1-6
let g:vimwiki_rxH1 = '^\s*=\{1}.\+=\{1}\s*$'
let g:vimwiki_rxH2 = '^\s*=\{2}.\+=\{2}\s*$'
let g:vimwiki_rxH3 = '^\s*=\{3}.\+=\{3}\s*$'
let g:vimwiki_rxH4 = '^\s*=\{4}.\+=\{4}\s*$'
let g:vimwiki_rxH5 = '^\s*=\{5}.\+=\{5}\s*$'
let g:vimwiki_rxH6 = '^\s*=\{6}.\+=\{6}\s*$'
" <hr>, horizontal rule
let g:vimwiki_rxHR = '^----.*$'
" Tables. Each line starts and ends with '||'; each cell is separated by '||'
let g:vimwiki_rxTable = '||'
" Bulleted list items start with whitespace(s), then '*'
" highlight only bullets and digits.
let g:vimwiki_rxListBullet = '^\s*\*\+\([^*]*$\)\@='
let g:vimwiki_rxListNumber = '^\s*#\+'
" Treat all other lines that start with spaces as PRE-formatted text.
let g:vimwiki_rxPre1 = '^\s\+[^[:blank:]*#].*$'
syntax region wikiPre start=/^{{{\s*$/ end=/^}}}\s*$/
syntax sync match wikiPreSync grouphere wikiPre /^{{{\s*$/
" vim:tw=0:
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.