From 73ad1efc4745e8860ce6282e82d9ad66037ce32a Mon Sep 17 00:00:00 2001 From: Alex Prabhat Bara <50404684+alexprabhat99@users.noreply.github.com> Date: Wed, 10 Apr 2024 22:48:22 +0530 Subject: [PATCH] Fix CSS more indentation bug Fix #14962, close #14968 --- PowerEditor/src/Notepad_plus.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PowerEditor/src/Notepad_plus.cpp b/PowerEditor/src/Notepad_plus.cpp index 89329fd75..31a0081a8 100644 --- a/PowerEditor/src/Notepad_plus.cpp +++ b/PowerEditor/src/Notepad_plus.cpp @@ -3640,7 +3640,7 @@ void Notepad_plus::maintainIndentation(TCHAR ch) auto startPos = _pEditView->execute(SCI_POSITIONFROMLINE, curLine); LRESULT endPos = _pEditView->execute(SCI_GETCURRENTPOS); - for (LRESULT i = endPos - 2; i > 0 && i > startPos; --i) + for (LRESULT i = endPos - 2; i > 0 && i >= startPos; --i) { UCHAR aChar = (UCHAR)_pEditView->execute(SCI_GETCHARAT, i); if (aChar != ' ' && aChar != '\t')