Fixed first TAB at the very start of line missing first indent level by 1 character

This commit is contained in:
bigguy345 committed 2025-12-18 00:50:27 +02:00
1 parent 7a661df47d
commit e41ab8ad91
1 file changed
+2 -2
@@ -1184,7 +1184,7 @@ public class GuiScriptTextArea extends GuiNpcTextField {
private void handleTab() {
LineData currentLine = null;
for (LineData line : this.container.lines) {
if (this.cursorPosition >= line.start && this.cursorPosition <= line.end) {
if (this.cursorPosition >= line.start && this.cursorPosition < line.end) {
currentLine = line;
break;
}
@@ -1243,7 +1243,7 @@ public class GuiScriptTextArea extends GuiNpcTextField {
private void handleShiftTab() {
LineData currentLine = null;
for (LineData line : this.container.lines) {
if (this.cursorPosition >= line.start && this.cursorPosition <= line.end) {
if (this.cursorPosition >= line.start && this.cursorPosition < line.end) {
currentLine = line;
break;
}