diff options
Diffstat (limited to 'tests/auto/quick/qquicktext/data/elideZeroWidth.qml')
-rw-r--r-- | tests/auto/quick/qquicktext/data/elideZeroWidth.qml | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/auto/quick/qquicktext/data/elideZeroWidth.qml b/tests/auto/quick/qquicktext/data/elideZeroWidth.qml new file mode 100644 index 0000000000..1193909350 --- /dev/null +++ b/tests/auto/quick/qquicktext/data/elideZeroWidth.qml @@ -0,0 +1,23 @@ +import QtQuick 2.15 + +Item { + id: root + property bool ok: false + width: 640 + height: 480 + + Text { + id: text + text: "This is a quite long text. Click me and i should remain visible!!! Sadly this doesn't happen" + elide: Text.ElideRight + } + + Component.onCompleted: { + text.width = 300; + text.height = 0; + text.width = 0; + text.height = 30; + text.width = 300; + root.ok = text.paintedWidth > 0 && text.paintedHeight > 0 + } +} |