diff options
author | Mitch Curtis <mitch.curtis@qt.io> | 2019-10-04 10:26:06 +0200 |
---|---|---|
committer | Mitch Curtis <mitch.curtis@qt.io> | 2019-10-04 13:42:43 +0000 |
commit | 1306951b9bcf8bda1610646726b7eb114c69454f (patch) | |
tree | e1731cf57068c64daebba7dd09eab148bd3b6f09 | |
parent | 4e669683277e9772d023287afd169c153b28ce84 (diff) |
Add a creation benchmark for right-elided Text
Task-number: QTBUG-76229
Change-Id: I0c6d4c576075c9677af19c89756953cf21456f75
Reviewed-by: Michael Brasser <michael.brasser@live.com>
-rw-r--r-- | benchmarks/auto/creation/quick.text/delegates_text_elide.qml | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/benchmarks/auto/creation/quick.text/delegates_text_elide.qml b/benchmarks/auto/creation/quick.text/delegates_text_elide.qml new file mode 100644 index 0000000..a0743eb --- /dev/null +++ b/benchmarks/auto/creation/quick.text/delegates_text_elide.qml @@ -0,0 +1,17 @@ +import QtQuick 2.0 +import QmlBench 1.0 + +// Tests the creation of Text with a long string of text that is elided on the right +CreationBenchmark { + id: root + count: 50 + staticCount: 1000 + delegate: Text { + x: QmlBench.getRandom() * (root.width - width) + y: QmlBench.getRandom() * (root.height - height) + width: 40 + text: "Some very very very long text" + font.pixelSize: 10 + elide: Text.ElideRight + } +} |