Add a binding to react when the infill density changes in the custom panel

Also make the icon dinamic, that will change when the infill density changes.

Contributes to CURA-5941.
This commit is contained in:
Diego Prado Gesto 2018-12-02 13:40:41 +01:00
parent 4154ec2fe8
commit 1caccfb577
3 changed files with 44 additions and 128 deletions

View file

@ -532,7 +532,7 @@ QtObject
color: (control.hovered || control._hovered) ? Theme.getColor("checkbox_hover") : Theme.getColor("checkbox")
Behavior on color { ColorAnimation { duration: 50; } }
radius: control.exclusiveGroup ? Math.round(Theme.getSize("checkbox").width / 2) : 0
radius: control.exclusiveGroup ? Math.round(Theme.getSize("checkbox").width / 2) : UM.Theme.getSize("checkbox_radius").width
border.width: Theme.getSize("default_lining").width
border.color: (control.hovered || control._hovered) ? Theme.getColor("checkbox_border_hover") : Theme.getColor("checkbox_border")
@ -557,6 +557,7 @@ QtObject
color: Theme.getColor("checkbox_text")
font: Theme.getFont("default")
elide: Text.ElideRight
renderType: Text.NativeRendering
}
}
}

View file

@ -239,10 +239,10 @@
"checkbox": [255, 255, 255, 255],
"checkbox_hover": [255, 255, 255, 255],
"checkbox_border": [64, 69, 72, 255],
"checkbox_border": [199, 199, 199, 255],
"checkbox_border_hover": [50, 130, 255, 255],
"checkbox_mark": [119, 122, 124, 255],
"checkbox_text": [27, 27, 27, 255],
"checkbox_mark": [50, 130, 255, 255],
"checkbox_text": [35, 35, 35, 255],
"tooltip": [68, 192, 255, 255],
"tooltip_text": [255, 255, 255, 255],
@ -459,7 +459,8 @@
"layerview_row": [11.0, 1.5],
"layerview_row_spacing": [0.0, 0.5],
"checkbox": [2.0, 2.0],
"checkbox": [1.5, 1.5],
"checkbox_radius": [0.08, 0.08],
"tooltip": [20.0, 10.0],
"tooltip_margins": [1.0, 1.0],