diff --git a/src/gui/Base/HTextArea.qml b/src/gui/Base/HTextArea.qml index 0d5d8704..6735fc40 100644 --- a/src/gui/Base/HTextArea.qml +++ b/src/gui/Base/HTextArea.qml @@ -20,7 +20,7 @@ TextArea { function reset() { clear(); text = defaultText } - function append(text) { insert(cursorPosition, text) } + function insertAtCursor(text) { insert(cursorPosition, text) } text: defaultText diff --git a/src/gui/Pages/Chat/Composer/MessageArea.qml b/src/gui/Pages/Chat/Composer/MessageArea.qml index 9156cdee..6755bc64 100644 --- a/src/gui/Pages/Chat/Composer/MessageArea.qml +++ b/src/gui/Pages/Chat/Composer/MessageArea.qml @@ -75,7 +75,7 @@ HTextArea { } const add = indent.repeat(indents) - textArea.append("\n" + add) + textArea.insertAtCursor("\n" + add) } function sendText() { @@ -176,7 +176,7 @@ HTextArea { Keys.onTabPressed: ev => { ev.accepted = true - textArea.append(indent) + textArea.insertAtCursor(indent) } Keys.onPressed: ev => {