Hi,

Is it possible to set the fold level of the previous line?  I am working on
folding for TADS3 and have the following problem.  Top level blocks may have
one of the following styles

silverRing : Wearable {
    'silver ring'
    'silver ring'
    "A silver ring lies glinting in the dust. "
}

or

silverRing : Wearable
    'silver ring'
    'silver ring'
    "A silver ring lies glinting in the dust. "
;

In the second case I don't find out that the block has begun untill I reach
'silver ring' on the second line.  I want to fold at the previous line where
the block actually began.  The first solution that occured to me was to use
the following at the point where I knew that a block had begun.

levelCurrent++;
if (!visibleChars) {
    styler.SetLevel(lineCurrent-1, styler.LevelAt(lineCurrent-1) + 1);
}

however that doesn't seem to work.  Have I missed something?

Michael
_______________________________________________
Scintilla-interest mailing list
[email protected]
http://mailman.lyra.org/mailman/listinfo/scintilla-interest

Reply via email to