Re: [textadept] Changing folding symbol to MARK_BOX* tree doesn't work

From: mitchell <c....at.caladbolg.net>
Date: Sat, 14 May 2011 21:17:35 -0400 (EDT)

Hi Victor,

On Fri, 13 May 2011, Victor T. wrote:

> Hi,
>
> I'm trying textadept out since I wanted a clean extensible code editor
> that uses lua scripting. I downloaded it and played around a bit.
> However I am running into a bit of problem trying to change the
> folding symbols into a boxtree.
>
> Here's what I did:
>
> - Copied scite theme and renamed it to scitemod as a starting base
> - In my user doc folder I added a theme file containing scitemod as
> the first line per instructions
> - I modified view.lua in /scitemod folder as follows:
>
> -- Fold Margin Markers.
> buffer:marker_define(c.SC_MARKNUM_FOLDEROPEN, c.SC_MARK_BOXMINUS)
> buffer:marker_set_fore(c.SC_MARKNUM_FOLDEROPEN, 0xFFFFFF)
> buffer:marker_set_back(c.SC_MARKNUM_FOLDEROPEN, 0x8F8F8F)
>
> buffer:marker_define(c.SC_MARKNUM_FOLDER, c.SC_MARK_BOXPLUS)
> buffer:marker_set_fore(c.SC_MARKNUM_FOLDER, 0xFFFFFF)
> buffer:marker_set_back(c.SC_MARKNUM_FOLDER, 0x8F8F8F)
>
> buffer:marker_define(c.SC_MARKNUM_FOLDERSUB, c.SC_MARK_VLINE)
> buffer:marker_set_fore(c.SC_MARKNUM_FOLDERSUB, 0xFFFFFF)
> buffer:marker_set_back(c.SC_MARKNUM_FOLDERSUB, 0x8F8F8F)
>
> buffer:marker_define(c.SC_MARKNUM_FOLDERTAIL, c.SC_MARK_LCORNER)
> buffer:marker_define(c.SC_MARKNUM_FOLDEREND,
> c.SC_MARK_BOXPLUSCONNECTED)
> buffer:marker_define(c.SC_MARKNUM_FOLDEROPENMID,
> c.SC_MARK_BOXMINUSCONNECTED)
> buffer:marker_define(c.SC_MARKNUM_FOLDERMIDTAIL, c.SC_MARK_TCORNER)

Do not forget to set colors for these last markers.

> Basically I followed the setting in the scite doc here:
> http://www.scintilla.org/ScintillaDoc.html#Markers. However the
> symbols don't appear properly. The +, - boxes show up in black instead
> of grey color and the vertical lines, closing L lines, and T lines are
> missing altogether. Any idea what the problem is?

There is a bug in the fold by indentation code. The correct markers show
up for the contributed dmd folding code. I will have to compare that code
to mine to see what I'm missing.

mitchell

>
> Thanks
>
> --
> You received this message because you are subscribed to the Google Groups "textadept" group.
> To post to this group, send email to textadept.at.googlegroups.com.
> To unsubscribe from this group, send email to textadept+unsubscribe.at.googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/textadept?hl=en.
>
>

mitchell
Received on Sat 14 May 2011 - 21:17:35 EDT

This archive was generated by hypermail 2.2.0 : Thu 08 Mar 2012 - 12:06:50 EST