aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquicktext/data/implicitSizeChangeRewrap.qml
blob: fb8626a75a53552e24e03820eb6b9df35f4d4814 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
import QtQuick 2.0
import QtQuick.Layouts 1.0

Item
{
  id : _rootItem
  width : 200
  height : 1000
        ColumnLayout
        {
            id : _textContainer
            anchors.centerIn: parent
            Layout.maximumWidth: (_rootItem.width - 40) // to have some space left / right
            Text
            {
                id : text
                objectName: "text"
                font.italic: true
                textFormat: Text.RichText
                horizontalAlignment :   Text.AlignHCenter
                verticalAlignment :     Text.AlignVCenter
                wrapMode: Text.Wrap
                Layout.maximumWidth: (_rootItem.width - 60)
                Component.onCompleted: text.text = "This is a too long text for the interface with a stupid path also too long -> /home/long/long/long/to/force/it/to/need/to/wrap This is a too long text for the interface with a stupid path also too long -> /home/long/long/long/to/force/it/to/need/to/wrap This is a too long text for the interface with a stupid path also too long -> /home/long/long/long/to/force/it/to/need/to/wrap This is a too long text for the interface with a stupid path also too long -> /home/long/long/long/to/force/it/to/need/to/wrap"
            }
    }
}