- fixed some of the strings that were left in the old way

- updated the POT file
- updated Romanian language partially
This commit is contained in:
Marius Stanciu 2019-09-13 18:27:00 +03:00
parent 6ea9b80ad6
commit f6cd63021e
21 changed files with 10467 additions and 9636 deletions

View File

@ -3834,31 +3834,14 @@ class App(QtCore.QObject):
tab_widget = QtWidgets.QTabWidget() tab_widget = QtWidgets.QTabWidget()
description_label = QtWidgets.QLabel( description_label = QtWidgets.QLabel(
_( "FlatCAM {version} {beta} ({date}) - {arch}<br>"
"FlatCAM {version} {beta} ({date}) - {arch}<br>" "<a href = \"http://flatcam.org/\">http://flatcam.org</a><br>".format(
"<a href = \"http://flatcam.org/\">http://flatcam.org</a><br>" version=version,beta=('BETA' if beta else ''),
).format(version=version, date=version_date,
beta=('BETA' if beta else ''), arch=platform.architecture()[0])
date=version_date,
arch=platform.architecture()[0])
) )
description_label.setOpenExternalLinks(True) description_label.setOpenExternalLinks(True)
programmers_label = QtWidgets.QLabel(
_(
"Juan Pablo Caram <BR>"
"<BR>"
"Denis Hayrullin<BR>"
"Kamil Sopko<BR>"
"Marius Stanciu<BR>"
"Matthieu Berthomé<BR><Br>"
"and many others found "
"<a href = \"https://bitbucket.org/jpcgt/flatcam/pull-requests/?state=MERGED\">here.</a><BR>"
"<BR>"
)
)
programmers_label.setOpenExternalLinks(True)
license_label = QtWidgets.QLabel( license_label = QtWidgets.QLabel(
_( _(
'(c) Copyright 2014 Juan Pablo Caram.\n\n' '(c) Copyright 2014 Juan Pablo Caram.\n\n'
@ -4400,7 +4383,7 @@ class App(QtCore.QObject):
for ext in exc_list: for ext in exc_list:
new_ext = new_ext + ext + ', ' new_ext = new_ext + ext + ', '
self.defaults["fa_excellon"] = new_ext self.defaults["fa_excellon"] = new_ext
self.inform.emit(_("[success] Selected Excellon file extensions registered with FlatCAM.")) self.inform.emit('[success] %s' % _("Selected Excellon file extensions registered with FlatCAM."))
if obj_type is None or obj_type == 'gcode': if obj_type is None or obj_type == 'gcode':
gco_list = self.ui.fa_defaults_form.fa_gcode_group.gco_list_text.get_value().replace(' ', '').split(',') gco_list = self.ui.fa_defaults_form.fa_gcode_group.gco_list_text.get_value().replace(' ', '').split(',')
@ -4616,7 +4599,7 @@ class App(QtCore.QObject):
if not isinstance(obj, FlatCAMGeometry): if not isinstance(obj, FlatCAMGeometry):
self.inform.emit('[ERROR_NOTCL] %s: %s' % self.inform.emit('[ERROR_NOTCL] %s: %s' %
(_("Expected a FlatCAMGeometry, got %s"), type(obj))) (_("Expected a FlatCAMGeometry, got"), type(obj)))
return return
obj.multigeo = False obj.multigeo = False
@ -4946,7 +4929,7 @@ class App(QtCore.QObject):
self.plot_all() self.plot_all()
self.inform.emit('[success] %s: %s' % self.inform.emit('[success] %s: %s' %
(_("Converted units to %s"), new_units)) (_("Converted units to"), new_units))
# self.ui.units_label.setText("[" + self.options["units"] + "]") # self.ui.units_label.setText("[" + self.options["units"] + "]")
self.set_screen_units(new_units) self.set_screen_units(new_units)
else: else:
@ -5725,7 +5708,7 @@ class App(QtCore.QObject):
if self.defaults["global_open_style"] is False: if self.defaults["global_open_style"] is False:
self.file_opened.emit("cncjob", filename) self.file_opened.emit("cncjob", filename)
self.file_saved.emit("cncjob", filename) self.file_saved.emit("cncjob", filename)
self.inform.emit(_("Saved to: %s") % filename) self.inform.emit('%s: %s' % (_("Saved to"), str(filename)))
def handleFindGCode(self): def handleFindGCode(self):
self.report_usage("handleFindGCode()") self.report_usage("handleFindGCode()")
@ -5854,8 +5837,8 @@ class App(QtCore.QObject):
return return
self.paint_tool.on_tool_add(dia=float(val)) self.paint_tool.on_tool_add(dia=float(val))
else: else:
self.inform.emit( self.inform.emit('[WARNING_NOTCL] %s...' %
_("[WARNING_NOTCL] Adding Tool cancelled ...")) _("Adding Tool cancelled"))
# and only if the tool is Solder Paste Dispensing Tool # and only if the tool is Solder Paste Dispensing Tool
elif tool_widget == self.paste_tool.toolName: elif tool_widget == self.paste_tool.toolName:
if ok: if ok:
@ -8017,7 +8000,7 @@ class App(QtCore.QObject):
pass pass
# add the tab if it was closed # add the tab if it was closed
self.ui.plot_tab_area.addTab(self.ui.cncjob_tab, _('%s') % name) self.ui.plot_tab_area.addTab(self.ui.cncjob_tab, '%s' % name)
self.ui.cncjob_tab.setObjectName('cncjob_tab') self.ui.cncjob_tab.setObjectName('cncjob_tab')
# delete the absolute and relative position and messages in the infobar # delete the absolute and relative position and messages in the infobar

View File

@ -210,7 +210,10 @@ class FlatCAMObj(QtCore.QObject):
self.default_data["name"] = self.ui.name_entry.get_value() self.default_data["name"] = self.ui.name_entry.get_value()
self.app.collection.update_view() self.app.collection.update_view()
if silent: if silent:
self.app.inform.emit(_("[success] Name changed from {old} to {new}").format(old=old_name, new=new_name)) self.app.inform.emit('[success] %s: %s %s: %s' % (
_("Name changed from"), str(old_name), _("to"), str(new_name)
)
)
def on_offset_button_click(self): def on_offset_button_click(self):
self.app.report_usage("obj_on_offset_button") self.app.report_usage("obj_on_offset_button")
@ -4465,9 +4468,12 @@ class FlatCAMGeometry(FlatCAMObj, Geometry):
try: try:
if self.special_group: if self.special_group:
self.app.inform.emit('[WARNING_NOTCL] %s' % self.app.inform.emit('[WARNING_NOTCL] %s %s %s.' %
_("This Geometry can't be processed because it is %s geometry." (_("This Geometry can't be processed because it is"),
) % str(self.special_group)) str(self.special_group),
_("geometry")
)
)
return return
except AttributeError: except AttributeError:
pass pass
@ -4756,9 +4762,9 @@ class FlatCAMGeometry(FlatCAMObj, Geometry):
# dia_cnc_dict['solid_geometry'] = cascaded_union([geo['geom'] for geo in dia_cnc_dict['gcode_parsed']]) # dia_cnc_dict['solid_geometry'] = cascaded_union([geo['geom'] for geo in dia_cnc_dict['gcode_parsed']])
try: try:
dia_cnc_dict['solid_geometry'] = tool_solid_geometry dia_cnc_dict['solid_geometry'] = tool_solid_geometry
self.app.inform.emit('[success] %s' % _("Finished G-Code processing...")) self.app.inform.emit('[success] %s...' % _("Finished G-Code processing"))
except Exception as e: except Exception as e:
self.app.inform.emit('[ERROR] %s' % _("G-Code processing failed with error: %s") % str(e)) self.app.inform.emit('[ERROR] %s: %s' % (_("G-Code processing failed with error"), str(e)))
app_obj.progress.emit(80) app_obj.progress.emit(80)
@ -4990,7 +4996,7 @@ class FlatCAMGeometry(FlatCAMObj, Geometry):
dia_cnc_dict['solid_geometry'] = tool_solid_geometry dia_cnc_dict['solid_geometry'] = tool_solid_geometry
self.app.inform.emit('[success] %s' % _("Finished G-Code processing...")) self.app.inform.emit('[success] %s' % _("Finished G-Code processing..."))
except Exception as e: except Exception as e:
self.app.inform.emit('[ERROR] %s' % _("G-Code processing failed with error: %s") % str(e)) self.app.inform.emit('[ERROR] %s: %s' % (_("G-Code processing failed with error"), str(e)))
# tell gcode_parse from which point to start drawing the lines depending on what kind of # tell gcode_parse from which point to start drawing the lines depending on what kind of
# object is the source of gcode # object is the source of gcode

View File

@ -89,7 +89,7 @@ def on_language_apply_click(app, restart=False):
if restart: if restart:
msgbox = QtWidgets.QMessageBox() msgbox = QtWidgets.QMessageBox()
msgbox.setText(_("The application will restart.")) msgbox.setText(_("The application will restart."))
msgbox.setInformativeText(_("Are you sure do you want to change the current language to %s?") % msgbox.setInformativeText('$s %s?' % _("Are you sure do you want to change the current language to"),
name.capitalize()) name.capitalize())
msgbox.setWindowTitle(_("Apply Language ...")) msgbox.setWindowTitle(_("Apply Language ..."))
msgbox.setWindowIcon(QtGui.QIcon('share/language32.png')) msgbox.setWindowIcon(QtGui.QIcon('share/language32.png'))

View File

@ -17,6 +17,9 @@ CAD program, and create G-Code for Isolation routing.
- upgraded the Script Editor to be able to run Tcl commands in batches - upgraded the Script Editor to be able to run Tcl commands in batches
- added some ToolTips for the buttons in the Code Editor - added some ToolTips for the buttons in the Code Editor
- converted the big strings that hold the shortcut keys descriptions to smaller string to make translations easier - converted the big strings that hold the shortcut keys descriptions to smaller string to make translations easier
- fixed some of the strings that were left in the old way
- updated the POT file
- updated Romanian language partially
12.09.2019 12.09.2019

View File

@ -6665,10 +6665,10 @@ class CNCjob(Geometry):
# if the offset is less than half of the total length or less than half of the total width of the # if the offset is less than half of the total length or less than half of the total width of the
# solid geometry it's obvious we can't do the offset # solid geometry it's obvious we can't do the offset
if -offset > ((c - a) / 2) or -offset > ((d - b) / 2): if -offset > ((c - a) / 2) or -offset > ((d - b) / 2):
self.app.inform.emit(_('[ERROR_NOTCL] %s' % self.app.inform.emit('[ERROR_NOTCL] %s' % _(
"The Tool Offset value is too negative to use " "The Tool Offset value is too negative to use "
"for the current_geometry.\n" "for the current_geometry.\n"
"Raise the value (in module) and try again.")) "Raise the value (in module) and try again."))
return 'fail' return 'fail'
# hack: make offset smaller by 0.0000000001 which is insignificant difference but allow the job # hack: make offset smaller by 0.0000000001 which is insignificant difference but allow the job
# to continue # to continue

View File

@ -1065,8 +1065,8 @@ class FCDrillResize(FCShapeTool):
# we reactivate the signals after the after the tool editing # we reactivate the signals after the after the tool editing
self.draw_app.tools_table_exc.itemChanged.connect(self.draw_app.on_tool_edit) self.draw_app.tools_table_exc.itemChanged.connect(self.draw_app.on_tool_edit)
self.draw_app.app.inform.emit('[success] Done. %s' % self.draw_app.app.inform.emit('[success] %s' %
_("Drill/Slot Resize completed.")) _("Done. Drill/Slot Resize completed."))
else: else:
self.draw_app.app.inform.emit('[WARNING_NOTCL] %s' % self.draw_app.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled. No drills/slots selected for resize ...")) _("Cancelled. No drills/slots selected for resize ..."))

View File

@ -632,8 +632,9 @@ class TransformEditorTool(FlatCAMTool):
self.transform_lay = QtWidgets.QVBoxLayout() self.transform_lay = QtWidgets.QVBoxLayout()
self.layout.addLayout(self.transform_lay) self.layout.addLayout(self.transform_lay)
# ## Title # ## Title
title_label = QtWidgets.QLabel("%s" % (_('Editor %s') % self.toolName)) title_label = QtWidgets.QLabel("%s %s" % (_('Editor'), str(self.toolName)))
title_label.setStyleSheet(""" title_label.setStyleSheet("""
QLabel QLabel
{ {
@ -2354,7 +2355,7 @@ class FCPath(FCPolygon):
self.draw_app.in_action = False self.draw_app.in_action = False
self.complete = True self.complete = True
self.draw_app.app.inform.emit(_("[success] Done. Path completed.")) self.draw_app.app.inform.emit('[success] %s' % _("Done. Path completed."))
def utility_geometry(self, data=None): def utility_geometry(self, data=None):
if len(self.points) > 0: if len(self.points) > 0:
@ -4583,9 +4584,12 @@ class FlatCAMGeoEditor(QtCore.QObject):
local_results += list(cp.get_objects()) local_results += list(cp.get_objects())
except Exception as e: except Exception as e:
log.debug("Could not Paint the polygons. %s" % str(e)) log.debug("Could not Paint the polygons. %s" % str(e))
self.app.inform.emit('[ERROR] %s' % self.app.inform.emit('[ERROR] %s\n%s' %
_("Could not do Paint. Try a different combination of parameters. " (_("Could not do Paint. Try a different combination of"
"Or a different method of Paint\n%s") % str(e)) " parameters. Or a different method of Paint"),
str(e)
)
)
return return
# add the result to the results list # add the result to the results list
@ -4595,7 +4599,7 @@ class FlatCAMGeoEditor(QtCore.QObject):
for r in results: for r in results:
self.add_shape(DrawToolShape(r)) self.add_shape(DrawToolShape(r))
self.app.inform.emit( self.app.inform.emit(
_("[success] Paint done.")) '[success] %s' % _("Paint done."))
self.replot() self.replot()

View File

@ -1520,7 +1520,7 @@ class FCSemiDisc(FCShapeTool):
def on_key(self, key): def on_key(self, key):
if key == 'D' or key == QtCore.Qt.Key_D: if key == 'D' or key == QtCore.Qt.Key_D:
self.direction = 'cw' if self.direction == 'ccw' else 'ccw' self.direction = 'cw' if self.direction == 'ccw' else 'ccw'
return _('Direction: %s') % self.direction.upper() return '%s: %s' % (_('Direction'), self.direction.upper())
if key == 'M' or key == QtCore.Qt.Key_M: if key == 'M' or key == QtCore.Qt.Key_M:
# delete the possible points made before this action; we want to start anew # delete the possible points made before this action; we want to start anew
@ -3764,7 +3764,8 @@ class FlatCAMGrbEditor(QtCore.QObject):
# and then add it to the storage elements (each storage elements is a member of a list # and then add it to the storage elements (each storage elements is a member of a list
def job_thread(aperture_id): def job_thread(aperture_id):
with self.app.proc_container.new(_("Adding aperture: %s geo ...") % str(aperture_id)): with self.app.proc_container.new('%s: %s %s...' %
(_("Adding aperture"), str(aperture_id), _("geo"))):
storage_elem = [] storage_elem = []
self.storage_dict[aperture_id] = {} self.storage_dict[aperture_id] = {}
@ -4849,7 +4850,7 @@ class TransformEditorTool(FlatCAMTool):
self.layout.addLayout(self.transform_lay) self.layout.addLayout(self.transform_lay)
# Title # Title
title_label = QtWidgets.QLabel("%s" % (_('Editor %s') % self.toolName)) title_label = QtWidgets.QLabel("%s %s" % (_('Editor'), self.toolName))
title_label.setStyleSheet(""" title_label.setStyleSheet("""
QLabel QLabel
{ {

View File

@ -2640,7 +2640,7 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
if self.app.geo_editor.active_tool.complete: if self.app.geo_editor.active_tool.complete:
self.app.geo_editor.on_shape_complete() self.app.geo_editor.on_shape_complete()
self.app.inform.emit(_("[success] Done.")) self.app.inform.emit('[success] %s' % _("Done."))
# automatically make the selection tool active after completing current action # automatically make the selection tool active after completing current action
self.app.geo_editor.select_tool('select') self.app.geo_editor.select_tool('select')
return return
@ -2652,7 +2652,7 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
if self.app.geo_editor.active_tool.complete: if self.app.geo_editor.active_tool.complete:
self.app.geo_editor.on_shape_complete() self.app.geo_editor.on_shape_complete()
self.app.inform.emit(_("[success] Done.")) self.app.inform.emit('[success] %s' % _("Done."))
# automatically make the selection tool active after completing current action # automatically make the selection tool active after completing current action
self.app.geo_editor.select_tool('select') self.app.geo_editor.select_tool('select')
@ -2660,7 +2660,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
if key == QtCore.Qt.Key_Escape or key == 'Escape': if key == QtCore.Qt.Key_Escape or key == 'Escape':
# TODO: ...? # TODO: ...?
# self.on_tool_select("select") # self.on_tool_select("select")
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled.")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled."))
self.app.geo_editor.delete_utility_geometry() self.app.geo_editor.delete_utility_geometry()
@ -2868,7 +2869,7 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
# Abort the current action # Abort the current action
if key == QtCore.Qt.Key_Escape or key == 'Escape': if key == QtCore.Qt.Key_Escape or key == 'Escape':
# self.on_tool_select("select") # self.on_tool_select("select")
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled.")) self.app.inform.emit('[WARNING_NOTCL] %s' % _("Cancelled."))
self.app.grb_editor.delete_utility_geometry() self.app.grb_editor.delete_utility_geometry()
@ -2884,7 +2885,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
self.app.grb_editor.delete_selected() self.app.grb_editor.delete_selected()
self.app.grb_editor.plot_all() self.app.grb_editor.plot_all()
else: else:
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled. Nothing selected to delete.")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled. Nothing selected to delete."))
return return
# Delete aperture in apertures table if delete key event comes from the Selected Tab # Delete aperture in apertures table if delete key event comes from the Selected Tab
@ -2968,7 +2970,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
self.app.grb_editor.active_tool.set_origin( self.app.grb_editor.active_tool.set_origin(
(self.app.grb_editor.snap_x, self.app.grb_editor.snap_y)) (self.app.grb_editor.snap_x, self.app.grb_editor.snap_y))
else: else:
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled. Nothing selected to copy.")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled. Nothing selected to copy."))
return return
# Add Disc Tool # Add Disc Tool
@ -3014,7 +3017,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
self.app.grb_editor.active_tool.set_origin( self.app.grb_editor.active_tool.set_origin(
(self.app.grb_editor.snap_x, self.app.grb_editor.snap_y)) (self.app.grb_editor.snap_x, self.app.grb_editor.snap_y))
else: else:
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled. Nothing selected to move.")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled. Nothing selected to move."))
return return
# Add Region Tool # Add Region Tool
@ -3079,7 +3083,7 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
if key == QtCore.Qt.Key_Escape or key == 'Escape': if key == QtCore.Qt.Key_Escape or key == 'Escape':
# TODO: ...? # TODO: ...?
# self.on_tool_select("select") # self.on_tool_select("select")
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled.")) self.app.inform.emit('[WARNING_NOTCL] %s' % _("Cancelled."))
self.app.exc_editor.delete_utility_geometry() self.app.exc_editor.delete_utility_geometry()
@ -3096,7 +3100,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
self.app.exc_editor.delete_selected() self.app.exc_editor.delete_selected()
self.app.exc_editor.replot() self.app.exc_editor.replot()
else: else:
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled. Nothing selected to delete.")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled. Nothing selected to delete."))
return return
# Delete tools in tools table if delete key event comes from the Selected Tab # Delete tools in tools table if delete key event comes from the Selected Tab
@ -3163,7 +3168,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
self.app.exc_editor.active_tool.set_origin( self.app.exc_editor.active_tool.set_origin(
(self.app.exc_editor.snap_x, self.app.exc_editor.snap_y)) (self.app.exc_editor.snap_x, self.app.exc_editor.snap_y))
else: else:
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled. Nothing selected to copy.")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled. Nothing selected to copy."))
return return
# Add Drill Hole Tool # Add Drill Hole Tool
@ -3209,7 +3215,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
self.app.exc_editor.active_tool.set_origin( self.app.exc_editor.active_tool.set_origin(
(self.app.exc_editor.snap_x, self.app.exc_editor.snap_y)) (self.app.exc_editor.snap_x, self.app.exc_editor.snap_y))
else: else:
self.app.inform.emit(_("[WARNING_NOTCL] Cancelled. Nothing selected to move.")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Cancelled. Nothing selected to move."))
return return
# Add Array of Slote Hole Tool # Add Array of Slote Hole Tool
@ -3243,12 +3250,16 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
val, ok = tool_add_popup.get_value() val, ok = tool_add_popup.get_value()
if ok: if ok:
self.app.exc_editor.on_tool_add(tooldia=val) self.app.exc_editor.on_tool_add(tooldia=val)
self.app.inform.emit( formated_val = '%.4f' % float(val)
_("[success] Added new tool with dia: {dia} {units}").format(dia='%.4f' % float(val), self.app.inform.emit('[success] %s: %s %s' %
units=str(self.units))) (_("Added new tool with dia"),
formated_val,
str(self.units)
)
)
else: else:
self.app.inform.emit( self.app.inform.emit(
_("[WARNING_NOTCL] Adding Tool cancelled ...")) '[WARNING_NOTCL] %s' % _("Adding Tool cancelled ..."))
return return
# Zoom Fit # Zoom Fit
@ -3392,7 +3403,8 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
def closeEvent(self, event): def closeEvent(self, event):
if self.app.save_in_progress: if self.app.save_in_progress:
self.app.inform.emit(_("[WARNING_NOTCL] Application is saving the project. Please wait ...")) self.app.inform.emit('[WARNING_NOTCL] %s' %
_("Application is saving the project. Please wait ..."))
else: else:
grect = self.geometry() grect = self.geometry()
@ -4828,7 +4840,7 @@ class GerberEditorPrefGroupUI(OptionsGroupUI):
self.adddim_entry = FCEntry() self.adddim_entry = FCEntry()
grid0.addWidget(self.adddim_entry, 5, 1) grid0.addWidget(self.adddim_entry, 5, 1)
self.grb_array_linear_label = QtWidgets.QLabel(_('<b>%s:</b>' % 'Linear Pad Array')) self.grb_array_linear_label = QtWidgets.QLabel('<b>%s:</b>' % _('Linear Pad Array'))
grid0.addWidget(self.grb_array_linear_label, 6, 0, 1, 2) grid0.addWidget(self.grb_array_linear_label, 6, 0, 1, 2)
# Linear Pad Array direction # Linear Pad Array direction
@ -5697,7 +5709,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI):
grid0.addWidget(self.drill_axis_radio, 4, 1) grid0.addWidget(self.drill_axis_radio, 4, 1)
# Linear Drill Array pitch distance # Linear Drill Array pitch distance
self.drill_pitch_label = QtWidgets.QLabel(_('%s:' % 'Pitch')) self.drill_pitch_label = QtWidgets.QLabel('%s:' % _('Pitch'))
self.drill_pitch_label.setToolTip( self.drill_pitch_label.setToolTip(
_("Pitch = Distance between elements of the array.") _("Pitch = Distance between elements of the array.")
) )
@ -6117,7 +6129,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI):
self.layout.addLayout(grid1) self.layout.addLayout(grid1)
# Toolchange X,Y # Toolchange X,Y
toolchange_xy_label = QtWidgets.QLabel(_('%s:' % 'Toolchange X-Y')) toolchange_xy_label = QtWidgets.QLabel('%s:' % _('Toolchange X-Y'))
toolchange_xy_label.setToolTip( toolchange_xy_label.setToolTip(
_("Toolchange X,Y position.") _("Toolchange X,Y position.")
) )

View File

@ -572,7 +572,7 @@ class CutOut(FlatCAMTool):
return "Could not retrieve object: %s" % name return "Could not retrieve object: %s" % name
if cutout_obj is None: if cutout_obj is None:
self.app.inform.emit('[ERROR_NOTCL] %s: %s' % (_("Object not found: %s"), cutout_obj)) self.app.inform.emit('[ERROR_NOTCL] %s: %s' % (_("Object not found"), str(name)))
try: try:
dia = float(self.dia.get_value()) dia = float(self.dia.get_value())

View File

@ -1080,11 +1080,11 @@ class NonCopperClear(FlatCAMTool, Gerber):
try: try:
self.ncc_obj = self.app.collection.get_by_name(self.obj_name) self.ncc_obj = self.app.collection.get_by_name(self.obj_name)
except Exception as e: except Exception as e:
self.app.inform.emit('[ERROR_NOTCL] %s' % _("Could not retrieve object: %s") % self.obj_name) self.app.inform.emit('[ERROR_NOTCL] %s: %s' % (_("Could not retrieve object"), str(self.obj_name)))
return "Could not retrieve object: %s" % self.obj_name return "Could not retrieve object: %s" % self.obj_name
if self.ncc_obj is None: if self.ncc_obj is None:
self.app.inform.emit('[ERROR_NOTCL] %s' % _("Object not found: %s") % self.ncc_obj) self.app.inform.emit('[ERROR_NOTCL] %s: %s' % (_("Object not found"), str(self.obj_name)))
return return
# use the selected tools in the tool table; get diameters for non-copper clear # use the selected tools in the tool table; get diameters for non-copper clear

View File

@ -217,7 +217,7 @@ class ToolPDF(FlatCAMTool):
time.sleep(0.1) time.sleep(0.1)
except Exception as e: except Exception as e:
log.debug("ToolPDF.open_pdf() --> %s" % str(e)) log.debug("ToolPDF.open_pdf() --> %s" % str(e))
self.app.inform.emit(_("[success] Opened: %s") % filename) self.app.inform.emit('[success] %s: %s' % (_("Opened"), str(filename)))
def layer_rendering_as_excellon(self, filename, ap_dict, layer_nr): def layer_rendering_as_excellon(self, filename, ap_dict, layer_nr):
outname = filename.split('/')[-1].split('\\')[-1] + "_%s" % str(layer_nr) outname = filename.split('/')[-1].split('\\')[-1] + "_%s" % str(layer_nr)

View File

@ -1233,11 +1233,11 @@ class ToolPaint(FlatCAMTool, Gerber):
# No polygon? # No polygon?
if poly is None: if poly is None:
self.app.log.warning('No polygon found.') self.app.log.warning('No polygon found.')
self.app.inform.emit(_('[WARNING] No polygon found.')) self.app.inform.emit('[WARNING] %s' % _('No polygon found.'))
return return
proc = self.app.proc_container.new(_("Painting polygon...")) proc = self.app.proc_container.new(_("Painting polygon..."))
self.app.inform.emit(_("Paint Tool. Painting polygon at location: %s") % str(inside_pt)) self.app.inform.emit('%s: %s' % (_("Paint Tool. Painting polygon at location"), str(inside_pt)))
name = outname if outname is not None else self.obj_name + "_paint" name = outname if outname is not None else self.obj_name + "_paint"
@ -1748,7 +1748,7 @@ class ToolPaint(FlatCAMTool, Gerber):
# print("Indexing...", end=' ') # print("Indexing...", end=' ')
# geo_obj.make_index() # geo_obj.make_index()
self.app.inform.emit(_("[success] Paint All Done.")) self.app.inform.emit('[success] %s' % _("Paint All Done."))
# Initializes the new geometry object # Initializes the new geometry object
def gen_paintarea_rest_machining(geo_obj, app_obj): def gen_paintarea_rest_machining(geo_obj, app_obj):
@ -2149,9 +2149,9 @@ class ToolPaint(FlatCAMTool, Gerber):
return "fail" return "fail"
except Exception as e: except Exception as e:
log.debug("Could not Paint the polygons. %s" % str(e)) log.debug("Could not Paint the polygons. %s" % str(e))
self.app.inform.emit('[ERROR] %s' % self.app.inform.emit('[ERROR] %s\n%s' %
_("Could not do Paint All. Try a different combination of parameters. " (_("Could not do Paint All. Try a different combination of parameters. "
"Or a different Method of paint\n%s") % str(e)) "Or a different Method of paint"), str(e)))
return return
pol_nr += 1 pol_nr += 1
@ -2209,7 +2209,7 @@ class ToolPaint(FlatCAMTool, Gerber):
# print("Indexing...", end=' ') # print("Indexing...", end=' ')
# geo_obj.make_index() # geo_obj.make_index()
self.app.inform.emit(_("[success] Paint Area Done.")) self.app.inform.emit('[success] %s' % _("Paint Area Done."))
# Initializes the new geometry object # Initializes the new geometry object
def gen_paintarea_rest_machining(geo_obj, app_obj): def gen_paintarea_rest_machining(geo_obj, app_obj):
@ -2307,9 +2307,9 @@ class ToolPaint(FlatCAMTool, Gerber):
return "fail" return "fail"
except Exception as e: except Exception as e:
log.debug("Could not Paint the polygons. %s" % str(e)) log.debug("Could not Paint the polygons. %s" % str(e))
self.app.inform.emit('[ERROR] %s' % self.app.inform.emit('[ERROR] %s\n%s' %
_("Could not do Paint All. Try a different combination of parameters. " (_("Could not do Paint All. Try a different combination of parameters. "
"Or a different Method of paint\n%s") % str(e)) "Or a different Method of paint"), str(e)))
return return
pol_nr += 1 pol_nr += 1

