summaryrefslogtreecommitdiffstats
path: root/demos/declarative/minehunt/Description.qml
diff options
context:
space:
mode:
Diffstat (limited to 'demos/declarative/minehunt/Description.qml')
-rw-r--r--demos/declarative/minehunt/Description.qml34
1 files changed, 34 insertions, 0 deletions
diff --git a/demos/declarative/minehunt/Description.qml b/demos/declarative/minehunt/Description.qml
new file mode 100644
index 0000000..440dd2e
--- /dev/null
+++ b/demos/declarative/minehunt/Description.qml
@@ -0,0 +1,34 @@
+import Qt 4.6
+
+Item {
+ id: page
+ height: myText.height + 20
+ property var text
+ MouseRegion {
+ anchors.fill: parent
+ drag.target: page
+ drag.axis: "XandYAxis"
+ drag.minimumX: 0
+ drag.maximumX: 1000
+ drag.minimumY: 0
+ drag.maximumY: 1000
+ }
+ Rectangle {
+ radius: 10
+ anchors.fill: parent
+ color: "lightsteelblue"
+ }
+ Item {
+ x: 10
+ y: 10
+ width: parent.width - 20
+ height: parent.height - 20
+ Text {
+ id: myText
+ text: page.text
+ width: parent.width
+ clip: true
+ wrap: true
+ }
+ }
+}