summaryrefslogtreecommitdiffstats
path: root/examples/declarative/searchbox/SearchBox.qml
diff options
context:
space:
mode:
Diffstat (limited to 'examples/declarative/searchbox/SearchBox.qml')
-rw-r--r--examples/declarative/searchbox/SearchBox.qml17
1 files changed, 10 insertions, 7 deletions
diff --git a/examples/declarative/searchbox/SearchBox.qml b/examples/declarative/searchbox/SearchBox.qml
index be85023..adeddd1 100644
--- a/examples/declarative/searchbox/SearchBox.qml
+++ b/examples/declarative/searchbox/SearchBox.qml
@@ -18,7 +18,8 @@ FocusScope {
}
Text {
- id: typeSomething; anchors.fill: parent; anchors.leftMargin: 8
+ id: typeSomething
+ anchors.fill: parent; anchors.leftMargin: 8
verticalAlignment: Text.AlignVCenter
text: "Type something..."; color: "gray"; font.italic: true
}
@@ -27,18 +28,20 @@ FocusScope {
TextInput {
id: textInput
- anchors.left: parent.left; anchors.leftMargin: 8
- anchors.verticalCenter: parent.verticalCenter
+ anchors { left: parent.left; leftMargin: 8; verticalCenter: parent.verticalCenter }
focus: if (1) true
}
Image {
id: clear
- anchors.right: parent.right; anchors.rightMargin: 8
- anchors.verticalCenter: parent.verticalCenter
- source: "images/edit-clear-locationbar-rtl.png"; opacity: 0
+ anchors { right: parent.right; rightMargin: 8; verticalCenter: parent.verticalCenter }
+ source: "images/edit-clear-locationbar-rtl.png"
+ opacity: 0
- MouseArea { anchors.fill: parent; onClicked: { textInput.text = ''; focusScope.focus = true } }
+ MouseArea {
+ anchors.fill: parent
+ onClicked: { textInput.text = ''; focusScope.focus = true }
+ }
}
states: State {