summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-11-29 22:27:50 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-11-29 22:27:50 (GMT)
commit4277b05af534ff29c31fdd20189638704d8e48fa (patch)
tree9575b9fb64e8dda8137cf9892e32e34d86c250c7 /doc
parent4973e73c064f706aaadbda4c4cb27ff5c577702e (diff)
parent312604c85b1e6a6fc6de505bac86848936f81edd (diff)
downloadQt-4277b05af534ff29c31fdd20189638704d8e48fa.zip
Qt-4277b05af534ff29c31fdd20189638704d8e48fa.tar.gz
Qt-4277b05af534ff29c31fdd20189638704d8e48fa.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml: Improve consistency in handling of aliases, bindings and value types Move KeyNavigation example to snippets, plus some doc rewording
Diffstat (limited to 'doc')
-rw-r--r--doc/src/snippets/declarative/keynavigation.qml45
1 files changed, 45 insertions, 0 deletions
diff --git a/doc/src/snippets/declarative/keynavigation.qml b/doc/src/snippets/declarative/keynavigation.qml
new file mode 100644
index 0000000..d72bb3a
--- /dev/null
+++ b/doc/src/snippets/declarative/keynavigation.qml
@@ -0,0 +1,45 @@
+//![0]
+import QtQuick 1.0
+
+Grid {
+ width: 100; height: 100
+ columns: 2
+
+ Rectangle {
+ id: topLeft
+ width: 50; height: 50
+ color: focus ? "red" : "lightgray"
+ focus: true
+
+ KeyNavigation.right: topRight
+ KeyNavigation.down: bottomLeft
+ }
+
+ Rectangle {
+ id: topRight
+ width: 50; height: 50
+ color: focus ? "red" : "lightgray"
+
+ KeyNavigation.left: topLeft
+ KeyNavigation.down: bottomRight
+ }
+
+ Rectangle {
+ id: bottomLeft
+ width: 50; height: 50
+ color: focus ? "red" : "lightgray"
+
+ KeyNavigation.right: bottomRight
+ KeyNavigation.up: topLeft
+ }
+
+ Rectangle {
+ id: bottomRight
+ width: 50; height: 50
+ color: focus ? "red" : "lightgray"
+
+ KeyNavigation.left: bottomLeft
+ KeyNavigation.up: topRight
+ }
+}
+//![0]