diff options
author | Warwick Allison <warwick.allison@nokia.com> | 2010-07-07 04:09:49 (GMT) |
---|---|---|
committer | Jason McDonald <jason.mcdonald@nokia.com> | 2010-07-13 05:19:34 (GMT) |
commit | 32d49340b973b7b4504514a8392d1f631ba248dc (patch) | |
tree | 8371a18e28ec9fb63276032003e69eed76c4bbdd /tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp | |
parent | 30afdcfb0eb5c926de434dc65076a97c87ac8d5d (diff) | |
download | Qt-32d49340b973b7b4504514a8392d1f631ba248dc.zip Qt-32d49340b973b7b4504514a8392d1f631ba248dc.tar.gz Qt-32d49340b973b7b4504514a8392d1f631ba248dc.tar.bz2 |
Make Text, TextInput, and TextEdit all have the same size for the same text.
This may mean that the cursor is to the right of the width, so components should
cater for that with a margin if they are boxed / clipped.
TextInput used to try to account for right bearing (and left bearing incorrectly since
it added it on the right). This is removed. Potentially this means that for some fonts
the text repaints incorrectly on the left or right, but if that is the case Text and TextEdit
already had such a problem (undetected), and all will need fixing.
Task-number: QTBUG-11983
(cherry picked from commit 628159323c60c434a202b036ecbaf5e433c703e8)
Diffstat (limited to 'tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp')
-rw-r--r-- | tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp index a032071..05dc50b 100644 --- a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp +++ b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp @@ -159,7 +159,7 @@ void tst_qdeclarativetextinput::width() QDeclarativeTextInput *textinputObject = qobject_cast<QDeclarativeTextInput*>(textinputComponent.create()); QVERIFY(textinputObject != 0); - QCOMPARE(textinputObject->width(), 1.); // 1 for the cursor + QCOMPARE(textinputObject->width(), 0.0); delete textinputObject; } |