From 47847bebcacef2bbf3b5627ca18966d7d34d6762 Mon Sep 17 00:00:00 2001 From: Eskil Abrahamsen Blomfeldt Date: Fri, 11 Nov 2016 10:22:33 +0100 Subject: Fix flow text objects in beginning of RTL block If the block is right-to-left and starts with a text object, it should be aligned to the right edge of the QTextLine instead of the left one. [ChangeLog][QtQuick][Text] Fixed placement of flowing text objects in the start of a right-to-left block. Task-number: QTBUG-43133 Change-Id: Id790e88f3464280f124c38b4260386b84cac8826 Reviewed-by: Lars Knoll --- .../data/text/text_flow_image_start_ltr.qml | 14 ++++++++++++++ .../data/text/text_flow_image_start_rtl.qml | 14 ++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_ltr.qml create mode 100644 tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_rtl.qml (limited to 'tests/manual') diff --git a/tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_ltr.qml b/tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_ltr.qml new file mode 100644 index 0000000000..b8f0458818 --- /dev/null +++ b/tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_ltr.qml @@ -0,0 +1,14 @@ +import QtQuick 2.0 + +Item { + width: 320 + height: 480 + + Text { + anchors.centerIn: parent + font.family: "Arial" + font.pixelSize: 16 + textFormat: Text.RichText + text: "This image is in the start of the text" + } +} diff --git a/tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_rtl.qml b/tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_rtl.qml new file mode 100644 index 0000000000..e5bea08e62 --- /dev/null +++ b/tests/manual/scenegraph_lancelot/data/text/text_flow_image_start_rtl.qml @@ -0,0 +1,14 @@ +import QtQuick 2.0 + +Item { + width: 320 + height: 480 + + Text { + anchors.centerIn: parent + font.family: "Arial" + font.pixelSize: 16 + textFormat: Text.RichText + text: "هو أمّا حكومة" + } +} -- cgit v1.2.3