Script local indent function was not recognized

This commit is contained in:
Karl Yngve Lervåg 2015-03-19 15:12:41 +01:00
parent e290144c3a
commit 94b39193eb

View File

@ -16,11 +16,11 @@ let s:cpo_save = &cpo
set cpo&vim set cpo&vim
setlocal autoindent setlocal autoindent
setlocal indentexpr=s:vimtex_indent() setlocal indentexpr=VimtexIndent()
setlocal indentkeys& setlocal indentkeys&
setlocal indentkeys+=[,(,{,),},],\&,=\\item setlocal indentkeys+=[,(,{,),},],\&,=\\item
function! s:vimtex_indent() " {{{1 function! VimtexIndent() " {{{1
" Find a non-blank non-comment line above the current line " Find a non-blank non-comment line above the current line
let lnum = prevnonblank(v:lnum - 1) let lnum = prevnonblank(v:lnum - 1)
while lnum != 0 && getline(lnum) =~# '^\s*%' while lnum != 0 && getline(lnum) =~# '^\s*%'