Vim often needs Redraw after Splitting
Asked Answered
A

2

7

after months of tweaking my vimrc file and installing plugins, I have this little bug which is very painful:

When I'm closing a split (looks like this only appears on vertical ones) the remaining buffer often needs a redraw, because the text is completly screwed up (lines are gone, remaining text from the closed buffer etc)

This can easily been fixed by pressing CTRL-L, but it's really annoying to press CTRL-L each time when I open and close my nerdtree explorer.

Does anyone ran into same/similar problems and/or knows a solution? I was not able to burn down this behaviour to a single line in my vimrc nor to a particular plugin...

Thanks in advance!

Aureomycin answered 12/5, 2011 at 11:10 Comment(5)
which platform? On my ubuntu 11.04 with the latest vim compiled by src I do not see this problem when using nerdtreePutto
I'm using vim on ubuntu 11.04, ubuntu 10.10 and mac os x. On mac I use MacVim where everything works just fine... To be clear: It's not a nerdtree-only problem, this appears on almost every split close.Aureomycin
Graphical or console? Try starting vim with "vim -u NONE" to disable all plugins and settings in .vimrc to see if problem is still there. do a ":help --noplugin" from within vim and play around with the various options therePutto
I've never heard about those switches, thanks! I'll try to find the troublemaker with those - hopefully :) Btw: Both graphical and console...Aureomycin
Notice this too since I work with CLI vim and tmux. Basically have to use redraw a lot. Seems to just be a bug that isn't going to be fixed any time soon.Subset
A
5

I had a similar problem in the past.

I used guioptions-=r and guioptions-=l which remove the left and right scroll bars ant this works just fine, but there are two more options for splits: guioptions-=L and guioptions-=R.

Those remove the scroll bars from split views, too. If you just set lr but not LR, vim will always append the left (or right) scroll bar when using NERDTree and other splits and this causes vim to display screwed up text...

Hope that helps!

Aureomycin answered 13/5, 2011 at 14:15 Comment(0)
C
2

Try to reproduce with disabled syntax coloring. Do this:

:syn off

If it's gone try to tune up your syntax coloring setting. You can tune the way Vim tries to colorize text.

Clastic answered 12/5, 2011 at 11:24 Comment(2)
Thanks for the hint, but the problem still appears when coloring is off.Aureomycin
@Daniel If you use the console, that's show be an normal thing. And one more C-L is not a big deal. At lease, I cannot reproduce your problem when using gvim.Wilkes

© 2022 - 2024 — McMap. All rights reserved.