Friday, June 7, 2013

Re: close all folds but current?

Erik Christiansen wrote:
> On 07.06.13 01:44, steen wrote:
>> Now the only issue I am having is with what I perceive to be inconsistent
>> behavior in foldmethod=indent, where it looks sometimes the same
>> indentations of line get included in a single fold. I suspect this is
>> something about me not understanding whitespace, so I should do further
>> testing before I ask any real questions about it.
> One test I'd do in that case is:
>
> :set expandtab
> :retab
>
> to convert all mixes of spaces and tabs to just spaces.
> Then see if fold behaviour improves, given the more consistent whitespace.
>
> It may change nothing, but you'd then know one thing which is not the
> cause.
>
> Erik

I use the following map:invoke it by hitting the space bar...
nno <silent> <space> :exe 'sil! norm! '.((foldclosed('.')>0)?
"zMzxzt" : 'zc')<cr>

In order to get just the current fold the only open one, I usually just
slap the space bar twice.

Regards,
C Campbell


--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments: