mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-23 14:48:15 +00:00
feat(ui/modules/Linphone/TelKeypad/TelKeypadButton): add a line below each button
This commit is contained in:
parent
e56412e9c2
commit
bdf3d566de
2 changed files with 42 additions and 19 deletions
|
|
@ -18,9 +18,18 @@ QtObject {
|
|||
property color pressed: Colors.i
|
||||
}
|
||||
|
||||
property QtObject line: QtObject {
|
||||
property color color: Colors.l50
|
||||
property int bottomMargin: 4
|
||||
property int height: 2
|
||||
property int leftMargin: 8
|
||||
property int rightMargin: 8
|
||||
property int topMargin: 0
|
||||
}
|
||||
|
||||
property QtObject text: QtObject {
|
||||
property color color: Colors.d
|
||||
property int fontSize: 10
|
||||
property int fontSize: 11
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Layouts 1.3
|
||||
|
||||
import Linphone.Styles 1.0
|
||||
|
||||
|
|
@ -16,30 +16,44 @@ Item {
|
|||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
Button {
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: button.color
|
||||
|
||||
background: Rectangle {
|
||||
color: button.color
|
||||
}
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
|
||||
contentItem: Text {
|
||||
color: TelKeypadStyle.button.text.color
|
||||
spacing: 0
|
||||
|
||||
font {
|
||||
bold: true
|
||||
pointSize: TelKeypadStyle.button.text.fontSize
|
||||
Text {
|
||||
Layout.fillHeight: true
|
||||
Layout.fillWidth: true
|
||||
|
||||
color: TelKeypadStyle.button.text.color
|
||||
elide: Text.ElideRight
|
||||
|
||||
font {
|
||||
bold: true
|
||||
pointSize: TelKeypadStyle.button.text.fontSize
|
||||
}
|
||||
|
||||
text: button.text
|
||||
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
}
|
||||
|
||||
elide: Text.ElideRight
|
||||
text: button.text
|
||||
Rectangle {
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: TelKeypadStyle.button.line.height
|
||||
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
Layout.bottomMargin: TelKeypadStyle.button.line.bottomMargin
|
||||
Layout.leftMargin: TelKeypadStyle.button.line.leftMargin
|
||||
Layout.rightMargin: TelKeypadStyle.button.line.rightMargin
|
||||
Layout.topMargin: TelKeypadStyle.button.line.topMargin
|
||||
|
||||
color: TelKeypadStyle.button.line.color
|
||||
}
|
||||
}
|
||||
|
||||
hoverEnabled: true
|
||||
|
||||
onClicked: button.clicked()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue