qml: Rebalance button widths

Removed preferred widths for OS, device buttons, and set one for the
storage button. This allows the storage label (generally the longest)
to fit on the control face reliably.
This commit is contained in:
Tom Dewey tom.dewey@raspberrypi.com 2023-10-09 14:12:42 +01:00
parent 8291e00934
commit c7fa7504fe

View file

@ -135,7 +135,6 @@ ApplicationWindow {
text: qsTr("Operating System") text: qsTr("Operating System")
Layout.fillWidth: true Layout.fillWidth: true
Layout.preferredHeight: 17 Layout.preferredHeight: 17
Layout.preferredWidth: 100
font.pixelSize: 12 font.pixelSize: 12
font.family: robotoBold.name font.family: robotoBold.name
font.bold: true font.bold: true
@ -171,7 +170,6 @@ ApplicationWindow {
text: qsTr("Storage") text: qsTr("Storage")
Layout.fillWidth: true Layout.fillWidth: true
Layout.preferredHeight: 17 Layout.preferredHeight: 17
Layout.preferredWidth: 100
font.pixelSize: 12 font.pixelSize: 12
font.family: robotoBold.name font.family: robotoBold.name
font.bold: true font.bold: true
@ -181,8 +179,12 @@ ApplicationWindow {
ImButton { ImButton {
id: dstbutton id: dstbutton
text: qsTr("CHOOSE STORAGE") text: qsTr("CHOOSE STORAGE")
spacing: 0
padding: 0
bottomPadding: 0
topPadding: 0
Layout.minimumHeight: 40 Layout.minimumHeight: 40
Layout.preferredWidth: 100 Layout.preferredWidth: 200
Layout.fillWidth: true Layout.fillWidth: true
onClicked: { onClicked: {
imageWriter.startDriveListPolling() imageWriter.startDriveListPolling()
@ -191,7 +193,7 @@ ApplicationWindow {
} }
Accessible.ignored: ospopup.visible || dstpopup.visible Accessible.ignored: ospopup.visible || dstpopup.visible
Accessible.description: qsTr("Select this button to change the destination storage device") Accessible.description: qsTr("Select this button to change the destination storage device")
} }
} }
ColumnLayout { ColumnLayout {