diff options
author | Martin Smith <martin.smith@nokia.com> | 2010-07-13 09:33:02 (GMT) |
---|---|---|
committer | Martin Smith <martin.smith@nokia.com> | 2010-07-13 09:33:02 (GMT) |
commit | e305732c0df93332a514a957b08e0ce283cb747f (patch) | |
tree | 603522227e5d4e9f2994408afd5d5523951ba648 /doc | |
parent | c93c9bbfe94cd271aeda9e2730d343e3eee31ec5 (diff) | |
parent | a296749eaea94ae4ed36086b632d32c87d3d99c9 (diff) | |
download | Qt-e305732c0df93332a514a957b08e0ce283cb747f.zip Qt-e305732c0df93332a514a957b08e0ce283cb747f.tar.gz Qt-e305732c0df93332a514a957b08e0ce283cb747f.tar.bz2 |
Fixing merge conflicts.
Merge branch '4.7-upstream' into 4.7
Conflicts:
doc/src/declarative/advtutorial.qdoc
src/declarative/graphicsitems/qdeclarativeloader.cpp
src/declarative/graphicsitems/qdeclarativetextedit.cpp
src/declarative/qml/qdeclarativeengine.cpp
src/declarative/util/qdeclarativexmllistmodel.cpp
Diffstat (limited to 'doc')
23 files changed, 173 insertions, 94 deletions
diff --git a/doc/src/declarative/advtutorial.qdoc b/doc/src/declarative/advtutorial.qdoc index 740f6f9..1341bbb 100644 --- a/doc/src/declarative/advtutorial.qdoc +++ b/doc/src/declarative/advtutorial.qdoc @@ -314,18 +314,17 @@ In anticipation of the new block animations, \c Block.qml file is now renamed to \section3 Animating block movement First we will animate the blocks so that they move in a fluid manner. QML has a number of methods for adding fluid -movement, and in this case we're going to use the \l SpringFollow element to add an animation with a spring-like -movement. In \c BoomBlock.qml, we apply a \l SpringFollow -to the \c x and \c y properties so that the block will follow and animate its movement towards the -position specified by the new \c targetX and \c targetY properties (whose values will be set by \c samegame.js). -Here is the code added to \c BoomBlock.qml: +movement, and in this case we're going to use the \l Behavior element to add a \l SpringAnimation. +In \c BoomBlock.qml, we apply a \l SpringAnimation behavior to the \c x and \c y properties so that the +block will follow and animate its movement in a spring-like fashion towards the specified position (whose +values will be set by \c samegame.js).Here is the code added to \c BoomBlock.qml: \snippet declarative/tutorials/samegame/samegame4/content/BoomBlock.qml 1 The \c spring and \c damping values can be changed to modify the spring-like effect of the animation. The \c {enabled: spawned} setting refers to the \c spawned value that is set from \c createBlock() in \c samegame.js. -This ensures the \l SpringFollow on the \c x is only enabled after \c createBlock() has set the block to +This ensures the \l SpringAnimation on the \c x is only enabled after \c createBlock() has set the block to the correct position. Otherwise, the blocks will slide out of the corner (0,0) when a game begins, instead of falling from the top in rows. (Try commenting out \c {enabled: spawned} and see for yourself.) diff --git a/doc/src/declarative/basictypes.qdoc b/doc/src/declarative/basictypes.qdoc index 159f40d..109e6d5 100644 --- a/doc/src/declarative/basictypes.qdoc +++ b/doc/src/declarative/basictypes.qdoc @@ -400,3 +400,26 @@ \sa {QML Basic Types} */ + +/*! + \qmlbasictype enumeration + \ingroup qmlbasictypes + + \brief An enumeration type consists of a set of named values. + + An enumeration type consists of a set of named values. + + An enumeration value may be specifed as either a string: + \qml + Text { horizontalAlignment: "AlignRight" } + \endqml + + or as \c {<Element>.<value>}: + \qml + Text { horizontalAlignment: Text.AlignRight } + \endqml + + The second form is preferred. + + \sa {QML Basic Types} +*/ diff --git a/doc/src/declarative/declarativeui.qdoc b/doc/src/declarative/declarativeui.qdoc index 4235c27..cd27c40 100644 --- a/doc/src/declarative/declarativeui.qdoc +++ b/doc/src/declarative/declarativeui.qdoc @@ -74,15 +74,15 @@ application or to build completely new applications. QML is fully \l \list \o \l {QML Documents} \o \l {Property Binding} -\o \l {Integrating JavaScript} -\o \l {QML Scope} \o \l {Network Transparency} +\o \l {QML Scope} +\o \l {Integrating JavaScript} \o \l {Data Models} \o \l {anchor-layout.html}{Anchor-based Layout} \o \l {qdeclarativestates.html}{States} \o \l {qdeclarativeanimation.html}{Animation} -\o \l {qdeclarativemodules.html}{Modules} \o \l {qdeclarativefocus.html}{Keyboard Focus} +\o \l {qdeclarativemodules.html}{Modules} \o \l {Extending types from QML} \o \l {qdeclarativedynamicobjects.html}{Dynamic Object Creation} \o \l {qmlruntime.html}{The Qt Declarative Runtime} @@ -90,10 +90,10 @@ application or to build completely new applications. QML is fully \l \section1 Using QML with C++ \list -\o \l {Tutorial: Writing QML extensions with C++} -\o \l {Extending QML in C++} \o \l {Using QML in C++ Applications} \o \l {Integrating QML with existing Qt UI code} +\o \l {Tutorial: Writing QML extensions with C++} +\o \l {Extending QML in C++} \endlist \section1 Reference diff --git a/doc/src/declarative/elements.qdoc b/doc/src/declarative/elements.qdoc index 349a8ed..c2930b3 100644 --- a/doc/src/declarative/elements.qdoc +++ b/doc/src/declarative/elements.qdoc @@ -76,11 +76,10 @@ The following table lists the QML elements provided by the \l {QtDeclarative}{Qt \row \o \l {AnchorAnimation} \o Animates anchor changes \row \o \l {PauseAnimation} \o Pauses an animation \row \o \l {SmoothedAnimation} \o Allows a property to smoothly track a value +\row \o \l {SpringAnimation} \o Allows a property to track a value in a spring-like motion \row \o \l {PropertyAction} \o Sets immediate property changes during animation \row \o \l {ScriptAction} \o Runs scripts during an animation \row \o \l {Transition} \o Animates transitions during state changes -\row \o \l {SpringFollow} \o Allows a property to follow value changes -\row \o \l {SmoothedFollow} \o Allows animation to smoothly follow value changes \header \o {2,1} \bold {Working with Data} \row \o \l {Binding} \o Binds any value to any property diff --git a/doc/src/declarative/examples.qdoc b/doc/src/declarative/examples.qdoc index 587cdf2..8a24228 100644 --- a/doc/src/declarative/examples.qdoc +++ b/doc/src/declarative/examples.qdoc @@ -36,11 +36,18 @@ Qt includes a set of examples and demos that show how to use various aspects of QML. The examples are small demonstrations of particular QML components, while the demos contain more complete and functional applications. -To run the examples and demos, you can use Qt Creator or the included \l {Qt Declarative UI Runtime}{qmlviewer} -command-line application. For example, from your build directory, run: +To run the examples and demos, open them in Qt Creator or use the included +\l {QML Viewer} tool. The \l {QML Viewer} can be run from the command line: \code - bin/qmlviewer $QTDIR/demos/declarative/samegame/samegame.qml + qmlviewer $QTDIR/demos/declarative/samegame/samegame.qml +\endcode + +On Mac OS X, you can run the included "QMLViewer" application from the +Finder, or use the command line: + +\code + QMLViewer.app/Contents/MacOS/QMLViewer $QTDIR/demos/declarative/samegame/samegame.qml \endcode diff --git a/doc/src/declarative/extending-tutorial.qdoc b/doc/src/declarative/extending-tutorial.qdoc index 0cb3a7d..2cf00b9 100644 --- a/doc/src/declarative/extending-tutorial.qdoc +++ b/doc/src/declarative/extending-tutorial.qdoc @@ -116,9 +116,9 @@ Now we can build and run the application. Try it yourself with the code in Qt's \example declarative/tutorials/extending/chapter1-basics At the moment, the \c app.qml is run from within a C++ application. -This may seem odd if you're used to running QML files with the standard \c qml tool. +This may seem odd if you're used to running QML files with the \l {QML Viewer}. Later on, we'll show how to create a plugin so that you can run \c app.qml using the -\c qml tool instead. +\l {QML Viewer} instead. */ @@ -301,8 +301,8 @@ Try it out with the code in Qt's \c examples/tutorials/extending/chapter4-custom Currently the \c Musician and \c Instrument types are used by \c app.qml, which is displayed using a QDeclarativeView in a C++ application. An alternative way to use our QML extension is to create a plugin library to make it available -to the QML engine. This means we could load \c app.qml using the standard \c qml tool -(or some other QML runtime application) instead of writing a \c main.cpp file and +to the QML engine. This means we could load \c app.qml using the \l {QML Viewer} +(or some other QML \l{Qt Declarative UI Runtime}{runtime} application) instead of writing a \c main.cpp file and loading our own C++ application. To create a plugin library, we need: @@ -337,12 +337,14 @@ of the example project) can be found in the "lib" subdirectory: \quotefile declarative/tutorials/extending/chapter5-plugins/qmldir Now we have a plugin, and instead of having a main.cpp and an executable, we can build -the project and then run the QML file directly using the \c qml tool: +the project and then load the QML file in the \l {QML Viewer}: \code - qml app.qml + qmlviewer app.qml \endcode +(On Mac OS X, you can launch the "QMLViewer" application instead.) + Notice the "import Music 1.0" statement has disappeared from \c app.qml. This is because the \c qmldir file is in the same directory as \c app.qml: this is equivalent to having Musician.qml and Instrument.qml files inside the project directory, which could both diff --git a/doc/src/declarative/extending.qdoc b/doc/src/declarative/extending.qdoc index 2fd6fa8..3acfbdf 100644 --- a/doc/src/declarative/extending.qdoc +++ b/doc/src/declarative/extending.qdoc @@ -704,10 +704,6 @@ of some of the types. For the remaining types the default values are undefined. \row \o color \o #000000 (black) \endtable -If specified, the optional "default" attribute marks the new property as the -types default property, overriding any existing default property. Using the -default attribute twice in the same type block is an error. - The following example shows how to declare a new "innerColor" property that controls the color of the inner rectangle. @@ -725,6 +721,9 @@ controls the color of the inner rectangle. } \endcode + +\section3 Property signal handlers + Adding a property to an item automatically adds a \e{value-changed} signal handler to the item. The signal hander is named \c{on<Property_name>Changed}, with the first letter of the property @@ -743,6 +742,42 @@ example shows how to output to a text console a new value of property } \endcode + +\section3 Setting default properties + +The optional \c default attribute for a property marks it as the \e {default property} +for a type. This allows other items to specify the default property's value +as child elements. For example, the \l Item element's default property is its +\l{Item::children}{children} property. This allows the children of an \l Item +to be set like this: + +\qml +Item { + Rectangle {} + Rectangle {} +} +\endqml + +If the \l{Item::children}{children} property was not the default property for +\l Item, its value would have to be set like this instead: + +\qml +Item { + children: [ + Rectangle {} + Rectangle {} + ] +} +\endqml + +See the \l{declarative/ui-components/tabwidget}{TabWidget} example for a +demonstration of using default properties. + +Specifying a default property overrides any existing default property (for +example, any default property inherited from a parent item). Using the +default attribute twice in the same type block is an error. + + \target qml-property-aliases \section2 Property aliases diff --git a/doc/src/declarative/focus.qdoc b/doc/src/declarative/focus.qdoc index cc546c0..0dd5eb3 100644 --- a/doc/src/declarative/focus.qdoc +++ b/doc/src/declarative/focus.qdoc @@ -87,7 +87,7 @@ Text { An \l Item requests focus by setting the \c {Item::focus} property to true. For very simple cases simply setting the \c {Item::focus} property is sometimes -sufficient. If we run the following example with the \l {Qt Declarative UI Runtime}{qml} tool, we see that +sufficient. If we run the following example with the \l {QML Viewer}, we see that the \c {keyHandler} element has \e {active focus} and pressing the 'A', 'B' or 'C' keys modifies the text appropriately. diff --git a/doc/src/declarative/globalobject.qdoc b/doc/src/declarative/globalobject.qdoc index 36d91ec..a9aee2f 100644 --- a/doc/src/declarative/globalobject.qdoc +++ b/doc/src/declarative/globalobject.qdoc @@ -35,7 +35,7 @@ Contains all the properties of the JavaScript global object, plus: \section1 Qt Object -The \l{Qt}{Qt object} provides useful enums and functions from Qt, for use in all QML +The \l{QmlGlobalQtObject}{Qt object} provides useful enums and functions from Qt, for use in all QML files. \section1 XMLHttpRequest diff --git a/doc/src/declarative/modules.qdoc b/doc/src/declarative/modules.qdoc index 02a2f5f..938222a 100644 --- a/doc/src/declarative/modules.qdoc +++ b/doc/src/declarative/modules.qdoc @@ -72,7 +72,7 @@ The second exception is explained in more detail in the section below on Namespa \section2 The Import Path Installed modules are searched for on the import path. -The \c -I option to the \l {Qt Declarative UI Runtime}{qml} runtime adds paths to the import path. +The \c -I option to the \l {QML Viewer} adds paths to the import path. From C++, the path is available via \l QDeclarativeEngine::importPathList() and can be prepended to using \l QDeclarativeEngine::addImportPath(). @@ -103,9 +103,16 @@ the \c qmldir file. Types which you do not wish to export to users of your modul may be marked with the \c internal keyword: \c internal <TypeName> <File>. The same type can be provided by different files in different versions, in which -case later earlier versions (eg. 1.2) must precede earlier versions (eg. 1.0), +case later versions (eg. 1.2) must precede earlier versions (eg. 1.0), since the \e first name-version match is used and a request for a version of a type -can be fulfilled by one defined in an earlier version of the module. +can be fulfilled by one defined in an earlier version of the module. If a user attempts +to import a version earlier than the earliest provided or later than the latest provided, +an error results, but if the user imports a version within the range of versions provided, +even if no type is specific to that version, no error results. + +A single module, in all versions, may only be provided in a single directory (and a single \c qmldir file). +If multiple are provided, only the first in the search path will be used (regardless of whether other versions +are provided by directories later in the search path). Installed and remote files without a namespace \e must be referred to by version information described above, local files \e may have it. @@ -122,7 +129,7 @@ to the module. of the plugin binary, which is platform dependent; e.g. the library MyAppTypes would produce a libMyAppTypes.so on Linux and MyAppTypes.dll on Windows. By default the engine searches for the plugin library in the directory containing the \c qmldir -file. The \c -P option to the \l {Qt Declarative UI Runtime}{qml} runtime adds paths to the +file. The \c -P option to the \l {QML Viewer} adds paths to the plugin search path. From C++, the path is available via \l QDeclarativeEngine::pluginPathList() and can be prepended to using \l QDeclarativeEngine::addPluginPath(). diff --git a/doc/src/declarative/network.qdoc b/doc/src/declarative/network.qdoc index b0d19e2..60359de 100644 --- a/doc/src/declarative/network.qdoc +++ b/doc/src/declarative/network.qdoc @@ -54,7 +54,7 @@ Network transparency is supported throughout QML, for example: \o WebViews - the \c url property of WebView (obviously!) \endlist -Even QML types themselves can be on the network - if the \l {Qt Declarative UI Runtime}{qml} tool is used to load +Even QML types themselves can be on the network - if the \l {QML Viewer} is used to load \tt http://example.com/mystuff/Hello.qml and that content refers to a type "World", the engine will load \tt http://example.com/mystuff/qmldir and resolve the type just as it would for a local file. For example if the qmldir file contains the line "World World.qml", it will load @@ -119,7 +119,7 @@ All network access from QML is managed by a QNetworkAccessManager set on the QDe By default, this is an unmodified Qt QNetworkAccessManager. You may set a different manager by providing a QDeclarativeNetworkAccessManagerFactory and setting it via QDeclarativeEngine::setNetworkAccessManagerFactory(). -For example, the \l {Qt Declarative UI Runtime}{qml} tool sets a QDeclarativeNetworkAccessManagerFactory which +For example, the \l {QML Viewer} sets a QDeclarativeNetworkAccessManagerFactory which creates QNetworkAccessManager that trusts HTTP Expiry headers to avoid network cache checks, allows HTTP Pipelining, adds a persistent HTTP CookieJar, a simple disk cache, and supports proxy settings. diff --git a/doc/src/declarative/pics/imageprovider.png b/doc/src/declarative/pics/imageprovider.png Binary files differnew file mode 100644 index 0000000..422103c --- /dev/null +++ b/doc/src/declarative/pics/imageprovider.png diff --git a/doc/src/declarative/qdeclarativedebugging.qdoc b/doc/src/declarative/qdeclarativedebugging.qdoc index da6e407..ea21852 100644 --- a/doc/src/declarative/qdeclarativedebugging.qdoc +++ b/doc/src/declarative/qdeclarativedebugging.qdoc @@ -47,7 +47,7 @@ Rectangle { When a transition doesn't look quite right, it can be helpful to view it in slow motion to see what is happening more clearly. This functionality is supported -in the \l {Qt Declarative UI Runtime}{qmlviewer} tool: to enable this, +in the \l {QML Viewer} tool: to enable this, click on the "Debugging" menu, then "Slow Down Animations". @@ -64,7 +64,7 @@ import Qt 4.7 Rectangle { width: 100; height: 100 } \endqml -If you set \c {QML_IMPORT_TRACE=1} before running the \l {Qt Declarative UI Runtime}{qmlviewer} +If you set \c {QML_IMPORT_TRACE=1} before running the \l {QML Viewer} (or your QML C++ application), you will see output similar to this: \code @@ -85,11 +85,11 @@ show QML debugging information and options for your application, including object inspection, property monitoring and application frame-rate analysis. Creator can be used to debug both local and remote QML applications. To -enable remote debugging, start the \l {Qt Declarative UI Runtime}{qml} tool +enable remote debugging, start the \l {QML Viewer} on the remote device with a debugging port defined, like this: \code - QML_DEBUG_SERVER_PORT=3768 qml myqmlfile.qml + QML_DEBUG_SERVER_PORT=3768 qmlviewer myqmlfile.qml \endcode In Creator, open the project settings pane and set the server and port diff --git a/doc/src/declarative/qdeclarativei18n.qdoc b/doc/src/declarative/qdeclarativei18n.qdoc index 40f7919..b6e6c6e 100644 --- a/doc/src/declarative/qdeclarativei18n.qdoc +++ b/doc/src/declarative/qdeclarativei18n.qdoc @@ -49,7 +49,7 @@ capabilities are described more fully in: \o \l {Qt Linguist Manual} \endlist -You can test a translation with the \l {Qt Declarative UI Runtime}{qml} tool using the -translation option. +You can test a translation with the \l {QML Viewer} using the -translation option. \section1 Example @@ -61,8 +61,8 @@ hello.qml: import Qt 4.7 Rectangle { - width: 200; height: 200 - Text { text: qsTr("Hello"); anchors.centerIn: parent } + width: 200; height: 200 + Text { text: qsTr("Hello"); anchors.centerIn: parent } } \endqml @@ -76,7 +76,7 @@ a translation and create the release file \c hello.qm. Finally, we can test the translation: \code -qml -translation hello.qm hello.qml +qmlviewer -translation hello.qm hello.qml \endcode 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. diff --git a/doc/src/declarative/qmlviewer.qdoc b/doc/src/declarative/qmlviewer.qdoc index efff9cc..5efc0ce 100644 --- a/doc/src/declarative/qmlviewer.qdoc +++ b/doc/src/declarative/qmlviewer.qdoc @@ -42,7 +42,7 @@ deployment of QML applications. In those cases, the QML runtime should be invoke from a Qt application instead; see \l {Qt Declarative UI Runtime} for more information. -The viewer is located at QTDIR/bin/qmlviewer. To load a \c .qml file +The viewer is located at \c QTDIR/bin/qmlviewer. To load a \c .qml file with the viewer, run the viewer and select the file to be opened, or provide the file path on the command line: @@ -50,7 +50,7 @@ file path on the command line: qmlviewer myqmlfile.qml \endcode -On Mac OS X, the QML Viewer application is named \c QMLViewer.app instead. You +On Mac OS X, the QML Viewer application is named "QMLViewer" instead. You can launch the viewer by opening the QMLViewer application from the Finder, or from the command line: diff --git a/doc/src/declarative/tutorial.qdoc b/doc/src/declarative/tutorial.qdoc index c884486..7a97eb1 100644 --- a/doc/src/declarative/tutorial.qdoc +++ b/doc/src/declarative/tutorial.qdoc @@ -101,11 +101,11 @@ The \c font.pointSize and \c font.bold properties are related to fonts and use t \section2 Viewing the example -To view what you have created, run the \l{Qt Declarative UI Runtime}{qml} tool (located in the \c bin directory) with your filename as the first argument. +To view what you have created, run the \l{QML Viewer} tool (located in the \c bin directory) with your filename as the first argument. For example, to run the provided completed Tutorial 1 example from the install location, you would type: \code -bin/qml $QTDIR/examples/declarative/tutorials/helloworld/tutorial1.qml +bin/qmlviewer $QTDIR/examples/declarative/tutorials/helloworld/tutorial1.qml \endcode */ diff --git a/doc/src/examples/qml-examples.qdoc b/doc/src/examples/qml-examples.qdoc index c8a7403..ce53677 100644 --- a/doc/src/examples/qml-examples.qdoc +++ b/doc/src/examples/qml-examples.qdoc @@ -196,6 +196,9 @@ \o \l{declarative/cppextensions/qgraphicslayouts/qgraphicsgridlayout}{QGraphicsGridLayout} \o \l{declarative/cppextensions/qgraphicslayouts/qgraphicslinearlayout}{QGraphicsLinearLayout} \endlist + + Also see \l {Integrating QML with existing Qt UI code} for information on using QML + in Qt applications that use the Graphics View framework or ordinary QWidget-based views. */ /*! @@ -211,8 +214,10 @@ \title C++ Extensions: Image Provider \example declarative/cppextensions/imageprovider - This examples shows how to use QDeclarativeImageProvider to serve images asynchronously - into a QML item. + This examples shows how to use QDeclarativeImageProvider to serve images + to QML image elements. + + \image qml-imageprovider-example.png */ /*! @@ -472,7 +477,7 @@ This example displays a set of clocks with different times for different cities. Each clock is created by combining \l Image elements with \l Rotation transforms - and \l SpringFollow animations. + and \l SpringAnimation behaviors. \image qml-clocks-example.png */ @@ -512,7 +517,7 @@ \title Toys: TV Tennis \example declarative/toys/tvtennis - This example shows how to use animation components such as \l SpringFollow, + This example shows how to use animation components such as \l SpringAnimation, \l SequentialAnimation and \l PropertyAction to create a game of TV tennis. \image qml-tvtennis-example.png @@ -540,7 +545,7 @@ \example declarative/ui-components/dialcontrol This example shows how to create a dial-type control. It combines - \l Image elements with \l Rotation transforms and \l SpringFollow animations + \l Image elements with \l Rotation transforms and \l SpringAnimatino behaviors to produce an interactive speedometer-type dial. \image qml-dialcontrol-example.png @@ -608,7 +613,9 @@ \title UI Components: Tab Widget \example declarative/ui-components/tabwidget - This example shows how to create a tab widget. + This example shows how to create a tab widget. It also demonstrates how + \l {Setting default properties}{default properties} can be used to collect and + assemble the child items declared within an \l Item. \image qml-tabwidget-example.png */ diff --git a/doc/src/examples/qml-webbrowser.qdoc b/doc/src/examples/qml-webbrowser.qdoc index da6f600..a3cef66 100644 --- a/doc/src/examples/qml-webbrowser.qdoc +++ b/doc/src/examples/qml-webbrowser.qdoc @@ -6,41 +6,27 @@ ** ** This file is part of the documentation of the Qt Toolkit. ** -** $QT_BEGIN_LICENSE:LGPL$ -** No Commercial Usage -** This file contains pre-release code and may not be distributed. -** You may use this file in accordance with the terms and conditions -** contained in the Technology Preview License Agreement accompanying -** this package. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 2.1 requirements -** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** In addition, as a special exception, Nokia gives you certain additional -** rights. These rights are described in the Nokia Qt LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** $QT_BEGIN_LICENSE:FDL$ +** Commercial Usage +** Licensees holding valid Qt Commercial licenses may use this file in +** accordance with the Qt Commercial License Agreement provided with the +** Software or, alternatively, in accordance with the terms contained in a +** written agreement between you and Nokia. +** +** GNU Free Documentation License +** Alternatively, this file may be used under the terms of the GNU Free +** Documentation License version 1.3 as published by the Free Software +** Foundation and appearing in the file included in the packaging of this +** file. ** ** If you have questions regarding the use of this file, please contact ** Nokia at qt-info@nokia.com. -** -** -** -** -** -** -** -** ** $QT_END_LICENSE$ ** ****************************************************************************/ /*! - \title Web Browser + \title QML Web Browser \example demos/declarative/webbrowser This demo shows how to write a simple web browser in QML by combining the diff --git a/doc/src/external-resources.qdoc b/doc/src/external-resources.qdoc index cbd66ee..61c9da2 100644 --- a/doc/src/external-resources.qdoc +++ b/doc/src/external-resources.qdoc @@ -416,5 +416,5 @@ /*! \externalpage http://opensource.org/licenses/bsd-license.php - \title New and Modified BSD Licenses -*/
\ No newline at end of file + \title BSD License +*/ diff --git a/doc/src/images/qml-imageprovider-example.png b/doc/src/images/qml-imageprovider-example.png Binary files differnew file mode 100644 index 0000000..e82548a --- /dev/null +++ b/doc/src/images/qml-imageprovider-example.png diff --git a/doc/src/snippets/declarative/gridview/gridview.qml b/doc/src/snippets/declarative/gridview/gridview.qml index 7377cee..e92a429 100644 --- a/doc/src/snippets/declarative/gridview/gridview.qml +++ b/doc/src/snippets/declarative/gridview/gridview.qml @@ -108,8 +108,10 @@ Component { Rectangle { width: view.cellWidth; height: view.cellHeight color: "lightsteelblue"; radius: 5 - SpringFollow on x { to: view.currentItem.x; spring: 3; damping: 0.2 } - SpringFollow on y { to: view.currentItem.y; spring: 3; damping: 0.2 } + x: view.currentItem.x + y: view.currentItem.y + Behavior on x { SpringAnimation { spring: 3; damping: 0.2 } } + Behavior on y { SpringAnimation { spring: 3; damping: 0.2 } } } } diff --git a/doc/src/snippets/declarative/listview/listview.qml b/doc/src/snippets/declarative/listview/listview.qml index 0c6dfd4..cde820e 100644 --- a/doc/src/snippets/declarative/listview/listview.qml +++ b/doc/src/snippets/declarative/listview/listview.qml @@ -99,10 +99,12 @@ Component { Rectangle { width: 180; height: 40 color: "lightsteelblue"; radius: 5 - SpringFollow on y { - to: list.currentItem.y - spring: 3 - damping: 0.2 + y: list.currentItem.y + Behavior on y { + SpringAnimation { + spring: 3 + damping: 0.2 + } } } } |