Make qml template more designer friendly

If you open the qml file in the designer and want to move the text item
you move the mouse area instead. I think it is not very intuitive.

Change-Id: I41457e4f42a145433189ac45768e345ac73b262e
Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
This commit is contained in:
Marco Bubke
2014-03-05 14:05:13 +01:00
parent 67b06f8d1d
commit 2784d750cf
6 changed files with 35 additions and 26 deletions

View File

@@ -3,15 +3,17 @@ import QtQuick 1.1
Rectangle { Rectangle {
width: 360 width: 360
height: 360 height: 360
Text {
anchors.centerIn: parent
text: "Hello World"
}
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
Qt.quit(); Qt.quit();
} }
} }
Text {
anchors.centerIn: parent
text: "Hello World"
}
} }

View File

@@ -3,15 +3,18 @@ import QtQuick 2.1
Rectangle { Rectangle {
width: 360 width: 360
height: 360 height: 360
Text {
anchors.centerIn: parent
text: "Hello World"
}
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
Qt.quit(); Qt.quit();
} }
} }
Text {
anchors.centerIn: parent
text: "Hello World"
}
} }

View File

@@ -3,15 +3,17 @@ import QtQuick 2.2
Rectangle { Rectangle {
width: 360 width: 360
height: 360 height: 360
Text {
anchors.centerIn: parent
text: "Hello World"
}
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
Qt.quit(); Qt.quit();
} }
} }
Text {
anchors.centerIn: parent
text: "Hello World"
}
} }

View File

@@ -3,14 +3,16 @@ import QtQuick 1.1
Rectangle { Rectangle {
width: 360 width: 360
height: 360 height: 360
Text {
text: qsTr("Hello World")
anchors.centerIn: parent
}
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
Qt.quit(); Qt.quit();
} }
} }
Text {
text: qsTr("Hello World")
anchors.centerIn: parent
}
} }

View File

@@ -6,15 +6,15 @@ Window {
width: 360 width: 360
height: 360 height: 360
Text {
text: qsTr("Hello World")
anchors.centerIn: parent
}
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
Qt.quit(); Qt.quit();
} }
} }
Text {
text: qsTr("Hello World")
anchors.centerIn: parent
}
} }

View File

@@ -6,15 +6,15 @@ Window {
width: 360 width: 360
height: 360 height: 360
Text {
text: qsTr("Hello World")
anchors.centerIn: parent
}
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
Qt.quit(); Qt.quit();
} }
} }
Text {
text: qsTr("Hello World")
anchors.centerIn: parent
}
} }