SynEdit: pas-hl, some more info for the outline markup. Code by x2nie

git-svn-id: trunk@52183 -
This commit is contained in:
martin 2016-04-12 23:57:04 +00:00
parent 7a5fbf76ba
commit df4915ecc5

View File

@ -3619,6 +3619,23 @@ begin
//inherited DoInitNode(Node, FinishingABlock, ABlockType, aActions, AIsFold);
aActions := aActions + [sfaMultiLine];
if (not FinishingABlock) and (ABlockType <> nil) then begin
if (PasBlockType in [cfbtIfThen,cfbtForDo,cfbtWhileDo,cfbtWithDo]) then
Include( aActions, sfaOutlineKeepLevel);
if (PasBlockType in [cfbtProcedure]) then
aActions := aActions + [sfaOutlineKeepLevel,sfaOutlineNoColor];
//if (PasBlockType in [cfbtProcedure]) and (InProcLevel > 0) then //nested
// aActions := aActions + [sfaOutlineForceIndent];
if (PasBlockType in [cfbtExcept]) then
Include( aActions, sfaOutlineMergeParent);
// if (PasBlockType in [cfbtIfThen, cfbtClass,cfbtRecord]) then
// aActions := aActions + [sfaOutlineNoLine];
end;
Node.LineIndex := LineIndex;
Node.LogXStart := Run;
Node.LogXEnd := Run + fStringLen;