// import QtQuick 1.0 // to target S60 5th Edition or Maemo 5 import QtQuick 1.0 Rectangle { id: opacityButton property string textLabel property int radiusOfButton: 15 property int textSize: 8 property bool boldState: false signal clicked() color: "#272727" border.color: "#626262" border.width: 2 radius: radiusOfButton opacity: 0.7 smooth: true Text{ id: textButton color: "#ffffff" anchors.centerIn: parent font.pointSize: textSize font.bold: boldState text: textLabel } MouseArea{ id: mouse anchors.fill: parent onClicked: opacityButton.clicked() } states: [ State { name: "pressed"; when: mouse.pressed === true PropertyChanges { target: opacityButton color: "#181818" border.color: "#323232" } PropertyChanges { target: textButton color: "#a5a5a5" } } ] }