diff --git a/components/synedit/synbeautifier.pas b/components/synedit/synbeautifier.pas index eb0dd013cd..479767e635 100644 --- a/components/synedit/synbeautifier.pas +++ b/components/synedit/synbeautifier.pas @@ -146,6 +146,7 @@ type end; implementation +uses SynEdit; { TSynCustomBeautifier } @@ -220,6 +221,8 @@ begin if (Command = ecDeleteLastChar) and (FAutoIndent) and (ACaret.CharPos > 1) and + ( (not TSynEdit(FCurrentEditor).SelAvail) or + (eoPersistentBlock in TSynEdit(FCurrentEditor).Options2) ) and (GetCurrentIndent(FCurrentEditor, ACaret.LineText, True) = ACaret.CharPos - 1) then begin UnIndentLine(ACaret, x);