- Geometry Editor - added the label Beginner/Advanced for uniformity within the app

- minor string changes
This commit is contained in:
Marius Stanciu
2020-12-25 21:46:18 +02:00
committed by Marius
parent 09acabc0c1
commit 1495624a9e
7 changed files with 16 additions and 8 deletions

View File

@@ -651,7 +651,7 @@ class CNCJobObject(FlatCAMObj, CNCjob):
# Show/Hide Advanced Options
if self.app.defaults["global_app_level"] == 'b':
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _("Basic"))
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _("Beginner"))
self.ui.sal_btn.hide()
self.ui.sal_btn.setChecked(False)

View File

@@ -67,7 +67,7 @@ class DocumentObject(FlatCAMObj):
# Show/Hide Advanced Options
if self.app.defaults["global_app_level"] == 'b':
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _("Basic"))
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _("Beginner"))
else:
self.ui.level.setText('<span style="color:red;"><b>%s</b></span>' % _("Advanced"))

View File

@@ -147,7 +147,7 @@ class ExcellonObject(FlatCAMObj, Excellon):
# Show/Hide Advanced Options
if self.app.defaults["global_app_level"] == 'b':
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _('Basic'))
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _('Beginner'))
self.ui.tools_table.setColumnHidden(4, True)
self.ui.tools_table.setColumnHidden(5, True)

View File

@@ -699,6 +699,12 @@ class GeometryObject(FlatCAMObj, Geometry):
#
# self.launch_job.connect(self.mtool_gen_cncjob)
# Show/Hide Advanced Options
if self.app.defaults["global_app_level"] == 'b':
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _('Beginner'))
else:
self.ui.level.setText('<span style="color:red;"><b>%s</b></span>' % _('Advanced'))
def on_properties(self, state):
if state:
self.ui.properties_frame.show()
@@ -3419,7 +3425,7 @@ class GeometryObject(FlatCAMObj, Geometry):
try:
new_options[option] = deepcopy(geo_obj.options[option])
except Exception as e:
self.app.log.warning("Failed to copy option %s. Error: %s" % (str(option), str(e)))
log.warning("Failed to copy option %s. Error: %s" % (str(option), str(e)))
# Expand lists
if type(geo_obj) is list:
@@ -3434,7 +3440,7 @@ class GeometryObject(FlatCAMObj, Geometry):
try:
new_solid_geometry += deepcopy(geo_obj.solid_geometry)
except Exception as e:
self.app.log.debug("GeometryObject.merge() --> %s" % str(e))
log.debug("GeometryObject.merge() --> %s" % str(e))
# find the tool_uid maximum value in the geo_final
try:

View File

@@ -172,7 +172,7 @@ class GerberObject(FlatCAMObj, Gerber):
# Show/Hide Advanced Options
if self.app.defaults["global_app_level"] == 'b':
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _('Basic'))
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _('Beginner'))
self.ui.apertures_table_label.hide()
self.ui.aperture_table_visibility_cb.hide()
@@ -1560,7 +1560,7 @@ class GerberObject(FlatCAMObj, Gerber):
try:
grb_final.options[option] = grb.options[option]
except KeyError:
self.app.log.warning("Failed to copy option.", option)
log.warning("Failed to copy option.", option)
try:
for geos in grb.solid_geometry:

View File

@@ -77,7 +77,7 @@ class ScriptObject(FlatCAMObj):
# Show/Hide Advanced Options
if self.app.defaults["global_app_level"] == 'b':
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _("Basic"))
self.ui.level.setText('<span style="color:green;"><b>%s</b></span>' % _("Beginner"))
else:
self.ui.level.setText('<span style="color:red;"><b>%s</b></span>' % _("Advanced"))