Update runtime files.
Includes changing &sw to shiftwidth() for all indent scripts.
diff --git a/runtime/indent/tex.vim b/runtime/indent/tex.vim
index fc6cc0a..1a4d8b1 100644
--- a/runtime/indent/tex.vim
+++ b/runtime/indent/tex.vim
@@ -215,14 +215,14 @@
" ZYC modification : \end after \begin won't cause wrong indent anymore
if line =~ '\\begin{.*}'
if line !~ g:tex_noindent_env
- let ind = ind + &sw
+ let ind = ind + shiftwidth()
let stay = 0
endif
if g:tex_indent_items
" Add another sw for item-environments
if line =~ g:tex_itemize_env
- let ind = ind + &sw
+ let ind = ind + shiftwidth()
let stay = 0
endif
endif
@@ -241,23 +241,23 @@
if g:tex_indent_items
" Remove another sw for item-environments
if cline =~ g:tex_itemize_env
- let ind = ind - &sw
+ let ind = ind - shiftwidth()
let stay = 0
endif
endif
- let ind = ind - &sw
+ let ind = ind - shiftwidth()
let stay = 0
endif
if g:tex_indent_brace
if line =~ '[[{]$'
- let ind += &sw
+ let ind += shiftwidth()
let stay = 0
endif
if cline =~ '^\s*\\\?[\]}]' && s:CheckPairedIsLastCharacter(v:lnum, indent(v:lnum))
- let ind -= &sw
+ let ind -= shiftwidth()
let stay = 0
endif
@@ -266,7 +266,7 @@
let char = line[i]
if char == ']' || char == '}'
if s:CheckPairedIsLastCharacter(lnum, i)
- let ind -= &sw
+ let ind -= shiftwidth()
let stay = 0
endif
endif
@@ -280,12 +280,12 @@
if g:tex_indent_items
" '\item' or '\bibitem' itself:
if cline =~ g:tex_items
- let ind = ind - &sw
+ let ind = ind - shiftwidth()
let stay = 0
endif
" lines following to '\item' are intented once again:
if line =~ g:tex_items
- let ind = ind + &sw
+ let ind = ind + shiftwidth()
let stay = 0
endif
endif
@@ -317,9 +317,9 @@
return indent(lnum)
endif
if line =~ g:tex_itemize_env
- return indent(lnum) + 2 * &sw
+ return indent(lnum) + 2 * shiftwidth()
endif
- return indent(lnum) + &sw
+ return indent(lnum) + shiftwidth()
endif
endfor
return -1
@@ -347,7 +347,7 @@
let min_indent = min([min_indent, indent(lnum)])
endif
endfor
- return min_indent - &sw
+ return min_indent - shiftwidth()
endfunction
" Most of the code is from matchparen.vim