From ffa4dca8b318d00d4514298eb21a4fb3cdcf146c Mon Sep 17 00:00:00 2001
From: SyldraTheCat <syldratube@gmail.com>
Date: Mon, 13 Jun 2022 07:22:09 +0000
Subject: [PATCH] Make cursoring up/down more consistent on some setups

---
 resources/qml/MessageInput.qml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/resources/qml/MessageInput.qml b/resources/qml/MessageInput.qml
index 76c498d92..8a5611dff 100644
--- a/resources/qml/MessageInput.qml
+++ b/resources/qml/MessageInput.qml
@@ -278,7 +278,7 @@ Rectangle {
                                 }
                                 idx++;
                             }
-                        } else if (positionAt(0, cursorRectangle.y) === 0) {
+                        } else if (positionAt(0, cursorRectangle.y + cursorRectangle.height / 2) === 0) {
                             event.accepted = true;
                             positionCursorAtStart();
                         }
@@ -295,7 +295,7 @@ Rectangle {
                                 }
                                 idx--;
                             }
-                        } else if (positionAt(width, cursorRectangle.y + 2) === messageInput.length) {
+                        } else if (positionAt(width, cursorRectangle.y + cursorRectangle.height / 2) === messageInput.length) {
                             event.accepted = true;
                             positionCursorAtEnd();
                         }
-- 
GitLab