summaryrefslogtreecommitdiffstats
path: root/src/declarative/util
diff options
context:
space:
mode:
authorBea Lam <bea.lam@nokia.com>2010-11-04 06:05:30 (GMT)
committerBea Lam <bea.lam@nokia.com>2010-11-04 06:06:25 (GMT)
commiteedb9980c89e77e21e1336195930a148b6a2e712 (patch)
tree863d51fef79d39c1bcd905790d3b208334c110ee /src/declarative/util
parentb5588ded342ed9dbc9f00fc8a4091e447880eccc (diff)
downloadQt-eedb9980c89e77e21e1336195930a148b6a2e712.zip
Qt-eedb9980c89e77e21e1336195930a148b6a2e712.tar.gz
Qt-eedb9980c89e77e21e1336195930a148b6a2e712.tar.bz2
Fix errors in example code. Also reverts the example code to the old
list format. Task-number: QTBUG-14871
Diffstat (limited to 'src/declarative/util')
-rw-r--r--src/declarative/util/qdeclarativefontloader.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/declarative/util/qdeclarativefontloader.cpp b/src/declarative/util/qdeclarativefontloader.cpp
index 9fee257..03a0561 100644
--- a/src/declarative/util/qdeclarativefontloader.cpp
+++ b/src/declarative/util/qdeclarativefontloader.cpp
@@ -297,23 +297,25 @@ void QDeclarativeFontLoader::setName(const QString &name)
Use this status to provide an update or respond to the status change in some way.
For example, you could:
- \e {Trigger a state change:}
- \qml
- State { name: 'loaded'; when: loader.status = FontLoader.Ready }
+ \list
+ \o Trigger a state change:
+ \qml
+ State { name: 'loaded'; when: loader.status == FontLoader.Ready }
\endqml
- \e {Implement an \c onStatusChanged signal handler:}
- \qml
+ \o Implement an \c onStatusChanged signal handler:
+ \qml
FontLoader {
id: loader
onStatusChanged: if (loader.status == FontLoader.Ready) console.log('Loaded')
}
\endqml
- \e {Bind to the status value:}
+ \o Bind to the status value:
\qml
- Text { text: loader.status != FontLoader.Ready ? 'Not Loaded' : 'Loaded' }
+ Text { text: loader.status == FontLoader.Ready ? 'Loaded' : 'Not loaded' }
\endqml
+ \endlist
*/
QDeclarativeFontLoader::Status QDeclarativeFontLoader::status() const
{