remove '.. (up a dir)' when NERDTreeMinimalUI is set
Shortening this line doesnt add anything to the UI (functionally speaking), but removing frees up an extra line. Anyone who sets NERDTreeMinimalUI probably uses the u/U mappings anyway.
This commit is contained in:
parent
fad6f06ace
commit
702a88956b
@ -150,11 +150,7 @@ let s:NERDTreeBufName = 'NERD_tree_'
|
|||||||
|
|
||||||
let s:tree_wid = 2
|
let s:tree_wid = 2
|
||||||
let s:tree_markup_reg = '^[ `|]*[\-+~▾▸ ]*'
|
let s:tree_markup_reg = '^[ `|]*[\-+~▾▸ ]*'
|
||||||
if g:NERDTreeMinimalUI == 0
|
let s:tree_up_dir_line = '.. (up a dir)'
|
||||||
let s:tree_up_dir_line = '.. (up a dir)'
|
|
||||||
else
|
|
||||||
let s:tree_up_dir_line = '..'
|
|
||||||
endif
|
|
||||||
|
|
||||||
"the number to add to the nerd tree buffer name to make the buf name unique
|
"the number to add to the nerd tree buffer name to make the buf name unique
|
||||||
let s:next_buffer_number = 1
|
let s:next_buffer_number = 1
|
||||||
@ -3313,8 +3309,10 @@ function! s:renderView()
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
"add the 'up a dir' line
|
"add the 'up a dir' line
|
||||||
call setline(line(".")+1, s:tree_up_dir_line)
|
if !g:NERDTreeMinimalUI
|
||||||
call cursor(line(".")+1, col("."))
|
call setline(line(".")+1, s:tree_up_dir_line)
|
||||||
|
call cursor(line(".")+1, col("."))
|
||||||
|
endif
|
||||||
|
|
||||||
"draw the header line
|
"draw the header line
|
||||||
let header = b:NERDTreeRoot.path.str({'format': 'UI', 'truncateTo': winwidth(0)})
|
let header = b:NERDTreeRoot.path.str({'format': 'UI', 'truncateTo': winwidth(0)})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user