mirror of https://gitlab.com/basile.b/dexed.git
fix, comment block, wrong indentation when the block included a empty lines
This commit is contained in:
parent
a249081860
commit
e3c655eca3
|
@ -869,7 +869,7 @@ begin
|
||||||
lx += editor.TabWidth
|
lx += editor.TabWidth
|
||||||
else
|
else
|
||||||
lx += 1;
|
lx += 1;
|
||||||
if lx + 1 < pt.X then
|
if (lx + 1 < pt.X) and not line.isEmpty then
|
||||||
pt.X:= lx + 1;
|
pt.X:= lx + 1;
|
||||||
if (line.length > 1) and (line[1..2] = '//') then
|
if (line.length > 1) and (line[1..2] = '//') then
|
||||||
numUndo += 1;
|
numUndo += 1;
|
||||||
|
@ -883,6 +883,8 @@ begin
|
||||||
begin
|
begin
|
||||||
pt.Y:= i;
|
pt.Y:= i;
|
||||||
editor.ExecuteCommand(ecGotoXY, '', @pt);
|
editor.ExecuteCommand(ecGotoXY, '', @pt);
|
||||||
|
while editor.CaretX < pt.X do
|
||||||
|
editor.ExecuteCommand(ecChar, ' ', nil);
|
||||||
if not undo then
|
if not undo then
|
||||||
begin
|
begin
|
||||||
commentHere;
|
commentHere;
|
||||||
|
|
Loading…
Reference in New Issue