summaryrefslogtreecommitdiffstats
path: root/examples/declarative/loader/Button.qml
blob: d01a6588736d08b85c1d3ab63a55030ee30f7fd5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import Qt 4.6

Rectangle {
    id: Container

    property var text
    signal clicked

    height: Text.height + 10
    width: Text.width + 20
    border.width: 1
    radius: 4
    color: "grey"
    MouseRegion { anchors.fill: parent; onClicked: Container.clicked() }
    Text { id: Text; anchors.centerIn:parent; font.pointSize: 10; text: parent.text }
}