Fixed #530: Support opening indexes in current window

This commit is contained in:
Karl Yngve Lervåg 2016-08-23 22:00:48 +02:00
parent cc068c30c5
commit 8d75f01cdd
2 changed files with 13 additions and 6 deletions

View File

@ -62,12 +62,16 @@ function! vimtex#index#create(index) " {{{1
unlet FnVal
endfor
if g:vimtex_index_split_pos ==# 'full'
silent execute 'edit' escape(a:index.name, ' ')
else
if g:vimtex_index_resize
silent exe 'set columns +=' . g:vimtex_index_split_width
endif
silent execute
\ g:vimtex_index_split_pos g:vimtex_index_split_width
\ 'new' escape(a:index.name, ' ')
endif
let b:index = a:index
setlocal bufhidden=wipe

View File

@ -545,7 +545,10 @@ Options~
Default value: 1
*g:vimtex_index_split_pos*
Define where index windows should be opened.
Define where index windows should be opened. This is a string that contains
either the word 'full' to open in the current window, or any of the position
commands, i.e. one or more of |:vertical|, |:leftabove|, |:rightbelow|, |:topleft|,
and |:botright|.
Default value: 'vert leftabove'