Reorganise release notes for QtQml and QtQuick
authorBea Lam <bea.lam@nokia.com>
Tue, 26 Jun 2012 04:12:12 +0000 (14:12 +1000)
committerQt by Nokia <qt-info@nokia.com>
Wed, 27 Jun 2012 05:26:46 +0000 (07:26 +0200)
This separates the "what's new" docs into different pages
under qml/ and quick/ and reorganizes the content structure.

Change-Id: I8a9c437caec75178c44b89b40507ea50f1b8faff
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
src/qml/doc/src/qtqml.qdoc
src/qml/doc/src/whatsnew.qdoc [new file with mode: 0644]
src/quick/doc/src/qtquick.qdoc
src/quick/doc/src/whatsnew.qdoc

index e4cefc2..6e95e73 100644 (file)
@@ -186,6 +186,7 @@ Quick Links:
 \li \l{qtqml-module.html}{Qt QML Module C++ API Reference}
 \li \l{qtquick-main.html}{Qt Quick Module Documentation}
 \li \l{qtquick-applicationdevelopers.html}{QML Application Developer Resources}
+\li \l{qtqml-releasenotes.html}{QtQml Release Notes}
 \endlist
 
 */
diff --git a/src/qml/doc/src/whatsnew.qdoc b/src/qml/doc/src/whatsnew.qdoc
new file mode 100644 (file)
index 0000000..8640094
--- /dev/null
@@ -0,0 +1,86 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/
+**
+** This file is part of the documentation of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:FDL$
+** 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.
+**
+** Other Usage
+** Alternatively, this file may be used in accordance with the terms
+** and conditions contained in a signed written agreement between you
+** and Nokia.
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+/*!
+\title QtQml Module Release Notes
+\page qtqml-releasenotes.html
+\inqmlmodule QtQuick 2.0
+
+\section1 Qt 5.0
+
+The QtQml C++ module is new in Qt 5. It provides the QML engine and implements
+the QML language supporting infrastructure.
+
+(Prior to Qt 5, this functionality was provided by the QtDeclarative module, which
+has now been replaced by the new QtQml and QtQuick C++ modules.)
+
+\section2 QML Engine
+
+\list
+\li JavaScript engine has changed to V8.
+\li Various parser and compiler optimizations have been implemented, as well as a new bindings optimizer.
+\li New QQmlEngine::trimComponentCache() method safely discards unused data in the engine's component cache to free memory.
+\endlist
+
+\section2 Component and Object creation
+
+\list
+\li Loading/compilation can now be performed in a separate thread. Enable this by loading a \l Loader object asynchronously through its \l{Loader::}{source} property, or by passing the \c Component.Asynchronous parameter to \c Qt.createComponent().
+\li The component returned by \c Qt.createComponent() is no longer parented to the engine.  Be sure to hold a reference, or provide a parent.
+\endlist
+
+\section2 Type System
+
+\list
+\li New \l var property type. This is a general-purpose property type which obsoletes the \l variant type.
+    Properties of the \l var type may hold JavaScript references.
+\li QML properties of type \l var and \l variant can now hold pixmaps. See \l {Scarce Resources in JavaScript} for more information.
+\li Value type improvements:
+    \list
+    \li QColor is now a value type.  The red, green, blue and alpha channels of a \l color property can be accessed via \c r, \c g, \c b and \c a properties.
+    \li Improved support for QVector4D, now constructible in QML via \c Qt.vector4d().
+    \endlist
+\li Support for sequence types QList<int>, QList<qreal>, QList<bool>, QList<QUrl>,
+    QList<QString> and QStringList has been improved. QObjects can define Q_PROPERTYs of
+    these types which can be accessed transparently from JavaScript.
+\endlist
+
+\section2 Modules and Imports
+
+\list
+\li Arbitrary functionality may be provided in a namespace through a Module API.  See qmlRegisterModuleApi() for more information.
+\li JavaScript (.js) files may now import QML modules and other JavaScript files using the ".import" syntax.
+\endlist
+
+\section2 Other
+
+\list
+\li QQmlExpression can now be constructed directly (and more efficiently) from a QQmlScriptString.
+\endlist
+
+*/
+
index d1f3755..ba752b0 100644 (file)
@@ -102,6 +102,7 @@ Quick Links:
 \li \l{qtquick-module.html}{Qt Quick Module C++ API Reference}
 \li \l{qtqml-main.html}{Qt QML Module Documentation}
 \li \l{qtquick-applicationdevelopers.html}{QML Application Developer Resources}
