From a030b5bfc3eb0072a3402815011360ee49f093cb Mon Sep 17 00:00:00 2001 From: Jack Ha Date: Tue, 18 Oct 2016 10:26:02 +0200 Subject: [PATCH 01/10] Fix gcode profile. CURA-2718 --- plugins/GCodeWriter/GCodeWriter.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/GCodeWriter/GCodeWriter.py b/plugins/GCodeWriter/GCodeWriter.py index ee35a05215..9ff1105b9f 100644 --- a/plugins/GCodeWriter/GCodeWriter.py +++ b/plugins/GCodeWriter/GCodeWriter.py @@ -13,6 +13,7 @@ from UM.Settings.InstanceContainer import InstanceContainer import re #For escaping characters in the settings. import json +import copy ## Writes g-code to a file. # @@ -70,7 +71,7 @@ class GCodeWriter(MeshWriter): flat_container.setDefinition(instance_container1.getDefinition()) else: flat_container.setDefinition(instance_container2.getDefinition()) - flat_container.setMetaData(instance_container2.getMetaData()) + flat_container.setMetaData(copy.deepcopy(instance_container2.getMetaData())) for key in instance_container2.getAllKeys(): flat_container.setProperty(key, "value", instance_container2.getProperty(key, "value")) From cc549932c4ded5b4b645d559369444a2b579c0cc Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Tue, 18 Oct 2016 11:48:23 +0200 Subject: [PATCH 02/10] ConvexHull decorater no longer crashes if node has no MeshData Fixes CURA-2706 --- cura/ConvexHullDecorator.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cura/ConvexHullDecorator.py b/cura/ConvexHullDecorator.py index 67c655f53d..a7d0775e21 100644 --- a/cura/ConvexHullDecorator.py +++ b/cura/ConvexHullDecorator.py @@ -200,6 +200,8 @@ class ConvexHullDecorator(SceneNodeDecorator): if len(vertex_data) >= 4: convex_hull = hull.getConvexHull() offset_hull = self._offsetHull(convex_hull) + else: + return Polygon([]) # Node has no mesh data, so just return an empty Polygon. # Store the result in the cache self._2d_convex_hull_mesh = mesh From 6d1f766ef348ce795ed4f0010c2d3b44674c49aa Mon Sep 17 00:00:00 2001 From: Simon Edwards Date: Tue, 18 Oct 2016 13:18:56 +0200 Subject: [PATCH 03/10] Fixed for the inheritance icon and custom profiles. CURA-2674 Inheritance icon not shown for saved profile. --- cura/Settings/SettingInheritanceManager.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cura/Settings/SettingInheritanceManager.py b/cura/Settings/SettingInheritanceManager.py index 93a7b1370d..84002128c7 100644 --- a/cura/Settings/SettingInheritanceManager.py +++ b/cura/Settings/SettingInheritanceManager.py @@ -170,11 +170,16 @@ class SettingInheritanceManager(QObject): def _onGlobalContainerChanged(self): if self._global_container_stack: self._global_container_stack.propertyChanged.disconnect(self._onPropertyChanged) + self._global_container_stack.containersChanged.disconnect(self._onContainersChanged) self._global_container_stack = Application.getInstance().getGlobalContainerStack() if self._global_container_stack: + self._global_container_stack.containersChanged.connect(self._onContainersChanged) self._global_container_stack.propertyChanged.connect(self._onPropertyChanged) self._onActiveExtruderChanged() + def _onContainersChanged(self, container): + self._onActiveExtruderChanged() + @staticmethod def createSettingInheritanceManager(engine=None, script_engine=None): return SettingInheritanceManager() \ No newline at end of file From 919596180656a3d15109143c5a7bc6b78d6a1eef Mon Sep 17 00:00:00 2001 From: Jack Ha Date: Tue, 18 Oct 2016 15:05:18 +0200 Subject: [PATCH 04/10] Fixed translation of 4 words in profilespage. remains of CURA-570 --- resources/qml/Preferences/ProfilesPage.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/qml/Preferences/ProfilesPage.qml b/resources/qml/Preferences/ProfilesPage.qml index 1bc705fe62..f85d967cfe 100644 --- a/resources/qml/Preferences/ProfilesPage.qml +++ b/resources/qml/Preferences/ProfilesPage.qml @@ -235,7 +235,7 @@ UM.ManagementPage Item { - UM.I18nCatalog { id: catalog; name: "uranium"; } + UM.I18nCatalog { id: catalog; name: "cura"; } UM.ConfirmRemoveDialog { From d3e3c0c6591e6690ae3939867edd23c00cc85f90 Mon Sep 17 00:00:00 2001 From: fieldOfView Date: Mon, 17 Oct 2016 14:10:02 +0200 Subject: [PATCH 05/10] Fix translation of machines page and some other references to Uranium CURA-570 --- resources/qml/Preferences/GeneralPage.qml | 4 ++-- resources/qml/Preferences/MachinesPage.qml | 4 ++-- resources/qml/Preferences/ProfilesPage.qml | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/resources/qml/Preferences/GeneralPage.qml b/resources/qml/Preferences/GeneralPage.qml index f727af5a10..adbad802ef 100644 --- a/resources/qml/Preferences/GeneralPage.qml +++ b/resources/qml/Preferences/GeneralPage.qml @@ -1,5 +1,5 @@ -// Copyright (c) 2015 Ultimaker B.V. -// Uranium is released under the terms of the AGPLv3 or higher. +// Copyright (c) 2016 Ultimaker B.V. +// Cura is released under the terms of the AGPLv3 or higher. import QtQuick 2.1 import QtQuick.Controls 1.1 diff --git a/resources/qml/Preferences/MachinesPage.qml b/resources/qml/Preferences/MachinesPage.qml index f2937c04e6..78553bb37f 100644 --- a/resources/qml/Preferences/MachinesPage.qml +++ b/resources/qml/Preferences/MachinesPage.qml @@ -1,5 +1,5 @@ // Copyright (c) 2016 Ultimaker B.V. -// Uranium is released under the terms of the AGPLv3 or higher. +// Cura is released under the terms of the AGPLv3 or higher. import QtQuick 2.1 import QtQuick.Controls 1.1 @@ -229,7 +229,7 @@ UM.ManagementPage } } - UM.I18nCatalog { id: catalog; name: "uranium"; } + UM.I18nCatalog { id: catalog; name: "cura"; } UM.ConfirmRemoveDialog { diff --git a/resources/qml/Preferences/ProfilesPage.qml b/resources/qml/Preferences/ProfilesPage.qml index f85d967cfe..621ecb3184 100644 --- a/resources/qml/Preferences/ProfilesPage.qml +++ b/resources/qml/Preferences/ProfilesPage.qml @@ -1,5 +1,5 @@ -// Copyright (c) 2015 Ultimaker B.V. -// Uranium is released under the terms of the AGPLv3 or higher. +// Copyright (c) 2016 Ultimaker B.V. +// Cura is released under the terms of the AGPLv3 or higher. import QtQuick 2.1 import QtQuick.Controls 1.1 From 9e6f340943732cc5cc940bccd1a641378c862824 Mon Sep 17 00:00:00 2001 From: Simon Edwards Date: Tue, 18 Oct 2016 15:47:38 +0200 Subject: [PATCH 06/10] Move z hop settings to Travel category CURA-2727 --- resources/definitions/fdmprinter.def.json | 60 +++++++++++------------ 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 603349726e..70ca9e7110 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -1297,36 +1297,6 @@ "settable_per_mesh": false, "settable_per_extruder": true }, - "retraction_hop_enabled": { - "label": "Z Hop when Retracted", - "description": "Whenever a retraction is done, the build plate is lowered to create clearance between the nozzle and the print. It prevents the nozzle from hitting the print during travel moves, reducing the chance to knock the print from the build plate.", - "type": "bool", - "default_value": false, - "enabled": "retraction_enable", - "settable_per_mesh": false, - "settable_per_extruder": true - }, - "retraction_hop_only_when_collides": { - "label": "Z Hop Only Over Printed Parts", - "description": "Only perform a Z Hop when moving over printed parts which cannot be avoided by horizontal motion by Avoid Printed Parts when Traveling.", - "type": "bool", - "default_value": false, - "enabled": "retraction_enable and retraction_hop_enabled and travel_avoid_other_parts", - "settable_per_mesh": false, - "settable_per_extruder": true - }, - "retraction_hop": { - "label": "Z Hop Height", - "description": "The height difference when performing a Z Hop.", - "unit": "mm", - "type": "float", - "default_value": 1, - "minimum_value_warning": "0.75 * machine_nozzle_size", - "maximum_value_warning": "10", - "enabled": "retraction_enable and retraction_hop_enabled", - "settable_per_mesh": false, - "settable_per_extruder": true - }, "material_standby_temperature": { "label": "Standby Temperature", @@ -2186,6 +2156,36 @@ "enabled": "resolveOrValue('retraction_combing') != 'off' and travel_avoid_other_parts", "settable_per_mesh": false, "settable_per_extruder": true + }, + "retraction_hop_enabled": { + "label": "Z Hop when Retracted", + "description": "Whenever a retraction is done, the build plate is lowered to create clearance between the nozzle and the print. It prevents the nozzle from hitting the print during travel moves, reducing the chance to knock the print from the build plate.", + "type": "bool", + "default_value": false, + "enabled": "retraction_enable", + "settable_per_mesh": false, + "settable_per_extruder": true + }, + "retraction_hop_only_when_collides": { + "label": "Z Hop Only Over Printed Parts", + "description": "Only perform a Z Hop when moving over printed parts which cannot be avoided by horizontal motion by Avoid Printed Parts when Traveling.", + "type": "bool", + "default_value": false, + "enabled": "retraction_enable and retraction_hop_enabled and travel_avoid_other_parts", + "settable_per_mesh": false, + "settable_per_extruder": true + }, + "retraction_hop": { + "label": "Z Hop Height", + "description": "The height difference when performing a Z Hop.", + "unit": "mm", + "type": "float", + "default_value": 1, + "minimum_value_warning": "0.75 * machine_nozzle_size", + "maximum_value_warning": "10", + "enabled": "retraction_enable and retraction_hop_enabled", + "settable_per_mesh": false, + "settable_per_extruder": true } } }, From aad3da85e9f15d8d0e0987f630f8b12729604974 Mon Sep 17 00:00:00 2001 From: Tim Kuipers Date: Wed, 19 Oct 2016 12:59:28 +0200 Subject: [PATCH 07/10] JSON refactor: move retraction_hop_after_extruder_switch to Travel category (CURA-2727) --- resources/definitions/fdmprinter.def.json | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 70ca9e7110..2862dfb857 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -1373,15 +1373,6 @@ "settable_per_extruder": true } } - }, - "retraction_hop_after_extruder_switch": { - "label": "Z Hop After Extruder Switch", - "description": "After the machine switched from one extruder to the other, the build plate is lowered to create clearance between the nozzle and the print. This prevents the nozzle from leaving oozed material on the outside of a print.", - "type": "bool", - "default_value": true, - "enabled": "retraction_hop_enabled", - "settable_per_mesh": false, - "settable_per_extruder": true } } }, @@ -2186,6 +2177,15 @@ "enabled": "retraction_enable and retraction_hop_enabled", "settable_per_mesh": false, "settable_per_extruder": true + }, + "retraction_hop_after_extruder_switch": { + "label": "Z Hop After Extruder Switch", + "description": "After the machine switched from one extruder to the other, the build plate is lowered to create clearance between the nozzle and the print. This prevents the nozzle from leaving oozed material on the outside of a print.", + "type": "bool", + "default_value": true, + "enabled": "retraction_hop_enabled", + "settable_per_mesh": false, + "settable_per_extruder": true } } }, From 97808958123dacc0a2e027dbe22519461bf3ac83 Mon Sep 17 00:00:00 2001 From: Tim Kuipers Date: Wed, 19 Oct 2016 13:05:10 +0200 Subject: [PATCH 08/10] JSON fix: retraction_hop_after_extruder_switch only visible for dual extrusion (CURA-2727) --- 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 2862dfb857..cd23b9d677 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -2183,7 +2183,7 @@ "description": "After the machine switched from one extruder to the other, the build plate is lowered to create clearance between the nozzle and the print. This prevents the nozzle from leaving oozed material on the outside of a print.", "type": "bool", "default_value": true, - "enabled": "retraction_hop_enabled", + "enabled": "retraction_hop_enabled and machine_extruder_count > 1", "settable_per_mesh": false, "settable_per_extruder": true } From 8cebaedd0ce5a32a9d97c5a89b813d3fb4e32e37 Mon Sep 17 00:00:00 2001 From: Tim Kuipers Date: Wed, 19 Oct 2016 13:14:06 +0200 Subject: [PATCH 09/10] JSOn refactor: moved support extruder settings to support catgegory (CURA-2707) --- cura/CuraApplication.py | 2 +- resources/definitions/fdmprinter.def.json | 90 +++++++++++------------ 2 files changed, 46 insertions(+), 46 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index b7092c4eaa..56690cf76c 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -283,6 +283,7 @@ class CuraApplication(QtApplication): cool_fan_enabled support support_enable + support_extruder_nr support_type support_interface_density platform_adhesion @@ -293,7 +294,6 @@ class CuraApplication(QtApplication): raft_surface_layers dual adhesion_extruder_nr - support_extruder_nr prime_tower_enable prime_tower_size prime_tower_position_x diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index cd23b9d677..b530cdf346 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -2343,6 +2343,51 @@ "settable_per_mesh": true, "settable_per_extruder": false }, + "support_extruder_nr": + { + "label": "Support Extruder", + "description": "The extruder train to use for printing the support. This is used in multi-extrusion.", + "type": "extruder", + "default_value": "0", + "enabled": "support_enable and machine_extruder_count > 1", + "settable_per_mesh": false, + "settable_per_extruder": false, + "children": { + "support_infill_extruder_nr": + { + "label": "Support Infill Extruder", + "description": "The extruder train to use for printing the infill of the support. This is used in multi-extrusion.", + "type": "extruder", + "default_value": "0", + "value": "support_extruder_nr", + "enabled": "support_enable and machine_extruder_count > 1", + "settable_per_mesh": false, + "settable_per_extruder": false + }, + "support_extruder_nr_layer_0": + { + "label": "First Layer Support Extruder", + "description": "The extruder train to use for printing the first layer of support infill. This is used in multi-extrusion.", + "type": "extruder", + "default_value": "0", + "value": "support_extruder_nr", + "enabled": "support_enable and machine_extruder_count > 1", + "settable_per_mesh": false, + "settable_per_extruder": false + }, + "support_interface_extruder_nr": + { + "label": "Support Interface Extruder", + "description": "The extruder train to use for printing the roofs and bottoms of the support. This is used in multi-extrusion.", + "type": "extruder", + "default_value": "0", + "value": "support_extruder_nr", + "enabled": "support_enable and machine_extruder_count > 1", + "settable_per_mesh": false, + "settable_per_extruder": false + } + } + }, "support_type": { "label": "Support Placement", @@ -3328,51 +3373,6 @@ "settable_per_mesh": false, "settable_per_extruder": false }, - "support_extruder_nr": - { - "label": "Support Extruder", - "description": "The extruder train to use for printing the support. This is used in multi-extrusion.", - "type": "extruder", - "default_value": "0", - "enabled": "support_enable and machine_extruder_count > 1", - "settable_per_mesh": false, - "settable_per_extruder": false, - "children": { - "support_infill_extruder_nr": - { - "label": "Support Infill Extruder", - "description": "The extruder train to use for printing the infill of the support. This is used in multi-extrusion.", - "type": "extruder", - "default_value": "0", - "value": "support_extruder_nr", - "enabled": "support_enable and machine_extruder_count > 1", - "settable_per_mesh": false, - "settable_per_extruder": false - }, - "support_extruder_nr_layer_0": - { - "label": "First Layer Support Extruder", - "description": "The extruder train to use for printing the first layer of support infill. This is used in multi-extrusion.", - "type": "extruder", - "default_value": "0", - "value": "support_extruder_nr", - "enabled": "support_enable and machine_extruder_count > 1", - "settable_per_mesh": false, - "settable_per_extruder": false - }, - "support_interface_extruder_nr": - { - "label": "Support Interface Extruder", - "description": "The extruder train to use for printing the roofs and bottoms of the support. This is used in multi-extrusion.", - "type": "extruder", - "default_value": "0", - "value": "support_extruder_nr", - "enabled": "support_enable and machine_extruder_count > 1", - "settable_per_mesh": false, - "settable_per_extruder": false - } - } - }, "prime_tower_enable": { "label": "Enable Prime Tower", From c7c3d24974e9436796bf3c978e7b97d453635941 Mon Sep 17 00:00:00 2001 From: Tim Kuipers Date: Wed, 19 Oct 2016 13:14:22 +0200 Subject: [PATCH 10/10] fix: adhesion_extruder_nr moved category also for default visibility (CURA-2707) --- cura/CuraApplication.py | 2 +- resources/definitions/fdmprinter.def.json | 20 ++++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 56690cf76c..7c45408488 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -288,12 +288,12 @@ class CuraApplication(QtApplication): support_interface_density platform_adhesion adhesion_type + adhesion_extruder_nr brim_width raft_airgap layer_0_z_overlap raft_surface_layers dual - adhesion_extruder_nr prime_tower_enable prime_tower_size prime_tower_position_x diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index b530cdf346..dfca058d4e 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -2826,6 +2826,16 @@ "settable_per_mesh": false, "settable_per_extruder": false }, + "adhesion_extruder_nr": + { + "label": "Build Plate Adhesion Extruder", + "description": "The extruder train to use for printing the skirt/brim/raft. This is used in multi-extrusion.", + "type": "extruder", + "default_value": "0", + "enabled": "machine_extruder_count > 1", + "settable_per_mesh": false, + "settable_per_extruder": false + }, "skirt_line_count": { "label": "Skirt Line Count", @@ -3363,16 +3373,6 @@ "enabled": "machine_extruder_count > 1", "children": { - "adhesion_extruder_nr": - { - "label": "Build Plate Adhesion Extruder", - "description": "The extruder train to use for printing the skirt/brim/raft. This is used in multi-extrusion.", - "type": "extruder", - "default_value": "0", - "enabled": "machine_extruder_count > 1", - "settable_per_mesh": false, - "settable_per_extruder": false - }, "prime_tower_enable": { "label": "Enable Prime Tower",