aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquicktext.cpp
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@digia.com>2014-01-17 13:41:27 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-29 10:12:42 +0100
commitd2f21f427fa85ef7b2655b375b7a521a5c4b25c1 (patch)
tree29111f6467c33934c89c3780b665bc855903c352 /src/quick/items/qquicktext.cpp
parente13547c595913c58e6bd6a5ed80fdc729fae7d47 (diff)
Docs: add a working example to Text::fontSizeMode docs
It's easy to miss the maximum bound specified by either the font.pointSize or font.pixelSize properties. Task-number: QTBUG-30005 Change-Id: If1dadebd6673f0e945a1ca95b64521f27d30f5a9 Reviewed-by: Alan Alpert <aalpert@blackberry.com>
Diffstat (limited to 'src/quick/items/qquicktext.cpp')
-rw-r--r--src/quick/items/qquicktext.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/quick/items/qquicktext.cpp b/src/quick/items/qquicktext.cpp
index 038025856c..c9dee9a986 100644
--- a/src/quick/items/qquicktext.cpp
+++ b/src/quick/items/qquicktext.cpp
@@ -2345,6 +2345,10 @@ void QQuickText::setLineHeightMode(LineHeightMode mode)
minimumPointSize or minimumPixelSize property and maximum bound specified
by either the \l font.pointSize or \l font.pixelSize properties.
+ \qml
+ Text { text: "Hello"; fontSizeMode: Text.Fit; minimumPixelSize: 10; font.pixelSize: 72 }
+ \endqml
+
If the text does not fit within the item bounds with the minimum font size
the text will be elided as per the \l elide property.
*/