From 8625978e9955c43a8135751a21da262b0e0d8af4 Mon Sep 17 00:00:00 2001 From: Hugues Hiegel Date: Tue, 23 Dec 2014 17:00:28 +0100 Subject: [plugins] VimWiki + Todo Power --- syntax/vimwiki_markdown.vim | 89 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 syntax/vimwiki_markdown.vim (limited to 'syntax/vimwiki_markdown.vim') diff --git a/syntax/vimwiki_markdown.vim b/syntax/vimwiki_markdown.vim new file mode 100644 index 0000000..13e35e1 --- /dev/null +++ b/syntax/vimwiki_markdown.vim @@ -0,0 +1,89 @@ +" vim:tabstop=2:shiftwidth=2:expandtab:foldmethod=marker:textwidth=79 +" Vimwiki syntax file +" Default syntax +" Author: Maxim Kim +" Home: http://code.google.com/p/vimwiki/ + +" placeholder for math environments +let b:vimwiki_mathEnv = "" + +" text: $ equation_inline $ +let g:vimwiki_rxEqIn = '\$[^$`]\+\$' +let g:vimwiki_char_eqin = '\$' + +" text: *strong* +" let g:vimwiki_rxBold = '\*[^*]\+\*' +let g:vimwiki_rxBold = '\%(^\|\s\|[[:punct:]]\)\@<='. + \'\*'. + \'\%([^*`[:space:]][^*`]*[^*`[:space:]]\|[^*`[:space:]]\)'. + \'\*'. + \'\%([[:punct:]]\|\s\|$\)\@=' +let g:vimwiki_char_bold = '*' + +" text: _emphasis_ +" let g:vimwiki_rxItalic = '_[^_]\+_' +let g:vimwiki_rxItalic = '\%(^\|\s\|[[:punct:]]\)\@<='. + \'_'. + \'\%([^_`[:space:]][^_`]*[^_`[:space:]]\|[^_`[:space:]]\)'. + \'_'. + \'\%([[:punct:]]\|\s\|$\)\@=' +let g:vimwiki_char_italic = '_' + +" text: *_bold italic_* or _*italic bold*_ +let g:vimwiki_rxBoldItalic = '\%(^\|\s\|[[:punct:]]\)\@<='. + \'\*_'. + \'\%([^*_`[:space:]][^*_`]*[^*_`[:space:]]\|[^*_`[:space:]]\)'. + \'_\*'. + \'\%([[:punct:]]\|\s\|$\)\@=' +let g:vimwiki_char_bolditalic = '\*_' + +let g:vimwiki_rxItalicBold = '\%(^\|\s\|[[:punct:]]\)\@<='. + \'_\*'. + \'\%([^*_`[:space:]][^*_`]*[^*_`[:space:]]\|[^*_`[:space:]]\)'. + \'\*_'. + \'\%([[:punct:]]\|\s\|$\)\@=' +let g:vimwiki_char_italicbold = '_\*' + +" text: `code` +let g:vimwiki_rxCode = '`[^`]\+`' +let g:vimwiki_char_code = '`' + +" text: ~~deleted text~~ +let g:vimwiki_rxDelText = '\~\~[^~`]\+\~\~' +let g:vimwiki_char_deltext = '\~\~' + +" text: ^superscript^ +let g:vimwiki_rxSuperScript = '\^[^^`]\+\^' +let g:vimwiki_char_superscript = '^' + +" text: ,,subscript,, +let g:vimwiki_rxSubScript = ',,[^,`]\+,,' +let g:vimwiki_char_subscript = ',,' + +" generic headers +let g:vimwiki_rxH = '#' +let g:vimwiki_symH = 0 + + + +"
, horizontal rule +let g:vimwiki_rxHR = '^-----*$' + +" Tables. Each line starts and ends with '|'; each cell is separated by '|' +let g:vimwiki_rxTableSep = '|' + +" List items start with optional whitespace(s) then '* ' or '1. ', '2. ', etc. +let g:vimwiki_rxListBullet = '^\s*[*+-]\s' +let g:vimwiki_rxListNumber = '^\s*[0-9]\+\.\s' + +let g:vimwiki_rxListDefine = '::\%(\s\|$\)' + +" Preformatted text +let g:vimwiki_rxPreStart = '```' +let g:vimwiki_rxPreEnd = '```' + +" Math block +let g:vimwiki_rxMathStart = '\$\$' +let g:vimwiki_rxMathEnd = '\$\$' + +let g:vimwiki_rxComment = '^\s*%%.*$' -- cgit v1.2.3