From afb29724ffcbd5c0e7cfaa75066dc899e3c4efd1 Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Tue, 25 Aug 2020 10:59:14 +0200 Subject: [PATCH] Give the machineButton selectors a fixed width This prevents them from popping out of the interface for certain languages --- resources/qml/PrinterSelector/MachineSelector.qml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/resources/qml/PrinterSelector/MachineSelector.qml b/resources/qml/PrinterSelector/MachineSelector.qml index 0907767eea..17bb80906a 100644 --- a/resources/qml/PrinterSelector/MachineSelector.qml +++ b/resources/qml/PrinterSelector/MachineSelector.qml @@ -238,7 +238,8 @@ Cura.ExpandablePopup text: catalog.i18nc("@button", "Add printer") // The maximum width of the button is half of the total space, minus the padding of the parent, the left // padding of the component and half the spacing because of the space between buttons. - maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - parent.padding - leftPadding - parent.spacing / 2 + fixedWidthMode: true + width: UM.Theme.getSize("machine_selector_widget_content").width / 2 - leftPadding onClicked: { toggleContent() @@ -252,9 +253,10 @@ Cura.ExpandablePopup leftPadding: UM.Theme.getSize("default_margin").width rightPadding: UM.Theme.getSize("default_margin").width text: catalog.i18nc("@button", "Manage printers") + fixedWidthMode: true // The maximum width of the button is half of the total space, minus the padding of the parent, the right // padding of the component and half the spacing because of the space between buttons. - maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - parent.padding - rightPadding - parent.spacing / 2 + width: UM.Theme.getSize("machine_selector_widget_content").width / 2 - leftPadding onClicked: { toggleContent()