aboutsummaryrefslogtreecommitdiffstats
path: root/tests/manual/scenegraph_lancelot/data
diff options
context:
space:
mode:
authorEirik Aavitsland <eirik.aavitsland@qt.io>2019-11-15 16:44:20 +0100
committerEirik Aavitsland <eirik.aavitsland@qt.io>2019-11-18 09:48:44 +0000
commitaf090d8073a4352f6a92bbe2d015ae87476684c7 (patch)
tree0ea1b145fce2fb700fa524fbce24ed43815a4c03 /tests/manual/scenegraph_lancelot/data
parent9b2af0c5f581797e0098494efa93365a2dc6d0bf (diff)
Fix: NativeRendering text for non-integer screen scaling
Commit 6e883c53 introduced snapping to pixel grid for non-integer device pixel ratios. But the snapping also modified the w element of the coord vector, which resulted in mangled and offset rendering. As a driveby, add the dpr snapping also to the outlinetext shader, as it improves rendering quality. Fixes: QTBUG-70481 Fixes: QTBUG-78160 Change-Id: I4c4b1788005514adc0255878ba24cdf1acc6755f Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Diffstat (limited to 'tests/manual/scenegraph_lancelot/data')
-rw-r--r--tests/manual/scenegraph_lancelot/data/text/text_style2.qml37
1 files changed, 37 insertions, 0 deletions
diff --git a/tests/manual/scenegraph_lancelot/data/text/text_style2.qml b/tests/manual/scenegraph_lancelot/data/text/text_style2.qml
new file mode 100644
index 0000000000..984ca6a1ed
--- /dev/null
+++ b/tests/manual/scenegraph_lancelot/data/text/text_style2.qml
@@ -0,0 +1,37 @@
+import QtQuick 2.0
+
+//vary font style
+
+Item {
+ width: 320
+ height: 480
+
+ Column {
+ anchors.fill: parent
+ Repeater {
+ model: [Text.Normal, Text.Outline, Text.Raised, Text.Sunken]
+ Text {
+ renderType: Text.QtRendering
+ width: parent.width
+ wrapMode: Text.Wrap
+ font.pointSize: 10
+ style: modelData
+ styleColor: "green"
+ text: "The quick fox jumps in style " + modelData
+ }
+ }
+
+ Repeater {
+ model: [Text.Normal, Text.Outline, Text.Raised, Text.Sunken]
+ Text {
+ renderType: Text.NativeRendering
+ width: parent.width
+ wrapMode: Text.Wrap
+ font.pointSize: 10
+ style: modelData
+ styleColor: "green"
+ text: "The quick fox jumps in style " + modelData
+ }
+ }
+ }
+}