Change default value of g:vimtex_syntax_minted

This commit is contained in:
Karl Yngve Lervåg 2015-08-03 21:51:37 +02:00
parent 0686d92631
commit 47ac958f76
2 changed files with 25 additions and 24 deletions

View File

@ -63,28 +63,7 @@ let b:current_syntax = 'tex'
" }}}1
" {{{1 Nested syntax highlighting for minted
let s:minted = get(g:, 'vimtex_syntax_minted', [
\ {
\ 'lang' : 'c',
\ },
\ {
\ 'lang' : 'cpp',
\ 'environments' : ['cppcode', 'cppcode_test'],
\ },
\ {
\ 'lang' : 'csharp',
\ 'syntax' : 'cs'
\ },
\ {
\ 'lang' : 'python',
\ 'ignore' : [
\ 'pythonEscape',
\ 'pythonBEscape',
\ ],
\ }
\])
for entry in s:minted
for entry in get(g:, 'vimtex_syntax_minted', [])
let lang = entry.lang
let syntax = get(entry, 'syntax', lang)

View File

@ -770,8 +770,30 @@ Options~
the syntax file. The `ignored` entry is also optional, and is used to name
syntax groups to ignore in the minted region.
Default value:
Please see `VIMTEX/after/syntax/tex.vim` for the default value.
Default value: []
Example for some languages: >
let g:vimtex_syntax_minted = [
\ {
\ 'lang' : 'c',
\ },
\ {
\ 'lang' : 'cpp',
\ 'environments' : ['cppcode', 'cppcode_test'],
\ },
\ {
\ 'lang' : 'csharp',
\ 'syntax' : 'cs'
\ },
\ {
\ 'lang' : 'python',
\ 'ignore' : [
\ 'pythonEscape',
\ 'pythonBEscape',
\ ],
\ }
\])
------------------------------------------------------------------------------
Commands~