diff --git a/electrum/gui/qml/components/MessageDialog.qml b/electrum/gui/qml/components/MessageDialog.qml index 0d6a5e77f..51fd9da56 100644 --- a/electrum/gui/qml/components/MessageDialog.qml +++ b/electrum/gui/qml/components/MessageDialog.qml @@ -28,35 +28,54 @@ ElDialog { color: "#aa000000" } + padding: 0 + ColumnLayout { - TextArea { - id: message - Layout.preferredWidth: Overlay.overlay.width *2/3 - readOnly: true - wrapMode: TextInput.WordWrap - textFormat: richText ? TextEdit.RichText : TextEdit.PlainText - background: Rectangle { - color: 'transparent' + ColumnLayout { + Layout.margins: constants.paddingMedium + Layout.alignment: Qt.AlignHCenter + TextArea { + id: message + Layout.preferredWidth: Overlay.overlay.width *2/3 + readOnly: true + wrapMode: TextInput.WordWrap + textFormat: richText ? TextEdit.RichText : TextEdit.PlainText + background: Rectangle { + color: 'transparent' + } } } - RowLayout { - Layout.alignment: Qt.AlignHCenter - Button { + ButtonContainer { + Layout.fillWidth: true + + FlatButton { + Layout.fillWidth: true + textUnderIcon: false text: qsTr('Ok') + icon.source: Qt.resolvedUrl('../../icons/confirmed.png') visible: !yesno onClicked: dialog.close() } - Button { + + FlatButton { + Layout.fillWidth: true + Layout.preferredWidth: 1 + textUnderIcon: false text: qsTr('Yes') + icon.source: Qt.resolvedUrl('../../icons/confirmed.png') visible: yesno onClicked: { yesClicked() dialog.close() } } - Button { + FlatButton { + Layout.fillWidth: true + Layout.preferredWidth: 1 + textUnderIcon: false text: qsTr('No') + icon.source: Qt.resolvedUrl('../../icons/closebutton.png') visible: yesno onClicked: { reject() diff --git a/electrum/gui/qml/components/controls/FlatButton.qml b/electrum/gui/qml/components/controls/FlatButton.qml index df336eaed..703e385b6 100644 --- a/electrum/gui/qml/components/controls/FlatButton.qml +++ b/electrum/gui/qml/components/controls/FlatButton.qml @@ -8,8 +8,10 @@ TabButton { id: control checkable: false + property bool textUnderIcon: true + font.pixelSize: constants.fontSizeSmall - display: IconLabel.TextUnderIcon + display: textUnderIcon ? IconLabel.TextUnderIcon : IconLabel.TextBesideIcon contentItem: IconLabel { spacing: control.spacing