Question

I am using vim 7.3 and the NERDTree 4.1 plugin.

I have been trying to get 2 NERDTrees to appear in the same tab but can't find how to do it so I am on the verge of calling it a day.

Just wondered if anyone new if it was possible and if so how?

Was it helpful?

Solution

Hmm, I don't think that's possible, at least I don't know any solution. NERDTree window is positioned in a screen-wise way, even if you open another window and toggle the Tree it will affect the single one.

I have been searching the help, but the closest topic I found is about window positioning. It says nothing about multiple windows, but suggests that one exclusive NERDTree window will be present on screen:

------------------------------------------------------------------------------
                                                             'NERDTreeWinPos'
Values: "left" or "right"
Default: "left".

This option  is used  to determine  where NERD  tree window  is placed  on the
screen.

This  option  makes  it  possible   to  use  two  different  explorer  plugins
simultaneously. For example, you could have  the taglist plugin on the left of
the window and the NERD tree on the right.

------------------------------------------------------------------------------

OTHER TIPS

I get close to the desired outcome by pressing 's' over a directory node, this opens a new vertical window with NERDTree characteristics but without the positioning.

Therefore I then might need to to resize so the file open for edit has greater presidence:

vert resize 30

and possibly set height and width of the new NERDTree window so it doesn't keep moving with new files:

set wfw
set wfh

And then every time I try open a node out of the new window (with 's') it shifts to the right so I need to move it back with.

CTRL-W_H

Not very convenient I must admit.

In that case the answer to the questions is no, in NERD Tree's current state

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top