mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 17:15:56 +08:00
Disambiguate theme name
This commit is contained in:
parent
93197cd173
commit
f18947681a
@ -419,15 +419,15 @@ Rectangle
|
|||||||
{
|
{
|
||||||
if(toggleLeftTextMouseArea.containsMouse)
|
if(toggleLeftTextMouseArea.containsMouse)
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("toggle_button_text_hover");
|
return UM.Theme.getColor("mode_switch_text_hover");
|
||||||
}
|
}
|
||||||
else if(!modeToggleSwitch.checked)
|
else if(!modeToggleSwitch.checked)
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("toggle_button_text_checked");
|
return UM.Theme.getColor("mode_switch_text_checked");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("toggle_button_text");
|
return UM.Theme.getColor("mode_switch_text");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
font: UM.Theme.getFont("default")
|
font: UM.Theme.getFont("default")
|
||||||
@ -483,7 +483,7 @@ Rectangle
|
|||||||
UM.Preferences.setValue("cura/active_mode", index);
|
UM.Preferences.setValue("cura/active_mode", index);
|
||||||
}
|
}
|
||||||
|
|
||||||
style: UM.Theme.styles.toggle_button
|
style: UM.Theme.styles.mode_switch
|
||||||
}
|
}
|
||||||
|
|
||||||
Label
|
Label
|
||||||
@ -496,15 +496,15 @@ Rectangle
|
|||||||
{
|
{
|
||||||
if(toggleRightTextMouseArea.containsMouse)
|
if(toggleRightTextMouseArea.containsMouse)
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("toggle_button_text_hover");
|
return UM.Theme.getColor("mode_switch_text_hover");
|
||||||
}
|
}
|
||||||
else if(modeToggleSwitch.checked)
|
else if(modeToggleSwitch.checked)
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("toggle_button_text_checked");
|
return UM.Theme.getColor("mode_switch_text_checked");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("toggle_button_text");
|
return UM.Theme.getColor("mode_switch_text");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
font: UM.Theme.getFont("default")
|
font: UM.Theme.getFont("default")
|
||||||
|
@ -8,25 +8,25 @@ import QtQuick.Controls.Styles 1.1
|
|||||||
import UM 1.1 as UM
|
import UM 1.1 as UM
|
||||||
|
|
||||||
QtObject {
|
QtObject {
|
||||||
property Component toggle_button: Component {
|
property Component mode_switch: Component {
|
||||||
SwitchStyle {
|
SwitchStyle {
|
||||||
groove: Rectangle {
|
groove: Rectangle {
|
||||||
implicitWidth: UM.Theme.getSize("toggle_button").width
|
implicitWidth: UM.Theme.getSize("mode_switch").width
|
||||||
implicitHeight: UM.Theme.getSize("toggle_button").height
|
implicitHeight: UM.Theme.getSize("mode_switch").height
|
||||||
radius: implicitHeight / 2
|
radius: implicitHeight / 2
|
||||||
color: {
|
color: {
|
||||||
if(control.hovered || control._hovered) {
|
if(control.hovered || control._hovered) {
|
||||||
return UM.Theme.getColor("toggle_button_hover");
|
return UM.Theme.getColor("mode_switch_hover");
|
||||||
} else {
|
} else {
|
||||||
return UM.Theme.getColor("toggle_button");
|
return UM.Theme.getColor("mode_switch");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on color { ColorAnimation { duration: 50; } }
|
Behavior on color { ColorAnimation { duration: 50; } }
|
||||||
border.color: {
|
border.color: {
|
||||||
if(control.hovered || control._hovered) {
|
if(control.hovered || control._hovered) {
|
||||||
return UM.Theme.getColor("toggle_button_border_hover");
|
return UM.Theme.getColor("mode_switch_border_hover");
|
||||||
} else {
|
} else {
|
||||||
return UM.Theme.getColor("toggle_button_border");
|
return UM.Theme.getColor("mode_switch_border");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on border.color { ColorAnimation { duration: 50; } }
|
Behavior on border.color { ColorAnimation { duration: 50; } }
|
||||||
@ -35,7 +35,7 @@ QtObject {
|
|||||||
|
|
||||||
handle: Rectangle {
|
handle: Rectangle {
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
implicitHeight: UM.Theme.getSize("toggle_button").height
|
implicitHeight: UM.Theme.getSize("mode_switch").height
|
||||||
radius: implicitHeight / 2
|
radius: implicitHeight / 2
|
||||||
|
|
||||||
color: {
|
color: {
|
||||||
|
@ -175,14 +175,14 @@
|
|||||||
"checkbox_mark": [24, 41, 77, 255],
|
"checkbox_mark": [24, 41, 77, 255],
|
||||||
"checkbox_text": [24, 41, 77, 255],
|
"checkbox_text": [24, 41, 77, 255],
|
||||||
|
|
||||||
"toggle_button": [255, 255, 255, 255],
|
"mode_switch": [255, 255, 255, 255],
|
||||||
"toggle_button_hover": [255, 255, 255, 255],
|
"mode_switch_hover": [255, 255, 255, 255],
|
||||||
"toggle_button_border": [127, 127, 127, 255],
|
"mode_switch_border": [127, 127, 127, 255],
|
||||||
"toggle_button_border_hover": [12, 169, 227, 255],
|
"mode_switch_border_hover": [12, 169, 227, 255],
|
||||||
"toggle_button_handle": [24, 41, 77, 255],
|
"mode_switch_handle": [24, 41, 77, 255],
|
||||||
"toggle_button_text": [24, 41, 77, 255],
|
"mode_switch_text": [24, 41, 77, 255],
|
||||||
"toggle_button_text_hover": [24, 41, 77, 255],
|
"mode_switch_text_hover": [24, 41, 77, 255],
|
||||||
"toggle_button_text_checked": [12, 169, 227, 255],
|
"mode_switch_text_checked": [12, 169, 227, 255],
|
||||||
|
|
||||||
"tooltip": [12, 169, 227, 255],
|
"tooltip": [12, 169, 227, 255],
|
||||||
"tooltip_text": [255, 255, 255, 255],
|
"tooltip_text": [255, 255, 255, 255],
|
||||||
@ -310,7 +310,7 @@
|
|||||||
"layerview_row_spacing": [0.0, 0.5],
|
"layerview_row_spacing": [0.0, 0.5],
|
||||||
|
|
||||||
"checkbox": [2.0, 2.0],
|
"checkbox": [2.0, 2.0],
|
||||||
"toggle_button": [2.0, 1.0],
|
"mode_switch": [2.0, 1.0],
|
||||||
|
|
||||||
"tooltip": [20.0, 10.0],
|
"tooltip": [20.0, 10.0],
|
||||||
"tooltip_margins": [1.0, 1.0],
|
"tooltip_margins": [1.0, 1.0],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user