mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-14 09:29:26 +02:00
Small editor draw optimization
This commit is contained in:
parent
8e5f22383f
commit
30dcf0b61a
@ -4153,7 +4153,7 @@ begin
|
|||||||
begin
|
begin
|
||||||
Color:=ColorTab[coTextColor];
|
Color:=ColorTab[coTextColor];
|
||||||
FillChar(FreeFormat,SizeOf(FreeFormat),1);
|
FillChar(FreeFormat,SizeOf(FreeFormat),1);
|
||||||
MoveChar(B,' ',Color,Size.X);
|
{ MoveChar(B,' ',Color,Size.X); redundant, following for loop covers it all }
|
||||||
GetDisplayTextFormat(AY,LineText,Format);
|
GetDisplayTextFormat(AY,LineText,Format);
|
||||||
if ShowIndent and (length(Format)=length(LineText)) then
|
if ShowIndent and (length(Format)=length(LineText)) then
|
||||||
for X:=1 to length(LineText) do
|
for X:=1 to length(LineText) do
|
||||||
@ -4232,7 +4232,8 @@ begin
|
|||||||
FreeFormat[X]:=false;
|
FreeFormat[X]:=false;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
if (0<=LSX+X-1-Delta.X) and (LSX+X-1-Delta.X<MaxViewWidth) then
|
{ redundant check, for loop condition is taking care of correct range
|
||||||
|
if (0<=LSX+X-1-Delta.X) and (LSX+X-1-Delta.X<MaxViewWidth) then }
|
||||||
MoveChar(B[LSX+X-1-Delta.X],C,Color,1);
|
MoveChar(B[LSX+X-1-Delta.X],C,Color,1);
|
||||||
end; { for X:=1 to ... }
|
end; { for X:=1 to ... }
|
||||||
if IsFlagSet(efFolds) then
|
if IsFlagSet(efFolds) then
|
||||||
|
Loading…
Reference in New Issue
Block a user