Platformer with Level Editor
import QtQuick 2.0
import QtQuick.Controls.Styles 1.0
import Felgo 3.0
GameButton {
id: textButton
width: screenText.width + 20
height: 30
property color color: "#ffffff"
property alias screenText: screenText.text
property alias textColor: screenText.color
style: ButtonStyle {
background: Rectangle {
border.width: 1
border.color: "black"
radius: 3
gradient: Gradient {
GradientStop { position: 0.0; color: textButton.color }
GradientStop { position: 1.0; color: Qt.tint(textButton.color, "#24000000") }
}
}
}
onClicked: audioManager.playSound("click")
Text {
id: screenText
anchors.centerIn: parent
font.pixelSize: 12
}
Rectangle {
anchors.fill: parent
radius: 3
color: "white"