From ac6ad5ec6c255b0c4983fd3498383d70876a01ff Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 11 Oct 2016 16:25:51 +0600 Subject: [PATCH 01/68] T466: Added plugin --- plugins/GCODEReader/GCODEReader.py | 40 ++++++++++++++++++++++++++++++ plugins/GCODEReader/__init__.py | 32 ++++++++++++++++++++++++ 2 files changed, 72 insertions(+) create mode 100644 plugins/GCODEReader/GCODEReader.py create mode 100644 plugins/GCODEReader/__init__.py diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py new file mode 100644 index 0000000000..ce6fd9075e --- /dev/null +++ b/plugins/GCODEReader/GCODEReader.py @@ -0,0 +1,40 @@ +# Copyright (c) 2015 Ultimaker B.V. +# Copyright (c) 2013 David Braam +# Uranium is released under the terms of the AGPLv3 or higher. + +from UM.Mesh.MeshReader import MeshReader +from UM.Mesh.MeshBuilder import MeshBuilder +import os +from UM.Scene.SceneNode import SceneNode +from UM.Math.Vector import Vector + +from UM.Job import Job + +class GCODEReader(MeshReader): + def __init__(self): + super(GCODEReader, self).__init__() + self._supported_extensions = [".gcode", ".g"] + + def read(self, file_name): + scene_node = None + + extension = os.path.splitext(file_name)[1] + if extension.lower() in self._supported_extensions: + scene_node = SceneNode() + + mesh_builder = MeshBuilder() + mesh_builder.setFileName(file_name) + + mesh_builder.addCube( + width=5, + height=5, + depth=5, + center=Vector(0, 2.5, 0) + ) + + scene_node.setMeshData(mesh_builder.build()) + + scene_node.setEnabled(False) + scene_node.setSelectable(False) + + return scene_node diff --git a/plugins/GCODEReader/__init__.py b/plugins/GCODEReader/__init__.py new file mode 100644 index 0000000000..f1572c077f --- /dev/null +++ b/plugins/GCODEReader/__init__.py @@ -0,0 +1,32 @@ +# Copyright (c) 2015 Ultimaker B.V. +# Uranium is released under the terms of the AGPLv3 or higher. + +#Shoopdawoop +from . import GCODEReader + +from UM.i18n import i18nCatalog +i18n_catalog = i18nCatalog("uranium") + +def getMetaData(): + return { + "plugin": { + "name": i18n_catalog.i18nc("@label", "GCODE Reader"), + "author": "Victor Larchenko", + "version": "1.0", + "description": i18n_catalog.i18nc("@info:whatsthis", "Makes it possbile to read GCODE files."), + "api": 3 + }, + "mesh_reader": [ + { + "extension": "gcode", + "description": i18n_catalog.i18nc("@item:inlistbox", "GCODE File") + }, + { + "extension": "g", + "description": i18n_catalog.i18nc("@item:inlistbox", "GCODE File") + } + ] + } + +def register(app): + return { "mesh_reader": GCODEReader.GCODEReader() } From b9514527dd4ce0a5da7834af338eb804a1399b57 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 11 Oct 2016 17:20:55 +0600 Subject: [PATCH 02/68] T466: Added test line --- plugins/GCODEReader/GCODEReader.py | 75 +++++++++++++++++++++++++----- plugins/LayerView/LayerPass.py | 8 +++- 2 files changed, 71 insertions(+), 12 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index ce6fd9075e..683355c9a3 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -7,6 +7,15 @@ from UM.Mesh.MeshBuilder import MeshBuilder import os from UM.Scene.SceneNode import SceneNode from UM.Math.Vector import Vector +from UM.Math.AxisAlignedBox import AxisAlignedBox +from UM.Application import Application + +from cura import LayerDataBuilder +from cura import LayerDataDecorator +from cura import LayerPolygon + +import numpy + from UM.Job import Job @@ -22,19 +31,63 @@ class GCODEReader(MeshReader): if extension.lower() in self._supported_extensions: scene_node = SceneNode() - mesh_builder = MeshBuilder() - mesh_builder.setFileName(file_name) + # mesh_builder = MeshBuilder() + # mesh_builder.setFileName(file_name) + # + # mesh_builder.addCube( + # width=5, + # height=5, + # depth=5, + # center=Vector(0, 2.5, 0) + # ) + # + # scene_node.setMeshData(mesh_builder.build()) - mesh_builder.addCube( - width=5, - height=5, - depth=5, - center=Vector(0, 2.5, 0) - ) + def getBoundingBox(): + return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) - scene_node.setMeshData(mesh_builder.build()) + scene_node.getBoundingBox = getBoundingBox + scene_node.gcode = True - scene_node.setEnabled(False) - scene_node.setSelectable(False) + layer_data = LayerDataBuilder.LayerDataBuilder() + layer_count = 1 + for id in range(layer_count): + layer_data.addLayer(id) + this_layer = layer_data.getLayer(id) + layer_data.setLayerHeight(id, 1) + layer_data.setLayerThickness(id, 1) + + extruder = 1 + line_types = numpy.empty((1, 1), numpy.int32) + line_types[0, 0] = 6 + line_widths = numpy.empty((1, 1), numpy.int32) + line_widths[0, 0] = 1 + points = numpy.empty((2, 3), numpy.float32) + points[0, 0] = 0 + points[0, 1] = 0 + points[0, 2] = 0 + points[1, 0] = 10 + points[1, 1] = 10 + points[1, 2] = 10 + + this_poly = LayerPolygon.LayerPolygon(layer_data, extruder, line_types, points, line_widths) + this_poly.buildCache() + + this_layer.polygons.append(this_poly) + + layer_mesh = layer_data.build() + decorator = LayerDataDecorator.LayerDataDecorator() + decorator.setLayerData(layer_mesh) + scene_node.addDecorator(decorator) + + scene_node_parent = Application.getInstance().getBuildVolume() + scene_node.setParent(scene_node_parent) + + view = Application.getInstance().getController().getActiveView() + if view.getPluginId() == "LayerView": + view.resetLayerData() + + #scene_node.setEnabled(False) + #scene_node.setSelectable(False) return scene_node diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index 8ff2eb16ec..cf3e5cd89a 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -45,10 +45,16 @@ class LayerPass(RenderPass): tool_handle_batch = RenderBatch(self._tool_handle_shader, type = RenderBatch.RenderType.Overlay) for node in DepthFirstIterator(self._scene.getRoot()): + flag = False + try: + flag = node.gcode + except AttributeError: + pass + if isinstance(node, ToolHandle): tool_handle_batch.addItem(node.getWorldTransformation(), mesh = node.getSolidMesh()) - elif isinstance(node, SceneNode) and node.getMeshData() and node.isVisible(): + elif isinstance(node, SceneNode) and (node.getMeshData() or flag) and node.isVisible(): layer_data = node.callDecoration("getLayerData") if not layer_data: continue From 65f3495a29ec30c5dc7a56e1d8cb5cfeb9794f32 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 12 Oct 2016 12:08:00 +0600 Subject: [PATCH 03/68] T466: Added pausing of backend work --- plugins/CuraEngineBackend/CuraEngineBackend.py | 5 ++++- plugins/GCODEReader/GCODEReader.py | 10 ++++++++++ plugins/LayerView/LayerPass.py | 7 +------ plugins/LayerView/LayerView.py | 8 +++++++- resources/qml/SaveButton.qml | 6 ++++++ 5 files changed, 28 insertions(+), 8 deletions(-) diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index b2df2563d0..4e1b2f6841 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -69,6 +69,8 @@ class CuraEngineBackend(Backend): self._scene = Application.getInstance().getController().getScene() self._scene.sceneChanged.connect(self._onSceneChanged) + self._pauseSlicing = False + # Workaround to disable layer view processing if layer view is not active. self._layer_view_active = False Application.getInstance().getController().activeViewChanged.connect(self._onActiveViewChanged) @@ -399,7 +401,8 @@ class CuraEngineBackend(Backend): # # This indicates that we should probably re-slice soon. def _onChanged(self, *args, **kwargs): - self._change_timer.start() + if not self._pauseSlicing: + self._change_timer.start() ## Called when the back-end connects to the front-end. def _onBackendConnected(self): diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 683355c9a3..6001edca67 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -48,6 +48,16 @@ class GCODEReader(MeshReader): scene_node.getBoundingBox = getBoundingBox scene_node.gcode = True + backend = Application.getInstance().getBackend() + backend._pauseSlicing = True + backend.backendStateChange.emit(0) + + mesh_builder = MeshBuilder() + mesh_builder.setFileName(file_name) + + mesh_builder.addCube(10,10,10) + + scene_node.setMeshData(mesh_builder.build()) layer_data = LayerDataBuilder.LayerDataBuilder() layer_count = 1 diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index cf3e5cd89a..287f3c3539 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -45,16 +45,11 @@ class LayerPass(RenderPass): tool_handle_batch = RenderBatch(self._tool_handle_shader, type = RenderBatch.RenderType.Overlay) for node in DepthFirstIterator(self._scene.getRoot()): - flag = False - try: - flag = node.gcode - except AttributeError: - pass if isinstance(node, ToolHandle): tool_handle_batch.addItem(node.getWorldTransformation(), mesh = node.getSolidMesh()) - elif isinstance(node, SceneNode) and (node.getMeshData() or flag) and node.isVisible(): + elif isinstance(node, SceneNode) and (node.getMeshData()) and node.isVisible(): layer_data = node.callDecoration("getLayerData") if not layer_data: continue diff --git a/plugins/LayerView/LayerView.py b/plugins/LayerView/LayerView.py index 50c13194f7..0736fe6dac 100644 --- a/plugins/LayerView/LayerView.py +++ b/plugins/LayerView/LayerView.py @@ -118,8 +118,14 @@ class LayerView(View): if type(node) is ConvexHullNode and not Selection.isSelected(node.getWatchedNode()): continue + flag = False + try: + flag = node.gcode + except AttributeError: + pass + if not node.render(renderer): - if node.getMeshData() and node.isVisible(): + if node.getMeshData() and node.isVisible() and not flag: renderer.queueNode(node, transparent = True, shader = self._ghost_shader) def setLayer(self, value): diff --git a/resources/qml/SaveButton.qml b/resources/qml/SaveButton.qml index 9b63fccf94..a25aae7a5e 100644 --- a/resources/qml/SaveButton.qml +++ b/resources/qml/SaveButton.qml @@ -14,6 +14,7 @@ Rectangle { property real progress: UM.Backend.progress; property int backendState: UM.Backend.state; + property bool backendPaused: UM.Backend.paused; property bool activity: Printer.getPlatformActivity; property int totalHeight: childrenRect.height + UM.Theme.getSize("default_margin").height property string fileBaseName @@ -24,6 +25,11 @@ Rectangle { return catalog.i18nc("@label:PrintjobStatus", "Please load a 3d model"); } + if (backendPaused) + { + return catalog.i18nc("@label:PrintjobStatus", "Slicing temporary disabled"); + } + switch(base.backendState) { case 1: From 8aa3b1b38cb367ba736f485b63345772df0d2b1a Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 12 Oct 2016 14:23:12 +0600 Subject: [PATCH 04/68] T466: Added basic file loading and parsing --- plugins/GCODEReader/GCODEReader.py | 138 +++++++++++++++++++++++------ plugins/LayerView/LayerView.py | 8 +- 2 files changed, 110 insertions(+), 36 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 6001edca67..fc5c0c45ac 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -24,6 +24,36 @@ class GCODEReader(MeshReader): super(GCODEReader, self).__init__() self._supported_extensions = [".gcode", ".g"] + def getInt(self, line, code): + n = line.find(code) + 1 + if n < 1: + return None + m = line.find(' ', n) + m2 = line.find(';', n) + if m < 0: + m = m2 + try: + if m < 0: + return int(line[n:]) + return int(line[n:m]) + except: + return None + + def getFloat(self, line, code): + n = line.find(code) + 1 + if n < 1: + return None + m = line.find(' ', n) + m2 = line.find(';', n) + if m < 0: + m = m2 + try: + if m < 0: + return float(line[n:]) + return float(line[n:m]) + except: + return None + def read(self, file_name): scene_node = None @@ -43,48 +73,90 @@ class GCODEReader(MeshReader): # # scene_node.setMeshData(mesh_builder.build()) - def getBoundingBox(): - return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) - - scene_node.getBoundingBox = getBoundingBox + # scene_node.getBoundingBox = getBoundingBox scene_node.gcode = True backend = Application.getInstance().getBackend() backend._pauseSlicing = True backend.backendStateChange.emit(0) - mesh_builder = MeshBuilder() - mesh_builder.setFileName(file_name) - - mesh_builder.addCube(10,10,10) - - scene_node.setMeshData(mesh_builder.build()) + file = open(file_name, "r") layer_data = LayerDataBuilder.LayerDataBuilder() - layer_count = 1 - for id in range(layer_count): - layer_data.addLayer(id) - this_layer = layer_data.getLayer(id) - layer_data.setLayerHeight(id, 1) - layer_data.setLayerThickness(id, 1) - extruder = 1 - line_types = numpy.empty((1, 1), numpy.int32) - line_types[0, 0] = 6 - line_widths = numpy.empty((1, 1), numpy.int32) - line_widths[0, 0] = 1 - points = numpy.empty((2, 3), numpy.float32) - points[0, 0] = 0 - points[0, 1] = 0 - points[0, 2] = 0 - points[1, 0] = 10 - points[1, 1] = 10 - points[1, 2] = 10 + layer_id = 0 - this_poly = LayerPolygon.LayerPolygon(layer_data, extruder, line_types, points, line_widths) + layer_data.addLayer(layer_id) + this_layer = layer_data.getLayer(layer_id) + layer_data.setLayerHeight(layer_id, 0) + layer_data.setLayerThickness(layer_id, 0.1) + + current_extruder = 1 + current_path = [] + current_x = 0 + current_y = 0 + current_z = 0 + + def CreatePolygon(): + count = len(current_path) + line_types = numpy.empty((count-1, 1), numpy.int32) + line_types[:, 0] = 1 + line_widths = numpy.empty((count-1, 1), numpy.int32) + line_widths[:, 0] = 1 + points = numpy.empty((count, 3), numpy.float32) + i = 0 + for point in current_path: + points[i, 0] = point[0] + points[i, 1] = point[1] + points[i, 2] = point[2] + i += 1 + + this_poly = LayerPolygon.LayerPolygon(layer_data, current_extruder, line_types, points, line_widths) this_poly.buildCache() this_layer.polygons.append(this_poly) + current_path.clear() + + # current_path.append([0, 0, 0]) + # current_path.append([10, 10, 10]) + # while file.readable(): + for line in file: + if len(line) == 0: + continue + if line[0] == ";": + continue + G = self.getInt(line, "G") + if G: + if G == 0 or G == 1: + x = self.getFloat(line, "X") + y = self.getFloat(line, "Y") + z = self.getFloat(line, "Z") + e = self.getFloat(line, "E") + if x: + current_x = x + if y: + current_y = y + if z: + current_z = z + if e and e > 0: + current_path.append([current_x, current_z, -current_y]) + else: + if len(current_path) > 1: + CreatePolygon() + elif G == 92: + x = self.getFloat(line, "X") + y = self.getFloat(line, "Y") + z = self.getFloat(line, "Z") + if x: + current_x += x + if y: + current_y += y + if z: + current_z += z + + if len(current_path) > 1: + CreatePolygon() + layer_mesh = layer_data.build() decorator = LayerDataDecorator.LayerDataDecorator() decorator.setLayerData(layer_mesh) @@ -93,6 +165,14 @@ class GCODEReader(MeshReader): scene_node_parent = Application.getInstance().getBuildVolume() scene_node.setParent(scene_node_parent) + mesh_builder = MeshBuilder() + mesh_builder.setFileName(file_name) + + mesh_builder.addCube(10, 10, 10, Vector(0, -5, 0)) + + scene_node.setMeshData(mesh_builder.build()) + scene_node.setPosition(Vector(0,0,0)) + view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() diff --git a/plugins/LayerView/LayerView.py b/plugins/LayerView/LayerView.py index 0736fe6dac..50c13194f7 100644 --- a/plugins/LayerView/LayerView.py +++ b/plugins/LayerView/LayerView.py @@ -118,14 +118,8 @@ class LayerView(View): if type(node) is ConvexHullNode and not Selection.isSelected(node.getWatchedNode()): continue - flag = False - try: - flag = node.gcode - except AttributeError: - pass - if not node.render(renderer): - if node.getMeshData() and node.isVisible() and not flag: + if node.getMeshData() and node.isVisible(): renderer.queueNode(node, transparent = True, shader = self._ghost_shader) def setLayer(self, value): From eb649511a75e7d24ca450a39889c987c9f05e731 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 12 Oct 2016 15:12:17 +0600 Subject: [PATCH 05/68] T466: Improved parsing --- plugins/GCODEReader/GCODEReader.py | 48 ++++++++++++++++++++---------- 1 file changed, 33 insertions(+), 15 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index fc5c0c45ac..0254eb5a98 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -29,9 +29,9 @@ class GCODEReader(MeshReader): if n < 1: return None m = line.find(' ', n) - m2 = line.find(';', n) - if m < 0: - m = m2 + # m2 = line.find(';', n) + # if m < 0: + # m = m2 try: if m < 0: return int(line[n:]) @@ -44,9 +44,9 @@ class GCODEReader(MeshReader): if n < 1: return None m = line.find(' ', n) - m2 = line.find(';', n) - if m < 0: - m = m2 + # m2 = line.find(';', n) + # if m < 0: + # m = m2 try: if m < 0: return float(line[n:]) @@ -95,6 +95,7 @@ class GCODEReader(MeshReader): current_x = 0 current_y = 0 current_z = 0 + current_e = 0 def CreatePolygon(): count = len(current_path) @@ -126,32 +127,49 @@ class GCODEReader(MeshReader): if line[0] == ";": continue G = self.getInt(line, "G") - if G: + if G is not None: if G == 0 or G == 1: x = self.getFloat(line, "X") y = self.getFloat(line, "Y") z = self.getFloat(line, "Z") e = self.getFloat(line, "E") - if x: + if x is not None: current_x = x - if y: + if y is not None: current_y = y - if z: + if z is not None: current_z = z - if e and e > 0: - current_path.append([current_x, current_z, -current_y]) + if e is not None: + if e >= current_e: + current_path.append([current_x, current_z, -current_y]) + else: + if len(current_path) > 1: + CreatePolygon() + else: + current_path.clear() + current_e = e else: if len(current_path) > 1: CreatePolygon() + else: + current_path.clear() + elif G == 28: + x = self.getFloat(line, "X") + y = self.getFloat(line, "Y") + if x is not None: + current_x += x + if y is not None: + current_y += y + current_z = 0 elif G == 92: x = self.getFloat(line, "X") y = self.getFloat(line, "Y") z = self.getFloat(line, "Z") - if x: + if x is not None: current_x += x - if y: + if y is not None: current_y += y - if z: + if z is not None: current_z += z if len(current_path) > 1: From 0a75c3d19b582b391b059936215d2fbb7d757038 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 12 Oct 2016 16:17:14 +0600 Subject: [PATCH 06/68] T466: Fixed infill parsing bug and moved model to center --- plugins/GCODEReader/GCODEReader.py | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 0254eb5a98..b63268ce7f 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -140,7 +140,7 @@ class GCODEReader(MeshReader): if z is not None: current_z = z if e is not None: - if e >= current_e: + if e > current_e: current_path.append([current_x, current_z, -current_y]) else: if len(current_path) > 1: @@ -151,15 +151,15 @@ class GCODEReader(MeshReader): else: if len(current_path) > 1: CreatePolygon() - else: + elif G == 1: current_path.clear() elif G == 28: x = self.getFloat(line, "X") y = self.getFloat(line, "Y") if x is not None: - current_x += x + current_x = x if y is not None: - current_y += y + current_y = y current_z = 0 elif G == 92: x = self.getFloat(line, "X") @@ -189,13 +189,18 @@ class GCODEReader(MeshReader): mesh_builder.addCube(10, 10, 10, Vector(0, -5, 0)) scene_node.setMeshData(mesh_builder.build()) - scene_node.setPosition(Vector(0,0,0)) + + settings = Application.getInstance().getGlobalContainerStack() + machine_width = settings.getProperty("machine_width", "value") + machine_depth = settings.getProperty("machine_depth", "value") + + scene_node.setPosition(Vector(-machine_width/2, 0, machine_depth/2)) view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() - #scene_node.setEnabled(False) + scene_node.setEnabled(False) #scene_node.setSelectable(False) return scene_node From 333e5012685f82372580e7bd65e0cda2d3e2c92b Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 13 Oct 2016 16:55:24 +0600 Subject: [PATCH 07/68] T466: Removed cube, Changed label, Added clearing of scene --- cura/CuraApplication.py | 4 +- .../ProcessSlicedLayersJob.py | 2 +- plugins/GCODEReader/GCODEReader.py | 38 ++++++++++++++----- plugins/LayerView/LayerPass.py | 2 +- plugins/LayerView/LayerView.py | 2 +- 5 files changed, 34 insertions(+), 14 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 2ab7837352..ee5fdfea2a 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -581,7 +581,7 @@ class CuraApplication(QtApplication): count = 0 scene_bounding_box = None for node in DepthFirstIterator(self.getController().getScene().getRoot()): - if type(node) is not SceneNode or not node.getMeshData(): + if type(node) is not SceneNode or (not node.getMeshData() and not hasattr(node, "gcode")): continue count += 1 @@ -712,7 +712,7 @@ class CuraApplication(QtApplication): for node in DepthFirstIterator(self.getController().getScene().getRoot()): if type(node) is not SceneNode: continue - if not node.getMeshData() and not node.callDecoration("isGroup"): + if (not node.getMeshData() and not hasattr(node, "gcode")) and not node.callDecoration("isGroup"): continue # Node that doesnt have a mesh and is not a group. if node.getParent() and node.getParent().callDecoration("isGroup"): continue # Grouped nodes don't need resetting as their parent (the group) is resetted) diff --git a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py index c4e9554b2c..206a3e83e8 100644 --- a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py +++ b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py @@ -60,7 +60,7 @@ class ProcessSlicedLayersJob(Job): for node in DepthFirstIterator(self._scene.getRoot()): if node.callDecoration("getLayerData"): node.getParent().removeChild(node) - break + # break if self._abort_requested: if self._progress: self._progress.hide() diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index b63268ce7f..abaefdadbd 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -4,11 +4,15 @@ from UM.Mesh.MeshReader import MeshReader from UM.Mesh.MeshBuilder import MeshBuilder +from UM.Mesh.MeshData import MeshData import os from UM.Scene.SceneNode import SceneNode +from UM.Scene.Iterator.DepthFirstIterator import DepthFirstIterator from UM.Math.Vector import Vector +from UM.Math.Color import Color from UM.Math.AxisAlignedBox import AxisAlignedBox from UM.Application import Application +from UM.Preferences import Preferences from cura import LayerDataBuilder from cura import LayerDataDecorator @@ -59,6 +63,14 @@ class GCODEReader(MeshReader): extension = os.path.splitext(file_name)[1] if extension.lower() in self._supported_extensions: + scene = Application.getInstance().getController().getScene() + if getattr(scene, "gcode_list"): + setattr(scene, "gcode_list", None) + for node in DepthFirstIterator(scene.getRoot()): + if node.callDecoration("getLayerData"): + node.getParent().removeChild(node) + Application.getInstance().deleteAll() + scene_node = SceneNode() # mesh_builder = MeshBuilder() @@ -73,11 +85,14 @@ class GCODEReader(MeshReader): # # scene_node.setMeshData(mesh_builder.build()) - # scene_node.getBoundingBox = getBoundingBox + def getBoundingBox(): + return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) + + scene_node.getBoundingBox = getBoundingBox scene_node.gcode = True - backend = Application.getInstance().getBackend() - backend._pauseSlicing = True - backend.backendStateChange.emit(0) + # backend = Application.getInstance().getBackend() + # backend._pauseSlicing = True + # backend.backendStateChange.emit(0) file = open(file_name, "r") @@ -183,12 +198,17 @@ class GCODEReader(MeshReader): scene_node_parent = Application.getInstance().getBuildVolume() scene_node.setParent(scene_node_parent) - mesh_builder = MeshBuilder() - mesh_builder.setFileName(file_name) + # mesh_builder = MeshBuilder() + # mesh_builder.setFileName(file_name) + # + # mesh_builder.addCube(10, 10, 10, Vector(0, -5, 0)) - mesh_builder.addCube(10, 10, 10, Vector(0, -5, 0)) + # scene_node.setMeshData(mesh_builder.build()) + # scene_node.setMeshData(MeshData(file_name=file_name)) - scene_node.setMeshData(mesh_builder.build()) + # Application.getInstance().getPrintInformation().JobName(file_name) + + Preferences.getInstance().setValue("cura/jobname_prefix", False) settings = Application.getInstance().getGlobalContainerStack() machine_width = settings.getProperty("machine_width", "value") @@ -200,7 +220,7 @@ class GCODEReader(MeshReader): if view.getPluginId() == "LayerView": view.resetLayerData() - scene_node.setEnabled(False) + # scene_node.setEnabled(False) #scene_node.setSelectable(False) return scene_node diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index 287f3c3539..9e610b68d2 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -49,7 +49,7 @@ class LayerPass(RenderPass): if isinstance(node, ToolHandle): tool_handle_batch.addItem(node.getWorldTransformation(), mesh = node.getSolidMesh()) - elif isinstance(node, SceneNode) and (node.getMeshData()) and node.isVisible(): + elif isinstance(node, SceneNode) and (node.getMeshData() or hasattr(node, "gcode")) and node.isVisible(): layer_data = node.callDecoration("getLayerData") if not layer_data: continue diff --git a/plugins/LayerView/LayerView.py b/plugins/LayerView/LayerView.py index 50c13194f7..0bae9c891c 100644 --- a/plugins/LayerView/LayerView.py +++ b/plugins/LayerView/LayerView.py @@ -119,7 +119,7 @@ class LayerView(View): continue if not node.render(renderer): - if node.getMeshData() and node.isVisible(): + if (node.getMeshData()) and node.isVisible(): renderer.queueNode(node, transparent = True, shader = self._ghost_shader) def setLayer(self, value): From 41a698959bd1c6a9e0a2d9bd6889e2f4b3744f40 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 13 Oct 2016 17:11:32 +0600 Subject: [PATCH 08/68] T466: Hiding backend label --- plugins/GCODEReader/GCODEReader.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index abaefdadbd..cbf630f8d5 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -90,9 +90,10 @@ class GCODEReader(MeshReader): scene_node.getBoundingBox = getBoundingBox scene_node.gcode = True - # backend = Application.getInstance().getBackend() + backend = Application.getInstance().getBackend() # backend._pauseSlicing = True - # backend.backendStateChange.emit(0) + # backend.close() + backend.backendStateChange.emit(0) file = open(file_name, "r") From 2b3f46f49eeadd41b07b2b1a82754ac41098c022 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 13 Oct 2016 17:30:20 +0600 Subject: [PATCH 09/68] T466: Added correct models switching --- plugins/GCODEReader/GCODEReader.py | 43 +++++++++++++++++++++--------- 1 file changed, 30 insertions(+), 13 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index cbf630f8d5..ca4a9c475c 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -58,17 +58,34 @@ class GCODEReader(MeshReader): except: return None + def onSceneChanged(self, obj): + scene = Application.getInstance().getController().getScene() + + def findAny(): + for node in DepthFirstIterator(scene.getRoot()): + if hasattr(node, "gcode"): + return True + return False + + if not findAny(): + # Preferences.getInstance().setValue("cura/jobname_prefix", True) + backend = Application.getInstance().getBackend() + backend._pauseSlicing = False + else: + backend = Application.getInstance().getBackend() + backend._pauseSlicing = True + backend.backendStateChange.emit(1) + def read(self, file_name): scene_node = None extension = os.path.splitext(file_name)[1] if extension.lower() in self._supported_extensions: scene = Application.getInstance().getController().getScene() - if getattr(scene, "gcode_list"): - setattr(scene, "gcode_list", None) - for node in DepthFirstIterator(scene.getRoot()): - if node.callDecoration("getLayerData"): - node.getParent().removeChild(node) + scene.sceneChanged.connect(self.onSceneChanged) + # for node in DepthFirstIterator(scene.getRoot()): + # if node.callDecoration("getLayerData"): + # node.getParent().removeChild(node) Application.getInstance().deleteAll() scene_node = SceneNode() @@ -91,9 +108,9 @@ class GCODEReader(MeshReader): scene_node.getBoundingBox = getBoundingBox scene_node.gcode = True backend = Application.getInstance().getBackend() - # backend._pauseSlicing = True + backend._pauseSlicing = True # backend.close() - backend.backendStateChange.emit(0) + backend.backendStateChange.emit(1) file = open(file_name, "r") @@ -199,6 +216,12 @@ class GCODEReader(MeshReader): scene_node_parent = Application.getInstance().getBuildVolume() scene_node.setParent(scene_node_parent) + settings = Application.getInstance().getGlobalContainerStack() + machine_width = settings.getProperty("machine_width", "value") + machine_depth = settings.getProperty("machine_depth", "value") + + scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) + # mesh_builder = MeshBuilder() # mesh_builder.setFileName(file_name) # @@ -211,12 +234,6 @@ class GCODEReader(MeshReader): Preferences.getInstance().setValue("cura/jobname_prefix", False) - settings = Application.getInstance().getGlobalContainerStack() - machine_width = settings.getProperty("machine_width", "value") - machine_depth = settings.getProperty("machine_depth", "value") - - scene_node.setPosition(Vector(-machine_width/2, 0, machine_depth/2)) - view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() From 3ee83f26c32b859a8e429f5bd80062b1061287b0 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 13 Oct 2016 17:32:43 +0600 Subject: [PATCH 10/68] T466: Added correct models switching --- plugins/GCODEReader/GCODEReader.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index ca4a9c475c..8bbe7ad89e 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -109,7 +109,7 @@ class GCODEReader(MeshReader): scene_node.gcode = True backend = Application.getInstance().getBackend() backend._pauseSlicing = True - # backend.close() + backend.close() backend.backendStateChange.emit(1) file = open(file_name, "r") From d7b4296cfc9deb40a7a3a3d18a367928d4402fbd Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 14 Oct 2016 16:17:46 +0600 Subject: [PATCH 11/68] T466: Added correct prefix --- plugins/GCODEReader/GCODEReader.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 8bbe7ad89e..5769959983 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -230,9 +230,9 @@ class GCODEReader(MeshReader): # scene_node.setMeshData(mesh_builder.build()) # scene_node.setMeshData(MeshData(file_name=file_name)) - # Application.getInstance().getPrintInformation().JobName(file_name) + Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" - Preferences.getInstance().setValue("cura/jobname_prefix", False) + Preferences.getInstance().setValue("cura/jobname_prefix", True) view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": From 2ee5e2cb0b306a912f78d8037a48c5392d1d9f5f Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 14 Oct 2016 17:06:53 +0600 Subject: [PATCH 12/68] T466: Added hiding of properties menu --- cura/CuraApplication.py | 15 +++++++++++++++ plugins/GCODEReader/GCODEReader.py | 9 ++++++++- resources/qml/Sidebar.qml | 7 ++++--- 3 files changed, 27 insertions(+), 4 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index ee5fdfea2a..c5db2b01e7 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -1007,3 +1007,18 @@ class CuraApplication(QtApplication): @pyqtSlot(str) def log(self, msg): Logger.log("d", msg) + + _hide_settings = False + + HideSettingsChanged = pyqtSignal(bool) + + @pyqtSlot(bool) + def setHideSettings(self, hide): + self._hide_settings = hide + self.HideSettingsChanged.emit(hide) + + @pyqtProperty(bool, notify=HideSettingsChanged) + def hideSettings(self): + return self._hide_settings + + diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 5769959983..8305061a59 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -71,10 +71,14 @@ class GCODEReader(MeshReader): # Preferences.getInstance().setValue("cura/jobname_prefix", True) backend = Application.getInstance().getBackend() backend._pauseSlicing = False + Application.getInstance().setHideSettings(False) + #Application.getInstance().getPrintInformation()._setAbbreviatedMachineName() else: backend = Application.getInstance().getBackend() backend._pauseSlicing = True backend.backendStateChange.emit(1) + Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" + Application.getInstance().setHideSettings(True) def read(self, file_name): scene_node = None @@ -213,6 +217,8 @@ class GCODEReader(MeshReader): decorator.setLayerData(layer_mesh) scene_node.addDecorator(decorator) + Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" + scene_node_parent = Application.getInstance().getBuildVolume() scene_node.setParent(scene_node_parent) @@ -230,10 +236,11 @@ class GCODEReader(MeshReader): # scene_node.setMeshData(mesh_builder.build()) # scene_node.setMeshData(MeshData(file_name=file_name)) - Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" + Preferences.getInstance().setValue("cura/jobname_prefix", True) + view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml index d97b69e801..234e139791 100644 --- a/resources/qml/Sidebar.qml +++ b/resources/qml/Sidebar.qml @@ -16,6 +16,7 @@ Rectangle property int currentModeIndex; property bool monitoringPrint: false + property bool hideSettings: Printer.hideSettings Connections { target: Printer @@ -296,7 +297,7 @@ Rectangle width: parent.width * 0.45 - 2 * UM.Theme.getSize("default_margin").width font: UM.Theme.getFont("large") color: UM.Theme.getColor("text") - visible: !monitoringPrint + visible: !monitoringPrint && !hideSettings elide: Text.ElideRight } @@ -308,7 +309,7 @@ Rectangle anchors.rightMargin: UM.Theme.getSize("default_margin").width anchors.top: headerSeparator.bottom anchors.topMargin: UM.Theme.getSize("default_margin").height - visible: !monitoringPrint + visible: !monitoringPrint && !hideSettings Component{ id: wizardDelegate Button { @@ -432,7 +433,7 @@ Rectangle anchors.topMargin: UM.Theme.getSize("default_margin").height anchors.left: base.left anchors.right: base.right - visible: !monitoringPrint + visible: !monitoringPrint && !hideSettings delegate: StackViewDelegate { From 64d7bb0c2a6250633212040720ba6cf00d5170a7 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 14 Oct 2016 18:08:33 +0600 Subject: [PATCH 13/68] T466: Added ability to print loaded gcode --- .gitignore | 0 CHANGES | 0 CMakeLists.txt | 0 CPackConfig.cmake | 0 LICENSE | 0 README.md | 0 build.sh | 0 cura.desktop.in | 0 cura.sharedmimeinfo | 0 cura/BuildVolume.py | 0 cura/CameraAnimation.py | 0 cura/CameraImageProvider.py | 0 cura/ConvexHullDecorator.py | 0 cura/ConvexHullNode.py | 0 cura/CrashHandler.py | 0 cura/CuraActions.py | 0 cura/CuraApplication.py | 0 cura/CuraSplashScreen.py | 0 cura/CuraVersion.py.in | 0 cura/Layer.py | 0 cura/LayerData.py | 0 cura/LayerDataBuilder.py | 0 cura/LayerDataDecorator.py | 0 cura/LayerPolygon.py | 0 cura/MachineAction.py | 0 cura/MachineActionManager.py | 0 cura/OneAtATimeIterator.py | 0 cura/PlatformPhysics.py | 0 cura/PlatformPhysicsOperation.py | 0 cura/PrintInformation.py | 0 cura/PrinterOutputDevice.py | 0 cura/ProfileReader.py | 0 cura/ProfileWriter.py | 0 cura/SetParentOperation.py | 0 cura/Settings/ContainerManager.py | 0 cura/Settings/ContainerSettingsModel.py | 0 cura/Settings/CuraContainerRegistry.py | 0 cura/Settings/ExtruderManager.py | 0 cura/Settings/ExtrudersModel.py | 0 cura/Settings/MachineManager.py | 0 cura/Settings/MaterialSettingsVisibilityHandler.py | 0 cura/Settings/QualitySettingsModel.py | 0 cura/Settings/SettingInheritanceManager.py | 0 cura/Settings/SettingOverrideDecorator.py | 0 cura/Settings/__init__.py | 0 cura/ZOffsetDecorator.py | 0 cura/__init__.py | 0 icons/cura-128.png | Bin icons/cura-32.png | Bin icons/cura-48.png | Bin icons/cura-64.png | Bin icons/cura.icns | Bin icons/cura.ico | Bin installer.nsi | 0 plugins/3MFReader/ThreeMFReader.py | 0 plugins/3MFReader/__init__.py | 0 plugins/AutoSave/AutoSave.py | 0 plugins/AutoSave/__init__.py | 0 plugins/ChangeLogPlugin/ChangeLog.py | 0 plugins/ChangeLogPlugin/ChangeLog.qml | 0 plugins/ChangeLogPlugin/ChangeLog.txt | 0 plugins/ChangeLogPlugin/__init__.py | 0 plugins/CuraEngineBackend/Cura.proto | 0 plugins/CuraEngineBackend/CuraEngineBackend.py | 0 plugins/CuraEngineBackend/ProcessGCodeJob.py | 0 plugins/CuraEngineBackend/ProcessSlicedLayersJob.py | 0 plugins/CuraEngineBackend/StartSliceJob.py | 0 plugins/CuraEngineBackend/__init__.py | 0 plugins/CuraProfileReader/CuraProfileReader.py | 0 plugins/CuraProfileReader/__init__.py | 0 plugins/CuraProfileWriter/CuraProfileWriter.py | 0 plugins/CuraProfileWriter/__init__.py | 0 plugins/GCODEReader/GCODEReader.py | 8 +++++++- plugins/GCODEReader/__init__.py | 0 plugins/GCodeProfileReader/GCodeProfileReader.py | 0 plugins/GCodeProfileReader/__init__.py | 0 plugins/GCodeWriter/GCodeWriter.py | 0 plugins/GCodeWriter/__init__.py | 0 plugins/ImageReader/ConfigUI.qml | 0 plugins/ImageReader/ImageReader.py | 0 plugins/ImageReader/ImageReaderUI.py | 0 plugins/ImageReader/__init__.py | 0 plugins/LayerView/LayerPass.py | 0 plugins/LayerView/LayerView.py | 0 plugins/LayerView/LayerView.qml | 0 plugins/LayerView/LayerViewProxy.py | 0 plugins/LayerView/__init__.py | 0 plugins/LayerView/layerview_composite.shader | 0 plugins/LegacyProfileReader/DictionaryOfDoom.json | 0 plugins/LegacyProfileReader/LegacyProfileReader.py | 0 plugins/LegacyProfileReader/__init__.py | 0 .../MachineSettingsAction/MachineSettingsAction.py | 0 .../MachineSettingsAction/MachineSettingsAction.qml | 0 plugins/MachineSettingsAction/__init__.py | 0 plugins/PerObjectSettingsTool/PerObjectCategory.qml | 0 plugins/PerObjectSettingsTool/PerObjectItem.qml | 0 .../PerObjectSettingVisibilityHandler.py | 0 .../PerObjectSettingsPanel.qml | 0 .../PerObjectSettingsTool/PerObjectSettingsTool.py | 0 plugins/PerObjectSettingsTool/__init__.py | 0 .../LinuxRemovableDrivePlugin.py | 0 .../OSXRemovableDrivePlugin.py | 0 .../RemovableDriveOutputDevice.py | 0 .../RemovableDrivePlugin.py | 0 .../WindowsRemovableDrivePlugin.py | 0 plugins/RemovableDriveOutputDevice/__init__.py | 0 plugins/SolidView/SolidView.py | 0 plugins/SolidView/__init__.py | 0 plugins/USBPrinting/FirmwareUpdateWindow.qml | 0 plugins/USBPrinting/USBPrinterOutputDevice.py | 0 .../USBPrinting/USBPrinterOutputDeviceManager.py | 0 plugins/USBPrinting/__init__.py | 0 plugins/USBPrinting/avr_isp/__init__.py | 0 plugins/USBPrinting/avr_isp/chipDB.py | 0 plugins/USBPrinting/avr_isp/intelHex.py | 0 plugins/USBPrinting/avr_isp/ispBase.py | 0 plugins/USBPrinting/avr_isp/stk500v2.py | 0 .../BedLevelMachineAction.py | 0 .../BedLevelMachineAction.qml | 0 .../UMOCheckupMachineAction.py | 0 .../UMOCheckupMachineAction.qml | 0 .../UltimakerMachineActions/UMOUpgradeSelection.py | 0 .../UMOUpgradeSelectionMachineAction.qml | 0 .../UpgradeFirmwareMachineAction.py | 0 .../UpgradeFirmwareMachineAction.qml | 0 plugins/UltimakerMachineActions/__init__.py | 0 .../VersionUpgrade21to22/MachineInstance.py | 0 .../VersionUpgrade21to22/Preferences.py | 0 .../VersionUpgrade/VersionUpgrade21to22/Profile.py | 0 .../VersionUpgrade21to22/VersionUpgrade21to22.py | 0 .../VersionUpgrade/VersionUpgrade21to22/__init__.py | 0 plugins/X3DReader/X3DReader.py | 0 plugins/X3DReader/__init__.py | 0 plugins/XRayView/XRayPass.py | 0 plugins/XRayView/XRayView.py | 0 plugins/XRayView/__init__.py | 0 plugins/XRayView/xray.shader | 0 plugins/XRayView/xray_composite.shader | 0 plugins/XmlMaterialProfile/XmlMaterialProfile.py | 0 plugins/XmlMaterialProfile/__init__.py | 0 pytest.ini | 0 resources/definitions/bq_hephestos.def.json | 0 resources/definitions/bq_hephestos_2.def.json | 0 resources/definitions/bq_hephestos_xl.def.json | 0 resources/definitions/bq_witbox.def.json | 0 resources/definitions/bq_witbox_2.def.json | 0 resources/definitions/custom.def.json | 0 resources/definitions/fdmextruder.def.json | 0 resources/definitions/fdmprinter.def.json | 0 resources/definitions/grr_neo.def.json | 0 resources/definitions/innovo_inventor.def.json | 0 resources/definitions/kossel_mini.def.json | 0 resources/definitions/m180.def.json | 0 resources/definitions/maker_starter.def.json | 0 .../definitions/mankati_fullscale_xt_plus.def.json | 0 resources/definitions/mendel90.def.json | 0 resources/definitions/printrbot_simple.def.json | 0 resources/definitions/prusa_i3.def.json | 0 resources/definitions/prusa_i3_mk2.def.json | 0 resources/definitions/prusa_i3_xl.def.json | 0 resources/definitions/rigidbot.def.json | 0 resources/definitions/rigidbot_big.def.json | 0 resources/definitions/ultimaker.def.json | 0 resources/definitions/ultimaker2.def.json | 0 resources/definitions/ultimaker2_extended.def.json | 0 .../definitions/ultimaker2_extended_plus.def.json | 0 resources/definitions/ultimaker2_go.def.json | 0 resources/definitions/ultimaker2_plus.def.json | 0 resources/definitions/ultimaker_original.def.json | 0 .../definitions/ultimaker_original_dual.def.json | 0 .../definitions/ultimaker_original_plus.def.json | 0 resources/definitions/uniqbot_one.def.json | 0 .../extruders/ultimaker_original_dual_1st.def.json | 0 .../extruders/ultimaker_original_dual_2nd.def.json | 0 resources/i18n/cura.pot | 0 resources/i18n/de/cura.po | 0 resources/i18n/en/cura.po | 0 resources/i18n/es/cura.po | 0 resources/i18n/fdmextruder.def.json.pot | 0 resources/i18n/fdmprinter.def.json.pot | 0 resources/i18n/fi/cura.po | 0 resources/i18n/fr/cura.po | 0 resources/i18n/it/cura.po | 0 resources/i18n/nl/cura.po | 0 resources/images/MakerStarterbackplate.png | Bin .../images/Ultimaker2ExtendedPlusbackplate.png | Bin resources/images/Ultimaker2Extendedbackplate.png | Bin resources/images/Ultimaker2Gobackplate.png | Bin resources/images/Ultimaker2Plusbackplate.png | Bin resources/images/Ultimaker2backplate.png | Bin resources/images/UltimakerPlusbackplate.png | Bin resources/images/cura-icon.png | Bin resources/images/cura.png | Bin resources/meshes/UltimakerRobot_support.stl | Bin resources/meshes/bq_hephestos_2_platform.stl | Bin resources/meshes/bq_hephestos_platform.stl | Bin resources/meshes/bq_witbox_platform.stl | Bin resources/meshes/grr_neo_platform.stl | Bin resources/meshes/inventor_platform.stl | Bin resources/meshes/kossel_platform.stl | 0 resources/meshes/makerstarter_platform.stl | Bin .../meshes/mankati_fullscale_xt_plus_platform.stl | Bin resources/meshes/mendel90_platform.stl | 0 .../meshes/printrbot_simple_metal_platform.stl | Bin resources/meshes/prusai3_platform.stl | 0 resources/meshes/prusai3_xl_platform.stl | 0 resources/meshes/rigidbot_platform.stl | Bin resources/meshes/rigidbotbig_platform.stl | Bin resources/meshes/ultimaker2_platform.obj | 0 resources/meshes/ultimaker2go_platform.obj | 0 resources/meshes/ultimaker_platform.stl | Bin resources/qml/AboutDialog.qml | 0 resources/qml/Actions.qml | 0 resources/qml/AddMachineDialog.qml | 0 resources/qml/Cura.qml | 0 resources/qml/EngineLog.qml | 0 resources/qml/JobSpecs.qml | 0 resources/qml/MachineAction.qml | 0 resources/qml/Menus/MaterialMenu.qml | 0 resources/qml/Menus/NozzleMenu.qml | 0 resources/qml/Menus/PrinterMenu.qml | 0 resources/qml/Menus/ProfileMenu.qml | 0 resources/qml/Menus/RecentFilesMenu.qml | 0 resources/qml/Menus/ViewMenu.qml | 0 resources/qml/MonitorButton.qml | 0 resources/qml/Preferences/GeneralPage.qml | 0 resources/qml/Preferences/MachinesPage.qml | 0 resources/qml/Preferences/MaterialView.qml | 0 resources/qml/Preferences/MaterialsPage.qml | 0 resources/qml/Preferences/ProfileTab.qml | 0 resources/qml/Preferences/ProfilesPage.qml | 0 resources/qml/Preferences/ReadOnlySpinBox.qml | 0 resources/qml/Preferences/ReadOnlyTextArea.qml | 0 resources/qml/Preferences/ReadOnlyTextField.qml | 0 resources/qml/Preferences/SettingVisibilityPage.qml | 0 resources/qml/PrintMonitor.qml | 0 resources/qml/SaveButton.qml | 0 resources/qml/Settings/SettingCategory.qml | 0 resources/qml/Settings/SettingCheckBox.qml | 0 resources/qml/Settings/SettingComboBox.qml | 0 resources/qml/Settings/SettingExtruder.qml | 0 resources/qml/Settings/SettingItem.qml | 0 resources/qml/Settings/SettingTextField.qml | 0 resources/qml/Settings/SettingUnknown.qml | 0 resources/qml/Settings/SettingView.qml | 0 resources/qml/Sidebar.qml | 0 resources/qml/SidebarAdvanced.qml | 0 resources/qml/SidebarContents.qml | 0 resources/qml/SidebarHeader.qml | 0 resources/qml/SidebarSimple.qml | 0 resources/qml/SidebarTooltip.qml | 0 resources/qml/Toolbar.qml | 0 resources/quality/high.inst.cfg | 0 resources/quality/low.inst.cfg | 0 resources/quality/normal.inst.cfg | 0 .../ultimaker2_plus/pla_0.25_normal.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.4_fast.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.4_high.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.4_normal.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.6_normal.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.4_high.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.25_high.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg | 0 .../ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg | 0 resources/shaders/grid.shader | 0 resources/shaders/overhang.shader | 0 resources/shaders/striped.shader | 0 resources/shaders/transparent_object.shader | 0 resources/themes/cura/fonts/LICENSE.txt | 0 resources/themes/cura/fonts/OpenSans-Bold.ttf | Bin resources/themes/cura/fonts/OpenSans-BoldItalic.ttf | Bin resources/themes/cura/fonts/OpenSans-Italic.ttf | Bin resources/themes/cura/fonts/OpenSans-Light.ttf | Bin .../themes/cura/fonts/OpenSans-LightItalic.ttf | Bin resources/themes/cura/fonts/OpenSans-Regular.ttf | Bin resources/themes/cura/fonts/OpenSans-Semibold.ttf | Bin .../themes/cura/fonts/OpenSans-SemiboldItalic.ttf | Bin resources/themes/cura/icons/application.svg | 0 resources/themes/cura/icons/arrow_bottom.svg | 0 resources/themes/cura/icons/arrow_left.svg | 0 resources/themes/cura/icons/arrow_right.svg | 0 resources/themes/cura/icons/arrow_top.svg | 0 resources/themes/cura/icons/basic.svg | 0 resources/themes/cura/icons/category_adhesion.svg | 0 resources/themes/cura/icons/category_blackmagic.svg | 0 resources/themes/cura/icons/category_cool.svg | 0 resources/themes/cura/icons/category_dual.svg | 0 .../themes/cura/icons/category_experimental.svg | 0 resources/themes/cura/icons/category_fixes.svg | 0 resources/themes/cura/icons/category_infill.svg | 0 .../themes/cura/icons/category_layer_height.svg | 0 resources/themes/cura/icons/category_machine.svg | 0 resources/themes/cura/icons/category_material.svg | 0 resources/themes/cura/icons/category_shell.svg | 0 resources/themes/cura/icons/category_shield.svg | 0 resources/themes/cura/icons/category_speed.svg | 0 resources/themes/cura/icons/category_support.svg | 0 resources/themes/cura/icons/category_travel.svg | 0 resources/themes/cura/icons/category_unknown.svg | 0 resources/themes/cura/icons/check.svg | 0 resources/themes/cura/icons/cross1.svg | 0 resources/themes/cura/icons/cross2.svg | 0 resources/themes/cura/icons/dense.svg | 0 resources/themes/cura/icons/dot.svg | 0 resources/themes/cura/icons/hollow.svg | 0 resources/themes/cura/icons/link.svg | 0 resources/themes/cura/icons/load.svg | 0 resources/themes/cura/icons/minus.svg | 0 resources/themes/cura/icons/mirror.svg | 0 resources/themes/cura/icons/notice.svg | 0 resources/themes/cura/icons/pencil.svg | 0 resources/themes/cura/icons/plugin.svg | 0 resources/themes/cura/icons/plus.svg | 0 resources/themes/cura/icons/print_time.svg | 0 resources/themes/cura/icons/printsetup.svg | 0 resources/themes/cura/icons/quick.svg | 0 resources/themes/cura/icons/reset.svg | 0 resources/themes/cura/icons/rotate.svg | 0 resources/themes/cura/icons/rotate_layflat.svg | 0 resources/themes/cura/icons/rotate_reset.svg | 0 resources/themes/cura/icons/scale.svg | 0 resources/themes/cura/icons/scale_max.svg | 0 resources/themes/cura/icons/scale_reset.svg | 0 resources/themes/cura/icons/setting_per_object.svg | 0 resources/themes/cura/icons/settings.svg | 0 resources/themes/cura/icons/solid.svg | 0 resources/themes/cura/icons/sparse.svg | 0 resources/themes/cura/icons/star.svg | 0 resources/themes/cura/icons/tab_monitor.svg | 0 resources/themes/cura/icons/tab_monitor_busy.svg | 0 .../themes/cura/icons/tab_monitor_connected.svg | 0 resources/themes/cura/icons/tab_monitor_offline.svg | 0 resources/themes/cura/icons/tab_monitor_paused.svg | 0 resources/themes/cura/icons/tab_monitor_stopped.svg | 0 resources/themes/cura/icons/tab_monitor_unknown.svg | 0 resources/themes/cura/icons/tab_settings.svg | 0 resources/themes/cura/icons/translate.svg | 0 resources/themes/cura/icons/ulti.svg | 0 resources/themes/cura/icons/view_layer.svg | 0 resources/themes/cura/icons/view_normal.svg | 0 resources/themes/cura/icons/view_xray.svg | 0 resources/themes/cura/icons/viewmode.svg | 0 resources/themes/cura/icons/warning.svg | 0 resources/themes/cura/images/logo.svg | 0 resources/themes/cura/styles.qml | 0 resources/themes/cura/theme.json | 0 .../variants/ultimaker2_extended_plus_0.25.inst.cfg | 0 .../variants/ultimaker2_extended_plus_0.4.inst.cfg | 0 .../variants/ultimaker2_extended_plus_0.6.inst.cfg | 0 .../variants/ultimaker2_extended_plus_0.8.inst.cfg | 0 resources/variants/ultimaker2_plus_0.25.inst.cfg | 0 resources/variants/ultimaker2_plus_0.4.inst.cfg | 0 resources/variants/ultimaker2_plus_0.6.inst.cfg | 0 resources/variants/ultimaker2_plus_0.8.inst.cfg | 0 setup.py | 0 tests/TestMachineAction.py | 0 390 files changed, 7 insertions(+), 1 deletion(-) mode change 100644 => 100755 .gitignore mode change 100644 => 100755 CHANGES mode change 100644 => 100755 CMakeLists.txt mode change 100644 => 100755 CPackConfig.cmake mode change 100644 => 100755 LICENSE mode change 100644 => 100755 README.md mode change 100644 => 100755 build.sh mode change 100644 => 100755 cura.desktop.in mode change 100644 => 100755 cura.sharedmimeinfo mode change 100644 => 100755 cura/BuildVolume.py mode change 100644 => 100755 cura/CameraAnimation.py mode change 100644 => 100755 cura/CameraImageProvider.py mode change 100644 => 100755 cura/ConvexHullDecorator.py mode change 100644 => 100755 cura/ConvexHullNode.py mode change 100644 => 100755 cura/CrashHandler.py mode change 100644 => 100755 cura/CuraActions.py mode change 100644 => 100755 cura/CuraApplication.py mode change 100644 => 100755 cura/CuraSplashScreen.py mode change 100644 => 100755 cura/CuraVersion.py.in mode change 100644 => 100755 cura/Layer.py mode change 100644 => 100755 cura/LayerData.py mode change 100644 => 100755 cura/LayerDataBuilder.py mode change 100644 => 100755 cura/LayerDataDecorator.py mode change 100644 => 100755 cura/LayerPolygon.py mode change 100644 => 100755 cura/MachineAction.py mode change 100644 => 100755 cura/MachineActionManager.py mode change 100644 => 100755 cura/OneAtATimeIterator.py mode change 100644 => 100755 cura/PlatformPhysics.py mode change 100644 => 100755 cura/PlatformPhysicsOperation.py mode change 100644 => 100755 cura/PrintInformation.py mode change 100644 => 100755 cura/PrinterOutputDevice.py mode change 100644 => 100755 cura/ProfileReader.py mode change 100644 => 100755 cura/ProfileWriter.py mode change 100644 => 100755 cura/SetParentOperation.py mode change 100644 => 100755 cura/Settings/ContainerManager.py mode change 100644 => 100755 cura/Settings/ContainerSettingsModel.py mode change 100644 => 100755 cura/Settings/CuraContainerRegistry.py mode change 100644 => 100755 cura/Settings/ExtruderManager.py mode change 100644 => 100755 cura/Settings/ExtrudersModel.py mode change 100644 => 100755 cura/Settings/MachineManager.py mode change 100644 => 100755 cura/Settings/MaterialSettingsVisibilityHandler.py mode change 100644 => 100755 cura/Settings/QualitySettingsModel.py mode change 100644 => 100755 cura/Settings/SettingInheritanceManager.py mode change 100644 => 100755 cura/Settings/SettingOverrideDecorator.py mode change 100644 => 100755 cura/Settings/__init__.py mode change 100644 => 100755 cura/ZOffsetDecorator.py mode change 100644 => 100755 cura/__init__.py mode change 100644 => 100755 icons/cura-128.png mode change 100644 => 100755 icons/cura-32.png mode change 100644 => 100755 icons/cura-48.png mode change 100644 => 100755 icons/cura-64.png mode change 100644 => 100755 icons/cura.icns mode change 100644 => 100755 icons/cura.ico mode change 100644 => 100755 installer.nsi mode change 100644 => 100755 plugins/3MFReader/ThreeMFReader.py mode change 100644 => 100755 plugins/3MFReader/__init__.py mode change 100644 => 100755 plugins/AutoSave/AutoSave.py mode change 100644 => 100755 plugins/AutoSave/__init__.py mode change 100644 => 100755 plugins/ChangeLogPlugin/ChangeLog.py mode change 100644 => 100755 plugins/ChangeLogPlugin/ChangeLog.qml mode change 100644 => 100755 plugins/ChangeLogPlugin/ChangeLog.txt mode change 100644 => 100755 plugins/ChangeLogPlugin/__init__.py mode change 100644 => 100755 plugins/CuraEngineBackend/Cura.proto mode change 100644 => 100755 plugins/CuraEngineBackend/CuraEngineBackend.py mode change 100644 => 100755 plugins/CuraEngineBackend/ProcessGCodeJob.py mode change 100644 => 100755 plugins/CuraEngineBackend/ProcessSlicedLayersJob.py mode change 100644 => 100755 plugins/CuraEngineBackend/StartSliceJob.py mode change 100644 => 100755 plugins/CuraEngineBackend/__init__.py mode change 100644 => 100755 plugins/CuraProfileReader/CuraProfileReader.py mode change 100644 => 100755 plugins/CuraProfileReader/__init__.py mode change 100644 => 100755 plugins/CuraProfileWriter/CuraProfileWriter.py mode change 100644 => 100755 plugins/CuraProfileWriter/__init__.py mode change 100644 => 100755 plugins/GCODEReader/GCODEReader.py mode change 100644 => 100755 plugins/GCODEReader/__init__.py mode change 100644 => 100755 plugins/GCodeProfileReader/GCodeProfileReader.py mode change 100644 => 100755 plugins/GCodeProfileReader/__init__.py mode change 100644 => 100755 plugins/GCodeWriter/GCodeWriter.py mode change 100644 => 100755 plugins/GCodeWriter/__init__.py mode change 100644 => 100755 plugins/ImageReader/ConfigUI.qml mode change 100644 => 100755 plugins/ImageReader/ImageReader.py mode change 100644 => 100755 plugins/ImageReader/ImageReaderUI.py mode change 100644 => 100755 plugins/ImageReader/__init__.py mode change 100644 => 100755 plugins/LayerView/LayerPass.py mode change 100644 => 100755 plugins/LayerView/LayerView.py mode change 100644 => 100755 plugins/LayerView/LayerView.qml mode change 100644 => 100755 plugins/LayerView/LayerViewProxy.py mode change 100644 => 100755 plugins/LayerView/__init__.py mode change 100644 => 100755 plugins/LayerView/layerview_composite.shader mode change 100644 => 100755 plugins/LegacyProfileReader/DictionaryOfDoom.json mode change 100644 => 100755 plugins/LegacyProfileReader/LegacyProfileReader.py mode change 100644 => 100755 plugins/LegacyProfileReader/__init__.py mode change 100644 => 100755 plugins/MachineSettingsAction/MachineSettingsAction.py mode change 100644 => 100755 plugins/MachineSettingsAction/MachineSettingsAction.qml mode change 100644 => 100755 plugins/MachineSettingsAction/__init__.py mode change 100644 => 100755 plugins/PerObjectSettingsTool/PerObjectCategory.qml mode change 100644 => 100755 plugins/PerObjectSettingsTool/PerObjectItem.qml mode change 100644 => 100755 plugins/PerObjectSettingsTool/PerObjectSettingVisibilityHandler.py mode change 100644 => 100755 plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml mode change 100644 => 100755 plugins/PerObjectSettingsTool/PerObjectSettingsTool.py mode change 100644 => 100755 plugins/PerObjectSettingsTool/__init__.py mode change 100644 => 100755 plugins/RemovableDriveOutputDevice/LinuxRemovableDrivePlugin.py mode change 100644 => 100755 plugins/RemovableDriveOutputDevice/OSXRemovableDrivePlugin.py mode change 100644 => 100755 plugins/RemovableDriveOutputDevice/RemovableDriveOutputDevice.py mode change 100644 => 100755 plugins/RemovableDriveOutputDevice/RemovableDrivePlugin.py mode change 100644 => 100755 plugins/RemovableDriveOutputDevice/WindowsRemovableDrivePlugin.py mode change 100644 => 100755 plugins/RemovableDriveOutputDevice/__init__.py mode change 100644 => 100755 plugins/SolidView/SolidView.py mode change 100644 => 100755 plugins/SolidView/__init__.py mode change 100644 => 100755 plugins/USBPrinting/FirmwareUpdateWindow.qml mode change 100644 => 100755 plugins/USBPrinting/USBPrinterOutputDevice.py mode change 100644 => 100755 plugins/USBPrinting/USBPrinterOutputDeviceManager.py mode change 100644 => 100755 plugins/USBPrinting/__init__.py mode change 100644 => 100755 plugins/USBPrinting/avr_isp/__init__.py mode change 100644 => 100755 plugins/USBPrinting/avr_isp/chipDB.py mode change 100644 => 100755 plugins/USBPrinting/avr_isp/intelHex.py mode change 100644 => 100755 plugins/USBPrinting/avr_isp/ispBase.py mode change 100644 => 100755 plugins/USBPrinting/avr_isp/stk500v2.py mode change 100644 => 100755 plugins/UltimakerMachineActions/BedLevelMachineAction.py mode change 100644 => 100755 plugins/UltimakerMachineActions/BedLevelMachineAction.qml mode change 100644 => 100755 plugins/UltimakerMachineActions/UMOCheckupMachineAction.py mode change 100644 => 100755 plugins/UltimakerMachineActions/UMOCheckupMachineAction.qml mode change 100644 => 100755 plugins/UltimakerMachineActions/UMOUpgradeSelection.py mode change 100644 => 100755 plugins/UltimakerMachineActions/UMOUpgradeSelectionMachineAction.qml mode change 100644 => 100755 plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.py mode change 100644 => 100755 plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.qml mode change 100644 => 100755 plugins/UltimakerMachineActions/__init__.py mode change 100644 => 100755 plugins/VersionUpgrade/VersionUpgrade21to22/MachineInstance.py mode change 100644 => 100755 plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py mode change 100644 => 100755 plugins/VersionUpgrade/VersionUpgrade21to22/Profile.py mode change 100644 => 100755 plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py mode change 100644 => 100755 plugins/VersionUpgrade/VersionUpgrade21to22/__init__.py mode change 100644 => 100755 plugins/X3DReader/X3DReader.py mode change 100644 => 100755 plugins/X3DReader/__init__.py mode change 100644 => 100755 plugins/XRayView/XRayPass.py mode change 100644 => 100755 plugins/XRayView/XRayView.py mode change 100644 => 100755 plugins/XRayView/__init__.py mode change 100644 => 100755 plugins/XRayView/xray.shader mode change 100644 => 100755 plugins/XRayView/xray_composite.shader mode change 100644 => 100755 plugins/XmlMaterialProfile/XmlMaterialProfile.py mode change 100644 => 100755 plugins/XmlMaterialProfile/__init__.py mode change 100644 => 100755 pytest.ini mode change 100644 => 100755 resources/definitions/bq_hephestos.def.json mode change 100644 => 100755 resources/definitions/bq_hephestos_2.def.json mode change 100644 => 100755 resources/definitions/bq_hephestos_xl.def.json mode change 100644 => 100755 resources/definitions/bq_witbox.def.json mode change 100644 => 100755 resources/definitions/bq_witbox_2.def.json mode change 100644 => 100755 resources/definitions/custom.def.json mode change 100644 => 100755 resources/definitions/fdmextruder.def.json mode change 100644 => 100755 resources/definitions/fdmprinter.def.json mode change 100644 => 100755 resources/definitions/grr_neo.def.json mode change 100644 => 100755 resources/definitions/innovo_inventor.def.json mode change 100644 => 100755 resources/definitions/kossel_mini.def.json mode change 100644 => 100755 resources/definitions/m180.def.json mode change 100644 => 100755 resources/definitions/maker_starter.def.json mode change 100644 => 100755 resources/definitions/mankati_fullscale_xt_plus.def.json mode change 100644 => 100755 resources/definitions/mendel90.def.json mode change 100644 => 100755 resources/definitions/printrbot_simple.def.json mode change 100644 => 100755 resources/definitions/prusa_i3.def.json mode change 100644 => 100755 resources/definitions/prusa_i3_mk2.def.json mode change 100644 => 100755 resources/definitions/prusa_i3_xl.def.json mode change 100644 => 100755 resources/definitions/rigidbot.def.json mode change 100644 => 100755 resources/definitions/rigidbot_big.def.json mode change 100644 => 100755 resources/definitions/ultimaker.def.json mode change 100644 => 100755 resources/definitions/ultimaker2.def.json mode change 100644 => 100755 resources/definitions/ultimaker2_extended.def.json mode change 100644 => 100755 resources/definitions/ultimaker2_extended_plus.def.json mode change 100644 => 100755 resources/definitions/ultimaker2_go.def.json mode change 100644 => 100755 resources/definitions/ultimaker2_plus.def.json mode change 100644 => 100755 resources/definitions/ultimaker_original.def.json mode change 100644 => 100755 resources/definitions/ultimaker_original_dual.def.json mode change 100644 => 100755 resources/definitions/ultimaker_original_plus.def.json mode change 100644 => 100755 resources/definitions/uniqbot_one.def.json mode change 100644 => 100755 resources/extruders/ultimaker_original_dual_1st.def.json mode change 100644 => 100755 resources/extruders/ultimaker_original_dual_2nd.def.json mode change 100644 => 100755 resources/i18n/cura.pot mode change 100644 => 100755 resources/i18n/de/cura.po mode change 100644 => 100755 resources/i18n/en/cura.po mode change 100644 => 100755 resources/i18n/es/cura.po mode change 100644 => 100755 resources/i18n/fdmextruder.def.json.pot mode change 100644 => 100755 resources/i18n/fdmprinter.def.json.pot mode change 100644 => 100755 resources/i18n/fi/cura.po mode change 100644 => 100755 resources/i18n/fr/cura.po mode change 100644 => 100755 resources/i18n/it/cura.po mode change 100644 => 100755 resources/i18n/nl/cura.po mode change 100644 => 100755 resources/images/MakerStarterbackplate.png mode change 100644 => 100755 resources/images/Ultimaker2ExtendedPlusbackplate.png mode change 100644 => 100755 resources/images/Ultimaker2Extendedbackplate.png mode change 100644 => 100755 resources/images/Ultimaker2Gobackplate.png mode change 100644 => 100755 resources/images/Ultimaker2Plusbackplate.png mode change 100644 => 100755 resources/images/Ultimaker2backplate.png mode change 100644 => 100755 resources/images/UltimakerPlusbackplate.png mode change 100644 => 100755 resources/images/cura-icon.png mode change 100644 => 100755 resources/images/cura.png mode change 100644 => 100755 resources/meshes/UltimakerRobot_support.stl mode change 100644 => 100755 resources/meshes/bq_hephestos_2_platform.stl mode change 100644 => 100755 resources/meshes/bq_hephestos_platform.stl mode change 100644 => 100755 resources/meshes/bq_witbox_platform.stl mode change 100644 => 100755 resources/meshes/grr_neo_platform.stl mode change 100644 => 100755 resources/meshes/inventor_platform.stl mode change 100644 => 100755 resources/meshes/kossel_platform.stl mode change 100644 => 100755 resources/meshes/makerstarter_platform.stl mode change 100644 => 100755 resources/meshes/mankati_fullscale_xt_plus_platform.stl mode change 100644 => 100755 resources/meshes/mendel90_platform.stl mode change 100644 => 100755 resources/meshes/printrbot_simple_metal_platform.stl mode change 100644 => 100755 resources/meshes/prusai3_platform.stl mode change 100644 => 100755 resources/meshes/prusai3_xl_platform.stl mode change 100644 => 100755 resources/meshes/rigidbot_platform.stl mode change 100644 => 100755 resources/meshes/rigidbotbig_platform.stl mode change 100644 => 100755 resources/meshes/ultimaker2_platform.obj mode change 100644 => 100755 resources/meshes/ultimaker2go_platform.obj mode change 100644 => 100755 resources/meshes/ultimaker_platform.stl mode change 100644 => 100755 resources/qml/AboutDialog.qml mode change 100644 => 100755 resources/qml/Actions.qml mode change 100644 => 100755 resources/qml/AddMachineDialog.qml mode change 100644 => 100755 resources/qml/Cura.qml mode change 100644 => 100755 resources/qml/EngineLog.qml mode change 100644 => 100755 resources/qml/JobSpecs.qml mode change 100644 => 100755 resources/qml/MachineAction.qml mode change 100644 => 100755 resources/qml/Menus/MaterialMenu.qml mode change 100644 => 100755 resources/qml/Menus/NozzleMenu.qml mode change 100644 => 100755 resources/qml/Menus/PrinterMenu.qml mode change 100644 => 100755 resources/qml/Menus/ProfileMenu.qml mode change 100644 => 100755 resources/qml/Menus/RecentFilesMenu.qml mode change 100644 => 100755 resources/qml/Menus/ViewMenu.qml mode change 100644 => 100755 resources/qml/MonitorButton.qml mode change 100644 => 100755 resources/qml/Preferences/GeneralPage.qml mode change 100644 => 100755 resources/qml/Preferences/MachinesPage.qml mode change 100644 => 100755 resources/qml/Preferences/MaterialView.qml mode change 100644 => 100755 resources/qml/Preferences/MaterialsPage.qml mode change 100644 => 100755 resources/qml/Preferences/ProfileTab.qml mode change 100644 => 100755 resources/qml/Preferences/ProfilesPage.qml mode change 100644 => 100755 resources/qml/Preferences/ReadOnlySpinBox.qml mode change 100644 => 100755 resources/qml/Preferences/ReadOnlyTextArea.qml mode change 100644 => 100755 resources/qml/Preferences/ReadOnlyTextField.qml mode change 100644 => 100755 resources/qml/Preferences/SettingVisibilityPage.qml mode change 100644 => 100755 resources/qml/PrintMonitor.qml mode change 100644 => 100755 resources/qml/SaveButton.qml mode change 100644 => 100755 resources/qml/Settings/SettingCategory.qml mode change 100644 => 100755 resources/qml/Settings/SettingCheckBox.qml mode change 100644 => 100755 resources/qml/Settings/SettingComboBox.qml mode change 100644 => 100755 resources/qml/Settings/SettingExtruder.qml mode change 100644 => 100755 resources/qml/Settings/SettingItem.qml mode change 100644 => 100755 resources/qml/Settings/SettingTextField.qml mode change 100644 => 100755 resources/qml/Settings/SettingUnknown.qml mode change 100644 => 100755 resources/qml/Settings/SettingView.qml mode change 100644 => 100755 resources/qml/Sidebar.qml mode change 100644 => 100755 resources/qml/SidebarAdvanced.qml mode change 100644 => 100755 resources/qml/SidebarContents.qml mode change 100644 => 100755 resources/qml/SidebarHeader.qml mode change 100644 => 100755 resources/qml/SidebarSimple.qml mode change 100644 => 100755 resources/qml/SidebarTooltip.qml mode change 100644 => 100755 resources/qml/Toolbar.qml mode change 100644 => 100755 resources/quality/high.inst.cfg mode change 100644 => 100755 resources/quality/low.inst.cfg mode change 100644 => 100755 resources/quality/normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/pla_0.25_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/pla_0.4_fast.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/pla_0.4_high.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/pla_0.4_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/pla_0.6_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/pla_0.8_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_abs_0.4_high.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.25_high.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg mode change 100644 => 100755 resources/quality/ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg mode change 100644 => 100755 resources/shaders/grid.shader mode change 100644 => 100755 resources/shaders/overhang.shader mode change 100644 => 100755 resources/shaders/striped.shader mode change 100644 => 100755 resources/shaders/transparent_object.shader mode change 100644 => 100755 resources/themes/cura/fonts/LICENSE.txt mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-Bold.ttf mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-BoldItalic.ttf mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-Italic.ttf mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-Light.ttf mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-LightItalic.ttf mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-Regular.ttf mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-Semibold.ttf mode change 100644 => 100755 resources/themes/cura/fonts/OpenSans-SemiboldItalic.ttf mode change 100644 => 100755 resources/themes/cura/icons/application.svg mode change 100644 => 100755 resources/themes/cura/icons/arrow_bottom.svg mode change 100644 => 100755 resources/themes/cura/icons/arrow_left.svg mode change 100644 => 100755 resources/themes/cura/icons/arrow_right.svg mode change 100644 => 100755 resources/themes/cura/icons/arrow_top.svg mode change 100644 => 100755 resources/themes/cura/icons/basic.svg mode change 100644 => 100755 resources/themes/cura/icons/category_adhesion.svg mode change 100644 => 100755 resources/themes/cura/icons/category_blackmagic.svg mode change 100644 => 100755 resources/themes/cura/icons/category_cool.svg mode change 100644 => 100755 resources/themes/cura/icons/category_dual.svg mode change 100644 => 100755 resources/themes/cura/icons/category_experimental.svg mode change 100644 => 100755 resources/themes/cura/icons/category_fixes.svg mode change 100644 => 100755 resources/themes/cura/icons/category_infill.svg mode change 100644 => 100755 resources/themes/cura/icons/category_layer_height.svg mode change 100644 => 100755 resources/themes/cura/icons/category_machine.svg mode change 100644 => 100755 resources/themes/cura/icons/category_material.svg mode change 100644 => 100755 resources/themes/cura/icons/category_shell.svg mode change 100644 => 100755 resources/themes/cura/icons/category_shield.svg mode change 100644 => 100755 resources/themes/cura/icons/category_speed.svg mode change 100644 => 100755 resources/themes/cura/icons/category_support.svg mode change 100644 => 100755 resources/themes/cura/icons/category_travel.svg mode change 100644 => 100755 resources/themes/cura/icons/category_unknown.svg mode change 100644 => 100755 resources/themes/cura/icons/check.svg mode change 100644 => 100755 resources/themes/cura/icons/cross1.svg mode change 100644 => 100755 resources/themes/cura/icons/cross2.svg mode change 100644 => 100755 resources/themes/cura/icons/dense.svg mode change 100644 => 100755 resources/themes/cura/icons/dot.svg mode change 100644 => 100755 resources/themes/cura/icons/hollow.svg mode change 100644 => 100755 resources/themes/cura/icons/link.svg mode change 100644 => 100755 resources/themes/cura/icons/load.svg mode change 100644 => 100755 resources/themes/cura/icons/minus.svg mode change 100644 => 100755 resources/themes/cura/icons/mirror.svg mode change 100644 => 100755 resources/themes/cura/icons/notice.svg mode change 100644 => 100755 resources/themes/cura/icons/pencil.svg mode change 100644 => 100755 resources/themes/cura/icons/plugin.svg mode change 100644 => 100755 resources/themes/cura/icons/plus.svg mode change 100644 => 100755 resources/themes/cura/icons/print_time.svg mode change 100644 => 100755 resources/themes/cura/icons/printsetup.svg mode change 100644 => 100755 resources/themes/cura/icons/quick.svg mode change 100644 => 100755 resources/themes/cura/icons/reset.svg mode change 100644 => 100755 resources/themes/cura/icons/rotate.svg mode change 100644 => 100755 resources/themes/cura/icons/rotate_layflat.svg mode change 100644 => 100755 resources/themes/cura/icons/rotate_reset.svg mode change 100644 => 100755 resources/themes/cura/icons/scale.svg mode change 100644 => 100755 resources/themes/cura/icons/scale_max.svg mode change 100644 => 100755 resources/themes/cura/icons/scale_reset.svg mode change 100644 => 100755 resources/themes/cura/icons/setting_per_object.svg mode change 100644 => 100755 resources/themes/cura/icons/settings.svg mode change 100644 => 100755 resources/themes/cura/icons/solid.svg mode change 100644 => 100755 resources/themes/cura/icons/sparse.svg mode change 100644 => 100755 resources/themes/cura/icons/star.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_monitor.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_monitor_busy.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_monitor_connected.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_monitor_offline.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_monitor_paused.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_monitor_stopped.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_monitor_unknown.svg mode change 100644 => 100755 resources/themes/cura/icons/tab_settings.svg mode change 100644 => 100755 resources/themes/cura/icons/translate.svg mode change 100644 => 100755 resources/themes/cura/icons/ulti.svg mode change 100644 => 100755 resources/themes/cura/icons/view_layer.svg mode change 100644 => 100755 resources/themes/cura/icons/view_normal.svg mode change 100644 => 100755 resources/themes/cura/icons/view_xray.svg mode change 100644 => 100755 resources/themes/cura/icons/viewmode.svg mode change 100644 => 100755 resources/themes/cura/icons/warning.svg mode change 100644 => 100755 resources/themes/cura/images/logo.svg mode change 100644 => 100755 resources/themes/cura/styles.qml mode change 100644 => 100755 resources/themes/cura/theme.json mode change 100644 => 100755 resources/variants/ultimaker2_extended_plus_0.25.inst.cfg mode change 100644 => 100755 resources/variants/ultimaker2_extended_plus_0.4.inst.cfg mode change 100644 => 100755 resources/variants/ultimaker2_extended_plus_0.6.inst.cfg mode change 100644 => 100755 resources/variants/ultimaker2_extended_plus_0.8.inst.cfg mode change 100644 => 100755 resources/variants/ultimaker2_plus_0.25.inst.cfg mode change 100644 => 100755 resources/variants/ultimaker2_plus_0.4.inst.cfg mode change 100644 => 100755 resources/variants/ultimaker2_plus_0.6.inst.cfg mode change 100644 => 100755 resources/variants/ultimaker2_plus_0.8.inst.cfg mode change 100644 => 100755 setup.py mode change 100644 => 100755 tests/TestMachineAction.py diff --git a/.gitignore b/.gitignore old mode 100644 new mode 100755 diff --git a/CHANGES b/CHANGES old mode 100644 new mode 100755 diff --git a/CMakeLists.txt b/CMakeLists.txt old mode 100644 new mode 100755 diff --git a/CPackConfig.cmake b/CPackConfig.cmake old mode 100644 new mode 100755 diff --git a/LICENSE b/LICENSE old mode 100644 new mode 100755 diff --git a/README.md b/README.md old mode 100644 new mode 100755 diff --git a/build.sh b/build.sh old mode 100644 new mode 100755 diff --git a/cura.desktop.in b/cura.desktop.in old mode 100644 new mode 100755 diff --git a/cura.sharedmimeinfo b/cura.sharedmimeinfo old mode 100644 new mode 100755 diff --git a/cura/BuildVolume.py b/cura/BuildVolume.py old mode 100644 new mode 100755 diff --git a/cura/CameraAnimation.py b/cura/CameraAnimation.py old mode 100644 new mode 100755 diff --git a/cura/CameraImageProvider.py b/cura/CameraImageProvider.py old mode 100644 new mode 100755 diff --git a/cura/ConvexHullDecorator.py b/cura/ConvexHullDecorator.py old mode 100644 new mode 100755 diff --git a/cura/ConvexHullNode.py b/cura/ConvexHullNode.py old mode 100644 new mode 100755 diff --git a/cura/CrashHandler.py b/cura/CrashHandler.py old mode 100644 new mode 100755 diff --git a/cura/CuraActions.py b/cura/CuraActions.py old mode 100644 new mode 100755 diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py old mode 100644 new mode 100755 diff --git a/cura/CuraSplashScreen.py b/cura/CuraSplashScreen.py old mode 100644 new mode 100755 diff --git a/cura/CuraVersion.py.in b/cura/CuraVersion.py.in old mode 100644 new mode 100755 diff --git a/cura/Layer.py b/cura/Layer.py old mode 100644 new mode 100755 diff --git a/cura/LayerData.py b/cura/LayerData.py old mode 100644 new mode 100755 diff --git a/cura/LayerDataBuilder.py b/cura/LayerDataBuilder.py old mode 100644 new mode 100755 diff --git a/cura/LayerDataDecorator.py b/cura/LayerDataDecorator.py old mode 100644 new mode 100755 diff --git a/cura/LayerPolygon.py b/cura/LayerPolygon.py old mode 100644 new mode 100755 diff --git a/cura/MachineAction.py b/cura/MachineAction.py old mode 100644 new mode 100755 diff --git a/cura/MachineActionManager.py b/cura/MachineActionManager.py old mode 100644 new mode 100755 diff --git a/cura/OneAtATimeIterator.py b/cura/OneAtATimeIterator.py old mode 100644 new mode 100755 diff --git a/cura/PlatformPhysics.py b/cura/PlatformPhysics.py old mode 100644 new mode 100755 diff --git a/cura/PlatformPhysicsOperation.py b/cura/PlatformPhysicsOperation.py old mode 100644 new mode 100755 diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py old mode 100644 new mode 100755 diff --git a/cura/PrinterOutputDevice.py b/cura/PrinterOutputDevice.py old mode 100644 new mode 100755 diff --git a/cura/ProfileReader.py b/cura/ProfileReader.py old mode 100644 new mode 100755 diff --git a/cura/ProfileWriter.py b/cura/ProfileWriter.py old mode 100644 new mode 100755 diff --git a/cura/SetParentOperation.py b/cura/SetParentOperation.py old mode 100644 new mode 100755 diff --git a/cura/Settings/ContainerManager.py b/cura/Settings/ContainerManager.py old mode 100644 new mode 100755 diff --git a/cura/Settings/ContainerSettingsModel.py b/cura/Settings/ContainerSettingsModel.py old mode 100644 new mode 100755 diff --git a/cura/Settings/CuraContainerRegistry.py b/cura/Settings/CuraContainerRegistry.py old mode 100644 new mode 100755 diff --git a/cura/Settings/ExtruderManager.py b/cura/Settings/ExtruderManager.py old mode 100644 new mode 100755 diff --git a/cura/Settings/ExtrudersModel.py b/cura/Settings/ExtrudersModel.py old mode 100644 new mode 100755 diff --git a/cura/Settings/MachineManager.py b/cura/Settings/MachineManager.py old mode 100644 new mode 100755 diff --git a/cura/Settings/MaterialSettingsVisibilityHandler.py b/cura/Settings/MaterialSettingsVisibilityHandler.py old mode 100644 new mode 100755 diff --git a/cura/Settings/QualitySettingsModel.py b/cura/Settings/QualitySettingsModel.py old mode 100644 new mode 100755 diff --git a/cura/Settings/SettingInheritanceManager.py b/cura/Settings/SettingInheritanceManager.py old mode 100644 new mode 100755 diff --git a/cura/Settings/SettingOverrideDecorator.py b/cura/Settings/SettingOverrideDecorator.py old mode 100644 new mode 100755 diff --git a/cura/Settings/__init__.py b/cura/Settings/__init__.py old mode 100644 new mode 100755 diff --git a/cura/ZOffsetDecorator.py b/cura/ZOffsetDecorator.py old mode 100644 new mode 100755 diff --git a/cura/__init__.py b/cura/__init__.py old mode 100644 new mode 100755 diff --git a/icons/cura-128.png b/icons/cura-128.png old mode 100644 new mode 100755 diff --git a/icons/cura-32.png b/icons/cura-32.png old mode 100644 new mode 100755 diff --git a/icons/cura-48.png b/icons/cura-48.png old mode 100644 new mode 100755 diff --git a/icons/cura-64.png b/icons/cura-64.png old mode 100644 new mode 100755 diff --git a/icons/cura.icns b/icons/cura.icns old mode 100644 new mode 100755 diff --git a/icons/cura.ico b/icons/cura.ico old mode 100644 new mode 100755 diff --git a/installer.nsi b/installer.nsi old mode 100644 new mode 100755 diff --git a/plugins/3MFReader/ThreeMFReader.py b/plugins/3MFReader/ThreeMFReader.py old mode 100644 new mode 100755 diff --git a/plugins/3MFReader/__init__.py b/plugins/3MFReader/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/AutoSave/AutoSave.py b/plugins/AutoSave/AutoSave.py old mode 100644 new mode 100755 diff --git a/plugins/AutoSave/__init__.py b/plugins/AutoSave/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/ChangeLogPlugin/ChangeLog.py b/plugins/ChangeLogPlugin/ChangeLog.py old mode 100644 new mode 100755 diff --git a/plugins/ChangeLogPlugin/ChangeLog.qml b/plugins/ChangeLogPlugin/ChangeLog.qml old mode 100644 new mode 100755 diff --git a/plugins/ChangeLogPlugin/ChangeLog.txt b/plugins/ChangeLogPlugin/ChangeLog.txt old mode 100644 new mode 100755 diff --git a/plugins/ChangeLogPlugin/__init__.py b/plugins/ChangeLogPlugin/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/CuraEngineBackend/Cura.proto b/plugins/CuraEngineBackend/Cura.proto old mode 100644 new mode 100755 diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py old mode 100644 new mode 100755 diff --git a/plugins/CuraEngineBackend/ProcessGCodeJob.py b/plugins/CuraEngineBackend/ProcessGCodeJob.py old mode 100644 new mode 100755 diff --git a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py old mode 100644 new mode 100755 diff --git a/plugins/CuraEngineBackend/StartSliceJob.py b/plugins/CuraEngineBackend/StartSliceJob.py old mode 100644 new mode 100755 diff --git a/plugins/CuraEngineBackend/__init__.py b/plugins/CuraEngineBackend/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/CuraProfileReader/CuraProfileReader.py b/plugins/CuraProfileReader/CuraProfileReader.py old mode 100644 new mode 100755 diff --git a/plugins/CuraProfileReader/__init__.py b/plugins/CuraProfileReader/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/CuraProfileWriter/CuraProfileWriter.py b/plugins/CuraProfileWriter/CuraProfileWriter.py old mode 100644 new mode 100755 diff --git a/plugins/CuraProfileWriter/__init__.py b/plugins/CuraProfileWriter/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py old mode 100644 new mode 100755 index 8305061a59..edc634a091 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -76,7 +76,7 @@ class GCODEReader(MeshReader): else: backend = Application.getInstance().getBackend() backend._pauseSlicing = True - backend.backendStateChange.emit(1) + backend.backendStateChange.emit(3) Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" Application.getInstance().setHideSettings(True) @@ -116,6 +116,9 @@ class GCODEReader(MeshReader): backend.close() backend.backendStateChange.emit(1) + glist = getattr(Application.getInstance().getController().getScene(), "gcode_list") + glist.clear() + file = open(file_name, "r") layer_data = LayerDataBuilder.LayerDataBuilder() @@ -159,6 +162,7 @@ class GCODEReader(MeshReader): # current_path.append([10, 10, 10]) # while file.readable(): for line in file: + glist.append(line) if len(line) == 0: continue if line[0] == ";": @@ -241,6 +245,8 @@ class GCODEReader(MeshReader): Preferences.getInstance().setValue("cura/jobname_prefix", True) + + view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() diff --git a/plugins/GCODEReader/__init__.py b/plugins/GCODEReader/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/GCodeProfileReader/GCodeProfileReader.py b/plugins/GCodeProfileReader/GCodeProfileReader.py old mode 100644 new mode 100755 diff --git a/plugins/GCodeProfileReader/__init__.py b/plugins/GCodeProfileReader/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/GCodeWriter/GCodeWriter.py b/plugins/GCodeWriter/GCodeWriter.py old mode 100644 new mode 100755 diff --git a/plugins/GCodeWriter/__init__.py b/plugins/GCodeWriter/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/ImageReader/ConfigUI.qml b/plugins/ImageReader/ConfigUI.qml old mode 100644 new mode 100755 diff --git a/plugins/ImageReader/ImageReader.py b/plugins/ImageReader/ImageReader.py old mode 100644 new mode 100755 diff --git a/plugins/ImageReader/ImageReaderUI.py b/plugins/ImageReader/ImageReaderUI.py old mode 100644 new mode 100755 diff --git a/plugins/ImageReader/__init__.py b/plugins/ImageReader/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py old mode 100644 new mode 100755 diff --git a/plugins/LayerView/LayerView.py b/plugins/LayerView/LayerView.py old mode 100644 new mode 100755 diff --git a/plugins/LayerView/LayerView.qml b/plugins/LayerView/LayerView.qml old mode 100644 new mode 100755 diff --git a/plugins/LayerView/LayerViewProxy.py b/plugins/LayerView/LayerViewProxy.py old mode 100644 new mode 100755 diff --git a/plugins/LayerView/__init__.py b/plugins/LayerView/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/LayerView/layerview_composite.shader b/plugins/LayerView/layerview_composite.shader old mode 100644 new mode 100755 diff --git a/plugins/LegacyProfileReader/DictionaryOfDoom.json b/plugins/LegacyProfileReader/DictionaryOfDoom.json old mode 100644 new mode 100755 diff --git a/plugins/LegacyProfileReader/LegacyProfileReader.py b/plugins/LegacyProfileReader/LegacyProfileReader.py old mode 100644 new mode 100755 diff --git a/plugins/LegacyProfileReader/__init__.py b/plugins/LegacyProfileReader/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/MachineSettingsAction/MachineSettingsAction.py b/plugins/MachineSettingsAction/MachineSettingsAction.py old mode 100644 new mode 100755 diff --git a/plugins/MachineSettingsAction/MachineSettingsAction.qml b/plugins/MachineSettingsAction/MachineSettingsAction.qml old mode 100644 new mode 100755 diff --git a/plugins/MachineSettingsAction/__init__.py b/plugins/MachineSettingsAction/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/PerObjectSettingsTool/PerObjectCategory.qml b/plugins/PerObjectSettingsTool/PerObjectCategory.qml old mode 100644 new mode 100755 diff --git a/plugins/PerObjectSettingsTool/PerObjectItem.qml b/plugins/PerObjectSettingsTool/PerObjectItem.qml old mode 100644 new mode 100755 diff --git a/plugins/PerObjectSettingsTool/PerObjectSettingVisibilityHandler.py b/plugins/PerObjectSettingsTool/PerObjectSettingVisibilityHandler.py old mode 100644 new mode 100755 diff --git a/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml b/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml old mode 100644 new mode 100755 diff --git a/plugins/PerObjectSettingsTool/PerObjectSettingsTool.py b/plugins/PerObjectSettingsTool/PerObjectSettingsTool.py old mode 100644 new mode 100755 diff --git a/plugins/PerObjectSettingsTool/__init__.py b/plugins/PerObjectSettingsTool/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/RemovableDriveOutputDevice/LinuxRemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/LinuxRemovableDrivePlugin.py old mode 100644 new mode 100755 diff --git a/plugins/RemovableDriveOutputDevice/OSXRemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/OSXRemovableDrivePlugin.py old mode 100644 new mode 100755 diff --git a/plugins/RemovableDriveOutputDevice/RemovableDriveOutputDevice.py b/plugins/RemovableDriveOutputDevice/RemovableDriveOutputDevice.py old mode 100644 new mode 100755 diff --git a/plugins/RemovableDriveOutputDevice/RemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/RemovableDrivePlugin.py old mode 100644 new mode 100755 diff --git a/plugins/RemovableDriveOutputDevice/WindowsRemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/WindowsRemovableDrivePlugin.py old mode 100644 new mode 100755 diff --git a/plugins/RemovableDriveOutputDevice/__init__.py b/plugins/RemovableDriveOutputDevice/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/SolidView/SolidView.py b/plugins/SolidView/SolidView.py old mode 100644 new mode 100755 diff --git a/plugins/SolidView/__init__.py b/plugins/SolidView/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/FirmwareUpdateWindow.qml b/plugins/USBPrinting/FirmwareUpdateWindow.qml old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/USBPrinterOutputDevice.py b/plugins/USBPrinting/USBPrinterOutputDevice.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/USBPrinterOutputDeviceManager.py b/plugins/USBPrinting/USBPrinterOutputDeviceManager.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/__init__.py b/plugins/USBPrinting/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/avr_isp/__init__.py b/plugins/USBPrinting/avr_isp/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/avr_isp/chipDB.py b/plugins/USBPrinting/avr_isp/chipDB.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/avr_isp/intelHex.py b/plugins/USBPrinting/avr_isp/intelHex.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/avr_isp/ispBase.py b/plugins/USBPrinting/avr_isp/ispBase.py old mode 100644 new mode 100755 diff --git a/plugins/USBPrinting/avr_isp/stk500v2.py b/plugins/USBPrinting/avr_isp/stk500v2.py old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/BedLevelMachineAction.py b/plugins/UltimakerMachineActions/BedLevelMachineAction.py old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/BedLevelMachineAction.qml b/plugins/UltimakerMachineActions/BedLevelMachineAction.qml old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/UMOCheckupMachineAction.py b/plugins/UltimakerMachineActions/UMOCheckupMachineAction.py old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/UMOCheckupMachineAction.qml b/plugins/UltimakerMachineActions/UMOCheckupMachineAction.qml old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/UMOUpgradeSelection.py b/plugins/UltimakerMachineActions/UMOUpgradeSelection.py old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/UMOUpgradeSelectionMachineAction.qml b/plugins/UltimakerMachineActions/UMOUpgradeSelectionMachineAction.qml old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.py b/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.py old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.qml b/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.qml old mode 100644 new mode 100755 diff --git a/plugins/UltimakerMachineActions/__init__.py b/plugins/UltimakerMachineActions/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/MachineInstance.py b/plugins/VersionUpgrade/VersionUpgrade21to22/MachineInstance.py old mode 100644 new mode 100755 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py b/plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py old mode 100644 new mode 100755 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/Profile.py b/plugins/VersionUpgrade/VersionUpgrade21to22/Profile.py old mode 100644 new mode 100755 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py b/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py old mode 100644 new mode 100755 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/__init__.py b/plugins/VersionUpgrade/VersionUpgrade21to22/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/X3DReader/X3DReader.py b/plugins/X3DReader/X3DReader.py old mode 100644 new mode 100755 diff --git a/plugins/X3DReader/__init__.py b/plugins/X3DReader/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/XRayView/XRayPass.py b/plugins/XRayView/XRayPass.py old mode 100644 new mode 100755 diff --git a/plugins/XRayView/XRayView.py b/plugins/XRayView/XRayView.py old mode 100644 new mode 100755 diff --git a/plugins/XRayView/__init__.py b/plugins/XRayView/__init__.py old mode 100644 new mode 100755 diff --git a/plugins/XRayView/xray.shader b/plugins/XRayView/xray.shader old mode 100644 new mode 100755 diff --git a/plugins/XRayView/xray_composite.shader b/plugins/XRayView/xray_composite.shader old mode 100644 new mode 100755 diff --git a/plugins/XmlMaterialProfile/XmlMaterialProfile.py b/plugins/XmlMaterialProfile/XmlMaterialProfile.py old mode 100644 new mode 100755 diff --git a/plugins/XmlMaterialProfile/__init__.py b/plugins/XmlMaterialProfile/__init__.py old mode 100644 new mode 100755 diff --git a/pytest.ini b/pytest.ini old mode 100644 new mode 100755 diff --git a/resources/definitions/bq_hephestos.def.json b/resources/definitions/bq_hephestos.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/bq_hephestos_2.def.json b/resources/definitions/bq_hephestos_2.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/bq_hephestos_xl.def.json b/resources/definitions/bq_hephestos_xl.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/bq_witbox.def.json b/resources/definitions/bq_witbox.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/bq_witbox_2.def.json b/resources/definitions/bq_witbox_2.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/custom.def.json b/resources/definitions/custom.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/fdmextruder.def.json b/resources/definitions/fdmextruder.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/grr_neo.def.json b/resources/definitions/grr_neo.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/innovo_inventor.def.json b/resources/definitions/innovo_inventor.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/kossel_mini.def.json b/resources/definitions/kossel_mini.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/m180.def.json b/resources/definitions/m180.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/maker_starter.def.json b/resources/definitions/maker_starter.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/mankati_fullscale_xt_plus.def.json b/resources/definitions/mankati_fullscale_xt_plus.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/mendel90.def.json b/resources/definitions/mendel90.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/printrbot_simple.def.json b/resources/definitions/printrbot_simple.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/prusa_i3.def.json b/resources/definitions/prusa_i3.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/prusa_i3_mk2.def.json b/resources/definitions/prusa_i3_mk2.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/prusa_i3_xl.def.json b/resources/definitions/prusa_i3_xl.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/rigidbot.def.json b/resources/definitions/rigidbot.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/rigidbot_big.def.json b/resources/definitions/rigidbot_big.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker.def.json b/resources/definitions/ultimaker.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker2.def.json b/resources/definitions/ultimaker2.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker2_extended.def.json b/resources/definitions/ultimaker2_extended.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker2_extended_plus.def.json b/resources/definitions/ultimaker2_extended_plus.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker2_go.def.json b/resources/definitions/ultimaker2_go.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker2_plus.def.json b/resources/definitions/ultimaker2_plus.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker_original.def.json b/resources/definitions/ultimaker_original.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker_original_dual.def.json b/resources/definitions/ultimaker_original_dual.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/ultimaker_original_plus.def.json b/resources/definitions/ultimaker_original_plus.def.json old mode 100644 new mode 100755 diff --git a/resources/definitions/uniqbot_one.def.json b/resources/definitions/uniqbot_one.def.json old mode 100644 new mode 100755 diff --git a/resources/extruders/ultimaker_original_dual_1st.def.json b/resources/extruders/ultimaker_original_dual_1st.def.json old mode 100644 new mode 100755 diff --git a/resources/extruders/ultimaker_original_dual_2nd.def.json b/resources/extruders/ultimaker_original_dual_2nd.def.json old mode 100644 new mode 100755 diff --git a/resources/i18n/cura.pot b/resources/i18n/cura.pot old mode 100644 new mode 100755 diff --git a/resources/i18n/de/cura.po b/resources/i18n/de/cura.po old mode 100644 new mode 100755 diff --git a/resources/i18n/en/cura.po b/resources/i18n/en/cura.po old mode 100644 new mode 100755 diff --git a/resources/i18n/es/cura.po b/resources/i18n/es/cura.po old mode 100644 new mode 100755 diff --git a/resources/i18n/fdmextruder.def.json.pot b/resources/i18n/fdmextruder.def.json.pot old mode 100644 new mode 100755 diff --git a/resources/i18n/fdmprinter.def.json.pot b/resources/i18n/fdmprinter.def.json.pot old mode 100644 new mode 100755 diff --git a/resources/i18n/fi/cura.po b/resources/i18n/fi/cura.po old mode 100644 new mode 100755 diff --git a/resources/i18n/fr/cura.po b/resources/i18n/fr/cura.po old mode 100644 new mode 100755 diff --git a/resources/i18n/it/cura.po b/resources/i18n/it/cura.po old mode 100644 new mode 100755 diff --git a/resources/i18n/nl/cura.po b/resources/i18n/nl/cura.po old mode 100644 new mode 100755 diff --git a/resources/images/MakerStarterbackplate.png b/resources/images/MakerStarterbackplate.png old mode 100644 new mode 100755 diff --git a/resources/images/Ultimaker2ExtendedPlusbackplate.png b/resources/images/Ultimaker2ExtendedPlusbackplate.png old mode 100644 new mode 100755 diff --git a/resources/images/Ultimaker2Extendedbackplate.png b/resources/images/Ultimaker2Extendedbackplate.png old mode 100644 new mode 100755 diff --git a/resources/images/Ultimaker2Gobackplate.png b/resources/images/Ultimaker2Gobackplate.png old mode 100644 new mode 100755 diff --git a/resources/images/Ultimaker2Plusbackplate.png b/resources/images/Ultimaker2Plusbackplate.png old mode 100644 new mode 100755 diff --git a/resources/images/Ultimaker2backplate.png b/resources/images/Ultimaker2backplate.png old mode 100644 new mode 100755 diff --git a/resources/images/UltimakerPlusbackplate.png b/resources/images/UltimakerPlusbackplate.png old mode 100644 new mode 100755 diff --git a/resources/images/cura-icon.png b/resources/images/cura-icon.png old mode 100644 new mode 100755 diff --git a/resources/images/cura.png b/resources/images/cura.png old mode 100644 new mode 100755 diff --git a/resources/meshes/UltimakerRobot_support.stl b/resources/meshes/UltimakerRobot_support.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/bq_hephestos_2_platform.stl b/resources/meshes/bq_hephestos_2_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/bq_hephestos_platform.stl b/resources/meshes/bq_hephestos_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/bq_witbox_platform.stl b/resources/meshes/bq_witbox_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/grr_neo_platform.stl b/resources/meshes/grr_neo_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/inventor_platform.stl b/resources/meshes/inventor_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/kossel_platform.stl b/resources/meshes/kossel_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/makerstarter_platform.stl b/resources/meshes/makerstarter_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/mankati_fullscale_xt_plus_platform.stl b/resources/meshes/mankati_fullscale_xt_plus_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/mendel90_platform.stl b/resources/meshes/mendel90_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/printrbot_simple_metal_platform.stl b/resources/meshes/printrbot_simple_metal_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/prusai3_platform.stl b/resources/meshes/prusai3_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/prusai3_xl_platform.stl b/resources/meshes/prusai3_xl_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/rigidbot_platform.stl b/resources/meshes/rigidbot_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/rigidbotbig_platform.stl b/resources/meshes/rigidbotbig_platform.stl old mode 100644 new mode 100755 diff --git a/resources/meshes/ultimaker2_platform.obj b/resources/meshes/ultimaker2_platform.obj old mode 100644 new mode 100755 diff --git a/resources/meshes/ultimaker2go_platform.obj b/resources/meshes/ultimaker2go_platform.obj old mode 100644 new mode 100755 diff --git a/resources/meshes/ultimaker_platform.stl b/resources/meshes/ultimaker_platform.stl old mode 100644 new mode 100755 diff --git a/resources/qml/AboutDialog.qml b/resources/qml/AboutDialog.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Actions.qml b/resources/qml/Actions.qml old mode 100644 new mode 100755 diff --git a/resources/qml/AddMachineDialog.qml b/resources/qml/AddMachineDialog.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml old mode 100644 new mode 100755 diff --git a/resources/qml/EngineLog.qml b/resources/qml/EngineLog.qml old mode 100644 new mode 100755 diff --git a/resources/qml/JobSpecs.qml b/resources/qml/JobSpecs.qml old mode 100644 new mode 100755 diff --git a/resources/qml/MachineAction.qml b/resources/qml/MachineAction.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Menus/MaterialMenu.qml b/resources/qml/Menus/MaterialMenu.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Menus/NozzleMenu.qml b/resources/qml/Menus/NozzleMenu.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Menus/PrinterMenu.qml b/resources/qml/Menus/PrinterMenu.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Menus/ProfileMenu.qml b/resources/qml/Menus/ProfileMenu.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Menus/RecentFilesMenu.qml b/resources/qml/Menus/RecentFilesMenu.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Menus/ViewMenu.qml b/resources/qml/Menus/ViewMenu.qml old mode 100644 new mode 100755 diff --git a/resources/qml/MonitorButton.qml b/resources/qml/MonitorButton.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/GeneralPage.qml b/resources/qml/Preferences/GeneralPage.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/MachinesPage.qml b/resources/qml/Preferences/MachinesPage.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/MaterialView.qml b/resources/qml/Preferences/MaterialView.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/MaterialsPage.qml b/resources/qml/Preferences/MaterialsPage.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/ProfileTab.qml b/resources/qml/Preferences/ProfileTab.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/ProfilesPage.qml b/resources/qml/Preferences/ProfilesPage.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/ReadOnlySpinBox.qml b/resources/qml/Preferences/ReadOnlySpinBox.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/ReadOnlyTextArea.qml b/resources/qml/Preferences/ReadOnlyTextArea.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/ReadOnlyTextField.qml b/resources/qml/Preferences/ReadOnlyTextField.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Preferences/SettingVisibilityPage.qml b/resources/qml/Preferences/SettingVisibilityPage.qml old mode 100644 new mode 100755 diff --git a/resources/qml/PrintMonitor.qml b/resources/qml/PrintMonitor.qml old mode 100644 new mode 100755 diff --git a/resources/qml/SaveButton.qml b/resources/qml/SaveButton.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingCategory.qml b/resources/qml/Settings/SettingCategory.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingCheckBox.qml b/resources/qml/Settings/SettingCheckBox.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingComboBox.qml b/resources/qml/Settings/SettingComboBox.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingExtruder.qml b/resources/qml/Settings/SettingExtruder.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingItem.qml b/resources/qml/Settings/SettingItem.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingTextField.qml b/resources/qml/Settings/SettingTextField.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingUnknown.qml b/resources/qml/Settings/SettingUnknown.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Settings/SettingView.qml b/resources/qml/Settings/SettingView.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml old mode 100644 new mode 100755 diff --git a/resources/qml/SidebarAdvanced.qml b/resources/qml/SidebarAdvanced.qml old mode 100644 new mode 100755 diff --git a/resources/qml/SidebarContents.qml b/resources/qml/SidebarContents.qml old mode 100644 new mode 100755 diff --git a/resources/qml/SidebarHeader.qml b/resources/qml/SidebarHeader.qml old mode 100644 new mode 100755 diff --git a/resources/qml/SidebarSimple.qml b/resources/qml/SidebarSimple.qml old mode 100644 new mode 100755 diff --git a/resources/qml/SidebarTooltip.qml b/resources/qml/SidebarTooltip.qml old mode 100644 new mode 100755 diff --git a/resources/qml/Toolbar.qml b/resources/qml/Toolbar.qml old mode 100644 new mode 100755 diff --git a/resources/quality/high.inst.cfg b/resources/quality/high.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/low.inst.cfg b/resources/quality/low.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/normal.inst.cfg b/resources/quality/normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/pla_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.25_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/pla_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.4_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/pla_0.4_high.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.4_high.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/pla_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.4_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/pla_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.6_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/pla_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.8_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.4_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.4_high.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.25_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.25_high.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/quality/ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/shaders/grid.shader b/resources/shaders/grid.shader old mode 100644 new mode 100755 diff --git a/resources/shaders/overhang.shader b/resources/shaders/overhang.shader old mode 100644 new mode 100755 diff --git a/resources/shaders/striped.shader b/resources/shaders/striped.shader old mode 100644 new mode 100755 diff --git a/resources/shaders/transparent_object.shader b/resources/shaders/transparent_object.shader old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/LICENSE.txt b/resources/themes/cura/fonts/LICENSE.txt old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-Bold.ttf b/resources/themes/cura/fonts/OpenSans-Bold.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-BoldItalic.ttf b/resources/themes/cura/fonts/OpenSans-BoldItalic.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-Italic.ttf b/resources/themes/cura/fonts/OpenSans-Italic.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-Light.ttf b/resources/themes/cura/fonts/OpenSans-Light.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-LightItalic.ttf b/resources/themes/cura/fonts/OpenSans-LightItalic.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-Regular.ttf b/resources/themes/cura/fonts/OpenSans-Regular.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-Semibold.ttf b/resources/themes/cura/fonts/OpenSans-Semibold.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/fonts/OpenSans-SemiboldItalic.ttf b/resources/themes/cura/fonts/OpenSans-SemiboldItalic.ttf old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/application.svg b/resources/themes/cura/icons/application.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/arrow_bottom.svg b/resources/themes/cura/icons/arrow_bottom.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/arrow_left.svg b/resources/themes/cura/icons/arrow_left.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/arrow_right.svg b/resources/themes/cura/icons/arrow_right.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/arrow_top.svg b/resources/themes/cura/icons/arrow_top.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/basic.svg b/resources/themes/cura/icons/basic.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_adhesion.svg b/resources/themes/cura/icons/category_adhesion.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_blackmagic.svg b/resources/themes/cura/icons/category_blackmagic.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_cool.svg b/resources/themes/cura/icons/category_cool.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_dual.svg b/resources/themes/cura/icons/category_dual.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_experimental.svg b/resources/themes/cura/icons/category_experimental.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_fixes.svg b/resources/themes/cura/icons/category_fixes.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_infill.svg b/resources/themes/cura/icons/category_infill.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_layer_height.svg b/resources/themes/cura/icons/category_layer_height.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_machine.svg b/resources/themes/cura/icons/category_machine.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_material.svg b/resources/themes/cura/icons/category_material.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_shell.svg b/resources/themes/cura/icons/category_shell.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_shield.svg b/resources/themes/cura/icons/category_shield.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_speed.svg b/resources/themes/cura/icons/category_speed.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_support.svg b/resources/themes/cura/icons/category_support.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_travel.svg b/resources/themes/cura/icons/category_travel.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/category_unknown.svg b/resources/themes/cura/icons/category_unknown.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/check.svg b/resources/themes/cura/icons/check.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/cross1.svg b/resources/themes/cura/icons/cross1.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/cross2.svg b/resources/themes/cura/icons/cross2.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/dense.svg b/resources/themes/cura/icons/dense.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/dot.svg b/resources/themes/cura/icons/dot.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/hollow.svg b/resources/themes/cura/icons/hollow.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/link.svg b/resources/themes/cura/icons/link.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/load.svg b/resources/themes/cura/icons/load.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/minus.svg b/resources/themes/cura/icons/minus.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/mirror.svg b/resources/themes/cura/icons/mirror.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/notice.svg b/resources/themes/cura/icons/notice.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/pencil.svg b/resources/themes/cura/icons/pencil.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/plugin.svg b/resources/themes/cura/icons/plugin.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/plus.svg b/resources/themes/cura/icons/plus.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/print_time.svg b/resources/themes/cura/icons/print_time.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/printsetup.svg b/resources/themes/cura/icons/printsetup.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/quick.svg b/resources/themes/cura/icons/quick.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/reset.svg b/resources/themes/cura/icons/reset.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/rotate.svg b/resources/themes/cura/icons/rotate.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/rotate_layflat.svg b/resources/themes/cura/icons/rotate_layflat.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/rotate_reset.svg b/resources/themes/cura/icons/rotate_reset.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/scale.svg b/resources/themes/cura/icons/scale.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/scale_max.svg b/resources/themes/cura/icons/scale_max.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/scale_reset.svg b/resources/themes/cura/icons/scale_reset.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/setting_per_object.svg b/resources/themes/cura/icons/setting_per_object.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/settings.svg b/resources/themes/cura/icons/settings.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/solid.svg b/resources/themes/cura/icons/solid.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/sparse.svg b/resources/themes/cura/icons/sparse.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/star.svg b/resources/themes/cura/icons/star.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_monitor.svg b/resources/themes/cura/icons/tab_monitor.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_monitor_busy.svg b/resources/themes/cura/icons/tab_monitor_busy.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_monitor_connected.svg b/resources/themes/cura/icons/tab_monitor_connected.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_monitor_offline.svg b/resources/themes/cura/icons/tab_monitor_offline.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_monitor_paused.svg b/resources/themes/cura/icons/tab_monitor_paused.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_monitor_stopped.svg b/resources/themes/cura/icons/tab_monitor_stopped.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_monitor_unknown.svg b/resources/themes/cura/icons/tab_monitor_unknown.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/tab_settings.svg b/resources/themes/cura/icons/tab_settings.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/translate.svg b/resources/themes/cura/icons/translate.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/ulti.svg b/resources/themes/cura/icons/ulti.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/view_layer.svg b/resources/themes/cura/icons/view_layer.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/view_normal.svg b/resources/themes/cura/icons/view_normal.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/view_xray.svg b/resources/themes/cura/icons/view_xray.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/viewmode.svg b/resources/themes/cura/icons/viewmode.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/icons/warning.svg b/resources/themes/cura/icons/warning.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/images/logo.svg b/resources/themes/cura/images/logo.svg old mode 100644 new mode 100755 diff --git a/resources/themes/cura/styles.qml b/resources/themes/cura/styles.qml old mode 100644 new mode 100755 diff --git a/resources/themes/cura/theme.json b/resources/themes/cura/theme.json old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_extended_plus_0.25.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.25.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_extended_plus_0.4.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.4.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_extended_plus_0.6.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.6.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_extended_plus_0.8.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.8.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_plus_0.25.inst.cfg b/resources/variants/ultimaker2_plus_0.25.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_plus_0.4.inst.cfg b/resources/variants/ultimaker2_plus_0.4.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_plus_0.6.inst.cfg b/resources/variants/ultimaker2_plus_0.6.inst.cfg old mode 100644 new mode 100755 diff --git a/resources/variants/ultimaker2_plus_0.8.inst.cfg b/resources/variants/ultimaker2_plus_0.8.inst.cfg old mode 100644 new mode 100755 diff --git a/setup.py b/setup.py old mode 100644 new mode 100755 diff --git a/tests/TestMachineAction.py b/tests/TestMachineAction.py old mode 100644 new mode 100755 From 8987aa20485120486fd5b0900106de31ea96e3e2 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 14 Oct 2016 19:09:44 +0600 Subject: [PATCH 14/68] T466: Revert the previous commit since it messed up the file rights. --- .gitignore | 0 CHANGES | 0 CMakeLists.txt | 0 CPackConfig.cmake | 0 LICENSE | 0 README.md | 0 build.sh | 0 cura.desktop.in | 0 cura.sharedmimeinfo | 0 cura/BuildVolume.py | 0 cura/CameraAnimation.py | 0 cura/CameraImageProvider.py | 0 cura/ConvexHullDecorator.py | 0 cura/ConvexHullNode.py | 0 cura/CrashHandler.py | 0 cura/CuraActions.py | 0 cura/CuraApplication.py | 0 cura/CuraSplashScreen.py | 0 cura/CuraVersion.py.in | 0 cura/Layer.py | 0 cura/LayerData.py | 0 cura/LayerDataBuilder.py | 0 cura/LayerDataDecorator.py | 0 cura/LayerPolygon.py | 0 cura/MachineAction.py | 0 cura/MachineActionManager.py | 0 cura/OneAtATimeIterator.py | 0 cura/PlatformPhysics.py | 0 cura/PlatformPhysicsOperation.py | 0 cura/PrintInformation.py | 0 cura/PrinterOutputDevice.py | 0 cura/ProfileReader.py | 0 cura/ProfileWriter.py | 0 cura/SetParentOperation.py | 0 cura/Settings/ContainerManager.py | 0 cura/Settings/ContainerSettingsModel.py | 0 cura/Settings/CuraContainerRegistry.py | 0 cura/Settings/ExtruderManager.py | 0 cura/Settings/ExtrudersModel.py | 0 cura/Settings/MachineManager.py | 0 cura/Settings/MaterialSettingsVisibilityHandler.py | 0 cura/Settings/QualitySettingsModel.py | 0 cura/Settings/SettingInheritanceManager.py | 0 cura/Settings/SettingOverrideDecorator.py | 0 cura/Settings/__init__.py | 0 cura/ZOffsetDecorator.py | 0 cura/__init__.py | 0 icons/cura-128.png | Bin icons/cura-32.png | Bin icons/cura-48.png | Bin icons/cura-64.png | Bin icons/cura.icns | Bin icons/cura.ico | Bin installer.nsi | 0 plugins/3MFReader/ThreeMFReader.py | 0 plugins/3MFReader/__init__.py | 0 plugins/AutoSave/AutoSave.py | 0 plugins/AutoSave/__init__.py | 0 plugins/ChangeLogPlugin/ChangeLog.py | 0 plugins/ChangeLogPlugin/ChangeLog.qml | 0 plugins/ChangeLogPlugin/ChangeLog.txt | 0 plugins/ChangeLogPlugin/__init__.py | 0 plugins/CuraEngineBackend/Cura.proto | 0 plugins/CuraEngineBackend/CuraEngineBackend.py | 0 plugins/CuraEngineBackend/ProcessGCodeJob.py | 0 plugins/CuraEngineBackend/ProcessSlicedLayersJob.py | 0 plugins/CuraEngineBackend/StartSliceJob.py | 0 plugins/CuraEngineBackend/__init__.py | 0 plugins/CuraProfileReader/CuraProfileReader.py | 0 plugins/CuraProfileReader/__init__.py | 0 plugins/CuraProfileWriter/CuraProfileWriter.py | 0 plugins/CuraProfileWriter/__init__.py | 0 plugins/GCODEReader/GCODEReader.py | 8 +------- plugins/GCODEReader/__init__.py | 0 plugins/GCodeProfileReader/GCodeProfileReader.py | 0 plugins/GCodeProfileReader/__init__.py | 0 plugins/GCodeWriter/GCodeWriter.py | 0 plugins/GCodeWriter/__init__.py | 0 plugins/ImageReader/ConfigUI.qml | 0 plugins/ImageReader/ImageReader.py | 0 plugins/ImageReader/ImageReaderUI.py | 0 plugins/ImageReader/__init__.py | 0 plugins/LayerView/LayerPass.py | 0 plugins/LayerView/LayerView.py | 0 plugins/LayerView/LayerView.qml | 0 plugins/LayerView/LayerViewProxy.py | 0 plugins/LayerView/__init__.py | 0 plugins/LayerView/layerview_composite.shader | 0 plugins/LegacyProfileReader/DictionaryOfDoom.json | 0 plugins/LegacyProfileReader/LegacyProfileReader.py | 0 plugins/LegacyProfileReader/__init__.py | 0 .../MachineSettingsAction/MachineSettingsAction.py | 0 .../MachineSettingsAction/MachineSettingsAction.qml | 0 plugins/MachineSettingsAction/__init__.py | 0 plugins/PerObjectSettingsTool/PerObjectCategory.qml | 0 plugins/PerObjectSettingsTool/PerObjectItem.qml | 0 .../PerObjectSettingVisibilityHandler.py | 0 .../PerObjectSettingsPanel.qml | 0 .../PerObjectSettingsTool/PerObjectSettingsTool.py | 0 plugins/PerObjectSettingsTool/__init__.py | 0 .../LinuxRemovableDrivePlugin.py | 0 .../OSXRemovableDrivePlugin.py | 0 .../RemovableDriveOutputDevice.py | 0 .../RemovableDrivePlugin.py | 0 .../WindowsRemovableDrivePlugin.py | 0 plugins/RemovableDriveOutputDevice/__init__.py | 0 plugins/SolidView/SolidView.py | 0 plugins/SolidView/__init__.py | 0 plugins/USBPrinting/FirmwareUpdateWindow.qml | 0 plugins/USBPrinting/USBPrinterOutputDevice.py | 0 .../USBPrinting/USBPrinterOutputDeviceManager.py | 0 plugins/USBPrinting/__init__.py | 0 plugins/USBPrinting/avr_isp/__init__.py | 0 plugins/USBPrinting/avr_isp/chipDB.py | 0 plugins/USBPrinting/avr_isp/intelHex.py | 0 plugins/USBPrinting/avr_isp/ispBase.py | 0 plugins/USBPrinting/avr_isp/stk500v2.py | 0 .../BedLevelMachineAction.py | 0 .../BedLevelMachineAction.qml | 0 .../UMOCheckupMachineAction.py | 0 .../UMOCheckupMachineAction.qml | 0 .../UltimakerMachineActions/UMOUpgradeSelection.py | 0 .../UMOUpgradeSelectionMachineAction.qml | 0 .../UpgradeFirmwareMachineAction.py | 0 .../UpgradeFirmwareMachineAction.qml | 0 plugins/UltimakerMachineActions/__init__.py | 0 .../VersionUpgrade21to22/MachineInstance.py | 0 .../VersionUpgrade21to22/Preferences.py | 0 .../VersionUpgrade/VersionUpgrade21to22/Profile.py | 0 .../VersionUpgrade21to22/VersionUpgrade21to22.py | 0 .../VersionUpgrade/VersionUpgrade21to22/__init__.py | 0 plugins/X3DReader/X3DReader.py | 0 plugins/X3DReader/__init__.py | 0 plugins/XRayView/XRayPass.py | 0 plugins/XRayView/XRayView.py | 0 plugins/XRayView/__init__.py | 0 plugins/XRayView/xray.shader | 0 plugins/XRayView/xray_composite.shader | 0 plugins/XmlMaterialProfile/XmlMaterialProfile.py | 0 plugins/XmlMaterialProfile/__init__.py | 0 pytest.ini | 0 resources/definitions/bq_hephestos.def.json | 0 resources/definitions/bq_hephestos_2.def.json | 0 resources/definitions/bq_hephestos_xl.def.json | 0 resources/definitions/bq_witbox.def.json | 0 resources/definitions/bq_witbox_2.def.json | 0 resources/definitions/custom.def.json | 0 resources/definitions/fdmextruder.def.json | 0 resources/definitions/fdmprinter.def.json | 0 resources/definitions/grr_neo.def.json | 0 resources/definitions/innovo_inventor.def.json | 0 resources/definitions/kossel_mini.def.json | 0 resources/definitions/m180.def.json | 0 resources/definitions/maker_starter.def.json | 0 .../definitions/mankati_fullscale_xt_plus.def.json | 0 resources/definitions/mendel90.def.json | 0 resources/definitions/printrbot_simple.def.json | 0 resources/definitions/prusa_i3.def.json | 0 resources/definitions/prusa_i3_mk2.def.json | 0 resources/definitions/prusa_i3_xl.def.json | 0 resources/definitions/rigidbot.def.json | 0 resources/definitions/rigidbot_big.def.json | 0 resources/definitions/ultimaker.def.json | 0 resources/definitions/ultimaker2.def.json | 0 resources/definitions/ultimaker2_extended.def.json | 0 .../definitions/ultimaker2_extended_plus.def.json | 0 resources/definitions/ultimaker2_go.def.json | 0 resources/definitions/ultimaker2_plus.def.json | 0 resources/definitions/ultimaker_original.def.json | 0 .../definitions/ultimaker_original_dual.def.json | 0 .../definitions/ultimaker_original_plus.def.json | 0 resources/definitions/uniqbot_one.def.json | 0 .../extruders/ultimaker_original_dual_1st.def.json | 0 .../extruders/ultimaker_original_dual_2nd.def.json | 0 resources/i18n/cura.pot | 0 resources/i18n/de/cura.po | 0 resources/i18n/en/cura.po | 0 resources/i18n/es/cura.po | 0 resources/i18n/fdmextruder.def.json.pot | 0 resources/i18n/fdmprinter.def.json.pot | 0 resources/i18n/fi/cura.po | 0 resources/i18n/fr/cura.po | 0 resources/i18n/it/cura.po | 0 resources/i18n/nl/cura.po | 0 resources/images/MakerStarterbackplate.png | Bin .../images/Ultimaker2ExtendedPlusbackplate.png | Bin resources/images/Ultimaker2Extendedbackplate.png | Bin resources/images/Ultimaker2Gobackplate.png | Bin resources/images/Ultimaker2Plusbackplate.png | Bin resources/images/Ultimaker2backplate.png | Bin resources/images/UltimakerPlusbackplate.png | Bin resources/images/cura-icon.png | Bin resources/images/cura.png | Bin resources/meshes/UltimakerRobot_support.stl | Bin resources/meshes/bq_hephestos_2_platform.stl | Bin resources/meshes/bq_hephestos_platform.stl | Bin resources/meshes/bq_witbox_platform.stl | Bin resources/meshes/grr_neo_platform.stl | Bin resources/meshes/inventor_platform.stl | Bin resources/meshes/kossel_platform.stl | 0 resources/meshes/makerstarter_platform.stl | Bin .../meshes/mankati_fullscale_xt_plus_platform.stl | Bin resources/meshes/mendel90_platform.stl | 0 .../meshes/printrbot_simple_metal_platform.stl | Bin resources/meshes/prusai3_platform.stl | 0 resources/meshes/prusai3_xl_platform.stl | 0 resources/meshes/rigidbot_platform.stl | Bin resources/meshes/rigidbotbig_platform.stl | Bin resources/meshes/ultimaker2_platform.obj | 0 resources/meshes/ultimaker2go_platform.obj | 0 resources/meshes/ultimaker_platform.stl | Bin resources/qml/AboutDialog.qml | 0 resources/qml/Actions.qml | 0 resources/qml/AddMachineDialog.qml | 0 resources/qml/Cura.qml | 0 resources/qml/EngineLog.qml | 0 resources/qml/JobSpecs.qml | 0 resources/qml/MachineAction.qml | 0 resources/qml/Menus/MaterialMenu.qml | 0 resources/qml/Menus/NozzleMenu.qml | 0 resources/qml/Menus/PrinterMenu.qml | 0 resources/qml/Menus/ProfileMenu.qml | 0 resources/qml/Menus/RecentFilesMenu.qml | 0 resources/qml/Menus/ViewMenu.qml | 0 resources/qml/MonitorButton.qml | 0 resources/qml/Preferences/GeneralPage.qml | 0 resources/qml/Preferences/MachinesPage.qml | 0 resources/qml/Preferences/MaterialView.qml | 0 resources/qml/Preferences/MaterialsPage.qml | 0 resources/qml/Preferences/ProfileTab.qml | 0 resources/qml/Preferences/ProfilesPage.qml | 0 resources/qml/Preferences/ReadOnlySpinBox.qml | 0 resources/qml/Preferences/ReadOnlyTextArea.qml | 0 resources/qml/Preferences/ReadOnlyTextField.qml | 0 resources/qml/Preferences/SettingVisibilityPage.qml | 0 resources/qml/PrintMonitor.qml | 0 resources/qml/SaveButton.qml | 0 resources/qml/Settings/SettingCategory.qml | 0 resources/qml/Settings/SettingCheckBox.qml | 0 resources/qml/Settings/SettingComboBox.qml | 0 resources/qml/Settings/SettingExtruder.qml | 0 resources/qml/Settings/SettingItem.qml | 0 resources/qml/Settings/SettingTextField.qml | 0 resources/qml/Settings/SettingUnknown.qml | 0 resources/qml/Settings/SettingView.qml | 0 resources/qml/Sidebar.qml | 0 resources/qml/SidebarAdvanced.qml | 0 resources/qml/SidebarContents.qml | 0 resources/qml/SidebarHeader.qml | 0 resources/qml/SidebarSimple.qml | 0 resources/qml/SidebarTooltip.qml | 0 resources/qml/Toolbar.qml | 0 resources/quality/high.inst.cfg | 0 resources/quality/low.inst.cfg | 0 resources/quality/normal.inst.cfg | 0 .../ultimaker2_plus/pla_0.25_normal.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.4_fast.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.4_high.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.4_normal.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.6_normal.inst.cfg | 0 .../quality/ultimaker2_plus/pla_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.4_high.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.25_high.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg | 0 .../ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg | 0 .../ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg | 0 .../ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg | 0 resources/shaders/grid.shader | 0 resources/shaders/overhang.shader | 0 resources/shaders/striped.shader | 0 resources/shaders/transparent_object.shader | 0 resources/themes/cura/fonts/LICENSE.txt | 0 resources/themes/cura/fonts/OpenSans-Bold.ttf | Bin resources/themes/cura/fonts/OpenSans-BoldItalic.ttf | Bin resources/themes/cura/fonts/OpenSans-Italic.ttf | Bin resources/themes/cura/fonts/OpenSans-Light.ttf | Bin .../themes/cura/fonts/OpenSans-LightItalic.ttf | Bin resources/themes/cura/fonts/OpenSans-Regular.ttf | Bin resources/themes/cura/fonts/OpenSans-Semibold.ttf | Bin .../themes/cura/fonts/OpenSans-SemiboldItalic.ttf | Bin resources/themes/cura/icons/application.svg | 0 resources/themes/cura/icons/arrow_bottom.svg | 0 resources/themes/cura/icons/arrow_left.svg | 0 resources/themes/cura/icons/arrow_right.svg | 0 resources/themes/cura/icons/arrow_top.svg | 0 resources/themes/cura/icons/basic.svg | 0 resources/themes/cura/icons/category_adhesion.svg | 0 resources/themes/cura/icons/category_blackmagic.svg | 0 resources/themes/cura/icons/category_cool.svg | 0 resources/themes/cura/icons/category_dual.svg | 0 .../themes/cura/icons/category_experimental.svg | 0 resources/themes/cura/icons/category_fixes.svg | 0 resources/themes/cura/icons/category_infill.svg | 0 .../themes/cura/icons/category_layer_height.svg | 0 resources/themes/cura/icons/category_machine.svg | 0 resources/themes/cura/icons/category_material.svg | 0 resources/themes/cura/icons/category_shell.svg | 0 resources/themes/cura/icons/category_shield.svg | 0 resources/themes/cura/icons/category_speed.svg | 0 resources/themes/cura/icons/category_support.svg | 0 resources/themes/cura/icons/category_travel.svg | 0 resources/themes/cura/icons/category_unknown.svg | 0 resources/themes/cura/icons/check.svg | 0 resources/themes/cura/icons/cross1.svg | 0 resources/themes/cura/icons/cross2.svg | 0 resources/themes/cura/icons/dense.svg | 0 resources/themes/cura/icons/dot.svg | 0 resources/themes/cura/icons/hollow.svg | 0 resources/themes/cura/icons/link.svg | 0 resources/themes/cura/icons/load.svg | 0 resources/themes/cura/icons/minus.svg | 0 resources/themes/cura/icons/mirror.svg | 0 resources/themes/cura/icons/notice.svg | 0 resources/themes/cura/icons/pencil.svg | 0 resources/themes/cura/icons/plugin.svg | 0 resources/themes/cura/icons/plus.svg | 0 resources/themes/cura/icons/print_time.svg | 0 resources/themes/cura/icons/printsetup.svg | 0 resources/themes/cura/icons/quick.svg | 0 resources/themes/cura/icons/reset.svg | 0 resources/themes/cura/icons/rotate.svg | 0 resources/themes/cura/icons/rotate_layflat.svg | 0 resources/themes/cura/icons/rotate_reset.svg | 0 resources/themes/cura/icons/scale.svg | 0 resources/themes/cura/icons/scale_max.svg | 0 resources/themes/cura/icons/scale_reset.svg | 0 resources/themes/cura/icons/setting_per_object.svg | 0 resources/themes/cura/icons/settings.svg | 0 resources/themes/cura/icons/solid.svg | 0 resources/themes/cura/icons/sparse.svg | 0 resources/themes/cura/icons/star.svg | 0 resources/themes/cura/icons/tab_monitor.svg | 0 resources/themes/cura/icons/tab_monitor_busy.svg | 0 .../themes/cura/icons/tab_monitor_connected.svg | 0 resources/themes/cura/icons/tab_monitor_offline.svg | 0 resources/themes/cura/icons/tab_monitor_paused.svg | 0 resources/themes/cura/icons/tab_monitor_stopped.svg | 0 resources/themes/cura/icons/tab_monitor_unknown.svg | 0 resources/themes/cura/icons/tab_settings.svg | 0 resources/themes/cura/icons/translate.svg | 0 resources/themes/cura/icons/ulti.svg | 0 resources/themes/cura/icons/view_layer.svg | 0 resources/themes/cura/icons/view_normal.svg | 0 resources/themes/cura/icons/view_xray.svg | 0 resources/themes/cura/icons/viewmode.svg | 0 resources/themes/cura/icons/warning.svg | 0 resources/themes/cura/images/logo.svg | 0 resources/themes/cura/styles.qml | 0 resources/themes/cura/theme.json | 0 .../variants/ultimaker2_extended_plus_0.25.inst.cfg | 0 .../variants/ultimaker2_extended_plus_0.4.inst.cfg | 0 .../variants/ultimaker2_extended_plus_0.6.inst.cfg | 0 .../variants/ultimaker2_extended_plus_0.8.inst.cfg | 0 resources/variants/ultimaker2_plus_0.25.inst.cfg | 0 resources/variants/ultimaker2_plus_0.4.inst.cfg | 0 resources/variants/ultimaker2_plus_0.6.inst.cfg | 0 resources/variants/ultimaker2_plus_0.8.inst.cfg | 0 setup.py | 0 tests/TestMachineAction.py | 0 390 files changed, 1 insertion(+), 7 deletions(-) mode change 100755 => 100644 .gitignore mode change 100755 => 100644 CHANGES mode change 100755 => 100644 CMakeLists.txt mode change 100755 => 100644 CPackConfig.cmake mode change 100755 => 100644 LICENSE mode change 100755 => 100644 README.md mode change 100755 => 100644 build.sh mode change 100755 => 100644 cura.desktop.in mode change 100755 => 100644 cura.sharedmimeinfo mode change 100755 => 100644 cura/BuildVolume.py mode change 100755 => 100644 cura/CameraAnimation.py mode change 100755 => 100644 cura/CameraImageProvider.py mode change 100755 => 100644 cura/ConvexHullDecorator.py mode change 100755 => 100644 cura/ConvexHullNode.py mode change 100755 => 100644 cura/CrashHandler.py mode change 100755 => 100644 cura/CuraActions.py mode change 100755 => 100644 cura/CuraApplication.py mode change 100755 => 100644 cura/CuraSplashScreen.py mode change 100755 => 100644 cura/CuraVersion.py.in mode change 100755 => 100644 cura/Layer.py mode change 100755 => 100644 cura/LayerData.py mode change 100755 => 100644 cura/LayerDataBuilder.py mode change 100755 => 100644 cura/LayerDataDecorator.py mode change 100755 => 100644 cura/LayerPolygon.py mode change 100755 => 100644 cura/MachineAction.py mode change 100755 => 100644 cura/MachineActionManager.py mode change 100755 => 100644 cura/OneAtATimeIterator.py mode change 100755 => 100644 cura/PlatformPhysics.py mode change 100755 => 100644 cura/PlatformPhysicsOperation.py mode change 100755 => 100644 cura/PrintInformation.py mode change 100755 => 100644 cura/PrinterOutputDevice.py mode change 100755 => 100644 cura/ProfileReader.py mode change 100755 => 100644 cura/ProfileWriter.py mode change 100755 => 100644 cura/SetParentOperation.py mode change 100755 => 100644 cura/Settings/ContainerManager.py mode change 100755 => 100644 cura/Settings/ContainerSettingsModel.py mode change 100755 => 100644 cura/Settings/CuraContainerRegistry.py mode change 100755 => 100644 cura/Settings/ExtruderManager.py mode change 100755 => 100644 cura/Settings/ExtrudersModel.py mode change 100755 => 100644 cura/Settings/MachineManager.py mode change 100755 => 100644 cura/Settings/MaterialSettingsVisibilityHandler.py mode change 100755 => 100644 cura/Settings/QualitySettingsModel.py mode change 100755 => 100644 cura/Settings/SettingInheritanceManager.py mode change 100755 => 100644 cura/Settings/SettingOverrideDecorator.py mode change 100755 => 100644 cura/Settings/__init__.py mode change 100755 => 100644 cura/ZOffsetDecorator.py mode change 100755 => 100644 cura/__init__.py mode change 100755 => 100644 icons/cura-128.png mode change 100755 => 100644 icons/cura-32.png mode change 100755 => 100644 icons/cura-48.png mode change 100755 => 100644 icons/cura-64.png mode change 100755 => 100644 icons/cura.icns mode change 100755 => 100644 icons/cura.ico mode change 100755 => 100644 installer.nsi mode change 100755 => 100644 plugins/3MFReader/ThreeMFReader.py mode change 100755 => 100644 plugins/3MFReader/__init__.py mode change 100755 => 100644 plugins/AutoSave/AutoSave.py mode change 100755 => 100644 plugins/AutoSave/__init__.py mode change 100755 => 100644 plugins/ChangeLogPlugin/ChangeLog.py mode change 100755 => 100644 plugins/ChangeLogPlugin/ChangeLog.qml mode change 100755 => 100644 plugins/ChangeLogPlugin/ChangeLog.txt mode change 100755 => 100644 plugins/ChangeLogPlugin/__init__.py mode change 100755 => 100644 plugins/CuraEngineBackend/Cura.proto mode change 100755 => 100644 plugins/CuraEngineBackend/CuraEngineBackend.py mode change 100755 => 100644 plugins/CuraEngineBackend/ProcessGCodeJob.py mode change 100755 => 100644 plugins/CuraEngineBackend/ProcessSlicedLayersJob.py mode change 100755 => 100644 plugins/CuraEngineBackend/StartSliceJob.py mode change 100755 => 100644 plugins/CuraEngineBackend/__init__.py mode change 100755 => 100644 plugins/CuraProfileReader/CuraProfileReader.py mode change 100755 => 100644 plugins/CuraProfileReader/__init__.py mode change 100755 => 100644 plugins/CuraProfileWriter/CuraProfileWriter.py mode change 100755 => 100644 plugins/CuraProfileWriter/__init__.py mode change 100755 => 100644 plugins/GCODEReader/GCODEReader.py mode change 100755 => 100644 plugins/GCODEReader/__init__.py mode change 100755 => 100644 plugins/GCodeProfileReader/GCodeProfileReader.py mode change 100755 => 100644 plugins/GCodeProfileReader/__init__.py mode change 100755 => 100644 plugins/GCodeWriter/GCodeWriter.py mode change 100755 => 100644 plugins/GCodeWriter/__init__.py mode change 100755 => 100644 plugins/ImageReader/ConfigUI.qml mode change 100755 => 100644 plugins/ImageReader/ImageReader.py mode change 100755 => 100644 plugins/ImageReader/ImageReaderUI.py mode change 100755 => 100644 plugins/ImageReader/__init__.py mode change 100755 => 100644 plugins/LayerView/LayerPass.py mode change 100755 => 100644 plugins/LayerView/LayerView.py mode change 100755 => 100644 plugins/LayerView/LayerView.qml mode change 100755 => 100644 plugins/LayerView/LayerViewProxy.py mode change 100755 => 100644 plugins/LayerView/__init__.py mode change 100755 => 100644 plugins/LayerView/layerview_composite.shader mode change 100755 => 100644 plugins/LegacyProfileReader/DictionaryOfDoom.json mode change 100755 => 100644 plugins/LegacyProfileReader/LegacyProfileReader.py mode change 100755 => 100644 plugins/LegacyProfileReader/__init__.py mode change 100755 => 100644 plugins/MachineSettingsAction/MachineSettingsAction.py mode change 100755 => 100644 plugins/MachineSettingsAction/MachineSettingsAction.qml mode change 100755 => 100644 plugins/MachineSettingsAction/__init__.py mode change 100755 => 100644 plugins/PerObjectSettingsTool/PerObjectCategory.qml mode change 100755 => 100644 plugins/PerObjectSettingsTool/PerObjectItem.qml mode change 100755 => 100644 plugins/PerObjectSettingsTool/PerObjectSettingVisibilityHandler.py mode change 100755 => 100644 plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml mode change 100755 => 100644 plugins/PerObjectSettingsTool/PerObjectSettingsTool.py mode change 100755 => 100644 plugins/PerObjectSettingsTool/__init__.py mode change 100755 => 100644 plugins/RemovableDriveOutputDevice/LinuxRemovableDrivePlugin.py mode change 100755 => 100644 plugins/RemovableDriveOutputDevice/OSXRemovableDrivePlugin.py mode change 100755 => 100644 plugins/RemovableDriveOutputDevice/RemovableDriveOutputDevice.py mode change 100755 => 100644 plugins/RemovableDriveOutputDevice/RemovableDrivePlugin.py mode change 100755 => 100644 plugins/RemovableDriveOutputDevice/WindowsRemovableDrivePlugin.py mode change 100755 => 100644 plugins/RemovableDriveOutputDevice/__init__.py mode change 100755 => 100644 plugins/SolidView/SolidView.py mode change 100755 => 100644 plugins/SolidView/__init__.py mode change 100755 => 100644 plugins/USBPrinting/FirmwareUpdateWindow.qml mode change 100755 => 100644 plugins/USBPrinting/USBPrinterOutputDevice.py mode change 100755 => 100644 plugins/USBPrinting/USBPrinterOutputDeviceManager.py mode change 100755 => 100644 plugins/USBPrinting/__init__.py mode change 100755 => 100644 plugins/USBPrinting/avr_isp/__init__.py mode change 100755 => 100644 plugins/USBPrinting/avr_isp/chipDB.py mode change 100755 => 100644 plugins/USBPrinting/avr_isp/intelHex.py mode change 100755 => 100644 plugins/USBPrinting/avr_isp/ispBase.py mode change 100755 => 100644 plugins/USBPrinting/avr_isp/stk500v2.py mode change 100755 => 100644 plugins/UltimakerMachineActions/BedLevelMachineAction.py mode change 100755 => 100644 plugins/UltimakerMachineActions/BedLevelMachineAction.qml mode change 100755 => 100644 plugins/UltimakerMachineActions/UMOCheckupMachineAction.py mode change 100755 => 100644 plugins/UltimakerMachineActions/UMOCheckupMachineAction.qml mode change 100755 => 100644 plugins/UltimakerMachineActions/UMOUpgradeSelection.py mode change 100755 => 100644 plugins/UltimakerMachineActions/UMOUpgradeSelectionMachineAction.qml mode change 100755 => 100644 plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.py mode change 100755 => 100644 plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.qml mode change 100755 => 100644 plugins/UltimakerMachineActions/__init__.py mode change 100755 => 100644 plugins/VersionUpgrade/VersionUpgrade21to22/MachineInstance.py mode change 100755 => 100644 plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py mode change 100755 => 100644 plugins/VersionUpgrade/VersionUpgrade21to22/Profile.py mode change 100755 => 100644 plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py mode change 100755 => 100644 plugins/VersionUpgrade/VersionUpgrade21to22/__init__.py mode change 100755 => 100644 plugins/X3DReader/X3DReader.py mode change 100755 => 100644 plugins/X3DReader/__init__.py mode change 100755 => 100644 plugins/XRayView/XRayPass.py mode change 100755 => 100644 plugins/XRayView/XRayView.py mode change 100755 => 100644 plugins/XRayView/__init__.py mode change 100755 => 100644 plugins/XRayView/xray.shader mode change 100755 => 100644 plugins/XRayView/xray_composite.shader mode change 100755 => 100644 plugins/XmlMaterialProfile/XmlMaterialProfile.py mode change 100755 => 100644 plugins/XmlMaterialProfile/__init__.py mode change 100755 => 100644 pytest.ini mode change 100755 => 100644 resources/definitions/bq_hephestos.def.json mode change 100755 => 100644 resources/definitions/bq_hephestos_2.def.json mode change 100755 => 100644 resources/definitions/bq_hephestos_xl.def.json mode change 100755 => 100644 resources/definitions/bq_witbox.def.json mode change 100755 => 100644 resources/definitions/bq_witbox_2.def.json mode change 100755 => 100644 resources/definitions/custom.def.json mode change 100755 => 100644 resources/definitions/fdmextruder.def.json mode change 100755 => 100644 resources/definitions/fdmprinter.def.json mode change 100755 => 100644 resources/definitions/grr_neo.def.json mode change 100755 => 100644 resources/definitions/innovo_inventor.def.json mode change 100755 => 100644 resources/definitions/kossel_mini.def.json mode change 100755 => 100644 resources/definitions/m180.def.json mode change 100755 => 100644 resources/definitions/maker_starter.def.json mode change 100755 => 100644 resources/definitions/mankati_fullscale_xt_plus.def.json mode change 100755 => 100644 resources/definitions/mendel90.def.json mode change 100755 => 100644 resources/definitions/printrbot_simple.def.json mode change 100755 => 100644 resources/definitions/prusa_i3.def.json mode change 100755 => 100644 resources/definitions/prusa_i3_mk2.def.json mode change 100755 => 100644 resources/definitions/prusa_i3_xl.def.json mode change 100755 => 100644 resources/definitions/rigidbot.def.json mode change 100755 => 100644 resources/definitions/rigidbot_big.def.json mode change 100755 => 100644 resources/definitions/ultimaker.def.json mode change 100755 => 100644 resources/definitions/ultimaker2.def.json mode change 100755 => 100644 resources/definitions/ultimaker2_extended.def.json mode change 100755 => 100644 resources/definitions/ultimaker2_extended_plus.def.json mode change 100755 => 100644 resources/definitions/ultimaker2_go.def.json mode change 100755 => 100644 resources/definitions/ultimaker2_plus.def.json mode change 100755 => 100644 resources/definitions/ultimaker_original.def.json mode change 100755 => 100644 resources/definitions/ultimaker_original_dual.def.json mode change 100755 => 100644 resources/definitions/ultimaker_original_plus.def.json mode change 100755 => 100644 resources/definitions/uniqbot_one.def.json mode change 100755 => 100644 resources/extruders/ultimaker_original_dual_1st.def.json mode change 100755 => 100644 resources/extruders/ultimaker_original_dual_2nd.def.json mode change 100755 => 100644 resources/i18n/cura.pot mode change 100755 => 100644 resources/i18n/de/cura.po mode change 100755 => 100644 resources/i18n/en/cura.po mode change 100755 => 100644 resources/i18n/es/cura.po mode change 100755 => 100644 resources/i18n/fdmextruder.def.json.pot mode change 100755 => 100644 resources/i18n/fdmprinter.def.json.pot mode change 100755 => 100644 resources/i18n/fi/cura.po mode change 100755 => 100644 resources/i18n/fr/cura.po mode change 100755 => 100644 resources/i18n/it/cura.po mode change 100755 => 100644 resources/i18n/nl/cura.po mode change 100755 => 100644 resources/images/MakerStarterbackplate.png mode change 100755 => 100644 resources/images/Ultimaker2ExtendedPlusbackplate.png mode change 100755 => 100644 resources/images/Ultimaker2Extendedbackplate.png mode change 100755 => 100644 resources/images/Ultimaker2Gobackplate.png mode change 100755 => 100644 resources/images/Ultimaker2Plusbackplate.png mode change 100755 => 100644 resources/images/Ultimaker2backplate.png mode change 100755 => 100644 resources/images/UltimakerPlusbackplate.png mode change 100755 => 100644 resources/images/cura-icon.png mode change 100755 => 100644 resources/images/cura.png mode change 100755 => 100644 resources/meshes/UltimakerRobot_support.stl mode change 100755 => 100644 resources/meshes/bq_hephestos_2_platform.stl mode change 100755 => 100644 resources/meshes/bq_hephestos_platform.stl mode change 100755 => 100644 resources/meshes/bq_witbox_platform.stl mode change 100755 => 100644 resources/meshes/grr_neo_platform.stl mode change 100755 => 100644 resources/meshes/inventor_platform.stl mode change 100755 => 100644 resources/meshes/kossel_platform.stl mode change 100755 => 100644 resources/meshes/makerstarter_platform.stl mode change 100755 => 100644 resources/meshes/mankati_fullscale_xt_plus_platform.stl mode change 100755 => 100644 resources/meshes/mendel90_platform.stl mode change 100755 => 100644 resources/meshes/printrbot_simple_metal_platform.stl mode change 100755 => 100644 resources/meshes/prusai3_platform.stl mode change 100755 => 100644 resources/meshes/prusai3_xl_platform.stl mode change 100755 => 100644 resources/meshes/rigidbot_platform.stl mode change 100755 => 100644 resources/meshes/rigidbotbig_platform.stl mode change 100755 => 100644 resources/meshes/ultimaker2_platform.obj mode change 100755 => 100644 resources/meshes/ultimaker2go_platform.obj mode change 100755 => 100644 resources/meshes/ultimaker_platform.stl mode change 100755 => 100644 resources/qml/AboutDialog.qml mode change 100755 => 100644 resources/qml/Actions.qml mode change 100755 => 100644 resources/qml/AddMachineDialog.qml mode change 100755 => 100644 resources/qml/Cura.qml mode change 100755 => 100644 resources/qml/EngineLog.qml mode change 100755 => 100644 resources/qml/JobSpecs.qml mode change 100755 => 100644 resources/qml/MachineAction.qml mode change 100755 => 100644 resources/qml/Menus/MaterialMenu.qml mode change 100755 => 100644 resources/qml/Menus/NozzleMenu.qml mode change 100755 => 100644 resources/qml/Menus/PrinterMenu.qml mode change 100755 => 100644 resources/qml/Menus/ProfileMenu.qml mode change 100755 => 100644 resources/qml/Menus/RecentFilesMenu.qml mode change 100755 => 100644 resources/qml/Menus/ViewMenu.qml mode change 100755 => 100644 resources/qml/MonitorButton.qml mode change 100755 => 100644 resources/qml/Preferences/GeneralPage.qml mode change 100755 => 100644 resources/qml/Preferences/MachinesPage.qml mode change 100755 => 100644 resources/qml/Preferences/MaterialView.qml mode change 100755 => 100644 resources/qml/Preferences/MaterialsPage.qml mode change 100755 => 100644 resources/qml/Preferences/ProfileTab.qml mode change 100755 => 100644 resources/qml/Preferences/ProfilesPage.qml mode change 100755 => 100644 resources/qml/Preferences/ReadOnlySpinBox.qml mode change 100755 => 100644 resources/qml/Preferences/ReadOnlyTextArea.qml mode change 100755 => 100644 resources/qml/Preferences/ReadOnlyTextField.qml mode change 100755 => 100644 resources/qml/Preferences/SettingVisibilityPage.qml mode change 100755 => 100644 resources/qml/PrintMonitor.qml mode change 100755 => 100644 resources/qml/SaveButton.qml mode change 100755 => 100644 resources/qml/Settings/SettingCategory.qml mode change 100755 => 100644 resources/qml/Settings/SettingCheckBox.qml mode change 100755 => 100644 resources/qml/Settings/SettingComboBox.qml mode change 100755 => 100644 resources/qml/Settings/SettingExtruder.qml mode change 100755 => 100644 resources/qml/Settings/SettingItem.qml mode change 100755 => 100644 resources/qml/Settings/SettingTextField.qml mode change 100755 => 100644 resources/qml/Settings/SettingUnknown.qml mode change 100755 => 100644 resources/qml/Settings/SettingView.qml mode change 100755 => 100644 resources/qml/Sidebar.qml mode change 100755 => 100644 resources/qml/SidebarAdvanced.qml mode change 100755 => 100644 resources/qml/SidebarContents.qml mode change 100755 => 100644 resources/qml/SidebarHeader.qml mode change 100755 => 100644 resources/qml/SidebarSimple.qml mode change 100755 => 100644 resources/qml/SidebarTooltip.qml mode change 100755 => 100644 resources/qml/Toolbar.qml mode change 100755 => 100644 resources/quality/high.inst.cfg mode change 100755 => 100644 resources/quality/low.inst.cfg mode change 100755 => 100644 resources/quality/normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/pla_0.25_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/pla_0.4_fast.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/pla_0.4_high.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/pla_0.4_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/pla_0.6_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/pla_0.8_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_abs_0.4_high.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.25_high.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg mode change 100755 => 100644 resources/quality/ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg mode change 100755 => 100644 resources/shaders/grid.shader mode change 100755 => 100644 resources/shaders/overhang.shader mode change 100755 => 100644 resources/shaders/striped.shader mode change 100755 => 100644 resources/shaders/transparent_object.shader mode change 100755 => 100644 resources/themes/cura/fonts/LICENSE.txt mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-Bold.ttf mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-BoldItalic.ttf mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-Italic.ttf mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-Light.ttf mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-LightItalic.ttf mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-Regular.ttf mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-Semibold.ttf mode change 100755 => 100644 resources/themes/cura/fonts/OpenSans-SemiboldItalic.ttf mode change 100755 => 100644 resources/themes/cura/icons/application.svg mode change 100755 => 100644 resources/themes/cura/icons/arrow_bottom.svg mode change 100755 => 100644 resources/themes/cura/icons/arrow_left.svg mode change 100755 => 100644 resources/themes/cura/icons/arrow_right.svg mode change 100755 => 100644 resources/themes/cura/icons/arrow_top.svg mode change 100755 => 100644 resources/themes/cura/icons/basic.svg mode change 100755 => 100644 resources/themes/cura/icons/category_adhesion.svg mode change 100755 => 100644 resources/themes/cura/icons/category_blackmagic.svg mode change 100755 => 100644 resources/themes/cura/icons/category_cool.svg mode change 100755 => 100644 resources/themes/cura/icons/category_dual.svg mode change 100755 => 100644 resources/themes/cura/icons/category_experimental.svg mode change 100755 => 100644 resources/themes/cura/icons/category_fixes.svg mode change 100755 => 100644 resources/themes/cura/icons/category_infill.svg mode change 100755 => 100644 resources/themes/cura/icons/category_layer_height.svg mode change 100755 => 100644 resources/themes/cura/icons/category_machine.svg mode change 100755 => 100644 resources/themes/cura/icons/category_material.svg mode change 100755 => 100644 resources/themes/cura/icons/category_shell.svg mode change 100755 => 100644 resources/themes/cura/icons/category_shield.svg mode change 100755 => 100644 resources/themes/cura/icons/category_speed.svg mode change 100755 => 100644 resources/themes/cura/icons/category_support.svg mode change 100755 => 100644 resources/themes/cura/icons/category_travel.svg mode change 100755 => 100644 resources/themes/cura/icons/category_unknown.svg mode change 100755 => 100644 resources/themes/cura/icons/check.svg mode change 100755 => 100644 resources/themes/cura/icons/cross1.svg mode change 100755 => 100644 resources/themes/cura/icons/cross2.svg mode change 100755 => 100644 resources/themes/cura/icons/dense.svg mode change 100755 => 100644 resources/themes/cura/icons/dot.svg mode change 100755 => 100644 resources/themes/cura/icons/hollow.svg mode change 100755 => 100644 resources/themes/cura/icons/link.svg mode change 100755 => 100644 resources/themes/cura/icons/load.svg mode change 100755 => 100644 resources/themes/cura/icons/minus.svg mode change 100755 => 100644 resources/themes/cura/icons/mirror.svg mode change 100755 => 100644 resources/themes/cura/icons/notice.svg mode change 100755 => 100644 resources/themes/cura/icons/pencil.svg mode change 100755 => 100644 resources/themes/cura/icons/plugin.svg mode change 100755 => 100644 resources/themes/cura/icons/plus.svg mode change 100755 => 100644 resources/themes/cura/icons/print_time.svg mode change 100755 => 100644 resources/themes/cura/icons/printsetup.svg mode change 100755 => 100644 resources/themes/cura/icons/quick.svg mode change 100755 => 100644 resources/themes/cura/icons/reset.svg mode change 100755 => 100644 resources/themes/cura/icons/rotate.svg mode change 100755 => 100644 resources/themes/cura/icons/rotate_layflat.svg mode change 100755 => 100644 resources/themes/cura/icons/rotate_reset.svg mode change 100755 => 100644 resources/themes/cura/icons/scale.svg mode change 100755 => 100644 resources/themes/cura/icons/scale_max.svg mode change 100755 => 100644 resources/themes/cura/icons/scale_reset.svg mode change 100755 => 100644 resources/themes/cura/icons/setting_per_object.svg mode change 100755 => 100644 resources/themes/cura/icons/settings.svg mode change 100755 => 100644 resources/themes/cura/icons/solid.svg mode change 100755 => 100644 resources/themes/cura/icons/sparse.svg mode change 100755 => 100644 resources/themes/cura/icons/star.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_monitor.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_monitor_busy.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_monitor_connected.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_monitor_offline.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_monitor_paused.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_monitor_stopped.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_monitor_unknown.svg mode change 100755 => 100644 resources/themes/cura/icons/tab_settings.svg mode change 100755 => 100644 resources/themes/cura/icons/translate.svg mode change 100755 => 100644 resources/themes/cura/icons/ulti.svg mode change 100755 => 100644 resources/themes/cura/icons/view_layer.svg mode change 100755 => 100644 resources/themes/cura/icons/view_normal.svg mode change 100755 => 100644 resources/themes/cura/icons/view_xray.svg mode change 100755 => 100644 resources/themes/cura/icons/viewmode.svg mode change 100755 => 100644 resources/themes/cura/icons/warning.svg mode change 100755 => 100644 resources/themes/cura/images/logo.svg mode change 100755 => 100644 resources/themes/cura/styles.qml mode change 100755 => 100644 resources/themes/cura/theme.json mode change 100755 => 100644 resources/variants/ultimaker2_extended_plus_0.25.inst.cfg mode change 100755 => 100644 resources/variants/ultimaker2_extended_plus_0.4.inst.cfg mode change 100755 => 100644 resources/variants/ultimaker2_extended_plus_0.6.inst.cfg mode change 100755 => 100644 resources/variants/ultimaker2_extended_plus_0.8.inst.cfg mode change 100755 => 100644 resources/variants/ultimaker2_plus_0.25.inst.cfg mode change 100755 => 100644 resources/variants/ultimaker2_plus_0.4.inst.cfg mode change 100755 => 100644 resources/variants/ultimaker2_plus_0.6.inst.cfg mode change 100755 => 100644 resources/variants/ultimaker2_plus_0.8.inst.cfg mode change 100755 => 100644 setup.py mode change 100755 => 100644 tests/TestMachineAction.py diff --git a/.gitignore b/.gitignore old mode 100755 new mode 100644 diff --git a/CHANGES b/CHANGES old mode 100755 new mode 100644 diff --git a/CMakeLists.txt b/CMakeLists.txt old mode 100755 new mode 100644 diff --git a/CPackConfig.cmake b/CPackConfig.cmake old mode 100755 new mode 100644 diff --git a/LICENSE b/LICENSE old mode 100755 new mode 100644 diff --git a/README.md b/README.md old mode 100755 new mode 100644 diff --git a/build.sh b/build.sh old mode 100755 new mode 100644 diff --git a/cura.desktop.in b/cura.desktop.in old mode 100755 new mode 100644 diff --git a/cura.sharedmimeinfo b/cura.sharedmimeinfo old mode 100755 new mode 100644 diff --git a/cura/BuildVolume.py b/cura/BuildVolume.py old mode 100755 new mode 100644 diff --git a/cura/CameraAnimation.py b/cura/CameraAnimation.py old mode 100755 new mode 100644 diff --git a/cura/CameraImageProvider.py b/cura/CameraImageProvider.py old mode 100755 new mode 100644 diff --git a/cura/ConvexHullDecorator.py b/cura/ConvexHullDecorator.py old mode 100755 new mode 100644 diff --git a/cura/ConvexHullNode.py b/cura/ConvexHullNode.py old mode 100755 new mode 100644 diff --git a/cura/CrashHandler.py b/cura/CrashHandler.py old mode 100755 new mode 100644 diff --git a/cura/CuraActions.py b/cura/CuraActions.py old mode 100755 new mode 100644 diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py old mode 100755 new mode 100644 diff --git a/cura/CuraSplashScreen.py b/cura/CuraSplashScreen.py old mode 100755 new mode 100644 diff --git a/cura/CuraVersion.py.in b/cura/CuraVersion.py.in old mode 100755 new mode 100644 diff --git a/cura/Layer.py b/cura/Layer.py old mode 100755 new mode 100644 diff --git a/cura/LayerData.py b/cura/LayerData.py old mode 100755 new mode 100644 diff --git a/cura/LayerDataBuilder.py b/cura/LayerDataBuilder.py old mode 100755 new mode 100644 diff --git a/cura/LayerDataDecorator.py b/cura/LayerDataDecorator.py old mode 100755 new mode 100644 diff --git a/cura/LayerPolygon.py b/cura/LayerPolygon.py old mode 100755 new mode 100644 diff --git a/cura/MachineAction.py b/cura/MachineAction.py old mode 100755 new mode 100644 diff --git a/cura/MachineActionManager.py b/cura/MachineActionManager.py old mode 100755 new mode 100644 diff --git a/cura/OneAtATimeIterator.py b/cura/OneAtATimeIterator.py old mode 100755 new mode 100644 diff --git a/cura/PlatformPhysics.py b/cura/PlatformPhysics.py old mode 100755 new mode 100644 diff --git a/cura/PlatformPhysicsOperation.py b/cura/PlatformPhysicsOperation.py old mode 100755 new mode 100644 diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py old mode 100755 new mode 100644 diff --git a/cura/PrinterOutputDevice.py b/cura/PrinterOutputDevice.py old mode 100755 new mode 100644 diff --git a/cura/ProfileReader.py b/cura/ProfileReader.py old mode 100755 new mode 100644 diff --git a/cura/ProfileWriter.py b/cura/ProfileWriter.py old mode 100755 new mode 100644 diff --git a/cura/SetParentOperation.py b/cura/SetParentOperation.py old mode 100755 new mode 100644 diff --git a/cura/Settings/ContainerManager.py b/cura/Settings/ContainerManager.py old mode 100755 new mode 100644 diff --git a/cura/Settings/ContainerSettingsModel.py b/cura/Settings/ContainerSettingsModel.py old mode 100755 new mode 100644 diff --git a/cura/Settings/CuraContainerRegistry.py b/cura/Settings/CuraContainerRegistry.py old mode 100755 new mode 100644 diff --git a/cura/Settings/ExtruderManager.py b/cura/Settings/ExtruderManager.py old mode 100755 new mode 100644 diff --git a/cura/Settings/ExtrudersModel.py b/cura/Settings/ExtrudersModel.py old mode 100755 new mode 100644 diff --git a/cura/Settings/MachineManager.py b/cura/Settings/MachineManager.py old mode 100755 new mode 100644 diff --git a/cura/Settings/MaterialSettingsVisibilityHandler.py b/cura/Settings/MaterialSettingsVisibilityHandler.py old mode 100755 new mode 100644 diff --git a/cura/Settings/QualitySettingsModel.py b/cura/Settings/QualitySettingsModel.py old mode 100755 new mode 100644 diff --git a/cura/Settings/SettingInheritanceManager.py b/cura/Settings/SettingInheritanceManager.py old mode 100755 new mode 100644 diff --git a/cura/Settings/SettingOverrideDecorator.py b/cura/Settings/SettingOverrideDecorator.py old mode 100755 new mode 100644 diff --git a/cura/Settings/__init__.py b/cura/Settings/__init__.py old mode 100755 new mode 100644 diff --git a/cura/ZOffsetDecorator.py b/cura/ZOffsetDecorator.py old mode 100755 new mode 100644 diff --git a/cura/__init__.py b/cura/__init__.py old mode 100755 new mode 100644 diff --git a/icons/cura-128.png b/icons/cura-128.png old mode 100755 new mode 100644 diff --git a/icons/cura-32.png b/icons/cura-32.png old mode 100755 new mode 100644 diff --git a/icons/cura-48.png b/icons/cura-48.png old mode 100755 new mode 100644 diff --git a/icons/cura-64.png b/icons/cura-64.png old mode 100755 new mode 100644 diff --git a/icons/cura.icns b/icons/cura.icns old mode 100755 new mode 100644 diff --git a/icons/cura.ico b/icons/cura.ico old mode 100755 new mode 100644 diff --git a/installer.nsi b/installer.nsi old mode 100755 new mode 100644 diff --git a/plugins/3MFReader/ThreeMFReader.py b/plugins/3MFReader/ThreeMFReader.py old mode 100755 new mode 100644 diff --git a/plugins/3MFReader/__init__.py b/plugins/3MFReader/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/AutoSave/AutoSave.py b/plugins/AutoSave/AutoSave.py old mode 100755 new mode 100644 diff --git a/plugins/AutoSave/__init__.py b/plugins/AutoSave/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/ChangeLogPlugin/ChangeLog.py b/plugins/ChangeLogPlugin/ChangeLog.py old mode 100755 new mode 100644 diff --git a/plugins/ChangeLogPlugin/ChangeLog.qml b/plugins/ChangeLogPlugin/ChangeLog.qml old mode 100755 new mode 100644 diff --git a/plugins/ChangeLogPlugin/ChangeLog.txt b/plugins/ChangeLogPlugin/ChangeLog.txt old mode 100755 new mode 100644 diff --git a/plugins/ChangeLogPlugin/__init__.py b/plugins/ChangeLogPlugin/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/CuraEngineBackend/Cura.proto b/plugins/CuraEngineBackend/Cura.proto old mode 100755 new mode 100644 diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py old mode 100755 new mode 100644 diff --git a/plugins/CuraEngineBackend/ProcessGCodeJob.py b/plugins/CuraEngineBackend/ProcessGCodeJob.py old mode 100755 new mode 100644 diff --git a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py old mode 100755 new mode 100644 diff --git a/plugins/CuraEngineBackend/StartSliceJob.py b/plugins/CuraEngineBackend/StartSliceJob.py old mode 100755 new mode 100644 diff --git a/plugins/CuraEngineBackend/__init__.py b/plugins/CuraEngineBackend/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/CuraProfileReader/CuraProfileReader.py b/plugins/CuraProfileReader/CuraProfileReader.py old mode 100755 new mode 100644 diff --git a/plugins/CuraProfileReader/__init__.py b/plugins/CuraProfileReader/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/CuraProfileWriter/CuraProfileWriter.py b/plugins/CuraProfileWriter/CuraProfileWriter.py old mode 100755 new mode 100644 diff --git a/plugins/CuraProfileWriter/__init__.py b/plugins/CuraProfileWriter/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py old mode 100755 new mode 100644 index edc634a091..8305061a59 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -76,7 +76,7 @@ class GCODEReader(MeshReader): else: backend = Application.getInstance().getBackend() backend._pauseSlicing = True - backend.backendStateChange.emit(3) + backend.backendStateChange.emit(1) Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" Application.getInstance().setHideSettings(True) @@ -116,9 +116,6 @@ class GCODEReader(MeshReader): backend.close() backend.backendStateChange.emit(1) - glist = getattr(Application.getInstance().getController().getScene(), "gcode_list") - glist.clear() - file = open(file_name, "r") layer_data = LayerDataBuilder.LayerDataBuilder() @@ -162,7 +159,6 @@ class GCODEReader(MeshReader): # current_path.append([10, 10, 10]) # while file.readable(): for line in file: - glist.append(line) if len(line) == 0: continue if line[0] == ";": @@ -245,8 +241,6 @@ class GCODEReader(MeshReader): Preferences.getInstance().setValue("cura/jobname_prefix", True) - - view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() diff --git a/plugins/GCODEReader/__init__.py b/plugins/GCODEReader/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/GCodeProfileReader/GCodeProfileReader.py b/plugins/GCodeProfileReader/GCodeProfileReader.py old mode 100755 new mode 100644 diff --git a/plugins/GCodeProfileReader/__init__.py b/plugins/GCodeProfileReader/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/GCodeWriter/GCodeWriter.py b/plugins/GCodeWriter/GCodeWriter.py old mode 100755 new mode 100644 diff --git a/plugins/GCodeWriter/__init__.py b/plugins/GCodeWriter/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/ImageReader/ConfigUI.qml b/plugins/ImageReader/ConfigUI.qml old mode 100755 new mode 100644 diff --git a/plugins/ImageReader/ImageReader.py b/plugins/ImageReader/ImageReader.py old mode 100755 new mode 100644 diff --git a/plugins/ImageReader/ImageReaderUI.py b/plugins/ImageReader/ImageReaderUI.py old mode 100755 new mode 100644 diff --git a/plugins/ImageReader/__init__.py b/plugins/ImageReader/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py old mode 100755 new mode 100644 diff --git a/plugins/LayerView/LayerView.py b/plugins/LayerView/LayerView.py old mode 100755 new mode 100644 diff --git a/plugins/LayerView/LayerView.qml b/plugins/LayerView/LayerView.qml old mode 100755 new mode 100644 diff --git a/plugins/LayerView/LayerViewProxy.py b/plugins/LayerView/LayerViewProxy.py old mode 100755 new mode 100644 diff --git a/plugins/LayerView/__init__.py b/plugins/LayerView/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/LayerView/layerview_composite.shader b/plugins/LayerView/layerview_composite.shader old mode 100755 new mode 100644 diff --git a/plugins/LegacyProfileReader/DictionaryOfDoom.json b/plugins/LegacyProfileReader/DictionaryOfDoom.json old mode 100755 new mode 100644 diff --git a/plugins/LegacyProfileReader/LegacyProfileReader.py b/plugins/LegacyProfileReader/LegacyProfileReader.py old mode 100755 new mode 100644 diff --git a/plugins/LegacyProfileReader/__init__.py b/plugins/LegacyProfileReader/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/MachineSettingsAction/MachineSettingsAction.py b/plugins/MachineSettingsAction/MachineSettingsAction.py old mode 100755 new mode 100644 diff --git a/plugins/MachineSettingsAction/MachineSettingsAction.qml b/plugins/MachineSettingsAction/MachineSettingsAction.qml old mode 100755 new mode 100644 diff --git a/plugins/MachineSettingsAction/__init__.py b/plugins/MachineSettingsAction/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/PerObjectSettingsTool/PerObjectCategory.qml b/plugins/PerObjectSettingsTool/PerObjectCategory.qml old mode 100755 new mode 100644 diff --git a/plugins/PerObjectSettingsTool/PerObjectItem.qml b/plugins/PerObjectSettingsTool/PerObjectItem.qml old mode 100755 new mode 100644 diff --git a/plugins/PerObjectSettingsTool/PerObjectSettingVisibilityHandler.py b/plugins/PerObjectSettingsTool/PerObjectSettingVisibilityHandler.py old mode 100755 new mode 100644 diff --git a/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml b/plugins/PerObjectSettingsTool/PerObjectSettingsPanel.qml old mode 100755 new mode 100644 diff --git a/plugins/PerObjectSettingsTool/PerObjectSettingsTool.py b/plugins/PerObjectSettingsTool/PerObjectSettingsTool.py old mode 100755 new mode 100644 diff --git a/plugins/PerObjectSettingsTool/__init__.py b/plugins/PerObjectSettingsTool/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/RemovableDriveOutputDevice/LinuxRemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/LinuxRemovableDrivePlugin.py old mode 100755 new mode 100644 diff --git a/plugins/RemovableDriveOutputDevice/OSXRemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/OSXRemovableDrivePlugin.py old mode 100755 new mode 100644 diff --git a/plugins/RemovableDriveOutputDevice/RemovableDriveOutputDevice.py b/plugins/RemovableDriveOutputDevice/RemovableDriveOutputDevice.py old mode 100755 new mode 100644 diff --git a/plugins/RemovableDriveOutputDevice/RemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/RemovableDrivePlugin.py old mode 100755 new mode 100644 diff --git a/plugins/RemovableDriveOutputDevice/WindowsRemovableDrivePlugin.py b/plugins/RemovableDriveOutputDevice/WindowsRemovableDrivePlugin.py old mode 100755 new mode 100644 diff --git a/plugins/RemovableDriveOutputDevice/__init__.py b/plugins/RemovableDriveOutputDevice/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/SolidView/SolidView.py b/plugins/SolidView/SolidView.py old mode 100755 new mode 100644 diff --git a/plugins/SolidView/__init__.py b/plugins/SolidView/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/FirmwareUpdateWindow.qml b/plugins/USBPrinting/FirmwareUpdateWindow.qml old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/USBPrinterOutputDevice.py b/plugins/USBPrinting/USBPrinterOutputDevice.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/USBPrinterOutputDeviceManager.py b/plugins/USBPrinting/USBPrinterOutputDeviceManager.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/__init__.py b/plugins/USBPrinting/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/avr_isp/__init__.py b/plugins/USBPrinting/avr_isp/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/avr_isp/chipDB.py b/plugins/USBPrinting/avr_isp/chipDB.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/avr_isp/intelHex.py b/plugins/USBPrinting/avr_isp/intelHex.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/avr_isp/ispBase.py b/plugins/USBPrinting/avr_isp/ispBase.py old mode 100755 new mode 100644 diff --git a/plugins/USBPrinting/avr_isp/stk500v2.py b/plugins/USBPrinting/avr_isp/stk500v2.py old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/BedLevelMachineAction.py b/plugins/UltimakerMachineActions/BedLevelMachineAction.py old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/BedLevelMachineAction.qml b/plugins/UltimakerMachineActions/BedLevelMachineAction.qml old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/UMOCheckupMachineAction.py b/plugins/UltimakerMachineActions/UMOCheckupMachineAction.py old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/UMOCheckupMachineAction.qml b/plugins/UltimakerMachineActions/UMOCheckupMachineAction.qml old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/UMOUpgradeSelection.py b/plugins/UltimakerMachineActions/UMOUpgradeSelection.py old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/UMOUpgradeSelectionMachineAction.qml b/plugins/UltimakerMachineActions/UMOUpgradeSelectionMachineAction.qml old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.py b/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.py old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.qml b/plugins/UltimakerMachineActions/UpgradeFirmwareMachineAction.qml old mode 100755 new mode 100644 diff --git a/plugins/UltimakerMachineActions/__init__.py b/plugins/UltimakerMachineActions/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/MachineInstance.py b/plugins/VersionUpgrade/VersionUpgrade21to22/MachineInstance.py old mode 100755 new mode 100644 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py b/plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py old mode 100755 new mode 100644 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/Profile.py b/plugins/VersionUpgrade/VersionUpgrade21to22/Profile.py old mode 100755 new mode 100644 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py b/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py old mode 100755 new mode 100644 diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/__init__.py b/plugins/VersionUpgrade/VersionUpgrade21to22/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/X3DReader/X3DReader.py b/plugins/X3DReader/X3DReader.py old mode 100755 new mode 100644 diff --git a/plugins/X3DReader/__init__.py b/plugins/X3DReader/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/XRayView/XRayPass.py b/plugins/XRayView/XRayPass.py old mode 100755 new mode 100644 diff --git a/plugins/XRayView/XRayView.py b/plugins/XRayView/XRayView.py old mode 100755 new mode 100644 diff --git a/plugins/XRayView/__init__.py b/plugins/XRayView/__init__.py old mode 100755 new mode 100644 diff --git a/plugins/XRayView/xray.shader b/plugins/XRayView/xray.shader old mode 100755 new mode 100644 diff --git a/plugins/XRayView/xray_composite.shader b/plugins/XRayView/xray_composite.shader old mode 100755 new mode 100644 diff --git a/plugins/XmlMaterialProfile/XmlMaterialProfile.py b/plugins/XmlMaterialProfile/XmlMaterialProfile.py old mode 100755 new mode 100644 diff --git a/plugins/XmlMaterialProfile/__init__.py b/plugins/XmlMaterialProfile/__init__.py old mode 100755 new mode 100644 diff --git a/pytest.ini b/pytest.ini old mode 100755 new mode 100644 diff --git a/resources/definitions/bq_hephestos.def.json b/resources/definitions/bq_hephestos.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/bq_hephestos_2.def.json b/resources/definitions/bq_hephestos_2.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/bq_hephestos_xl.def.json b/resources/definitions/bq_hephestos_xl.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/bq_witbox.def.json b/resources/definitions/bq_witbox.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/bq_witbox_2.def.json b/resources/definitions/bq_witbox_2.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/custom.def.json b/resources/definitions/custom.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/fdmextruder.def.json b/resources/definitions/fdmextruder.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/grr_neo.def.json b/resources/definitions/grr_neo.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/innovo_inventor.def.json b/resources/definitions/innovo_inventor.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/kossel_mini.def.json b/resources/definitions/kossel_mini.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/m180.def.json b/resources/definitions/m180.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/maker_starter.def.json b/resources/definitions/maker_starter.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/mankati_fullscale_xt_plus.def.json b/resources/definitions/mankati_fullscale_xt_plus.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/mendel90.def.json b/resources/definitions/mendel90.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/printrbot_simple.def.json b/resources/definitions/printrbot_simple.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/prusa_i3.def.json b/resources/definitions/prusa_i3.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/prusa_i3_mk2.def.json b/resources/definitions/prusa_i3_mk2.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/prusa_i3_xl.def.json b/resources/definitions/prusa_i3_xl.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/rigidbot.def.json b/resources/definitions/rigidbot.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/rigidbot_big.def.json b/resources/definitions/rigidbot_big.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker.def.json b/resources/definitions/ultimaker.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker2.def.json b/resources/definitions/ultimaker2.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker2_extended.def.json b/resources/definitions/ultimaker2_extended.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker2_extended_plus.def.json b/resources/definitions/ultimaker2_extended_plus.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker2_go.def.json b/resources/definitions/ultimaker2_go.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker2_plus.def.json b/resources/definitions/ultimaker2_plus.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker_original.def.json b/resources/definitions/ultimaker_original.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker_original_dual.def.json b/resources/definitions/ultimaker_original_dual.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/ultimaker_original_plus.def.json b/resources/definitions/ultimaker_original_plus.def.json old mode 100755 new mode 100644 diff --git a/resources/definitions/uniqbot_one.def.json b/resources/definitions/uniqbot_one.def.json old mode 100755 new mode 100644 diff --git a/resources/extruders/ultimaker_original_dual_1st.def.json b/resources/extruders/ultimaker_original_dual_1st.def.json old mode 100755 new mode 100644 diff --git a/resources/extruders/ultimaker_original_dual_2nd.def.json b/resources/extruders/ultimaker_original_dual_2nd.def.json old mode 100755 new mode 100644 diff --git a/resources/i18n/cura.pot b/resources/i18n/cura.pot old mode 100755 new mode 100644 diff --git a/resources/i18n/de/cura.po b/resources/i18n/de/cura.po old mode 100755 new mode 100644 diff --git a/resources/i18n/en/cura.po b/resources/i18n/en/cura.po old mode 100755 new mode 100644 diff --git a/resources/i18n/es/cura.po b/resources/i18n/es/cura.po old mode 100755 new mode 100644 diff --git a/resources/i18n/fdmextruder.def.json.pot b/resources/i18n/fdmextruder.def.json.pot old mode 100755 new mode 100644 diff --git a/resources/i18n/fdmprinter.def.json.pot b/resources/i18n/fdmprinter.def.json.pot old mode 100755 new mode 100644 diff --git a/resources/i18n/fi/cura.po b/resources/i18n/fi/cura.po old mode 100755 new mode 100644 diff --git a/resources/i18n/fr/cura.po b/resources/i18n/fr/cura.po old mode 100755 new mode 100644 diff --git a/resources/i18n/it/cura.po b/resources/i18n/it/cura.po old mode 100755 new mode 100644 diff --git a/resources/i18n/nl/cura.po b/resources/i18n/nl/cura.po old mode 100755 new mode 100644 diff --git a/resources/images/MakerStarterbackplate.png b/resources/images/MakerStarterbackplate.png old mode 100755 new mode 100644 diff --git a/resources/images/Ultimaker2ExtendedPlusbackplate.png b/resources/images/Ultimaker2ExtendedPlusbackplate.png old mode 100755 new mode 100644 diff --git a/resources/images/Ultimaker2Extendedbackplate.png b/resources/images/Ultimaker2Extendedbackplate.png old mode 100755 new mode 100644 diff --git a/resources/images/Ultimaker2Gobackplate.png b/resources/images/Ultimaker2Gobackplate.png old mode 100755 new mode 100644 diff --git a/resources/images/Ultimaker2Plusbackplate.png b/resources/images/Ultimaker2Plusbackplate.png old mode 100755 new mode 100644 diff --git a/resources/images/Ultimaker2backplate.png b/resources/images/Ultimaker2backplate.png old mode 100755 new mode 100644 diff --git a/resources/images/UltimakerPlusbackplate.png b/resources/images/UltimakerPlusbackplate.png old mode 100755 new mode 100644 diff --git a/resources/images/cura-icon.png b/resources/images/cura-icon.png old mode 100755 new mode 100644 diff --git a/resources/images/cura.png b/resources/images/cura.png old mode 100755 new mode 100644 diff --git a/resources/meshes/UltimakerRobot_support.stl b/resources/meshes/UltimakerRobot_support.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/bq_hephestos_2_platform.stl b/resources/meshes/bq_hephestos_2_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/bq_hephestos_platform.stl b/resources/meshes/bq_hephestos_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/bq_witbox_platform.stl b/resources/meshes/bq_witbox_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/grr_neo_platform.stl b/resources/meshes/grr_neo_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/inventor_platform.stl b/resources/meshes/inventor_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/kossel_platform.stl b/resources/meshes/kossel_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/makerstarter_platform.stl b/resources/meshes/makerstarter_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/mankati_fullscale_xt_plus_platform.stl b/resources/meshes/mankati_fullscale_xt_plus_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/mendel90_platform.stl b/resources/meshes/mendel90_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/printrbot_simple_metal_platform.stl b/resources/meshes/printrbot_simple_metal_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/prusai3_platform.stl b/resources/meshes/prusai3_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/prusai3_xl_platform.stl b/resources/meshes/prusai3_xl_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/rigidbot_platform.stl b/resources/meshes/rigidbot_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/rigidbotbig_platform.stl b/resources/meshes/rigidbotbig_platform.stl old mode 100755 new mode 100644 diff --git a/resources/meshes/ultimaker2_platform.obj b/resources/meshes/ultimaker2_platform.obj old mode 100755 new mode 100644 diff --git a/resources/meshes/ultimaker2go_platform.obj b/resources/meshes/ultimaker2go_platform.obj old mode 100755 new mode 100644 diff --git a/resources/meshes/ultimaker_platform.stl b/resources/meshes/ultimaker_platform.stl old mode 100755 new mode 100644 diff --git a/resources/qml/AboutDialog.qml b/resources/qml/AboutDialog.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Actions.qml b/resources/qml/Actions.qml old mode 100755 new mode 100644 diff --git a/resources/qml/AddMachineDialog.qml b/resources/qml/AddMachineDialog.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml old mode 100755 new mode 100644 diff --git a/resources/qml/EngineLog.qml b/resources/qml/EngineLog.qml old mode 100755 new mode 100644 diff --git a/resources/qml/JobSpecs.qml b/resources/qml/JobSpecs.qml old mode 100755 new mode 100644 diff --git a/resources/qml/MachineAction.qml b/resources/qml/MachineAction.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Menus/MaterialMenu.qml b/resources/qml/Menus/MaterialMenu.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Menus/NozzleMenu.qml b/resources/qml/Menus/NozzleMenu.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Menus/PrinterMenu.qml b/resources/qml/Menus/PrinterMenu.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Menus/ProfileMenu.qml b/resources/qml/Menus/ProfileMenu.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Menus/RecentFilesMenu.qml b/resources/qml/Menus/RecentFilesMenu.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Menus/ViewMenu.qml b/resources/qml/Menus/ViewMenu.qml old mode 100755 new mode 100644 diff --git a/resources/qml/MonitorButton.qml b/resources/qml/MonitorButton.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/GeneralPage.qml b/resources/qml/Preferences/GeneralPage.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/MachinesPage.qml b/resources/qml/Preferences/MachinesPage.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/MaterialView.qml b/resources/qml/Preferences/MaterialView.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/MaterialsPage.qml b/resources/qml/Preferences/MaterialsPage.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/ProfileTab.qml b/resources/qml/Preferences/ProfileTab.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/ProfilesPage.qml b/resources/qml/Preferences/ProfilesPage.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/ReadOnlySpinBox.qml b/resources/qml/Preferences/ReadOnlySpinBox.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/ReadOnlyTextArea.qml b/resources/qml/Preferences/ReadOnlyTextArea.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/ReadOnlyTextField.qml b/resources/qml/Preferences/ReadOnlyTextField.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Preferences/SettingVisibilityPage.qml b/resources/qml/Preferences/SettingVisibilityPage.qml old mode 100755 new mode 100644 diff --git a/resources/qml/PrintMonitor.qml b/resources/qml/PrintMonitor.qml old mode 100755 new mode 100644 diff --git a/resources/qml/SaveButton.qml b/resources/qml/SaveButton.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingCategory.qml b/resources/qml/Settings/SettingCategory.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingCheckBox.qml b/resources/qml/Settings/SettingCheckBox.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingComboBox.qml b/resources/qml/Settings/SettingComboBox.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingExtruder.qml b/resources/qml/Settings/SettingExtruder.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingItem.qml b/resources/qml/Settings/SettingItem.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingTextField.qml b/resources/qml/Settings/SettingTextField.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingUnknown.qml b/resources/qml/Settings/SettingUnknown.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Settings/SettingView.qml b/resources/qml/Settings/SettingView.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml old mode 100755 new mode 100644 diff --git a/resources/qml/SidebarAdvanced.qml b/resources/qml/SidebarAdvanced.qml old mode 100755 new mode 100644 diff --git a/resources/qml/SidebarContents.qml b/resources/qml/SidebarContents.qml old mode 100755 new mode 100644 diff --git a/resources/qml/SidebarHeader.qml b/resources/qml/SidebarHeader.qml old mode 100755 new mode 100644 diff --git a/resources/qml/SidebarSimple.qml b/resources/qml/SidebarSimple.qml old mode 100755 new mode 100644 diff --git a/resources/qml/SidebarTooltip.qml b/resources/qml/SidebarTooltip.qml old mode 100755 new mode 100644 diff --git a/resources/qml/Toolbar.qml b/resources/qml/Toolbar.qml old mode 100755 new mode 100644 diff --git a/resources/quality/high.inst.cfg b/resources/quality/high.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/low.inst.cfg b/resources/quality/low.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/normal.inst.cfg b/resources/quality/normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/pla_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.25_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/pla_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.4_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/pla_0.4_high.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.4_high.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/pla_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.4_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/pla_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.6_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/pla_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/pla_0.8_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.25_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.4_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.4_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.4_high.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.4_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.6_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_abs_0.8_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.25_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.4_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.4_high.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.4_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.6_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpe_0.8_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.4_draft.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.4_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.6_draft.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.6_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.8_draft.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_cpep_0.8_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.25_high.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.25_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.4_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.4_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.6_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.6_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.8_draft.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_nylon_0.8_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.25_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.25_high.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.25_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.4_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.4_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.6_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.6_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.8_draft.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_pc_0.8_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg b/resources/quality/ultimaker2_plus/um2p_tpu_0.25_high.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg b/resources/quality/ultimaker2_plus/um2p_tpu_0.4_normal.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/quality/ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg b/resources/quality/ultimaker2_plus/um2p_tpu_0.6_fast.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/shaders/grid.shader b/resources/shaders/grid.shader old mode 100755 new mode 100644 diff --git a/resources/shaders/overhang.shader b/resources/shaders/overhang.shader old mode 100755 new mode 100644 diff --git a/resources/shaders/striped.shader b/resources/shaders/striped.shader old mode 100755 new mode 100644 diff --git a/resources/shaders/transparent_object.shader b/resources/shaders/transparent_object.shader old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/LICENSE.txt b/resources/themes/cura/fonts/LICENSE.txt old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-Bold.ttf b/resources/themes/cura/fonts/OpenSans-Bold.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-BoldItalic.ttf b/resources/themes/cura/fonts/OpenSans-BoldItalic.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-Italic.ttf b/resources/themes/cura/fonts/OpenSans-Italic.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-Light.ttf b/resources/themes/cura/fonts/OpenSans-Light.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-LightItalic.ttf b/resources/themes/cura/fonts/OpenSans-LightItalic.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-Regular.ttf b/resources/themes/cura/fonts/OpenSans-Regular.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-Semibold.ttf b/resources/themes/cura/fonts/OpenSans-Semibold.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/fonts/OpenSans-SemiboldItalic.ttf b/resources/themes/cura/fonts/OpenSans-SemiboldItalic.ttf old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/application.svg b/resources/themes/cura/icons/application.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/arrow_bottom.svg b/resources/themes/cura/icons/arrow_bottom.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/arrow_left.svg b/resources/themes/cura/icons/arrow_left.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/arrow_right.svg b/resources/themes/cura/icons/arrow_right.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/arrow_top.svg b/resources/themes/cura/icons/arrow_top.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/basic.svg b/resources/themes/cura/icons/basic.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_adhesion.svg b/resources/themes/cura/icons/category_adhesion.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_blackmagic.svg b/resources/themes/cura/icons/category_blackmagic.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_cool.svg b/resources/themes/cura/icons/category_cool.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_dual.svg b/resources/themes/cura/icons/category_dual.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_experimental.svg b/resources/themes/cura/icons/category_experimental.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_fixes.svg b/resources/themes/cura/icons/category_fixes.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_infill.svg b/resources/themes/cura/icons/category_infill.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_layer_height.svg b/resources/themes/cura/icons/category_layer_height.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_machine.svg b/resources/themes/cura/icons/category_machine.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_material.svg b/resources/themes/cura/icons/category_material.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_shell.svg b/resources/themes/cura/icons/category_shell.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_shield.svg b/resources/themes/cura/icons/category_shield.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_speed.svg b/resources/themes/cura/icons/category_speed.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_support.svg b/resources/themes/cura/icons/category_support.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_travel.svg b/resources/themes/cura/icons/category_travel.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/category_unknown.svg b/resources/themes/cura/icons/category_unknown.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/check.svg b/resources/themes/cura/icons/check.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/cross1.svg b/resources/themes/cura/icons/cross1.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/cross2.svg b/resources/themes/cura/icons/cross2.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/dense.svg b/resources/themes/cura/icons/dense.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/dot.svg b/resources/themes/cura/icons/dot.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/hollow.svg b/resources/themes/cura/icons/hollow.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/link.svg b/resources/themes/cura/icons/link.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/load.svg b/resources/themes/cura/icons/load.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/minus.svg b/resources/themes/cura/icons/minus.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/mirror.svg b/resources/themes/cura/icons/mirror.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/notice.svg b/resources/themes/cura/icons/notice.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/pencil.svg b/resources/themes/cura/icons/pencil.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/plugin.svg b/resources/themes/cura/icons/plugin.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/plus.svg b/resources/themes/cura/icons/plus.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/print_time.svg b/resources/themes/cura/icons/print_time.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/printsetup.svg b/resources/themes/cura/icons/printsetup.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/quick.svg b/resources/themes/cura/icons/quick.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/reset.svg b/resources/themes/cura/icons/reset.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/rotate.svg b/resources/themes/cura/icons/rotate.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/rotate_layflat.svg b/resources/themes/cura/icons/rotate_layflat.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/rotate_reset.svg b/resources/themes/cura/icons/rotate_reset.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/scale.svg b/resources/themes/cura/icons/scale.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/scale_max.svg b/resources/themes/cura/icons/scale_max.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/scale_reset.svg b/resources/themes/cura/icons/scale_reset.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/setting_per_object.svg b/resources/themes/cura/icons/setting_per_object.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/settings.svg b/resources/themes/cura/icons/settings.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/solid.svg b/resources/themes/cura/icons/solid.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/sparse.svg b/resources/themes/cura/icons/sparse.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/star.svg b/resources/themes/cura/icons/star.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_monitor.svg b/resources/themes/cura/icons/tab_monitor.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_monitor_busy.svg b/resources/themes/cura/icons/tab_monitor_busy.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_monitor_connected.svg b/resources/themes/cura/icons/tab_monitor_connected.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_monitor_offline.svg b/resources/themes/cura/icons/tab_monitor_offline.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_monitor_paused.svg b/resources/themes/cura/icons/tab_monitor_paused.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_monitor_stopped.svg b/resources/themes/cura/icons/tab_monitor_stopped.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_monitor_unknown.svg b/resources/themes/cura/icons/tab_monitor_unknown.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/tab_settings.svg b/resources/themes/cura/icons/tab_settings.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/translate.svg b/resources/themes/cura/icons/translate.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/ulti.svg b/resources/themes/cura/icons/ulti.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/view_layer.svg b/resources/themes/cura/icons/view_layer.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/view_normal.svg b/resources/themes/cura/icons/view_normal.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/view_xray.svg b/resources/themes/cura/icons/view_xray.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/viewmode.svg b/resources/themes/cura/icons/viewmode.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/icons/warning.svg b/resources/themes/cura/icons/warning.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/images/logo.svg b/resources/themes/cura/images/logo.svg old mode 100755 new mode 100644 diff --git a/resources/themes/cura/styles.qml b/resources/themes/cura/styles.qml old mode 100755 new mode 100644 diff --git a/resources/themes/cura/theme.json b/resources/themes/cura/theme.json old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_extended_plus_0.25.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.25.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_extended_plus_0.4.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.4.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_extended_plus_0.6.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.6.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_extended_plus_0.8.inst.cfg b/resources/variants/ultimaker2_extended_plus_0.8.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_plus_0.25.inst.cfg b/resources/variants/ultimaker2_plus_0.25.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_plus_0.4.inst.cfg b/resources/variants/ultimaker2_plus_0.4.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_plus_0.6.inst.cfg b/resources/variants/ultimaker2_plus_0.6.inst.cfg old mode 100755 new mode 100644 diff --git a/resources/variants/ultimaker2_plus_0.8.inst.cfg b/resources/variants/ultimaker2_plus_0.8.inst.cfg old mode 100755 new mode 100644 diff --git a/setup.py b/setup.py old mode 100755 new mode 100644 diff --git a/tests/TestMachineAction.py b/tests/TestMachineAction.py old mode 100755 new mode 100644 From aa81cc090b18a02e3c06906eb7137c2f810546c1 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 14 Oct 2016 18:57:39 +0600 Subject: [PATCH 15/68] T466: Added ability to print loaded gcode --- plugins/GCODEReader/GCODEReader.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 8305061a59..fd8d3c9f08 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -76,7 +76,7 @@ class GCODEReader(MeshReader): else: backend = Application.getInstance().getBackend() backend._pauseSlicing = True - backend.backendStateChange.emit(1) + backend.backendStateChange.emit(3) Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" Application.getInstance().setHideSettings(True) @@ -116,6 +116,9 @@ class GCODEReader(MeshReader): backend.close() backend.backendStateChange.emit(1) + glist = getattr(Application.getInstance().getController().getScene(), "gcode_list") + glist.clear() + file = open(file_name, "r") layer_data = LayerDataBuilder.LayerDataBuilder() @@ -159,6 +162,7 @@ class GCODEReader(MeshReader): # current_path.append([10, 10, 10]) # while file.readable(): for line in file: + glist.append(line) if len(line) == 0: continue if line[0] == ";": From 38d42a78858b047a8a91da3af2aeca86d7da2948 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sun, 16 Oct 2016 13:30:16 +0600 Subject: [PATCH 16/68] T466: Added multilayer parsing for speed issues --- plugins/GCODEReader/GCODEReader.py | 60 +++++++++++++++++++++--------- 1 file changed, 42 insertions(+), 18 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index fd8d3c9f08..519222c8ec 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -123,13 +123,6 @@ class GCODEReader(MeshReader): layer_data = LayerDataBuilder.LayerDataBuilder() - layer_id = 0 - - layer_data.addLayer(layer_id) - this_layer = layer_data.getLayer(layer_id) - layer_data.setLayerHeight(layer_id, 0) - layer_data.setLayerThickness(layer_id, 0.1) - current_extruder = 1 current_path = [] current_x = 0 @@ -137,18 +130,47 @@ class GCODEReader(MeshReader): current_z = 0 current_e = 0 + layers = [] + for line in file: + glist.append(line) + if len(line) == 0: + continue + if line[0] == ";": + continue + G = self.getInt(line, "G") + if G is not None: + if G == 0 or G == 1: + z = self.getFloat(line, "Z") + if z is not None and z not in layers and z >= 0: + layers.append(z) + layers.sort() + file.seek(0) + + for layer in layers: + layer_id = layers.index(layer) + layer_data.addLayer(layer_id) + layer_data.setLayerHeight(layer_id, layer) + layer_data.setLayerThickness(layer_id, 0.25) + def CreatePolygon(): + try: + this_layer = layer_data.getLayer(layers.index(current_path[0][1])) + except ValueError: + current_path.clear() + return count = len(current_path) line_types = numpy.empty((count-1, 1), numpy.int32) line_types[:, 0] = 1 line_widths = numpy.empty((count-1, 1), numpy.int32) - line_widths[:, 0] = 1 + line_widths[:, 0] = 0.5 points = numpy.empty((count, 3), numpy.float32) i = 0 for point in current_path: points[i, 0] = point[0] points[i, 1] = point[1] points[i, 2] = point[2] + if i > 0: + line_types[i-1] = point[3] i += 1 this_poly = LayerPolygon.LayerPolygon(layer_data, current_extruder, line_types, points, line_widths) @@ -158,11 +180,7 @@ class GCODEReader(MeshReader): current_path.clear() - # current_path.append([0, 0, 0]) - # current_path.append([10, 10, 10]) - # while file.readable(): for line in file: - glist.append(line) if len(line) == 0: continue if line[0] == ";": @@ -174,26 +192,32 @@ class GCODEReader(MeshReader): y = self.getFloat(line, "Y") z = self.getFloat(line, "Z") e = self.getFloat(line, "E") + z_changed = False if x is not None: current_x = x if y is not None: current_y = y if z is not None: + if not current_z == z: + z_changed = True current_z = z if e is not None: if e > current_e: - current_path.append([current_x, current_z, -current_y]) + current_path.append([current_x, current_z, -current_y, 1]) else: - if len(current_path) > 1: - CreatePolygon() - else: - current_path.clear() + current_path.append([current_x, current_z, -current_y, 0]) current_e = e else: + # if G == 0: + # current_path.append([current_x, current_z, -current_y, 6]) + # else: + current_path.append([current_x, current_z, -current_y, 0]) + if z_changed: if len(current_path) > 1: CreatePolygon() - elif G == 1: + else: current_path.clear() + elif G == 28: x = self.getFloat(line, "X") y = self.getFloat(line, "Y") From 4ba8033c2aa4f8e009720193a92204772c90910c Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 21 Oct 2016 13:47:14 +0600 Subject: [PATCH 17/68] T553: Resetting layer slider to max --- plugins/GCODEReader/GCODEReader.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 519222c8ec..868fa1e430 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -272,6 +272,8 @@ class GCODEReader(MeshReader): view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() + view.setLayer(999999) + view.calculateMaxLayers() # scene_node.setEnabled(False) #scene_node.setSelectable(False) From 9da00563e544d0a3391f2336aee4f10e31aa4af4 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 21 Oct 2016 15:26:34 +0600 Subject: [PATCH 18/68] T553: Fixed job name --- cura/PrintInformation.py | 8 +++-- plugins/GCODEReader/GCODEReader.py | 52 +++++++++++++++--------------- 2 files changed, 32 insertions(+), 28 deletions(-) diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py index b65101ecc7..fa0b43993e 100644 --- a/cura/PrintInformation.py +++ b/cura/PrintInformation.py @@ -49,6 +49,8 @@ class PrintInformation(QObject): self._material_lengths = [] self._material_weights = [] + self._pre_sliced = False + self._backend = Application.getInstance().getBackend() if self._backend: self._backend.printDurationMessage.connect(self._onPrintDurationMessage) @@ -122,7 +124,9 @@ class PrintInformation(QObject): def createJobName(self, base_name): base_name = self._stripAccents(base_name) self._setAbbreviatedMachineName() - if Preferences.getInstance().getValue("cura/jobname_prefix"): + if self._pre_sliced: + return "Pre-sliced_" + base_name + elif Preferences.getInstance().getValue("cura/jobname_prefix"): return self._abbr_machine + "_" + base_name else: return base_name @@ -150,4 +154,4 @@ class PrintInformation(QObject): ## Utility method that strips accents from characters (eg: â -> a) def _stripAccents(self, str): - return ''.join(char for char in unicodedata.normalize('NFD', str) if unicodedata.category(char) != 'Mn') \ No newline at end of file + return ''.join(char for char in unicodedata.normalize('NFD', str) if unicodedata.category(char) != 'Mn') diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 868fa1e430..55802e5c16 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -58,35 +58,33 @@ class GCODEReader(MeshReader): except: return None - def onSceneChanged(self, obj): - scene = Application.getInstance().getController().getScene() + def parent_changed(self, node): + if node.getParent() is None: + scene = Application.getInstance().getController().getScene() - def findAny(): - for node in DepthFirstIterator(scene.getRoot()): - if hasattr(node, "gcode"): - return True - return False + def findAny(): + for node1 in DepthFirstIterator(scene.getRoot()): + if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: + return True + return False - if not findAny(): - # Preferences.getInstance().setValue("cura/jobname_prefix", True) backend = Application.getInstance().getBackend() - backend._pauseSlicing = False - Application.getInstance().setHideSettings(False) - #Application.getInstance().getPrintInformation()._setAbbreviatedMachineName() - else: - backend = Application.getInstance().getBackend() - backend._pauseSlicing = True - backend.backendStateChange.emit(3) - Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" - Application.getInstance().setHideSettings(True) + if not findAny(): + backend._pauseSlicing = False + Application.getInstance().setHideSettings(False) + Application.getInstance().getPrintInformation()._pre_sliced = False + else: + backend._pauseSlicing = True + backend.backendStateChange.emit(3) + Application.getInstance().getPrintInformation()._pre_sliced = True + Application.getInstance().setHideSettings(True) + def read(self, file_name): scene_node = None extension = os.path.splitext(file_name)[1] if extension.lower() in self._supported_extensions: - scene = Application.getInstance().getController().getScene() - scene.sceneChanged.connect(self.onSceneChanged) # for node in DepthFirstIterator(scene.getRoot()): # if node.callDecoration("getLayerData"): # node.getParent().removeChild(node) @@ -245,7 +243,12 @@ class GCODEReader(MeshReader): decorator.setLayerData(layer_mesh) scene_node.addDecorator(decorator) - Application.getInstance().getPrintInformation()._abbr_machine = "Pre-sliced" + Application.getInstance().getPrintInformation()._pre_sliced = True + + + + + scene_node.parentChanged.connect(self.parent_changed) scene_node_parent = Application.getInstance().getBuildVolume() scene_node.setParent(scene_node_parent) @@ -256,6 +259,8 @@ class GCODEReader(MeshReader): scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) + + # mesh_builder = MeshBuilder() # mesh_builder.setFileName(file_name) # @@ -264,11 +269,6 @@ class GCODEReader(MeshReader): # scene_node.setMeshData(mesh_builder.build()) # scene_node.setMeshData(MeshData(file_name=file_name)) - - - Preferences.getInstance().setValue("cura/jobname_prefix", True) - - view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() From 84add5be84f7ef95d438c047dc8a4231a4eda51c Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 21 Oct 2016 16:06:28 +0600 Subject: [PATCH 19/68] T466: Added disabling of view button --- cura/PrintInformation.py | 10 ++++++++++ plugins/GCODEReader/GCODEReader.py | 4 ++-- resources/qml/Cura.qml | 3 ++- resources/qml/Menus/ViewMenu.qml | 1 + 4 files changed, 15 insertions(+), 3 deletions(-) diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py index fa0b43993e..4379ec72ca 100644 --- a/cura/PrintInformation.py +++ b/cura/PrintInformation.py @@ -63,6 +63,16 @@ class PrintInformation(QObject): currentPrintTimeChanged = pyqtSignal() + preSlicedChanged = pyqtSignal() + + @pyqtProperty(bool, notify=preSlicedChanged) + def isPreSliced(self): + return self._pre_sliced + + def setPreSliced(self, pre_sliced): + self._pre_sliced = pre_sliced + self.preSlicedChanged.emit() + @pyqtProperty(Duration, notify = currentPrintTimeChanged) def currentPrintTime(self): return self._current_print_time diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 55802e5c16..4b13f03220 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -72,11 +72,11 @@ class GCODEReader(MeshReader): if not findAny(): backend._pauseSlicing = False Application.getInstance().setHideSettings(False) - Application.getInstance().getPrintInformation()._pre_sliced = False + Application.getInstance().getPrintInformation().setPreSliced(False) else: backend._pauseSlicing = True backend.backendStateChange.emit(3) - Application.getInstance().getPrintInformation()._pre_sliced = True + Application.getInstance().getPrintInformation().setPreSliced(True) Application.getInstance().setHideSettings(True) diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml index 314f3b7443..e4843f7eb5 100644 --- a/resources/qml/Cura.qml +++ b/resources/qml/Cura.qml @@ -406,7 +406,8 @@ UM.MainWindow iconSource: UM.Theme.getIcon("viewmode"); style: UM.Theme.styles.tool_button; - tooltip: ''; + tooltip: ""; + enabled: !PrintInformation.isPreSliced menu: ViewMenu { } } diff --git a/resources/qml/Menus/ViewMenu.qml b/resources/qml/Menus/ViewMenu.qml index 74579932e0..dc9cbe7501 100644 --- a/resources/qml/Menus/ViewMenu.qml +++ b/resources/qml/Menus/ViewMenu.qml @@ -11,6 +11,7 @@ Menu { title: catalog.i18nc("@title:menu menubar:toplevel", "&View"); id: menu + enabled: !PrintInformation.isPreSliced Instantiator { model: UM.ViewModel { } From 1f84ad70842aa191e34cd92df04a9970aa317cd0 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 21 Oct 2016 16:13:27 +0600 Subject: [PATCH 20/68] T466: Added explanation text on settings panel --- resources/qml/Sidebar.qml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml index 234e139791..44cad11d09 100644 --- a/resources/qml/Sidebar.qml +++ b/resources/qml/Sidebar.qml @@ -289,7 +289,7 @@ Rectangle Label { id: settingsModeLabel - text: catalog.i18nc("@label:listbox", "Print Setup"); + text: !hideSettings ? catalog.i18nc("@label:listbox", "Print Setup") : catalog.i18nc("@label:listbox","Not possible to modify slicing settings or re-slice\nwhile a GCODE file is open"); anchors.left: parent.left anchors.leftMargin: UM.Theme.getSize("default_margin").width; anchors.top: headerSeparator.bottom @@ -297,7 +297,7 @@ Rectangle width: parent.width * 0.45 - 2 * UM.Theme.getSize("default_margin").width font: UM.Theme.getFont("large") color: UM.Theme.getColor("text") - visible: !monitoringPrint && !hideSettings + visible: !monitoringPrint elide: Text.ElideRight } From b4a7173a6160c25f75a4df8482d040c4d4219c03 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sun, 23 Oct 2016 14:53:25 +0600 Subject: [PATCH 21/68] T466: Only one gcode file can be loaded at a time, and deleting previous gcode file when loading non-gcode file Merge changes : Only call backgroundItem.hasMesh if/on an imported model (skips if only curaprofiles get loaded) --- cura/CuraApplication.py | 51 +++++++++++++++++++++++++ plugins/GCODEReader/GCODEReader.py | 2 + resources/qml/Cura.qml | 24 ++++++------ resources/qml/Menus/RecentFilesMenu.qml | 2 +- 4 files changed, 67 insertions(+), 12 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index c5db2b01e7..b53b351ac2 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -19,6 +19,9 @@ from UM.SaveFile import SaveFile from UM.Scene.Selection import Selection from UM.Scene.GroupDecorator import GroupDecorator from UM.Settings.Validator import Validator +from types import MethodType + +from UM.Qt.Bindings.MeshFileHandlerProxy import MeshFileHandlerProxy from UM.Operations.AddSceneNodeOperation import AddSceneNodeOperation from UM.Operations.RemoveSceneNodeOperation import RemoveSceneNodeOperation @@ -535,6 +538,54 @@ class CuraApplication(QtApplication): qmlRegisterType(QUrl.fromLocalFile(path), "Cura", 1, 0, type_name) + loadingFiles = [] + + @pyqtSlot(QUrl) + def loadFile(self, file): + scene = self.getController().getScene() + + def findAny(): + for node1 in DepthFirstIterator(scene.getRoot()): + if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: + return True + return False + if findAny(): + self.deleteAll() + + if not file.isValid(): + return + + supported_extensions = [".gcode", ".g"] + + f = file.toLocalFile() + + if len(self.loadingFiles) > 0: + extension = os.path.splitext(f)[1] + if extension.lower() in supported_extensions: + return + extension = os.path.splitext(self.loadingFiles[0])[1] + if extension.lower() in supported_extensions: + return + + self.loadingFiles.append(f) + + job = ReadMeshJob(f) + job.finished.connect(self._readMeshFinished) + job.start() + + def _readMeshFinished(self, job): + node = job.getResult() + if node != None: + filename = job.getFileName() + node.setSelectable(True) + node.setName(filename) + self.loadingFiles.remove(filename) + + op = AddSceneNodeOperation(node, self.getController().getScene().getRoot()) + op.push() + + self.getController().getScene().sceneChanged.emit(node) + def onSelectionChanged(self): if Selection.hasSelection(): if self.getController().getActiveTool(): diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 4b13f03220..1420a9d081 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -14,11 +14,13 @@ from UM.Math.AxisAlignedBox import AxisAlignedBox from UM.Application import Application from UM.Preferences import Preferences + from cura import LayerDataBuilder from cura import LayerDataDecorator from cura import LayerPolygon import numpy +from types import MethodType from UM.Job import Job diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml index e4843f7eb5..4a6a780305 100644 --- a/resources/qml/Cura.qml +++ b/resources/qml/Cura.qml @@ -269,16 +269,16 @@ UM.MainWindow if(drop.urls.length > 0) { // Import models + var imported_model = -1; for(var i in drop.urls) { // There is no endsWith in this version of JS... if ((drop.urls[i].length <= 12) || (drop.urls[i].substring(drop.urls[i].length-12) !== ".curaprofile")) { // Drop an object - UM.MeshFileHandler.readLocalFile(drop.urls[i]); - if (i == drop.urls.length - 1) + Printer.loadFile(drop.urls[i]); + if (imported_model == -1) { - var meshName = backgroundItem.getMeshName(drop.urls[i].toString()); - backgroundItem.hasMesh(decodeURIComponent(meshName)); + imported_model = i; } } } @@ -297,6 +297,11 @@ UM.MainWindow } messageDialog.open() } + if (imported_model != -1) + { + var meshName = backgroundItem.getMeshName(drop.urls[imported_model].toString()) + backgroundItem.hasMesh(decodeURIComponent(meshName)) + } } } } @@ -732,14 +737,11 @@ UM.MainWindow for(var i in fileUrls) { - UM.MeshFileHandler.readLocalFile(fileUrls[i]) - - if (i == fileUrls.length - 1) - { - var meshName = backgroundItem.getMeshName(fileUrls.toString()) - backgroundItem.hasMesh(decodeURIComponent(meshName)) - } + Printer.loadFile(fileUrls[i]) } + + var meshName = backgroundItem.getMeshName(fileUrls[0].toString()) + backgroundItem.hasMesh(decodeURIComponent(meshName)) } } diff --git a/resources/qml/Menus/RecentFilesMenu.qml b/resources/qml/Menus/RecentFilesMenu.qml index c47fc5715b..4453be6887 100644 --- a/resources/qml/Menus/RecentFilesMenu.qml +++ b/resources/qml/Menus/RecentFilesMenu.qml @@ -26,7 +26,7 @@ Menu return (index + 1) + ". " + path.slice(path.lastIndexOf("/") + 1); } onTriggered: { - UM.MeshFileHandler.readLocalFile(modelData); + Printer.loadFile(modelData); var meshName = backgroundItem.getMeshName(modelData.toString()) backgroundItem.hasMesh(decodeURIComponent(meshName)) } From b24d5ef12be57de9aadfdebaf97a69b50421723c Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sun, 23 Oct 2016 15:03:53 +0600 Subject: [PATCH 22/68] T466: Ignoring top layers option for gcode files --- plugins/LayerView/LayerPass.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index 9e610b68d2..a8a2b7ba7e 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -55,7 +55,7 @@ class LayerPass(RenderPass): continue # Render all layers below a certain number as line mesh instead of vertices. - if self._layerview._current_layer_num - self._layerview._solid_layers > -1 and not self._layerview._only_show_top_layers: + if self._layerview._current_layer_num - self._layerview._solid_layers > -1 and (not self._layerview._only_show_top_layers or hasattr(node, "gcode")): start = 0 end = 0 element_counts = layer_data.getElementCounts() From 5d0c598622bc394cbb27b46341397af999d5a869 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 25 Oct 2016 16:38:25 +0600 Subject: [PATCH 23/68] T466: Cleaned code --- cura/CuraApplication.py | 3 -- .../ProcessSlicedLayersJob.py | 1 - plugins/GCODEReader/GCODEReader.py | 50 +------------------ 3 files changed, 1 insertion(+), 53 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index b53b351ac2..547999f142 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -19,9 +19,6 @@ from UM.SaveFile import SaveFile from UM.Scene.Selection import Selection from UM.Scene.GroupDecorator import GroupDecorator from UM.Settings.Validator import Validator -from types import MethodType - -from UM.Qt.Bindings.MeshFileHandlerProxy import MeshFileHandlerProxy from UM.Operations.AddSceneNodeOperation import AddSceneNodeOperation from UM.Operations.RemoveSceneNodeOperation import RemoveSceneNodeOperation diff --git a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py index 206a3e83e8..490690bd27 100644 --- a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py +++ b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py @@ -60,7 +60,6 @@ class ProcessSlicedLayersJob(Job): for node in DepthFirstIterator(self._scene.getRoot()): if node.callDecoration("getLayerData"): node.getParent().removeChild(node) - # break if self._abort_requested: if self._progress: self._progress.hide() diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 1420a9d081..0e4c82674c 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -3,16 +3,12 @@ # Uranium is released under the terms of the AGPLv3 or higher. from UM.Mesh.MeshReader import MeshReader -from UM.Mesh.MeshBuilder import MeshBuilder -from UM.Mesh.MeshData import MeshData import os from UM.Scene.SceneNode import SceneNode from UM.Scene.Iterator.DepthFirstIterator import DepthFirstIterator from UM.Math.Vector import Vector -from UM.Math.Color import Color from UM.Math.AxisAlignedBox import AxisAlignedBox from UM.Application import Application -from UM.Preferences import Preferences from cura import LayerDataBuilder @@ -20,11 +16,8 @@ from cura import LayerDataDecorator from cura import LayerPolygon import numpy -from types import MethodType -from UM.Job import Job - class GCODEReader(MeshReader): def __init__(self): super(GCODEReader, self).__init__() @@ -35,9 +28,6 @@ class GCODEReader(MeshReader): if n < 1: return None m = line.find(' ', n) - # m2 = line.find(';', n) - # if m < 0: - # m = m2 try: if m < 0: return int(line[n:]) @@ -50,9 +40,6 @@ class GCODEReader(MeshReader): if n < 1: return None m = line.find(' ', n) - # m2 = line.find(';', n) - # if m < 0: - # m = m2 try: if m < 0: return float(line[n:]) @@ -81,31 +68,15 @@ class GCODEReader(MeshReader): Application.getInstance().getPrintInformation().setPreSliced(True) Application.getInstance().setHideSettings(True) - def read(self, file_name): scene_node = None extension = os.path.splitext(file_name)[1] if extension.lower() in self._supported_extensions: - # for node in DepthFirstIterator(scene.getRoot()): - # if node.callDecoration("getLayerData"): - # node.getParent().removeChild(node) Application.getInstance().deleteAll() scene_node = SceneNode() - # mesh_builder = MeshBuilder() - # mesh_builder.setFileName(file_name) - # - # mesh_builder.addCube( - # width=5, - # height=5, - # depth=5, - # center=Vector(0, 2.5, 0) - # ) - # - # scene_node.setMeshData(mesh_builder.build()) - def getBoundingBox(): return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) @@ -208,10 +179,7 @@ class GCODEReader(MeshReader): current_path.append([current_x, current_z, -current_y, 0]) current_e = e else: - # if G == 0: - # current_path.append([current_x, current_z, -current_y, 6]) - # else: - current_path.append([current_x, current_z, -current_y, 0]) + current_path.append([current_x, current_z, -current_y, 0]) if z_changed: if len(current_path) > 1: CreatePolygon() @@ -247,9 +215,6 @@ class GCODEReader(MeshReader): Application.getInstance().getPrintInformation()._pre_sliced = True - - - scene_node.parentChanged.connect(self.parent_changed) scene_node_parent = Application.getInstance().getBuildVolume() @@ -261,23 +226,10 @@ class GCODEReader(MeshReader): scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) - - - # mesh_builder = MeshBuilder() - # mesh_builder.setFileName(file_name) - # - # mesh_builder.addCube(10, 10, 10, Vector(0, -5, 0)) - - # scene_node.setMeshData(mesh_builder.build()) - # scene_node.setMeshData(MeshData(file_name=file_name)) - view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": view.resetLayerData() view.setLayer(999999) view.calculateMaxLayers() - # scene_node.setEnabled(False) - #scene_node.setSelectable(False) - return scene_node From d7120e24d08a35cee9b99355afecef124c464c8c Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 3 Nov 2016 16:12:11 +0600 Subject: [PATCH 24/68] T466: Automatic switch to LayerView --- cura/CuraApplication.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 547999f142..dbbbb7e4f8 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -555,14 +555,15 @@ class CuraApplication(QtApplication): supported_extensions = [".gcode", ".g"] f = file.toLocalFile() - + extension = os.path.splitext(f)[1] if len(self.loadingFiles) > 0: - extension = os.path.splitext(f)[1] if extension.lower() in supported_extensions: return extension = os.path.splitext(self.loadingFiles[0])[1] if extension.lower() in supported_extensions: return + elif extension.lower() in supported_extensions: + self.getController().setActiveView("LayerView") self.loadingFiles.append(f) From ba9d7fa1e2f4bbd77f3c31d7e265873874e5acd0 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 3 Nov 2016 16:39:20 +0600 Subject: [PATCH 25/68] T466: Fixed one at a time printing --- plugins/GCODEReader/GCODEReader.py | 43 ++++++++++++------------------ 1 file changed, 17 insertions(+), 26 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 0e4c82674c..9346c8cc4f 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -100,35 +100,24 @@ class GCODEReader(MeshReader): current_y = 0 current_z = 0 current_e = 0 - - layers = [] - for line in file: - glist.append(line) - if len(line) == 0: - continue - if line[0] == ";": - continue - G = self.getInt(line, "G") - if G is not None: - if G == 0 or G == 1: - z = self.getFloat(line, "Z") - if z is not None and z not in layers and z >= 0: - layers.append(z) - layers.sort() - file.seek(0) - - for layer in layers: - layer_id = layers.index(layer) - layer_data.addLayer(layer_id) - layer_data.setLayerHeight(layer_id, layer) - layer_data.setLayerThickness(layer_id, 0.25) + current_layer = 0 def CreatePolygon(): + countvalid = False + for point in current_path: + if point[3] > 0: + countvalid += 1 + if countvalid < 2: + current_path.clear() + return False try: - this_layer = layer_data.getLayer(layers.index(current_path[0][1])) + layer_data.addLayer(current_layer) + layer_data.setLayerHeight(current_layer, current_path[0][1]) + layer_data.setLayerThickness(current_layer, 0.25) + this_layer = layer_data.getLayer(current_layer) except ValueError: current_path.clear() - return + return False count = len(current_path) line_types = numpy.empty((count-1, 1), numpy.int32) line_types[:, 0] = 1 @@ -150,6 +139,7 @@ class GCODEReader(MeshReader): this_layer.polygons.append(this_poly) current_path.clear() + return True for line in file: if len(line) == 0: @@ -181,8 +171,9 @@ class GCODEReader(MeshReader): else: current_path.append([current_x, current_z, -current_y, 0]) if z_changed: - if len(current_path) > 1: - CreatePolygon() + if len(current_path) > 1 and current_z > 0: + if CreatePolygon(): + current_layer += 1 else: current_path.clear() From 2d2b8601a02fd0b66c4c57364e07c97b6203973d Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 3 Nov 2016 17:14:15 +0600 Subject: [PATCH 26/68] T466: Added progress indicator --- plugins/GCODEReader/GCODEReader.py | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 9346c8cc4f..80d0e45260 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -9,6 +9,10 @@ from UM.Scene.Iterator.DepthFirstIterator import DepthFirstIterator from UM.Math.Vector import Vector from UM.Math.AxisAlignedBox import AxisAlignedBox from UM.Application import Application +from UM.Message import Message + +from UM.i18n import i18nCatalog +catalog = i18nCatalog("cura") from cura import LayerDataBuilder @@ -16,6 +20,7 @@ from cura import LayerDataDecorator from cura import LayerPolygon import numpy +import math class GCODEReader(MeshReader): @@ -92,6 +97,14 @@ class GCODEReader(MeshReader): file = open(file_name, "r") + file_lines = 0 + current_line = 0 + for line in file: + file_lines += 1 + file.seek(0) + + file_step = math.floor(file_lines / 100) + layer_data = LayerDataBuilder.LayerDataBuilder() current_extruder = 1 @@ -102,6 +115,10 @@ class GCODEReader(MeshReader): current_e = 0 current_layer = 0 + message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0, dismissable=False) + message.setProgress(0) + message.show() + def CreatePolygon(): countvalid = False for point in current_path: @@ -142,6 +159,10 @@ class GCODEReader(MeshReader): return True for line in file: + current_line += 1 + if current_line % file_step == 0: + # print(current_line/file_lines*100) + message.setProgress(math.floor(current_line/file_lines*100)) if len(line) == 0: continue if line[0] == ";": @@ -204,6 +225,8 @@ class GCODEReader(MeshReader): decorator.setLayerData(layer_mesh) scene_node.addDecorator(decorator) + message.hide() + Application.getInstance().getPrintInformation()._pre_sliced = True scene_node.parentChanged.connect(self.parent_changed) From 529c47c690f175954717c78bfaec1170d820606b Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sat, 5 Nov 2016 15:39:21 +0600 Subject: [PATCH 27/68] T466: Fixed crash on small files --- plugins/GCODEReader/GCODEReader.py | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 80d0e45260..ba70975a15 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -104,6 +104,7 @@ class GCODEReader(MeshReader): file.seek(0) file_step = math.floor(file_lines / 100) + file_step = 1 if file_step < 1 else file_step layer_data = LayerDataBuilder.LayerDataBuilder() From a8dcdef4dd76191bf1ae2ec54aea9b650a54a8d6 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sat, 5 Nov 2016 15:46:22 +0600 Subject: [PATCH 28/68] T466: Renamed *.g file label --- plugins/GCODEReader/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/GCODEReader/__init__.py b/plugins/GCODEReader/__init__.py index f1572c077f..8c0e493eb6 100644 --- a/plugins/GCODEReader/__init__.py +++ b/plugins/GCODEReader/__init__.py @@ -23,7 +23,7 @@ def getMetaData(): }, { "extension": "g", - "description": i18n_catalog.i18nc("@item:inlistbox", "GCODE File") + "description": i18n_catalog.i18nc("@item:inlistbox", "G File") } ] } From 1932437b07a53e904209c8001869a4c1305421cf Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sat, 5 Nov 2016 16:05:43 +0600 Subject: [PATCH 29/68] T466: Added logging --- plugins/GCODEReader/GCODEReader.py | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index ba70975a15..0a2b6463a5 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -10,6 +10,7 @@ from UM.Math.Vector import Vector from UM.Math.AxisAlignedBox import AxisAlignedBox from UM.Application import Application from UM.Message import Message +from UM.Logger import Logger from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") @@ -78,6 +79,7 @@ class GCODEReader(MeshReader): extension = os.path.splitext(file_name)[1] if extension.lower() in self._supported_extensions: + Logger.log("d", "Preparing to load %s" % file_name) Application.getInstance().deleteAll() scene_node = SceneNode() @@ -95,6 +97,8 @@ class GCODEReader(MeshReader): glist = getattr(Application.getInstance().getController().getScene(), "gcode_list") glist.clear() + Logger.log("d", "Opening file %s" % file_name) + file = open(file_name, "r") file_lines = 0 @@ -120,6 +124,8 @@ class GCODEReader(MeshReader): message.setProgress(0) message.show() + Logger.log("d", "Parsing %s" % file_name) + def CreatePolygon(): countvalid = False for point in current_path: @@ -162,7 +168,6 @@ class GCODEReader(MeshReader): for line in file: current_line += 1 if current_line % file_step == 0: - # print(current_line/file_lines*100) message.setProgress(math.floor(current_line/file_lines*100)) if len(line) == 0: continue @@ -219,15 +224,20 @@ class GCODEReader(MeshReader): current_z += z if len(current_path) > 1: - CreatePolygon() + if CreatePolygon(): + current_layer += 1 layer_mesh = layer_data.build() decorator = LayerDataDecorator.LayerDataDecorator() decorator.setLayerData(layer_mesh) scene_node.addDecorator(decorator) + Logger.log("d", "Finished parsing %s" % file_name) message.hide() + if current_layer == 0: + Logger.log("w", "File %s don't contain any valid layers" % file_name) + Application.getInstance().getPrintInformation()._pre_sliced = True scene_node.parentChanged.connect(self.parent_changed) @@ -247,4 +257,6 @@ class GCODEReader(MeshReader): view.setLayer(999999) view.calculateMaxLayers() + Logger.log("d", "Loaded %s" % file_name) + return scene_node From 0f835a240db181cb9f4a6b94be3635dd6e910f5d Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sat, 5 Nov 2016 16:23:36 +0600 Subject: [PATCH 30/68] T466: Added ability to cancel parsing --- plugins/GCODEReader/GCODEReader.py | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 0a2b6463a5..b8f1f8efa3 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -28,6 +28,9 @@ class GCODEReader(MeshReader): def __init__(self): super(GCODEReader, self).__init__() self._supported_extensions = [".gcode", ".g"] + Application.getInstance().hideMessageSignal.connect(self.onHideMessage) + self.cancelled = False + self.message = None def getInt(self, line, code): n = line.find(code) + 1 @@ -53,6 +56,10 @@ class GCODEReader(MeshReader): except: return None + def onHideMessage(self, m): + if m == self.message: + self.cancelled = True + def parent_changed(self, node): if node.getParent() is None: scene = Application.getInstance().getController().getScene() @@ -80,6 +87,7 @@ class GCODEReader(MeshReader): extension = os.path.splitext(file_name)[1] if extension.lower() in self._supported_extensions: Logger.log("d", "Preparing to load %s" % file_name) + self.cancelled = False Application.getInstance().deleteAll() scene_node = SceneNode() @@ -120,9 +128,9 @@ class GCODEReader(MeshReader): current_e = 0 current_layer = 0 - message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0, dismissable=False) - message.setProgress(0) - message.show() + self.message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0) + self.message.setProgress(0) + self.message.show() Logger.log("d", "Parsing %s" % file_name) @@ -166,9 +174,12 @@ class GCODEReader(MeshReader): return True for line in file: + if self.cancelled: + Logger.log("w", "Parsing %s cancelled" % file_name) + return None current_line += 1 if current_line % file_step == 0: - message.setProgress(math.floor(current_line/file_lines*100)) + self.message.setProgress(math.floor(current_line/file_lines*100)) if len(line) == 0: continue if line[0] == ";": @@ -233,7 +244,7 @@ class GCODEReader(MeshReader): scene_node.addDecorator(decorator) Logger.log("d", "Finished parsing %s" % file_name) - message.hide() + self.message.hide() if current_layer == 0: Logger.log("w", "File %s don't contain any valid layers" % file_name) From 5441f1889c64cb903465f6751963b128f8d6e819 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sat, 5 Nov 2016 16:39:01 +0600 Subject: [PATCH 31/68] T466: Added support of retraction moves --- plugins/GCODEReader/GCODEReader.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index b8f1f8efa3..430c3f6052 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -202,9 +202,9 @@ class GCODEReader(MeshReader): current_z = z if e is not None: if e > current_e: - current_path.append([current_x, current_z, -current_y, 1]) + current_path.append([current_x, current_z, -current_y, 1]) # extrusion else: - current_path.append([current_x, current_z, -current_y, 0]) + current_path.append([current_x, current_z, -current_y, 2]) # retraction current_e = e else: current_path.append([current_x, current_z, -current_y, 0]) From 87eb1e44f4ea001e96177b8c4e31363f706ba8f3 Mon Sep 17 00:00:00 2001 From: nickthetait Date: Tue, 8 Nov 2016 14:15:35 -0700 Subject: [PATCH 32/68] Update labeling for T466 --- cura/PrintInformation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py index 4379ec72ca..442b9ce846 100644 --- a/cura/PrintInformation.py +++ b/cura/PrintInformation.py @@ -135,7 +135,7 @@ class PrintInformation(QObject): base_name = self._stripAccents(base_name) self._setAbbreviatedMachineName() if self._pre_sliced: - return "Pre-sliced_" + base_name + return "Pre-sliced file " + base_name elif Preferences.getInstance().getValue("cura/jobname_prefix"): return self._abbr_machine + "_" + base_name else: From 9120a336023600a22964b982bce195d99d7e3aa9 Mon Sep 17 00:00:00 2001 From: nickthetait Date: Tue, 8 Nov 2016 14:55:28 -0700 Subject: [PATCH 33/68] Improve grammar of a log message T466 --- plugins/GCODEReader/GCODEReader.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCODEReader/GCODEReader.py index 430c3f6052..4e4f4de824 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCODEReader/GCODEReader.py @@ -247,7 +247,7 @@ class GCODEReader(MeshReader): self.message.hide() if current_layer == 0: - Logger.log("w", "File %s don't contain any valid layers" % file_name) + Logger.log("w", "File %s doesn't contain any valid layers" % file_name) Application.getInstance().getPrintInformation()._pre_sliced = True From ec12b901d101aa6b0858e71b15a74c8aec8018c3 Mon Sep 17 00:00:00 2001 From: nickthetait Date: Tue, 8 Nov 2016 15:05:59 -0700 Subject: [PATCH 34/68] Rename to be consistent with other plugins T466 --- .../GCODEReader.py => GCodeReader/GCodeReader.py} | 4 ++-- plugins/{GCODEReader => GCodeReader}/__init__.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) rename plugins/{GCODEReader/GCODEReader.py => GCodeReader/GCodeReader.py} (99%) rename plugins/{GCODEReader => GCodeReader}/__init__.py (91%) diff --git a/plugins/GCODEReader/GCODEReader.py b/plugins/GCodeReader/GCodeReader.py similarity index 99% rename from plugins/GCODEReader/GCODEReader.py rename to plugins/GCodeReader/GCodeReader.py index 4e4f4de824..68dece113e 100644 --- a/plugins/GCODEReader/GCODEReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -24,9 +24,9 @@ import numpy import math -class GCODEReader(MeshReader): +class GCodeReader(MeshReader): def __init__(self): - super(GCODEReader, self).__init__() + super(GCodeReader, self).__init__() self._supported_extensions = [".gcode", ".g"] Application.getInstance().hideMessageSignal.connect(self.onHideMessage) self.cancelled = False diff --git a/plugins/GCODEReader/__init__.py b/plugins/GCodeReader/__init__.py similarity index 91% rename from plugins/GCODEReader/__init__.py rename to plugins/GCodeReader/__init__.py index 8c0e493eb6..2f372f3cd2 100644 --- a/plugins/GCODEReader/__init__.py +++ b/plugins/GCodeReader/__init__.py @@ -2,7 +2,7 @@ # Uranium is released under the terms of the AGPLv3 or higher. #Shoopdawoop -from . import GCODEReader +from . import GCodeReader from UM.i18n import i18nCatalog i18n_catalog = i18nCatalog("uranium") @@ -29,4 +29,4 @@ def getMetaData(): } def register(app): - return { "mesh_reader": GCODEReader.GCODEReader() } + return { "mesh_reader": GCodeReader.GCodeReader() } From 79f54a16f6766339b01f7b980f571555beac560e Mon Sep 17 00:00:00 2001 From: nickthetait Date: Tue, 8 Nov 2016 15:25:58 -0700 Subject: [PATCH 35/68] Update copyright information --- plugins/GCodeReader/GCodeReader.py | 5 ++--- plugins/GCodeReader/__init__.py | 5 ++--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 68dece113e..f084f1d7db 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -1,6 +1,5 @@ -# Copyright (c) 2015 Ultimaker B.V. -# Copyright (c) 2013 David Braam -# Uranium is released under the terms of the AGPLv3 or higher. +# Copyright (c) 2016 Aleph Objects, Inc. +# Cura is released under the terms of the AGPLv3 or higher. from UM.Mesh.MeshReader import MeshReader import os diff --git a/plugins/GCodeReader/__init__.py b/plugins/GCodeReader/__init__.py index 2f372f3cd2..39246072f9 100644 --- a/plugins/GCodeReader/__init__.py +++ b/plugins/GCodeReader/__init__.py @@ -1,7 +1,6 @@ -# Copyright (c) 2015 Ultimaker B.V. -# Uranium is released under the terms of the AGPLv3 or higher. +# Copyright (c) 2016 Aleph Objects, Inc. +# Cura is released under the terms of the AGPLv3 or higher. -#Shoopdawoop from . import GCodeReader from UM.i18n import i18nCatalog From b576e4a7bdf566b5a608e0fb4bbe22784b1ac29f Mon Sep 17 00:00:00 2001 From: nickthetait Date: Tue, 8 Nov 2016 15:27:40 -0700 Subject: [PATCH 36/68] Improve description of plugin for T466 --- plugins/GCodeReader/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/GCodeReader/__init__.py b/plugins/GCodeReader/__init__.py index 39246072f9..4bb3d787bb 100644 --- a/plugins/GCodeReader/__init__.py +++ b/plugins/GCodeReader/__init__.py @@ -12,7 +12,7 @@ def getMetaData(): "name": i18n_catalog.i18nc("@label", "GCODE Reader"), "author": "Victor Larchenko", "version": "1.0", - "description": i18n_catalog.i18nc("@info:whatsthis", "Makes it possbile to read GCODE files."), + "description": i18n_catalog.i18nc("@info:whatsthis", "Allows displaying GCODE files."), "api": 3 }, "mesh_reader": [ From 2b2eec5643dc21e10b949aae2c9c2e5907e97029 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 9 Nov 2016 13:58:47 +0600 Subject: [PATCH 37/68] T466: Removed nested functions --- plugins/GCodeReader/GCodeReader.py | 119 +++++++++++++++-------------- 1 file changed, 60 insertions(+), 59 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index f084f1d7db..8502c044c4 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -31,7 +31,8 @@ class GCodeReader(MeshReader): self.cancelled = False self.message = None - def getInt(self, line, code): + @staticmethod + def getInt(line, code): n = line.find(code) + 1 if n < 1: return None @@ -43,7 +44,8 @@ class GCodeReader(MeshReader): except: return None - def getFloat(self, line, code): + @staticmethod + def getFloat(line, code): n = line.find(code) + 1 if n < 1: return None @@ -59,18 +61,18 @@ class GCodeReader(MeshReader): if m == self.message: self.cancelled = True - def parent_changed(self, node): + @staticmethod + def onParentChanged(node): if node.getParent() is None: scene = Application.getInstance().getController().getScene() - def findAny(): - for node1 in DepthFirstIterator(scene.getRoot()): - if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: - return True - return False + isAny = False + for node1 in DepthFirstIterator(scene.getRoot()): + if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: + isAny = True backend = Application.getInstance().getBackend() - if not findAny(): + if not isAny: backend._pauseSlicing = False Application.getInstance().setHideSettings(False) Application.getInstance().getPrintInformation().setPreSliced(False) @@ -80,6 +82,50 @@ class GCodeReader(MeshReader): Application.getInstance().getPrintInformation().setPreSliced(True) Application.getInstance().setHideSettings(True) + @staticmethod + def getNullBoundingBox(): + return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) + + @staticmethod + def createPolygon(layer_data, path, layer_id, extruder): + countvalid = 0 + for point in path: + if point[3] > 0: + countvalid += 1 + if countvalid < 2: + path.clear() + return False + try: + layer_data.addLayer(layer_id) + layer_data.setLayerHeight(layer_id, path[0][1]) + layer_data.setLayerThickness(layer_id, 0.25) + this_layer = layer_data.getLayer(layer_id) + except ValueError: + path.clear() + return False + count = len(path) + line_types = numpy.empty((count - 1, 1), numpy.int32) + line_types[:, 0] = 1 + line_widths = numpy.empty((count - 1, 1), numpy.int32) + line_widths[:, 0] = 0.5 + points = numpy.empty((count, 3), numpy.float32) + i = 0 + for point in path: + points[i, 0] = point[0] + points[i, 1] = point[1] + points[i, 2] = point[2] + if i > 0: + line_types[i - 1] = point[3] + i += 1 + + this_poly = LayerPolygon.LayerPolygon(layer_data, extruder, line_types, points, line_widths) + this_poly.buildCache() + + this_layer.polygons.append(this_poly) + + path.clear() + return True + def read(self, file_name): scene_node = None @@ -90,11 +136,7 @@ class GCodeReader(MeshReader): Application.getInstance().deleteAll() scene_node = SceneNode() - - def getBoundingBox(): - return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) - - scene_node.getBoundingBox = getBoundingBox + scene_node.getBoundingBox = self.getNullBoundingBox scene_node.gcode = True backend = Application.getInstance().getBackend() backend._pauseSlicing = True @@ -114,9 +156,7 @@ class GCodeReader(MeshReader): file_lines += 1 file.seek(0) - file_step = math.floor(file_lines / 100) - file_step = 1 if file_step < 1 else file_step - + file_step = max(math.floor(file_lines / 100), 1) layer_data = LayerDataBuilder.LayerDataBuilder() current_extruder = 1 @@ -133,45 +173,6 @@ class GCodeReader(MeshReader): Logger.log("d", "Parsing %s" % file_name) - def CreatePolygon(): - countvalid = False - for point in current_path: - if point[3] > 0: - countvalid += 1 - if countvalid < 2: - current_path.clear() - return False - try: - layer_data.addLayer(current_layer) - layer_data.setLayerHeight(current_layer, current_path[0][1]) - layer_data.setLayerThickness(current_layer, 0.25) - this_layer = layer_data.getLayer(current_layer) - except ValueError: - current_path.clear() - return False - count = len(current_path) - line_types = numpy.empty((count-1, 1), numpy.int32) - line_types[:, 0] = 1 - line_widths = numpy.empty((count-1, 1), numpy.int32) - line_widths[:, 0] = 0.5 - points = numpy.empty((count, 3), numpy.float32) - i = 0 - for point in current_path: - points[i, 0] = point[0] - points[i, 1] = point[1] - points[i, 2] = point[2] - if i > 0: - line_types[i-1] = point[3] - i += 1 - - this_poly = LayerPolygon.LayerPolygon(layer_data, current_extruder, line_types, points, line_widths) - this_poly.buildCache() - - this_layer.polygons.append(this_poly) - - current_path.clear() - return True - for line in file: if self.cancelled: Logger.log("w", "Parsing %s cancelled" % file_name) @@ -209,7 +210,7 @@ class GCodeReader(MeshReader): current_path.append([current_x, current_z, -current_y, 0]) if z_changed: if len(current_path) > 1 and current_z > 0: - if CreatePolygon(): + if self.createPolygon(layer_data, current_path, current_layer, current_extruder): current_layer += 1 else: current_path.clear() @@ -234,7 +235,7 @@ class GCodeReader(MeshReader): current_z += z if len(current_path) > 1: - if CreatePolygon(): + if self.createPolygon(layer_data, current_path, current_layer, current_extruder): current_layer += 1 layer_mesh = layer_data.build() @@ -250,7 +251,7 @@ class GCodeReader(MeshReader): Application.getInstance().getPrintInformation()._pre_sliced = True - scene_node.parentChanged.connect(self.parent_changed) + scene_node.parentChanged.connect(self.onParentChanged) scene_node_parent = Application.getInstance().getBuildVolume() scene_node.setParent(scene_node_parent) From be3a945fb029a64976b71e1b55734cfe9f5828a0 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 9 Nov 2016 14:53:23 +0600 Subject: [PATCH 38/68] T466: Fixed Nothing to slice bug --- cura/CuraApplication.py | 11 ++-- .../CuraEngineBackend/CuraEngineBackend.py | 5 +- plugins/GCodeReader/GCodeReader.py | 60 ++++++++----------- 3 files changed, 33 insertions(+), 43 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index dbbbb7e4f8..0a552428af 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -541,13 +541,10 @@ class CuraApplication(QtApplication): def loadFile(self, file): scene = self.getController().getScene() - def findAny(): - for node1 in DepthFirstIterator(scene.getRoot()): - if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: - return True - return False - if findAny(): - self.deleteAll() + for node1 in DepthFirstIterator(scene.getRoot()): + if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: + self.deleteAll() + break if not file.isValid(): return diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index 4e1b2f6841..3737976175 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -152,6 +152,8 @@ class CuraEngineBackend(Backend): ## Perform a slice of the scene. def slice(self): Logger.log("d", "Starting slice job...") + if self._pauseSlicing: + return self._slice_start_time = time() if not self._enabled or not self._global_container_stack: # We shouldn't be slicing. # try again in a short time @@ -395,7 +397,8 @@ class CuraEngineBackend(Backend): ## Manually triggers a reslice def forceSlice(self): - self._change_timer.start() + if not self._pauseSlicing: + self._change_timer.start() ## Called when anything has changed to the stuff that needs to be sliced. # diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 8502c044c4..1fcd615c5e 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -31,6 +31,8 @@ class GCodeReader(MeshReader): self.cancelled = False self.message = None + self.scene_node = None + @staticmethod def getInt(line, code): n = line.find(code) + 1 @@ -61,26 +63,17 @@ class GCodeReader(MeshReader): if m == self.message: self.cancelled = True - @staticmethod - def onParentChanged(node): - if node.getParent() is None: - scene = Application.getInstance().getController().getScene() - - isAny = False - for node1 in DepthFirstIterator(scene.getRoot()): - if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: - isAny = True - - backend = Application.getInstance().getBackend() - if not isAny: - backend._pauseSlicing = False - Application.getInstance().setHideSettings(False) - Application.getInstance().getPrintInformation().setPreSliced(False) - else: - backend._pauseSlicing = True - backend.backendStateChange.emit(3) - Application.getInstance().getPrintInformation().setPreSliced(True) - Application.getInstance().setHideSettings(True) + def onParentChanged(self, node): + backend = Application.getInstance().getBackend() + if self.scene_node is not None and self.scene_node.getParent() is None: + self.scene_node = None + backend._pauseSlicing = False + Application.getInstance().setHideSettings(False) + Application.getInstance().getPrintInformation().setPreSliced(False) + else: + backend._pauseSlicing = True + Application.getInstance().getPrintInformation().setPreSliced(True) + Application.getInstance().setHideSettings(True) @staticmethod def getNullBoundingBox(): @@ -127,21 +120,21 @@ class GCodeReader(MeshReader): return True def read(self, file_name): - scene_node = None - extension = os.path.splitext(file_name)[1] if extension.lower() in self._supported_extensions: Logger.log("d", "Preparing to load %s" % file_name) self.cancelled = False Application.getInstance().deleteAll() - scene_node = SceneNode() - scene_node.getBoundingBox = self.getNullBoundingBox - scene_node.gcode = True + self.scene_node = SceneNode() + self.scene_node.getBoundingBox = self.getNullBoundingBox + self.scene_node.gcode = True + self.scene_node.parentChanged.connect(self.onParentChanged) + backend = Application.getInstance().getBackend() backend._pauseSlicing = True backend.close() - backend.backendStateChange.emit(1) + backend.backendStateChange.emit(3) glist = getattr(Application.getInstance().getController().getScene(), "gcode_list") glist.clear() @@ -241,7 +234,9 @@ class GCodeReader(MeshReader): layer_mesh = layer_data.build() decorator = LayerDataDecorator.LayerDataDecorator() decorator.setLayerData(layer_mesh) - scene_node.addDecorator(decorator) + + self.scene_node.removeDecorator("LayerDataDecorator") + self.scene_node.addDecorator(decorator) Logger.log("d", "Finished parsing %s" % file_name) self.message.hide() @@ -249,18 +244,13 @@ class GCodeReader(MeshReader): if current_layer == 0: Logger.log("w", "File %s doesn't contain any valid layers" % file_name) - Application.getInstance().getPrintInformation()._pre_sliced = True - - scene_node.parentChanged.connect(self.onParentChanged) - - scene_node_parent = Application.getInstance().getBuildVolume() - scene_node.setParent(scene_node_parent) + Application.getInstance().getPrintInformation().setPreSliced(True) settings = Application.getInstance().getGlobalContainerStack() machine_width = settings.getProperty("machine_width", "value") machine_depth = settings.getProperty("machine_depth", "value") - scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) + self.scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) view = Application.getInstance().getController().getActiveView() if view.getPluginId() == "LayerView": @@ -270,4 +260,4 @@ class GCodeReader(MeshReader): Logger.log("d", "Loaded %s" % file_name) - return scene_node + return self.scene_node From 1139b31900c174adb976eadc5662163d182088d2 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 9 Nov 2016 15:02:15 +0600 Subject: [PATCH 39/68] T466: Shortened long filenames --- cura/PrintInformation.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py index 442b9ce846..92aeb17ea0 100644 --- a/cura/PrintInformation.py +++ b/cura/PrintInformation.py @@ -134,6 +134,8 @@ class PrintInformation(QObject): def createJobName(self, base_name): base_name = self._stripAccents(base_name) self._setAbbreviatedMachineName() + if len(base_name) > 100: + base_name = "%s..." % base_name[:100] if self._pre_sliced: return "Pre-sliced file " + base_name elif Preferences.getInstance().getValue("cura/jobname_prefix"): From cb1b9770fd2660437027799d001730d1417abac0 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 9 Nov 2016 15:41:47 +0600 Subject: [PATCH 40/68] T466: Added support of multiextrudion --- plugins/GCodeReader/GCodeReader.py | 39 ++++++++++++++++++++++++------ 1 file changed, 32 insertions(+), 7 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 1fcd615c5e..54af0d5dae 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -80,7 +80,7 @@ class GCodeReader(MeshReader): return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) @staticmethod - def createPolygon(layer_data, path, layer_id, extruder): + def createPolygon(layer_data, path, layer_id, extruder, extruder_offsets): countvalid = 0 for point in path: if point[3] > 0: @@ -104,11 +104,14 @@ class GCodeReader(MeshReader): points = numpy.empty((count, 3), numpy.float32) i = 0 for point in path: - points[i, 0] = point[0] - points[i, 1] = point[1] + points[i, 0] = point[0] + extruder_offsets[extruder]['x'] + points[i, 1] = point[1] + extruder_offsets[extruder]['y'] points[i, 2] = point[2] if i > 0: - line_types[i - 1] = point[3] + if point[3] == 1: + line_types[i - 1] = extruder + 1 + else: + line_types[i - 1] = point[3] i += 1 this_poly = LayerPolygon.LayerPolygon(layer_data, extruder, line_types, points, line_widths) @@ -152,7 +155,8 @@ class GCodeReader(MeshReader): file_step = max(math.floor(file_lines / 100), 1) layer_data = LayerDataBuilder.LayerDataBuilder() - current_extruder = 1 + current_extruder = 0 + extruder_offsets = {0: {'x': 0, 'y': 0}} current_path = [] current_x = 0 current_y = 0 @@ -203,7 +207,7 @@ class GCodeReader(MeshReader): current_path.append([current_x, current_z, -current_y, 0]) if z_changed: if len(current_path) > 1 and current_z > 0: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder): + if self.createPolygon(layer_data, current_path, current_layer, current_extruder, extruder_offsets): current_layer += 1 else: current_path.clear() @@ -226,9 +230,30 @@ class GCodeReader(MeshReader): current_y += y if z is not None: current_z += z + elif G == 10: + x = self.getFloat(line, "X") + y = self.getFloat(line, "Y") + p = self.getInt(line, "P") + if p is not None: + if extruder_offsets.get(p, None) is None: + extruder_offsets[p] = {'x': 0, 'y': 0} + print(p, type(p)) + if x is not None: + extruder_offsets[p]['x'] = x + if y is not None: + extruder_offsets[p]['y'] = y + + T = self.getInt(line, "T") + if T is not None: + current_extruder = T + if len(current_path) > 1 and current_z > 0: + if self.createPolygon(layer_data, current_path, current_layer, current_extruder, extruder_offsets): + current_layer += 1 + else: + current_path.clear() if len(current_path) > 1: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder): + if self.createPolygon(layer_data, current_path, current_layer, current_extruder, extruder_offsets): current_layer += 1 layer_mesh = layer_data.build() From 2948e99fe8988feb0fd036416b2cfc47d4dc3282 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 10 Nov 2016 16:13:26 +0600 Subject: [PATCH 41/68] T466: Removed dual extrusion offsets, the second extruder shown as another color --- plugins/GCodeReader/GCodeReader.py | 25 ++++++------------------- 1 file changed, 6 insertions(+), 19 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 54af0d5dae..cf7d16c5a4 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -80,7 +80,7 @@ class GCodeReader(MeshReader): return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) @staticmethod - def createPolygon(layer_data, path, layer_id, extruder, extruder_offsets): + def createPolygon(layer_data, path, layer_id, extruder): countvalid = 0 for point in path: if point[3] > 0: @@ -104,8 +104,8 @@ class GCodeReader(MeshReader): points = numpy.empty((count, 3), numpy.float32) i = 0 for point in path: - points[i, 0] = point[0] + extruder_offsets[extruder]['x'] - points[i, 1] = point[1] + extruder_offsets[extruder]['y'] + points[i, 0] = point[0] + points[i, 1] = point[1] points[i, 2] = point[2] if i > 0: if point[3] == 1: @@ -156,7 +156,6 @@ class GCodeReader(MeshReader): layer_data = LayerDataBuilder.LayerDataBuilder() current_extruder = 0 - extruder_offsets = {0: {'x': 0, 'y': 0}} current_path = [] current_x = 0 current_y = 0 @@ -207,7 +206,7 @@ class GCodeReader(MeshReader): current_path.append([current_x, current_z, -current_y, 0]) if z_changed: if len(current_path) > 1 and current_z > 0: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder, extruder_offsets): + if self.createPolygon(layer_data, current_path, current_layer, current_extruder): current_layer += 1 else: current_path.clear() @@ -230,30 +229,18 @@ class GCodeReader(MeshReader): current_y += y if z is not None: current_z += z - elif G == 10: - x = self.getFloat(line, "X") - y = self.getFloat(line, "Y") - p = self.getInt(line, "P") - if p is not None: - if extruder_offsets.get(p, None) is None: - extruder_offsets[p] = {'x': 0, 'y': 0} - print(p, type(p)) - if x is not None: - extruder_offsets[p]['x'] = x - if y is not None: - extruder_offsets[p]['y'] = y T = self.getInt(line, "T") if T is not None: current_extruder = T if len(current_path) > 1 and current_z > 0: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder, extruder_offsets): + if self.createPolygon(layer_data, current_path, current_layer, current_extruder): current_layer += 1 else: current_path.clear() if len(current_path) > 1: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder, extruder_offsets): + if self.createPolygon(layer_data, current_path, current_layer, current_extruder): current_layer += 1 layer_mesh = layer_data.build() From ce9251b5a6cb486d3b5620f91f0c5fd8d20f7fb7 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 10 Nov 2016 16:56:45 +0600 Subject: [PATCH 42/68] T466: Fixed show only top layers bug --- plugins/GCodeReader/GCodeReader.py | 2 +- plugins/LayerView/LayerPass.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index cf7d16c5a4..72e97465f4 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -99,7 +99,7 @@ class GCodeReader(MeshReader): count = len(path) line_types = numpy.empty((count - 1, 1), numpy.int32) line_types[:, 0] = 1 - line_widths = numpy.empty((count - 1, 1), numpy.int32) + line_widths = numpy.empty((count - 1, 1), numpy.float32) line_widths[:, 0] = 0.5 points = numpy.empty((count, 3), numpy.float32) i = 0 diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index a8a2b7ba7e..9e610b68d2 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -55,7 +55,7 @@ class LayerPass(RenderPass): continue # Render all layers below a certain number as line mesh instead of vertices. - if self._layerview._current_layer_num - self._layerview._solid_layers > -1 and (not self._layerview._only_show_top_layers or hasattr(node, "gcode")): + if self._layerview._current_layer_num - self._layerview._solid_layers > -1 and not self._layerview._only_show_top_layers: start = 0 end = 0 element_counts = layer_data.getElementCounts() From 1631045d7ab94fca0eb984d7978b8015f4427442 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 22 Nov 2016 15:12:37 +0600 Subject: [PATCH 43/68] D5: Refactoring --- cura/CuraApplication.py | 55 +++++++++++++------ cura/PrintInformation.py | 9 +-- .../CuraEngineBackend/CuraEngineBackend.py | 17 ++++-- .../ProcessSlicedLayersJob.py | 1 + plugins/GCodeReader/GCodeReader.py | 8 +-- plugins/GCodeReader/__init__.py | 8 +-- resources/qml/Cura.qml | 2 +- resources/qml/Menus/ViewMenu.qml | 2 +- resources/qml/SaveButton.qml | 8 +-- resources/qml/Sidebar.qml | 2 +- 10 files changed, 69 insertions(+), 43 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 0a552428af..58dd3d8bc4 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -19,6 +19,7 @@ from UM.SaveFile import SaveFile from UM.Scene.Selection import Selection from UM.Scene.GroupDecorator import GroupDecorator from UM.Settings.Validator import Validator +from UM.Message import Message from UM.Operations.AddSceneNodeOperation import AddSceneNodeOperation from UM.Operations.RemoveSceneNodeOperation import RemoveSceneNodeOperation @@ -32,6 +33,7 @@ from UM.Settings.ContainerRegistry import ContainerRegistry from UM.Settings.SettingFunction import SettingFunction from UM.i18n import i18nCatalog +catalog = i18nCatalog("cura") from . import PlatformPhysics from . import BuildVolume @@ -289,6 +291,8 @@ class CuraApplication(QtApplication): self._recent_files.append(QUrl.fromLocalFile(f)) + self.changeLayerViewSignal.connect(self.changeToLayerView) + def _onEngineCreated(self): self._engine.addImageProvider("camera", CameraImageProvider.CameraImageProvider()) @@ -536,31 +540,45 @@ class CuraApplication(QtApplication): qmlRegisterType(QUrl.fromLocalFile(path), "Cura", 1, 0, type_name) loadingFiles = [] + non_sliceable_extensions = [".gcode", ".g"] + + changeLayerViewSignal = pyqtSignal() + + def changeToLayerView(self): + self.getController().setActiveView("LayerView") @pyqtSlot(QUrl) def loadFile(self, file): scene = self.getController().getScene() - for node1 in DepthFirstIterator(scene.getRoot()): - if hasattr(node1, "gcode") and getattr(node1, "gcode") is True: - self.deleteAll() - break - if not file.isValid(): return - supported_extensions = [".gcode", ".g"] + for node in DepthFirstIterator(scene.getRoot()): + if hasattr(node, "gcode") and getattr(node, "gcode") is True: + self.deleteAll() + break f = file.toLocalFile() extension = os.path.splitext(f)[1] + filename = os.path.basename(f) if len(self.loadingFiles) > 0: - if extension.lower() in supported_extensions: + # If a non-slicable file is already being loaded, we prevent loading of any further non-slicable files + if extension.lower() in self.non_sliceable_extensions: + message = Message( + catalog.i18nc("@info:status", "Only one G-code file can be loaded at a time. Skipped importing {0}", + filename)) + message.show() return + # If file being loaded is non-slicable file, then prevent loading of any other files extension = os.path.splitext(self.loadingFiles[0])[1] - if extension.lower() in supported_extensions: + if extension.lower() in self.non_sliceable_extensions: + message = Message( + catalog.i18nc("@info:status", + "Can't open any other file if G-code is loading. Skipped importing {0}", + filename)) + message.show() return - elif extension.lower() in supported_extensions: - self.getController().setActiveView("LayerView") self.loadingFiles.append(f) @@ -570,11 +588,16 @@ class CuraApplication(QtApplication): def _readMeshFinished(self, job): node = job.getResult() + filename = job.getFileName() + self.loadingFiles.remove(filename) + if node != None: - filename = job.getFileName() node.setSelectable(True) - node.setName(filename) - self.loadingFiles.remove(filename) + node.setName(os.path.basename(filename)) + + extension = os.path.splitext(filename)[1] + if extension.lower() in self.non_sliceable_extensions: + self.changeLayerViewSignal.emit() op = AddSceneNodeOperation(node, self.getController().getScene().getRoot()) op.push() @@ -1056,14 +1079,14 @@ class CuraApplication(QtApplication): _hide_settings = False - HideSettingsChanged = pyqtSignal(bool) + hideSettingsChanged = pyqtSignal(bool) @pyqtSlot(bool) def setHideSettings(self, hide): self._hide_settings = hide - self.HideSettingsChanged.emit(hide) + self.hideSettingsChanged.emit(hide) - @pyqtProperty(bool, notify=HideSettingsChanged) + @pyqtProperty(bool, fset=setHideSettings, notify=hideSettingsChanged) def hideSettings(self): return self._hide_settings diff --git a/cura/PrintInformation.py b/cura/PrintInformation.py index 92aeb17ea0..8fa7c48840 100644 --- a/cura/PrintInformation.py +++ b/cura/PrintInformation.py @@ -13,6 +13,9 @@ import math import os.path import unicodedata +from UM.i18n import i18nCatalog +catalog = i18nCatalog("cura") + ## A class for processing and calculating minimum, current and maximum print time as well as managing the job name # # This class contains all the logic relating to calculation and slicing for the @@ -66,7 +69,7 @@ class PrintInformation(QObject): preSlicedChanged = pyqtSignal() @pyqtProperty(bool, notify=preSlicedChanged) - def isPreSliced(self): + def preSliced(self): return self._pre_sliced def setPreSliced(self, pre_sliced): @@ -134,10 +137,8 @@ class PrintInformation(QObject): def createJobName(self, base_name): base_name = self._stripAccents(base_name) self._setAbbreviatedMachineName() - if len(base_name) > 100: - base_name = "%s..." % base_name[:100] if self._pre_sliced: - return "Pre-sliced file " + base_name + return catalog.i18nc("@label", "Pre-sliced file {0}", base_name) elif Preferences.getInstance().getValue("cura/jobname_prefix"): return self._abbr_machine + "_" + base_name else: diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index 3737976175..5524fd8d7b 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -69,7 +69,7 @@ class CuraEngineBackend(Backend): self._scene = Application.getInstance().getController().getScene() self._scene.sceneChanged.connect(self._onSceneChanged) - self._pauseSlicing = False + self._pause_slicing = False # Workaround to disable layer view processing if layer view is not active. self._layer_view_active = False @@ -116,6 +116,7 @@ class CuraEngineBackend(Backend): self.backendQuit.connect(self._onBackendQuit) self.backendConnected.connect(self._onBackendConnected) + self.backendStateChange.connect(self._onBackendStateChanged) # When a tool operation is in progress, don't slice. So we need to listen for tool operations. Application.getInstance().getController().toolOperationStarted.connect(self._onToolOperationStarted) @@ -152,7 +153,7 @@ class CuraEngineBackend(Backend): ## Perform a slice of the scene. def slice(self): Logger.log("d", "Starting slice job...") - if self._pauseSlicing: + if self._pause_slicing: return self._slice_start_time = time() if not self._enabled or not self._global_container_stack: # We shouldn't be slicing. @@ -187,6 +188,12 @@ class CuraEngineBackend(Backend): self._start_slice_job.start() self._start_slice_job.finished.connect(self._onStartSliceCompleted) + def _onBackendStateChanged(self, state): + if state == BackendState.SlicingDisabled: + self._pause_slicing = True + else: + self._pause_slicing = False + ## Terminate the engine process. def _terminate(self): self._slicing = False @@ -397,15 +404,13 @@ class CuraEngineBackend(Backend): ## Manually triggers a reslice def forceSlice(self): - if not self._pauseSlicing: - self._change_timer.start() + self._change_timer.start() ## Called when anything has changed to the stuff that needs to be sliced. # # This indicates that we should probably re-slice soon. def _onChanged(self, *args, **kwargs): - if not self._pauseSlicing: - self._change_timer.start() + self._change_timer.start() ## Called when the back-end connects to the front-end. def _onBackendConnected(self): diff --git a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py index 490690bd27..c4e9554b2c 100644 --- a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py +++ b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py @@ -60,6 +60,7 @@ class ProcessSlicedLayersJob(Job): for node in DepthFirstIterator(self._scene.getRoot()): if node.callDecoration("getLayerData"): node.getParent().removeChild(node) + break if self._abort_requested: if self._progress: self._progress.hide() diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 72e97465f4..09e5495b94 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -10,6 +10,7 @@ from UM.Math.AxisAlignedBox import AxisAlignedBox from UM.Application import Application from UM.Message import Message from UM.Logger import Logger +from UM.Backend.Backend import BackendState from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") @@ -67,11 +68,11 @@ class GCodeReader(MeshReader): backend = Application.getInstance().getBackend() if self.scene_node is not None and self.scene_node.getParent() is None: self.scene_node = None - backend._pauseSlicing = False + backend.backendStateChange.emit(BackendState.NotStarted) Application.getInstance().setHideSettings(False) Application.getInstance().getPrintInformation().setPreSliced(False) else: - backend._pauseSlicing = True + backend.backendStateChange.emit(BackendState.SlicingDisabled) Application.getInstance().getPrintInformation().setPreSliced(True) Application.getInstance().setHideSettings(True) @@ -135,9 +136,8 @@ class GCodeReader(MeshReader): self.scene_node.parentChanged.connect(self.onParentChanged) backend = Application.getInstance().getBackend() - backend._pauseSlicing = True backend.close() - backend.backendStateChange.emit(3) + backend.backendStateChange.emit(BackendState.SlicingDisabled) glist = getattr(Application.getInstance().getController().getScene(), "gcode_list") glist.clear() diff --git a/plugins/GCodeReader/__init__.py b/plugins/GCodeReader/__init__.py index 4bb3d787bb..7e543d6624 100644 --- a/plugins/GCodeReader/__init__.py +++ b/plugins/GCodeReader/__init__.py @@ -4,21 +4,21 @@ from . import GCodeReader from UM.i18n import i18nCatalog -i18n_catalog = i18nCatalog("uranium") +i18n_catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { - "name": i18n_catalog.i18nc("@label", "GCODE Reader"), + "name": i18n_catalog.i18nc("@label", "G-code Reader"), "author": "Victor Larchenko", "version": "1.0", - "description": i18n_catalog.i18nc("@info:whatsthis", "Allows displaying GCODE files."), + "description": i18n_catalog.i18nc("@info:whatsthis", "Allows loading and displaying G-code files."), "api": 3 }, "mesh_reader": [ { "extension": "gcode", - "description": i18n_catalog.i18nc("@item:inlistbox", "GCODE File") + "description": i18n_catalog.i18nc("@item:inlistbox", "G-code File") }, { "extension": "g", diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml index 4a6a780305..c1fa773816 100644 --- a/resources/qml/Cura.qml +++ b/resources/qml/Cura.qml @@ -412,7 +412,7 @@ UM.MainWindow style: UM.Theme.styles.tool_button; tooltip: ""; - enabled: !PrintInformation.isPreSliced + enabled: !PrintInformation.preSliced menu: ViewMenu { } } diff --git a/resources/qml/Menus/ViewMenu.qml b/resources/qml/Menus/ViewMenu.qml index dc9cbe7501..859620692e 100644 --- a/resources/qml/Menus/ViewMenu.qml +++ b/resources/qml/Menus/ViewMenu.qml @@ -11,7 +11,7 @@ Menu { title: catalog.i18nc("@title:menu menubar:toplevel", "&View"); id: menu - enabled: !PrintInformation.isPreSliced + enabled: !PrintInformation.preSliced Instantiator { model: UM.ViewModel { } diff --git a/resources/qml/SaveButton.qml b/resources/qml/SaveButton.qml index a25aae7a5e..843ac19837 100644 --- a/resources/qml/SaveButton.qml +++ b/resources/qml/SaveButton.qml @@ -14,7 +14,6 @@ Rectangle { property real progress: UM.Backend.progress; property int backendState: UM.Backend.state; - property bool backendPaused: UM.Backend.paused; property bool activity: Printer.getPlatformActivity; property int totalHeight: childrenRect.height + UM.Theme.getSize("default_margin").height property string fileBaseName @@ -25,11 +24,6 @@ Rectangle { return catalog.i18nc("@label:PrintjobStatus", "Please load a 3d model"); } - if (backendPaused) - { - return catalog.i18nc("@label:PrintjobStatus", "Slicing temporary disabled"); - } - switch(base.backendState) { case 1: @@ -40,6 +34,8 @@ Rectangle { return catalog.i18nc("@label:PrintjobStatus %1 is target operation","Ready to %1").arg(UM.OutputDeviceManager.activeDeviceShortDescription); case 4: return catalog.i18nc("@label:PrintjobStatus", "Unable to Slice"); + case 5: + return catalog.i18nc("@label:PrintjobStatus", "Slicing unavailable"); default: return ""; } diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml index 44cad11d09..202bfd070c 100644 --- a/resources/qml/Sidebar.qml +++ b/resources/qml/Sidebar.qml @@ -289,7 +289,7 @@ Rectangle Label { id: settingsModeLabel - text: !hideSettings ? catalog.i18nc("@label:listbox", "Print Setup") : catalog.i18nc("@label:listbox","Not possible to modify slicing settings or re-slice\nwhile a GCODE file is open"); + text: !hideSettings ? catalog.i18nc("@label:listbox", "Print Setup") : catalog.i18nc("@label:listbox","Print Setup disabled\nG-code files cannot be modified"); anchors.left: parent.left anchors.leftMargin: UM.Theme.getSize("default_margin").width; anchors.top: headerSeparator.bottom From cd7979e3019b1bc1c8ca58e68be345bffee470aa Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 22 Nov 2016 16:30:56 +0600 Subject: [PATCH 44/68] D5: Refactoring --- cura/CuraApplication.py | 4 + .../ProcessSlicedLayersJob.py | 1 - plugins/GCodeReader/GCodeReader.py | 202 +++++++++--------- 3 files changed, 102 insertions(+), 105 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 58dd3d8bc4..7cc4be3a9e 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -546,6 +546,10 @@ class CuraApplication(QtApplication): def changeToLayerView(self): self.getController().setActiveView("LayerView") + view = self.getController().getActiveView() + view.resetLayerData() + view.setLayer(999999) + view.calculateMaxLayers() @pyqtSlot(QUrl) def loadFile(self, file): diff --git a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py index c4e9554b2c..490690bd27 100644 --- a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py +++ b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py @@ -60,7 +60,6 @@ class ProcessSlicedLayersJob(Job): for node in DepthFirstIterator(self._scene.getRoot()): if node.callDecoration("getLayerData"): node.getParent().removeChild(node) - break if self._abort_requested: if self._progress: self._progress.hide() diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 09e5495b94..c7b8f806f0 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -18,7 +18,7 @@ catalog = i18nCatalog("cura") from cura import LayerDataBuilder from cura import LayerDataDecorator -from cura import LayerPolygon +from cura.LayerPolygon import LayerPolygon import numpy import math @@ -28,66 +28,66 @@ class GCodeReader(MeshReader): def __init__(self): super(GCodeReader, self).__init__() self._supported_extensions = [".gcode", ".g"] - Application.getInstance().hideMessageSignal.connect(self.onHideMessage) - self.cancelled = False - self.message = None + Application.getInstance().hideMessageSignal.connect(self._onHideMessage) + self._cancelled = False + self._message = None - self.scene_node = None + self._scene_node = None @staticmethod - def getInt(line, code): - n = line.find(code) + 1 + def _getValue(line, code): + n = line.find(code) + len(code) if n < 1: return None m = line.find(' ', n) try: if m < 0: - return int(line[n:]) - return int(line[n:m]) + return line[n:] + return line[n:m] except: return None - @staticmethod - def getFloat(line, code): - n = line.find(code) + 1 - if n < 1: - return None - m = line.find(' ', n) + def _getInt(self, line, code): + value = self._getValue(line, code) try: - if m < 0: - return float(line[n:]) - return float(line[n:m]) + return int(value) except: return None - def onHideMessage(self, m): - if m == self.message: - self.cancelled = True + def _getFloat(self, line, code): + value = self._getValue(line, code) + try: + return float(value) + except: + return None - def onParentChanged(self, node): + def _onHideMessage(self, message): + if message == self._message: + self._cancelled = True + + def _onParentChanged(self, node): backend = Application.getInstance().getBackend() - if self.scene_node is not None and self.scene_node.getParent() is None: - self.scene_node = None + if self._scene_node is not None and self._scene_node.getParent() is None: + self._scene_node = None backend.backendStateChange.emit(BackendState.NotStarted) Application.getInstance().setHideSettings(False) Application.getInstance().getPrintInformation().setPreSliced(False) - else: - backend.backendStateChange.emit(BackendState.SlicingDisabled) - Application.getInstance().getPrintInformation().setPreSliced(True) - Application.getInstance().setHideSettings(True) + # else: + # backend.backendStateChange.emit(BackendState.SlicingDisabled) + # Application.getInstance().getPrintInformation().setPreSliced(True) + # Application.getInstance().setHideSettings(True) @staticmethod - def getNullBoundingBox(): + def _getNullBoundingBox(): return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) @staticmethod - def createPolygon(layer_data, path, layer_id, extruder): + def _createPolygon(layer_data, path, layer_id, extruder): countvalid = 0 for point in path: if point[3] > 0: countvalid += 1 if countvalid < 2: - path.clear() return False try: layer_data.addLayer(layer_id) @@ -95,57 +95,51 @@ class GCodeReader(MeshReader): layer_data.setLayerThickness(layer_id, 0.25) this_layer = layer_data.getLayer(layer_id) except ValueError: - path.clear() return False count = len(path) line_types = numpy.empty((count - 1, 1), numpy.int32) - line_types[:, 0] = 1 line_widths = numpy.empty((count - 1, 1), numpy.float32) line_widths[:, 0] = 0.5 points = numpy.empty((count, 3), numpy.float32) i = 0 for point in path: points[i, 0] = point[0] - points[i, 1] = point[1] - points[i, 2] = point[2] + points[i, 1] = point[2] + points[i, 2] = -point[1] if i > 0: - if point[3] == 1: + if point[3] == LayerPolygon.Inset0Type: line_types[i - 1] = extruder + 1 else: line_types[i - 1] = point[3] i += 1 - this_poly = LayerPolygon.LayerPolygon(layer_data, extruder, line_types, points, line_widths) + this_poly = LayerPolygon(layer_data, extruder, line_types, points, line_widths) this_poly.buildCache() this_layer.polygons.append(this_poly) - - path.clear() return True def read(self, file_name): - extension = os.path.splitext(file_name)[1] - if extension.lower() in self._supported_extensions: - Logger.log("d", "Preparing to load %s" % file_name) - self.cancelled = False - Application.getInstance().deleteAll() + Logger.log("d", "Preparing to load %s" % file_name) + self._cancelled = False - self.scene_node = SceneNode() - self.scene_node.getBoundingBox = self.getNullBoundingBox - self.scene_node.gcode = True - self.scene_node.parentChanged.connect(self.onParentChanged) + self._scene_node = SceneNode() + self._scene_node.getBoundingBox = self._getNullBoundingBox # Manually set bounding box, because mesh doesn't have mesh data + self._scene_node.gcode = True + self._scene_node.parentChanged.connect(self._onParentChanged) - backend = Application.getInstance().getBackend() - backend.close() - backend.backendStateChange.emit(BackendState.SlicingDisabled) + backend = Application.getInstance().getBackend() + backend.close() + backend.backendStateChange.emit(BackendState.SlicingDisabled) - glist = getattr(Application.getInstance().getController().getScene(), "gcode_list") - glist.clear() + glist = [] + Application.getInstance().getController().getScene().gcode_list = glist - Logger.log("d", "Opening file %s" % file_name) + Logger.log("d", "Opening file %s" % file_name) - file = open(file_name, "r") + layer_data_builder = LayerDataBuilder.LayerDataBuilder() + with open(file_name, "r") as file: file_lines = 0 current_line = 0 for line in file: @@ -153,7 +147,6 @@ class GCodeReader(MeshReader): file.seek(0) file_step = max(math.floor(file_lines / 100), 1) - layer_data = LayerDataBuilder.LayerDataBuilder() current_extruder = 0 current_path = [] @@ -163,30 +156,30 @@ class GCodeReader(MeshReader): current_e = 0 current_layer = 0 - self.message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0) - self.message.setProgress(0) - self.message.show() + self._message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0) + self._message.setProgress(0) + self._message.show() Logger.log("d", "Parsing %s" % file_name) for line in file: - if self.cancelled: + if self._cancelled: Logger.log("w", "Parsing %s cancelled" % file_name) return None current_line += 1 if current_line % file_step == 0: - self.message.setProgress(math.floor(current_line/file_lines*100)) + self._message.setProgress(math.floor(current_line / file_lines * 100)) if len(line) == 0: continue if line[0] == ";": continue - G = self.getInt(line, "G") + G = self._getInt(line, "G") if G is not None: if G == 0 or G == 1: - x = self.getFloat(line, "X") - y = self.getFloat(line, "Y") - z = self.getFloat(line, "Z") - e = self.getFloat(line, "E") + x = self._getFloat(line, "X") + y = self._getFloat(line, "Y") + z = self._getFloat(line, "Z") + e = self._getFloat(line, "E") z_changed = False if x is not None: current_x = x @@ -198,78 +191,79 @@ class GCodeReader(MeshReader): current_z = z if e is not None: if e > current_e: - current_path.append([current_x, current_z, -current_y, 1]) # extrusion + current_path.append([current_x, current_y, current_z, LayerPolygon.Inset0Type]) # extrusion else: - current_path.append([current_x, current_z, -current_y, 2]) # retraction + current_path.append([current_x, current_y, current_z, LayerPolygon.MoveRetractionType]) # retraction current_e = e else: - current_path.append([current_x, current_z, -current_y, 0]) + current_path.append([current_x, current_y, current_z, LayerPolygon.NoneType]) if z_changed: if len(current_path) > 1 and current_z > 0: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder): + if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder): current_layer += 1 + current_path.clear() else: current_path.clear() elif G == 28: - x = self.getFloat(line, "X") - y = self.getFloat(line, "Y") + x = self._getFloat(line, "X") + y = self._getFloat(line, "Y") if x is not None: current_x = x if y is not None: current_y = y current_z = 0 elif G == 92: - x = self.getFloat(line, "X") - y = self.getFloat(line, "Y") - z = self.getFloat(line, "Z") + x = self._getFloat(line, "X") + y = self._getFloat(line, "Y") + z = self._getFloat(line, "Z") + e = self._getFloat(line, "E") if x is not None: - current_x += x + current_x = x if y is not None: - current_y += y + current_y = y if z is not None: - current_z += z + current_z = z + if e is not None: + current_e = e - T = self.getInt(line, "T") + T = self._getInt(line, "T") if T is not None: current_extruder = T if len(current_path) > 1 and current_z > 0: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder): + if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder): current_layer += 1 + current_path.clear() else: current_path.clear() - if len(current_path) > 1: - if self.createPolygon(layer_data, current_path, current_layer, current_extruder): + if len(current_path) > 1 and current_z > 0: + if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder): current_layer += 1 + current_path.clear() - layer_mesh = layer_data.build() - decorator = LayerDataDecorator.LayerDataDecorator() - decorator.setLayerData(layer_mesh) + layer_mesh = layer_data_builder.build() + decorator = LayerDataDecorator.LayerDataDecorator() + decorator.setLayerData(layer_mesh) - self.scene_node.removeDecorator("LayerDataDecorator") - self.scene_node.addDecorator(decorator) + self._scene_node.removeDecorator("LayerDataDecorator") + self._scene_node.addDecorator(decorator) - Logger.log("d", "Finished parsing %s" % file_name) - self.message.hide() + Logger.log("d", "Finished parsing %s" % file_name) + self._message.hide() - if current_layer == 0: - Logger.log("w", "File %s doesn't contain any valid layers" % file_name) + if current_layer == 0: + Logger.log("w", "File %s doesn't contain any valid layers" % file_name) - Application.getInstance().getPrintInformation().setPreSliced(True) + Application.getInstance().getPrintInformation().setPreSliced(True) + Application.getInstance().setHideSettings(True) - settings = Application.getInstance().getGlobalContainerStack() - machine_width = settings.getProperty("machine_width", "value") - machine_depth = settings.getProperty("machine_depth", "value") + settings = Application.getInstance().getGlobalContainerStack() + machine_width = settings.getProperty("machine_width", "value") + machine_depth = settings.getProperty("machine_depth", "value") - self.scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) + self._scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) - view = Application.getInstance().getController().getActiveView() - if view.getPluginId() == "LayerView": - view.resetLayerData() - view.setLayer(999999) - view.calculateMaxLayers() + Logger.log("d", "Loaded %s" % file_name) - Logger.log("d", "Loaded %s" % file_name) - - return self.scene_node + return self._scene_node From c18b3149da3a344fc4d77e269752353b651f1718 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 23 Nov 2016 11:32:18 +0600 Subject: [PATCH 45/68] D5: Moved loading files code --- cura/CuraApplication.py | 60 ------------------- .../CuraEngineBackend/CuraEngineBackend.py | 7 +++ plugins/GCodeReader/GCodeReader.py | 30 +++++----- resources/qml/Cura.qml | 4 +- resources/qml/Menus/RecentFilesMenu.qml | 2 +- 5 files changed, 24 insertions(+), 79 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 7cc4be3a9e..44a1f4d8a0 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -539,9 +539,6 @@ class CuraApplication(QtApplication): qmlRegisterType(QUrl.fromLocalFile(path), "Cura", 1, 0, type_name) - loadingFiles = [] - non_sliceable_extensions = [".gcode", ".g"] - changeLayerViewSignal = pyqtSignal() def changeToLayerView(self): @@ -551,63 +548,6 @@ class CuraApplication(QtApplication): view.setLayer(999999) view.calculateMaxLayers() - @pyqtSlot(QUrl) - def loadFile(self, file): - scene = self.getController().getScene() - - if not file.isValid(): - return - - for node in DepthFirstIterator(scene.getRoot()): - if hasattr(node, "gcode") and getattr(node, "gcode") is True: - self.deleteAll() - break - - f = file.toLocalFile() - extension = os.path.splitext(f)[1] - filename = os.path.basename(f) - if len(self.loadingFiles) > 0: - # If a non-slicable file is already being loaded, we prevent loading of any further non-slicable files - if extension.lower() in self.non_sliceable_extensions: - message = Message( - catalog.i18nc("@info:status", "Only one G-code file can be loaded at a time. Skipped importing {0}", - filename)) - message.show() - return - # If file being loaded is non-slicable file, then prevent loading of any other files - extension = os.path.splitext(self.loadingFiles[0])[1] - if extension.lower() in self.non_sliceable_extensions: - message = Message( - catalog.i18nc("@info:status", - "Can't open any other file if G-code is loading. Skipped importing {0}", - filename)) - message.show() - return - - self.loadingFiles.append(f) - - job = ReadMeshJob(f) - job.finished.connect(self._readMeshFinished) - job.start() - - def _readMeshFinished(self, job): - node = job.getResult() - filename = job.getFileName() - self.loadingFiles.remove(filename) - - if node != None: - node.setSelectable(True) - node.setName(os.path.basename(filename)) - - extension = os.path.splitext(filename)[1] - if extension.lower() in self.non_sliceable_extensions: - self.changeLayerViewSignal.emit() - - op = AddSceneNodeOperation(node, self.getController().getScene().getRoot()) - op.push() - - self.getController().getScene().sceneChanged.emit(node) - def onSelectionChanged(self): if Selection.hasSelection(): if self.getController().getActiveTool(): diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index 5524fd8d7b..31e35aa778 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -188,6 +188,13 @@ class CuraEngineBackend(Backend): self._start_slice_job.start() self._start_slice_job.finished.connect(self._onStartSliceCompleted) + def pauseSlicing(self): + self.close() + self.backendStateChange.emit(BackendState.SlicingDisabled) + + def continueSlicing(self): + self.backendStateChange.emit(BackendState.NotStarted) + def _onBackendStateChanged(self, state): if state == BackendState.SlicingDisabled: self._pause_slicing = True diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index c7b8f806f0..66a2dfa6b6 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -22,6 +22,7 @@ from cura.LayerPolygon import LayerPolygon import numpy import math +import re class GCodeReader(MeshReader): @@ -39,7 +40,9 @@ class GCodeReader(MeshReader): n = line.find(code) + len(code) if n < 1: return None - m = line.find(' ', n) + pattern = re.compile("[;\s]") + match = pattern.search(line, n) + m = match.start() if math is not None else -1 try: if m < 0: return line[n:] @@ -66,23 +69,18 @@ class GCodeReader(MeshReader): self._cancelled = True def _onParentChanged(self, node): - backend = Application.getInstance().getBackend() if self._scene_node is not None and self._scene_node.getParent() is None: self._scene_node = None - backend.backendStateChange.emit(BackendState.NotStarted) + Application.getInstance().getBackend().continueSlicing() Application.getInstance().setHideSettings(False) Application.getInstance().getPrintInformation().setPreSliced(False) - # else: - # backend.backendStateChange.emit(BackendState.SlicingDisabled) - # Application.getInstance().getPrintInformation().setPreSliced(True) - # Application.getInstance().setHideSettings(True) @staticmethod def _getNullBoundingBox(): return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) @staticmethod - def _createPolygon(layer_data, path, layer_id, extruder): + def _createPolygon(layer_data, path, layer_id, extruder, thickness): countvalid = 0 for point in path: if point[3] > 0: @@ -92,7 +90,7 @@ class GCodeReader(MeshReader): try: layer_data.addLayer(layer_id) layer_data.setLayerHeight(layer_id, path[0][1]) - layer_data.setLayerThickness(layer_id, 0.25) + layer_data.setLayerThickness(layer_id, thickness) this_layer = layer_data.getLayer(layer_id) except ValueError: return False @@ -128,9 +126,7 @@ class GCodeReader(MeshReader): self._scene_node.gcode = True self._scene_node.parentChanged.connect(self._onParentChanged) - backend = Application.getInstance().getBackend() - backend.close() - backend.backendStateChange.emit(BackendState.SlicingDisabled) + Application.getInstance().getBackend().pauseSlicing() glist = [] Application.getInstance().getController().getScene().gcode_list = glist @@ -155,6 +151,7 @@ class GCodeReader(MeshReader): current_z = 0 current_e = 0 current_layer = 0 + prev_z = 0 self._message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0) self._message.setProgress(0) @@ -188,6 +185,7 @@ class GCodeReader(MeshReader): if z is not None: if not current_z == z: z_changed = True + prev_z = current_z current_z = z if e is not None: if e > current_e: @@ -196,10 +194,10 @@ class GCodeReader(MeshReader): current_path.append([current_x, current_y, current_z, LayerPolygon.MoveRetractionType]) # retraction current_e = e else: - current_path.append([current_x, current_y, current_z, LayerPolygon.NoneType]) + current_path.append([current_x, current_y, current_z, LayerPolygon.MoveCombingType]) if z_changed: if len(current_path) > 1 and current_z > 0: - if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder): + if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder, math.fabs(current_z - prev_z)): current_layer += 1 current_path.clear() else: @@ -231,14 +229,14 @@ class GCodeReader(MeshReader): if T is not None: current_extruder = T if len(current_path) > 1 and current_z > 0: - if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder): + if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder, math.fabs(current_z - prev_z)): current_layer += 1 current_path.clear() else: current_path.clear() if len(current_path) > 1 and current_z > 0: - if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder): + if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder, math.fabs(current_z - prev_z)): current_layer += 1 current_path.clear() diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml index c1fa773816..8eb3cf850e 100644 --- a/resources/qml/Cura.qml +++ b/resources/qml/Cura.qml @@ -275,7 +275,7 @@ UM.MainWindow // There is no endsWith in this version of JS... if ((drop.urls[i].length <= 12) || (drop.urls[i].substring(drop.urls[i].length-12) !== ".curaprofile")) { // Drop an object - Printer.loadFile(drop.urls[i]); + UM.MeshFileHandler.readLocalFile(drop.urls[i]); if (imported_model == -1) { imported_model = i; @@ -737,7 +737,7 @@ UM.MainWindow for(var i in fileUrls) { - Printer.loadFile(fileUrls[i]) + UM.MeshFileHandler.readLocalFile(fileUrls[i]) } var meshName = backgroundItem.getMeshName(fileUrls[0].toString()) diff --git a/resources/qml/Menus/RecentFilesMenu.qml b/resources/qml/Menus/RecentFilesMenu.qml index 4453be6887..c47fc5715b 100644 --- a/resources/qml/Menus/RecentFilesMenu.qml +++ b/resources/qml/Menus/RecentFilesMenu.qml @@ -26,7 +26,7 @@ Menu return (index + 1) + ". " + path.slice(path.lastIndexOf("/") + 1); } onTriggered: { - Printer.loadFile(modelData); + UM.MeshFileHandler.readLocalFile(modelData); var meshName = backgroundItem.getMeshName(modelData.toString()) backgroundItem.hasMesh(decodeURIComponent(meshName)) } From 897f01150b016a3b27a5f1a56290f9b68fd7fa91 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 23 Nov 2016 11:37:57 +0600 Subject: [PATCH 46/68] D5: Added class documentation --- plugins/GCodeReader/GCodeReader.py | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 66a2dfa6b6..2583634354 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -25,6 +25,7 @@ import math import re +# Class for loading and parsing G-code files class GCodeReader(MeshReader): def __init__(self): super(GCodeReader, self).__init__() From a795323e5ffe63f69731d6bf2dc4487f5c093309 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 24 Nov 2016 14:30:49 +0600 Subject: [PATCH 47/68] D5: Added cura-generated gcode coloring --- plugins/GCodeReader/GCodeReader.py | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 2583634354..a147603892 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -98,6 +98,7 @@ class GCodeReader(MeshReader): count = len(path) line_types = numpy.empty((count - 1, 1), numpy.int32) line_widths = numpy.empty((count - 1, 1), numpy.float32) + # TODO: need to calculate actual line width based on E values line_widths[:, 0] = 0.5 points = numpy.empty((count, 3), numpy.float32) i = 0 @@ -151,6 +152,7 @@ class GCodeReader(MeshReader): current_y = 0 current_z = 0 current_e = 0 + current_block = LayerPolygon.Inset0Type current_layer = 0 prev_z = 0 @@ -169,6 +171,20 @@ class GCodeReader(MeshReader): self._message.setProgress(math.floor(current_line / file_lines * 100)) if len(line) == 0: continue + if line.find(";TYPE:") == 0: + type = line[6:].strip() + if type == "WALL-INNER": + current_block = LayerPolygon.InsetXType + elif type == "WALL-OUTER": + current_block = LayerPolygon.Inset0Type + elif type == "SKIN": + current_block = LayerPolygon.SkinType + elif type == "SKIRT": + current_block = LayerPolygon.SkirtType + elif type == "SUPPORT": + current_block = LayerPolygon.SupportType + elif type == "FILL": + current_block = LayerPolygon.InfillType if line[0] == ";": continue G = self._getInt(line, "G") @@ -190,7 +206,7 @@ class GCodeReader(MeshReader): current_z = z if e is not None: if e > current_e: - current_path.append([current_x, current_y, current_z, LayerPolygon.Inset0Type]) # extrusion + current_path.append([current_x, current_y, current_z, current_block]) # extrusion else: current_path.append([current_x, current_y, current_z, LayerPolygon.MoveRetractionType]) # retraction current_e = e From 002b3139e64c6dba87138070094c86e53293d6b7 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 24 Nov 2016 14:31:48 +0600 Subject: [PATCH 48/68] D5: Fixed dual extrusion colors --- plugins/GCodeReader/GCodeReader.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index a147603892..af3536c6f1 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -107,10 +107,7 @@ class GCodeReader(MeshReader): points[i, 1] = point[2] points[i, 2] = -point[1] if i > 0: - if point[3] == LayerPolygon.Inset0Type: - line_types[i - 1] = extruder + 1 - else: - line_types[i - 1] = point[3] + line_types[i - 1] = point[3] i += 1 this_poly = LayerPolygon(layer_data, extruder, line_types, points, line_widths) From 4aa59950ca438e9a93788e9144321c89abbe8da8 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Sun, 27 Nov 2016 14:05:25 +0600 Subject: [PATCH 49/68] D5: Added decorator --- cura/CuraApplication.py | 17 ++++++++-- plugins/3MFReader/ThreeMFReader.py | 5 ++- .../CuraEngineBackend/CuraEngineBackend.py | 6 +++- .../ProcessSlicedLayersJob.py | 1 + plugins/GCodeReader/GCodeReader.py | 32 ++++++------------- plugins/LayerView/LayerPass.py | 2 +- plugins/X3DReader/X3DReader.py | 3 ++ 7 files changed, 39 insertions(+), 27 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 44a1f4d8a0..4e611cf680 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -593,9 +593,12 @@ class CuraApplication(QtApplication): def updatePlatformActivity(self, node = None): count = 0 scene_bounding_box = None + should_pause = False for node in DepthFirstIterator(self.getController().getScene().getRoot()): - if type(node) is not SceneNode or (not node.getMeshData() and not hasattr(node, "gcode")): + if type(node) is not SceneNode or (not node.getMeshData() and not node.callDecoration("shouldBlockSlicing")): continue + if node.callDecoration("shouldBlockSlicing"): + should_pause = True count += 1 if not scene_bounding_box: @@ -605,6 +608,16 @@ class CuraApplication(QtApplication): if other_bb is not None: scene_bounding_box = scene_bounding_box + node.getBoundingBox() + if not should_pause: + self.getBackend().continueSlicing() + self.setHideSettings(False) + if self.getPrintInformation(): + self.getPrintInformation().setPreSliced(False) + else: + self.getBackend().pauseSlicing() + self.setHideSettings(True) + self.getPrintInformation().setPreSliced(True) + if not scene_bounding_box: scene_bounding_box = AxisAlignedBox.Null @@ -725,7 +738,7 @@ class CuraApplication(QtApplication): for node in DepthFirstIterator(self.getController().getScene().getRoot()): if type(node) is not SceneNode: continue - if (not node.getMeshData() and not hasattr(node, "gcode")) and not node.callDecoration("isGroup"): + if (not node.getMeshData() and node.callDecoration("isSliceable")) and not node.callDecoration("isGroup"): continue # Node that doesnt have a mesh and is not a group. if node.getParent() and node.getParent().callDecoration("isGroup"): continue # Grouped nodes don't need resetting as their parent (the group) is resetted) diff --git a/plugins/3MFReader/ThreeMFReader.py b/plugins/3MFReader/ThreeMFReader.py index 397a63c194..97134bf676 100644 --- a/plugins/3MFReader/ThreeMFReader.py +++ b/plugins/3MFReader/ThreeMFReader.py @@ -14,6 +14,7 @@ from cura.Settings.SettingOverrideDecorator import SettingOverrideDecorator from UM.Application import Application from cura.Settings.ExtruderManager import ExtruderManager from cura.QualityManager import QualityManager +from UM.Scene.SliceableObjectDecorator import SliceableObjectDecorator import os.path import zipfile @@ -234,6 +235,8 @@ class ThreeMFReader(MeshReader): except Exception as e: Logger.log("e", "An exception occurred in 3mf reader: %s", e) + sliceable_decorator = SliceableObjectDecorator() + result.addDecorator(sliceable_decorator) return result ## Create a scale vector based on a unit string. @@ -263,4 +266,4 @@ class ThreeMFReader(MeshReader): Logger.log("w", "Unrecognised unit %s used. Assuming mm instead", unit) scale = 1 - return Vector(scale, scale, scale) \ No newline at end of file + return Vector(scale, scale, scale) diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index 31e35aa778..b77b5da5bd 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -188,14 +188,18 @@ class CuraEngineBackend(Backend): self._start_slice_job.start() self._start_slice_job.finished.connect(self._onStartSliceCompleted) + _last_state = BackendState.NotStarted + def pauseSlicing(self): self.close() self.backendStateChange.emit(BackendState.SlicingDisabled) def continueSlicing(self): - self.backendStateChange.emit(BackendState.NotStarted) + if self._last_state == BackendState.SlicingDisabled: + self.backendStateChange.emit(BackendState.NotStarted) def _onBackendStateChanged(self, state): + self._last_state = state if state == BackendState.SlicingDisabled: self._pause_slicing = True else: diff --git a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py index 490690bd27..c4e9554b2c 100644 --- a/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py +++ b/plugins/CuraEngineBackend/ProcessSlicedLayersJob.py @@ -60,6 +60,7 @@ class ProcessSlicedLayersJob(Job): for node in DepthFirstIterator(self._scene.getRoot()): if node.callDecoration("getLayerData"): node.getParent().removeChild(node) + break if self._abort_requested: if self._progress: self._progress.hide() diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index af3536c6f1..461f4f70b3 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -19,6 +19,7 @@ catalog = i18nCatalog("cura") from cura import LayerDataBuilder from cura import LayerDataDecorator from cura.LayerPolygon import LayerPolygon +from UM.Scene.SliceableObjectDecorator import SliceableObjectDecorator import numpy import math @@ -34,8 +35,6 @@ class GCodeReader(MeshReader): self._cancelled = False self._message = None - self._scene_node = None - @staticmethod def _getValue(line, code): n = line.find(code) + len(code) @@ -69,13 +68,6 @@ class GCodeReader(MeshReader): if message == self._message: self._cancelled = True - def _onParentChanged(self, node): - if self._scene_node is not None and self._scene_node.getParent() is None: - self._scene_node = None - Application.getInstance().getBackend().continueSlicing() - Application.getInstance().setHideSettings(False) - Application.getInstance().getPrintInformation().setPreSliced(False) - @staticmethod def _getNullBoundingBox(): return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) @@ -120,12 +112,8 @@ class GCodeReader(MeshReader): Logger.log("d", "Preparing to load %s" % file_name) self._cancelled = False - self._scene_node = SceneNode() - self._scene_node.getBoundingBox = self._getNullBoundingBox # Manually set bounding box, because mesh doesn't have mesh data - self._scene_node.gcode = True - self._scene_node.parentChanged.connect(self._onParentChanged) - - Application.getInstance().getBackend().pauseSlicing() + scene_node = SceneNode() + scene_node.getBoundingBox = self._getNullBoundingBox # Manually set bounding box, because mesh doesn't have mesh data glist = [] Application.getInstance().getController().getScene().gcode_list = glist @@ -257,9 +245,12 @@ class GCodeReader(MeshReader): layer_mesh = layer_data_builder.build() decorator = LayerDataDecorator.LayerDataDecorator() decorator.setLayerData(layer_mesh) + scene_node.addDecorator(decorator) - self._scene_node.removeDecorator("LayerDataDecorator") - self._scene_node.addDecorator(decorator) + sliceable_decorator = SliceableObjectDecorator() + sliceable_decorator.setBlockSlicing(True) + sliceable_decorator.setSliceable(False) + scene_node.addDecorator(sliceable_decorator) Logger.log("d", "Finished parsing %s" % file_name) self._message.hide() @@ -267,15 +258,12 @@ class GCodeReader(MeshReader): if current_layer == 0: Logger.log("w", "File %s doesn't contain any valid layers" % file_name) - Application.getInstance().getPrintInformation().setPreSliced(True) - Application.getInstance().setHideSettings(True) - settings = Application.getInstance().getGlobalContainerStack() machine_width = settings.getProperty("machine_width", "value") machine_depth = settings.getProperty("machine_depth", "value") - self._scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) + scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) Logger.log("d", "Loaded %s" % file_name) - return self._scene_node + return scene_node diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index 9e610b68d2..ca895619a3 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -49,7 +49,7 @@ class LayerPass(RenderPass): if isinstance(node, ToolHandle): tool_handle_batch.addItem(node.getWorldTransformation(), mesh = node.getSolidMesh()) - elif isinstance(node, SceneNode) and (node.getMeshData() or hasattr(node, "gcode")) and node.isVisible(): + elif isinstance(node, SceneNode) and (node.getMeshData() or not node.callDecoration("isSliceable")) and node.isVisible(): layer_data = node.callDecoration("getLayerData") if not layer_data: continue diff --git a/plugins/X3DReader/X3DReader.py b/plugins/X3DReader/X3DReader.py index ba31c9ea86..16b8a6a5ae 100644 --- a/plugins/X3DReader/X3DReader.py +++ b/plugins/X3DReader/X3DReader.py @@ -10,6 +10,7 @@ from UM.Scene.SceneNode import SceneNode from UM.Job import Job from math import pi, sin, cos, sqrt import numpy +from UM.Scene.SliceableObjectDecorator import SliceableObjectDecorator try: import xml.etree.cElementTree as ET @@ -96,6 +97,8 @@ class X3DReader(MeshReader): Logger.logException("e", "Exception in X3D reader") return None + sliceable_decorator = SliceableObjectDecorator() + node.addDecorator(sliceable_decorator) return node # ------------------------- XML tree traversal From e6ebd225d37b3d2b4a3421c86cb9a6742eef9886 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Mon, 28 Nov 2016 14:24:19 +0600 Subject: [PATCH 50/68] D5: Added support of printers with center is zero parameter --- plugins/GCodeReader/GCodeReader.py | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 461f4f70b3..3de7f1f5e0 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -140,6 +140,7 @@ class GCodeReader(MeshReader): current_block = LayerPolygon.Inset0Type current_layer = 0 prev_z = 0 + center_is_zero = False self._message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0) self._message.setProgress(0) @@ -173,11 +174,15 @@ class GCodeReader(MeshReader): if line[0] == ";": continue G = self._getInt(line, "G") + x = self._getFloat(line, "X") + y = self._getFloat(line, "Y") + z = self._getFloat(line, "Z") + if x is not None and x < 0: + center_is_zero = True + if y is not None and y < 0: + center_is_zero = True if G is not None: if G == 0 or G == 1: - x = self._getFloat(line, "X") - y = self._getFloat(line, "Y") - z = self._getFloat(line, "Z") e = self._getFloat(line, "E") z_changed = False if x is not None: @@ -206,17 +211,12 @@ class GCodeReader(MeshReader): current_path.clear() elif G == 28: - x = self._getFloat(line, "X") - y = self._getFloat(line, "Y") if x is not None: current_x = x if y is not None: current_y = y current_z = 0 elif G == 92: - x = self._getFloat(line, "X") - y = self._getFloat(line, "Y") - z = self._getFloat(line, "Z") e = self._getFloat(line, "E") if x is not None: current_x = x @@ -262,7 +262,8 @@ class GCodeReader(MeshReader): machine_width = settings.getProperty("machine_width", "value") machine_depth = settings.getProperty("machine_depth", "value") - scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) + if not center_is_zero: + scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) Logger.log("d", "Loaded %s" % file_name) From 60eb83d9205f09df5a4dd64e6a399e6b70cc8658 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 30 Nov 2016 12:02:21 +0600 Subject: [PATCH 51/68] D5: Refactored main cycle --- plugins/GCodeReader/GCodeReader.py | 194 ++++++++++++++++------------- 1 file changed, 104 insertions(+), 90 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 3de7f1f5e0..dc91af756c 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -34,6 +34,16 @@ class GCodeReader(MeshReader): Application.getInstance().hideMessageSignal.connect(self._onHideMessage) self._cancelled = False self._message = None + self._clearValues() + self._scene_node = None + + def _clearValues(self): + self._extruder = 0 + self._layer_type = LayerPolygon.Inset0Type + self._layer = 0 + self._prev_z = 0 + self._layer_data_builder = LayerDataBuilder.LayerDataBuilder() + self._center_is_zero = False @staticmethod def _getValue(line, code): @@ -72,8 +82,7 @@ class GCodeReader(MeshReader): def _getNullBoundingBox(): return AxisAlignedBox(minimum=Vector(0, 0, 0), maximum=Vector(10, 10, 10)) - @staticmethod - def _createPolygon(layer_data, path, layer_id, extruder, thickness): + def _createPolygon(self, current_z, path): countvalid = 0 for point in path: if point[3] > 0: @@ -81,10 +90,10 @@ class GCodeReader(MeshReader): if countvalid < 2: return False try: - layer_data.addLayer(layer_id) - layer_data.setLayerHeight(layer_id, path[0][1]) - layer_data.setLayerThickness(layer_id, thickness) - this_layer = layer_data.getLayer(layer_id) + self._layer_data_builder.addLayer(self._layer) + self._layer_data_builder.setLayerHeight(self._layer, path[0][1]) + self._layer_data_builder.setLayerThickness(self._layer, math.fabs(current_z - self._prev_z)) + this_layer = self._layer_data_builder.getLayer(self._layer) except ValueError: return False count = len(path) @@ -102,12 +111,81 @@ class GCodeReader(MeshReader): line_types[i - 1] = point[3] i += 1 - this_poly = LayerPolygon(layer_data, extruder, line_types, points, line_widths) + this_poly = LayerPolygon(self._layer_data_builder, self._extruder, line_types, points, line_widths) this_poly.buildCache() this_layer.polygons.append(this_poly) return True + def _gCode0(self, position, params, path): + x, y, z, e = position + xp, yp, zp, ep = params + x, y = xp if xp is not None else x, yp if yp is not None else y + z_changed = False + if zp is not None: + if z != zp: + z_changed = True + self._prev_z = z + z = zp + if ep is not None: + if ep > e: + path.append([x, y, z, self._layer_type]) # extrusion + else: + path.append([x, y, z, LayerPolygon.MoveRetractionType]) # retraction + e = ep + else: + path.append([x, y, z, LayerPolygon.MoveCombingType]) + if z_changed: + if len(path) > 1 and z > 0: + if self._createPolygon(z, path): + self._layer += 1 + path.clear() + else: + path.clear() + return x, y, z, e + + def _gCode28(self, position, params, path): + x, y, z, e = position + xp, yp, zp, ep = params + return xp if xp is not None else x,\ + yp if yp is not None else y,\ + 0,\ + e + + def _gCode92(self, position, params, path): + x, y, z, e = position + xp, yp, zp, ep = params + return xp if xp is not None else x,\ + yp if yp is not None else y,\ + zp if zp is not None else z,\ + ep if ep is not None else e + + _g_code_map = {0: _gCode0, 1: _gCode0, 28: _gCode28, 92: _gCode92} + + def _processGCode(self, G, line, position, path): + func = self._g_code_map.get(G, None) + x = self._getFloat(line, "X") + y = self._getFloat(line, "Y") + z = self._getFloat(line, "Z") + e = self._getFloat(line, "E") + if x is not None and x < 0: + self._center_is_zero = True + if y is not None and y < 0: + self._center_is_zero = True + if func is not None: + params = (x, y, z, e) + return func(self, position, params, path) + return position + + def _processTCode(self, T, line, position, path): + self._extruder = T + if len(path) > 1 and position[2] > 0: + if self._createPolygon(position[2], path): + self._layer += 1 + path.clear() + else: + path.clear() + def read(self, file_name): Logger.log("d", "Preparing to load %s" % file_name) self._cancelled = False @@ -120,8 +198,6 @@ class GCodeReader(MeshReader): Logger.log("d", "Opening file %s" % file_name) - layer_data_builder = LayerDataBuilder.LayerDataBuilder() - with open(file_name, "r") as file: file_lines = 0 current_line = 0 @@ -131,16 +207,7 @@ class GCodeReader(MeshReader): file_step = max(math.floor(file_lines / 100), 1) - current_extruder = 0 - current_path = [] - current_x = 0 - current_y = 0 - current_z = 0 - current_e = 0 - current_block = LayerPolygon.Inset0Type - current_layer = 0 - prev_z = 0 - center_is_zero = False + self._clearValues() self._message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0) self._message.setProgress(0) @@ -148,6 +215,9 @@ class GCodeReader(MeshReader): Logger.log("d", "Parsing %s" % file_name) + current_position = (0, 0, 0, 0) # x, y, z, e + current_path = [] + for line in file: if self._cancelled: Logger.log("w", "Parsing %s cancelled" % file_name) @@ -160,89 +230,33 @@ class GCodeReader(MeshReader): if line.find(";TYPE:") == 0: type = line[6:].strip() if type == "WALL-INNER": - current_block = LayerPolygon.InsetXType + self._layer_type = LayerPolygon.InsetXType elif type == "WALL-OUTER": - current_block = LayerPolygon.Inset0Type + self._layer_type = LayerPolygon.Inset0Type elif type == "SKIN": - current_block = LayerPolygon.SkinType + self._layer_type = LayerPolygon.SkinType elif type == "SKIRT": - current_block = LayerPolygon.SkirtType + self._layer_type = LayerPolygon.SkirtType elif type == "SUPPORT": - current_block = LayerPolygon.SupportType + self._layer_type = LayerPolygon.SupportType elif type == "FILL": - current_block = LayerPolygon.InfillType + self._layer_type = LayerPolygon.InfillType if line[0] == ";": continue + G = self._getInt(line, "G") - x = self._getFloat(line, "X") - y = self._getFloat(line, "Y") - z = self._getFloat(line, "Z") - if x is not None and x < 0: - center_is_zero = True - if y is not None and y < 0: - center_is_zero = True if G is not None: - if G == 0 or G == 1: - e = self._getFloat(line, "E") - z_changed = False - if x is not None: - current_x = x - if y is not None: - current_y = y - if z is not None: - if not current_z == z: - z_changed = True - prev_z = current_z - current_z = z - if e is not None: - if e > current_e: - current_path.append([current_x, current_y, current_z, current_block]) # extrusion - else: - current_path.append([current_x, current_y, current_z, LayerPolygon.MoveRetractionType]) # retraction - current_e = e - else: - current_path.append([current_x, current_y, current_z, LayerPolygon.MoveCombingType]) - if z_changed: - if len(current_path) > 1 and current_z > 0: - if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder, math.fabs(current_z - prev_z)): - current_layer += 1 - current_path.clear() - else: - current_path.clear() - - elif G == 28: - if x is not None: - current_x = x - if y is not None: - current_y = y - current_z = 0 - elif G == 92: - e = self._getFloat(line, "E") - if x is not None: - current_x = x - if y is not None: - current_y = y - if z is not None: - current_z = z - if e is not None: - current_e = e - + current_position = self._processGCode(G, line, current_position, current_path) T = self._getInt(line, "T") if T is not None: - current_extruder = T - if len(current_path) > 1 and current_z > 0: - if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder, math.fabs(current_z - prev_z)): - current_layer += 1 - current_path.clear() - else: - current_path.clear() + self._processTCode(T, line, current_position, current_path) - if len(current_path) > 1 and current_z > 0: - if self._createPolygon(layer_data_builder, current_path, current_layer, current_extruder, math.fabs(current_z - prev_z)): - current_layer += 1 + if len(current_path) > 1 and current_position[2] > 0: + if self._createPolygon(current_position[2], current_path): + self._layer += 1 current_path.clear() - layer_mesh = layer_data_builder.build() + layer_mesh = self._layer_data_builder.build() decorator = LayerDataDecorator.LayerDataDecorator() decorator.setLayerData(layer_mesh) scene_node.addDecorator(decorator) @@ -255,14 +269,14 @@ class GCodeReader(MeshReader): Logger.log("d", "Finished parsing %s" % file_name) self._message.hide() - if current_layer == 0: + if self._layer == 0: Logger.log("w", "File %s doesn't contain any valid layers" % file_name) settings = Application.getInstance().getGlobalContainerStack() machine_width = settings.getProperty("machine_width", "value") machine_depth = settings.getProperty("machine_depth", "value") - if not center_is_zero: + if not self._center_is_zero: scene_node.setPosition(Vector(-machine_width / 2, 0, machine_depth / 2)) Logger.log("d", "Loaded %s" % file_name) From ba372f69a74f70e8ed1579de3d2c4de3b33739f9 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 6 Dec 2016 16:57:17 +0600 Subject: [PATCH 52/68] D6: Refactoring --- cura/CuraApplication.py | 19 ++++--- .../CuraEngineBackend/CuraEngineBackend.py | 13 ++--- plugins/GCodeReader/GCodeReader.py | 54 ++++++++++--------- 3 files changed, 41 insertions(+), 45 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 4e611cf680..3676756a32 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -20,6 +20,7 @@ from UM.Scene.Selection import Selection from UM.Scene.GroupDecorator import GroupDecorator from UM.Settings.Validator import Validator from UM.Message import Message +from UM.i18n import i18nCatalog from UM.Operations.AddSceneNodeOperation import AddSceneNodeOperation from UM.Operations.RemoveSceneNodeOperation import RemoveSceneNodeOperation @@ -32,9 +33,6 @@ from UM.Settings.SettingDefinition import SettingDefinition, DefinitionPropertyT from UM.Settings.ContainerRegistry import ContainerRegistry from UM.Settings.SettingFunction import SettingFunction -from UM.i18n import i18nCatalog -catalog = i18nCatalog("cura") - from . import PlatformPhysics from . import BuildVolume from . import CameraAnimation @@ -608,15 +606,16 @@ class CuraApplication(QtApplication): if other_bb is not None: scene_bounding_box = scene_bounding_box + node.getBoundingBox() - if not should_pause: - self.getBackend().continueSlicing() - self.setHideSettings(False) - if self.getPrintInformation(): - self.getPrintInformation().setPreSliced(False) - else: + print_information = self.getPrintInformation() + if should_pause: self.getBackend().pauseSlicing() self.setHideSettings(True) - self.getPrintInformation().setPreSliced(True) + print_information.setPreSliced(True) + else: + self.getBackend().continueSlicing() + self.setHideSettings(False) + if print_information: + print_information.setPreSliced(False) if not scene_bounding_box: scene_bounding_box = AxisAlignedBox.Null diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index b77b5da5bd..db5e256d81 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -116,7 +116,6 @@ class CuraEngineBackend(Backend): self.backendQuit.connect(self._onBackendQuit) self.backendConnected.connect(self._onBackendConnected) - self.backendStateChange.connect(self._onBackendStateChanged) # When a tool operation is in progress, don't slice. So we need to listen for tool operations. Application.getInstance().getController().toolOperationStarted.connect(self._onToolOperationStarted) @@ -188,22 +187,16 @@ class CuraEngineBackend(Backend): self._start_slice_job.start() self._start_slice_job.finished.connect(self._onStartSliceCompleted) - _last_state = BackendState.NotStarted def pauseSlicing(self): self.close() + self._pause_slicing = True self.backendStateChange.emit(BackendState.SlicingDisabled) def continueSlicing(self): - if self._last_state == BackendState.SlicingDisabled: - self.backendStateChange.emit(BackendState.NotStarted) - - def _onBackendStateChanged(self, state): - self._last_state = state - if state == BackendState.SlicingDisabled: - self._pause_slicing = True - else: + if self._pause_slicing: self._pause_slicing = False + self.backendStateChange.emit(BackendState.NotStarted) ## Terminate the engine process. def _terminate(self): diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index dc91af756c..e05985bab5 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -47,12 +47,13 @@ class GCodeReader(MeshReader): @staticmethod def _getValue(line, code): - n = line.find(code) + len(code) - if n < 1: + n = line.find(code) + if n < 0: return None + n += len(code) pattern = re.compile("[;\s]") match = pattern.search(line, n) - m = match.start() if math is not None else -1 + m = match.start() if match is not None else -1 try: if m < 0: return line[n:] @@ -91,7 +92,7 @@ class GCodeReader(MeshReader): return False try: self._layer_data_builder.addLayer(self._layer) - self._layer_data_builder.setLayerHeight(self._layer, path[0][1]) + self._layer_data_builder.setLayerHeight(self._layer, path[0][2]) self._layer_data_builder.setLayerThickness(self._layer, math.fabs(current_z - self._prev_z)) this_layer = self._layer_data_builder.getLayer(self._layer) except ValueError: @@ -120,7 +121,8 @@ class GCodeReader(MeshReader): def _gCode0(self, position, params, path): x, y, z, e = position xp, yp, zp, ep = params - x, y = xp if xp is not None else x, yp if yp is not None else y + x = xp if xp is not None else x + y = yp if yp is not None else y z_changed = False if zp is not None: if z != zp: @@ -142,39 +144,37 @@ class GCodeReader(MeshReader): path.clear() else: path.clear() - return x, y, z, e + return (x, y, z, e) def _gCode28(self, position, params, path): x, y, z, e = position xp, yp, zp, ep = params - return xp if xp is not None else x,\ - yp if yp is not None else y,\ - 0,\ - e + return (xp if xp is not None else x, + yp if yp is not None else y, + 0, + e) def _gCode92(self, position, params, path): x, y, z, e = position xp, yp, zp, ep = params - return xp if xp is not None else x,\ - yp if yp is not None else y,\ - zp if zp is not None else z,\ - ep if ep is not None else e + return (xp if xp is not None else x, + yp if yp is not None else y, + zp if zp is not None else z, + ep if ep is not None else e) - _g_code_map = {0: _gCode0, 1: _gCode0, 28: _gCode28, 92: _gCode92} + _gCode1 = _gCode0 def _processGCode(self, G, line, position, path): - func = self._g_code_map.get(G, None) + func = getattr(self, "_gCode%s" % G, None) x = self._getFloat(line, "X") y = self._getFloat(line, "Y") z = self._getFloat(line, "Z") e = self._getFloat(line, "E") - if x is not None and x < 0: - self._center_is_zero = True - if y is not None and y < 0: - self._center_is_zero = True if func is not None: + if (x is not None and x < 0) or (y is not None and y < 0): + self._center_is_zero = True params = (x, y, z, e) - return func(self, position, params, path) + return func(position, params, path) return position def _processTCode(self, T, line, position, path): @@ -186,6 +186,8 @@ class GCodeReader(MeshReader): else: path.clear() + _type_keyword = ";TYPE:" + def read(self, file_name): Logger.log("d", "Preparing to load %s" % file_name) self._cancelled = False @@ -194,7 +196,7 @@ class GCodeReader(MeshReader): scene_node.getBoundingBox = self._getNullBoundingBox # Manually set bounding box, because mesh doesn't have mesh data glist = [] - Application.getInstance().getController().getScene().gcode_list = glist + Logger.log("d", "Opening file %s" % file_name) @@ -209,7 +211,7 @@ class GCodeReader(MeshReader): self._clearValues() - self._message = Message(catalog.i18nc("@info:status", "Parsing GCODE"), lifetime=0) + self._message = Message(catalog.i18nc("@info:status", "Parsing G-code"), lifetime=0) self._message.setProgress(0) self._message.show() @@ -227,8 +229,8 @@ class GCodeReader(MeshReader): self._message.setProgress(math.floor(current_line / file_lines * 100)) if len(line) == 0: continue - if line.find(";TYPE:") == 0: - type = line[6:].strip() + if line.find(self._type_keyword) == 0: + type = line[len(self._type_keyword):].strip() if type == "WALL-INNER": self._layer_type = LayerPolygon.InsetXType elif type == "WALL-OUTER": @@ -266,6 +268,8 @@ class GCodeReader(MeshReader): sliceable_decorator.setSliceable(False) scene_node.addDecorator(sliceable_decorator) + Application.getInstance().getController().getScene().gcode_list = glist + Logger.log("d", "Finished parsing %s" % file_name) self._message.hide() From afc9b71279b12e01b666bab8918a16e317a4eea7 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Wed, 7 Dec 2016 11:56:38 +0600 Subject: [PATCH 53/68] D6: Fixed dual extrusion E value --- plugins/GCodeReader/GCodeReader.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index e05985bab5..15c75b6ec2 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -130,11 +130,11 @@ class GCodeReader(MeshReader): self._prev_z = z z = zp if ep is not None: - if ep > e: + if ep > e[self._extruder]: path.append([x, y, z, self._layer_type]) # extrusion else: path.append([x, y, z, LayerPolygon.MoveRetractionType]) # retraction - e = ep + e[self._extruder] = ep else: path.append([x, y, z, LayerPolygon.MoveCombingType]) if z_changed: @@ -157,10 +157,12 @@ class GCodeReader(MeshReader): def _gCode92(self, position, params, path): x, y, z, e = position xp, yp, zp, ep = params + if ep is not None: + e[self._extruder] = ep return (xp if xp is not None else x, yp if yp is not None else y, zp if zp is not None else z, - ep if ep is not None else e) + e) _gCode1 = _gCode0 @@ -217,7 +219,7 @@ class GCodeReader(MeshReader): Logger.log("d", "Parsing %s" % file_name) - current_position = (0, 0, 0, 0) # x, y, z, e + current_position = (0, 0, 0, [0, 0]) # x, y, z, e current_path = [] for line in file: From 26fe0ddbb5882665c0d73532bf786442518f44ef Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 9 Dec 2016 14:47:13 +0600 Subject: [PATCH 54/68] D6: Refactoring --- cura/CuraApplication.py | 15 -------- plugins/GCodeReader/GCodeReader.py | 57 +++++++++++++++--------------- resources/qml/Sidebar.qml | 2 +- 3 files changed, 29 insertions(+), 45 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 3676756a32..679911bb0a 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -609,11 +609,9 @@ class CuraApplication(QtApplication): print_information = self.getPrintInformation() if should_pause: self.getBackend().pauseSlicing() - self.setHideSettings(True) print_information.setPreSliced(True) else: self.getBackend().continueSlicing() - self.setHideSettings(False) if print_information: print_information.setPreSliced(False) @@ -1033,17 +1031,4 @@ class CuraApplication(QtApplication): def log(self, msg): Logger.log("d", msg) - _hide_settings = False - - hideSettingsChanged = pyqtSignal(bool) - - @pyqtSlot(bool) - def setHideSettings(self, hide): - self._hide_settings = hide - self.hideSettingsChanged.emit(hide) - - @pyqtProperty(bool, fset=setHideSettings, notify=hideSettingsChanged) - def hideSettings(self): - return self._hide_settings - diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 15c75b6ec2..ef278a0019 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -24,6 +24,7 @@ from UM.Scene.SliceableObjectDecorator import SliceableObjectDecorator import numpy import math import re +from collections import namedtuple # Class for loading and parsing G-code files @@ -36,12 +37,13 @@ class GCodeReader(MeshReader): self._message = None self._clearValues() self._scene_node = None + self._position = namedtuple('Position', ['x', 'y', 'z', 'e']) def _clearValues(self): self._extruder = 0 self._layer_type = LayerPolygon.Inset0Type self._layer = 0 - self._prev_z = 0 + self._previous_z = 0 self._layer_data_builder = LayerDataBuilder.LayerDataBuilder() self._center_is_zero = False @@ -93,7 +95,7 @@ class GCodeReader(MeshReader): try: self._layer_data_builder.addLayer(self._layer) self._layer_data_builder.setLayerHeight(self._layer, path[0][2]) - self._layer_data_builder.setLayerThickness(self._layer, math.fabs(current_z - self._prev_z)) + self._layer_data_builder.setLayerThickness(self._layer, math.fabs(current_z - self._previous_z)) this_layer = self._layer_data_builder.getLayer(self._layer) except ValueError: return False @@ -120,21 +122,20 @@ class GCodeReader(MeshReader): def _gCode0(self, position, params, path): x, y, z, e = position - xp, yp, zp, ep = params - x = xp if xp is not None else x - y = yp if yp is not None else y + x = params.x if params.x is not None else x + y = params.y if params.y is not None else y z_changed = False - if zp is not None: - if z != zp: + if params.z is not None: + if z != params.z: z_changed = True - self._prev_z = z - z = zp - if ep is not None: - if ep > e[self._extruder]: + self._previous_z = z + z = params.z + if params.e is not None: + if params.e > e[self._extruder]: path.append([x, y, z, self._layer_type]) # extrusion else: path.append([x, y, z, LayerPolygon.MoveRetractionType]) # retraction - e[self._extruder] = ep + e[self._extruder] = params.e else: path.append([x, y, z, LayerPolygon.MoveCombingType]) if z_changed: @@ -144,25 +145,23 @@ class GCodeReader(MeshReader): path.clear() else: path.clear() - return (x, y, z, e) + return self._position(x, y, z, e) def _gCode28(self, position, params, path): - x, y, z, e = position - xp, yp, zp, ep = params - return (xp if xp is not None else x, - yp if yp is not None else y, + return self._position( + params.x if params.x is not None else position.x, + params.y if params.y is not None else position.y, 0, - e) + position.e) def _gCode92(self, position, params, path): - x, y, z, e = position - xp, yp, zp, ep = params - if ep is not None: - e[self._extruder] = ep - return (xp if xp is not None else x, - yp if yp is not None else y, - zp if zp is not None else z, - e) + if params.e is not None: + position.e[self._extruder] = params.e + return self._position( + params.x if params.x is not None else position.x, + params.y if params.y is not None else position.y, + params.z if params.z is not None else position.z, + position.e) _gCode1 = _gCode0 @@ -175,7 +174,7 @@ class GCodeReader(MeshReader): if func is not None: if (x is not None and x < 0) or (y is not None and y < 0): self._center_is_zero = True - params = (x, y, z, e) + params = self._position(x, y, z, e) return func(position, params, path) return position @@ -219,12 +218,12 @@ class GCodeReader(MeshReader): Logger.log("d", "Parsing %s" % file_name) - current_position = (0, 0, 0, [0, 0]) # x, y, z, e + current_position = self._position(0, 0, 0, [0, 0]) current_path = [] for line in file: if self._cancelled: - Logger.log("w", "Parsing %s cancelled" % file_name) + Logger.log("i", "Parsing %s cancelled" % file_name) return None current_line += 1 if current_line % file_step == 0: diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml index 202bfd070c..ecbe64b26a 100644 --- a/resources/qml/Sidebar.qml +++ b/resources/qml/Sidebar.qml @@ -16,7 +16,7 @@ Rectangle property int currentModeIndex; property bool monitoringPrint: false - property bool hideSettings: Printer.hideSettings + property bool hideSettings: PrintInformation.preSliced Connections { target: Printer From 3605403314ff68dab3d8535b3ee659de87f21df6 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 9 Dec 2016 15:09:53 +0600 Subject: [PATCH 55/68] D6: Moved file loading code --- cura/CuraApplication.py | 64 +++++++++++++++++++ .../CuraEngineBackend/CuraEngineBackend.py | 2 +- plugins/GCodeReader/GCodeReader.py | 2 +- resources/qml/Cura.qml | 4 +- resources/qml/Menus/RecentFilesMenu.qml | 2 +- 5 files changed, 69 insertions(+), 5 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 679911bb0a..6297efb747 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -1031,4 +1031,68 @@ class CuraApplication(QtApplication): def log(self, msg): Logger.log("d", msg) + _loading_files = [] + _non_sliceable_extensions = [".gcode", ".g"] + + @pyqtSlot(QUrl) + def readLocalFile(self, file): + if not file.isValid(): + return + + scene = self.getController().getScene() + + for node in DepthFirstIterator(scene.getRoot()): + if node.callDecoration("shouldBlockSlicing"): + self.deleteAll() + break + + f = file.toLocalFile() + extension = os.path.splitext(f)[1] + filename = os.path.basename(f) + if len(self._loading_files) > 0: + # If a non-slicable file is already being loaded, we prevent loading of any further non-slicable files + if extension.lower() in self._non_sliceable_extensions: + message = Message( + self._i18n_catalog.i18nc("@info:status", + "Only one G-code file can be loaded at a time. Skipped importing {0}", + filename)) + message.show() + return + # If file being loaded is non-slicable file, then prevent loading of any other files + extension = os.path.splitext(self._loading_files[0])[1] + if extension.lower() in self._non_sliceable_extensions: + message = Message( + self._i18n_catalog.i18nc("@info:status", + "Can't open any other file if G-code is loading. Skipped importing {0}", + filename)) + message.show() + return + + self._loading_files.append(f) + if extension in self._non_sliceable_extensions: + self.deleteAll() + + job = ReadMeshJob(f) + job.finished.connect(self._readMeshFinished) + job.start() + + def _readMeshFinished(self, job): + node = job.getResult() + filename = job.getFileName() + self._loading_files.remove(filename) + + if node != None: + node.setSelectable(True) + node.setName(os.path.basename(filename)) + + extension = os.path.splitext(filename)[1] + if extension.lower() in self._non_sliceable_extensions: + self.changeLayerViewSignal.emit() + + scene = self.getController().getScene() + + op = AddSceneNodeOperation(node, scene.getRoot()) + op.push() + + scene.sceneChanged.emit(node) diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index db5e256d81..44009ae1de 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -191,7 +191,7 @@ class CuraEngineBackend(Backend): def pauseSlicing(self): self.close() self._pause_slicing = True - self.backendStateChange.emit(BackendState.SlicingDisabled) + self.backendStateChange.emit(BackendState.Disabled) def continueSlicing(self): if self._pause_slicing: diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index ef278a0019..e9aea36fae 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -223,7 +223,7 @@ class GCodeReader(MeshReader): for line in file: if self._cancelled: - Logger.log("i", "Parsing %s cancelled" % file_name) + Logger.log("d", "Parsing %s cancelled" % file_name) return None current_line += 1 if current_line % file_step == 0: diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml index 8eb3cf850e..1383338144 100644 --- a/resources/qml/Cura.qml +++ b/resources/qml/Cura.qml @@ -275,7 +275,7 @@ UM.MainWindow // There is no endsWith in this version of JS... if ((drop.urls[i].length <= 12) || (drop.urls[i].substring(drop.urls[i].length-12) !== ".curaprofile")) { // Drop an object - UM.MeshFileHandler.readLocalFile(drop.urls[i]); + Printer.readLocalFile(drop.urls[i]); if (imported_model == -1) { imported_model = i; @@ -737,7 +737,7 @@ UM.MainWindow for(var i in fileUrls) { - UM.MeshFileHandler.readLocalFile(fileUrls[i]) + Printer.readLocalFile(fileUrls[i]) } var meshName = backgroundItem.getMeshName(fileUrls[0].toString()) diff --git a/resources/qml/Menus/RecentFilesMenu.qml b/resources/qml/Menus/RecentFilesMenu.qml index c47fc5715b..866b06ccbb 100644 --- a/resources/qml/Menus/RecentFilesMenu.qml +++ b/resources/qml/Menus/RecentFilesMenu.qml @@ -26,7 +26,7 @@ Menu return (index + 1) + ". " + path.slice(path.lastIndexOf("/") + 1); } onTriggered: { - UM.MeshFileHandler.readLocalFile(modelData); + Printer.readLocalFile(modelData); var meshName = backgroundItem.getMeshName(modelData.toString()) backgroundItem.hasMesh(decodeURIComponent(meshName)) } From 620a3891da3da7f9dd6007236ae2ea5eb5833156 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 9 Dec 2016 15:26:37 +0600 Subject: [PATCH 56/68] D6: Moved decorator to cura --- cura/CuraApplication.py | 11 +++++++++++ cura/SliceableObjectDecorator.py | 21 +++++++++++++++++++++ plugins/3MFReader/ThreeMFReader.py | 18 ++++++++---------- plugins/GCodeReader/GCodeReader.py | 23 +++++++---------------- plugins/X3DReader/X3DReader.py | 15 +++++++-------- 5 files changed, 54 insertions(+), 34 deletions(-) create mode 100644 cura/SliceableObjectDecorator.py diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 6297efb747..028a8bf85e 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -28,6 +28,7 @@ from UM.Operations.GroupedOperation import GroupedOperation from UM.Operations.SetTransformOperation import SetTransformOperation from UM.Operations.TranslateOperation import TranslateOperation from cura.SetParentOperation import SetParentOperation +from cura.SliceableObjectDecorator import SliceableObjectDecorator from UM.Settings.SettingDefinition import SettingDefinition, DefinitionPropertyType from UM.Settings.ContainerRegistry import ContainerRegistry @@ -1088,6 +1089,16 @@ class CuraApplication(QtApplication): extension = os.path.splitext(filename)[1] if extension.lower() in self._non_sliceable_extensions: self.changeLayerViewSignal.emit() + sliceable_decorator = SliceableObjectDecorator() + sliceable_decorator.setBlockSlicing(True) + sliceable_decorator.setSliceable(False) + node.addDecorator(sliceable_decorator) + else: + sliceable_decorator = SliceableObjectDecorator() + sliceable_decorator.setBlockSlicing(False) + sliceable_decorator.setSliceable(True) + node.addDecorator(sliceable_decorator) + scene = self.getController().getScene() diff --git a/cura/SliceableObjectDecorator.py b/cura/SliceableObjectDecorator.py new file mode 100644 index 0000000000..12dbbcb751 --- /dev/null +++ b/cura/SliceableObjectDecorator.py @@ -0,0 +1,21 @@ +from UM.Scene.SceneNodeDecorator import SceneNodeDecorator + + +## Simple decorator to indicate a scene node is sliceable or not. +class SliceableObjectDecorator(SceneNodeDecorator): + def __init__(self): + super().__init__() + self._sliceable = True + self._block_slicing = False + + def isSliceable(self): + return self._sliceable + + def setSliceable(self, sliceable): + self._sliceable = sliceable + + def shouldBlockSlicing(self): + return self._block_slicing + + def setBlockSlicing(self, block_slicing): + self._block_slicing = block_slicing diff --git a/plugins/3MFReader/ThreeMFReader.py b/plugins/3MFReader/ThreeMFReader.py index 97134bf676..ee4e1daab4 100644 --- a/plugins/3MFReader/ThreeMFReader.py +++ b/plugins/3MFReader/ThreeMFReader.py @@ -1,23 +1,23 @@ # Copyright (c) 2015 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. -from UM.Mesh.MeshReader import MeshReader -from UM.Mesh.MeshBuilder import MeshBuilder +import math +import os.path +import zipfile + +from UM.Job import Job from UM.Logger import Logger from UM.Math.Matrix import Matrix from UM.Math.Vector import Vector -from UM.Scene.SceneNode import SceneNode +from UM.Mesh.MeshBuilder import MeshBuilder +from UM.Mesh.MeshReader import MeshReader from UM.Scene.GroupDecorator import GroupDecorator import UM.Application -from UM.Job import Job from cura.Settings.SettingOverrideDecorator import SettingOverrideDecorator from UM.Application import Application from cura.Settings.ExtruderManager import ExtruderManager from cura.QualityManager import QualityManager -from UM.Scene.SliceableObjectDecorator import SliceableObjectDecorator - -import os.path -import zipfile +from UM.Scene.SceneNode import SceneNode try: import xml.etree.cElementTree as ET @@ -235,8 +235,6 @@ class ThreeMFReader(MeshReader): except Exception as e: Logger.log("e", "An exception occurred in 3mf reader: %s", e) - sliceable_decorator = SliceableObjectDecorator() - result.addDecorator(sliceable_decorator) return result ## Create a scale vector based on a unit string. diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index e9aea36fae..22a2463724 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -1,25 +1,22 @@ # Copyright (c) 2016 Aleph Objects, Inc. # Cura is released under the terms of the AGPLv3 or higher. -from UM.Mesh.MeshReader import MeshReader -import os -from UM.Scene.SceneNode import SceneNode -from UM.Scene.Iterator.DepthFirstIterator import DepthFirstIterator -from UM.Math.Vector import Vector -from UM.Math.AxisAlignedBox import AxisAlignedBox from UM.Application import Application -from UM.Message import Message from UM.Logger import Logger -from UM.Backend.Backend import BackendState - +from UM.Math.AxisAlignedBox import AxisAlignedBox +from UM.Math.Vector import Vector +from UM.Mesh.MeshReader import MeshReader +from UM.Message import Message +from UM.Scene.SceneNode import SceneNode from UM.i18n import i18nCatalog + catalog = i18nCatalog("cura") from cura import LayerDataBuilder from cura import LayerDataDecorator from cura.LayerPolygon import LayerPolygon -from UM.Scene.SliceableObjectDecorator import SliceableObjectDecorator +from cura.SliceableObjectDecorator import SliceableObjectDecorator import numpy import math @@ -263,12 +260,6 @@ class GCodeReader(MeshReader): decorator = LayerDataDecorator.LayerDataDecorator() decorator.setLayerData(layer_mesh) scene_node.addDecorator(decorator) - - sliceable_decorator = SliceableObjectDecorator() - sliceable_decorator.setBlockSlicing(True) - sliceable_decorator.setSliceable(False) - scene_node.addDecorator(sliceable_decorator) - Application.getInstance().getController().getScene().gcode_list = glist Logger.log("d", "Finished parsing %s" % file_name) diff --git a/plugins/X3DReader/X3DReader.py b/plugins/X3DReader/X3DReader.py index 16b8a6a5ae..0a81e98d0d 100644 --- a/plugins/X3DReader/X3DReader.py +++ b/plugins/X3DReader/X3DReader.py @@ -1,16 +1,17 @@ # Contributed by Seva Alekseyev with National Institutes of Health, 2016 # Cura is released under the terms of the AGPLv3 or higher. -from UM.Mesh.MeshReader import MeshReader -from UM.Mesh.MeshBuilder import MeshBuilder +from math import pi, sin, cos, sqrt + +import numpy + +from UM.Job import Job from UM.Logger import Logger from UM.Math.Matrix import Matrix from UM.Math.Vector import Vector +from UM.Mesh.MeshBuilder import MeshBuilder +from UM.Mesh.MeshReader import MeshReader from UM.Scene.SceneNode import SceneNode -from UM.Job import Job -from math import pi, sin, cos, sqrt -import numpy -from UM.Scene.SliceableObjectDecorator import SliceableObjectDecorator try: import xml.etree.cElementTree as ET @@ -97,8 +98,6 @@ class X3DReader(MeshReader): Logger.logException("e", "Exception in X3D reader") return None - sliceable_decorator = SliceableObjectDecorator() - node.addDecorator(sliceable_decorator) return node # ------------------------- XML tree traversal From fecf23d66d099f8192ef2b9e41c182b82b9a8680 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Fri, 9 Dec 2016 15:42:00 +0600 Subject: [PATCH 57/68] D6: Moved extensions to plugin metadata --- cura/CuraApplication.py | 11 +++++------ plugins/GCodeReader/__init__.py | 2 ++ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 028a8bf85e..8e93b1b7ad 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -1033,7 +1033,7 @@ class CuraApplication(QtApplication): Logger.log("d", msg) _loading_files = [] - _non_sliceable_extensions = [".gcode", ".g"] + non_sliceable_extensions = [] @pyqtSlot(QUrl) def readLocalFile(self, file): @@ -1052,7 +1052,7 @@ class CuraApplication(QtApplication): filename = os.path.basename(f) if len(self._loading_files) > 0: # If a non-slicable file is already being loaded, we prevent loading of any further non-slicable files - if extension.lower() in self._non_sliceable_extensions: + if extension.lower() in self.non_sliceable_extensions: message = Message( self._i18n_catalog.i18nc("@info:status", "Only one G-code file can be loaded at a time. Skipped importing {0}", @@ -1061,7 +1061,7 @@ class CuraApplication(QtApplication): return # If file being loaded is non-slicable file, then prevent loading of any other files extension = os.path.splitext(self._loading_files[0])[1] - if extension.lower() in self._non_sliceable_extensions: + if extension.lower() in self.non_sliceable_extensions: message = Message( self._i18n_catalog.i18nc("@info:status", "Can't open any other file if G-code is loading. Skipped importing {0}", @@ -1070,7 +1070,7 @@ class CuraApplication(QtApplication): return self._loading_files.append(f) - if extension in self._non_sliceable_extensions: + if extension in self.non_sliceable_extensions: self.deleteAll() job = ReadMeshJob(f) @@ -1087,7 +1087,7 @@ class CuraApplication(QtApplication): node.setName(os.path.basename(filename)) extension = os.path.splitext(filename)[1] - if extension.lower() in self._non_sliceable_extensions: + if extension.lower() in self.non_sliceable_extensions: self.changeLayerViewSignal.emit() sliceable_decorator = SliceableObjectDecorator() sliceable_decorator.setBlockSlicing(True) @@ -1099,7 +1099,6 @@ class CuraApplication(QtApplication): sliceable_decorator.setSliceable(True) node.addDecorator(sliceable_decorator) - scene = self.getController().getScene() op = AddSceneNodeOperation(node, scene.getRoot()) diff --git a/plugins/GCodeReader/__init__.py b/plugins/GCodeReader/__init__.py index 7e543d6624..cdf1b063aa 100644 --- a/plugins/GCodeReader/__init__.py +++ b/plugins/GCodeReader/__init__.py @@ -28,4 +28,6 @@ def getMetaData(): } def register(app): + app.non_sliceable_extensions.append(".gcode") + app.non_sliceable_extensions.append(".g") return { "mesh_reader": GCodeReader.GCodeReader() } From 90f7cebbbbf2bbb5678a3fc0d92801c8d5930593 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Mon, 12 Dec 2016 12:45:46 +0600 Subject: [PATCH 58/68] D6: Fixed gcode loading to scene while undo/redo --- cura/CuraApplication.py | 3 +++ cura/GCodeListDecorator.py | 13 +++++++++++++ plugins/GCodeReader/GCodeReader.py | 8 ++++++-- resources/qml/SaveButton.qml | 4 ++-- 4 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 cura/GCodeListDecorator.py diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 8e93b1b7ad..cf6284bf86 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -598,6 +598,9 @@ class CuraApplication(QtApplication): continue if node.callDecoration("shouldBlockSlicing"): should_pause = True + gcode_list = node.callDecoration("gCodeList") + if gcode_list is not None: + self.getController().getScene().gcode_list = gcode_list count += 1 if not scene_bounding_box: diff --git a/cura/GCodeListDecorator.py b/cura/GCodeListDecorator.py new file mode 100644 index 0000000000..9c103db84f --- /dev/null +++ b/cura/GCodeListDecorator.py @@ -0,0 +1,13 @@ +from UM.Scene.SceneNodeDecorator import SceneNodeDecorator + + +class GCodeListDecorator(SceneNodeDecorator): + def __init__(self): + super().__init__() + self._gcode_list = [] + + def gCodeList(self): + return self._gcode_list + + def setGCodeList(self, list): + self._gcode_list = list diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 22a2463724..4ca0be0000 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -16,7 +16,7 @@ catalog = i18nCatalog("cura") from cura import LayerDataBuilder from cura import LayerDataDecorator from cura.LayerPolygon import LayerPolygon -from cura.SliceableObjectDecorator import SliceableObjectDecorator +from cura.GCodeListDecorator import GCodeListDecorator import numpy import math @@ -203,6 +203,7 @@ class GCodeReader(MeshReader): current_line = 0 for line in file: file_lines += 1 + glist.append(line) file.seek(0) file_step = max(math.floor(file_lines / 100), 1) @@ -260,7 +261,10 @@ class GCodeReader(MeshReader): decorator = LayerDataDecorator.LayerDataDecorator() decorator.setLayerData(layer_mesh) scene_node.addDecorator(decorator) - Application.getInstance().getController().getScene().gcode_list = glist + + gcode_list_decorator = GCodeListDecorator() + gcode_list_decorator.setGCodeList(glist) + scene_node.addDecorator(gcode_list_decorator) Logger.log("d", "Finished parsing %s" % file_name) self._message.hide() diff --git a/resources/qml/SaveButton.qml b/resources/qml/SaveButton.qml index 843ac19837..323123e9a7 100644 --- a/resources/qml/SaveButton.qml +++ b/resources/qml/SaveButton.qml @@ -106,7 +106,7 @@ Rectangle { id: saveToButton tooltip: UM.OutputDeviceManager.activeDeviceDescription; - enabled: base.backendState == 3 && base.activity == true + enabled: (base.backendState == 3 || base.backendState == 5) && base.activity == true height: UM.Theme.getSize("save_button_save_to_button").height anchors.top: parent.top @@ -181,7 +181,7 @@ Rectangle { anchors.rightMargin: UM.Theme.getSize("default_margin").width width: UM.Theme.getSize("save_button_save_to_button").height height: UM.Theme.getSize("save_button_save_to_button").height - enabled: base.backendState == 3 && base.activity == true + enabled: (base.backendState == 3 || base.backendState == 5) && base.activity == true visible: devicesModel.deviceCount > 1 From 647c2f15ba16926619b0aea52ba0503201529172 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Mon, 12 Dec 2016 13:10:02 +0600 Subject: [PATCH 59/68] D6: Changed Decorator --- cura/CuraApplication.py | 14 ++++++-------- cura/SliceableObjectDecorator.py | 7 ------- plugins/LayerView/LayerPass.py | 2 +- 3 files changed, 7 insertions(+), 16 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index cf6284bf86..f25fbe19bc 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -594,9 +594,9 @@ class CuraApplication(QtApplication): scene_bounding_box = None should_pause = False for node in DepthFirstIterator(self.getController().getScene().getRoot()): - if type(node) is not SceneNode or (not node.getMeshData() and not node.callDecoration("shouldBlockSlicing")): + if type(node) is not SceneNode or (not node.getMeshData() and node.callDecoration("isSliceable") is None): continue - if node.callDecoration("shouldBlockSlicing"): + if node.callDecoration("isSliceable") is False: should_pause = True gcode_list = node.callDecoration("gCodeList") if gcode_list is not None: @@ -613,7 +613,8 @@ class CuraApplication(QtApplication): print_information = self.getPrintInformation() if should_pause: self.getBackend().pauseSlicing() - print_information.setPreSliced(True) + if print_information: + print_information.setPreSliced(True) else: self.getBackend().continueSlicing() if print_information: @@ -739,7 +740,7 @@ class CuraApplication(QtApplication): for node in DepthFirstIterator(self.getController().getScene().getRoot()): if type(node) is not SceneNode: continue - if (not node.getMeshData() and node.callDecoration("isSliceable")) and not node.callDecoration("isGroup"): + if (not node.getMeshData() and node.callDecoration("isSliceable") is None) and not node.callDecoration("isGroup"): continue # Node that doesnt have a mesh and is not a group. if node.getParent() and node.getParent().callDecoration("isGroup"): continue # Grouped nodes don't need resetting as their parent (the group) is resetted) @@ -1046,7 +1047,7 @@ class CuraApplication(QtApplication): scene = self.getController().getScene() for node in DepthFirstIterator(scene.getRoot()): - if node.callDecoration("shouldBlockSlicing"): + if node.callDecoration("isSliceable") is False: self.deleteAll() break @@ -1093,13 +1094,10 @@ class CuraApplication(QtApplication): if extension.lower() in self.non_sliceable_extensions: self.changeLayerViewSignal.emit() sliceable_decorator = SliceableObjectDecorator() - sliceable_decorator.setBlockSlicing(True) sliceable_decorator.setSliceable(False) node.addDecorator(sliceable_decorator) else: sliceable_decorator = SliceableObjectDecorator() - sliceable_decorator.setBlockSlicing(False) - sliceable_decorator.setSliceable(True) node.addDecorator(sliceable_decorator) scene = self.getController().getScene() diff --git a/cura/SliceableObjectDecorator.py b/cura/SliceableObjectDecorator.py index 12dbbcb751..7fa3ca37f2 100644 --- a/cura/SliceableObjectDecorator.py +++ b/cura/SliceableObjectDecorator.py @@ -6,16 +6,9 @@ class SliceableObjectDecorator(SceneNodeDecorator): def __init__(self): super().__init__() self._sliceable = True - self._block_slicing = False def isSliceable(self): return self._sliceable def setSliceable(self, sliceable): self._sliceable = sliceable - - def shouldBlockSlicing(self): - return self._block_slicing - - def setBlockSlicing(self, block_slicing): - self._block_slicing = block_slicing diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index ca895619a3..4a494a3436 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -49,7 +49,7 @@ class LayerPass(RenderPass): if isinstance(node, ToolHandle): tool_handle_batch.addItem(node.getWorldTransformation(), mesh = node.getSolidMesh()) - elif isinstance(node, SceneNode) and (node.getMeshData() or not node.callDecoration("isSliceable")) and node.isVisible(): + elif isinstance(node, SceneNode) and (node.getMeshData() or node.callDecoration("isSliceable") is False) and node.isVisible(): layer_data = node.callDecoration("getLayerData") if not layer_data: continue From 67ab0cab4160f56e3e0ecb239d7cc8ce540fc8f3 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 13 Dec 2016 13:39:09 +0600 Subject: [PATCH 60/68] D6: Changed decorator and swapping to LayerView --- cura/BlockSlicingDecorator.py | 9 +++++ cura/CuraApplication.py | 58 ++++++++++++++--------------- cura/GCodeListDecorator.py | 2 +- cura/NonSliceableObjectDecorator.py | 9 +++++ cura/SliceableObjectDecorator.py | 7 +--- plugins/GCodeReader/__init__.py | 4 +- plugins/LayerView/LayerPass.py | 2 +- 7 files changed, 50 insertions(+), 41 deletions(-) create mode 100644 cura/BlockSlicingDecorator.py create mode 100644 cura/NonSliceableObjectDecorator.py diff --git a/cura/BlockSlicingDecorator.py b/cura/BlockSlicingDecorator.py new file mode 100644 index 0000000000..669d69b09f --- /dev/null +++ b/cura/BlockSlicingDecorator.py @@ -0,0 +1,9 @@ +from UM.Scene.SceneNodeDecorator import SceneNodeDecorator + + +class BlockSlicingDecorator(SceneNodeDecorator): + def __init__(self): + super().__init__() + + def isBlockSlicing(self): + return True diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index f25fbe19bc..a9cafd4fc6 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -29,6 +29,7 @@ from UM.Operations.SetTransformOperation import SetTransformOperation from UM.Operations.TranslateOperation import TranslateOperation from cura.SetParentOperation import SetParentOperation from cura.SliceableObjectDecorator import SliceableObjectDecorator +from cura.BlockSlicingDecorator import BlockSlicingDecorator from UM.Settings.SettingDefinition import SettingDefinition, DefinitionPropertyType from UM.Settings.ContainerRegistry import ContainerRegistry @@ -136,6 +137,9 @@ class CuraApplication(QtApplication): } ) + self._currently_loading_files = [] + self._non_sliceable_extensions = [] + self._machine_action_manager = MachineActionManager.MachineActionManager() self._machine_manager = None # This is initialized on demand. self._setting_inheritance_manager = None @@ -290,8 +294,6 @@ class CuraApplication(QtApplication): self._recent_files.append(QUrl.fromLocalFile(f)) - self.changeLayerViewSignal.connect(self.changeToLayerView) - def _onEngineCreated(self): self._engine.addImageProvider("camera", CameraImageProvider.CameraImageProvider()) @@ -538,15 +540,6 @@ class CuraApplication(QtApplication): qmlRegisterType(QUrl.fromLocalFile(path), "Cura", 1, 0, type_name) - changeLayerViewSignal = pyqtSignal() - - def changeToLayerView(self): - self.getController().setActiveView("LayerView") - view = self.getController().getActiveView() - view.resetLayerData() - view.setLayer(999999) - view.calculateMaxLayers() - def onSelectionChanged(self): if Selection.hasSelection(): if self.getController().getActiveTool(): @@ -594,11 +587,11 @@ class CuraApplication(QtApplication): scene_bounding_box = None should_pause = False for node in DepthFirstIterator(self.getController().getScene().getRoot()): - if type(node) is not SceneNode or (not node.getMeshData() and node.callDecoration("isSliceable") is None): + if type(node) is not SceneNode or (not node.getMeshData() and not node.callDecoration("isBlockSlicing")): continue - if node.callDecoration("isSliceable") is False: + if node.callDecoration("isBlockSlicing"): should_pause = True - gcode_list = node.callDecoration("gCodeList") + gcode_list = node.callDecoration("getGCodeList") if gcode_list is not None: self.getController().getScene().gcode_list = gcode_list @@ -740,7 +733,7 @@ class CuraApplication(QtApplication): for node in DepthFirstIterator(self.getController().getScene().getRoot()): if type(node) is not SceneNode: continue - if (not node.getMeshData() and node.callDecoration("isSliceable") is None) and not node.callDecoration("isGroup"): + if (not node.getMeshData() and not node.callDecoration("isBlockSlicing")) and not node.callDecoration("isGroup"): continue # Node that doesnt have a mesh and is not a group. if node.getParent() and node.getParent().callDecoration("isGroup"): continue # Grouped nodes don't need resetting as their parent (the group) is resetted) @@ -1036,9 +1029,6 @@ class CuraApplication(QtApplication): def log(self, msg): Logger.log("d", msg) - _loading_files = [] - non_sliceable_extensions = [] - @pyqtSlot(QUrl) def readLocalFile(self, file): if not file.isValid(): @@ -1047,16 +1037,16 @@ class CuraApplication(QtApplication): scene = self.getController().getScene() for node in DepthFirstIterator(scene.getRoot()): - if node.callDecoration("isSliceable") is False: + if node.callDecoration("isBlockSlicing"): self.deleteAll() break f = file.toLocalFile() extension = os.path.splitext(f)[1] filename = os.path.basename(f) - if len(self._loading_files) > 0: + if len(self._currently_loading_files) > 0: # If a non-slicable file is already being loaded, we prevent loading of any further non-slicable files - if extension.lower() in self.non_sliceable_extensions: + if extension.lower() in self._non_sliceable_extensions: message = Message( self._i18n_catalog.i18nc("@info:status", "Only one G-code file can be loaded at a time. Skipped importing {0}", @@ -1064,8 +1054,8 @@ class CuraApplication(QtApplication): message.show() return # If file being loaded is non-slicable file, then prevent loading of any other files - extension = os.path.splitext(self._loading_files[0])[1] - if extension.lower() in self.non_sliceable_extensions: + extension = os.path.splitext(self._currently_loading_files[0])[1] + if extension.lower() in self._non_sliceable_extensions: message = Message( self._i18n_catalog.i18nc("@info:status", "Can't open any other file if G-code is loading. Skipped importing {0}", @@ -1073,8 +1063,8 @@ class CuraApplication(QtApplication): message.show() return - self._loading_files.append(f) - if extension in self.non_sliceable_extensions: + self._currently_loading_files.append(f) + if extension in self._non_sliceable_extensions: self.deleteAll() job = ReadMeshJob(f) @@ -1084,18 +1074,22 @@ class CuraApplication(QtApplication): def _readMeshFinished(self, job): node = job.getResult() filename = job.getFileName() - self._loading_files.remove(filename) + self._currently_loading_files.remove(filename) if node != None: node.setSelectable(True) node.setName(os.path.basename(filename)) extension = os.path.splitext(filename)[1] - if extension.lower() in self.non_sliceable_extensions: - self.changeLayerViewSignal.emit() - sliceable_decorator = SliceableObjectDecorator() - sliceable_decorator.setSliceable(False) - node.addDecorator(sliceable_decorator) + if extension.lower() in self._non_sliceable_extensions: + self.getController().setActiveView("LayerView") + view = self.getController().getActiveView() + view.resetLayerData() + view.setLayer(9999999) + view.calculateMaxLayers() + + block_slicing_decorator = BlockSlicingDecorator() + node.addDecorator(block_slicing_decorator) else: sliceable_decorator = SliceableObjectDecorator() node.addDecorator(sliceable_decorator) @@ -1107,3 +1101,5 @@ class CuraApplication(QtApplication): scene.sceneChanged.emit(node) + def addNonSliceableExtension(self, extension): + self._non_sliceable_extensions.append(extension) diff --git a/cura/GCodeListDecorator.py b/cura/GCodeListDecorator.py index 9c103db84f..72ff975108 100644 --- a/cura/GCodeListDecorator.py +++ b/cura/GCodeListDecorator.py @@ -6,7 +6,7 @@ class GCodeListDecorator(SceneNodeDecorator): super().__init__() self._gcode_list = [] - def gCodeList(self): + def getGCodeList(self): return self._gcode_list def setGCodeList(self, list): diff --git a/cura/NonSliceableObjectDecorator.py b/cura/NonSliceableObjectDecorator.py new file mode 100644 index 0000000000..1f1a08e075 --- /dev/null +++ b/cura/NonSliceableObjectDecorator.py @@ -0,0 +1,9 @@ +from UM.Scene.SceneNodeDecorator import SceneNodeDecorator + + +class NonSliceableObjectDecorator(SceneNodeDecorator): + def __init__(self): + super().__init__() + + def isNonSliceable(self): + return True diff --git a/cura/SliceableObjectDecorator.py b/cura/SliceableObjectDecorator.py index 7fa3ca37f2..315149a3cf 100644 --- a/cura/SliceableObjectDecorator.py +++ b/cura/SliceableObjectDecorator.py @@ -1,14 +1,9 @@ from UM.Scene.SceneNodeDecorator import SceneNodeDecorator -## Simple decorator to indicate a scene node is sliceable or not. class SliceableObjectDecorator(SceneNodeDecorator): def __init__(self): super().__init__() - self._sliceable = True def isSliceable(self): - return self._sliceable - - def setSliceable(self, sliceable): - self._sliceable = sliceable + return True diff --git a/plugins/GCodeReader/__init__.py b/plugins/GCodeReader/__init__.py index cdf1b063aa..2ff412e757 100644 --- a/plugins/GCodeReader/__init__.py +++ b/plugins/GCodeReader/__init__.py @@ -28,6 +28,6 @@ def getMetaData(): } def register(app): - app.non_sliceable_extensions.append(".gcode") - app.non_sliceable_extensions.append(".g") + app.addNonSliceableExtension(".gcode") + app.addNonSliceableExtension(".g") return { "mesh_reader": GCodeReader.GCodeReader() } diff --git a/plugins/LayerView/LayerPass.py b/plugins/LayerView/LayerPass.py index 4a494a3436..9bc67efc58 100644 --- a/plugins/LayerView/LayerPass.py +++ b/plugins/LayerView/LayerPass.py @@ -49,7 +49,7 @@ class LayerPass(RenderPass): if isinstance(node, ToolHandle): tool_handle_batch.addItem(node.getWorldTransformation(), mesh = node.getSolidMesh()) - elif isinstance(node, SceneNode) and (node.getMeshData() or node.callDecoration("isSliceable") is False) and node.isVisible(): + elif isinstance(node, SceneNode) and (node.getMeshData() or node.callDecoration("isBlockSlicing")) and node.isVisible(): layer_data = node.callDecoration("getLayerData") if not layer_data: continue From b967f045fe2e0342fd4629066f1764d5482454c5 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 13 Dec 2016 13:41:00 +0600 Subject: [PATCH 61/68] D6: Removed unused file --- cura/NonSliceableObjectDecorator.py | 9 --------- 1 file changed, 9 deletions(-) delete mode 100644 cura/NonSliceableObjectDecorator.py diff --git a/cura/NonSliceableObjectDecorator.py b/cura/NonSliceableObjectDecorator.py deleted file mode 100644 index 1f1a08e075..0000000000 --- a/cura/NonSliceableObjectDecorator.py +++ /dev/null @@ -1,9 +0,0 @@ -from UM.Scene.SceneNodeDecorator import SceneNodeDecorator - - -class NonSliceableObjectDecorator(SceneNodeDecorator): - def __init__(self): - super().__init__() - - def isNonSliceable(self): - return True From cb428c70de5cd79e3f652a5eeba944c038bc8e7e Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 13 Dec 2016 13:58:33 +0600 Subject: [PATCH 62/68] D6: Moved backend pausing to itself --- cura/CuraApplication.py | 18 +-------------- .../CuraEngineBackend/CuraEngineBackend.py | 22 +++++++++++++++++++ 2 files changed, 23 insertions(+), 17 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index a9cafd4fc6..45221738be 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -585,16 +585,10 @@ class CuraApplication(QtApplication): def updatePlatformActivity(self, node = None): count = 0 scene_bounding_box = None - should_pause = False for node in DepthFirstIterator(self.getController().getScene().getRoot()): if type(node) is not SceneNode or (not node.getMeshData() and not node.callDecoration("isBlockSlicing")): continue - if node.callDecoration("isBlockSlicing"): - should_pause = True - gcode_list = node.callDecoration("getGCodeList") - if gcode_list is not None: - self.getController().getScene().gcode_list = gcode_list - + count += 1 if not scene_bounding_box: scene_bounding_box = node.getBoundingBox() @@ -603,16 +597,6 @@ class CuraApplication(QtApplication): if other_bb is not None: scene_bounding_box = scene_bounding_box + node.getBoundingBox() - print_information = self.getPrintInformation() - if should_pause: - self.getBackend().pauseSlicing() - if print_information: - print_information.setPreSliced(True) - else: - self.getBackend().continueSlicing() - if print_information: - print_information.setPreSliced(False) - if not scene_bounding_box: scene_bounding_box = AxisAlignedBox.Null diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index 44009ae1de..93e2bd7c68 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -12,6 +12,8 @@ from UM.PluginRegistry import PluginRegistry from UM.Resources import Resources from UM.Settings.Validator import ValidatorState #To find if a setting is in an error state. We can't slice then. from UM.Platform import Platform +from UM.Scene.Iterator.DepthFirstIterator import DepthFirstIterator + import cura.Settings @@ -313,6 +315,26 @@ class CuraEngineBackend(Backend): if source is self._scene.getRoot(): return + application = Application.getInstance() + + should_pause = False + for node in DepthFirstIterator(self._scene.getRoot()): + if node.callDecoration("isBlockSlicing"): + should_pause = True + gcode_list = node.callDecoration("getGCodeList") + if gcode_list is not None: + self._scene.gcode_list = gcode_list + + print_information = application.getPrintInformation() + if should_pause: + self.pauseSlicing() + if print_information: + print_information.setPreSliced(True) + else: + self.continueSlicing() + if print_information: + print_information.setPreSliced(False) + if source.getMeshData() is None: return From 9e85d6c8941a303edc2b99a076d17f4298cc4978 Mon Sep 17 00:00:00 2001 From: Youness Alaoui Date: Fri, 16 Dec 2016 12:59:37 -0500 Subject: [PATCH 63/68] Fix GCodeReader-feature related _readMeshfinished to match changes upstream. The job.getResult() now returns a list of nodes now, so we need to loop over those nodes instead of taking it as a single node value. --- cura/CuraApplication.py | 4 ++-- plugins/3MFReader/ThreeMFReader.py | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 45221738be..54f4cf3057 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -1056,11 +1056,11 @@ class CuraApplication(QtApplication): job.start() def _readMeshFinished(self, job): - node = job.getResult() + nodes = job.getResult() filename = job.getFileName() self._currently_loading_files.remove(filename) - if node != None: + for node in nodes: node.setSelectable(True) node.setName(os.path.basename(filename)) diff --git a/plugins/3MFReader/ThreeMFReader.py b/plugins/3MFReader/ThreeMFReader.py index ee4e1daab4..e9f0e28511 100644 --- a/plugins/3MFReader/ThreeMFReader.py +++ b/plugins/3MFReader/ThreeMFReader.py @@ -1,7 +1,6 @@ # Copyright (c) 2015 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. -import math import os.path import zipfile From 485e81731f455a48d8a74f8562a2426e0a9c5a64 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Mon, 19 Dec 2016 10:10:51 +0600 Subject: [PATCH 64/68] D6: Fixed file naming, removed spaces and fixed decoration calls --- cura/BlockSlicingDecorator.py | 2 +- cura/CuraApplication.py | 13 ++++++++++--- cura/GCodeListDecorator.py | 2 +- plugins/CuraEngineBackend/CuraEngineBackend.py | 7 ------- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/cura/BlockSlicingDecorator.py b/cura/BlockSlicingDecorator.py index 669d69b09f..3fc0015836 100644 --- a/cura/BlockSlicingDecorator.py +++ b/cura/BlockSlicingDecorator.py @@ -4,6 +4,6 @@ from UM.Scene.SceneNodeDecorator import SceneNodeDecorator class BlockSlicingDecorator(SceneNodeDecorator): def __init__(self): super().__init__() - + def isBlockSlicing(self): return True diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 54f4cf3057..73cf50b214 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -585,10 +585,13 @@ class CuraApplication(QtApplication): def updatePlatformActivity(self, node = None): count = 0 scene_bounding_box = None + is_block_slicing_node = False for node in DepthFirstIterator(self.getController().getScene().getRoot()): - if type(node) is not SceneNode or (not node.getMeshData() and not node.callDecoration("isBlockSlicing")): + if type(node) is not SceneNode or (not node.getMeshData() and not node.callDecoration("getLayerData")): continue - + if node.callDecoration("isBlockSlicing"): + is_block_slicing_node = True + count += 1 if not scene_bounding_box: scene_bounding_box = node.getBoundingBox() @@ -597,6 +600,10 @@ class CuraApplication(QtApplication): if other_bb is not None: scene_bounding_box = scene_bounding_box + node.getBoundingBox() + print_information = self.getPrintInformation() + if print_information: + print_information.setPreSliced(is_block_slicing_node) + if not scene_bounding_box: scene_bounding_box = AxisAlignedBox.Null @@ -717,7 +724,7 @@ class CuraApplication(QtApplication): for node in DepthFirstIterator(self.getController().getScene().getRoot()): if type(node) is not SceneNode: continue - if (not node.getMeshData() and not node.callDecoration("isBlockSlicing")) and not node.callDecoration("isGroup"): + if (not node.getMeshData() and not node.callDecoration("getLayerData")) and not node.callDecoration("isGroup"): continue # Node that doesnt have a mesh and is not a group. if node.getParent() and node.getParent().callDecoration("isGroup"): continue # Grouped nodes don't need resetting as their parent (the group) is resetted) diff --git a/cura/GCodeListDecorator.py b/cura/GCodeListDecorator.py index 72ff975108..5738d0a7f2 100644 --- a/cura/GCodeListDecorator.py +++ b/cura/GCodeListDecorator.py @@ -5,7 +5,7 @@ class GCodeListDecorator(SceneNodeDecorator): def __init__(self): super().__init__() self._gcode_list = [] - + def getGCodeList(self): return self._gcode_list diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index 93e2bd7c68..cf53475fb4 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -315,8 +315,6 @@ class CuraEngineBackend(Backend): if source is self._scene.getRoot(): return - application = Application.getInstance() - should_pause = False for node in DepthFirstIterator(self._scene.getRoot()): if node.callDecoration("isBlockSlicing"): @@ -325,15 +323,10 @@ class CuraEngineBackend(Backend): if gcode_list is not None: self._scene.gcode_list = gcode_list - print_information = application.getPrintInformation() if should_pause: self.pauseSlicing() - if print_information: - print_information.setPreSliced(True) else: self.continueSlicing() - if print_information: - print_information.setPreSliced(False) if source.getMeshData() is None: return From f8874bfe21ac27d28816053c5e73c1978487a8d3 Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Tue, 20 Dec 2016 14:12:33 +0600 Subject: [PATCH 65/68] D6: Fixed multi-extrusion --- plugins/GCodeReader/GCodeReader.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 4ca0be0000..4aa7e92a45 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -177,12 +177,15 @@ class GCodeReader(MeshReader): def _processTCode(self, T, line, position, path): self._extruder = T + if self._extruder + 1 > len(position.e): + position.e.extend([0] * (self._extruder - len(position.e) + 1)) if len(path) > 1 and position[2] > 0: if self._createPolygon(position[2], path): self._layer += 1 path.clear() else: path.clear() + return position _type_keyword = ";TYPE:" @@ -216,7 +219,7 @@ class GCodeReader(MeshReader): Logger.log("d", "Parsing %s" % file_name) - current_position = self._position(0, 0, 0, [0, 0]) + current_position = self._position(0, 0, 0, [0]) current_path = [] for line in file: @@ -250,7 +253,7 @@ class GCodeReader(MeshReader): current_position = self._processGCode(G, line, current_position, current_path) T = self._getInt(line, "T") if T is not None: - self._processTCode(T, line, current_position, current_path) + current_position = self._processTCode(T, line, current_position, current_path) if len(current_path) > 1 and current_position[2] > 0: if self._createPolygon(current_position[2], current_path): From 33cd386556717111e5bc35331bf2428b10f7d72c Mon Sep 17 00:00:00 2001 From: Victor Larchenko Date: Thu, 5 Jan 2017 13:43:08 +0600 Subject: [PATCH 66/68] D6: Fixed layers and line widths --- cura/SliceableObjectDecorator.py | 3 ++ plugins/GCodeReader/GCodeReader.py | 44 ++++++++++++++++++++---------- 2 files changed, 33 insertions(+), 14 deletions(-) diff --git a/cura/SliceableObjectDecorator.py b/cura/SliceableObjectDecorator.py index 315149a3cf..1cb589d9c6 100644 --- a/cura/SliceableObjectDecorator.py +++ b/cura/SliceableObjectDecorator.py @@ -7,3 +7,6 @@ class SliceableObjectDecorator(SceneNodeDecorator): def isSliceable(self): return True + + def __deepcopy__(self, memo): + return type(self)() diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 4aa7e92a45..894783c07d 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -100,7 +100,7 @@ class GCodeReader(MeshReader): line_types = numpy.empty((count - 1, 1), numpy.int32) line_widths = numpy.empty((count - 1, 1), numpy.float32) # TODO: need to calculate actual line width based on E values - line_widths[:, 0] = 0.5 + line_widths[:, 0] = 0.4 points = numpy.empty((count, 3), numpy.float32) i = 0 for point in path: @@ -109,6 +109,8 @@ class GCodeReader(MeshReader): points[i, 2] = -point[1] if i > 0: line_types[i - 1] = point[3] + if point[3] in [LayerPolygon.MoveCombingType, LayerPolygon.MoveRetractionType]: + line_widths[i - 1] = 0.2 i += 1 this_poly = LayerPolygon(self._layer_data_builder, self._extruder, line_types, points, line_widths) @@ -136,12 +138,13 @@ class GCodeReader(MeshReader): else: path.append([x, y, z, LayerPolygon.MoveCombingType]) if z_changed: - if len(path) > 1 and z > 0: - if self._createPolygon(z, path): - self._layer += 1 - path.clear() - else: - path.clear() + if not self._is_layers_in_file: + if not self._is_layers_in_file and len(path) > 1 and z > 0: + if self._createPolygon(z, path): + self._layer += 1 + path.clear() + else: + path.clear() return self._position(x, y, z, e) def _gCode28(self, position, params, path): @@ -179,15 +182,17 @@ class GCodeReader(MeshReader): self._extruder = T if self._extruder + 1 > len(position.e): position.e.extend([0] * (self._extruder - len(position.e) + 1)) - if len(path) > 1 and position[2] > 0: - if self._createPolygon(position[2], path): - self._layer += 1 - path.clear() - else: - path.clear() + if not self._is_layers_in_file: + if len(path) > 1 and position[2] > 0: + if self._createPolygon(position[2], path): + self._layer += 1 + path.clear() + else: + path.clear() return position _type_keyword = ";TYPE:" + _layer_keyword = ";LAYER:" def read(self, file_name): Logger.log("d", "Preparing to load %s" % file_name) @@ -197,6 +202,7 @@ class GCodeReader(MeshReader): scene_node.getBoundingBox = self._getNullBoundingBox # Manually set bounding box, because mesh doesn't have mesh data glist = [] + self._is_layers_in_file = False Logger.log("d", "Opening file %s" % file_name) @@ -207,6 +213,8 @@ class GCodeReader(MeshReader): for line in file: file_lines += 1 glist.append(line) + if not self._is_layers_in_file and line[:len(self._layer_keyword)] == self._layer_keyword: + self._is_layers_in_file = True file.seek(0) file_step = max(math.floor(file_lines / 100), 1) @@ -245,6 +253,14 @@ class GCodeReader(MeshReader): self._layer_type = LayerPolygon.SupportType elif type == "FILL": self._layer_type = LayerPolygon.InfillType + if self._is_layers_in_file and line[:len(self._layer_keyword)] == self._layer_keyword: + try: + layer_number = int(line[len(self._layer_keyword):]) + self._createPolygon(current_position[2], current_path) + current_path.clear() + self._layer = layer_number + except: + pass if line[0] == ";": continue @@ -255,7 +271,7 @@ class GCodeReader(MeshReader): if T is not None: current_position = self._processTCode(T, line, current_position, current_path) - if len(current_path) > 1 and current_position[2] > 0: + if not self._is_layers_in_file and len(current_path) > 1 and current_position[2] > 0: if self._createPolygon(current_position[2], current_path): self._layer += 1 current_path.clear() From ad95f94d408f8023e91533217da452f122fbc1ef Mon Sep 17 00:00:00 2001 From: Youness Alaoui Date: Thu, 5 Jan 2017 13:04:56 -0500 Subject: [PATCH 67/68] Remove redundant check --- plugins/GCodeReader/GCodeReader.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/GCodeReader/GCodeReader.py b/plugins/GCodeReader/GCodeReader.py index 894783c07d..34ea91a727 100644 --- a/plugins/GCodeReader/GCodeReader.py +++ b/plugins/GCodeReader/GCodeReader.py @@ -139,7 +139,7 @@ class GCodeReader(MeshReader): path.append([x, y, z, LayerPolygon.MoveCombingType]) if z_changed: if not self._is_layers_in_file: - if not self._is_layers_in_file and len(path) > 1 and z > 0: + if len(path) > 1 and z > 0: if self._createPolygon(z, path): self._layer += 1 path.clear() From f095e9050f03af4a6e3a74c4e7309723f59b2aa0 Mon Sep 17 00:00:00 2001 From: Youness Alaoui Date: Thu, 5 Jan 2017 13:14:33 -0500 Subject: [PATCH 68/68] T466: Hide the search icon from printer setup When in custom mode in the printer setup pane and a gcode file gets loaded the search icon needs to disappear as well. Reported by @GhostKeeper, and fix provided by @victor9999 --- resources/qml/Sidebar.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/qml/Sidebar.qml b/resources/qml/Sidebar.qml index ecbe64b26a..a3f792d137 100644 --- a/resources/qml/Sidebar.qml +++ b/resources/qml/Sidebar.qml @@ -385,7 +385,7 @@ Rectangle height: settingsModeSelection.height width: visible ? height : 0 - visible: !monitoringPrint && modesListModel.get(base.currentModeIndex) != undefined && modesListModel.get(base.currentModeIndex).showFilterButton + visible: !monitoringPrint && !hideSettings && modesListModel.get(base.currentModeIndex) != undefined && modesListModel.get(base.currentModeIndex).showFilterButton opacity: visible ? 1 : 0 onClicked: sidebarContents.currentItem.toggleFilterField()