mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-17 01:29:08 +02:00
SynEdit: defer Highlight Scan => increased amount per idle
git-svn-id: trunk@25777 -
This commit is contained in:
parent
46444dc603
commit
8457924769
@ -386,6 +386,9 @@ type
|
|||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
|
const
|
||||||
|
IDLE_SCAN_CHUNK_SIZE = 2500;
|
||||||
|
|
||||||
{$IFDEF _Gp_MustEnhanceRegistry}
|
{$IFDEF _Gp_MustEnhanceRegistry}
|
||||||
function IsRelative(const Value: string): Boolean;
|
function IsRelative(const Value: string): Boolean;
|
||||||
begin
|
begin
|
||||||
@ -1312,8 +1315,8 @@ begin
|
|||||||
EndIndex := CurrentRanges.NeedsReScanEndIndex + 1;
|
EndIndex := CurrentRanges.NeedsReScanEndIndex + 1;
|
||||||
|
|
||||||
RealEndIndex := EndIndex;
|
RealEndIndex := EndIndex;
|
||||||
if EndIndex > StartIndex + 100 then
|
if EndIndex > StartIndex + IDLE_SCAN_CHUNK_SIZE then
|
||||||
EndIndex := StartIndex + 100;
|
EndIndex := StartIndex + IDLE_SCAN_CHUNK_SIZE;
|
||||||
FIsScanning := True;
|
FIsScanning := True;
|
||||||
try
|
try
|
||||||
EndIndex := PerformScan(StartIndex, EndIndex, True);
|
EndIndex := PerformScan(StartIndex, EndIndex, True);
|
||||||
|
Loading…
Reference in New Issue
Block a user