Saturday, November 27, 2010

major confusion on vim folding behavior I'm seeing

I'm trying to get vim folding to behave as I'd expect. I changed it to 'indent' (since it wasn't picking up html files for some reason with 'syntax' as the folding type.) Here is a valid xml file indented properly (just a snippet shown):

http://img.skitch.com/20101127-qe6x55rbfrp1xg14dhhqi3h12d.jpg

Now if I put my cursor in the node "distributionManagement" I'd expect it to collapse that node (using zc),  Instead it collapses a bunch of junk and looks like:

http://img.skitch.com/20101127-qk79fh5k73ash2xpmdeiry2421.jpg

I really have no idea what's going on. It seems to just do very random stuff when I mess around with collapsing and expanding nodes. I read the help file and I thought I grasped the concepts, but apparently not or else I have something set up wrong.

my .vimrc has:

set foldmethod=indent
set nofoldenable        "dont fold by default
set foldlevel=0

I tried set foldlevel=1 also

 

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments:

Post a Comment