Browse Source

Adjust size and margins of the icon in the action button

Contributes to CURA-5876.
Diego Prado Gesto 6 years ago
parent
commit
ed8292c472

+ 3 - 2
resources/qml/ActionButton.qml

@@ -43,12 +43,13 @@ Button
 
     contentItem: Row
     {
+        spacing: UM.Theme.getSize("narrow_margin").width
         //Left side icon. Only displayed if !isIconOnRightSide.
         UM.RecolorImage
         {
             id: buttonIconLeft
             source: ""
-            height: buttonText.height
+            height: UM.Theme.getSize("action_button_icon").height
             width: visible ? height : 0
             sourceSize.width: width
             sourceSize.height: height
@@ -76,7 +77,7 @@ Button
         {
             id: buttonIconRight
             source: buttonIconLeft.source
-            height: buttonText.height
+            height: UM.Theme.getSize("action_button_icon").height
             width: visible ? height : 0
             sourceSize.width: width
             sourceSize.height: height

+ 1 - 1
resources/qml/Menus/ConfigurationMenu/CustomConfiguration.qml

@@ -60,7 +60,7 @@ Item
         {
             text: catalog.i18nc("@label", "Printer")
             width: Math.round(parent.width * 0.3) - UM.Theme.getSize("default_margin").width
-//            height: contentHeight
+            height: contentHeight
             font: UM.Theme.getFont("default")
             color: UM.Theme.getColor("text")
             anchors.verticalCenter: printerTypeSelector.verticalCenter

+ 1 - 0
resources/themes/cura-light/theme.json

@@ -407,6 +407,7 @@
         "button_lining": [0, 0],
 
         "action_button": [15.0, 3.0],
+        "action_button_icon": [1.0, 1.0],
         "action_button_radius": [0.15, 0.15],
 
         "small_button": [2, 2],