From cd3d4dc80fa547a170e23e469c74512da147d67d Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Mon, 11 Sep 2017 16:58:07 +0200 Subject: [PATCH 01/20] CURA-4203 updated message style for light theme, add shadows --- resources/themes/cura-light/styles.qml | 1 - resources/themes/cura-light/theme.json | 25 ++++++++++++++----------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index bb2b57509a..fa04c92d60 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -385,7 +385,6 @@ QtObject { background: Rectangle { implicitWidth: Theme.getSize("message").width - (Theme.getSize("default_margin").width * 2) implicitHeight: Theme.getSize("progressbar").height - radius: Theme.getSize("progressbar_radius").width color: control.hasOwnProperty("backgroundColor") ? control.backgroundColor : Theme.getColor("progressbar_background") } progress: Rectangle { diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index d727425795..e8137cffa7 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -217,16 +217,17 @@ "tool_button_border": [39, 44, 48, 255], - "message_background": [24, 41, 77, 255], - "message_text": [255, 255, 255, 255], - "message_border": [24, 41, 77, 255], - "message_button": [255, 255, 255, 255], + + "message_background": [255, 255, 255, 255], + "message_shadow": [0, 0, 0, 120], + "message_text": [0, 0, 0, 255], + "message_button": [12, 169, 227, 255], "message_button_hover": [12, 169, 227, 255], - "message_button_active": [32, 166, 219, 255], - "message_button_text": [24, 41, 77, 255], + "message_button_active": [12, 169, 227, 255], + "message_button_text": [255, 255, 255, 255], "message_button_text_hover": [255, 255, 255, 255], "message_button_text_active": [255, 255, 255, 255], - "message_progressbar_background": [255, 255, 255, 255], + "message_progressbar_background": [200, 200, 200, 255], "message_progressbar_control": [12, 169, 227, 255], "tool_panel_background": [255, 255, 255, 255], @@ -332,9 +333,9 @@ "button_tooltip": [1.0, 1.3], "button_tooltip_arrow": [0.25, 0.25], - "progressbar": [26.0, 0.8], - "progressbar_radius": [0.4, 0.4], - "progressbar_control": [8.0, 0.8], + "progressbar": [26.0, 0.4], + "progressbar_radius": [0, 0], + "progressbar_control": [8.0, 0.4], "scrollbar": [0.75, 0.5], @@ -365,8 +366,10 @@ "wizard_progress": [10.0, 0.0], "message": [30.0, 5.0], - "message_close": [1.25, 1.25], + "message_close": [1, 1], "message_button": [6.0, 1.8], + "message_shadow": [0, 0], + "message_margin": [0, 1.0], "infill_button_margin": [0.5, 0.5], From 461d4be310237f359d1c0aa5f96922137f82ac49 Mon Sep 17 00:00:00 2001 From: fieldOfView Date: Mon, 11 Sep 2017 20:35:24 +0200 Subject: [PATCH 02/20] Fix hover state of Monitor button in the topbar --- resources/themes/cura-light/styles.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index bb2b57509a..f4d9aa6d59 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -107,7 +107,7 @@ QtObject { anchors.bottom: parent.bottom width: parent.width height: Theme.getSize("sidebar_header_highlight").height - color: control.checked ? UM.Theme.getColor("sidebar_header_highlight") : "transparent" + color: control.checked ? UM.Theme.getColor("sidebar_header_highlight") : UM.Theme.getColor("sidebar_header_highlight_hover") visible: control.hovered || control.checked } } From 1aa46045af7f4e83c30939a6c03a7ed0a00ccf53 Mon Sep 17 00:00:00 2001 From: Eloi Pardo Date: Tue, 12 Sep 2017 08:42:17 +0200 Subject: [PATCH 03/20] add ConvexHullDecorator when grouping --- cura/CuraApplication.py | 1 + 1 file changed, 1 insertion(+) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 1b7dafd53d..021f20fa82 100755 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -1182,6 +1182,7 @@ class CuraApplication(QtApplication): group_node = SceneNode() group_decorator = GroupDecorator() group_node.addDecorator(group_decorator) + group_node.addDecorator(ConvexHullDecorator()) group_node.setParent(self.getController().getScene().getRoot()) group_node.setSelectable(True) center = Selection.getSelectionCenter() From 4143effbe19ab5ae0c90fbb069e1c9c6e2f22772 Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 09:13:16 +0200 Subject: [PATCH 04/20] only show slider track when layers are available --- plugins/LayerView/LayerView.qml | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/LayerView/LayerView.qml b/plugins/LayerView/LayerView.qml index 092df3fb6e..1f04be77d3 100755 --- a/plugins/LayerView/LayerView.qml +++ b/plugins/LayerView/LayerView.qml @@ -418,6 +418,7 @@ Item color: parent.trackColor border.width: parent.trackBorderWidth; border.color: parent.trackBorderColor; + visible: slider.layersVisible } Item { From 670d1784c4b89d7bc35e60265f15d6159a50322c Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 09:45:45 +0200 Subject: [PATCH 05/20] Fix layer mode combobox hover not transparent --- resources/themes/cura-light/styles.qml | 2 +- resources/themes/cura-light/theme.json | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index 47274f99d9..8f2131bbfb 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -614,7 +614,7 @@ QtObject { implicitHeight: Theme.getSize("setting_control").height; implicitWidth: Theme.getSize("setting_control").width; - color: (control.hovered || control._hovered) ? Theme.getColor("setting_control_highlight") : Theme.getColor("setting_control"); + color: Theme.getColor("setting_control") Behavior on color { ColorAnimation { duration: 50; } } border.width: Theme.getSize("default_lining").width; diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index e8137cffa7..98afe76350 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -357,6 +357,7 @@ "tooltip_margins": [1.0, 1.0], "tooltip_arrow_margins": [2.0, 2.0], + "save_button_text_margin": [0.3, 0.6], "save_button_save_to_button": [0.3, 2.7], "save_button_specs_icons": [1.4, 1.4], From 7d719c4ab56b44aa13e3cc0b08c53e597b81bb92 Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 09:54:24 +0200 Subject: [PATCH 06/20] layer view toolbox height depending on color scheme mode --- plugins/LayerView/LayerView.qml | 2 ++ resources/themes/cura-light/theme.json | 1 + 2 files changed, 3 insertions(+) diff --git a/plugins/LayerView/LayerView.qml b/plugins/LayerView/LayerView.qml index 1f04be77d3..10a2b4c3cf 100755 --- a/plugins/LayerView/LayerView.qml +++ b/plugins/LayerView/LayerView.qml @@ -22,6 +22,8 @@ Item height: { if (UM.LayerView.compatibilityMode) { return UM.Theme.getSize("layerview_menu_size_compatibility").height; + } else if (UM.Preferences.getValue("layerview/layer_view_type") == 0) { + return UM.Theme.getSize("layerview_menu_size_material_color_mode").height + UM.LayerView.extruderCount * (UM.Theme.getSize("layerview_row").height + UM.Theme.getSize("layerview_row_spacing").height) } else { return UM.Theme.getSize("layerview_menu_size").height + UM.LayerView.extruderCount * (UM.Theme.getSize("layerview_row").height + UM.Theme.getSize("layerview_row_spacing").height) } diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index 98afe76350..3b98ac1ae4 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -346,6 +346,7 @@ "slider_layerview_margin": [1.0, 1.0], "layerview_menu_size": [15, 19.5], + "layerview_menu_size_material_color_mode": [15, 15.5], "layerview_menu_size_compatibility": [22, 22.0], "layerview_legend_size": [1.0, 1.0], "layerview_row": [11.0, 1.5], From 92617e217721be5ead45b5ec30040db88a3aa98c Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 10:15:08 +0200 Subject: [PATCH 07/20] remove layerview toolbox arrow --- plugins/LayerView/LayerView.qml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/plugins/LayerView/LayerView.qml b/plugins/LayerView/LayerView.qml index 10a2b4c3cf..8927d59017 100755 --- a/plugins/LayerView/LayerView.qml +++ b/plugins/LayerView/LayerView.qml @@ -28,6 +28,7 @@ Item return UM.Theme.getSize("layerview_menu_size").height + UM.LayerView.extruderCount * (UM.Theme.getSize("layerview_row").height + UM.Theme.getSize("layerview_row_spacing").height) } } + property var buttonTarget: { var force_binding = parent.y; // ensure this gets reevaluated when the panel moves return base.mapFromItem(parent.parent, parent.buttonTarget.x, parent.buttonTarget.y); @@ -45,9 +46,7 @@ Item color: UM.Theme.getColor("tool_panel_background") borderWidth: UM.Theme.getSize("default_lining").width borderColor: UM.Theme.getColor("lining") - - target: parent.buttonTarget - arrowSize: UM.Theme.getSize("default_arrow").width + arrowSize: 0 // hide arrow until weird issue with first time rendering is fixed ColumnLayout { id: view_settings From 8f2ee96f401ee3813aafde883de127bab88c5ba4 Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 10:27:07 +0200 Subject: [PATCH 08/20] CURA-4203 message progress bar color dark --- resources/themes/cura-light/theme.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index 3b98ac1ae4..f30026f172 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -217,7 +217,6 @@ "tool_button_border": [39, 44, 48, 255], - "message_background": [255, 255, 255, 255], "message_shadow": [0, 0, 0, 120], "message_text": [0, 0, 0, 255], @@ -228,7 +227,7 @@ "message_button_text_hover": [255, 255, 255, 255], "message_button_text_active": [255, 255, 255, 255], "message_progressbar_background": [200, 200, 200, 255], - "message_progressbar_control": [12, 169, 227, 255], + "message_progressbar_control": [77, 182, 226, 255], "tool_panel_background": [255, 255, 255, 255], From 3fe75d9c9523fcad4e723e6b85f6c36cb938ba21 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Tue, 12 Sep 2017 11:24:49 +0200 Subject: [PATCH 09/20] Update default values of new settings These settings have now been tested and good defaults have been found for them. --- resources/definitions/fdmprinter.def.json | 12 ++++++------ .../ultimaker3/um3_aa0.8_PP_Draft_Print.inst.cfg | 1 - .../um3_aa0.8_PP_Superdraft_Print.inst.cfg | 1 - .../ultimaker3/um3_aa0.8_PP_Verydraft_Print.inst.cfg | 1 - .../ultimaker3/um3_aa0.8_TPU_Draft_Print.inst.cfg | 1 - .../um3_aa0.8_TPU_Superdraft_Print.inst.cfg | 1 - .../um3_aa0.8_TPU_Verydraft_Print.inst.cfg | 1 - 7 files changed, 6 insertions(+), 12 deletions(-) diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 0e871ffad5..7694aaf3ef 100755 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -1234,7 +1234,7 @@ "random": "Random", "sharpest_corner": "Sharpest Corner" }, - "default_value": "shortest", + "default_value": "sharpest_corner", "limit_to_extruder": "wall_0_extruder_nr", "settable_per_mesh": true }, @@ -1539,6 +1539,7 @@ "unit": "mm", "type": "float", "default_value": 0, + "value": "wall_line_width_0 + (wall_line_count - 1) * wall_line_width_x", "minimum_value": "0", "limit_to_extruder": "top_bottom_extruder_nr", "settable_per_mesh": true, @@ -1575,7 +1576,7 @@ "label": "Expand Skins Into Infill", "description": "Expand skin areas of top and/or bottom skin of flat surfaces. By default, skins stop under the wall lines that surround infill but this can lead to holes appearing when the infill density is low. This setting extends the skins beyond the wall lines so that the infill on the next layer rests on skin.", "type": "bool", - "default_value": false, + "default_value": true, "limit_to_extruder": "top_bottom_extruder_nr", "settable_per_mesh": true, "children": @@ -1609,7 +1610,7 @@ "unit": "mm", "type": "float", "default_value": 2.8, - "value": "infill_line_distance * 1.4", + "value": "wall_line_width_0 + (wall_line_count - 1) * wall_line_width_x", "minimum_value": "0", "enabled": "expand_upper_skins or expand_lower_skins", "limit_to_extruder": "top_bottom_extruder_nr", @@ -1623,9 +1624,8 @@ "type": "float", "minimum_value": "0", "minimum_value_warning": "2", - "maximum_value_warning": "45", "maximum_value": "90", - "default_value": 20, + "default_value": 90, "enabled": "expand_upper_skins or expand_lower_skins", "limit_to_extruder": "top_bottom_extruder_nr", "settable_per_mesh": true, @@ -5157,7 +5157,7 @@ { "label": "Extra Skin Wall Count", "description": "Replaces the outermost part of the top/bottom pattern with a number of concentric lines. Using one or two lines improves roofs that start on infill material.", - "default_value": 0, + "default_value": 1, "minimum_value": "0", "maximum_value_warning": "10", "type": "int", diff --git a/resources/quality/ultimaker3/um3_aa0.8_PP_Draft_Print.inst.cfg b/resources/quality/ultimaker3/um3_aa0.8_PP_Draft_Print.inst.cfg index 8b85d6d7fb..2051888b08 100644 --- a/resources/quality/ultimaker3/um3_aa0.8_PP_Draft_Print.inst.cfg +++ b/resources/quality/ultimaker3/um3_aa0.8_PP_Draft_Print.inst.cfg @@ -14,7 +14,6 @@ setting_version = 2 brim_width = 25 cool_min_layer_time_fan_speed_max = 6 cool_min_speed = 17 -expand_skins_expand_distance = =line_width * 2 expand_upper_skins = True infill_before_walls = True infill_line_width = =round(line_width * 0.7 / 0.8, 2) diff --git a/resources/quality/ultimaker3/um3_aa0.8_PP_Superdraft_Print.inst.cfg b/resources/quality/ultimaker3/um3_aa0.8_PP_Superdraft_Print.inst.cfg index f1042df045..4a93260597 100644 --- a/resources/quality/ultimaker3/um3_aa0.8_PP_Superdraft_Print.inst.cfg +++ b/resources/quality/ultimaker3/um3_aa0.8_PP_Superdraft_Print.inst.cfg @@ -14,7 +14,6 @@ setting_version = 2 brim_width = 25 cool_min_layer_time_fan_speed_max = 6 cool_min_speed = 17 -expand_skins_expand_distance = =line_width * 2 expand_upper_skins = True infill_before_walls = True infill_line_width = =round(line_width * 0.7 / 0.8, 2) diff --git a/resources/quality/ultimaker3/um3_aa0.8_PP_Verydraft_Print.inst.cfg b/resources/quality/ultimaker3/um3_aa0.8_PP_Verydraft_Print.inst.cfg index 2ddb591127..3cf4d0a244 100644 --- a/resources/quality/ultimaker3/um3_aa0.8_PP_Verydraft_Print.inst.cfg +++ b/resources/quality/ultimaker3/um3_aa0.8_PP_Verydraft_Print.inst.cfg @@ -14,7 +14,6 @@ setting_version = 2 brim_width = 25 cool_min_layer_time_fan_speed_max = 6 cool_min_speed = 17 -expand_skins_expand_distance = =line_width * 2 expand_upper_skins = True infill_before_walls = True infill_line_width = =round(line_width * 0.7 / 0.8, 2) diff --git a/resources/quality/ultimaker3/um3_aa0.8_TPU_Draft_Print.inst.cfg b/resources/quality/ultimaker3/um3_aa0.8_TPU_Draft_Print.inst.cfg index 97deea6740..1b8d71a8f0 100644 --- a/resources/quality/ultimaker3/um3_aa0.8_TPU_Draft_Print.inst.cfg +++ b/resources/quality/ultimaker3/um3_aa0.8_TPU_Draft_Print.inst.cfg @@ -13,7 +13,6 @@ setting_version = 2 [values] brim_width = 8.75 cool_min_layer_time_fan_speed_max = 6 -expand_skins_expand_distance = =line_width * 2 expand_upper_skins = True gradual_infill_step_height = =4 * layer_height gradual_infill_steps = 5 diff --git a/resources/quality/ultimaker3/um3_aa0.8_TPU_Superdraft_Print.inst.cfg b/resources/quality/ultimaker3/um3_aa0.8_TPU_Superdraft_Print.inst.cfg index 7871f330cc..20bbe05e4a 100644 --- a/resources/quality/ultimaker3/um3_aa0.8_TPU_Superdraft_Print.inst.cfg +++ b/resources/quality/ultimaker3/um3_aa0.8_TPU_Superdraft_Print.inst.cfg @@ -13,7 +13,6 @@ setting_version = 2 [values] brim_width = 8.75 cool_min_layer_time_fan_speed_max = 6 -expand_skins_expand_distance = =line_width * 2 expand_upper_skins = True gradual_infill_step_height = =4 * layer_height gradual_infill_steps = 5 diff --git a/resources/quality/ultimaker3/um3_aa0.8_TPU_Verydraft_Print.inst.cfg b/resources/quality/ultimaker3/um3_aa0.8_TPU_Verydraft_Print.inst.cfg index 9da9e3945f..d8e5146dc6 100644 --- a/resources/quality/ultimaker3/um3_aa0.8_TPU_Verydraft_Print.inst.cfg +++ b/resources/quality/ultimaker3/um3_aa0.8_TPU_Verydraft_Print.inst.cfg @@ -13,7 +13,6 @@ setting_version = 2 [values] brim_width = 8.75 cool_min_layer_time_fan_speed_max = 6 -expand_skins_expand_distance = =line_width * 2 expand_upper_skins = True gradual_infill_step_height = =4 * layer_height gradual_infill_steps = 5 From 14e10c698735d90971cb8a01cfe08acbfe6cfdc8 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Tue, 12 Sep 2017 11:27:35 +0200 Subject: [PATCH 10/20] Move skin extra wall count from experimental to shell category Nobody sees any risk in this. --- resources/definitions/fdmprinter.def.json | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 7694aaf3ef..f37e9ffdb4 100755 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -1298,6 +1298,17 @@ "default_value": true, "limit_to_extruder": "top_bottom_extruder_nr", "settable_per_mesh": true + }, + "skin_outline_count": + { + "label": "Extra Skin Wall Count", + "description": "Replaces the outermost part of the top/bottom pattern with a number of concentric lines. Using one or two lines improves roofs that start on infill material.", + "default_value": 1, + "minimum_value": "0", + "maximum_value_warning": "10", + "type": "int", + "limit_to_extruder": "top_bottom_extruder_nr", + "settable_per_mesh": true } } }, @@ -5153,17 +5164,6 @@ "settable_per_mesh": false, "settable_per_extruder": true }, - "skin_outline_count": - { - "label": "Extra Skin Wall Count", - "description": "Replaces the outermost part of the top/bottom pattern with a number of concentric lines. Using one or two lines improves roofs that start on infill material.", - "default_value": 1, - "minimum_value": "0", - "maximum_value_warning": "10", - "type": "int", - "limit_to_extruder": "top_bottom_extruder_nr", - "settable_per_mesh": true - }, "skin_alternate_rotation": { "label": "Alternate Skin Rotation", From 9e62c4db15f9b335f577efd454a258ffabd415fe Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 11:39:48 +0200 Subject: [PATCH 11/20] CURA-4318 remove active printer hover underline, theme inheritance, theme names --- resources/qml/Topbar.qml | 12 - resources/themes/cura-dark/theme.json | 200 ++++++++++++++++- resources/themes/cura-light/theme.json | 2 +- resources/themes/cura/theme.json | 291 ------------------------- 4 files changed, 197 insertions(+), 308 deletions(-) delete mode 100644 resources/themes/cura/theme.json diff --git a/resources/qml/Topbar.qml b/resources/qml/Topbar.qml index 930cc7c4bf..e3550aaad7 100644 --- a/resources/qml/Topbar.qml +++ b/resources/qml/Topbar.qml @@ -156,18 +156,6 @@ Rectangle } Behavior on color { ColorAnimation { duration: 50; } } - Rectangle - { - id: underline; - - anchors.left: parent.left - anchors.right: parent.right - anchors.bottom: parent.bottom - height: UM.Theme.getSize("sidebar_header_highlight").height - color: UM.Theme.getColor("sidebar_header_highlight_hover") - visible: control.hovered || control.pressed - } - UM.RecolorImage { id: downArrow diff --git a/resources/themes/cura-dark/theme.json b/resources/themes/cura-dark/theme.json index 45b8fd8675..dbe19bd298 100644 --- a/resources/themes/cura-dark/theme.json +++ b/resources/themes/cura-dark/theme.json @@ -1,11 +1,203 @@ { "metadata": { - "name": "Dark", - "inherits": "cura" + "name": "Ultimaker Dark", + "inherits": "cura-light" }, "colors": { - "viewport_background": [31, 36, 39, 255], + + "sidebar": [39, 44, 48, 255], + "lining": [64, 69, 72, 255], + "viewport_overlay": [0, 6, 9, 222], + + "primary": [12, 169, 227, 255], + "primary_hover": [48, 182, 231, 255], + "primary_text": [255, 255, 255, 204], + "border": [127, 127, 127, 255], + "secondary": [241, 242, 242, 255], + + "text": [255, 255, 255, 204], + "text_detail": [255, 255, 255, 172], + "text_link": [255, 255, 255, 127], + "text_inactive": [255, 255, 255, 88], + "text_hover": [255, 255, 255, 204], + "text_pressed": [255, 255, 255, 204], + "text_subtext": [255, 255, 255, 172], + "text_emphasis": [255, 255, 255, 255], "text_scene": [255, 255, 255, 162], - "text_scene_hover": [255, 255, 255, 204] + "text_scene_hover": [255, 255, 255, 204], + + "error": [212, 31, 53, 255], + "sidebar_header_bar": [39, 44, 48, 255], + "sidebar_header_active": [39, 44, 48, 255], + "sidebar_header_hover": [39, 44, 48, 255], + "sidebar_header_highlight": [68, 192, 255, 255], + "sidebar_header_highlight_hover": [68, 192, 255, 255], + "sidebar_header_text_active": [255, 255, 255, 255], + "sidebar_header_text_hover": [255, 255, 255, 255], + "sidebar_header_text_inactive": [255, 255, 255, 127], + "sidebar_lining": [31, 36, 39, 255], + + "button": [39, 44, 48, 255], + "button_hover": [39, 44, 48, 255], + "button_active": [67, 72, 75, 255], + "button_active_hover": [67, 72, 75, 255], + "button_text": [255, 255, 255, 197], + "button_text_hover": [255, 255, 255, 255], + "button_text_active": [255, 255, 255, 255], + "button_text_active_hover": [255, 255, 255, 255], + "button_disabled": [39, 44, 48, 255], + "button_disabled_text": [255, 255, 255, 101], + + "button_tooltip": [39, 44, 48, 255], + "button_tooltip_border": [39, 44, 48, 255], + "button_tooltip_text": [255, 255, 255, 172], + + "tab_checked": [39, 44, 48, 255], + "tab_checked_border": [255, 255, 255, 30], + "tab_checked_text": [255, 255, 255, 255], + "tab_unchecked": [39, 44, 48, 255], + "tab_unchecked_border": [255, 255, 255, 30], + "tab_unchecked_text": [255, 255, 255, 101], + "tab_hovered": [39, 44, 48, 255], + "tab_hovered_border": [255, 255, 255, 30], + "tab_hovered_text": [255, 255, 255, 255], + "tab_active": [39, 44, 48, 255], + "tab_active_border": [255, 255, 255, 30], + "tab_active_text": [255, 255, 255, 255], + "tab_background": [39, 44, 48, 255], + + "action_button": [39, 44, 48, 255], + "action_button_text": [255, 255, 255, 101], + "action_button_border": [255, 255, 255, 30], + "action_button_hovered": [39, 44, 48, 255], + "action_button_hovered_text": [255, 255, 255, 255], + "action_button_hovered_border": [255, 255, 255, 30], + "action_button_active": [39, 44, 48, 30], + "action_button_active_text": [255, 255, 255, 255], + "action_button_active_border": [255, 255, 255, 30], + "action_button_disabled": [39, 44, 48, 255], + "action_button_disabled_text": [255, 255, 255, 101], + "action_button_disabled_border": [255, 255, 255, 30], + + "scrollbar_background": [39, 44, 48, 0], + "scrollbar_handle": [255, 255, 255, 105], + "scrollbar_handle_hover": [255, 255, 255, 255], + "scrollbar_handle_down": [255, 255, 255, 255], + + "setting_category": [39, 44, 48, 255], + "setting_category_disabled": [39, 44, 48, 255], + "setting_category_hover": [39, 44, 48, 255], + "setting_category_active": [39, 44, 48, 255], + "setting_category_active_hover": [39, 44, 48, 255], + "setting_category_text": [255, 255, 255, 152], + "setting_category_disabled_text": [255, 255, 255, 101], + "setting_category_hover_text": [255, 255, 255, 204], + "setting_category_active_text": [255, 255, 255, 204], + "setting_category_active_hover_text": [255, 255, 255, 204], + "setting_category_border": [39, 44, 48, 0], + "setting_category_disabled_border": [39, 44, 48, 0], + "setting_category_hover_border": [39, 44, 48, 0], + "setting_category_active_border": [39, 44, 48, 0], + "setting_category_active_hover_border": [39, 44, 48, 0], + + "setting_control": [43, 48, 52, 255], + "setting_control_selected": [34, 39, 42, 38], + "setting_control_highlight": [255, 255, 255, 0], + "setting_control_border": [255, 255, 255, 38], + "setting_control_border_highlight": [255, 255, 255, 38], + "setting_control_text": [255, 255, 255, 181], + "setting_control_button": [255, 255, 255, 127], + "setting_control_button_hover": [255, 255, 255, 204], + "setting_control_disabled": [34, 39, 42, 255], + "setting_control_disabled_text": [255, 255, 255, 101], + "setting_control_disabled_border": [255, 255, 255, 101], + "setting_unit": [255, 255, 255, 127], + "setting_validation_error_background": [59, 31, 53, 255], + "setting_validation_error": [212, 31, 53, 255], + "setting_validation_warning_background": [62, 54, 46, 255], + "setting_validation_warning": [245, 166, 35, 255], + "setting_validation_ok": [43, 48, 52, 255], + + "progressbar_background": [255, 255, 255, 48], + "progressbar_control": [255, 255, 255, 197], + + "slider_groove": [39, 44, 48, 75], + "slider_groove_border": [39, 44, 48, 0], + "slider_groove_fill": [39, 44, 48, 182], + "slider_handle": [255, 255, 255, 255], + "slider_handle_border": [39, 44, 48, 255], + "slider_handle_hover": [255, 255, 255, 255], + "slider_handle_hover_border": [39, 44, 48, 255], + "slider_text_background": [39, 44, 48, 255], + + "checkbox": [43, 48, 52, 255], + "checkbox_hover": [43, 48, 52, 255], + "checkbox_border": [255, 255, 255, 38], + "checkbox_border_hover": [255, 255, 255, 38], + "checkbox_mark": [255, 255, 255, 181], + "checkbox_text": [255, 255, 255, 181], + + "tooltip": [39, 44, 48, 255], + "tooltip_text": [255, 255, 255, 204], + + "message_background": [255, 255, 255, 200], + "message_text": [0, 0, 0, 255], + "message_border": [191, 191, 191, 200], + "message_button": [255, 255, 255, 255], + "message_button_hover": [12, 169, 227, 255], + "message_button_active": [32, 166, 219, 255], + "message_button_text": [24, 41, 77, 255], + "message_button_text_hover": [255, 255, 255, 255], + "message_button_text_active": [255, 255, 255, 255], + "message_progressbar_background": [255, 255, 255, 255], + "message_progressbar_control": [12, 169, 227, 255], + + "tool_panel_background": [39, 44, 48, 255], + + "status_offline": [0, 0, 0, 255], + "status_ready": [0, 205, 0, 255], + "status_busy": [12, 169, 227, 255], + "status_paused": [255, 140, 0, 255], + "status_stopped": [236, 82, 80, 255], + "status_unknown": [127, 127, 127, 255], + + "disabled_axis": [127, 127, 127, 255], + "x_axis": [255, 0, 0, 255], + "y_axis": [0, 0, 255, 255], + "z_axis": [0, 255, 0, 255], + "all_axis": [255, 255, 255, 255], + + "viewport_background": [31, 36, 39, 255], + "volume_outline": [1, 168, 230, 255], + "buildplate": [252, 252, 252, 255], + "buildplate_alt": [204, 204, 204, 255], + "buildplate_grid": [129, 131, 134, 255], + "buildplate_grid_minor": [129, 131, 134, 31], + + "convex_hull": [35, 35, 35, 127], + "disallowed_area": [0, 0, 0, 52], + "error_area": [255, 0, 0, 127], + + "model_default": [255, 201, 36, 255], + "model_overhang": [255, 0, 0, 255], + "model_unslicable": [122, 122, 122, 255], + "model_unslicable_alt": [172, 172, 127, 255], + "model_selection_outline": [12, 169, 227, 255], + + "xray": [26, 26, 62, 255], + "xray_error": [255, 0, 0, 255], + + "layerview_ghost": [32, 32, 32, 96], + "layerview_none": [255, 255, 255, 255], + "layerview_inset_0": [255, 0, 0, 255], + "layerview_inset_x": [0, 255, 0, 255], + "layerview_skin": [255, 255, 0, 255], + "layerview_support": [0, 255, 255, 255], + "layerview_skirt": [0, 255, 255, 255], + "layerview_infill": [255, 192, 0, 255], + "layerview_support_infill": [0, 255, 255, 255], + "layerview_move_combing": [0, 0, 255, 255], + "layerview_move_retraction": [128, 128, 255, 255], + "layerview_support_interface": [64, 192, 255, 255] } } diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index f30026f172..b00050c14c 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -1,6 +1,6 @@ { "metadata": { - "name": "Light" + "name": "Ultimaker" }, "fonts": { diff --git a/resources/themes/cura/theme.json b/resources/themes/cura/theme.json deleted file mode 100644 index 46da3cbe7a..0000000000 --- a/resources/themes/cura/theme.json +++ /dev/null @@ -1,291 +0,0 @@ -{ - "metadata": { - "name": "Ultimaker", - "inherits": "cura-light" - }, - - "colors": { - "sidebar": [39, 44, 48, 255], - "lining": [64, 69, 72, 255], - "viewport_overlay": [0, 6, 9, 222], - - "primary": [12, 169, 227, 255], - "primary_hover": [48, 182, 231, 255], - "primary_text": [255, 255, 255, 204], - "border": [127, 127, 127, 255], - "secondary": [241, 242, 242, 255], - - "text": [255, 255, 255, 204], - "text_detail": [255, 255, 255, 172], - "text_link": [255, 255, 255, 127], - "text_inactive": [255, 255, 255, 88], - "text_hover": [255, 255, 255, 204], - "text_pressed": [255, 255, 255, 204], - "text_subtext": [255, 255, 255, 172], - "text_emphasis": [255, 255, 255, 255], - "text_scene": [39, 44, 48, 255], - "text_scene_hover": [43, 48, 52, 255], - - "error": [212, 31, 53, 255], - "sidebar_header_bar": [39, 44, 48, 255], - "sidebar_header_active": [39, 44, 48, 255], - "sidebar_header_hover": [39, 44, 48, 255], - "sidebar_header_highlight": [68, 192, 255, 255], - "sidebar_header_highlight_hover": [68, 192, 255, 255], - "sidebar_header_text_active": [255, 255, 255, 255], - "sidebar_header_text_hover": [255, 255, 255, 255], - "sidebar_header_text_inactive": [255, 255, 255, 127], - "sidebar_lining": [31, 36, 39, 255], - - "button": [39, 44, 48, 255], - "button_hover": [39, 44, 48, 255], - "button_active": [67, 72, 75, 255], - "button_active_hover": [67, 72, 75, 255], - "button_text": [255, 255, 255, 197], - "button_text_hover": [255, 255, 255, 255], - "button_text_active": [255, 255, 255, 255], - "button_text_active_hover": [255, 255, 255, 255], - "button_disabled": [39, 44, 48, 255], - "button_disabled_text": [255, 255, 255, 101], - - "button_tooltip": [39, 44, 48, 255], - "button_tooltip_border": [39, 44, 48, 255], - "button_tooltip_text": [255, 255, 255, 172], - - "tab_checked": [39, 44, 48, 255], - "tab_checked_border": [255, 255, 255, 30], - "tab_checked_text": [255, 255, 255, 255], - "tab_unchecked": [39, 44, 48, 255], - "tab_unchecked_border": [255, 255, 255, 30], - "tab_unchecked_text": [255, 255, 255, 101], - "tab_hovered": [39, 44, 48, 255], - "tab_hovered_border": [255, 255, 255, 30], - "tab_hovered_text": [255, 255, 255, 255], - "tab_active": [39, 44, 48, 255], - "tab_active_border": [255, 255, 255, 30], - "tab_active_text": [255, 255, 255, 255], - "tab_background": [39, 44, 48, 255], - - "action_button": [39, 44, 48, 255], - "action_button_text": [255, 255, 255, 101], - "action_button_border": [255, 255, 255, 30], - "action_button_hovered": [39, 44, 48, 255], - "action_button_hovered_text": [255, 255, 255, 255], - "action_button_hovered_border": [255, 255, 255, 30], - "action_button_active": [39, 44, 48, 30], - "action_button_active_text": [255, 255, 255, 255], - "action_button_active_border": [255, 255, 255, 30], - "action_button_disabled": [39, 44, 48, 255], - "action_button_disabled_text": [255, 255, 255, 101], - "action_button_disabled_border": [255, 255, 255, 30], - - "scrollbar_background": [39, 44, 48, 0], - "scrollbar_handle": [255, 255, 255, 105], - "scrollbar_handle_hover": [255, 255, 255, 255], - "scrollbar_handle_down": [255, 255, 255, 255], - - "setting_category": [39, 44, 48, 255], - "setting_category_disabled": [39, 44, 48, 255], - "setting_category_hover": [39, 44, 48, 255], - "setting_category_active": [39, 44, 48, 255], - "setting_category_active_hover": [39, 44, 48, 255], - "setting_category_text": [255, 255, 255, 152], - "setting_category_disabled_text": [255, 255, 255, 101], - "setting_category_hover_text": [255, 255, 255, 204], - "setting_category_active_text": [255, 255, 255, 204], - "setting_category_active_hover_text": [255, 255, 255, 204], - "setting_category_border": [39, 44, 48, 0], - "setting_category_disabled_border": [39, 44, 48, 0], - "setting_category_hover_border": [39, 44, 48, 0], - "setting_category_active_border": [39, 44, 48, 0], - "setting_category_active_hover_border": [39, 44, 48, 0], - - "setting_control": [43, 48, 52, 255], - "setting_control_selected": [34, 39, 42, 38], - "setting_control_highlight": [255, 255, 255, 0], - "setting_control_border": [255, 255, 255, 38], - "setting_control_border_highlight": [255, 255, 255, 38], - "setting_control_text": [255, 255, 255, 181], - "setting_control_button": [255, 255, 255, 127], - "setting_control_button_hover": [255, 255, 255, 204], - "setting_control_disabled": [34, 39, 42, 255], - "setting_control_disabled_text": [255, 255, 255, 101], - "setting_control_disabled_border": [255, 255, 255, 101], - "setting_unit": [255, 255, 255, 127], - "setting_validation_error_background": [59, 31, 53, 255], - "setting_validation_error": [212, 31, 53, 255], - "setting_validation_warning_background": [62, 54, 46, 255], - "setting_validation_warning": [245, 166, 35, 255], - "setting_validation_ok": [43, 48, 52, 255], - - "progressbar_background": [255, 255, 255, 48], - "progressbar_control": [255, 255, 255, 197], - - "slider_groove": [39, 44, 48, 75], - "slider_groove_border": [39, 44, 48, 0], - "slider_groove_fill": [39, 44, 48, 182], - "slider_handle": [255, 255, 255, 255], - "slider_handle_border": [39, 44, 48, 255], - "slider_handle_hover": [255, 255, 255, 255], - "slider_handle_hover_border": [39, 44, 48, 255], - "slider_text_background": [39, 44, 48, 255], - - "checkbox": [43, 48, 52, 255], - "checkbox_hover": [43, 48, 52, 255], - "checkbox_border": [255, 255, 255, 38], - "checkbox_border_hover": [255, 255, 255, 38], - "checkbox_mark": [255, 255, 255, 181], - "checkbox_text": [255, 255, 255, 181], - - "tooltip": [39, 44, 48, 255], - "tooltip_text": [255, 255, 255, 204], - - "message_background": [255, 255, 255, 200], - "message_text": [0, 0, 0, 255], - "message_border": [191, 191, 191, 200], - "message_button": [255, 255, 255, 255], - "message_button_hover": [12, 169, 227, 255], - "message_button_active": [32, 166, 219, 255], - "message_button_text": [24, 41, 77, 255], - "message_button_text_hover": [255, 255, 255, 255], - "message_button_text_active": [255, 255, 255, 255], - "message_progressbar_background": [255, 255, 255, 255], - "message_progressbar_control": [12, 169, 227, 255], - - "tool_panel_background": [39, 44, 48, 255], - - "status_offline": [0, 0, 0, 255], - "status_ready": [0, 205, 0, 255], - "status_busy": [12, 169, 227, 255], - "status_paused": [255, 140, 0, 255], - "status_stopped": [236, 82, 80, 255], - "status_unknown": [127, 127, 127, 255], - - "disabled_axis": [127, 127, 127, 255], - "x_axis": [255, 0, 0, 255], - "y_axis": [0, 0, 255, 255], - "z_axis": [0, 255, 0, 255], - "all_axis": [255, 255, 255, 255], - - "viewport_background": [241, 242, 242, 255], - "volume_outline": [1, 168, 230, 255], - "buildplate": [252, 252, 252, 255], - "buildplate_alt": [204, 204, 204, 255], - "buildplate_grid": [129, 131, 134, 255], - "buildplate_grid_minor": [129, 131, 134, 31], - - "convex_hull": [35, 35, 35, 127], - "disallowed_area": [0, 0, 0, 52], - "error_area": [255, 0, 0, 127], - - "model_default": [255, 201, 36, 255], - "model_overhang": [255, 0, 0, 255], - "model_unslicable": [122, 122, 122, 255], - "model_unslicable_alt": [172, 172, 127, 255], - "model_selection_outline": [12, 169, 227, 255], - - "xray": [26, 26, 62, 255], - "xray_error": [255, 0, 0, 255], - - "layerview_ghost": [32, 32, 32, 96], - "layerview_none": [255, 255, 255, 255], - "layerview_inset_0": [255, 0, 0, 255], - "layerview_inset_x": [0, 255, 0, 255], - "layerview_skin": [255, 255, 0, 255], - "layerview_support": [0, 255, 255, 255], - "layerview_skirt": [0, 255, 255, 255], - "layerview_infill": [255, 192, 0, 255], - "layerview_support_infill": [0, 255, 255, 255], - "layerview_move_combing": [0, 0, 255, 255], - "layerview_move_retraction": [128, 128, 255, 255], - "layerview_support_interface": [64, 192, 255, 255] - }, - - "sizes": { - "window_minimum_size": [70, 50], - "window_margin": [1.0, 1.0], - "default_margin": [1.0, 1.0], - "default_lining": [0.08, 0.08], - "default_arrow": [0.8, 0.8], - "logo": [9.5, 2.0], - - "sidebar": [35.0, 10.0], - "sidebar_header": [0.0, 4.0], - "sidebar_header_highlight": [0.25, 0.25], - "sidebar_header_mode_toggle": [0.0, 2.0], - "sidebar_header_mode_tabs": [0.0, 3.0], - "sidebar_lining": [0.5, 0.5], - "sidebar_lining_thin": [0.2, 0.2], - "sidebar_setup": [0.0, 2.0], - "sidebar_tabs": [0.0, 3.5], - "sidebar_inputfields": [0.0, 2.0], - "sidebar_extruder_box": [0.0, 6.0], - "simple_mode_infill_caption": [0.0, 5.0], - "simple_mode_infill_height": [0.0, 8.0], - - "section": [0.0, 2.0], - "section_icon": [1.6, 1.6], - "section_icon_column": [2.8, 0.0], - - "setting": [25.0, 1.8], - "setting_control": [10.0, 2.0], - "setting_control_depth_margin": [1.4, 0.0], - "setting_preferences_button_margin": [3.3, 0.0], - "setting_control_margin": [0.0, 0.0], - "setting_unit_margin": [0.5, 0.5], - "setting_text_maxwidth": [40.0, 0.0], - - "standard_list_lineheight": [1.5, 1.5], - "standard_list_input": [20.0, 25.0], - "standard_arrow": [0.8, 0.8], - - "button": [4, 4], - "button_icon": [2.5, 2.5], - "button_lining": [0, 0], - - "topbar_button": [8, 4], - - "button_tooltip": [1.0, 1.3], - "button_tooltip_arrow": [0.25, 0.25], - - "progressbar": [26.0, 0.8], - "progressbar_radius": [0.4, 0.4], - "progressbar_control": [8.0, 0.8], - - "scrollbar": [0.75, 0.5], - - "slider_groove": [0.5, 0.5], - "slider_handle": [1.5, 1.5], - "slider_layerview_size": [1.0, 22.0], - "slider_layerview_background": [4.0, 0.0], - "slider_layerview_margin": [1.0, 1.0], - - "layerview_menu_size": [16.5, 21.0], - "layerview_menu_size_compatibility": [22, 23.0], - "layerview_legend_size": [1.0, 1.0], - "layerview_row": [11.0, 1.5], - "layerview_row_spacing": [0.0, 0.5], - - "checkbox": [2.0, 2.0], - "mode_switch": [2.0, 1.0], - - "tooltip": [20.0, 10.0], - "tooltip_margins": [1.0, 1.0], - "tooltip_arrow_margins": [2.0, 2.0], - - "save_button_text_margin": [0.3, 0.6], - "save_button_save_to_button": [0.3, 2.7], - "save_button_specs_icons": [1.4, 1.4], - - "modal_window_minimum": [60.0, 45], - "wizard_progress": [10.0, 0.0], - - "message": [30.0, 5.0], - "message_close": [1.25, 1.25], - "message_button": [6.0, 1.8], - - "infill_button_margin": [0.5, 0.5], - - "jobspecs_line": [2.0, 2.0] - } -} From 1070e99ec2b7bf30af9dcaedfcbb2ac29f5dff0a Mon Sep 17 00:00:00 2001 From: Lipu Fei Date: Tue, 12 Sep 2017 11:51:04 +0200 Subject: [PATCH 12/20] Add message_border back CURA-4203 Sadly QtGraphicalEffects is not available in Qt 5.8, so we have to use the less fancy border for message boxes. --- resources/themes/cura-light/theme.json | 1 + 1 file changed, 1 insertion(+) diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index f30026f172..431c5b44e3 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -219,6 +219,7 @@ "message_background": [255, 255, 255, 255], "message_shadow": [0, 0, 0, 120], + "message_border": [127, 127, 127, 255], "message_text": [0, 0, 0, 255], "message_button": [12, 169, 227, 255], "message_button_hover": [12, 169, 227, 255], From 3f60bc9287501df4f89bfade395f60d3f854316f Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 11:59:21 +0200 Subject: [PATCH 13/20] Cleanup combobox styling --- resources/themes/cura-light/styles.qml | 23 ++++++----------------- resources/themes/cura-light/theme.json | 2 +- 2 files changed, 7 insertions(+), 18 deletions(-) diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index 8f2131bbfb..049c2b547c 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -614,7 +614,7 @@ QtObject { implicitHeight: Theme.getSize("setting_control").height; implicitWidth: Theme.getSize("setting_control").width; - color: Theme.getColor("setting_control") + color: (control.hovered || controler._hovered) ? UM.Theme.getColor("setting_control_highlight") : UM.Theme.getColor("setting_control") Behavior on color { ColorAnimation { duration: 50; } } border.width: Theme.getSize("default_lining").width; @@ -660,24 +660,11 @@ QtObject { { background: Rectangle { - color: - { - if(!enabled) - { - return UM.Theme.getColor("setting_control_disabled"); - } - if(control.hovered) - { - return UM.Theme.getColor("setting_control_highlight"); - } - else - { - return UM.Theme.getColor("setting_control"); - } - } + color: !enabled ? UM.Theme.getColor("setting_control_disabled") : (control.hovered || controler._hovered) ? UM.Theme.getColor("setting_control_highlight") : UM.Theme.getColor("setting_control") border.width: UM.Theme.getSize("default_lining").width - border.color: !enabled ? UM.Theme.getColor("setting_control_disabled_border") : control.hovered ? UM.Theme.getColor("setting_control_border_highlight") : UM.Theme.getColor("setting_control_border") + border.color: !enabled ? UM.Theme.getColor("setting_control_disabled_border") : (control.hovered || control._hovered) ? UM.Theme.getColor("setting_control_border_highlight") : UM.Theme.getColor("setting_control_border") } + label: Item { Label @@ -695,6 +682,7 @@ QtObject { elide: Text.ElideRight verticalAlignment: Text.AlignVCenter } + Rectangle { id: swatch @@ -714,6 +702,7 @@ QtObject { color: if (control.color_override != "") {return control.color_override} else {return control.color;} } + UM.RecolorImage { id: downArrow diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index b00050c14c..c8cd70ff2f 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -166,7 +166,7 @@ "setting_control": [255, 255, 255, 255], "setting_control_selected": [24, 41, 77, 255], - "setting_control_highlight": [255, 255, 255, 0], + "setting_control_highlight": [255, 255, 255, 255], "setting_control_border": [127, 127, 127, 255], "setting_control_border_highlight": [12, 169, 227, 255], "setting_control_text": [27, 27, 27, 255], From 073c2d3335d91c2c8427340efcb39829edb330c1 Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 12:11:23 +0200 Subject: [PATCH 14/20] style and code improvements for combobox with color swatch --- resources/qml/SidebarSimple.qml | 36 +++++--------------------- resources/themes/cura-light/styles.qml | 29 ++++++++++----------- 2 files changed, 20 insertions(+), 45 deletions(-) diff --git a/resources/qml/SidebarSimple.qml b/resources/qml/SidebarSimple.qml index bd2c7ab3b7..c2c1562fbb 100644 --- a/resources/qml/SidebarSimple.qml +++ b/resources/qml/SidebarSimple.qml @@ -331,41 +331,19 @@ Item { var current_extruder = extruderModel.get(currentIndex); color_override = ""; - if (current_extruder === undefined) { - return ""; - } - var model_color = current_extruder.color; - return (model_color) ? model_color : ""; + if (current_extruder === undefined) return "" + return (current_extruder.color) ? current_extruder.color : ""; } - textRole: 'text' // this solves that the combobox isn't populated in the first time Cura is started + textRole: "text" // this solves that the combobox isn't populated in the first time Cura is started anchors.top: enableSupportCheckBox.bottom - anchors.topMargin: - { - if ((supportEnabled.properties.value == "True") && (machineExtruderCount.properties.value > 1)) - { - return UM.Theme.getSize("sidebar_margin").height; - } - else - { - return 0; - } - } + anchors.topMargin: ((supportEnabled.properties.value === "True") && (machineExtruderCount.properties.value > 1)) ? UM.Theme.getSize("sidebar_margin").height : 0 anchors.left: infillCellRight.left + width: UM.Theme.getSize("sidebar").width * .55 - height: - { - if ((supportEnabled.properties.value == "True") && (machineExtruderCount.properties.value > 1)) - { - // default height when control is enabled - return UM.Theme.getSize("setting_control").height; - } - else - { - return 0; - } - } + height: ((supportEnabled.properties.value == "True") && (machineExtruderCount.properties.value > 1)) ? UM.Theme.getSize("setting_control").height : 0 + Behavior on height { NumberAnimation { duration: 100 } } style: UM.Theme.styles.combobox_color diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index 049c2b547c..a2b36569fb 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -610,6 +610,7 @@ QtObject { property Component combobox: Component { ComboBoxStyle { + background: Rectangle { implicitHeight: Theme.getSize("setting_control").height; implicitWidth: Theme.getSize("setting_control").width; @@ -620,6 +621,7 @@ QtObject { border.width: Theme.getSize("default_lining").width; border.color: (control.hovered || control._hovered) ? Theme.getColor("setting_control_border_highlight") : Theme.getColor("setting_control_border"); } + label: Item { Label { anchors.left: parent.left; @@ -656,19 +658,17 @@ QtObject { // Combobox with items with colored rectangles property Component combobox_color: Component { - ComboBoxStyle - { - background: Rectangle - { + ComboBoxStyle { + + background: Rectangle { color: !enabled ? UM.Theme.getColor("setting_control_disabled") : (control.hovered || controler._hovered) ? UM.Theme.getColor("setting_control_highlight") : UM.Theme.getColor("setting_control") border.width: UM.Theme.getSize("default_lining").width border.color: !enabled ? UM.Theme.getColor("setting_control_disabled_border") : (control.hovered || control._hovered) ? UM.Theme.getColor("setting_control_border_highlight") : UM.Theme.getColor("setting_control_border") } - label: Item - { - Label - { + label: Item { + + Label { anchors.left: parent.left anchors.leftMargin: UM.Theme.getSize("default_lining").width anchors.right: swatch.left @@ -683,28 +683,25 @@ QtObject { verticalAlignment: Text.AlignVCenter } - Rectangle - { + Rectangle { id: swatch height: UM.Theme.getSize("setting_control").height / 2 width: height - anchors - { + anchors { right: downArrow.left; verticalCenter: parent.verticalCenter margins: UM.Theme.getSize("default_margin").width / 4 } - border.width: UM.Theme.getSize("default_lining").width * 2 - border.color: enabled ? UM.Theme.getColor("setting_control_border") : UM.Theme.getColor("setting_control_disabled_border") +// border.width: UM.Theme.getSize("default_lining").width * 2 +// border.color: enabled ? UM.Theme.getColor("setting_control_border") : UM.Theme.getColor("setting_control_disabled_border") radius: width / 2 color: if (control.color_override != "") {return control.color_override} else {return control.color;} } - UM.RecolorImage - { + UM.RecolorImage { id: downArrow anchors.right: parent.right anchors.rightMargin: UM.Theme.getSize("default_lining").width * 2 From 9b33bc8194f20c02dc59a9a8da85f778ada4ee40 Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 12:50:12 +0200 Subject: [PATCH 15/20] CURA-4319 fix combobox hover states --- resources/themes/cura-light/styles.qml | 27 +++++++++++--------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index a2b36569fb..71e45b9bb1 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -615,14 +615,15 @@ QtObject { implicitHeight: Theme.getSize("setting_control").height; implicitWidth: Theme.getSize("setting_control").width; - color: (control.hovered || controler._hovered) ? UM.Theme.getColor("setting_control_highlight") : UM.Theme.getColor("setting_control") + color: control.hovered ? UM.Theme.getColor("setting_control_highlight") : UM.Theme.getColor("setting_control") Behavior on color { ColorAnimation { duration: 50; } } border.width: Theme.getSize("default_lining").width; - border.color: (control.hovered || control._hovered) ? Theme.getColor("setting_control_border_highlight") : Theme.getColor("setting_control_border"); + border.color: control.hovered ? Theme.getColor("setting_control_border_highlight") : Theme.getColor("setting_control_border"); } label: Item { + Label { anchors.left: parent.left; anchors.leftMargin: Theme.getSize("default_lining").width @@ -658,16 +659,17 @@ QtObject { // Combobox with items with colored rectangles property Component combobox_color: Component { + ComboBoxStyle { background: Rectangle { - color: !enabled ? UM.Theme.getColor("setting_control_disabled") : (control.hovered || controler._hovered) ? UM.Theme.getColor("setting_control_highlight") : UM.Theme.getColor("setting_control") + color: !enabled ? UM.Theme.getColor("setting_control_disabled") : control._hovered ? UM.Theme.getColor("setting_control_highlight") : UM.Theme.getColor("setting_control") border.width: UM.Theme.getSize("default_lining").width - border.color: !enabled ? UM.Theme.getColor("setting_control_disabled_border") : (control.hovered || control._hovered) ? UM.Theme.getColor("setting_control_border_highlight") : UM.Theme.getColor("setting_control_border") + border.color: !enabled ? UM.Theme.getColor("setting_control_disabled_border") : control._hovered ? UM.Theme.getColor("setting_control_border_highlight") : UM.Theme.getColor("setting_control_border") } label: Item { - + Label { anchors.left: parent.left anchors.leftMargin: UM.Theme.getSize("default_lining").width @@ -687,18 +689,11 @@ QtObject { id: swatch height: UM.Theme.getSize("setting_control").height / 2 width: height - - anchors { - right: downArrow.left; - verticalCenter: parent.verticalCenter - margins: UM.Theme.getSize("default_margin").width / 4 - } - -// border.width: UM.Theme.getSize("default_lining").width * 2 -// border.color: enabled ? UM.Theme.getColor("setting_control_border") : UM.Theme.getColor("setting_control_disabled_border") + anchors.right: downArrow.left + anchors.verticalCenter: parent.verticalCenter + anchors.margins: UM.Theme.getSize("default_margin").width / 4 radius: width / 2 - - color: if (control.color_override != "") {return control.color_override} else {return control.color;} + color: (control.color_override !== "") ? control.color_override : control.color } UM.RecolorImage { From 6b08a435b3e32760c3f59158e6306e1deec40bc6 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Tue, 12 Sep 2017 13:16:29 +0200 Subject: [PATCH 16/20] Improve retraction settings for PVA These are new retraction settings as tested by the materials & processing team. --- resources/variants/ultimaker3_bb04.inst.cfg | 6 +++++- resources/variants/ultimaker3_extended_bb04.inst.cfg | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/resources/variants/ultimaker3_bb04.inst.cfg b/resources/variants/ultimaker3_bb04.inst.cfg index a5aa03f1fa..6b189bc6c3 100644 --- a/resources/variants/ultimaker3_bb04.inst.cfg +++ b/resources/variants/ultimaker3_bb04.inst.cfg @@ -24,7 +24,10 @@ prime_tower_purge_volume = 1 raft_base_speed = 20 raft_interface_speed = 20 raft_speed = 25 +retraction_amount = 4.5 +retraction_count_max = 20 retraction_extrusion_window = =retraction_amount +retraction_min_travel = =3 * line_width speed_layer_0 = 20 speed_support = =math.ceil(speed_print * 25 / 35) speed_support_interface = =math.ceil(speed_support * 20 / 25) @@ -40,6 +43,7 @@ support_interface_height = 0.6 support_interface_skip_height = =layer_height support_join_distance = 3 support_line_width = =round(line_width * 0.4 / 0.35, 2) -support_offset = 3 +support_offset = 2 support_xy_distance = =round(wall_line_width_0 * 0.75, 2) support_xy_distance_overhang = =wall_line_width_0 / 2 +switch_extruder_retraction_amount = 12 \ No newline at end of file diff --git a/resources/variants/ultimaker3_extended_bb04.inst.cfg b/resources/variants/ultimaker3_extended_bb04.inst.cfg index eb9eefed0c..769044db0b 100644 --- a/resources/variants/ultimaker3_extended_bb04.inst.cfg +++ b/resources/variants/ultimaker3_extended_bb04.inst.cfg @@ -24,7 +24,10 @@ prime_tower_purge_volume = 1 raft_base_speed = 20 raft_interface_speed = 20 raft_speed = 25 +retraction_amount = 4.5 +retraction_count_max = 20 retraction_extrusion_window = =retraction_amount +retraction_min_travel = =3 * line_width speed_layer_0 = 20 speed_support = =math.ceil(speed_print * 25 / 35) speed_support_interface = =math.ceil(speed_support * 20 / 25) @@ -40,6 +43,7 @@ support_interface_height = 0.6 support_interface_skip_height = =layer_height support_join_distance = 3 support_line_width = =round(line_width * 0.4 / 0.35, 2) -support_offset = 3 +support_offset = 2 support_xy_distance = =round(wall_line_width_0 * 0.75, 2) support_xy_distance_overhang = =wall_line_width_0 / 2 +switch_extruder_retraction_amount = 12 \ No newline at end of file From 53dbf1c55d581f24d3df14f64d4f0f1f6e1b0626 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Tue, 12 Sep 2017 13:21:48 +0200 Subject: [PATCH 17/20] Remove switch_extruder_* settings from UM2+ UM2+ is a single-extrusion printer after all, so these settings aren't used. --- resources/quality/ultimaker2_plus/um2p_pp_0.4_fast.inst.cfg | 3 --- resources/quality/ultimaker2_plus/um2p_pp_0.4_normal.inst.cfg | 3 --- resources/quality/ultimaker2_plus/um2p_pp_0.6_draft.inst.cfg | 3 --- resources/quality/ultimaker2_plus/um2p_pp_0.6_fast.inst.cfg | 3 --- resources/quality/ultimaker2_plus/um2p_pp_0.8_draft.inst.cfg | 3 --- .../quality/ultimaker2_plus/um2p_pp_0.8_verydraft.inst.cfg | 3 --- 6 files changed, 18 deletions(-) diff --git a/resources/quality/ultimaker2_plus/um2p_pp_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pp_0.4_fast.inst.cfg index 6b0cd0b200..4d3c299526 100644 --- a/resources/quality/ultimaker2_plus/um2p_pp_0.4_fast.inst.cfg +++ b/resources/quality/ultimaker2_plus/um2p_pp_0.4_fast.inst.cfg @@ -64,9 +64,6 @@ support_top_distance = =support_z_distance support_xy_distance = =wall_line_width_0 * 2.5 support_xy_distance_overhang = =wall_line_width_0 support_z_distance = =layer_height * 2 -switch_extruder_prime_speed = 15 -switch_extruder_retraction_amount = 20 -switch_extruder_retraction_speeds = 35 travel_avoid_distance = 3 wall_0_inset = 0 wall_line_width_x = =round(line_width * 0.38 / 0.38, 2) diff --git a/resources/quality/ultimaker2_plus/um2p_pp_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pp_0.4_normal.inst.cfg index 1c596ab98d..ef50e2889d 100644 --- a/resources/quality/ultimaker2_plus/um2p_pp_0.4_normal.inst.cfg +++ b/resources/quality/ultimaker2_plus/um2p_pp_0.4_normal.inst.cfg @@ -63,9 +63,6 @@ support_top_distance = =support_z_distance support_xy_distance = =wall_line_width_0 * 2.5 support_xy_distance_overhang = =wall_line_width_0 support_z_distance = =layer_height * 2 -switch_extruder_prime_speed = 15 -switch_extruder_retraction_amount = 20 -switch_extruder_retraction_speeds = 35 travel_avoid_distance = 3 wall_0_inset = 0 wall_line_width_x = =round(line_width * 0.38 / 0.38, 2) diff --git a/resources/quality/ultimaker2_plus/um2p_pp_0.6_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pp_0.6_draft.inst.cfg index 88814ba2a4..b6130e43eb 100644 --- a/resources/quality/ultimaker2_plus/um2p_pp_0.6_draft.inst.cfg +++ b/resources/quality/ultimaker2_plus/um2p_pp_0.6_draft.inst.cfg @@ -65,9 +65,6 @@ support_top_distance = =support_z_distance support_xy_distance = =wall_line_width_0 * 2.5 support_xy_distance_overhang = =wall_line_width_0 support_z_distance = =layer_height * 2 -switch_extruder_prime_speed = 15 -switch_extruder_retraction_amount = 20 -switch_extruder_retraction_speeds = 35 top_bottom_thickness = 1.1 travel_avoid_distance = 3 wall_0_inset = 0 diff --git a/resources/quality/ultimaker2_plus/um2p_pp_0.6_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pp_0.6_fast.inst.cfg index da1b928482..399a3a6631 100644 --- a/resources/quality/ultimaker2_plus/um2p_pp_0.6_fast.inst.cfg +++ b/resources/quality/ultimaker2_plus/um2p_pp_0.6_fast.inst.cfg @@ -65,9 +65,6 @@ support_top_distance = =support_z_distance support_xy_distance = =wall_line_width_0 * 2.5 support_xy_distance_overhang = =wall_line_width_0 support_z_distance = =layer_height * 2 -switch_extruder_prime_speed = 15 -switch_extruder_retraction_amount = 20 -switch_extruder_retraction_speeds = 35 top_bottom_thickness = 1.1 travel_avoid_distance = 3 wall_0_inset = 0 diff --git a/resources/quality/ultimaker2_plus/um2p_pp_0.8_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pp_0.8_draft.inst.cfg index b4e2ddfa96..b6156728c9 100644 --- a/resources/quality/ultimaker2_plus/um2p_pp_0.8_draft.inst.cfg +++ b/resources/quality/ultimaker2_plus/um2p_pp_0.8_draft.inst.cfg @@ -65,9 +65,6 @@ support_top_distance = =support_z_distance support_xy_distance = =wall_line_width_0 * 2.5 support_xy_distance_overhang = =wall_line_width_0 support_z_distance = =layer_height * 2 -switch_extruder_prime_speed = 15 -switch_extruder_retraction_amount = 20 -switch_extruder_retraction_speeds = 35 top_bottom_thickness = 1.5 travel_avoid_distance = 3 wall_0_inset = 0 diff --git a/resources/quality/ultimaker2_plus/um2p_pp_0.8_verydraft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pp_0.8_verydraft.inst.cfg index f31e0dd192..1b66887dbe 100644 --- a/resources/quality/ultimaker2_plus/um2p_pp_0.8_verydraft.inst.cfg +++ b/resources/quality/ultimaker2_plus/um2p_pp_0.8_verydraft.inst.cfg @@ -65,9 +65,6 @@ support_top_distance = =support_z_distance support_xy_distance = =wall_line_width_0 * 2.5 support_xy_distance_overhang = =wall_line_width_0 support_z_distance = =layer_height * 2 -switch_extruder_prime_speed = 15 -switch_extruder_retraction_amount = 20 -switch_extruder_retraction_speeds = 35 top_bottom_thickness = 1.5 travel_avoid_distance = 3 wall_0_inset = 0 From 3a098f4b4c1c340463f31020da4dbee48d063064 Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 13:24:33 +0200 Subject: [PATCH 18/20] CURA-4319 material compatibility link style --- resources/qml/SidebarHeader.qml | 29 +++++++++----------------- resources/themes/cura-light/styles.qml | 1 + 2 files changed, 11 insertions(+), 19 deletions(-) diff --git a/resources/qml/SidebarHeader.qml b/resources/qml/SidebarHeader.qml index 3cb5ae156f..91f16d49ec 100644 --- a/resources/qml/SidebarHeader.qml +++ b/resources/qml/SidebarHeader.qml @@ -351,14 +351,12 @@ Column rightMargin: UM.Theme.getSize("sidebar_margin").width } - Item - { + Item { height: UM.Theme.getSize("sidebar_setup").height anchors.right: parent.right width: parent.width * 0.7 + UM.Theme.getSize("sidebar_margin").width - UM.RecolorImage - { + UM.RecolorImage { id: warningImage anchors.right: materialInfoLabel.left anchors.rightMargin: UM.Theme.getSize("default_margin").width @@ -366,40 +364,33 @@ Column source: UM.Theme.getIcon("warning") width: UM.Theme.getSize("section_icon").width height: UM.Theme.getSize("section_icon").height - //sourceSize.width: width + 5 - //sourceSize.height: width + 5 - color: UM.Theme.getColor("material_compatibility_warning") visible: !Cura.MachineManager.isCurrentSetupSupported } - Text - { + Text { id: materialInfoLabel wrapMode: Text.WordWrap - text: catalog.i18nc("@label", "Check material compatibility") - font: UM.Theme.getFont("default"); + text: catalog.i18nc("@label", "Check material compatibility") + font: UM.Theme.getFont("default") + color: UM.Theme.getColor("text") + linkColor: UM.Theme.getColor("text_link") verticalAlignment: Text.AlignTop anchors.top: parent.top anchors.right: parent.right anchors.bottom: parent.bottom - color: UM.Theme.getColor("text") - MouseArea - { + MouseArea { anchors.fill: parent hoverEnabled: true - onClicked: - { + onClicked: { // open the material URL with web browser var version = UM.Application.version; var machineName = Cura.MachineManager.activeMachine.definition.id; - var url = "https://ultimaker.com/materialcompatibility/" + version + "/" + machineName; Qt.openUrlExternally(url); } - onEntered: - { + onEntered: { var content = catalog.i18nc("@tooltip", "Click to check the material compatibility on Ultimaker.com."); base.showTooltip( materialInfoRow, diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index 71e45b9bb1..6b6093901b 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -693,6 +693,7 @@ QtObject { anchors.verticalCenter: parent.verticalCenter anchors.margins: UM.Theme.getSize("default_margin").width / 4 radius: width / 2 + color: (control.color_override !== "") ? control.color_override : control.color } From 2ffc5d2b581da42c405f8094ddf3817b01904e9b Mon Sep 17 00:00:00 2001 From: ChrisTerBeke Date: Tue, 12 Sep 2017 13:39:39 +0200 Subject: [PATCH 19/20] fix color swatch to be the same as layer view color swatch --- resources/themes/cura-light/styles.qml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/resources/themes/cura-light/styles.qml b/resources/themes/cura-light/styles.qml index 6b6093901b..be3e78990e 100755 --- a/resources/themes/cura-light/styles.qml +++ b/resources/themes/cura-light/styles.qml @@ -693,7 +693,8 @@ QtObject { anchors.verticalCenter: parent.verticalCenter anchors.margins: UM.Theme.getSize("default_margin").width / 4 radius: width / 2 - + border.width: UM.Theme.getSize("default_lining").width + border.color: UM.Theme.getColor("lining") color: (control.color_override !== "") ? control.color_override : control.color } From 766bc9ae972e491b3a90bc6ced78a14087678004 Mon Sep 17 00:00:00 2001 From: Mark Date: Tue, 12 Sep 2017 14:37:29 +0200 Subject: [PATCH 20/20] Changed bold fonts to normal CURA-4148 --- resources/qml/Sidebar.qml | 2 +- resources/qml/SidebarHeader.qml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml index 27b5b23aa6..ba357f40a5 100755 --- a/resources/qml/Sidebar.qml +++ b/resources/qml/Sidebar.qml @@ -181,7 +181,7 @@ Rectangle color: (control.checked || control.pressed) ? UM.Theme.getColor("action_button_active_text") : control.hovered ? UM.Theme.getColor("action_button_hovered_text") : UM.Theme.getColor("action_button_text") - font: (control.checked || control.pressed) ? UM.Theme.getFont("default_little_big") : UM.Theme.getFont("default") + font: UM.Theme.getFont("default") text: control.text; } } diff --git a/resources/qml/SidebarHeader.qml b/resources/qml/SidebarHeader.qml index 91f16d49ec..a17c896ad6 100644 --- a/resources/qml/SidebarHeader.qml +++ b/resources/qml/SidebarHeader.qml @@ -153,7 +153,7 @@ Column control.hovered ? UM.Theme.getColor("action_button_hovered_text") : UM.Theme.getColor("action_button_text") - font: control.checked ? UM.Theme.getFont("default_bold") : UM.Theme.getFont("default") + font: UM.Theme.getFont("large_nonbold") text: catalog.i18nc("@label", "Extruder") visible: width < (control.width - extruderIconItem.width - UM.Theme.getSize("default_margin").width) elide: Text.ElideRight