34 lines
1020 B
QML
34 lines
1020 B
QML
import QtQuick 2.12
|
|
import QtQuick.Controls 2.12
|
|
|
|
import Utils 1.0
|
|
|
|
Button {
|
|
id: control
|
|
|
|
contentItem: Text {
|
|
text: control.text
|
|
font.pixelSize: 16
|
|
font.weight: Font.Bold
|
|
opacity: enabled ? 1.0 : 0.7
|
|
color: control.hovered ? Palette.alternativeTextColor : Palette.textColor
|
|
horizontalAlignment: Text.AlignHCenter
|
|
verticalAlignment: Text.AlignVCenter
|
|
elide: Text.ElideRight
|
|
maximumLineCount: 2
|
|
wrapMode: Text.Wrap
|
|
}
|
|
|
|
background: Rectangle {
|
|
implicitWidth: 200
|
|
implicitHeight: 52
|
|
opacity: enabled ? 1 : 0.7
|
|
color: control.pressed ? Palette.pressedButtonColor :
|
|
control.hovered ? Palette.hoveredButtonColor : Palette.outlineButtonColor
|
|
border.color: control.pressed ? Palette.pressedButtonColor :
|
|
control.hovered ? Palette.hoveredButtonColor : Palette.buttonColor
|
|
border.width: 1
|
|
radius: 5
|
|
}
|
|
}
|