Skip to content

Commit

Permalink
Set a maximum window size when zooming. (#950)
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilRunninger authored Feb 15, 2019
1 parent 5e8aa9e commit c05615f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions doc/NERDTree.txt
Original file line number Diff line number Diff line change
Expand Up @@ -702,6 +702,9 @@ the NERD tree. These settings should be set in your vimrc, using `:let`.
|NERDTreeWinSize| Sets the window size when the NERD tree is
opened.

|NERDTreeWinSizeMax| Sets the maximum window size when the NERD tree
is zoomed.

|NERDTreeMinimalUI| Disables display of the 'Bookmarks' label and
'Press ? for help' text.

Expand Down
2 changes: 1 addition & 1 deletion lib/nerdtree/ui.vim
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ function! s:UI.toggleZoom()
exec "silent vertical resize ". size
let b:NERDTreeZoomed = 0
else
exec "vertical resize"
exec "vertical resize ". get(g:, 'NERDTreeWinSizeMax', '')
let b:NERDTreeZoomed = 1
endif
endfunction
Expand Down

0 comments on commit c05615f

Please sign in to comment.