From 58e30315101bd56dcb1a28e549cb41cc1ba9f74b Mon Sep 17 00:00:00 2001 From: WerWolv Date: Tue, 19 Oct 2021 12:48:44 +0200 Subject: [PATCH] ui: Fixed cursor being positioned weirdly when deleting a tab in the source editor --- external/ImGui/source/TextEditor.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/external/ImGui/source/TextEditor.cpp b/external/ImGui/source/TextEditor.cpp index 8e0ce860d..a4fd0eeef 100644 --- a/external/ImGui/source/TextEditor.cpp +++ b/external/ImGui/source/TextEditor.cpp @@ -1872,7 +1872,7 @@ void TextEditor::Backspace() u.mRemovedStart = u.mRemovedEnd = GetActualCursorCoordinates(); --u.mRemovedStart.mColumn; - --mState.mCursorPosition.mColumn; + mState.mCursorPosition.mColumn = GetCharacterColumn(mState.mCursorPosition.mLine, cindex); while (cindex < line.size() && cend-- > cindex) {