Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.12
Description
The TextInput has the issue that the text is extending over the border on the left side by one pixel and on the right side by at least 3 pixels. Even if the left and right padding are set, it is only showing when scrolling fully to the left or right.
import QtQuick 2.12 import QtQuick.Window 2.12 import QtQuick.Controls 2.12 Window { visible: true width: 640 height: 480 color: "#606060" TextInput { id: textInput anchors.centerIn: parent z: 2 width: 280 height: 60 horizontalAlignment: Qt.AlignHCenter verticalAlignment: Qt.AlignVCenter readOnly: false selectByMouse: false activeFocusOnPress: false clip: true font.pixelSize: 48 color: "white" text: "This is it!#" leftPadding: 40 rightPadding: 40 Rectangle { id: textInputArea color: "grey" border.color: "black" border.width: 1 x: 0 y: 0 z: -1 width: textInput.width height: textInput.height } TapHandler { id: tapHandler acceptedDevices: PointerDevice.Mouse enabled: true onTapped: textInput.forceActiveFocus() } } }
Attachments
Issue Links
- duplicates
-
QTBUG-37967 The text cursor is not clipped in TextInput control
- Closed
- relates to
-
QTBUG-75937 TextEdit: caret isn't clipped
- Closed
-
QTBUG-97648 TextField clipping breaks batching; so maybe avoid populating characters outside?
- Reported
-
QTBUG-35646 Setting clip property true on TextInput hides cursor on an empty input.
- Closed
- resulted from
-
QTBUG-29316 Text in TextInput is drawn behind the element
- Closed