- updated the UI in Geometry UI
- optimized the order of the defaults storage declaration and the update of the Preferences GUI from the defaults
This commit is contained in:
@@ -34,7 +34,7 @@ class Distance(FlatCAMTool):
|
||||
|
||||
self.app = app
|
||||
self.canvas = self.app.plotcanvas
|
||||
self.units = self.app.ui.general_defaults_form.general_app_group.units_radio.get_value().lower()
|
||||
self.units = self.app.defaults['units'].lower()
|
||||
|
||||
# ## Title
|
||||
title_label = QtWidgets.QLabel("<font size=4><b>%s</b></font><br>" % self.toolName)
|
||||
|
||||
@@ -35,7 +35,7 @@ class DistanceMin(FlatCAMTool):
|
||||
|
||||
self.app = app
|
||||
self.canvas = self.app.plotcanvas
|
||||
self.units = self.app.ui.general_defaults_form.general_app_group.units_radio.get_value().lower()
|
||||
self.units = self.app.defaults['units'].lower()
|
||||
|
||||
# ## Title
|
||||
title_label = QtWidgets.QLabel("<font size=4><b>%s</b></font><br>" % self.toolName)
|
||||
|
||||
@@ -421,7 +421,7 @@ class NonCopperClear(FlatCAMTool, Gerber):
|
||||
self.ncc_offset_spinner.set_precision(4)
|
||||
self.ncc_offset_spinner.setWrapping(True)
|
||||
|
||||
units = self.app.ui.general_defaults_form.general_app_group.units_radio.get_value().upper()
|
||||
units = self.app.defaults['units'].upper()
|
||||
if units == 'MM':
|
||||
self.ncc_offset_spinner.setSingleStep(0.1)
|
||||
else:
|
||||
|
||||
@@ -39,7 +39,7 @@ class ToolOptimal(FlatCAMTool):
|
||||
def __init__(self, app):
|
||||
FlatCAMTool.__init__(self, app)
|
||||
|
||||
self.units = self.app.ui.general_defaults_form.general_app_group.units_radio.get_value().upper()
|
||||
self.units = self.app.defaults['units'].upper()
|
||||
self.decimals = 4
|
||||
|
||||
# ############################################################################
|
||||
|
||||
Reference in New Issue
Block a user