From f320000ce5e5019d8f96af20b29aa266b54856f6 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Mon, 3 Dec 2018 17:23:44 +0100 Subject: [PATCH 1/9] Change default profile of Aurora and Alfawise printers Instead of the default layer height, we should change the default quality profile. This is necessary because the 'normal' quality profile doesn't define a layer height, so that should inherit from the 0.1mm default layer height. But if the printer turned the default into a 0.15mm layer height then that is wrong. Maybe we should let the normal quality profile overwrite it to 0.1mm, always? Contributes to issue CURA-5902. --- resources/definitions/alfawise_u20.def.json | 5 +---- resources/definitions/jgaurora_a1.def.json | 5 +---- resources/definitions/jgaurora_a5.def.json | 5 +---- resources/definitions/jgaurora_z_603s.def.json | 5 +---- 4 files changed, 4 insertions(+), 16 deletions(-) diff --git a/resources/definitions/alfawise_u20.def.json b/resources/definitions/alfawise_u20.def.json index 87726fec3d..de8525fa4d 100644 --- a/resources/definitions/alfawise_u20.def.json +++ b/resources/definitions/alfawise_u20.def.json @@ -7,7 +7,7 @@ "author": "Samuel Pinches", "manufacturer": "Alfawise", "file_formats": "text/x-gcode", - "preferred_quality_type": "fine", + "preferred_quality_type": "fast", "machine_extruder_trains": { "0": "alfawise_u20_extruder_0" @@ -53,9 +53,6 @@ "material_bed_temperature": { "default_value": 50 }, - "layer_height": { - "default_value": 0.15 - }, "layer_height_0": { "default_value": 0.2 }, diff --git a/resources/definitions/jgaurora_a1.def.json b/resources/definitions/jgaurora_a1.def.json index 4fd2eb4994..b9a921c311 100644 --- a/resources/definitions/jgaurora_a1.def.json +++ b/resources/definitions/jgaurora_a1.def.json @@ -7,7 +7,7 @@ "author": "Samuel Pinches", "manufacturer": "JGAurora", "file_formats": "text/x-gcode", - "preferred_quality_type": "fine", + "preferred_quality_type": "fast", "machine_extruder_trains": { "0": "jgaurora_a1_extruder_0" @@ -53,9 +53,6 @@ "material_bed_temperature": { "default_value": 67 }, - "layer_height": { - "default_value": 0.15 - }, "layer_height_0": { "default_value": 0.12 }, diff --git a/resources/definitions/jgaurora_a5.def.json b/resources/definitions/jgaurora_a5.def.json index 02d9a9db4f..d84a8440e6 100644 --- a/resources/definitions/jgaurora_a5.def.json +++ b/resources/definitions/jgaurora_a5.def.json @@ -9,7 +9,7 @@ "file_formats": "text/x-gcode", "platform": "jgaurora_a5.stl", "platform_offset": [-242, -101, 273], - "preferred_quality_type": "fine", + "preferred_quality_type": "fast", "machine_extruder_trains": { "0": "jgaurora_a5_extruder_0" @@ -55,9 +55,6 @@ "material_bed_temperature": { "default_value": 67 }, - "layer_height": { - "default_value": 0.15 - }, "layer_height_0": { "default_value": 0.12 }, diff --git a/resources/definitions/jgaurora_z_603s.def.json b/resources/definitions/jgaurora_z_603s.def.json index 59e0ff129c..3a78585240 100644 --- a/resources/definitions/jgaurora_z_603s.def.json +++ b/resources/definitions/jgaurora_z_603s.def.json @@ -7,7 +7,7 @@ "author": "Samuel Pinches", "manufacturer": "JGAurora", "file_formats": "text/x-gcode", - "preferred_quality_type": "fine", + "preferred_quality_type": "fast", "machine_extruder_trains": { "0": "jgaurora_z_603s_extruder_0" @@ -53,9 +53,6 @@ "material_bed_temperature": { "default_value": 55 }, - "layer_height": { - "default_value": 0.15 - }, "layer_height_0": { "default_value": 0.2 }, From 6af1e72ea330c009feb3a3834233481a442db2c7 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Tue, 4 Dec 2018 07:45:34 +0100 Subject: [PATCH 2/9] Show progress bar while autoslice is preparing Previously it would say 'preparing to slice'. Now it just says 'auto slicing' but with an indeterminate progress bar. Only the indeterminate progress bar just appears empty right now... Contributes to issue CURA-5997. --- resources/qml/ActionPanel/SliceProcessWidget.qml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/resources/qml/ActionPanel/SliceProcessWidget.qml b/resources/qml/ActionPanel/SliceProcessWidget.qml index 3329ac4b23..14e149dddb 100644 --- a/resources/qml/ActionPanel/SliceProcessWidget.qml +++ b/resources/qml/ActionPanel/SliceProcessWidget.qml @@ -44,7 +44,7 @@ Column { id: autoSlicingLabel width: parent.width - visible: prepareButtons.autoSlice && widget.backendState == UM.Backend.Processing + visible: prepareButtons.autoSlice && (widget.backendState == UM.Backend.Processing || widget.backendState == UM.Backend.NotStarted) text: catalog.i18nc("@label:PrintjobStatus", "Auto slicing...") color: UM.Theme.getColor("text") @@ -71,7 +71,8 @@ Column width: parent.width height: UM.Theme.getSize("progressbar").height value: progress - visible: widget.backendState == UM.Backend.Processing + indeterminate: widget.backendState == UM.Backend.NotStarted + visible: (widget.backendState == UM.Backend.Processing || (prepareButtons.autoSlice && widget.backendState == UM.Backend.NotStarted)) background: Rectangle { From e9f8757fac1b5740f7daab3dea3288940f092400 Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Tue, 4 Dec 2018 09:12:57 +0100 Subject: [PATCH 3/9] Change the info button in the action panel according to the designs Adjust the padding in the preview shortcut. --- .../qml/ActionPanel/OutputProcessWidget.qml | 2 + .../ActionPanel/PrintInformationWidget.qml | 3 -- resources/themes/cura-light/icons/info.svg | 48 ------------------- 3 files changed, 2 insertions(+), 51 deletions(-) delete mode 100644 resources/themes/cura-light/icons/info.svg diff --git a/resources/qml/ActionPanel/OutputProcessWidget.qml b/resources/qml/ActionPanel/OutputProcessWidget.qml index 45cb1fdb41..6ab8dc6fbb 100644 --- a/resources/qml/ActionPanel/OutputProcessWidget.qml +++ b/resources/qml/ActionPanel/OutputProcessWidget.qml @@ -112,6 +112,8 @@ Column id: previewStageShortcut height: UM.Theme.getSize("action_panel_button").height + leftPadding: UM.Theme.getSize("default_margin").width + rightPadding: UM.Theme.getSize("default_margin").width text: catalog.i18nc("@button", "Preview") onClicked: UM.Controller.setActiveStage("PreviewStage") diff --git a/resources/qml/ActionPanel/PrintInformationWidget.qml b/resources/qml/ActionPanel/PrintInformationWidget.qml index 82707576e0..25e380dea8 100644 --- a/resources/qml/ActionPanel/PrintInformationWidget.qml +++ b/resources/qml/ActionPanel/PrintInformationWidget.qml @@ -11,9 +11,6 @@ UM.RecolorImage { id: widget - //implicitHeight: UM.Theme.getSize("section_icon").height - //implicitWidth: UM.Theme.getSize("section_icon").width - source: UM.Theme.getIcon("info") width: UM.Theme.getSize("section_icon").width height: UM.Theme.getSize("section_icon").height diff --git a/resources/themes/cura-light/icons/info.svg b/resources/themes/cura-light/icons/info.svg deleted file mode 100644 index 97e4fc4f35..0000000000 --- a/resources/themes/cura-light/icons/info.svg +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From c1f5c00a7e088fee409d7c7282607faf3976707f Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Tue, 4 Dec 2018 09:18:45 +0100 Subject: [PATCH 4/9] Forgot to add the icon --- resources/themes/cura-light/icons/info.svg | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 resources/themes/cura-light/icons/info.svg diff --git a/resources/themes/cura-light/icons/info.svg b/resources/themes/cura-light/icons/info.svg new file mode 100644 index 0000000000..9896b3dac8 --- /dev/null +++ b/resources/themes/cura-light/icons/info.svg @@ -0,0 +1,13 @@ + + + + Icon/ info + Created with Sketch. + + + + + + + + \ No newline at end of file From 57a852a15ae0ff9e292e3eff574c067399a29777 Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Tue, 4 Dec 2018 09:19:08 +0100 Subject: [PATCH 5/9] Don't show the background if there are less than 2 extruders to show in the Toolbar It caused a very tiny rectangle if the printer has only 1 extruder. Contributes to CURA-5984. --- resources/qml/Toolbar.qml | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) diff --git a/resources/qml/Toolbar.qml b/resources/qml/Toolbar.qml index 07522dd535..5fbddea9ac 100644 --- a/resources/qml/Toolbar.qml +++ b/resources/qml/Toolbar.qml @@ -115,6 +115,7 @@ Item } radius: UM.Theme.getSize("default_radius").width color: UM.Theme.getColor("lining") + visible: extrudersModel.items.length > 1 } Column @@ -131,8 +132,7 @@ Item id: extruders width: childrenRect.width height: childrenRect.height - property var _model: Cura.ExtrudersModel { id: extrudersModel } - model: _model.items.length > 1 ? _model : 0 + model: extrudersModel.items.length > 1 ? extrudersModel : 0 delegate: ExtruderButton { @@ -144,13 +144,18 @@ Item } } + Cura.ExtrudersModel + { + id: extrudersModel + } + UM.PointingRectangle { - id: panelBorder; + id: panelBorder - anchors.left: parent.right; - anchors.leftMargin: UM.Theme.getSize("default_margin").width; - anchors.top: base.top; + anchors.left: parent.right + anchors.leftMargin: UM.Theme.getSize("default_margin").width + anchors.top: base.top anchors.topMargin: base.activeY z: buttons.z - 1 @@ -161,14 +166,14 @@ Item { if (panel.item && panel.width > 0) { - return Math.max(panel.width + 2 * UM.Theme.getSize("default_margin").width); + return Math.max(panel.width + 2 * UM.Theme.getSize("default_margin").width) } else { return 0; } } - height: panel.item ? panel.height + 2 * UM.Theme.getSize("default_margin").height : 0; + height: panel.item ? panel.height + 2 * UM.Theme.getSize("default_margin").height : 0 opacity: panel.item && panel.width > 0 ? 1 : 0 Behavior on opacity { NumberAnimation { duration: 100 } } @@ -186,11 +191,11 @@ Item { id: panel - x: UM.Theme.getSize("default_margin").width; - y: UM.Theme.getSize("default_margin").height; + x: UM.Theme.getSize("default_margin").width + y: UM.Theme.getSize("default_margin").height source: UM.ActiveTool.valid ? UM.ActiveTool.activeToolPanel : "" - enabled: UM.Controller.toolsEnabled; + enabled: UM.Controller.toolsEnabled } } From 9ec7428620e4ea31b1b172aeda86a29db28fd7c8 Mon Sep 17 00:00:00 2001 From: Lipu Fei Date: Tue, 4 Dec 2018 10:54:30 +0100 Subject: [PATCH 6/9] Fix setting visiblity current index CURA-5981 --- resources/qml/Preferences/SettingVisibilityPage.qml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/resources/qml/Preferences/SettingVisibilityPage.qml b/resources/qml/Preferences/SettingVisibilityPage.qml index e319069502..1b964cad0c 100644 --- a/resources/qml/Preferences/SettingVisibilityPage.qml +++ b/resources/qml/Preferences/SettingVisibilityPage.qml @@ -115,15 +115,16 @@ UM.PreferencesPage currentIndex: { + var idx = -1; for(var i = 0; i < settingVisibilityPresetsModel.items.length; ++i) { if(settingVisibilityPresetsModel.items[i].presetId == settingVisibilityPresetsModel.activePreset) { - currentIndex = i; - return; + idx = i; + break; } } - return -1 + return idx; } onActivated: From 5b4fad3c08fe089bf216f91ac2ce889c4cc16e83 Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Tue, 4 Dec 2018 14:54:15 +0100 Subject: [PATCH 7/9] When toggling auto-slice, force a re-slice CURA-5997 --- resources/qml/ActionPanel/SliceProcessWidget.qml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/resources/qml/ActionPanel/SliceProcessWidget.qml b/resources/qml/ActionPanel/SliceProcessWidget.qml index 14e149dddb..03d91db530 100644 --- a/resources/qml/ActionPanel/SliceProcessWidget.qml +++ b/resources/qml/ActionPanel/SliceProcessWidget.qml @@ -137,6 +137,10 @@ Column { var autoSlice = UM.Preferences.getValue("general/auto_slice") prepareButtons.autoSlice = autoSlice + if(autoSlice) + { + CuraApplication.backend.forceSlice() + } } } From 02e7f904734c3d0cae1a33f0a978d3c3aa088912 Mon Sep 17 00:00:00 2001 From: Lipu Fei Date: Tue, 4 Dec 2018 15:02:24 +0100 Subject: [PATCH 8/9] Fix module importing in USBPrinting CURA-5943 --- plugins/USBPrinting/AutoDetectBaudJob.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/USBPrinting/AutoDetectBaudJob.py b/plugins/USBPrinting/AutoDetectBaudJob.py index 6f1af6727a..78de864e57 100644 --- a/plugins/USBPrinting/AutoDetectBaudJob.py +++ b/plugins/USBPrinting/AutoDetectBaudJob.py @@ -3,8 +3,8 @@ from UM.Job import Job from UM.Logger import Logger -from plugins.USBPrinting.avr_isp import ispBase +from .avr_isp import ispBase from .avr_isp.stk500v2 import Stk500v2 from time import time, sleep From 43096c1bafc0790bf265709d46eb1b88eb7445dc Mon Sep 17 00:00:00 2001 From: Lipu Fei Date: Tue, 4 Dec 2018 15:03:43 +0100 Subject: [PATCH 9/9] Update USBPrinting version to 1.0.1 CURA-5943 --- plugins/USBPrinting/plugin.json | 2 +- resources/bundled_packages/cura.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/USBPrinting/plugin.json b/plugins/USBPrinting/plugin.json index 3484c8a48a..5d3cba8415 100644 --- a/plugins/USBPrinting/plugin.json +++ b/plugins/USBPrinting/plugin.json @@ -1,7 +1,7 @@ { "name": "USB printing", "author": "Ultimaker B.V.", - "version": "1.0.0", + "version": "1.0.1", "api": 5, "description": "Accepts G-Code and sends them to a printer. Plugin can also update firmware.", "i18n-catalog": "cura" diff --git a/resources/bundled_packages/cura.json b/resources/bundled_packages/cura.json index ee82b17a75..d8a7df2478 100644 --- a/resources/bundled_packages/cura.json +++ b/resources/bundled_packages/cura.json @@ -515,7 +515,7 @@ "package_type": "plugin", "display_name": "USB Printing", "description": "Accepts G-Code and sends them to a printer. Plugin can also update firmware.", - "package_version": "1.0.0", + "package_version": "1.0.1", "sdk_version": 5, "website": "https://ultimaker.com", "author": {