from Cura.gui import configBase
from Cura.util import profile
-class expertConfigWindow(wx.Frame):
+class expertConfigWindow(wx.Dialog):
"Expert configuration window"
def _addSettingsToPanels(self, category, left, right):
count = len(profile.getSubCategoriesFor(category)) + len(profile.getSettingsForCategory(category))
left, right, main = self.panel.CreateConfigPanel(self)
self._addSettingsToPanels('expert', left, right)
+
+ self.okButton = wx.Button(right, -1, 'Ok')
+ right.GetSizer().Add(self.okButton, (right.GetSizer().GetRows(), 0))
+ self.Bind(wx.EVT_BUTTON, lambda e: self.Close(), self.okButton)
main.Fit()
self.Fit()
setting('bottom_layer_speed', 20, float, 'advanced', 'Speed').setRange(0.1).setLabel('Bottom layer speed (mm/s)', 'Print speed for the bottom layer, you want to print the first layer slower so it sticks better to the printer bed.')
setting('cool_min_layer_time', 5, float, 'advanced', 'Cool').setRange(0).setLabel('Minimal layer time (sec)', 'Minimum time spend in a layer, gives the layer time to cool down before the next layer is put on top. If the layer will be placed down too fast the printer will slow down to make sure it has spend at least this amount of seconds printing this layer.')
#setting('fan_enabled', True, bool, 'advanced', 'Cool').setLabel('Enable cooling fan', 'Enable the cooling fan during the print. The extra cooling from the cooling fan is essensial during faster prints.')
+
#setting('max_z_speed', 3.0, float, 'expert', 'Speed').setRange(0.1).setLabel('Max Z speed (mm/s)', 'Speed at which Z moves are done. When you Z axis is properly lubricated you can increase this for less Z blob.')
#setting('retract_on_jumps_only', True, bool, 'expert', 'Retraction').setLabel('Retract on jumps only', 'Only retract when we are making a move that is over a hole in the model, else retract on every move. This effects print quality in different ways.')
setting('fan_layer', 1, int, 'expert', 'Cool').setRange(0).setLabel('Fan on layer number', 'The layer at which the fan is turned on. The first layer is layer 0. The first layer can stick better if you turn on the fan on, on the 2nd layer.')
#setting('sequence', 'Loops > Perimeter > Infill', ['Loops > Perimeter > Infill', 'Loops > Infill > Perimeter', 'Infill > Loops > Perimeter', 'Infill > Perimeter > Loops', 'Perimeter > Infill > Loops', 'Perimeter > Loops > Infill'], 'expert', 'Sequence')
#setting('force_first_layer_sequence', True, bool, 'expert', 'Sequence').setLabel('Force first layer sequence', 'This setting forces the order of the first layer to be \'Perimeter > Loops > Infill\'')
#setting('infill_type', 'Line', ['Line', 'Grid Circular', 'Grid Hexagonal', 'Grid Rectangular'], 'expert', 'Infill').setLabel('Infill pattern', 'Pattern of the none-solid infill. Line is default, but grids can provide a strong print.')
-#setting('solid_top', True, bool, 'expert', 'Infill').setLabel('Solid infill top', 'Create a solid top surface, if set to false the top is filled with the fill percentage. Useful for cups/vases.')
+setting('solid_top', True, bool, 'expert', 'Infill').setLabel('Solid infill top', 'Create a solid top surface, if set to false the top is filled with the fill percentage. Useful for cups/vases.')
+setting('solid_bottom', True, bool, 'expert', 'Infill').setLabel('Solid infill bottom', 'Create a solid bottom surface, if set to false the bottom is filled with the fill percentage. Useful for buildings.')
#setting('fill_overlap', 15, int, 'expert', 'Infill').setRange(0,100).setLabel('Infill overlap (%)', 'Amount of overlap between the infill and the walls. There is a slight overlap with the walls and the infill so the walls connect firmly to the infill.')
#setting('support_rate', 50, int, 'expert', 'Support').setRange(0,100).setLabel('Material amount (%)', 'Amount of material used for support, less material gives a weaker support structure which is easier to remove.')
#setting('support_distance', 0.5, float, 'expert', 'Support').setRange(0).setLabel('Distance from object (mm)', 'Distance between the support structure and the object. Empty gap in which no support structure is printed.')
'filamentDiameter': int(profile.getProfileSettingFloat('filament_diameter') * 1000),
'extrusionWidth': int(profile.calculateEdgeWidth() * 1000),
'insetCount': int(profile.calculateLineCount()),
- 'downSkinCount': int(profile.calculateSolidLayerCount()),
- 'upSkinCount': int(profile.calculateSolidLayerCount()),
+ 'downSkinCount': int(profile.calculateSolidLayerCount()) if profile.getProfileSetting('solid_bottom') == 'True' else 0,
+ 'upSkinCount': int(profile.calculateSolidLayerCount()) if profile.getProfileSetting('solid_top') == 'True' else 0,
'sparseInfillLineDistance': int(100 * profile.calculateEdgeWidth() * 1000 / profile.getProfileSettingFloat('fill_density')) if profile.getProfileSettingFloat('fill_density') > 0 else 9999999999,
'skirtDistance': int(profile.getProfileSettingFloat('skirt_gap') * 1000),
'skirtLineCount': int(profile.getProfileSettingFloat('skirt_line_count')),