mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-23 05:39:29 +02:00
SynEdit: (Un)Indent current line, if no selection. Issue #0019724
git-svn-id: trunk@32049 -
This commit is contained in:
parent
bfdb46c6b6
commit
df270d4561
@ -7798,13 +7798,17 @@ var
|
||||
end;
|
||||
|
||||
begin
|
||||
if not SelAvail then exit;
|
||||
IncPaintLock;
|
||||
FBlockSelection.IncPersistentLock;
|
||||
try
|
||||
// build text to insert
|
||||
BB := BlockBegin;
|
||||
BE := BlockEnd;
|
||||
if not SelAvail then begin
|
||||
BB := CaretXY;
|
||||
BE := CaretXY;
|
||||
end else begin
|
||||
BB := BlockBegin;
|
||||
BE := BlockEnd;
|
||||
end;
|
||||
if (BE.X = 1) then
|
||||
e := BE.y - 1
|
||||
else
|
||||
@ -7859,10 +7863,13 @@ var
|
||||
end;
|
||||
|
||||
begin
|
||||
if not SelAvail then exit;
|
||||
|
||||
BB := BlockBegin;
|
||||
BE := BlockEnd;
|
||||
if not SelAvail then begin
|
||||
BB := CaretXY;
|
||||
BE := CaretXY;
|
||||
end else begin
|
||||
BB := BlockBegin;
|
||||
BE := BlockEnd;
|
||||
end;
|
||||
// convert selection to complete lines
|
||||
if BE.X = 1 then
|
||||
e := BE.y - 1
|
||||
|
Loading…
Reference in New Issue
Block a user