I have problems with automated splits and folding. In my ~/.gvimrc file, at the very end, I have the command
vsplit, so that when I'm using gvim as opposed to vim, it opens with two panes. The problem occurs when I open a file that would normally be folded via the command line, as in
gvim example.cpp. This opens the example.cpp file in two panes; however, the first pane is folded while the second is not. It's a minor annoyance, but I wondered if anyone had a suggestion to get the second (or all) buffers to be folded when the window first appears.
If it makes a difference, I use
set foldmethod=indent in my ~/.vimrc file, and my version is 7.1.
How do I do a :g with a concatenating of submatches in Vim?
Can vim monitor realtime changes to a file
vim mapping :w with a shell command
Anyway, I found an easy workaround.
Is it possible to display Indentation guides in Vim?
I have this at the end of my
.vimrcand what you are looking for now works on my vim:.
Delay before 'O' opens a new line?
Now when I open a file, the window is split in two and both are folded correctly..
set foldmethod=indent set sw=2 set tw=2 vsplit +edit
Map key to toggle between normal mode and insert mode in Vim
The workaround is executing the ex command
:editon the second pane so that the missing settings (although it seems that only
'foldmethod'is missing) are reloaded.
Does omnicppcomplete support typedef syntax
That's what the
How do I get the VIM matchit plugin working with ColdFusion and HTML?
Hope this resolves your problem..