summaryrefslogtreecommitdiffstats
path: root/doc/src/declarative
diff options
context:
space:
mode:
authorYann Bodson <yann.bodson@nokia.com>2009-08-21 00:07:17 (GMT)
committerYann Bodson <yann.bodson@nokia.com>2009-08-21 00:07:17 (GMT)
commitaf15183ca230cb96ef9e2901e3fbb716eb4300bb (patch)
treec84d4bed8a1acba57c898446259f4028f9dd4e72 /doc/src/declarative
parentf738eab2d811e7d2ef274c3b7819c1231669e8b8 (diff)
downloadQt-af15183ca230cb96ef9e2901e3fbb716eb4300bb.zip
Qt-af15183ca230cb96ef9e2901e3fbb716eb4300bb.tar.gz
Qt-af15183ca230cb96ef9e2901e3fbb716eb4300bb.tar.bz2
Renaming: Bind -> Binding
Diffstat (limited to 'doc/src/declarative')
-rw-r--r--doc/src/declarative/binding.qdoc14
-rw-r--r--doc/src/declarative/elements.qdoc2
2 files changed, 8 insertions, 8 deletions
diff --git a/doc/src/declarative/binding.qdoc b/doc/src/declarative/binding.qdoc
index a649f3f..064f686 100644
--- a/doc/src/declarative/binding.qdoc
+++ b/doc/src/declarative/binding.qdoc
@@ -5,17 +5,17 @@
Data binding provides a declarative way of specifying the data associated with objects, as well as the relationship between data of different objects. For example, you could bind the text of a label to the value of a slider: as the value of the slider changed, the label would be automatically updated with the new value.
-Bindings are created in QML when an expression is assigned to a property. For example, the following produces two rectangles of equal size (\c rect2 is bound to the size of \c rect1):
+Bindings are created in QML when an expression is assigned to a property. For example, the following produces two rectangles of equal size (\c Rect2 is bound to the size of \c Rect1):
\code
-Rectangle { id: rect1; width: 100; height: 100 }
-Rectangle { id: rect2; width: rect1.width; height: rect1.height }
+Rectangle { id: Rect1; width: 100; height: 100 }
+Rectangle { id: Rect2; width: Rect1.width; height: Rect1.height }
\endcode
-There is also a special \l Bind element, which is typically used to bind from the UI to the underlying UI model (see \l {Passing Data Between C++ and QML} for an example of this). The bindings above could be expressed using the \l Bind element as:
+There is also a special \l Binding element, which is typically used to bind from the UI to the underlying UI model (see \l {Passing Data Between C++ and QML} for an example of this). The bindings above could be expressed using the \l Binding element as:
\code
-Bind { target: rect2; property: "width"; value: rect1.width }
-Bind { target: rect2; property: "height"; value: rect1.height }
+Binding { target: Rect2; property: "width"; value: Rect1.width }
+Binding { target: Rect2; property: "height"; value: Rect1.height }
\endcode
In addition to binding directly to a property, you can also bind to the results of expressions involving properties. For example:
@@ -102,7 +102,7 @@ Finally, in QML you can make the appropriate bindings, so in \c "MyUI.qml":
\code
Slider { value: screen.brightness }
-Bind { target: screen; property: "brightness"; value: slider.value }
+Binding { target: screen; property: "brightness"; value: slider.value }
\endcode
The \l QBindableMap class provides a convenient way to make data visible to the bind engine.
diff --git a/doc/src/declarative/elements.qdoc b/doc/src/declarative/elements.qdoc
index 2d43fda..aef05d7 100644
--- a/doc/src/declarative/elements.qdoc
+++ b/doc/src/declarative/elements.qdoc
@@ -40,7 +40,7 @@ The following table lists the QML elements provided by the Qt Declarative module
\o
\list
-\o \l Bind
+\o \l Binding
\o \l ListModel
\o \l VisualItemModel
\o \l XmlListModel and XmlRole