" vim:tabstop=2:shiftwidth=2:expandtab:textwidth=99 " Vimwiki syntax file " Description: Defines markdown syntax " Home: https://github.com/vimwiki/vimwiki/ " see the comments in vimwiki_default.vim for some info about this file let s:markdown_syntax = g:vimwiki_syntax_variables['markdown'] " TODO mutualise " Get config: possibly concealed chars let b:vimwiki_syntax_conceal = exists('+conceallevel') ? ' conceal' : '' let b:vimwiki_syntax_concealends = has('conceal') ? ' concealends' : '' " Typeface: let s:markdown_syntax.dTypeface = {} " text: **bold** or __bold__ let s:markdown_syntax.dTypeface['bold'] = [ \ ['\S\@<=__\|__\S\@=', '\S\@<=__\|__\S\@='], \ ['\S\@<=\*\*\|\*\*\S\@=', '\S\@<=\*\*\|\*\*\S\@='], \ ] " text: *italic* or _italic_ let s:markdown_syntax.dTypeface['italic'] = [ \ ['\S\@<=\*\|\*\S\@=', '\S\@<=\*\|\*\S\@='], \ ['\S\@<=_\|_\S\@=', '\S\@<=_\|_\S\@='], \ ] " text: no underline defined let s:markdown_syntax.dTypeface['underline'] = [] " text: *_bold italic_* or _*italic bold*_ or ___bi___ or ***bi*** let s:markdown_syntax.dTypeface['bold_italic'] = [ \ ['\S\@<=\*_\|\*_\S\@=', '\S\@<=_\*\|_\*\S\@='], \ ['\S\@<=_\*\|_\*\S\@=', '\S\@<=\*_\|\*_\S\@='], \ ['\S\@<=\*\*\*\|\*\*\*\S\@=', '\S\@<=\*\*\*\|\*\*\*\S\@='], \ ['\S\@<=___\|___\S\@=', '\S\@<=___\|___\S\@='], \ ] " text: $ equation_inline $ let s:markdown_syntax.rxEqIn = '\$[^$`]\+\$' let s:markdown_syntax.char_eqin = '\$' " text: `code` let s:markdown_syntax.rxCode = '`[^`]\+`' let s:markdown_syntax.char_code = '`' " text: ~~deleted text~~ let s:markdown_syntax.rxDelText = '\~\~[^~`]\+\~\~' let s:markdown_syntax.char_deltext = '\~\~' " text: ^superscript^ let s:markdown_syntax.rxSuperScript = '\^[^^`]\+\^' let s:markdown_syntax.char_superscript = '^' " text: ,,subscript,, let s:markdown_syntax.rxSubScript = ',,[^,`]\+,,' let s:markdown_syntax.char_subscript = ',,' " generic headers let s:markdown_syntax.rxH = '#' let s:markdown_syntax.symH = 0 "