View File

@ -68,7 +68,7 @@ class TermWidget(QWidget):
if detail is None: if detail is None:
self._edit.setPlainText(_("...proccessing...")) self._edit.setPlainText(_("...proccessing..."))
else: else:
self._edit.setPlainText(_("...proccessing... [%s]") % detail) self._edit.setPlainText('%s [%s]' % (_("...proccessing..."), detail))
self._edit.setDisabled(True) self._edit.setDisabled(True)
self._edit.setFocus() self._edit.setFocus()

View File

@ -311,7 +311,7 @@ class ToolSub(FlatCAMTool):
log.debug("Working on promise: %s" % str(apid)) log.debug("Working on promise: %s" % str(apid))
with self.app.proc_container.new(_("Parsing aperture %s geometry ..." % str(apid))): with self.app.proc_container.new('%s %s %s...' % (_("Parsing aperture", str(apid), _("geometry")))):
for geo_el in geo: for geo_el in geo:
new_el = dict() new_el = dict()
@ -520,7 +520,7 @@ class ToolSub(FlatCAMTool):
if tool == "single": if tool == "single":
text = _("Parsing solid_geometry ...") text = _("Parsing solid_geometry ...")
else: else:
text = _("Parsing tool %s geometry ...") % str(tool) text = '%s %s %s...' % (_("Parsing tool"), str(tool), _("geometry"))
with self.app.proc_container.new(text): with self.app.proc_container.new(text):
# resulting paths are closed resulting into Polygons # resulting paths are closed resulting into Polygons

View File

@ -800,7 +800,8 @@ class ToolTransform(FlatCAMTool):
sel_obj.options['skew_y'] = num sel_obj.options['skew_y'] = num
self.app.object_changed.emit(sel_obj) self.app.object_changed.emit(sel_obj)
sel_obj.plot() sel_obj.plot()
self.app.inform.emit(_('[success] Skew on the %s axis done ...') % str(axis)) self.app.inform.emit('[success] %s %s %s...' %
(_('Skew on the'), str(axis), _("axis done")))
self.app.progress.emit(100) self.app.progress.emit(100)
except Exception as e: except Exception as e:

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff