summaryrefslogtreecommitdiffstats
path: root/doc/src/declarative/qml-intro.qdoc
diff options
context:
space:
mode:
Diffstat (limited to 'doc/src/declarative/qml-intro.qdoc')
-rw-r--r--doc/src/declarative/qml-intro.qdoc24
1 files changed, 17 insertions, 7 deletions
diff --git a/doc/src/declarative/qml-intro.qdoc b/doc/src/declarative/qml-intro.qdoc
index ac79496..fbab001 100644
--- a/doc/src/declarative/qml-intro.qdoc
+++ b/doc/src/declarative/qml-intro.qdoc
@@ -105,9 +105,17 @@ This is a valid QML script. To run it, copy it and save it to a file, say
myexample.qml, and on the command line run the command
\code
- qml myexample.qml
+ qmlviewer myexample.qml
\endcode
+On Mac OS X, open the "QMLViewer" application instead and open the
+\c myexample.qml file, or run it from the command line:
+
+ \code
+ QMLViewer.app/Contents/MacOS/QMLViewer myexample.qml
+ \endcode
+
+
It will create a very boring rectangle in its own window.
@@ -915,16 +923,18 @@ the rotation of the needle image. Notice this piece of code in Dial where
the change in \c value modifies the position of the needle.
\code
- SpringFollow on angle {
- spring: 1.4
- damping: .15
- to: Math.min(Math.max(-130, root.value*2.6 - 130), 133)
+ angle: Math.min(Math.max(-130, root.value*2.6 - 130), 133)
+ Behavior on angle {
+ SpringAnimation {
+ spring: 1.4
+ damping: .15
+ }
}
\endcode
This is part of the \c needleRotation that rotates the needle and causes the
-rotation of its shadow. \l SpringFollow is an element that modifies the value
-of that rotation angle \e to and mimics the oscillatory behavior of a spring,
+rotation of its shadow. \l SpringAnimation is an element that modifies the value
+of that rotation \e angle and mimics the oscillatory behavior of a spring,
with the appropriate \e spring constant to control the acceleration and the \e
damping to control how quickly the effect dies away.