From b294aede47c24cf12dff15678913b933872b07b5 Mon Sep 17 00:00:00 2001 From: daid Date: Fri, 6 Apr 2012 17:08:49 +0200 Subject: [PATCH] Added skin setting to advanced settings --- Cura/cura_sf/fabmetheus_utilities/settings.py | 12 ++++++------ Cura/gui/mainWindow.py | 1 + Cura/util/gcodeInterpreter.py | 2 +- Cura/util/profile.py | 1 + 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Cura/cura_sf/fabmetheus_utilities/settings.py b/Cura/cura_sf/fabmetheus_utilities/settings.py index fb19b972..e765bff0 100644 --- a/Cura/cura_sf/fabmetheus_utilities/settings.py +++ b/Cura/cura_sf/fabmetheus_utilities/settings.py @@ -270,12 +270,12 @@ def getProfileInformation(): 'Perimeter_Outside_Stretch_Over_Perimeter_Width_ratio': DEFSET, 'Stretch_From_Distance_Over_Perimeter_Width_ratio': DEFSET, },'skin': { - 'Activate_Skin': "False", - 'Horizontal_Infill_Divisions_integer': DEFSET, - 'Horizontal_Perimeter_Divisions_integer': DEFSET, - 'Vertical_Divisions_integer': DEFSET, - 'Hop_When_Extruding_Infill': DEFSET, - 'Layers_From_index': DEFSET, + 'Activate_Skin': storedSetting("enable_skin"), + 'Horizontal_Infill_Divisions_integer': "1", + 'Horizontal_Perimeter_Divisions_integer': "1", + 'Vertical_Divisions_integer': "2", + 'Hop_When_Extruding_Infill': "False", + 'Layers_From_index': "1", },'comb': { 'Activate_Comb': "True", 'Running_Jump_Space_mm': DEFSET, diff --git a/Cura/gui/mainWindow.py b/Cura/gui/mainWindow.py index 5740fc72..05170c85 100644 --- a/Cura/gui/mainWindow.py +++ b/Cura/gui/mainWindow.py @@ -175,6 +175,7 @@ class mainWindow(configBase.configWindowBase): c = configBase.SettingRow(right, "Initial layer thickness (mm)", 'bottom_thickness', '0.0', 'Layer thickness of the bottom layer. A thicker bottom layer makes sticking to the bed easier. Set to 0.0 to have the bottom layer thickness the same as the other layers.') validators.validFloat(c, 0.0) validators.warningAbove(c, lambda : (float(profile.getProfileSetting('nozzle_size')) * 3.0 / 4.0), "A bottom layer of more then %.2fmm (3/4 nozzle size) usually give bad results and is not recommended.") + c = configBase.SettingRow(right, "Enable 'skin'", 'enable_skin', False, 'Skin prints the outer lines of the prints twice, each time with half the thickness. This gives the illusion of a higher print quality.') nb.AddPage(alterationPanel.alterationPanel(nb), "Start/End-GCode") diff --git a/Cura/util/gcodeInterpreter.py b/Cura/util/gcodeInterpreter.py index 3570d49e..0518be27 100644 --- a/Cura/util/gcodeInterpreter.py +++ b/Cura/util/gcodeInterpreter.py @@ -105,7 +105,7 @@ class gcode(): else: pos.z += z * scale #Check if we have a new layer. - if oldPos.z != pos.z and startCodeDone: + if oldPos.z < pos.z and startCodeDone and len(currentLayer) > 0: self.layerList.append(currentLayer) currentLayer = [] if f is not None: diff --git a/Cura/util/profile.py b/Cura/util/profile.py index 8229aeec..34df82db 100644 --- a/Cura/util/profile.py +++ b/Cura/util/profile.py @@ -56,6 +56,7 @@ profileDefaultSettings = { 'support_rate': '50', 'support_distance': '0.5', 'joris': 'False', + 'enable_skin': 'False', 'enable_raft': 'False', 'cool_min_feedrate': '5', 'bridge_speed': '100', -- 2.30.2