Fixed #554: Wrong syntax highlighting of \cite[pt]

This commit is contained in:
Karl Yngve Lervåg 2016-09-14 23:02:57 +02:00
parent 7e2793d4e3
commit 4e39b1337d

View File

@ -65,12 +65,6 @@ highlight link texHyperref texRefZone
" }}}1
" {{{1 Improve support for cite commands
if get(g:, 'tex_fast', 'r') =~# 'r'
"
" natbib
"
syntax match texStatement '\\cite\%([tp]\*\?\)\?'
\ nextgroup=texRefOption,texCite
"
" biblatex
"
@ -104,6 +98,15 @@ if get(g:, 'tex_fast', 'r') =~# 'r'
execute 'syntax match texStatement /\\cite\%(field\|list\|name\)/'
\ 'nextgroup=texRefOptions,texCites'
"
" natbib
"
syntax match texStatement '\\cite\%([tp]\*\?\)\?'
\ nextgroup=texRefOption,texCite
"
" Common
"
syntax region texRefOptions contained matchgroup=Delimiter
\ start='\[' end=']'
\ contains=@texRefGroup,texRefZone