mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-25 01:08:21 +02:00
synedit: fixed updating gutter when codefolding ranges changed
git-svn-id: trunk@10412 -
This commit is contained in:
parent
e8fa91fe05
commit
40a2432420
@ -2042,7 +2042,9 @@ begin
|
|||||||
if Visible and HandleAllocated then
|
if Visible and HandleAllocated then
|
||||||
if (FirstLine = -1) and (LastLine = -1) then begin
|
if (FirstLine = -1) and (LastLine = -1) then begin
|
||||||
rcInval := ClientRect;
|
rcInval := ClientRect;
|
||||||
|
{$IFNDEF SYN_LAZARUS}
|
||||||
rcInval.Left := fGutterWidth;
|
rcInval.Left := fGutterWidth;
|
||||||
|
{$ENDIF}
|
||||||
if sfLinesChanging in fStateFlags then
|
if sfLinesChanging in fStateFlags then
|
||||||
UnionRect(fInvalidateRect, fInvalidateRect, rcInval)
|
UnionRect(fInvalidateRect, fInvalidateRect, rcInval)
|
||||||
else
|
else
|
||||||
@ -2060,12 +2062,14 @@ begin
|
|||||||
);
|
);
|
||||||
{ any line visible? }
|
{ any line visible? }
|
||||||
if (LastLine >= FirstLine) then begin
|
if (LastLine >= FirstLine) then begin
|
||||||
rcInval := Rect(fGutterWidth,
|
{$IFDEF SYN_LAZARUS}
|
||||||
fTextHeight * {$IFDEF SYN_LAZARUS}RowToScreenRow(FirstLine)
|
rcInval := Rect(0,fTextHeight * RowToScreenRow(FirstLine),
|
||||||
{$ELSE}(FirstLine - TopLine){$ENDIF},
|
ClientWidth-ScrollBarWidth,
|
||||||
ClientWidth{$IFDEF SYN_LAZARUS}-ScrollBarWidth{$ENDIF},
|
fTextHeight * (RowToScreenRow(LastLine)+1));
|
||||||
fTextHeight * {$IFDEF SYN_LAZARUS}(RowToScreenRow(LastLine)+1)
|
{$ELSE}
|
||||||
{$ELSE}(LastLine - TopLine + 1){$ENDIF});
|
rcInval := Rect(fGutterWidth,fTextHeight * (FirstLine - TopLine),
|
||||||
|
ClientWidth, fTextHeight * (LastLine - TopLine + 1));
|
||||||
|
{$ENDIF}
|
||||||
if sfLinesChanging in fStateFlags then
|
if sfLinesChanging in fStateFlags then
|
||||||
UnionRect(fInvalidateRect, fInvalidateRect, rcInval)
|
UnionRect(fInvalidateRect, fInvalidateRect, rcInval)
|
||||||
else
|
else
|
||||||
@ -2393,7 +2397,7 @@ begin
|
|||||||
and (Y >= 0)
|
and (Y >= 0)
|
||||||
and (Y < ClientHeight{$IFDEF SYN_LAZARUS}-ScrollBarWidth{$ENDIF})
|
and (Y < ClientHeight{$IFDEF SYN_LAZARUS}-ScrollBarWidth{$ENDIF})
|
||||||
then begin
|
then begin
|
||||||
if Cursor <> crHandPoint then
|
if (Cursor <> crHandPoint) or (not (ssCtrl in Shift)) then
|
||||||
Cursor := crIBeam;
|
Cursor := crIBeam;
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
|
@ -698,6 +698,10 @@ begin
|
|||||||
Result := tkKey;
|
Result := tkKey;
|
||||||
fRange := rsAsm;
|
fRange := rsAsm;
|
||||||
fAsmStart := True;
|
fAsmStart := True;
|
||||||
|
{$IFDEF SYN_LAZARUS}
|
||||||
|
StartPascalCodeFoldBlock(cfbtBeginEnd);
|
||||||
|
//debugln('TSynPasSyn.Func37 BEGIN ',dbgs(ord(TopPascalCodeFoldBlockType)),' LineNumber=',dbgs(fLineNumber),' ',dbgs(MinimumCodeFoldBlockLevel),' ',dbgs(CurrentCodeFoldBlockLevel));
|
||||||
|
{$ENDIF}
|
||||||
end else Result := tkIdentifier;
|
end else Result := tkIdentifier;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user