5 property alias textInButton: buttonText.text
9 function setText(string) { textInButton = string; }
10 border { left: 10; top: 10; right: 10; bottom: 10 }
14 anchors.centerIn: parent;
16 height: parent.height;
25 anchors.centerIn: parent;
26 font.pixelSize: parent.height * .5
27 style: Text.Sunken; color: "white"; styleColor: "black"; smooth: true
32 width: (35*parent.height)/107 +1
34 anchors.left: parent.left
35 source: "qrc:/button/buttonLeft.png"
36 fillMode:Image.Stretch
42 width: parent.width - ((70*parent.height)/107) +1;
44 anchors.horizontalCenter: parent.horizontalCenter
45 source: "qrc:/button/buttonCenter.png"
46 fillMode:Image.Stretch
52 width: (35*parent.height)/107 +1
54 anchors.right: parent.right
55 source: "qrc:/button/buttonR.png"
56 fillMode:Image.Stretch
62 when: (mouseArea.pressed == true && button.enabled == true);
64 PropertyChanges { target: image1; source: "qrc:/button/buttonLeftPushed.png" }
65 PropertyChanges { target: image3; source: "qrc:/button/buttonCenterPushed.png" }
66 PropertyChanges { target: image2; source: "qrc:/button/buttonRightPushed.png" }
70 when: (button.enabled == false);
72 PropertyChanges { target: image1; source: "qrc:/button/buttonLeftDisabled.png" }
73 PropertyChanges { target: image3; source: "qrc:/button/buttonCenterDisabled.png" }
74 PropertyChanges { target: image2; source: "qrc:/button/buttonRightDisabled.png" }
82 anchors.centerIn: parent;
83 width: ((parent.width > buttonText.text.length*buttonText.font.pixelSize*.8) ? (parent.width) : (buttonText.text.length*buttonText.font.pixelSize*.60)) - ((70*parent.height)/107)
93 anchors.centerIn: parent;
94 font.pixelSize: parent.height * .5
95 style: Text.Sunken; color: "white"; styleColor: "black"; smooth: true
98 width: (button.width> buttonText.text.length*buttonText.font.pixelSize*.8) ? (parent.width) : (buttonText.text.length*buttonText.font.pixelSize*.8)
104 anchors.centerIn: parent;
105 radius: parent.height*.4;
108 width: ((parent.width > buttonText.text.length*buttonText.font.pixelSize*.8) ? (parent.width) : (buttonText.text.length*buttonText.font.pixelSize*.60))
109 height: parent.height
114 width: (35*parent.height)/107 +1
115 height: parent.height
116 anchors.left: parent.left
117 anchors.leftMargin: (parent.width - ((parent.width > buttonText.text.length*buttonText.font.pixelSize*.8) ? (parent.width) : (buttonText.text.length*buttonText.font.pixelSize*.60)))/2
118 source: "qrc:/button/buttonLeft.png"
124 width: (((parent.width > buttonText.text.length*buttonText.font.pixelSize*.8) ? (parent.width) : (buttonText.text.length*buttonText.font.pixelSize*.60)) - ((70*parent.height)/107))+1
125 height: parent.height
126 anchors.horizontalCenter: parent.horizontalCenter
127 source: "qrc:/button/buttonCenter.png"
133 width: (35*parent.height)/107 +1
134 height: parent.height
135 anchors.right: parent.right
136 anchors.rightMargin: (parent.width - ((parent.width > buttonText.text.length*buttonText.font.pixelSize*.8) ? (parent.width) : (buttonText.text.length*buttonText.font.pixelSize*.60)))/2
137 source: "qrc:/button/buttonR.png"
142 name: "pressed"; when: mouseArea.pressed == true
143 PropertyChanges { target: shade; opacity: 0.4 }
144 PropertyChanges { target: image1; opacity: 0.5 }
145 PropertyChanges { target: image3; opacity: 0.5 }
146 PropertyChanges { target: image2; opacity: 0.5 }