diff options
author | David Boddie <dboddie@trolltech.com> | 2010-06-30 17:06:37 (GMT) |
---|---|---|
committer | David Boddie <dboddie@trolltech.com> | 2010-06-30 17:06:37 (GMT) |
commit | 0713442baa4120050e85c13998797415bb40efce (patch) | |
tree | 2735cae5573363fd5edceae71ae8b7af60518df2 /doc | |
parent | 08478207ee9a6563ae63ebcef833925db6426bd8 (diff) | |
parent | 01648005f1f546dc0281155fecd94b4f47a94584 (diff) | |
download | Qt-0713442baa4120050e85c13998797415bb40efce.zip Qt-0713442baa4120050e85c13998797415bb40efce.tar.gz Qt-0713442baa4120050e85c13998797415bb40efce.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7
Conflicts:
tools/qdoc3/test/qt-html-templates.qdocconf
Diffstat (limited to 'doc')
-rw-r--r-- | doc/src/declarative/basictypes.qdoc | 16 | ||||
-rw-r--r-- | doc/src/declarative/dynamicobjects.qdoc | 14 | ||||
-rw-r--r-- | doc/src/scripting/ecmascript.qdoc | 50 |
3 files changed, 62 insertions, 18 deletions
diff --git a/doc/src/declarative/basictypes.qdoc b/doc/src/declarative/basictypes.qdoc index 734175c..159f40d 100644 --- a/doc/src/declarative/basictypes.qdoc +++ b/doc/src/declarative/basictypes.qdoc @@ -157,8 +157,8 @@ Rectangle { color: "#800000FF" } \endqml - Or with the \l{Qt::rgba()}{Qt.rgba()}, \l{Qt::hsla()}{Qt.hsla()}, \l{Qt::darker()}{Qt.darker()}, - \l{Qt::lighter()}{Qt.lighter()} or \l{Qt::tint()}{Qt.tint()} functions: + Or with the \l{QML:Qt::rgba()}{Qt.rgba()}, \l{QML:Qt::hsla()}{Qt.hsla()}, \l{QML:Qt::darker()}{Qt.darker()}, + \l{QML:Qt::lighter()}{Qt.lighter()} or \l{QML:Qt::tint()}{Qt.tint()} functions: \qml Rectangle { color: Qt.rgba(255, 0, 0, 1) } @@ -181,7 +181,7 @@ CustomObject { myPointProperty: "0,20" } \endqml - Or use the \l{Qt::point()}{Qt.point()} function: + Or use the \l{QML:Qt::point()}{Qt.point()} function: \qml CustomObject { myPointProperty: Qt.point(0, 20) } @@ -213,7 +213,7 @@ LayoutItem { preferredSize: "150x50" } \endqml - Or use the \l{Qt::size()}{Qt.size()} function: + Or use the \l{QML:Qt::size()}{Qt.size()} function: \qml LayoutItem { preferredSize: Qt.size(150, 50) } @@ -246,7 +246,7 @@ CustomObject { myRectProperty: "50,50,100x100" } \endqml - Or use the \l{Qt::rect()}{Qt.rect()} function: + Or use the \l{QML:Qt::rect()}{Qt.rect()} function: \qml CustomObject { myRectProperty: Qt.rect(50, 50, 100, 100) } @@ -269,7 +269,7 @@ \endqml To read a date value returned from a C++ extension class, use - \l{Qt::formatDate()}{Qt.formatDate()} and \l{Qt::formatDateTime()}{Qt.formatDateTime()}. + \l{QML:Qt::formatDate()}{Qt.formatDate()} and \l{QML:Qt::formatDateTime()}{Qt.formatDateTime()}. \sa {QML Basic Types} */ @@ -288,7 +288,7 @@ \endqml To read a time value returned from a C++ extension class, use - \l{Qt::formatTime()}{Qt.formatTime()} and \l{Qt::formatDateTime()}{Qt.formatDateTime()}. + \l{QML:Qt::formatTime()}{Qt.formatTime()} and \l{QML:Qt::formatDateTime()}{Qt.formatDateTime()}. \sa {QML Basic Types} */ @@ -386,7 +386,7 @@ Rotation { angle: 60; axis: "0,1,0" } \endqml - or with the \l{Qt::vector3d()}{Qt.vector3d()} function: + or with the \l{QML:Qt::vector3d()}{Qt.vector3d()} function: \qml Rotation { angle: 60; axis: Qt.vector3d(0, 1, 0) } diff --git a/doc/src/declarative/dynamicobjects.qdoc b/doc/src/declarative/dynamicobjects.qdoc index 0ffdbc9..de65a12 100644 --- a/doc/src/declarative/dynamicobjects.qdoc +++ b/doc/src/declarative/dynamicobjects.qdoc @@ -42,15 +42,15 @@ application, and there are no C++ components involved. \section1 Creating Objects Dynamically There are two ways to create objects dynamically from JavaScript. You can either call -\l {Qt::createComponent()}{Qt.createComponent()} to create -a component which instantiates items, or use \l{Qt::createQmlObject()}{Qt.createQmlObject()} +\l {QML:Qt::createComponent()}{Qt.createComponent()} to create +a component which instantiates items, or use \l{QML:Qt::createQmlObject()}{Qt.createQmlObject()} to create an item from a string of QML. Creating a component is better if you have a predefined item, and you want to create dynamic instances of that item; creating an item from a string of QML is useful when the item QML itself is generated at runtime. If you have a component specified in a QML file, you can dynamically load it with -the \l {Qt::createComponent()}{Qt.createComponent()} function on the \l{QML Global Object}. +the \l {QML:Qt::createComponent()}{Qt.createComponent()} function on the \l{QML Global Object}. This function takes the URL of the QML file as its only argument and returns a component object which can be used to create and load that QML file. @@ -84,10 +84,10 @@ in \c main.qml). After creating an item, you must set its parent to an item with Otherwise your dynamically created item will not appear in the scene. When using files with relative paths, the path should -be relative to the file where \l {Qt::createComponent()}{Qt.createComponent()} is executed. +be relative to the file where \l {QML:Qt::createComponent()}{Qt.createComponent()} is executed. If the QML component does not exist until runtime, you can create a QML item from -a string of QML using the \l{Qt::createQmlObject()}{Qt.createQmlObject()} function, as in the following example: +a string of QML using the \l{QML:Qt::createQmlObject()}{Qt.createQmlObject()} function, as in the following example: \snippet doc/src/snippets/declarative/createQmlObject.qml 0 @@ -107,9 +107,9 @@ the bindings in the dynamic item will no longer work. The actual creation context depends on how an item is created: \list -\o If \l {Qt::createComponent()}{Qt.createComponent()} is used, the creation context +\o If \l {QML:Qt::createComponent()}{Qt.createComponent()} is used, the creation context is the QDeclarativeContext in which this method is called -\o If \l{Qt::createQmlObject()}{Qt.createQmlObject()} +\o If \l{QML:Qt::createQmlObject()}{Qt.createQmlObject()} if called, it is the context of the item used as the second argument to this method \o If a \c {Component{}} item is defined and \l {Component::createObject()}{createObject()} is called on that item, it is the context in which the \c Component is defined diff --git a/doc/src/scripting/ecmascript.qdoc b/doc/src/scripting/ecmascript.qdoc index 4497a0b..508bf3b 100644 --- a/doc/src/scripting/ecmascript.qdoc +++ b/doc/src/scripting/ecmascript.qdoc @@ -30,8 +30,9 @@ \title ECMAScript Reference \brief A list of objects, functions and properties supported by QtScript. - This reference contains a list of objects, functions and - properties supported by QtScript. + This reference contains a list of built-in objects, functions and + properties supported by QtScript. For a detailed description, see + the \l{ECMA-262} specification. \tableofcontents @@ -43,7 +44,6 @@ \o NaN \o Infinity \o undefined - \o Math \endlist \section2 Function Properties @@ -80,10 +80,33 @@ \o URIError \endlist + \section2 Other Properties + + \list + \o Math + \o JSON + \endlist + \section1 Object Objects + \section2 Object Constructor + + \section3 Function Properties + + \list + \o getPrototypeOf(O) + \o getOwnPropertyDescriptor(O, P) + \o getOwnPropertyNames(O) + \o create(O [, Properties]) + \o defineProperty(O, P, Attributes) + \o defineProperties(O, Properties) + \o keys(O) + \endlist + \section2 Object Prototype Object + \section3 Function Properties + \list \o toString() \o toLocaleString() @@ -124,6 +147,15 @@ \o sort(comparefn) \o splice(start, deleteCount[, item1 [, item2 [, ...]]]) \o unshift([item1 [, item2 [, ...]]]) + \o indexOf(searchElement [, fromIndex]) + \o lastIndexOf(searchElement [, fromIndex]) + \o every(callbackfn [, thisArg]) + \o some(callbackfn [, thisArg]) + \o forEach(callbackfn [, thisArg]) + \o map(callbackfn [, thisArg]) + \o filter(callbackfn [, thisArg]) + \o reduce(callbackfn [, initialValue]) + \o reduceRight(callbackfn [, initialValue]) \endlist \section1 String Objects @@ -151,6 +183,7 @@ \o toLocaleLowerCase() \o toUpperCase() \o toLocaleUpperCase() + \o trim() \endlist \section1 Boolean Objects @@ -264,6 +297,8 @@ \o setFullYear(year [, month [, date]]) \o setUTCFullYear(year [, month [, date]]) \o toUTCString() + \o toISOString() + \o toJSON() \endlist \section1 RegExp Objects @@ -295,4 +330,13 @@ \o toString() \endlist + \section1 The JSON Object + + \section2 Function Properties + + \list + \o parse(text [, reviver]) + \o stringify(value [, replacer [, space]]) + \endlist + */ |