+\li \l{qtquick-releasenotes.html}{QtQuick Release Notes}
 \endlist
 
 */
index 9c0046c..03d5433 100644 (file)
 ****************************************************************************/
 
 /*!
-\title What's New in Qt Quick 2
-\page qtquick2-whatsnew.html
+\title QtQuick Module Release Notes
+\page qtquick-releasenotes.html
 \inqmlmodule QtQuick 2.0
 
-\section1 Qt 5.0.0 includes QtQuick 2.0
+\section1 Qt 5.0 - QtQuick C++ Module
 
-QtQuick 2.0 is a major update.
+The QtQuick C++ module is new in Qt 5. It provides the visual canvas and scenegraph backend
+as well as the QtQuick QML module for QML application development.
 
-\section2 SceneGraph renderer
+(Prior to Qt 5, the QtQuick QML module was provided by the QtDeclarative C++ module. In Qt 5
+the QtDeclarative module has been replaced by the new QtQml and QtQuick C++ modules.)
 
-QtQuick 2 is based on an OpenGL scenegraph.  The following
-classes replace their equivalents in QtQuick 1:
+As of Qt 5, the QtQuick module is based on an OpenGL scenegraph. The following C++ classes replace
+their \c QDeclarative* equivalents from QtQuick 1:
 
 \list
 \li QQuickView
@@ -46,122 +48,149 @@ classes replace their equivalents in QtQuick 1:
 \li QQuickPaintedItem
 \endlist
 
-\section2 QML Engine/Language Improvements
 
-JS engine changed to V8. For most QML users this should not make a visible difference beyond performance improvements, however a lot of undefined behavior semantics may have changed as well. As always, it is recommended not to rely on undefined behavior.
+\section1 Qt 5.0 - QtQuick QML Module
 
-Parser and compiler optimizations.
+The QtQuick 2.0 QML module is a major update.
 
-New binding optimizer.
+Below are the additions and changes in QtQuick 2.0:
 
-ValueType improvements:
- - QColor is now a value type.  The red, green, blue and alpha channels can be accessed via "r", "g", "b" and "a" properties
- - Improved support for QVector4D, now constructible in QML via Qt.vector4d()
+\section2 Graphics and Animations
 
-Arbitrary functionality may be provided in a namespace through a Module API.  See \l{qmlRegisterModuleApi()} for more information.
-
-JavaScript (.js) files may now import QML modules and other JavaScript files.  See \l{Importing One JavaScript File From Another} for more information.
-
-A new property type "var" has been added which obsoletes the old "variant" property type.
-Properties of the "var" type may hold JavaScript references.  See \l{QML Basic Types} for more information.
-
-QML properties of type \c var and \c variant can now hold pixmaps.  See \l{Scarce Resources in JavaScript} for more information
-
-QQmlExpression can now be directly (and more efficiently) constructed from a
-QQmlScriptString.
-
-Support for certain sequence types (QList<int>, QList<qreal>, QList<bool>, QList<QUrl>, QList<QString> and QStringList) has been improved.
-QObjects can define Q_PROPERTYs of these types which can be accessed transparently from JavaScript.  See the section on
-sequences in \l{Extending QML Functionalities using C++} for more information.
-
-\section2 Canvas Item
-
-The new \l Canvas item provides a HTML5 canvas like API, with some enhancements:
-1) Supports 2 render targets: Canvas.Image and Canvas.FramebufferObject
-2) Supports background thread rendering
-3) Supports tiled canvas rendering
-
-The Canvas item supports most of the HTML5 context2d APIs, the API details please look at the canvas item documentation.
-
-
-\section2 Particle System
-
-The \l{QtQuick.Particles 2}{QtQuick.Particles} module contains elements that can be composed to form 2D particle system.
-
-
-\section2 Element API/Behavior Changes
+\list
+\li New \l Canvas type for drawing. This provides a HTML5 canvas like API along with some additional features.
+    \list
+    \li Supports two render targets: \c Canvas.Image and \c Canvas.FramebufferObject.
+    \li Supports background thread rendering.
+    \li Supports tiled canvas rendering.
+    \li Supports most of the HTML5 context2d APIs.
+    \endlist
+\li \l Image:
+    \list
+    \li New \l{Image::}{horizontalAlignment} and \l{Image::}{verticalAlignment} properties.
+    \li New \c Image.Pad enum value for \l{Image::}{fillMode} that does not transform the image, unlike other \l{Image::}{fillMode} enum values.
+    \li Modifying the \l{Image::}{sourceSize} now fits the image to the size, maintaining aspect ratio.
+    \endlist
+\li New SpriteSequence type renders animated sprites and can transition between animations.
+\li New \l Sprite type which represents each animation in a SpriteSequence.
+\li New AnimatedSprite type for drawing single sprite animations.
+\li New PathArc, PathCurve and PathSvg types:
+    \list
+    \li PathArc and PathCurve support the construction of arcs and catmull-rom curves, respectively. PathSvg supports the construction of a path from a SVG string.
+    \endlist
+    \endlist
+\endlist
 
-New \l SpriteSequence element renders animated sprites and can transition between animations.
-It uses the \l Sprite element to represent each animation. For drawing single sprite animations, there is also the \l AnimatedSprite element.
 
-MouseArea now propagates clicked, doubleClicked and pressAndHold differently to pressed.
-These will now be propagated to the highest-stacking-order enabled MouseArea which has a handler for them.
-You can still ignore these events in the handler to let them pass through.
-This behavior is triggered with the new property propagateComposedEvents.
+\section2 Text
 
-The Binding element can now be used as a value source, and will also restore any previously
-set binding when its \e when clause becomes false.
+\list
+\li \l Text:
+    \list
+    \li When \c Text.AutoText format is enabled, the text object will automatically switch to \c Text.StyledText instead of \c Text.RichText.
+    \li New \l{Text::}{onLineLaidOut} handler is called for every line during the layout process to give the option of positioning and/or resizing lines as they are laid out.
+    \li New \l{Text::}{doLayout()} method will trigger the text layout from Javascript.
+    \li \c Text.RightElide is now supported where text spans multiple lines.
+    \li New \l{Text::}{fontSizeMode} property allows text to be fitted to the item size.
+    \li New \l{Text::}{minimumPixelSize} and \l {Text::}{minimumPointSize} properties can be used to specify a lower bound when auto-fitting.
+    \endlist
+\li TextEdit:
+    \list
+    \li \l{TextEdit::}{textFormat} property now defaults to \c PlainText instead of \c AutoText.
+    \endlist
+\li TextInput:
+    \list
+    \li New \l{TextInput::}{wrapMode} property.
+    \li New \l{TextInput::}{horizontalAlignment} and \l{TextInput::}{verticalAlignment} properties.
+    \li \l{TextInput::}{positionAt()} method now takes a y parameter.
+    \endlist
+\endlist
 
-Flickable: added dragging, draggingHorizontally and draggingVerically properties.
-Added topMargin, bottomMargin, leftMargin, rightMargin, xOrigin, yOrigin properties.
+\section2 User Input
 
-Image has two new properties: horizontalAlignment and verticalAlignment. It also has a new value for
-fillMode (Image.Pad) that does not transform the image.
-Setting Image sourceSize.width and sourceSize.height will now fit the image to the size, maintaining aspect.
+\list
+\li New MultiPointTouchArea type processes multi-point touches and provides information on touch points including position, pressure and velocity.
+\li MouseArea:
+    \list
+    \li Wheel events are now supported.
+    \li The \l{MouseArea::}{onClicked}, \l{MouseArea::}{onDoubleClicked} and \l{MouseArea::}{onPressAndHold} signals are now propagated differently to \l{MouseArea::}{onPressed}. These will now be propagated to the highest-stacking-order enabled MouseArea that has a handler for them. You can still ignore these events in the handler to let them pass through; this behavior is triggered with the new property \l{MouseArea::}{propagateComposedEvents}.
+    \li New \l{MouseArea::}{propagateComposedEvents} property sets whether composed events are propagated to other mouse areas.
+    \endlist
+\endlist
 
-Grid now has rowSpacing and columnSpacing properties. Spacing properties on positioners are now real numbers instead
-of integers.
+\section2 Specialised Containers
 
-Positioner (Row, Column, Grid, Flow) improvements:
 \list
-\li Transitions used for \c add and \c move now have improved features: they can access a ViewTransition attached property (see the ViewTransition documentation for examples) and can now animate arbitrary item properties (instead of being restricted to animating an item's position).
-\li Items in a positioner now have attached properties that can be used to determine a subitem's location: Positioner.index, Positioner.isFirstItem, Positioner.isLastItem.
+\li Flickable:
+    \list
+    \li New \l{Flickable::}{rebound} property specifies the transition to be applied when a flickable snaps back to its bounds.
+    \li New \l{Flickable::}{topMargin}, \l{Flickable::}{bottomMargin}, \l{Flickable::}{leftMargin}, \l{Flickable::}{rightMargin} allow extra margin space to be specified for a flickable. This can be used, for example, to implement the pull-to-refresh functionality for a list.
+    \li New \l{Flickable::}{originX} and \l{Flickable::}{originY} properties provide the top left position of the content item.
+    \li New \l{Flickable::}{dragging}, \l{Flickable::}{draggingHorizontally} and \l{Flickable::}{draggingVertically} properties provide information on whether a flickable is currently being dragged.
+    \endlist
 \endlist
 
-Loader improvements:
- - "active" property added to Loader, to allow delaying instantiation of a Loader element's item property
- - "setSource(JSObject)" method added to Loader to allow initial property values to be specified (similar to Component.createObject())
- - now only emits the \c sourceChanged signal when the source is changed and the
-\c sourceComponentChanged signal when the sourceComponent is changed. It used to emit both signals when one of the properties was changed.
+\section2 Positioners (Row, Column, Grid, Flow types):
 
-Text improvements:
- - a \c onLineLaidOut handler is called for every line during the layout process. This gives the opportunity to position and resize a line as it is being laid out.
- - a \c doLayout method was added to trigger the layout from Javascript.
- - now automatically switch to StyledText instead of RichText if textFormat is set to AutoText.
+\list
+\li The \c add and \c move transitions can now access a ViewTransition attached property (see the ViewTransition documentation for examples) and can now animate arbitrary item properties (instead of being restricted to animating an item's position).
+\li New \l Positioner type provides \c index, \c isFirstItem and \c isLastItem attached properties for items within positioners.
+\li All \c spacing properties on positioners now use real numbers instead of integers.
+\li Grid:
+    \list
+    \li New \l{Grid::}{rowSpacing} and \l{Grid::}{columnSpacing} properties.
+    \endlist
+\endlist
 
-TextEdit:
- - the default value of the textFormat property is now PlainText instead of AutoText.
+\section2 Models and Views
 
-TextInput has new wrapMode and verticalAlignment properties, and the positionAt function now takes
-a y parameter.
+\list
+\li ListView and GridView:
+    \list
+    \li New transition support for animating the adding, removing and moving of items in a ListView or GridView. See the ViewTransition documentation for details.
+    \li New \c verticalLayoutDirection property enables items to be laid out from bottom-to-top using the new \c BottomToTop enum value.
+    \li New \c headerItem and \c footerItem properties provide access to the instantiated header and footer items.
+    \li The \c cacheBuffer property now has a non-zero default.
+    \li Delegates in the cache buffer are now created asynchronously.
+    \li Setting a \c RightToLeft layout now also reverses the \c preferredHighlightBegin and \c preferredHighlightEnd.
+    \endlist
+\li ListView only:
+    \list
+    \li New \l{ListView::}{section.labelPositioning} property can fix the current section label to the start of the view, and the next section label to the end of the view, so that labels do not scroll while section items are still in view.
+    \endlist
+\li PathView:
+    \list
+    \li New \l{PathView::}{currentItem} property.
+    \li New \l{PathView::}{maximumFlickVelocity} property.
+    \endlist
+\endlist
 
-PathView now has a \c currentItem property
+\section2 Utility types
 
-ListView and GridView:
- - Can now apply specified transitions whenever items are added, removed or moved in a view.
-   See the documentation for ViewTransition and ListView.add, ListView.addDisplaced,
-   GridView.add, GridView.addDisplaced etc. for details.
- - These now have headerItem and footerItem properties (the instantiated header and footer items).
- - In RightToLeft layout the preferredHighlightBegin/End are now also reversed.
+\list
+\li \l Loader:
+    \list
+    \li New \l{Loader::}{asynchronous} property allows components to be instantiated with lower chance of blocking.  If source is used with \e {asynchonous: true} the component will be compiled in a background thread.
+    \li New \l{Loader::}{active} property delays instantiation of a \l Loader object's \l{Loader::}{item}.
+    \li New \l{Loader::}{setSource()} method can load an object with specific initial property values, similar to \l Component::createObject().
+    \li The \c sourceChanged signal is now only emitted when the \l{Loader::}{source} changes and the \c sourceComponentChanged signal is now only emitted when the \l{Loader::}{sourceComponent} changes. (Previously Loader emitted both signals when only one of the properties had changed.)
+    \endlist
+\li \l Binding:
+    \list
+    \li This type can now be used as a value source, and will also restore any previously set binding when its \l{Binding::}{when} clause becomes false.
+    \endlist
+\endlist
 
-ListView section.labelPositioning property added to allow keeping the current section label
-at the start and/or next section label at the end of the view.
 
-A new property type ("var") has been introduced which obsoletes "variant" properties in QML.
-Properties of this type are equivalent to regular JavaScript variables.  See the documentation
-on \l{QML Basic Types} for more information about "var" properties.
+\section1 Qt 5.0 - Additional QML Modules
 
-New elements have been added for contructing paths: PathArc, PathCurve, PathSvg.
+\section2 QtQuick.Particles
 
-\section2 QtQuick 1 is now a separate library and module
+The new QtQuick.Particles module provides particle system support for creating a variety of 2D particle systems. See the QtQuick.Particles documentation for comprehensive details.
 
-Writing C++ applications using QtQuick 1 specific API, i.e. QDeclarativeView or QDeclarativeItem
-requires adding the "quick1" module to the .pro file, e.g. QT += quick1
+\section2 QtQuick.XmlListModel
 
-QDeclarativeView and QDeclarativeItem headers are now in the QtQuick 1 module, i.e.
-#include <QtQuick1/QDeclarativeView>
-#include <QtQuick1/QDeclarativeItem>
+XmlListModel has now moved into its own module, QtQuick.XmlListModel. This module must now be imported to use the XmlListModel and XmlListModelRole types.
 
-\sa {What's New in Qt Quick 1}{What's New in Qt Quick 1}
 
 */