newbie question on textadept fold

From: Terry Chen <terrysc....at.gmail.com>
Date: Thu, 5 May 2011 11:08:54 -0400

Hi,

I just started to use textadept, and I have a question about folding.
Does textadept only support folding by indentation?
Or is only a subset of language support folding via syntax (like "{", "}")?

When I set buffer.property['fold.by.indentation'] = '0',
I get an error: "Lua Error: Table of folds expected from lexer.fold"

Coming from scite, I was a little bit surprised by this. It makes me believe
that I am doing something wrong.
Is there a setting somewhere in textadept to use scite's (or scintilla's)
originally lexer and folding?
If not, how can I go about modifying the lpeg lexers to support folding.
Poking my head around the source code seems to point me to the _fold
function as an entry point to implement custom folding levels.
Am I going down the right direction with this? And does anyone have some
examples of some folding code not based on indentation?

Thanks,
Terry
Received on Thu 05 May 2011 - 11:08:54 EDT

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