From 6aca44a72d4d2c0b4201ca778dc9bf1edd8eb7a7 Mon Sep 17 00:00:00 2001 From: Thomas Karl Pietrowski Date: Wed, 30 Aug 2017 19:32:19 +0200 Subject: [PATCH 01/19] Install cura icon on Linux This commit is needed for https://github.com/probonopd/Cura/commit/b9970d57b48b31f217f08fb652e5e39f1e55f3bb Never tested it, but believing the author of the commit that this change will work. --- CMakeLists.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index bdcd8f44c2..7870759cd1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -52,6 +52,8 @@ if(NOT APPLE AND NOT WIN32) DESTINATION lib/python${PYTHON_VERSION_MAJOR}/dist-packages/cura) install(FILES ${CMAKE_BINARY_DIR}/cura.desktop DESTINATION ${CMAKE_INSTALL_DATADIR}/applications) + install(FILES ${CMAKE_SOURCE_DIR}/resources/images/cura-icon.png + DESTINATION ${CMAKE_INSTALL_DATADIR}/icons/hicolor/128x128/apps/) install(FILES cura.appdata.xml DESTINATION ${CMAKE_INSTALL_DATADIR}/appdata) install(FILES cura.sharedmimeinfo From 6ad61153271cb4e09e042076891f18fa419e420b Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Thu, 21 Mar 2019 16:07:26 +0100 Subject: [PATCH 02/19] Modify the firmware checker url to use the new file location --- resources/definitions/ultimaker3.def.json | 3 +-- resources/definitions/ultimaker_s5.def.json | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/resources/definitions/ultimaker3.def.json b/resources/definitions/ultimaker3.def.json index 9e017688a2..6e01390703 100644 --- a/resources/definitions/ultimaker3.def.json +++ b/resources/definitions/ultimaker3.def.json @@ -29,8 +29,7 @@ "id": 9066, "check_urls": [ - "http://software.ultimaker.com/jedi/releases/latest.version?utm_source=cura&utm_medium=software&utm_campaign=resources", - "http://software.ultimaker.com/releases/firmware/9066/stable/version.txt" + "http://software.ultimaker.com/releases/firmware/9066/stable/um-update.swu.version" ], "update_url": "https://ultimaker.com/firmware" } diff --git a/resources/definitions/ultimaker_s5.def.json b/resources/definitions/ultimaker_s5.def.json index 310765dbc3..3f24673e6d 100644 --- a/resources/definitions/ultimaker_s5.def.json +++ b/resources/definitions/ultimaker_s5.def.json @@ -33,7 +33,7 @@ "weight": -1, "firmware_update_info": { "id": 9051, - "check_urls": ["http://software.ultimaker.com/releases/firmware/9051/stable/version.txt"], + "check_urls": ["http://software.ultimaker.com/releases/firmware/9051/stable/um-update.swu.version"], "update_url": "https://ultimaker.com/firmware" } }, From 294b61937a147b6fe5ac1bb7d08a4cef7bd4ab96 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Thu, 21 Mar 2019 21:10:12 +0100 Subject: [PATCH 03/19] Re-enable Polish --- resources/qml/Preferences/GeneralPage.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/qml/Preferences/GeneralPage.qml b/resources/qml/Preferences/GeneralPage.qml index e8519c6abf..47cc11632c 100644 --- a/resources/qml/Preferences/GeneralPage.qml +++ b/resources/qml/Preferences/GeneralPage.qml @@ -154,7 +154,7 @@ UM.PreferencesPage append({ text: "日本語", code: "ja_JP" }) append({ text: "한국어", code: "ko_KR" }) append({ text: "Nederlands", code: "nl_NL" }) - //Polish is disabled for being incomplete: append({ text: "Polski", code: "pl_PL" }) + append({ text: "Polski", code: "pl_PL" }) append({ text: "Português do Brasil", code: "pt_BR" }) append({ text: "Português", code: "pt_PT" }) append({ text: "Русский", code: "ru_RU" }) From 9a5b7e7925717015c6522589483c2acd7cafc614 Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Fri, 22 Mar 2019 10:44:47 +0100 Subject: [PATCH 04/19] Set min value for adaptive_layer_height_variation_step This is to prevent using 0, since that crashes the engine --- resources/definitions/fdmprinter.def.json | 1 + 1 file changed, 1 insertion(+) diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 1e39576391..da4ccefac0 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -6677,6 +6677,7 @@ "default_value": 0.01, "unit": "mm", "settable_per_mesh": false, + "minimum_value": "0.0001", "settable_per_extruder": false, "settable_per_meshgroup": false }, From 709321fc0ca8f9ee63c0b09d584f03150957ce5c Mon Sep 17 00:00:00 2001 From: Tim Kuipers Date: Fri, 22 Mar 2019 11:22:30 +0100 Subject: [PATCH 05/19] Change image import options for standard lithophanes --- plugins/ImageReader/ConfigUI.qml | 4 ++-- plugins/ImageReader/ImageReaderUI.py | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/plugins/ImageReader/ConfigUI.qml b/plugins/ImageReader/ConfigUI.qml index b9ff2e4453..87e155846b 100644 --- a/plugins/ImageReader/ConfigUI.qml +++ b/plugins/ImageReader/ConfigUI.qml @@ -123,7 +123,7 @@ UM.Dialog UM.TooltipArea { Layout.fillWidth:true height: childrenRect.height - text: catalog.i18nc("@info:tooltip","By default, white pixels represent high points on the mesh and black pixels represent low points on the mesh. Change this option to reverse the behavior such that black pixels represent high points on the mesh and white pixels represent low points on the mesh.") + text: catalog.i18nc("@info:tooltip","By default, black pixels represent high points on the mesh and white pixels represent low points on the mesh. Change this option to reverse the behavior such that white pixels represent high points on the mesh and black pixels represent low points on the mesh. ") Row { width: parent.width @@ -136,7 +136,7 @@ UM.Dialog ComboBox { id: image_color_invert objectName: "Image_Color_Invert" - model: [ catalog.i18nc("@item:inlistbox","Lighter is higher"), catalog.i18nc("@item:inlistbox","Darker is higher") ] + model: [ catalog.i18nc("@item:inlistbox","Darker is higher"), catalog.i18nc("@item:inlistbox","Lighter is higher") ] width: 180 * screenScaleFactor onCurrentIndexChanged: { manager.onImageColorInvertChanged(currentIndex) } } diff --git a/plugins/ImageReader/ImageReaderUI.py b/plugins/ImageReader/ImageReaderUI.py index cb45afa4ad..ab5ec239ba 100644 --- a/plugins/ImageReader/ImageReaderUI.py +++ b/plugins/ImageReader/ImageReaderUI.py @@ -30,10 +30,10 @@ class ImageReaderUI(QObject): self._width = self.default_width self._depth = self.default_depth - self.base_height = 1 - self.peak_height = 10 + self.base_height = 0.4 + self.peak_height = 2.5 self.smoothing = 1 - self.image_color_invert = False; + self.image_color_invert = True; self._ui_lock = threading.Lock() self._cancelled = False From bdf102ea64dd9206c175e6e97c81238cadcb3712 Mon Sep 17 00:00:00 2001 From: Tim Kuipers Date: Fri, 22 Mar 2019 11:30:58 +0100 Subject: [PATCH 06/19] make description of color invert explanatory, rather than purely descriptive. --- plugins/ImageReader/ConfigUI.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/ImageReader/ConfigUI.qml b/plugins/ImageReader/ConfigUI.qml index 87e155846b..42b93be918 100644 --- a/plugins/ImageReader/ConfigUI.qml +++ b/plugins/ImageReader/ConfigUI.qml @@ -123,7 +123,7 @@ UM.Dialog UM.TooltipArea { Layout.fillWidth:true height: childrenRect.height - text: catalog.i18nc("@info:tooltip","By default, black pixels represent high points on the mesh and white pixels represent low points on the mesh. Change this option to reverse the behavior such that white pixels represent high points on the mesh and black pixels represent low points on the mesh. ") + text: catalog.i18nc("@info:tooltip","For lithophanes dark pixels should correspond to thicker locations in order to block more light coming through. For height maps lighter pixels signify higher terrain, so lighter pixels should correspond to thicker locations in the generated 3D model.") Row { width: parent.width From 32d79451cc2b0cf51282297f4b8b49d69d4bb994 Mon Sep 17 00:00:00 2001 From: Tim Kuipers Date: Fri, 22 Mar 2019 11:42:31 +0100 Subject: [PATCH 07/19] fix color inversion and make variable naming descriptive --- plugins/ImageReader/ConfigUI.qml | 4 ++-- plugins/ImageReader/ImageReader.py | 6 +++--- plugins/ImageReader/ImageReaderUI.py | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/plugins/ImageReader/ConfigUI.qml b/plugins/ImageReader/ConfigUI.qml index 42b93be918..47ba10778c 100644 --- a/plugins/ImageReader/ConfigUI.qml +++ b/plugins/ImageReader/ConfigUI.qml @@ -134,8 +134,8 @@ UM.Dialog anchors.verticalCenter: parent.verticalCenter } ComboBox { - id: image_color_invert - objectName: "Image_Color_Invert" + id: lighter_is_higher + objectName: "Lighter_Is_Higher" model: [ catalog.i18nc("@item:inlistbox","Darker is higher"), catalog.i18nc("@item:inlistbox","Lighter is higher") ] width: 180 * screenScaleFactor onCurrentIndexChanged: { manager.onImageColorInvertChanged(currentIndex) } diff --git a/plugins/ImageReader/ImageReader.py b/plugins/ImageReader/ImageReader.py index 5195b61595..e720ce4854 100644 --- a/plugins/ImageReader/ImageReader.py +++ b/plugins/ImageReader/ImageReader.py @@ -46,9 +46,9 @@ class ImageReader(MeshReader): def _read(self, file_name): size = max(self._ui.getWidth(), self._ui.getDepth()) - return self._generateSceneNode(file_name, size, self._ui.peak_height, self._ui.base_height, self._ui.smoothing, 512, self._ui.image_color_invert) + return self._generateSceneNode(file_name, size, self._ui.peak_height, self._ui.base_height, self._ui.smoothing, 512, self._ui.lighter_is_higher) - def _generateSceneNode(self, file_name, xz_size, peak_height, base_height, blur_iterations, max_size, image_color_invert): + def _generateSceneNode(self, file_name, xz_size, peak_height, base_height, blur_iterations, max_size, lighter_is_higher): scene_node = SceneNode() mesh = MeshBuilder() @@ -104,7 +104,7 @@ class ImageReader(MeshReader): Job.yieldThread() - if image_color_invert: + if not lighter_is_higher: height_data = 1 - height_data for _ in range(0, blur_iterations): diff --git a/plugins/ImageReader/ImageReaderUI.py b/plugins/ImageReader/ImageReaderUI.py index ab5ec239ba..213468a2ab 100644 --- a/plugins/ImageReader/ImageReaderUI.py +++ b/plugins/ImageReader/ImageReaderUI.py @@ -33,7 +33,7 @@ class ImageReaderUI(QObject): self.base_height = 0.4 self.peak_height = 2.5 self.smoothing = 1 - self.image_color_invert = True; + self.lighter_is_higher = False; self._ui_lock = threading.Lock() self._cancelled = False @@ -143,4 +143,4 @@ class ImageReaderUI(QObject): @pyqtSlot(int) def onImageColorInvertChanged(self, value): - self.image_color_invert = (value == 1) + self.lighter_is_higher = (value == 1) From 794d13969a78c8ec5c1de20ca7faa16efcf74417 Mon Sep 17 00:00:00 2001 From: Remco Burema Date: Fri, 22 Mar 2019 12:06:04 +0100 Subject: [PATCH 08/19] Shorter log messages for operations. --- cura/Operations/PlatformPhysicsOperation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cura/Operations/PlatformPhysicsOperation.py b/cura/Operations/PlatformPhysicsOperation.py index 75c5b437bc..9571679c3c 100644 --- a/cura/Operations/PlatformPhysicsOperation.py +++ b/cura/Operations/PlatformPhysicsOperation.py @@ -29,4 +29,4 @@ class PlatformPhysicsOperation(Operation): return group def __repr__(self): - return "PlatformPhysicsOperation(translation = {0})".format(self._translation) + return "PlatformPhysicsOp.(trans.={0})".format(self._translation) From fc650865d61574c3c6508d9668783aede04216d2 Mon Sep 17 00:00:00 2001 From: Ian Paschal Date: Fri, 22 Mar 2019 15:24:12 +0100 Subject: [PATCH 09/19] Improved cloud pop-up Contributes to CL-1287 --- plugins/UM3NetworkPrinting/src/Cloud/CloudProgressMessage.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/UM3NetworkPrinting/src/Cloud/CloudProgressMessage.py b/plugins/UM3NetworkPrinting/src/Cloud/CloudProgressMessage.py index d85f49c1a0..943bef2bc1 100644 --- a/plugins/UM3NetworkPrinting/src/Cloud/CloudProgressMessage.py +++ b/plugins/UM3NetworkPrinting/src/Cloud/CloudProgressMessage.py @@ -11,8 +11,8 @@ I18N_CATALOG = i18nCatalog("cura") class CloudProgressMessage(Message): def __init__(self): super().__init__( - text = I18N_CATALOG.i18nc("@info:status", "Sending data to remote cluster"), - title = I18N_CATALOG.i18nc("@info:status", "Sending data to remote cluster"), + title = I18N_CATALOG.i18nc("@info:status", "Sending Print Job"), + text = I18N_CATALOG.i18nc("@info:status", "Uploading via Ultimaker Cloud"), progress = -1, lifetime = 0, dismissable = False, From a793a06b609c6e5c33db84e9c400c9c464b16469 Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Fri, 22 Mar 2019 17:10:42 +0100 Subject: [PATCH 10/19] Add a maximumWidth to the ActionButton In case the text is too long, it can exceed the limits of the container. This is an optional flag that will work only in case it's set up. Contributes to CURA-6412. --- resources/qml/ActionButton.qml | 6 +++++- resources/qml/PrinterSelector/MachineSelector.qml | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/resources/qml/ActionButton.qml b/resources/qml/ActionButton.qml index e4e2aedb8a..905863a561 100644 --- a/resources/qml/ActionButton.qml +++ b/resources/qml/ActionButton.qml @@ -40,6 +40,10 @@ Button // we elide the text to the right so the text will be cut off with the three dots at the end. property var fixedWidthMode: false + // This property is used when the space for the button is limited. In case the button needs to grow with the text, + // but it can exceed a maximum, then this value have to be set. + property int maximumWidth: 0 + leftPadding: UM.Theme.getSize("default_margin").width rightPadding: UM.Theme.getSize("default_margin").width height: UM.Theme.getSize("action_button").height @@ -73,7 +77,7 @@ Button renderType: Text.NativeRendering height: parent.height anchors.verticalCenter: parent.verticalCenter - width: fixedWidthMode ? button.width - button.leftPadding - button.rightPadding : undefined + width: fixedWidthMode ? button.width - button.leftPadding - button.rightPadding : ((maximumWidth != 0 && contentWidth > maximumWidth) ? maximumWidth : undefined) horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter elide: Text.ElideRight diff --git a/resources/qml/PrinterSelector/MachineSelector.qml b/resources/qml/PrinterSelector/MachineSelector.qml index e9452f4d35..c632c5ee11 100644 --- a/resources/qml/PrinterSelector/MachineSelector.qml +++ b/resources/qml/PrinterSelector/MachineSelector.qml @@ -159,6 +159,7 @@ Cura.ExpandablePopup leftPadding: UM.Theme.getSize("default_margin").width rightPadding: UM.Theme.getSize("default_margin").width text: catalog.i18nc("@button", "Add printer") + maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - 2.5 * UM.Theme.getSize("default_margin").width onClicked: { toggleContent() @@ -171,6 +172,7 @@ Cura.ExpandablePopup leftPadding: UM.Theme.getSize("default_margin").width rightPadding: UM.Theme.getSize("default_margin").width text: catalog.i18nc("@button", "Manage printers") + maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - 2.5 * UM.Theme.getSize("default_margin").width onClicked: { toggleContent() From 74ffee78109a9b3fe252c98be2533d9db9371959 Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Fri, 22 Mar 2019 18:03:01 +0100 Subject: [PATCH 11/19] Fix typo in a previous commit --- plugins/Toolbox/resources/qml/ToolboxDownloadsGridTile.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/Toolbox/resources/qml/ToolboxDownloadsGridTile.qml b/plugins/Toolbox/resources/qml/ToolboxDownloadsGridTile.qml index 7844a5c394..73dd593336 100644 --- a/plugins/Toolbox/resources/qml/ToolboxDownloadsGridTile.qml +++ b/plugins/Toolbox/resources/qml/ToolboxDownloadsGridTile.qml @@ -76,7 +76,7 @@ Item height: (parent.height * 0.4) | 0 anchors { - bottom: parent.bottomcommi + bottom: parent.bottom right: parent.right } sourceSize.height: height From 8b0e1e9f5dc87b33ad7f0f18e13c4aa0f61b2d75 Mon Sep 17 00:00:00 2001 From: Thomas Karl Pietrowski Date: Fri, 22 Mar 2019 19:42:01 +0100 Subject: [PATCH 12/19] PrintSetupSelector: "G code" -> "G-code" Noticed that "g-code" is written at some places with and without a hyphen. Since it think it should be written with, I'm correcting it at this point. --- resources/qml/PrintSetupSelector/PrintSetupSelector.qml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/qml/PrintSetupSelector/PrintSetupSelector.qml b/resources/qml/PrintSetupSelector/PrintSetupSelector.qml index 48ac07679d..48b6d191c2 100644 --- a/resources/qml/PrintSetupSelector/PrintSetupSelector.qml +++ b/resources/qml/PrintSetupSelector/PrintSetupSelector.qml @@ -16,7 +16,7 @@ Cura.ExpandableComponent contentPadding: UM.Theme.getSize("default_lining").width contentHeaderTitle: catalog.i18nc("@label", "Print settings") enabled: !preSlicedData - disabledText: catalog.i18nc("@label shown when we load a Gcode file", "Print setup disabled. G code file can not be modified.") + disabledText: catalog.i18nc("@label shown when we load a Gcode file", "Print setup disabled. G-code file can not be modified.") UM.I18nCatalog { @@ -32,4 +32,4 @@ Cura.ExpandableComponent onExpandedChanged: UM.Preferences.setValue("view/settings_visible", expanded) Component.onCompleted: expanded = UM.Preferences.getValue("view/settings_visible") -} \ No newline at end of file +} From 7958f99152ad09ed301457ac266d48cd26622c84 Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Mon, 25 Mar 2019 11:59:28 +0100 Subject: [PATCH 13/19] Update the list of check urls for UM3 Extended --- resources/definitions/ultimaker3_extended.def.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/resources/definitions/ultimaker3_extended.def.json b/resources/definitions/ultimaker3_extended.def.json index 68f26969b7..43f7b94e61 100644 --- a/resources/definitions/ultimaker3_extended.def.json +++ b/resources/definitions/ultimaker3_extended.def.json @@ -28,8 +28,7 @@ "id": 9511, "check_urls": [ - "http://software.ultimaker.com/jedi/releases/latest.version?utm_source=cura&utm_medium=software&utm_campaign=resources", - "http://software.ultimaker.com/releases/firmware/9511/stable/version.txt" + "http://software.ultimaker.com/releases/firmware/9066/stable/um-update.swu.version" ], "update_url": "https://ultimaker.com/firmware" } From 14b409a89504d49b0103feb8ae4f4c42c1407938 Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Mon, 25 Mar 2019 12:59:05 +0100 Subject: [PATCH 14/19] Exclude gff and cff materials for all ultimaker printers except UMS5 Contributes to CURA-6089. --- resources/definitions/ultimaker2.def.json | 1 - resources/definitions/ultimaker2_plus.def.json | 1 + resources/definitions/ultimaker3.def.json | 1 + resources/definitions/ultimaker_original.def.json | 2 +- resources/definitions/ultimaker_original_dual.def.json | 2 +- 5 files changed, 4 insertions(+), 3 deletions(-) diff --git a/resources/definitions/ultimaker2.def.json b/resources/definitions/ultimaker2.def.json index 4cc291ff45..88731bc297 100644 --- a/resources/definitions/ultimaker2.def.json +++ b/resources/definitions/ultimaker2.def.json @@ -14,7 +14,6 @@ "has_materials": false, "has_machine_quality": true, "preferred_variant_name": "0.4 mm", - "exclude_materials": ["generic_hips", "generic_petg", "generic_bam", "ultimaker_bam", "generic_pva", "ultimaker_pva", "generic_tough_pla", "ultimaker_tough_pla_black", "ultimaker_tough_pla_green", "ultimaker_tough_pla_red", "ultimaker_tough_pla_white"], "first_start_actions": ["UM2UpgradeSelection"], "supported_actions":["UM2UpgradeSelection"], "machine_extruder_trains": diff --git a/resources/definitions/ultimaker2_plus.def.json b/resources/definitions/ultimaker2_plus.def.json index 28fd2b71f9..dd97e944d6 100644 --- a/resources/definitions/ultimaker2_plus.def.json +++ b/resources/definitions/ultimaker2_plus.def.json @@ -14,6 +14,7 @@ "has_materials": true, "has_machine_materials": true, "has_machine_quality": true, + "exclude_materials": ["generic_hips", "generic_petg", "generic_bam", "ultimaker_bam", "generic_pva", "ultimaker_pva", "generic_tough_pla", "ultimaker_tough_pla_black", "ultimaker_tough_pla_green", "ultimaker_tough_pla_red", "ultimaker_tough_pla_white", "generic_cffcpe", "generic_cffpa", "generic_gffcpe", "generic_gffpa", "structur3d_dap100silicone" ], "first_start_actions": [], "supported_actions": [], "machine_extruder_trains": diff --git a/resources/definitions/ultimaker3.def.json b/resources/definitions/ultimaker3.def.json index 6e01390703..e730a156ff 100644 --- a/resources/definitions/ultimaker3.def.json +++ b/resources/definitions/ultimaker3.def.json @@ -14,6 +14,7 @@ "has_materials": true, "has_machine_materials": true, "has_variants": true, + "exclude_materials": [ "generic_cffcpe", "generic_cffpa", "generic_gffcpe", "generic_gffpa", "structur3d_dap100silicone" ], "preferred_variant_name": "AA 0.4", "preferred_quality_type": "normal", "variants_name": "Print core", diff --git a/resources/definitions/ultimaker_original.def.json b/resources/definitions/ultimaker_original.def.json index 6a978c47cb..5078e4747f 100644 --- a/resources/definitions/ultimaker_original.def.json +++ b/resources/definitions/ultimaker_original.def.json @@ -11,7 +11,7 @@ "platform": "ultimaker_platform.stl", "has_materials": true, "has_machine_quality": true, - "exclude_materials": ["generic_hips", "generic_petg", "generic_bam", "ultimaker_bam", "generic_pva", "ultimaker_pva", "generic_tough_pla", "ultimaker_tough_pla_black", "ultimaker_tough_pla_green", "ultimaker_tough_pla_red", "ultimaker_tough_pla_white"], + "exclude_materials": ["generic_hips", "generic_petg", "generic_bam", "ultimaker_bam", "generic_pva", "ultimaker_pva", "generic_tough_pla", "ultimaker_tough_pla_black", "ultimaker_tough_pla_green", "ultimaker_tough_pla_red", "ultimaker_tough_pla_white", "generic_cffcpe", "generic_cffpa", "generic_gffcpe", "generic_gffpa", "structur3d_dap100silicone" ], "first_start_actions": ["UMOUpgradeSelection", "UMOCheckup", "BedLevel"], "supported_actions": ["UMOUpgradeSelection", "UMOCheckup", "BedLevel"], "machine_extruder_trains": diff --git a/resources/definitions/ultimaker_original_dual.def.json b/resources/definitions/ultimaker_original_dual.def.json index 999650aa28..8e44dc9a7d 100644 --- a/resources/definitions/ultimaker_original_dual.def.json +++ b/resources/definitions/ultimaker_original_dual.def.json @@ -12,7 +12,7 @@ "has_materials": true, "has_machine_quality": true, "quality_definition": "ultimaker_original", - "exclude_materials": ["generic_hips", "generic_petg", "generic_bam", "ultimaker_bam", "generic_pva", "ultimaker_pva", "generic_tough_pla", "ultimaker_tough_pla_black", "ultimaker_tough_pla_green", "ultimaker_tough_pla_red", "ultimaker_tough_pla_white"], + "exclude_materials": ["generic_hips", "generic_petg", "generic_bam", "ultimaker_bam", "generic_pva", "ultimaker_pva", "generic_tough_pla", "ultimaker_tough_pla_black", "ultimaker_tough_pla_green", "ultimaker_tough_pla_red", "ultimaker_tough_pla_white", "generic_cffcpe", "generic_cffpa", "generic_gffcpe", "generic_gffpa", "structur3d_dap100silicone" ], "machine_extruder_trains": { "0": "ultimaker_original_dual_1st", From 85a7d814d8b26748b51ed518d7b78ee02030dc27 Mon Sep 17 00:00:00 2001 From: Satish Date: Mon, 25 Mar 2019 14:34:00 +0100 Subject: [PATCH 15/19] Added id to machine selector for integration tests --- resources/qml/PrinterSelector/MachineSelector.qml | 1 + 1 file changed, 1 insertion(+) diff --git a/resources/qml/PrinterSelector/MachineSelector.qml b/resources/qml/PrinterSelector/MachineSelector.qml index e9452f4d35..f781f62e4e 100644 --- a/resources/qml/PrinterSelector/MachineSelector.qml +++ b/resources/qml/PrinterSelector/MachineSelector.qml @@ -114,6 +114,7 @@ Cura.ExpandablePopup MachineSelectorList { + id: machineSelectorList // Can't use parent.width since the parent is the flickable component and not the ScrollView width: scroll.width - scroll.leftPadding - scroll.rightPadding property real maximumHeight: UM.Theme.getSize("machine_selector_widget_content").height - buttonRow.height From ff99c4e45f5a88ab303740a46b6fca0a5b36b2df Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Tue, 26 Mar 2019 10:00:10 +0100 Subject: [PATCH 16/19] Don't include group nodes in AABB In fact, don't include any node that would just have a position rather than actual data. The rest of the code is robust anyway against there being no AABB. Contributes to issue CURA-6416. --- cura/Scene/CuraSceneNode.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/cura/Scene/CuraSceneNode.py b/cura/Scene/CuraSceneNode.py index 259c273329..4fd8f2b983 100644 --- a/cura/Scene/CuraSceneNode.py +++ b/cura/Scene/CuraSceneNode.py @@ -112,21 +112,21 @@ class CuraSceneNode(SceneNode): ## Override of SceneNode._calculateAABB to exclude non-printing-meshes from bounding box def _calculateAABB(self) -> None: + self._aabb = None if self._mesh_data: - aabb = self._mesh_data.getExtents(self.getWorldTransformation()) - else: # If there is no mesh_data, use a boundingbox that encompasses the local (0,0,0) - position = self.getWorldPosition() - aabb = AxisAlignedBox(minimum = position, maximum = position) + self._aabb = self._mesh_data.getExtents(self.getWorldTransformation()) for child in self._children: if child.callDecoration("isNonPrintingMesh"): # Non-printing-meshes inside a group should not affect push apart or drop to build plate continue - if aabb is None: - aabb = child.getBoundingBox() + if not child._mesh_data: + # Nodes without mesh data should not affect bounding boxes of their parents. + continue + if self._aabb is None: + self._aabb = child.getBoundingBox() else: - aabb = aabb + child.getBoundingBox() - self._aabb = aabb + self._aabb = self._aabb + child.getBoundingBox() ## Taken from SceneNode, but replaced SceneNode with CuraSceneNode def __deepcopy__(self, memo: Dict[int, object]) -> "CuraSceneNode": From a4924d26951e7d9260ec66e78578c2d283935d39 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Tue, 26 Mar 2019 12:04:46 +0100 Subject: [PATCH 17/19] Fix for weird home directories on Windows The expanduser function will expand to a combination of HOMEDRIVE and HOMEPATH which might not be the same as APPDATA if your configuration is very weird (e.g. you've changed your APPDATA location). Contributes to CURA-6418. --- cura_app.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cura_app.py b/cura_app.py index 3224a5b99b..1978e0f5fd 100755 --- a/cura_app.py +++ b/cura_app.py @@ -23,7 +23,10 @@ known_args = vars(parser.parse_known_args()[0]) if not known_args["debug"]: def get_cura_dir_path(): if Platform.isWindows(): - return os.path.expanduser("~/AppData/Roaming/" + CuraAppName) + appdata_path = os.getenv("APPDATA") + if not appdata_path: #Defensive against the environment variable missing (should never happen). + appdata_path = "." + return os.path.join(appdata_path, CuraAppName) elif Platform.isLinux(): return os.path.expanduser("~/.local/share/" + CuraAppName) elif Platform.isOSX(): From 58507303fa6672ef71afb6f467a955b3baeba849 Mon Sep 17 00:00:00 2001 From: Lipu Fei Date: Wed, 27 Mar 2019 14:08:03 +0100 Subject: [PATCH 18/19] Duplicate qualities should have unique names CURA-6426 --- cura/Machines/QualityManager.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cura/Machines/QualityManager.py b/cura/Machines/QualityManager.py index b849b16169..ef1ff920fe 100644 --- a/cura/Machines/QualityManager.py +++ b/cura/Machines/QualityManager.py @@ -442,7 +442,8 @@ class QualityManager(QObject): quality_changes_group = quality_model_item["quality_changes_group"] if quality_changes_group is None: # create global quality changes only - new_quality_changes = self._createQualityChanges(quality_group.quality_type, quality_changes_name, + new_name = self._container_registry.uniqueName(quality_changes_name) + new_quality_changes = self._createQualityChanges(quality_group.quality_type, new_name, global_stack, None) self._container_registry.addContainer(new_quality_changes) else: From 742329a170c3932138f9508ea7656b49436915bd Mon Sep 17 00:00:00 2001 From: Diego Prado Gesto Date: Thu, 28 Mar 2019 09:29:31 +0100 Subject: [PATCH 19/19] Document where the magic numbers come from For the maximumSize of a button. Contributes to CURA-6412. --- resources/qml/PrinterSelector/MachineSelector.qml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/resources/qml/PrinterSelector/MachineSelector.qml b/resources/qml/PrinterSelector/MachineSelector.qml index c632c5ee11..f7ac3fdcba 100644 --- a/resources/qml/PrinterSelector/MachineSelector.qml +++ b/resources/qml/PrinterSelector/MachineSelector.qml @@ -159,7 +159,9 @@ Cura.ExpandablePopup leftPadding: UM.Theme.getSize("default_margin").width rightPadding: UM.Theme.getSize("default_margin").width text: catalog.i18nc("@button", "Add printer") - maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - 2.5 * UM.Theme.getSize("default_margin").width + // The maximum width of the button is half of the total space, minus the padding of the parent, the left + // padding of the component and half the spacing because of the space between buttons. + maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - parent.padding - leftPadding - parent.spacing / 2 onClicked: { toggleContent() @@ -172,7 +174,9 @@ Cura.ExpandablePopup leftPadding: UM.Theme.getSize("default_margin").width rightPadding: UM.Theme.getSize("default_margin").width text: catalog.i18nc("@button", "Manage printers") - maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - 2.5 * UM.Theme.getSize("default_margin").width + // The maximum width of the button is half of the total space, minus the padding of the parent, the right + // padding of the component and half the spacing because of the space between buttons. + maximumWidth: UM.Theme.getSize("machine_selector_widget_content").width / 2 - parent.padding - rightPadding - parent.spacing / 2 onClicked: { toggleContent()