mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-16 07:36:02 +08:00
Theme advanced mode controls
Unify down-arrows
This commit is contained in:
parent
16bbcac4f8
commit
66782d41f7
@ -34,10 +34,11 @@ QtObject {
|
|||||||
elide: Text.ElideRight;
|
elide: Text.ElideRight;
|
||||||
anchors.left: parent.left;
|
anchors.left: parent.left;
|
||||||
anchors.leftMargin: UM.Theme.sizes.setting_unit_margin.width
|
anchors.leftMargin: UM.Theme.sizes.setting_unit_margin.width
|
||||||
anchors.right: separationLine.left;
|
anchors.right: downArrow.left;
|
||||||
anchors.verticalCenter: parent.verticalCenter;
|
anchors.verticalCenter: parent.verticalCenter;
|
||||||
font: UM.Theme.fonts.default
|
font: UM.Theme.fonts.default
|
||||||
}
|
}
|
||||||
|
/*
|
||||||
Rectangle{
|
Rectangle{
|
||||||
id: separationLine
|
id: separationLine
|
||||||
width: 1
|
width: 1
|
||||||
@ -48,6 +49,7 @@ QtObject {
|
|||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
z: parent.z + 1
|
z: parent.z + 1
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
label: Label{}
|
label: Label{}
|
||||||
}
|
}
|
||||||
@ -60,15 +62,12 @@ QtObject {
|
|||||||
implicitHeight: UM.Theme.sizes.button.height;
|
implicitHeight: UM.Theme.sizes.button.height;
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: tool_button_background
|
id: tool_button_background
|
||||||
anchors.top: parent.verticalCenter;
|
anchors.top: parent.bottom;
|
||||||
|
|
||||||
width: parent.width;
|
width: parent.width;
|
||||||
height: control.hovered ? parent.height / 2 + label.height : 0;
|
height: control.hovered ? label.height : 0;
|
||||||
Behavior on height { NumberAnimation { duration: 100; } }
|
Behavior on height { NumberAnimation { duration: 100; } }
|
||||||
|
|
||||||
opacity: control.hovered ? 1.0 : 0.0;
|
|
||||||
Behavior on opacity { NumberAnimation { duration: 100; } }
|
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
id: label
|
id: label
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
@ -159,17 +158,21 @@ QtObject {
|
|||||||
}
|
}
|
||||||
Behavior on color { ColorAnimation { duration: 50; } }
|
Behavior on color { ColorAnimation { duration: 50; } }
|
||||||
|
|
||||||
Label {
|
|
||||||
|
UM.RecolorImage {
|
||||||
id: tool_button_arrow
|
id: tool_button_arrow
|
||||||
opacity: !control.enabled ? 0.2 : 1.0
|
opacity: !control.enabled ? 0.2 : 1.0
|
||||||
anchors.right: parent.right;
|
anchors.right: parent.right;
|
||||||
anchors.rightMargin: (UM.Theme.sizes.button.width - UM.Theme.sizes.button_icon.width) / 4
|
anchors.rightMargin: (UM.Theme.sizes.button.width - UM.Theme.sizes.button_icon.width) / 4
|
||||||
anchors.bottom: parent.bottom;
|
anchors.bottom: parent.bottom;
|
||||||
anchors.bottomMargin: (UM.Theme.sizes.button.height - UM.Theme.sizes.button_icon.height) / 4
|
anchors.bottomMargin: (UM.Theme.sizes.button.height - UM.Theme.sizes.button_icon.height) / 4
|
||||||
text: "▼";
|
width: UM.Theme.sizes.standard_arrow.width
|
||||||
font: UM.Theme.fonts.small;
|
height: UM.Theme.sizes.standard_arrow.height
|
||||||
|
sourceSize.width: width
|
||||||
|
sourceSize.height: width
|
||||||
visible: control.menu != null;
|
visible: control.menu != null;
|
||||||
color: UM.Theme.colors.button_text
|
color: UM.Theme.colors.button_text
|
||||||
|
source: UM.Theme.icons.arrow_bottom
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -347,7 +350,7 @@ QtObject {
|
|||||||
sourceSize.width: width
|
sourceSize.width: width
|
||||||
sourceSize.height: width
|
sourceSize.height: width
|
||||||
color: UM.Theme.colors.setting_category_text
|
color: UM.Theme.colors.setting_category_text
|
||||||
source: control.checked ? UM.Theme.icons.arrow_top : UM.Theme.icons.arrow_bottom
|
source: control.checked ? UM.Theme.icons.arrow_bottom : UM.Theme.icons.arrow_right
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -389,6 +392,7 @@ QtObject {
|
|||||||
controlColor: UM.Theme.colors.setting_control;
|
controlColor: UM.Theme.colors.setting_control;
|
||||||
controlHighlightColor: UM.Theme.colors.setting_control_highlight;
|
controlHighlightColor: UM.Theme.colors.setting_control_highlight;
|
||||||
controlBorderColor: UM.Theme.colors.setting_control_border;
|
controlBorderColor: UM.Theme.colors.setting_control_border;
|
||||||
|
controlBorderHighlightColor: UM.Theme.colors.setting_control_border_highlight;
|
||||||
controlTextColor: UM.Theme.colors.setting_control_text;
|
controlTextColor: UM.Theme.colors.setting_control_text;
|
||||||
controlFont: UM.Theme.fonts.default;
|
controlFont: UM.Theme.fonts.default;
|
||||||
|
|
||||||
@ -411,8 +415,8 @@ QtObject {
|
|||||||
color: control.hovered ? UM.Theme.colors.checkbox_hover : UM.Theme.colors.checkbox;
|
color: control.hovered ? UM.Theme.colors.checkbox_hover : UM.Theme.colors.checkbox;
|
||||||
Behavior on color { ColorAnimation { duration: 50; } }
|
Behavior on color { ColorAnimation { duration: 50; } }
|
||||||
|
|
||||||
border.width: 1
|
border.width: UM.Theme.sizes.default_lining.width;
|
||||||
border.color: UM.Theme.colors.checkbox_border;
|
border.color: control.hovered ? UM.Theme.colors.checkbox_border_hover : UM.Theme.colors.checkbox_border;
|
||||||
|
|
||||||
UM.RecolorImage {
|
UM.RecolorImage {
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
@ -442,7 +446,7 @@ QtObject {
|
|||||||
implicitHeight: UM.Theme.sizes.slider_groove.height;
|
implicitHeight: UM.Theme.sizes.slider_groove.height;
|
||||||
|
|
||||||
color: UM.Theme.colors.slider_groove;
|
color: UM.Theme.colors.slider_groove;
|
||||||
border.width: 1;
|
border.width: UM.Theme.sizes.default_lining.width;
|
||||||
border.color: UM.Theme.colors.slider_groove_border;
|
border.color: UM.Theme.colors.slider_groove_border;
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
@ -516,7 +520,7 @@ QtObject {
|
|||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
implicitWidth: control.maxValue.length * valueLabel.font.pixelSize
|
implicitWidth: control.maxValue.length * valueLabel.font.pixelSize
|
||||||
implicitHeight: UM.Theme.sizes.slider_handle.height + UM.Theme.sizes.default_margin.width
|
implicitHeight: UM.Theme.sizes.slider_handle.height + UM.Theme.sizes.default_margin.width
|
||||||
border.width: 1;
|
border.width: UM.Theme.sizes.default_lining.width;
|
||||||
border.color: UM.Theme.colors.slider_groove_border;
|
border.color: UM.Theme.colors.slider_groove_border;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -535,8 +539,8 @@ QtObject {
|
|||||||
implicitHeight: control.height;
|
implicitHeight: control.height;
|
||||||
implicitWidth: control.width;
|
implicitWidth: control.width;
|
||||||
|
|
||||||
border.width: 1;
|
border.width: UM.Theme.sizes.default_lining.width;
|
||||||
border.color: UM.Theme.colors.setting_control_border;
|
border.color: control.hovered ? UM.Theme.colors.setting_control_border_highlight : UM.Theme.colors.setting_control_border;
|
||||||
|
|
||||||
color: UM.Theme.colors.setting_validation_ok;
|
color: UM.Theme.colors.setting_validation_ok;
|
||||||
|
|
||||||
|
@ -113,12 +113,11 @@
|
|||||||
"setting_category_text": [24, 41, 77, 255],
|
"setting_category_text": [24, 41, 77, 255],
|
||||||
|
|
||||||
"setting_control": [255, 255, 255, 255],
|
"setting_control": [255, 255, 255, 255],
|
||||||
"setting_control_highlight": [245, 245, 245, 255],
|
"setting_control_highlight": [255, 255, 255, 0],
|
||||||
"setting_control_border": [127, 127, 127, 255],
|
"setting_control_border": [127, 127, 127, 255],
|
||||||
"setting_control_text": [24,41,77, 255],
|
"setting_control_border_highlight": [12, 169, 227, 255],
|
||||||
|
"setting_control_text": [24, 41, 77, 255],
|
||||||
"setting_control_depth_line": [162, 192, 227, 255],
|
"setting_control_depth_line": [162, 192, 227, 255],
|
||||||
"setting_control_hover": [127, 127, 127, 255],
|
|
||||||
"setting_control_selected": [35, 35, 35, 255],
|
|
||||||
"setting_control_revert": [127, 127, 127, 255],
|
"setting_control_revert": [127, 127, 127, 255],
|
||||||
"setting_unit": [127, 127, 127, 255],
|
"setting_unit": [127, 127, 127, 255],
|
||||||
"setting_validation_error": [255, 57, 14, 255],
|
"setting_validation_error": [255, 57, 14, 255],
|
||||||
@ -136,8 +135,9 @@
|
|||||||
"slider_text_background": [255, 255, 255, 255],
|
"slider_text_background": [255, 255, 255, 255],
|
||||||
|
|
||||||
"checkbox": [255, 255, 255, 255],
|
"checkbox": [255, 255, 255, 255],
|
||||||
"checkbox_hover": [245, 245, 245, 255],
|
"checkbox_hover": [255, 255, 255, 255],
|
||||||
"checkbox_border": [127, 127, 127, 255],
|
"checkbox_border": [127, 127, 127, 255],
|
||||||
|
"checkbox_border_hover": [12, 169, 227, 255],
|
||||||
"checkbox_mark": [24, 41, 77, 255],
|
"checkbox_mark": [24, 41, 77, 255],
|
||||||
"checkbox_text": [24, 41, 77, 255],
|
"checkbox_text": [24, 41, 77, 255],
|
||||||
|
|
||||||
@ -182,7 +182,7 @@
|
|||||||
|
|
||||||
"standard_list_lineheight": [1.5, 1.5],
|
"standard_list_lineheight": [1.5, 1.5],
|
||||||
"standard_list_input": [20.0, 25.0],
|
"standard_list_input": [20.0, 25.0],
|
||||||
"standard_arrow": [0.6, 0.6],
|
"standard_arrow": [0.8, 0.8],
|
||||||
|
|
||||||
"button": [4, 4],
|
"button": [4, 4],
|
||||||
"button_icon": [3, 3],
|
"button_icon": [3, 3],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user