Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexey-T committed Apr 26, 2023
1 parent 2712a42 commit 8560038
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
10 changes: 10 additions & 0 deletions atsynedit/atsynedit_cmd_editing.inc
Original file line number Diff line number Diff line change
Expand Up @@ -854,6 +854,16 @@ begin
bChange:= false;
St:= Strings;

//Sublime Text, VSCode: delete selection first
if Carets.IsSelection then
begin
Result:= DoCommand_TextDeleteSelection();
//deletion of block by BkSpace needs undo-group, CudaText issue #3971
St.BeginUndoGroup;
St.EndUndoGroup;
exit;
end;

//also make undo-group to fix CudaText issue #3971
St.BeginUndoGroup;
St.EndUndoGroup;
Expand Down
4 changes: 2 additions & 2 deletions atsynedit/atsynedit_commands.pas
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ interface
cCommand_TextDeleteToLineBegin = 173 or cCmdFlag_ResetSel;
cCommand_TextDeleteToLineEnd = 174 or cCmdFlag_ResetSel;
cCommand_TextDeleteToTextEnd = 175 or cCmdFlag_ResetSel;
cCommand_TextDeleteWordNext = 176 or cCmdFlag_ResetSel;
cCommand_TextDeleteWordPrev = 177 or cCmdFlag_ResetSel;
cCommand_TextDeleteWordNext = 176;
cCommand_TextDeleteWordPrev = 177;
cCommand_TextDeleteToTextBegin = 178 or cCmdFlag_ResetSel;
cCommand_TextDeleteWordEntire = 179 or cCmdFlag_ResetSel;

Expand Down

0 comments on commit 8560038

Please sign in to comment.