Jason H wrote:
>Text {
> id: instructionText
> color: "white"
> text: instructionTextData
> width: contentWidth > parent.width *.9 ? parent.width *.9 : contentWidth
> font.pointSize: 16
> horizontalAlignment: Text.AlignHCenter
> anchors.horizontalCenter: parent.horizontalCenter }
>
>Where I want the text to be it's natural width up to 90% of the parent width,
>then wrap, but it only works when initially laying out and shrinking.
I think I'm missing some use case, why bother setting the width to contentWidth?
You anyway center the Text element and the text inside it so nothing prevents
you from always setting it to parent.width *.9?
The text will then still be centered inside the Text element, and the Text
element centered in its parent.
-Even
_______________________________________________
Interest mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/interest