Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.11.2, 5.12.0 RC2, 6.1.2, 6.3.0 Beta2, 6.5.2, 6.6.0 Beta2
Description
Please compare the mouse text selection behaviour of a QtQuick TextEdit vs. a QtQuick Controls2 TextArea.
While TextEdit is ok, TextArea shows these problems:
- The Cursor position is changed on release not on press - this feels unnatural. TextEdit works as expected.
- Just press and move the mouse downwards. A text selection should be startet. But it isn't. A horizontal movement must be made before selection is started. Again TextEdit just works as expected.
- Sometimes selection doesn't start at all
import QtQuick 2.11 import QtQuick.Controls 2.4 import QtQuick.Window 2.11 ApplicationWindow { visible: true width: 640 height: 480 title: qsTr("Hello World") Rectangle { anchors.fill: ta1 color: "red" opacity: 0.2 } // Bad TextArea { id: ta1 height: 50 anchors { left: parent.left; right: parent.right } clip: true text: "Line 1: Hello Hello Hello\nLine 2: Hello Hello Hello\nLine 3: Hello Hello Hello" selectByMouse: true leftPadding: 0 rightPadding: 0 bottomPadding: 0 topPadding: 0 padding: 0 } Rectangle { anchors.fill: ta2 color: "green" opacity: 0.2 } // Good TextEdit { id: ta2 y: 50 height: 50 anchors { left: parent.left; right: parent.right } clip: true text: "Line 1: Hello Hello Hello\nLine 2: Hello Hello Hello\nLine 3: Hello Hello Hello" selectByMouse: true leftPadding: 0 rightPadding: 0 bottomPadding: 0 topPadding: 0 padding: 0 } }
Attachments
Issue Links
- is duplicated by
-
QTBUG-121461 Qml TextArea Selecting one character with the mouse on small and medium font sizes works very incorrectly
-
- Closed
-