mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-12-05 16:51:12 -07:00
Add swatches in extruder dropdown
This commit is contained in:
parent
19e74a2d45
commit
6480926869
1 changed files with 18 additions and 1 deletions
|
|
@ -141,7 +141,6 @@ SettingItem
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
popup: Popup {
|
popup: Popup {
|
||||||
y: control.height - UM.Theme.getSize("default_lining").height
|
y: control.height - UM.Theme.getSize("default_lining").height
|
||||||
width: control.width
|
width: control.width
|
||||||
|
|
@ -176,6 +175,24 @@ SettingItem
|
||||||
font: UM.Theme.getFont("default")
|
font: UM.Theme.getFont("default")
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
|
rightPadding: swatch.width + UM.Theme.getSize("setting_unit_margin").width
|
||||||
|
|
||||||
|
background: Rectangle
|
||||||
|
{
|
||||||
|
id: swatch
|
||||||
|
height: UM.Theme.getSize("setting_control").height / 2
|
||||||
|
width: height
|
||||||
|
|
||||||
|
anchors.right: parent.right
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
anchors.margins: UM.Theme.getSize("default_margin").width / 4
|
||||||
|
|
||||||
|
border.width: UM.Theme.getSize("default_lining").width
|
||||||
|
border.color: enabled ? UM.Theme.getColor("setting_control_border") : UM.Theme.getColor("setting_control_disabled_border")
|
||||||
|
radius: width / 2
|
||||||
|
|
||||||
|
color: control.model.getItem(index).color
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle
|
background: Rectangle
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue