From 1e2c590c54aa77d7945c6eb4953c4a0d0d823bf7 Mon Sep 17 00:00:00 2001 From: Jack Ha Date: Tue, 31 Jul 2018 09:50:43 +0200 Subject: [PATCH 1/8] In multi build plate mode objects are now always arranged instead of never. CURA-5606 --- cura/CuraApplication.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 8dd17896bb..9f4ea7b3d3 100755 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -1605,8 +1605,7 @@ class CuraApplication(QtApplication): self._currently_loading_files.remove(file_name) self.fileLoaded.emit(file_name) - arrange_objects_on_load = not self.getPreferences().getValue("cura/use_multi_build_plate") - target_build_plate = self.getMultiBuildPlateModel().activeBuildPlate if arrange_objects_on_load else -1 + target_build_plate = self.getMultiBuildPlateModel().activeBuildPlate root = self.getController().getScene().getRoot() fixed_nodes = [] @@ -1660,7 +1659,7 @@ class CuraApplication(QtApplication): if not child.getDecorator(ConvexHullDecorator): child.addDecorator(ConvexHullDecorator()) - if file_extension != "3mf" and arrange_objects_on_load: + if file_extension != "3mf": if node.callDecoration("isSliceable"): # Only check position if it's not already blatantly obvious that it won't fit. if node.getBoundingBox() is None or self._volume.getBoundingBox() is None or node.getBoundingBox().width < self._volume.getBoundingBox().width or node.getBoundingBox().depth < self._volume.getBoundingBox().depth: From e55775175230efeb4a87eeb82d14b9498619dd4c Mon Sep 17 00:00:00 2001 From: Jack Ha Date: Tue, 31 Jul 2018 11:31:46 +0200 Subject: [PATCH 2/8] Add the active build plate name to default (not user specified) job name --- cura/PrintInformation.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py index 41faa7cef8..1e09cd9baa 100644 --- a/cura/PrintInformation.py +++ b/cura/PrintInformation.py @@ -267,6 +267,7 @@ class PrintInformation(QObject): new_active_build_plate = self._multi_build_plate_model.activeBuildPlate if new_active_build_plate != self._active_build_plate: self._active_build_plate = new_active_build_plate + self._updateJobName() self._initVariablesWithBuildPlate(self._active_build_plate) @@ -310,15 +311,18 @@ class PrintInformation(QObject): # Only update the job name when it's not user-specified. if not self._is_user_specified_job_name: if self._pre_sliced: - self._job_name = catalog.i18nc("@label", "Pre-sliced file {0}", base_name) + job_name = catalog.i18nc("@label", "Pre-sliced file {0}", base_name) elif self._application.getInstance().getPreferences().getValue("cura/jobname_prefix"): # Don't add abbreviation if it already has the exact same abbreviation. if base_name.startswith(self._abbr_machine + "_"): - self._job_name = base_name + job_name = base_name else: - self._job_name = self._abbr_machine + "_" + base_name + job_name = self._abbr_machine + "_" + base_name else: - self._job_name = base_name + job_name = base_name + if self._active_build_plate != 0: + job_name += "-{}".format(self._active_build_plate) + self._job_name = job_name self.jobNameChanged.emit() From be177939b56be6dcb605bc4e5c44f01769b546d7 Mon Sep 17 00:00:00 2001 From: Jack Ha Date: Tue, 31 Jul 2018 17:09:33 +0200 Subject: [PATCH 3/8] Reverts other commit bound to CURA-5563, that was not correct. --- resources/definitions/fdmprinter.def.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 373ddc879c..b767aac7b9 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -1074,7 +1074,7 @@ "maximum_value_warning": "top_layers - 1", "type": "int", "value": "0", - "limit_to_extruder": "top_bottom_extruder_nr", + "limit_to_extruder": "roofing_extruder_nr", "settable_per_mesh": true, "enabled": "top_layers > 0" }, From d1b6aa8c375f070f49fdf3b8c216ecf4564bf69e Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Wed, 1 Aug 2018 08:33:47 +0200 Subject: [PATCH 4/8] Set the focus in the upper handle in the layer view instead of in the text field. That makes it easier to release the focus by clicking in the main view and use the arrow keys to rotate the view. --- plugins/SimulationView/LayerSlider.qml | 4 ++++ plugins/SimulationView/SimulationSliderLabel.qml | 4 ---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/SimulationView/LayerSlider.qml b/plugins/SimulationView/LayerSlider.qml index 22f9d91340..ab752419db 100644 --- a/plugins/SimulationView/LayerSlider.qml +++ b/plugins/SimulationView/LayerSlider.qml @@ -67,6 +67,10 @@ Item { activeHandle = handle } + // make sure the upper handle is focussed when pressing the parent handle + // needed to connect the key bindings when switching active handle + onVisibleChanged: if (visible) upperHandleLabel.forceActiveFocus() + // slider track Rectangle { id: track diff --git a/plugins/SimulationView/SimulationSliderLabel.qml b/plugins/SimulationView/SimulationSliderLabel.qml index 8615a382da..94167d001e 100644 --- a/plugins/SimulationView/SimulationSliderLabel.qml +++ b/plugins/SimulationView/SimulationSliderLabel.qml @@ -25,10 +25,6 @@ UM.PointingRectangle { width: valueLabel.width + UM.Theme.getSize("default_margin").width visible: false - // make sure the text field is focussed when pressing the parent handle - // needed to connect the key bindings when switching active handle - onVisibleChanged: if (visible) valueLabel.forceActiveFocus() - color: UM.Theme.getColor("tool_panel_background") borderColor: UM.Theme.getColor("lining") borderWidth: UM.Theme.getSize("default_lining").width From 4406b621a5d3935ca55ba9b737d53127f1a14924 Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Wed, 1 Aug 2018 08:46:44 +0200 Subject: [PATCH 5/8] Fix quality profiles for Dagoma Neva Magis. Contributes to CURA-5499. --- resources/quality/dagoma/dagoma_neva_magis_pla_fast.inst.cfg | 2 +- resources/quality/dagoma/dagoma_neva_magis_pla_fine.inst.cfg | 2 +- .../quality/dagoma/dagoma_neva_magis_pla_standard.inst.cfg | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/quality/dagoma/dagoma_neva_magis_pla_fast.inst.cfg b/resources/quality/dagoma/dagoma_neva_magis_pla_fast.inst.cfg index efdf2f7d32..e52cba165c 100644 --- a/resources/quality/dagoma/dagoma_neva_magis_pla_fast.inst.cfg +++ b/resources/quality/dagoma/dagoma_neva_magis_pla_fast.inst.cfg @@ -1,7 +1,7 @@ [general] version = 4 name = Fast -definition = dagoma_neva +definition = dagoma_neva_magis [metadata] setting_version = 5 diff --git a/resources/quality/dagoma/dagoma_neva_magis_pla_fine.inst.cfg b/resources/quality/dagoma/dagoma_neva_magis_pla_fine.inst.cfg index 50915db112..033cfbc8fa 100644 --- a/resources/quality/dagoma/dagoma_neva_magis_pla_fine.inst.cfg +++ b/resources/quality/dagoma/dagoma_neva_magis_pla_fine.inst.cfg @@ -1,7 +1,7 @@ [general] version = 4 name = Fine -definition = dagoma_neva +definition = dagoma_neva_magis [metadata] setting_version = 5 diff --git a/resources/quality/dagoma/dagoma_neva_magis_pla_standard.inst.cfg b/resources/quality/dagoma/dagoma_neva_magis_pla_standard.inst.cfg index ed67800eac..d07d5b58d5 100644 --- a/resources/quality/dagoma/dagoma_neva_magis_pla_standard.inst.cfg +++ b/resources/quality/dagoma/dagoma_neva_magis_pla_standard.inst.cfg @@ -1,7 +1,7 @@ [general] version = 4 name = Standard -definition = dagoma_neva +definition = dagoma_neva_magis [metadata] setting_version = 5 From 56437af4d2a892c8789d433d67046de467188314 Mon Sep 17 00:00:00 2001 From: Ian Paschal Date: Wed, 1 Aug 2018 10:50:29 +0200 Subject: [PATCH 6/8] CURA-5613 Don't focus on slider This way arrow keys are able to rotate the viewport --- plugins/SimulationView/LayerSlider.qml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/plugins/SimulationView/LayerSlider.qml b/plugins/SimulationView/LayerSlider.qml index ab752419db..22f9d91340 100644 --- a/plugins/SimulationView/LayerSlider.qml +++ b/plugins/SimulationView/LayerSlider.qml @@ -67,10 +67,6 @@ Item { activeHandle = handle } - // make sure the upper handle is focussed when pressing the parent handle - // needed to connect the key bindings when switching active handle - onVisibleChanged: if (visible) upperHandleLabel.forceActiveFocus() - // slider track Rectangle { id: track From b8ec1d0fa768d790b6fb172d212060a9b500f1ae Mon Sep 17 00:00:00 2001 From: Jack Ha Date: Wed, 1 Aug 2018 10:52:31 +0200 Subject: [PATCH 7/8] In relative mode, the feedback is still absolute and not relative. CURA-5480 --- plugins/PostProcessingPlugin/scripts/Stretch.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/plugins/PostProcessingPlugin/scripts/Stretch.py b/plugins/PostProcessingPlugin/scripts/Stretch.py index 377bc4e8da..9757296041 100644 --- a/plugins/PostProcessingPlugin/scripts/Stretch.py +++ b/plugins/PostProcessingPlugin/scripts/Stretch.py @@ -62,13 +62,12 @@ class GCodeStep(): delta_step_y = _getValue(line, "Y", 0) delta_step_z = _getValue(line, "Z", 0) delta_step_e = _getValue(line, "E", 0) - delta_step_f = _getValue(line, "F", 0) self.step_x += delta_step_x self.step_y += delta_step_y self.step_z += delta_step_z self.step_e += delta_step_e - self.step_f += delta_step_f + self.step_f = _getValue(line, "F", self.step_f) # the feedrate is not relative def copyPosFrom(self, step): """ From d57090c049f43cb5d3f62894bc0bada3ef654b2c Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Wed, 1 Aug 2018 12:53:07 +0200 Subject: [PATCH 8/8] Allow the user to change the name and even though the name in the different buildplates will change accordingly to the build plate number. --- cura/PrintInformation.py | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py index 1e09cd9baa..21e2040dc1 100644 --- a/cura/PrintInformation.py +++ b/cura/PrintInformation.py @@ -311,18 +311,24 @@ class PrintInformation(QObject): # Only update the job name when it's not user-specified. if not self._is_user_specified_job_name: if self._pre_sliced: - job_name = catalog.i18nc("@label", "Pre-sliced file {0}", base_name) + self._job_name = catalog.i18nc("@label", "Pre-sliced file {0}", base_name) elif self._application.getInstance().getPreferences().getValue("cura/jobname_prefix"): # Don't add abbreviation if it already has the exact same abbreviation. if base_name.startswith(self._abbr_machine + "_"): - job_name = base_name + self._job_name = base_name else: - job_name = self._abbr_machine + "_" + base_name + self._job_name = self._abbr_machine + "_" + base_name else: - job_name = base_name + self._job_name = base_name + + # In case there are several buildplates, a suffix is attached + if self._multi_build_plate_model.maxBuildPlate > 0: + connector = "_#" + suffix = connector + str(self._active_build_plate + 1) + if connector in self._job_name: + self._job_name = self._job_name.split(connector)[0] # get the real name if self._active_build_plate != 0: - job_name += "-{}".format(self._active_build_plate) - self._job_name = job_name + self._job_name += suffix self.jobNameChanged.emit()