[patch] change foldtext

31 views
Skip to first unread message

Christian Brabandt

unread,
Jul 27, 2011, 5:07:12 PM7/27/11
to vim...@vim.org
Hi Bram,

not sure, if this issue is still valid, but anyway, this patch fixes
this issue from the todo list:

,----
| 7 Use "++--", "+++--" for different levels instead of "+---" "+----".
`----

regards,
Christian

new_foldtext.diff

Bram Moolenaar

unread,
Jul 28, 2011, 2:20:58 PM7/28/11
to Christian Brabandt, vim...@vim.org

Christian Brabandt wrote:

> not sure, if this issue is still valid, but anyway, this patch fixes
> this issue from the todo list:
>
> ,----
> | 7 Use "++--", "+++--" for different levels instead of "+---" "+----".
> `----

Thanks, I'll look into it soon.

--
ARTHUR: Well, I AM king...
DENNIS: Oh king, eh, very nice. An' how'd you get that, eh? By exploitin'
the workers -- by 'angin' on to outdated imperialist dogma which
perpetuates the economic an' social differences in our society! If
there's ever going to be any progress--
The Quest for the Holy Grail (Monty Python)

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

Ben Fritz

unread,
Jul 29, 2011, 12:13:41 AM7/29/11
to vim_dev


On Jul 28, 1:20 pm, Bram Moolenaar <B...@Moolenaar.net> wrote:
> Christian Brabandt wrote:
> > not sure, if this issue is still valid, but anyway, this patch fixes
> > this issue from the todo list:
>
> > ,----
> > | 7   Use "++--", "+++--" for different levels instead of "+---" "+----".
> > `----
>
> Thanks, I'll look into it soon.
>

This is going to break TOhtml's gathering of data to describe each
fold, specifically the foldlevel calculation. Currently it looks for
the number of dashes after the initial "+-". I'll send an update
tomorrow or this weekend which counts the '+' characters instead.

Benjamin Fritz

unread,
Jul 30, 2011, 1:18:02 AM7/30/11
to vim_dev

Update for TOhtml attached. Additionally, I noticed an extraneous
space character added to the foldtext by the patch. Updated patch also
attached to remove this extra space, but perhaps it was intentional.

--
Ben

new_foldtext_updated.diff
tohtml.vim
2html.vim

Ben Fritz

unread,
Jul 30, 2011, 1:20:25 AM7/30/11
to vim_dev


On Jul 30, 12:18 am, Benjamin Fritz <fritzophre...@gmail.com> wrote:
>
> > This is going to break TOhtml's gathering of data to describe each
> > fold, specifically the foldlevel calculation. Currently it looks for
> > the number of dashes after the initial "+-". I'll send an update
> > tomorrow or this weekend which counts the '+' characters instead.
>
> Update for TOhtml attached.

Note, this update should only be included in the runtime, if the patch
is included first. It won't work with the old foldtext until I'm able
to add a "has('patchXXX')" check, but I figure it would be best to
push both together so the tip isn't broken.
Reply all
Reply to author
Forward
0 new messages