SynEdit: markup, added BeginMarkup notification

git-svn-id: trunk@54020 -
This commit is contained in:
martin 2017-01-28 03:20:47 +00:00
parent ccc7c8c621
commit b5d8bc7807
2 changed files with 16 additions and 0 deletions

View File

@ -1730,6 +1730,7 @@ var
{ end local procedures }
begin
fMarkupManager.BeginMarkup;
FTokenBreaker.Prepare(DisplayView, FTheLinesView, FMarkupManager, FirstCol, LastCol);
FTokenBreaker.ForegroundColor := ForegroundColor;
FTokenBreaker.BackgroundColor := BackgroundColor;

View File

@ -101,6 +101,7 @@ type
destructor Destroy; override;
Procedure PrepareMarkupForRow(aRow : Integer); virtual;
Procedure FinishMarkupForRow(aRow : Integer); virtual;
Procedure BeginMarkup; virtual;
Procedure EndMarkup; virtual;
Function GetMarkupAttributeAtRowCol(const aRow: Integer;
const aStartCol: TLazSynDisplayTokenBound;
@ -167,6 +168,7 @@ type
Procedure PrepareMarkupForRow(aRow : Integer); override;
Procedure FinishMarkupForRow(aRow : Integer); override;
Procedure BeginMarkup; virtual;
Procedure EndMarkup; override;
Function GetMarkupAttributeAtRowCol(const aRow: Integer;
const aStartCol: TLazSynDisplayTokenBound;
@ -422,6 +424,10 @@ procedure TSynEditMarkup.FinishMarkupForRow(aRow: Integer);
begin
end;
procedure TSynEditMarkup.BeginMarkup;
begin
end;
procedure TSynEditMarkup.EndMarkup;
begin
end;
@ -549,6 +555,15 @@ begin
TSynEditMarkup(fMarkUpList[i]).FinishMarkupForRow(aRow);
end;
procedure TSynEditMarkupManager.BeginMarkup;
var
i : integer;
begin
for i := 0 to fMarkUpList.Count-1 do
if TSynEditMarkup(fMarkUpList[i]).RealEnabled then
TSynEditMarkup(fMarkUpList[i]).BeginMarkup;
end;
procedure TSynEditMarkupManager.EndMarkup;
var
i : integer;