summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLeena Miettinen <riitta-leena.miettinen@qt.io>2019-12-19 16:38:18 +0100
committerLeena Miettinen <riitta-leena.miettinen@qt.io>2020-01-09 14:05:37 +0000
commitdf60a47cdd0d41e9589ae86a68e212303ab5fd4e (patch)
tree4f3d8470127aa98bc69c407b845948d36815662e
parent4ad3cdc1159dd4f2a4478e85b69c984c11127367 (diff)
downloadqt-creator-df60a47cdd0d41e9589ae86a68e212303ab5fd4e.tar.gz
Doc: Describe using the binding editor in the Design mode States pane
...to create when statements Change-Id: Iec56f6aa76478ca1ffc9803df3dffd4cd7196e65 Reviewed-by: Aleksei German <aleksei.german@qt.io> Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
-rw-r--r--doc/images/qmldesigner-transitions.pngbin3229 -> 5169 bytes
-rw-r--r--doc/images/qtquick-states-binding-editor.pngbin0 -> 3422 bytes
-rw-r--r--doc/src/qtquick/qtquick-states.qdoc8
3 files changed, 8 insertions, 0 deletions
diff --git a/doc/images/qmldesigner-transitions.png b/doc/images/qmldesigner-transitions.png
index f3599b7ca6..8d7309ddc8 100644
--- a/doc/images/qmldesigner-transitions.png
+++ b/doc/images/qmldesigner-transitions.png
Binary files differ
diff --git a/doc/images/qtquick-states-binding-editor.png b/doc/images/qtquick-states-binding-editor.png
new file mode 100644
index 0000000000..57be12f0ec
--- /dev/null
+++ b/doc/images/qtquick-states-binding-editor.png
Binary files differ
diff --git a/doc/src/qtquick/qtquick-states.qdoc b/doc/src/qtquick/qtquick-states.qdoc
index 58a02677f6..5a40828f76 100644
--- a/doc/src/qtquick/qtquick-states.qdoc
+++ b/doc/src/qtquick/qtquick-states.qdoc
@@ -79,6 +79,14 @@
To determine when the state should be applied, select
\uicontrol {Set when Condition} in the menu and specify a
\l [QtQuick]{State::when}{when} property for the state.
+ Set the value of the property to an expression that
+ evaluates to \c true when you want the state to be applied.
+ In the binding editor, select the component and property to
+ create the expression. For example, to change the state when
+ a button is pressed, you could select a button component and
+ its pressed property.
+
+ \image qtquick-states-binding-editor.png "Binding editor in States pane"
You can preview the states in the \uicontrol States pane and click them to
switch between states on the canvas.