Sunday, April 22, 2012

Re: Syntax highlighting...

Hi Chris!

On So, 22 Apr 2012, Chris Jones wrote:

> I have a few hundred text files, mostly documentation, and all of them
> basically have the following structure:
>
> | 1. first section
> | ...
> | 2. second section
> | ...
> | etc..
>
> I would like to have Vim automatically create folds so that I could use
> the usual 'z' commands to easily collapse 'first', 'second'.. above, for
> a quick overview of the contents..

set fdm=expr fde=getline(v:lnum)=~'^\\d\\+.*section$'?'>1':'='

regards,
Christian
--
Genie ist oft nur die Fähigkeit, auf ungewöhnliche Art zu schauen.
-- William James

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