diff --git a/FlatCAMApp.py b/FlatCAMApp.py index 977d7c5a..b46d32ba 100644 --- a/FlatCAMApp.py +++ b/FlatCAMApp.py @@ -422,6 +422,21 @@ class App(QtCore.QObject): # Gerber Editor "gerber_editor_sel_limit": self.ui.gerber_defaults_form.gerber_editor_group.sel_limit_entry, + "gerber_editor_newcode": self.ui.gerber_defaults_form.gerber_editor_group.addcode_entry, + "gerber_editor_newsize": self.ui.gerber_defaults_form.gerber_editor_group.addsize_entry, + "gerber_editor_newtype": self.ui.gerber_defaults_form.gerber_editor_group.addtype_combo, + "gerber_editor_newdim": self.ui.gerber_defaults_form.gerber_editor_group.adddim_entry, + "gerber_editor_array_size": self.ui.gerber_defaults_form.gerber_editor_group.grb_array_size_entry, + "gerber_editor_lin_axis": self.ui.gerber_defaults_form.gerber_editor_group.grb_axis_radio, + "gerber_editor_lin_pitch": self.ui.gerber_defaults_form.gerber_editor_group.grb_pitch_entry, + "gerber_editor_lin_angle": self.ui.gerber_defaults_form.gerber_editor_group.grb_angle_entry, + "gerber_editor_circ_dir": self.ui.gerber_defaults_form.gerber_editor_group.grb_circular_dir_radio, + "gerber_editor_circ_angle": + self.ui.gerber_defaults_form.gerber_editor_group.grb_circular_angle_entry, + "gerber_editor_scale_f": self.ui.gerber_defaults_form.gerber_editor_group.grb_scale_entry, + "gerber_editor_buff_f": self.ui.gerber_defaults_form.gerber_editor_group.grb_buff_entry, + "gerber_editor_ma_low": self.ui.gerber_defaults_form.gerber_editor_group.grb_ma_low_entry, + "gerber_editor_ma_high": self.ui.gerber_defaults_form.gerber_editor_group.grb_ma_high_entry, # Excellon General "excellon_plot": self.ui.excellon_defaults_form.excellon_gen_group.plot_cb, @@ -794,6 +809,20 @@ class App(QtCore.QObject): # Gerber Editor "gerber_editor_sel_limit": 30, + "gerber_editor_newcode": 10, + "gerber_editor_newsize": 0.8, + "gerber_editor_newtype": 'C', + "gerber_editor_newdim": "0.5, 0.5", + "gerber_editor_array_size": 5, + "gerber_editor_lin_axis": 'X', + "gerber_editor_lin_pitch": 1, + "gerber_editor_lin_angle": 0.0, + "gerber_editor_circ_dir": 'CW', + "gerber_editor_circ_angle": 0.0, + "gerber_editor_scale_f": 1.0, + "gerber_editor_buff_f": 0.1, + "gerber_editor_ma_low": 0.0, + "gerber_editor_ma_high": 1.0, # Excellon General "excellon_plot": True, diff --git a/README.md b/README.md index af57bf26..669d595b 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,12 @@ CAD program, and create G-Code for Isolation routing. ================================================= +19.08.2019 + +- updated the Edit -> Preferences to include also the Gerber Editor complete Preferences +- started to update the app strings to make it easier for future translations + + 18.08.2019 - made the exported preferences formatted therefore more easily read diff --git a/flatcamEditors/FlatCAMGrbEditor.py b/flatcamEditors/FlatCAMGrbEditor.py index 700c6591..5b11df2e 100644 --- a/flatcamEditors/FlatCAMGrbEditor.py +++ b/flatcamEditors/FlatCAMGrbEditor.py @@ -2202,6 +2202,7 @@ class FCApertureSelect(DrawTool): self.grb_editor_app.hide_tool('all') self.grb_editor_app.hide_tool('select') + self.grb_editor_app.array_frame.hide() try: QtGui.QGuiApplication.restoreOverrideCursor() @@ -2345,7 +2346,7 @@ class FlatCAMGrbEditor(QtCore.QObject): # ######################### # ### Gerber Apertures #### # ######################### - self.apertures_table_label = QtWidgets.QLabel(_('Apertures:')) + self.apertures_table_label = QtWidgets.QLabel('%s:' % _('Apertures')) self.apertures_table_label.setToolTip( _("Apertures Table for the Gerber Object.") ) @@ -2391,7 +2392,7 @@ class FlatCAMGrbEditor(QtCore.QObject): grid1 = QtWidgets.QGridLayout() self.apertures_box.addLayout(grid1) - apcode_lbl = QtWidgets.QLabel(_('Aperture Code:')) + apcode_lbl = QtWidgets.QLabel('%s:' % _('Aperture Code')) apcode_lbl.setToolTip( _("Code for the new aperture") ) @@ -2401,7 +2402,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.apcode_entry.setValidator(QtGui.QIntValidator(0, 999)) grid1.addWidget(self.apcode_entry, 1, 1) - apsize_lbl = QtWidgets.QLabel(_('Aperture Size:')) + apsize_lbl = QtWidgets.QLabel('%s:' % _('Aperture Size')) apsize_lbl.setToolTip( _("Size for the new aperture.\n" "If aperture type is 'R' or 'O' then\n" @@ -2415,7 +2416,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.apsize_entry.setValidator(QtGui.QDoubleValidator(0.0001, 99.9999, 4)) grid1.addWidget(self.apsize_entry, 2, 1) - aptype_lbl = QtWidgets.QLabel(_('Aperture Type:')) + aptype_lbl = QtWidgets.QLabel('%s:' % _('Aperture Type')) aptype_lbl.setToolTip( _("Select the type of new aperture. Can be:\n" "C = circular\n" @@ -2428,7 +2429,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.aptype_cb.addItems(['C', 'R', 'O']) grid1.addWidget(self.aptype_cb, 3, 1) - self.apdim_lbl = QtWidgets.QLabel(_('Aperture Dim:')) + self.apdim_lbl = QtWidgets.QLabel('%s:' % _('Aperture Dim')) self.apdim_lbl.setToolTip( _("Dimensions for the new aperture.\n" "Active only for rectangular apertures (type R).\n" @@ -2484,8 +2485,8 @@ class FlatCAMGrbEditor(QtCore.QObject): # Buffer distance self.buffer_distance_entry = FCEntry() - buf_form_layout.addRow(_("Buffer distance:"), self.buffer_distance_entry) - self.buffer_corner_lbl = QtWidgets.QLabel(_("Buffer corner:")) + buf_form_layout.addRow('%s:' % _("Buffer distance"), self.buffer_distance_entry) + self.buffer_corner_lbl = QtWidgets.QLabel('%s:' % _("Buffer corner")) self.buffer_corner_lbl.setToolTip( _("There are 3 types of corners:\n" " - 'Round': the corner is rounded.\n" @@ -2517,7 +2518,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.scale_tool_frame.hide() # Title - scale_title_lbl = QtWidgets.QLabel('%s' % _('Scale Aperture:')) + scale_title_lbl = QtWidgets.QLabel('%s:' % _('Scale Aperture')) scale_title_lbl.setToolTip( _("Scale a aperture in the aperture list") ) @@ -2527,7 +2528,7 @@ class FlatCAMGrbEditor(QtCore.QObject): scale_form_layout = QtWidgets.QFormLayout() self.scale_tools_box.addLayout(scale_form_layout) - self.scale_factor_lbl = QtWidgets.QLabel(_("Scale factor:")) + self.scale_factor_lbl = QtWidgets.QLabel('%s:' % _("Scale factor")) self.scale_factor_lbl.setToolTip( _("The factor by which to scale the selected aperture.\n" "Values can be between 0.0000 and 999.9999") @@ -2555,7 +2556,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.ma_tool_frame.hide() # Title - ma_title_lbl = QtWidgets.QLabel('%s' % _('Mark polygon areas:')) + ma_title_lbl = QtWidgets.QLabel('%s:' % _('Mark polygon areas')) ma_title_lbl.setToolTip( _("Mark the polygon areas.") ) @@ -2565,7 +2566,7 @@ class FlatCAMGrbEditor(QtCore.QObject): ma_form_layout = QtWidgets.QFormLayout() self.ma_tools_box.addLayout(ma_form_layout) - self.ma_upper_threshold_lbl = QtWidgets.QLabel(_("Area UPPER threshold:")) + self.ma_upper_threshold_lbl = QtWidgets.QLabel('%s:' % _("Area UPPER threshold")) self.ma_upper_threshold_lbl.setToolTip( _("The threshold value, all areas less than this are marked.\n" "Can have a value between 0.0000 and 9999.9999") @@ -2573,7 +2574,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.ma_upper_threshold_entry = FCEntry() self.ma_upper_threshold_entry.setValidator(QtGui.QDoubleValidator(0.0000, 9999.9999, 4)) - self.ma_lower_threshold_lbl = QtWidgets.QLabel(_("Area LOWER threshold:")) + self.ma_lower_threshold_lbl = QtWidgets.QLabel('%s:' % _("Area LOWER threshold")) self.ma_lower_threshold_lbl.setToolTip( _("The threshold value, all areas more than this are marked.\n" "Can have a value between 0.0000 and 9999.9999") @@ -2594,7 +2595,6 @@ class FlatCAMGrbEditor(QtCore.QObject): # ###################### # ### Add Pad Array #### # ###################### - # add a frame and inside add a vertical box layout. Inside this vbox layout I add # all the add Pad array widgets # this way I can hide/show the frame @@ -2627,7 +2627,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.array_form = QtWidgets.QFormLayout() self.array_box.addLayout(self.array_form) - self.pad_array_size_label = QtWidgets.QLabel(_('Nr of pads:')) + self.pad_array_size_label = QtWidgets.QLabel('%s:' % _('Nr of pads')) self.pad_array_size_label.setToolTip( _("Specify how many pads to be in the array.") ) @@ -2646,7 +2646,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.linear_form = QtWidgets.QFormLayout() self.linear_box.addLayout(self.linear_form) - self.pad_axis_label = QtWidgets.QLabel(_('Direction:')) + self.pad_axis_label = QtWidgets.QLabel('%s:' % _('Direction')) self.pad_axis_label.setToolTip( _("Direction on which the linear array is oriented:\n" "- 'X' - horizontal axis \n" @@ -2661,7 +2661,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.pad_axis_radio.set_value('X') self.linear_form.addRow(self.pad_axis_label, self.pad_axis_radio) - self.pad_pitch_label = QtWidgets.QLabel(_('Pitch:')) + self.pad_pitch_label = QtWidgets.QLabel('%s:' % _('Pitch')) self.pad_pitch_label.setToolTip( _("Pitch = Distance between elements of the array.") ) @@ -2670,7 +2670,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.pad_pitch_entry = LengthEntry() self.linear_form.addRow(self.pad_pitch_label, self.pad_pitch_entry) - self.linear_angle_label = QtWidgets.QLabel(_('Angle:')) + self.linear_angle_label = QtWidgets.QLabel('%s:' % _('Angle')) self.linear_angle_label.setToolTip( _( "Angle at which the linear array is placed.\n" "The precision is of max 2 decimals.\n" @@ -2691,7 +2691,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.circular_box.setContentsMargins(0, 0, 0, 0) self.array_circular_frame.setLayout(self.circular_box) - self.pad_direction_label = QtWidgets.QLabel(_('Direction:')) + self.pad_direction_label = QtWidgets.QLabel('%s:' % _('Direction')) self.pad_direction_label.setToolTip( _("Direction for circular array." "Can be CW = clockwise or CCW = counter clockwise.") @@ -2706,7 +2706,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.pad_direction_radio.set_value('CW') self.circular_form.addRow(self.pad_direction_label, self.pad_direction_radio) - self.pad_angle_label = QtWidgets.QLabel(_('Angle:')) + self.pad_angle_label = QtWidgets.QLabel('%s:' % _('Angle')) self.pad_angle_label.setToolTip( _("Angle at which each element in circular array is placed.") ) @@ -2944,23 +2944,24 @@ class FlatCAMGrbEditor(QtCore.QObject): self.tool2tooldia[i + 1] = tt_aperture # Init GUI - if self.units == 'MM': - self.buffer_distance_entry.set_value(0.01) - self.scale_factor_entry.set_value(1.0) - self.ma_upper_threshold_entry.set_value(1.0) - self.apsize_entry.set_value(1.00) - else: - self.buffer_distance_entry.set_value(0.0003937) - self.scale_factor_entry.set_value(0.03937) - self.ma_upper_threshold_entry.set_value(0.00155) - self.apsize_entry.set_value(0.039) - self.ma_lower_threshold_entry.set_value(0.0) - self.pad_array_size_entry.set_value(5) - self.pad_pitch_entry.set_value(2.54) - self.pad_angle_entry.set_value(12) - self.pad_direction_radio.set_value('CW') - self.pad_axis_radio.set_value('X') + self.buffer_distance_entry.set_value(self.app.defaults["gerber_editor_buff_f"]) + self.scale_factor_entry.set_value(self.app.defaults["gerber_editor_scale_f"]) + self.ma_upper_threshold_entry.set_value(self.app.defaults["gerber_editor_ma_low"]) + self.ma_lower_threshold_entry.set_value(self.app.defaults["gerber_editor_ma_high"]) + + self.apsize_entry.set_value(self.app.defaults["gerber_editor_newsize"]) + self.aptype_cb.set_value(self.app.defaults["gerber_editor_newtype"]) + self.apdim_entry.set_value(self.app.defaults["gerber_editor_newdim"]) + + self.pad_array_size_entry.set_value(self.app.defaults["gerber_editor_array_size"]) + # linear array + self.pad_axis_radio.set_value(self.app.defaults["gerber_editor_lin_axis"]) + self.pad_pitch_entry.set_value(self.app.defaults["gerber_editor_lin_pitch"]) + self.linear_angle_spinner.set_value(self.app.defaults["gerber_editor_lin_angle"]) + # circular array + self.pad_direction_radio.set_value(self.app.defaults["gerber_editor_circ_dir"]) + self.pad_angle_entry.set_value(self.app.defaults["gerber_editor_circ_angle"]) def build_ui(self, first_run=None): @@ -3113,7 +3114,7 @@ class FlatCAMGrbEditor(QtCore.QObject): self.apcode_entry.set_value(max(self.tool2tooldia.values()) + 1) except ValueError: # this means that the edited object has no apertures so we start with 10 (Gerber specifications) - self.apcode_entry.set_value(10) + self.apcode_entry.set_value(self.app.defaults["gerber_editor_newcode"]) def on_aperture_add(self, apid=None): self.is_modified = True diff --git a/flatcamGUI/FlatCAMGUI.py b/flatcamGUI/FlatCAMGUI.py index 28b6c25b..0f43f9e5 100644 --- a/flatcamGUI/FlatCAMGUI.py +++ b/flatcamGUI/FlatCAMGUI.py @@ -1,15 +1,15 @@ -# ########################################################## ## +# ########################################################## # FlatCAM: 2D Post-processing for Manufacturing # # http://flatcam.org # # Author: Juan Pablo Caram (c) # # Date: 2/5/2014 # # MIT Licence # -# ########################################################## ## +# ########################################################## -# ########################################################## ## +# ########################################################## # File Modified (major mod): Marius Adrian Stanciu # # Date: 3/10/2019 # -# ########################################################## ## +# ########################################################## from PyQt5.QtCore import QSettings from flatcamGUI.GUIElements import * @@ -3965,7 +3965,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): self.form_box = QtWidgets.QFormLayout() # Units for FlatCAM - self.unitslabel = QtWidgets.QLabel(_('Units:')) + self.unitslabel = QtWidgets.QLabel('%s:' % _('Units')) self.unitslabel.setToolTip(_("The default value for FlatCAM units.\n" "Whatever is selected here is set every time\n" "FLatCAM is started.")) @@ -3973,7 +3973,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): {'label': _('MM'), 'value': 'MM'}]) # Application Level for FlatCAM - self.app_level_label = QtWidgets.QLabel(_('APP. LEVEL:')) + self.app_level_label = QtWidgets.QLabel('%s:' % _('APP. LEVEL')) self.app_level_label.setToolTip(_("Choose the default level of usage for FlatCAM.\n" "BASIC level -> reduced functionality, best for beginner's.\n" "ADVANCED level -> full functionality.\n\n" @@ -3983,7 +3983,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): {'label': _('Advanced'), 'value': 'a'}]) # Languages for FlatCAM - self.languagelabel = QtWidgets.QLabel(_('Languages:')) + self.languagelabel = QtWidgets.QLabel('%s:' % _('Languages')) self.languagelabel.setToolTip(_("Set the language used throughout FlatCAM.")) self.language_cb = FCComboBox() self.languagespace = QtWidgets.QLabel('') @@ -3997,7 +3997,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): "applied at the next app start.")) # Shell StartUp CB - self.shell_startup_label = QtWidgets.QLabel(_('Shell at StartUp:')) + self.shell_startup_label = QtWidgets.QLabel('%s:' % _('Shell at StartUp')) self.shell_startup_label.setToolTip( _("Check this box if you want the shell to\n" "start automatically at startup.") @@ -4009,7 +4009,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): ) # Version Check CB - self.version_check_label = QtWidgets.QLabel(_('Version Check:')) + self.version_check_label = QtWidgets.QLabel('%s:' % _('Version Check')) self.version_check_label.setToolTip( _("Check this box if you want to check\n" "for a new version automatically at startup.") @@ -4021,7 +4021,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): ) # Send Stats CB - self.send_stats_label = QtWidgets.QLabel(_('Send Stats:')) + self.send_stats_label = QtWidgets.QLabel('%s:' % _('Send Stats')) self.send_stats_label.setToolTip( _("Check this box if you agree to send anonymous\n" "stats automatically at startup, to help improve FlatCAM.") @@ -4035,7 +4035,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): self.ois_version_check = OptionalInputSection(self.version_check_cb, [self.send_stats_cb]) # Select mouse pan button - self.panbuttonlabel = QtWidgets.QLabel(_('Pan Button:')) + self.panbuttonlabel = QtWidgets.QLabel('%s:' % _('Pan Button')) self.panbuttonlabel.setToolTip(_("Select the mouse button to use for panning:\n" "- MMB --> Middle Mouse Button\n" "- RMB --> Right Mouse Button")) @@ -4043,13 +4043,13 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): {'label': _('RMB'), 'value': '2'}]) # Multiple Selection Modifier Key - self.mselectlabel = QtWidgets.QLabel(_('Multiple Sel:')) + self.mselectlabel = QtWidgets.QLabel('%s:' % _('Multiple Sel:')) self.mselectlabel.setToolTip(_("Select the key used for multiple selection.")) self.mselect_radio = RadioSet([{'label': _('CTRL'), 'value': 'Control'}, {'label': _('SHIFT'), 'value': 'Shift'}]) # Project at StartUp CB - self.project_startup_label = QtWidgets.QLabel(_('Project at StartUp:')) + self.project_startup_label = QtWidgets.QLabel('%s:' % _('Project at StartUp')) self.project_startup_label.setToolTip( _("Check this box if you want the project/selected/tool tab area to\n" "to be shown automatically at startup.") @@ -4061,7 +4061,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): ) # Project autohide CB - self.project_autohide_label = QtWidgets.QLabel(_('Project AutoHide:')) + self.project_autohide_label = QtWidgets.QLabel('%s:' % _('Project AutoHide')) self.project_autohide_label.setToolTip( _("Check this box if you want the project/selected/tool tab area to\n" "hide automatically when there are no objects loaded and\n" @@ -4075,7 +4075,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): ) # Enable/Disable ToolTips globally - self.toggle_tooltips_label = QtWidgets.QLabel(_('Enable ToolTips:')) + self.toggle_tooltips_label = QtWidgets.QLabel('%s:' % _('Enable ToolTips')) self.toggle_tooltips_label.setToolTip( _("Check this box if you want to have toolTips displayed\n" "when hovering with mouse over items throughout the App.") @@ -4085,7 +4085,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): _("Check this box if you want to have toolTips displayed\n" "when hovering with mouse over items throughout the App.") ) - self.worker_number_label = QtWidgets.QLabel(_('Workers number:')) + self.worker_number_label = QtWidgets.QLabel('%s:' % _('Workers number')) self.worker_number_label.setToolTip( _("The number of Qthreads made available to the App.\n" "A bigger number may finish the jobs more quickly but\n" @@ -4106,7 +4106,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): self.worker_number_sb.set_range(2, 16) # Geometric tolerance - tol_label = QtWidgets.QLabel(_("Geo Tolerance:")) + tol_label = QtWidgets.QLabel('%s:' % _("Geo Tolerance")) tol_label.setToolTip(_( "This value can counter the effect of the Circle Steps\n" "parameter. Default value is 0.01.\n" @@ -4153,7 +4153,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): self.layout.addLayout(self.form_box) # Open behavior - self.open_style_cb = FCCheckBox(_('"Open" behavior')) + self.open_style_cb = FCCheckBox('%s' % _('"Open" behavior')) self.open_style_cb.setToolTip( _("When checked the path for the last saved file is used when saving files,\n" "and the path for the last opened file is used when opening files.\n\n" @@ -4186,7 +4186,7 @@ class GeneralAppPrefGroupUI(OptionsGroupUI): # Project LZMA Comppression Level self.compress_combo = FCComboBox() - self.compress_label = QtWidgets.QLabel(_('Compression Level:')) + self.compress_label = QtWidgets.QLabel('%s:' % _('Compression Level')) self.compress_label.setToolTip( _("The level of compression used when saving\n" "a FlatCAM project. Higher value means better compression\n" @@ -4221,28 +4221,28 @@ class GerberGenPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid0) # Solid CB - self.solid_cb = FCCheckBox(label=_('Solid')) + self.solid_cb = FCCheckBox(label='%s' % _('Solid')) self.solid_cb.setToolTip( _("Solid color polygons.") ) grid0.addWidget(self.solid_cb, 0, 0) # Multicolored CB - self.multicolored_cb = FCCheckBox(label=_('M-Color')) + self.multicolored_cb = FCCheckBox(label='%s' % _('M-Color')) self.multicolored_cb.setToolTip( _("Draw polygons in different colors.") ) grid0.addWidget(self.multicolored_cb, 0, 1) # Plot CB - self.plot_cb = FCCheckBox(label=_('Plot')) + self.plot_cb = FCCheckBox(label='%s' % _('Plot')) self.plot_options_label.setToolTip( _("Plot (show) this object.") ) grid0.addWidget(self.plot_cb, 0, 2) # Number of circle steps for circular aperture linear approximation - self.circle_steps_label = QtWidgets.QLabel(_("Circle Steps:")) + self.circle_steps_label = QtWidgets.QLabel('%s:' % _("Circle Steps")) self.circle_steps_label.setToolTip( _("The number of circle steps for Gerber \n" "circular aperture linear approximation.") @@ -4273,7 +4273,7 @@ class GerberOptPrefGroupUI(OptionsGroupUI): grid0 = QtWidgets.QGridLayout() self.layout.addLayout(grid0) - tdlabel = QtWidgets.QLabel(_('Tool dia:')) + tdlabel = QtWidgets.QLabel('%s:' % _('Tool dia')) tdlabel.setToolTip( _("Diameter of the cutting tool.") ) @@ -4282,7 +4282,7 @@ class GerberOptPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.iso_tool_dia_entry, 0, 1) # Nr of passes - passlabel = QtWidgets.QLabel(_('Width (# passes):')) + passlabel = QtWidgets.QLabel('%s:' % _('# Passes')) passlabel.setToolTip( _("Width of the isolation gap in\n" "number (integer) of tool widths.") @@ -4293,7 +4293,7 @@ class GerberOptPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.iso_width_entry, 1, 1) # Pass overlap - overlabel = QtWidgets.QLabel(_('Pass overlap:')) + overlabel = QtWidgets.QLabel('%s:' % _('Pass overlap')) overlabel.setToolTip( _("How much (fraction) of the tool width to overlap each tool pass.\n" "Example:\n" @@ -4303,7 +4303,7 @@ class GerberOptPrefGroupUI(OptionsGroupUI): self.iso_overlap_entry = FloatEntry() grid0.addWidget(self.iso_overlap_entry, 2, 1) - milling_type_label = QtWidgets.QLabel(_('Milling Type:')) + milling_type_label = QtWidgets.QLabel('%s:' % _('Milling Type')) milling_type_label.setToolTip( _("Milling type:\n" "- climb / best for precision milling and to reduce tool usage\n" @@ -4322,10 +4322,13 @@ class GerberOptPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.combine_passes_cb, 4, 0, 1, 2) # ## Clear non-copper regions - self.clearcopper_label = QtWidgets.QLabel("%s:" % _("Clear non-copper")) + self.clearcopper_label = QtWidgets.QLabel("%s:" % _("Non-copper regions")) self.clearcopper_label.setToolTip( - _("Create a Geometry object with\n" - "toolpaths to cut all non-copper regions.") + _("Create polygons covering the\n" + "areas without copper on the PCB.\n" + "Equivalent to the inverse of this\n" + "object. Can be used to remove all\n" + "copper from a specified region.") ) self.layout.addWidget(self.clearcopper_label) @@ -4333,7 +4336,7 @@ class GerberOptPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid1) # Margin - bmlabel = QtWidgets.QLabel(_('Boundary Margin:')) + bmlabel = QtWidgets.QLabel('%s:' % _('Boundary Margin')) bmlabel.setToolTip( _("Specify the edge of the PCB\n" "by drawing a box around all\n" @@ -4345,21 +4348,20 @@ class GerberOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.noncopper_margin_entry, 0, 1) # Rounded corners - self.noncopper_rounded_cb = FCCheckBox(label=_("Rounded corners")) + self.noncopper_rounded_cb = FCCheckBox(label=_("Rounded Geo")) self.noncopper_rounded_cb.setToolTip( - _("Creates a Geometry objects with polygons\n" - "covering the copper-free areas of the PCB.") + _("Resulting geometry will have rounded corners.") ) grid1.addWidget(self.noncopper_rounded_cb, 1, 0, 1, 2) # ## Bounding box - self.boundingbox_label = QtWidgets.QLabel(_('Bounding Box:')) + self.boundingbox_label = QtWidgets.QLabel('%s:' % _('Bounding Box')) self.layout.addWidget(self.boundingbox_label) grid2 = QtWidgets.QGridLayout() self.layout.addLayout(grid2) - bbmargin = QtWidgets.QLabel(_('Boundary Margin:')) + bbmargin = QtWidgets.QLabel('%s:' % _('Boundary Margin')) bbmargin.setToolTip( _("Distance of the edges of the box\n" "to the nearest polygon.") @@ -4368,7 +4370,7 @@ class GerberOptPrefGroupUI(OptionsGroupUI): self.bbmargin_entry = LengthEntry() grid2.addWidget(self.bbmargin_entry, 0, 1) - self.bbrounded_cb = FCCheckBox(label=_("Rounded corners")) + self.bbrounded_cb = FCCheckBox(label='%s' % _("Rounded Geo")) self.bbrounded_cb.setToolTip( _("If the bounding box is \n" "to have rounded corners\n" @@ -4463,7 +4465,7 @@ class GerberExpPrefGroupUI(OptionsGroupUI): self.layout.addLayout(form) # Gerber Units - self.gerber_units_label = QtWidgets.QLabel(_('Units:')) + self.gerber_units_label = QtWidgets.QLabel('%s:' % _('Units')) self.gerber_units_label.setToolTip( _("The units used in the Gerber file.") ) @@ -4513,7 +4515,7 @@ class GerberExpPrefGroupUI(OptionsGroupUI): form.addRow(self.digits_label, hlay1) # Gerber Zeros - self.zeros_label = QtWidgets.QLabel(_('Zeros:')) + self.zeros_label = QtWidgets.QLabel('%s:' % _('Zeros')) self.zeros_label.setAlignment(QtCore.Qt.AlignLeft) self.zeros_label.setToolTip( _("This sets the type of Gerber zeros.\n" @@ -4556,7 +4558,7 @@ class GerberEditorPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid0) # Selection Limit - self.sel_limit_label = QtWidgets.QLabel(_("Selection limit:")) + self.sel_limit_label = QtWidgets.QLabel('%s:' % _("Selection limit")) self.sel_limit_label.setToolTip( _("Set the number of selected Gerber geometry\n" "items above which the utility geometry\n" @@ -4569,6 +4571,177 @@ class GerberEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.sel_limit_label, 0, 0) grid0.addWidget(self.sel_limit_entry, 0, 1) + # New aperture code + self.addcode_entry_lbl = QtWidgets.QLabel('%s:' % _('New Aperture code')) + self.addcode_entry_lbl.setToolTip( + _("Code for the new aperture") + ) + + self.addcode_entry = FCEntry() + self.addcode_entry.setValidator(QtGui.QIntValidator(0, 99)) + + grid0.addWidget(self.addcode_entry_lbl, 1, 0) + grid0.addWidget(self.addcode_entry, 1, 1) + + # New aperture size + self.addsize_entry_lbl = QtWidgets.QLabel('%s:' % _('New Aperture size')) + self.addsize_entry_lbl.setToolTip( + _("Size for the new aperture") + ) + + self.addsize_entry = FCEntry() + self.addsize_entry.setValidator(QtGui.QDoubleValidator(0.0001, 99.9999, 4)) + + grid0.addWidget(self.addsize_entry_lbl, 2, 0) + grid0.addWidget(self.addsize_entry, 2, 1) + + # New aperture type + self.addtype_combo_lbl = QtWidgets.QLabel('%s:' % _('New Aperture type')) + self.addtype_combo_lbl.setToolTip( + _("Type for the new aperture.\n" + "Can be 'C', 'R' or 'O'.") + ) + + self.addtype_combo = FCComboBox() + self.addtype_combo.addItems(['C', 'R', 'O']) + + grid0.addWidget(self.addtype_combo_lbl, 3, 0) + grid0.addWidget(self.addtype_combo, 3, 1) + + # Number of pads in a pad array + self.grb_array_size_label = QtWidgets.QLabel('%s:' % _('Nr of pads')) + self.grb_array_size_label.setToolTip( + _("Specify how many pads to be in the array.") + ) + + self.grb_array_size_entry = LengthEntry() + + grid0.addWidget(self.grb_array_size_label, 4, 0) + grid0.addWidget(self.grb_array_size_entry, 4, 1) + + self.adddim_label = QtWidgets.QLabel('%s:' % _('Aperture Dimensions')) + self.adddim_label.setToolTip( + _("Diameters of the cutting tools, separated by ','") + ) + grid0.addWidget(self.adddim_label, 5, 0) + self.adddim_entry = FCEntry() + grid0.addWidget(self.adddim_entry, 5, 1) + + self.grb_array_linear_label = QtWidgets.QLabel(_('%s:' % 'Linear Pad Array')) + grid0.addWidget(self.grb_array_linear_label, 6, 0, 1, 2) + + # Linear Pad Array direction + self.grb_axis_label = QtWidgets.QLabel('%s:' % _('Linear Dir.')) + self.grb_axis_label.setToolTip( + _("Direction on which the linear array is oriented:\n" + "- 'X' - horizontal axis \n" + "- 'Y' - vertical axis or \n" + "- 'Angle' - a custom angle for the array inclination") + ) + + self.grb_axis_radio = RadioSet([{'label': _('X'), 'value': 'X'}, + {'label': _('Y'), 'value': 'Y'}, + {'label': _('Angle'), 'value': 'A'}]) + + grid0.addWidget(self.grb_axis_label, 7, 0) + grid0.addWidget(self.grb_axis_radio, 7, 1) + + # Linear Pad Array pitch distance + self.grb_pitch_label = QtWidgets.QLabel('%s:' % _('Pitch')) + self.grb_pitch_label.setToolTip( + _("Pitch = Distance between elements of the array.") + ) + # self.drill_pitch_label.setMinimumWidth(100) + self.grb_pitch_entry = LengthEntry() + + grid0.addWidget(self.grb_pitch_label, 8, 0) + grid0.addWidget(self.grb_pitch_entry, 8, 1) + + # Linear Pad Array custom angle + self.grb_angle_label = QtWidgets.QLabel('%s:' % _('Angle')) + self.grb_angle_label.setToolTip( + _("Angle at which each element in circular array is placed.") + ) + self.grb_angle_entry = LengthEntry() + + grid0.addWidget(self.grb_angle_label, 9, 0) + grid0.addWidget(self.grb_angle_entry, 9, 1) + + self.grb_array_circ_label = QtWidgets.QLabel('%s:' % _('Circular Pad Array')) + grid0.addWidget(self.grb_array_circ_label, 10, 0, 1, 2) + + # Circular Pad Array direction + self.grb_circular_direction_label = QtWidgets.QLabel('%s:' % _('Circular Dir.')) + self.grb_circular_direction_label.setToolTip( + _("Direction for circular array.\n" + "Can be CW = clockwise or CCW = counter clockwise.") + ) + + self.grb_circular_dir_radio = RadioSet([{'label': _('CW'), 'value': 'CW'}, + {'label': _('CCW'), 'value': 'CCW'}]) + + grid0.addWidget(self.grb_circular_direction_label, 11, 0) + grid0.addWidget(self.grb_circular_dir_radio, 11, 1) + + # Circular Pad Array Angle + self.grb_circular_angle_label = QtWidgets.QLabel('%s:' % _('Circ. Angle')) + self.grb_circular_angle_label.setToolTip( + _("Angle at which each element in circular array is placed.") + ) + self.grb_circular_angle_entry = LengthEntry() + + grid0.addWidget(self.grb_circular_angle_label, 12, 0) + grid0.addWidget(self.grb_circular_angle_entry, 12, 1) + + self.grb_array_tools_b_label = QtWidgets.QLabel('%s:' % _('Buffer Tool')) + grid0.addWidget(self.grb_array_tools_b_label, 13, 0, 1, 2) + + # Buffer Distance + self.grb_buff_label = QtWidgets.QLabel('%s:' % _('Buffer distance')) + self.grb_buff_label.setToolTip( + _("Distance at which to buffer the Gerber element.") + ) + self.grb_buff_entry = LengthEntry() + + grid0.addWidget(self.grb_buff_label, 14, 0) + grid0.addWidget(self.grb_buff_entry, 14, 1) + + self.grb_array_tools_s_label = QtWidgets.QLabel('%s:' % _('Scale Tool')) + grid0.addWidget(self.grb_array_tools_s_label, 15, 0, 1, 2) + + # Scale Factor + self.grb_scale_label = QtWidgets.QLabel('%s:' % _('Scale factor')) + self.grb_scale_label.setToolTip( + _("Factor to scale the Gerber element.") + ) + self.grb_scale_entry = LengthEntry() + + grid0.addWidget(self.grb_scale_label, 16, 0) + grid0.addWidget(self.grb_scale_entry, 16, 1) + + self.grb_array_tools_ma_label = QtWidgets.QLabel('%s:' % _('Mark Area Tool')) + grid0.addWidget(self.grb_array_tools_ma_label, 17, 0, 1, 2) + + # Mark area Tool low threshold + self.grb_ma_low_label = QtWidgets.QLabel('%s:' % _('Threshold low')) + self.grb_ma_low_label.setToolTip( + _("Threshold value under which the apertures are not marked.") + ) + self.grb_ma_low_entry = LengthEntry() + + grid0.addWidget(self.grb_ma_low_label, 18, 0) + grid0.addWidget(self.grb_ma_low_entry, 18, 1) + + # Mark area Tool high threshold + self.grb_ma_high_label = QtWidgets.QLabel('%s:' % _('Threshold low')) + self.grb_ma_high_label.setToolTip( + _("Threshold value over which the apertures are not marked.") + ) + self.grb_ma_high_entry = LengthEntry() + + grid0.addWidget(self.grb_ma_high_label, 19, 0) + grid0.addWidget(self.grb_ma_high_entry, 19, 1) + self.layout.addStretch() @@ -4627,7 +4800,7 @@ class ExcellonGenPrefGroupUI(OptionsGroupUI): hlay1 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay1) - self.excellon_format_in_label = QtWidgets.QLabel(_("INCH:")) + self.excellon_format_in_label = QtWidgets.QLabel('%s:' % _("INCH")) self.excellon_format_in_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_format_in_label.setToolTip( _("Default values for INCH are 2:4")) @@ -4660,7 +4833,7 @@ class ExcellonGenPrefGroupUI(OptionsGroupUI): hlay2 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay2) - self.excellon_format_mm_label = QtWidgets.QLabel(_("METRIC:")) + self.excellon_format_mm_label = QtWidgets.QLabel('%s:' % _("METRIC")) self.excellon_format_mm_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_format_mm_label.setToolTip( _("Default values for METRIC are 3:3")) @@ -4694,7 +4867,7 @@ class ExcellonGenPrefGroupUI(OptionsGroupUI): grid2 = QtWidgets.QGridLayout() self.layout.addLayout(grid2) - self.excellon_zeros_label = QtWidgets.QLabel(_('Default Zeros:')) + self.excellon_zeros_label = QtWidgets.QLabel('%s:' % _('Default Zeros')) self.excellon_zeros_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_zeros_label.setToolTip( _("This sets the type of Excellon zeros.\n" @@ -4718,7 +4891,7 @@ class ExcellonGenPrefGroupUI(OptionsGroupUI): ) grid2.addWidget(self.excellon_zeros_radio, 0, 1) - self.excellon_units_label = QtWidgets.QLabel(_('Default Units:')) + self.excellon_units_label = QtWidgets.QLabel('%s:' % _('Default Units')) self.excellon_units_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_units_label.setToolTip( _("This sets the default units of Excellon files.\n" @@ -4770,7 +4943,7 @@ class ExcellonGenPrefGroupUI(OptionsGroupUI): ) grid2.addWidget(self.excellon_optimization_radio, 4, 1) - self.optimization_time_label = QtWidgets.QLabel(_('Optimization Time: ')) + self.optimization_time_label = QtWidgets.QLabel('%s:' % _('Optimization Time')) self.optimization_time_label.setAlignment(QtCore.Qt.AlignLeft) self.optimization_time_label.setToolTip( _("When OR-Tools Metaheuristic (MH) is enabled there is a\n" @@ -4819,7 +4992,7 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): self.setTitle(str(_("Excellon Options"))) # ## Create CNC Job - self.cncjob_label = QtWidgets.QLabel(_('Create CNC Job')) + self.cncjob_label = QtWidgets.QLabel('%s' % _('Create CNC Job')) self.cncjob_label.setToolTip( _("Parameters used to create a CNC Job object\n" "for this drill object.") @@ -4829,7 +5002,7 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): grid2 = QtWidgets.QGridLayout() self.layout.addLayout(grid2) - cutzlabel = QtWidgets.QLabel(_('Cut Z:')) + cutzlabel = QtWidgets.QLabel('%s:' % _('Cut Z')) cutzlabel.setToolTip( _("Drill depth (negative)\n" "below the copper surface.") @@ -4838,7 +5011,7 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): self.cutz_entry = LengthEntry() grid2.addWidget(self.cutz_entry, 0, 1) - travelzlabel = QtWidgets.QLabel(_('Travel Z:')) + travelzlabel = QtWidgets.QLabel('%s:' % _('Travel Z')) travelzlabel.setToolTip( _("Tool height when travelling\n" "across the XY plane.") @@ -4848,7 +5021,7 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): grid2.addWidget(self.travelz_entry, 1, 1) # Tool change: - toolchlabel = QtWidgets.QLabel(_("Tool change:")) + toolchlabel = QtWidgets.QLabel('%s:' % _("Tool change")) toolchlabel.setToolTip( _("Include tool-change sequence\n" "in G-Code (Pause for tool change).") @@ -4857,25 +5030,27 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): grid2.addWidget(toolchlabel, 2, 0) grid2.addWidget(self.toolchange_cb, 2, 1) - toolchangezlabel = QtWidgets.QLabel(_('Toolchange Z:')) + toolchangezlabel = QtWidgets.QLabel('%s:' % _('Toolchange Z')) toolchangezlabel.setToolTip( - _("Toolchange Z position.") + _("Z-axis position (height) for\n" + "tool change.") ) grid2.addWidget(toolchangezlabel, 3, 0) self.toolchangez_entry = LengthEntry() grid2.addWidget(self.toolchangez_entry, 3, 1) - frlabel = QtWidgets.QLabel(_('Feedrate:')) + frlabel = QtWidgets.QLabel('%s:' % _('Feedrate (Plunge):')) frlabel.setToolTip( _("Tool speed while drilling\n" - "(in units per minute).") + "(in units per minute).\n" + "This is for linear move G01.") ) grid2.addWidget(frlabel, 4, 0) self.feedrate_entry = LengthEntry() grid2.addWidget(self.feedrate_entry, 4, 1) # Spindle speed - spdlabel = QtWidgets.QLabel(_('Spindle Speed:')) + spdlabel = QtWidgets.QLabel('%s:' % _('Spindle Speed')) spdlabel.setToolTip( _("Speed of the spindle\n" "in RPM (optional)") @@ -4885,7 +5060,7 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): grid2.addWidget(self.spindlespeed_entry, 5, 1) # Spindle direction - spindle_dir_label = QtWidgets.QLabel(_('Spindle dir.:')) + spindle_dir_label = QtWidgets.QLabel('%s:' % _('Spindle dir.')) spindle_dir_label.setToolTip( _("This sets the direction that the spindle is rotating.\n" "It can be either:\n" @@ -4899,14 +5074,14 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): grid2.addWidget(self.spindledir_radio, 6, 1) # Dwell - dwelllabel = QtWidgets.QLabel(_('Dwell:')) + dwelllabel = QtWidgets.QLabel('%s:' % _('Dwell')) dwelllabel.setToolTip( _("Pause to allow the spindle to reach its\n" "speed before cutting.") ) dwelltime = QtWidgets.QLabel(_('Duration:')) dwelltime.setToolTip( - _("Number of milliseconds for spindle to dwell.") + _("Number of time units for spindle to dwell.") ) self.dwell_cb = FCCheckBox() self.dwelltime_entry = FCEntry() @@ -4918,10 +5093,10 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): self.ois_dwell_exc = OptionalInputSection(self.dwell_cb, [self.dwelltime_entry]) # postprocessor selection - pp_excellon_label = QtWidgets.QLabel(_("Postprocessor:")) + pp_excellon_label = QtWidgets.QLabel('%s:' % _("Postprocessor")) pp_excellon_label.setToolTip( - _("The postprocessor file that dictates\n" - "gcode output.") + _("The postprocessor JSON file that dictates\n" + "Gcode output.") ) grid2.addWidget(pp_excellon_label, 9, 0) self.pp_excellon_name_cb = FCComboBox() @@ -4929,7 +5104,7 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): grid2.addWidget(self.pp_excellon_name_cb, 9, 1) # ### Choose what to use for Gcode creation: Drills, Slots or Both - excellon_gcode_type_label = QtWidgets.QLabel(_('Gcode: ')) + excellon_gcode_type_label = QtWidgets.QLabel('%s' % _('Gcode')) excellon_gcode_type_label.setToolTip( _("Choose what to use for GCode generation:\n" "'Drills', 'Slots' or 'Both'.\n" @@ -4947,20 +5122,20 @@ class ExcellonOptPrefGroupUI(OptionsGroupUI): self.excellon_gcode_type_radio.setVisible(False) # ### Milling Holes ## ## - self.mill_hole_label = QtWidgets.QLabel(_('Mill Holes')) + self.mill_hole_label = QtWidgets.QLabel('%s' % _('Mill Holes')) self.mill_hole_label.setToolTip( _("Create Geometry for milling holes.") ) grid2.addWidget(excellon_gcode_type_label, 11, 0, 1, 2) - tdlabel = QtWidgets.QLabel(_('Drill Tool dia:')) + tdlabel = QtWidgets.QLabel('%s:' % _('Drill Tool dia')) tdlabel.setToolTip( _("Diameter of the cutting tool.") ) grid2.addWidget(tdlabel, 12, 0) self.tooldia_entry = LengthEntry() grid2.addWidget(self.tooldia_entry, 12, 1) - stdlabel = QtWidgets.QLabel(_('Slot Tool dia:')) + stdlabel = QtWidgets.QLabel('%s:' % _('Slot Tool dia')) stdlabel.setToolTip( _("Diameter of the cutting tool\n" "when milling slots.") @@ -4993,7 +5168,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): # ## ADVANCED OPTIONS ### # ####################### - self.cncjob_label = QtWidgets.QLabel(_('Advanced Options:')) + self.cncjob_label = QtWidgets.QLabel('%s:' % _('Advanced Options')) self.cncjob_label.setToolTip( _("Parameters used to create a CNC Job object\n" "for this drill object that are shown when App Level is Advanced.") @@ -5003,7 +5178,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): grid1 = QtWidgets.QGridLayout() self.layout.addLayout(grid1) - offsetlabel = QtWidgets.QLabel(_('Offset Z:')) + offsetlabel = QtWidgets.QLabel('%s:' % _('Offset Z')) offsetlabel.setToolTip( _("Some drill bits (the larger ones) need to drill deeper\n" "to create the desired exit hole diameter due of the tip shape.\n" @@ -5012,7 +5187,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): self.offset_entry = LengthEntry() grid1.addWidget(self.offset_entry, 0, 1) - toolchange_xy_label = QtWidgets.QLabel(_('Toolchange X,Y:')) + toolchange_xy_label = QtWidgets.QLabel('%s:' % _('Toolchange X,Y')) toolchange_xy_label.setToolTip( _("Toolchange X,Y position.") ) @@ -5020,7 +5195,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): self.toolchangexy_entry = FCEntry() grid1.addWidget(self.toolchangexy_entry, 1, 1) - startzlabel = QtWidgets.QLabel(_('Start move Z:')) + startzlabel = QtWidgets.QLabel('%s:' % _('Start move Z')) startzlabel.setToolTip( _("Height of the tool just after start.\n" "Delete the value if you don't need this feature.") @@ -5029,7 +5204,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): self.estartz_entry = FloatEntry() grid1.addWidget(self.estartz_entry, 2, 1) - endzlabel = QtWidgets.QLabel(_('End move Z:')) + endzlabel = QtWidgets.QLabel('%s:' % _('End move Z')) endzlabel.setToolTip( _("Height of the tool after\n" "the last move at the end of the job.") @@ -5038,7 +5213,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): self.eendz_entry = LengthEntry() grid1.addWidget(self.eendz_entry, 3, 1) - fr_rapid_label = QtWidgets.QLabel(_('Feedrate Rapids:')) + fr_rapid_label = QtWidgets.QLabel('%s:' % _('Feedrate Rapids')) fr_rapid_label.setToolTip( _("Tool speed while drilling\n" "(in units per minute).\n" @@ -5051,7 +5226,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.feedrate_rapid_entry, 4, 1) # Probe depth - self.pdepth_label = QtWidgets.QLabel(_("Probe Z depth:")) + self.pdepth_label = QtWidgets.QLabel('%s:' % _("Probe Z depth")) self.pdepth_label.setToolTip( _("The maximum depth that the probe is allowed\n" "to probe. Negative value, in current units.") @@ -5061,7 +5236,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.pdepth_entry, 5, 1) # Probe feedrate - self.feedrate_probe_label = QtWidgets.QLabel(_("Feedrate Probe:")) + self.feedrate_probe_label = QtWidgets.QLabel('%s:' % _("Feedrate Probe")) self.feedrate_probe_label.setToolTip( _("The feedrate used while the probe is probing.") ) @@ -5080,7 +5255,7 @@ class ExcellonAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(fplungelabel, 7, 0) grid1.addWidget(self.fplunge_cb, 7, 1) - fretractlabel = QtWidgets.QLabel(_('Fast Retract:')) + fretractlabel = QtWidgets.QLabel('%s:' % _('Fast Retract')) fretractlabel.setToolTip( _("Exit hole strategy.\n" " - When uncheked, while exiting the drilled hole the drill bit\n" @@ -5115,7 +5290,7 @@ class ExcellonExpPrefGroupUI(OptionsGroupUI): self.layout.addLayout(form) # Excellon Units - self.excellon_units_label = QtWidgets.QLabel(_('Units:')) + self.excellon_units_label = QtWidgets.QLabel('%s:' % _('Units')) self.excellon_units_label.setToolTip( _("The units used in the Excellon file.") ) @@ -5190,7 +5365,7 @@ class ExcellonExpPrefGroupUI(OptionsGroupUI): form.addRow(self.format_label, self.format_radio) # Excellon Zeros - self.zeros_label = QtWidgets.QLabel(_('Zeros:')) + self.zeros_label = QtWidgets.QLabel('%s:' % _('Zeros')) self.zeros_label.setAlignment(QtCore.Qt.AlignLeft) self.zeros_label.setToolTip( _("This sets the type of Excellon zeros.\n" @@ -5213,7 +5388,7 @@ class ExcellonExpPrefGroupUI(OptionsGroupUI): form.addRow(self.zeros_label, self.zeros_radio) # Slot type - self.slot_type_label = QtWidgets.QLabel(_('Slot type:')) + self.slot_type_label = QtWidgets.QLabel('%s:' % _('Slot type')) self.slot_type_label.setAlignment(QtCore.Qt.AlignLeft) self.slot_type_label.setToolTip( _("This sets how the slots will be exported.\n" @@ -5264,7 +5439,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid0) # Selection Limit - self.sel_limit_label = QtWidgets.QLabel(_("Selection limit:")) + self.sel_limit_label = QtWidgets.QLabel('%s:' % _("Selection limit")) self.sel_limit_label.setToolTip( _("Set the number of selected Excellon geometry\n" "items above which the utility geometry\n" @@ -5278,7 +5453,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.sel_limit_entry, 0, 1) # New tool diameter - self.addtool_entry_lbl = QtWidgets.QLabel(_('New Tool Dia:')) + self.addtool_entry_lbl = QtWidgets.QLabel('%s:' % _('New Tool Dia')) self.addtool_entry_lbl.setToolTip( _("Diameter for the new tool") ) @@ -5290,7 +5465,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.addtool_entry, 1, 1) # Number of drill holes in a drill array - self.drill_array_size_label = QtWidgets.QLabel(_('Nr of drills:')) + self.drill_array_size_label = QtWidgets.QLabel('%s:' % _('Nr of drills')) self.drill_array_size_label.setToolTip( _("Specify how many drills to be in the array.") ) @@ -5301,7 +5476,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.drill_array_size_label, 2, 0) grid0.addWidget(self.drill_array_size_entry, 2, 1) - self.drill_array_linear_label = QtWidgets.QLabel(_('Linear Drill Array:')) + self.drill_array_linear_label = QtWidgets.QLabel('%s:' % _('Linear Drill Array')) grid0.addWidget(self.drill_array_linear_label, 3, 0, 1, 2) # Linear Drill Array direction @@ -5321,7 +5496,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.drill_axis_radio, 4, 1) # Linear Drill Array pitch distance - self.drill_pitch_label = QtWidgets.QLabel(_('Pitch:')) + self.drill_pitch_label = QtWidgets.QLabel(_('%s:' % 'Pitch')) self.drill_pitch_label.setToolTip( _("Pitch = Distance between elements of the array.") ) @@ -5332,7 +5507,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.drill_pitch_entry, 5, 1) # Linear Drill Array custom angle - self.drill_angle_label = QtWidgets.QLabel(_('Angle:')) + self.drill_angle_label = QtWidgets.QLabel('%s:' % _('Angle')) self.drill_angle_label.setToolTip( _("Angle at which each element in circular array is placed.") ) @@ -5341,11 +5516,11 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.drill_angle_label, 6, 0) grid0.addWidget(self.drill_angle_entry, 6, 1) - self.drill_array_circ_label = QtWidgets.QLabel(_('Circular Drill Array:')) + self.drill_array_circ_label = QtWidgets.QLabel('%s:' % _('Circular Drill Array')) grid0.addWidget(self.drill_array_circ_label, 7, 0, 1, 2) # Circular Drill Array direction - self.drill_circular_direction_label = QtWidgets.QLabel(_('Circular Dir.:')) + self.drill_circular_direction_label = QtWidgets.QLabel('%s:' % _('Circular Dir.')) self.drill_circular_direction_label.setToolTip( _("Direction for circular array.\n" "Can be CW = clockwise or CCW = counter clockwise.") @@ -5358,7 +5533,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.drill_circular_dir_radio, 8, 1) # Circular Drill Array Angle - self.drill_circular_angle_label = QtWidgets.QLabel(_('Circ. Angle:')) + self.drill_circular_angle_label = QtWidgets.QLabel('%s:' % _('Circ. Angle')) self.drill_circular_angle_label.setToolTip( _("Angle at which each element in circular array is placed.") ) @@ -5369,11 +5544,11 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): # ##### SLOTS ##### # ################# - self.drill_array_circ_label = QtWidgets.QLabel(_('Slots:')) + self.drill_array_circ_label = QtWidgets.QLabel('%s:' % _('Slots')) grid0.addWidget(self.drill_array_circ_label, 10, 0, 1, 2) # Slot length - self.slot_length_label = QtWidgets.QLabel(_('Length:')) + self.slot_length_label = QtWidgets.QLabel('%s:' % _('Length')) self.slot_length_label.setToolTip( _("Length = The length of the slot.") ) @@ -5384,7 +5559,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.slot_length_entry, 11, 1) # Slot direction - self.slot_axis_label = QtWidgets.QLabel(_('Direction:')) + self.slot_axis_label = QtWidgets.QLabel('%s:' % _('Direction')) self.slot_axis_label.setToolTip( _("Direction on which the slot is oriented:\n" "- 'X' - horizontal axis \n" @@ -5400,7 +5575,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.slot_axis_radio, 12, 1) # Slot custom angle - self.slot_angle_label = QtWidgets.QLabel(_('Angle:')) + self.slot_angle_label = QtWidgets.QLabel('%s:' % _('Angle')) self.slot_angle_label.setToolTip( _("Angle at which the slot is placed.\n" "The precision is of max 2 decimals.\n" @@ -5420,11 +5595,11 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): # #### SLOTS ARRAY ####### # ######################## - self.slot_array_linear_label = QtWidgets.QLabel(_('Linear Slot Array:')) + self.slot_array_linear_label = QtWidgets.QLabel('%s:' % _('Linear Slot Array')) grid0.addWidget(self.slot_array_linear_label, 14, 0, 1, 2) # Number of slot holes in a drill array - self.slot_array_size_label = QtWidgets.QLabel(_('Nr of slots:')) + self.slot_array_size_label = QtWidgets.QLabel('%s:' % _('Nr of slots')) self.drill_array_size_label.setToolTip( _("Specify how many slots to be in the array.") ) @@ -5436,7 +5611,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.slot_array_size_entry, 15, 1) # Linear Slot Array direction - self.slot_array_axis_label = QtWidgets.QLabel(_('Linear Dir.:')) + self.slot_array_axis_label = QtWidgets.QLabel('%s:' % _('Linear Dir.')) self.slot_array_axis_label.setToolTip( _("Direction on which the linear array is oriented:\n" "- 'X' - horizontal axis \n" @@ -5452,7 +5627,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.slot_array_axis_radio, 16, 1) # Linear Slot Array pitch distance - self.slot_array_pitch_label = QtWidgets.QLabel(_('Pitch:')) + self.slot_array_pitch_label = QtWidgets.QLabel('%s:' % _('Pitch')) self.slot_array_pitch_label.setToolTip( _("Pitch = Distance between elements of the array.") ) @@ -5463,7 +5638,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.slot_array_pitch_entry, 17, 1) # Linear Slot Array custom angle - self.slot_array_angle_label = QtWidgets.QLabel(_('Angle:')) + self.slot_array_angle_label = QtWidgets.QLabel('%s:' % _('Angle')) self.slot_array_angle_label.setToolTip( _("Angle at which each element in circular array is placed.") ) @@ -5472,11 +5647,11 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.slot_array_angle_label, 18, 0) grid0.addWidget(self.slot_array_angle_entry, 18, 1) - self.slot_array_circ_label = QtWidgets.QLabel(_('Circular Slot Array:')) + self.slot_array_circ_label = QtWidgets.QLabel('%s:' % _('Circular Slot Array')) grid0.addWidget(self.slot_array_circ_label, 19, 0, 1, 2) # Circular Slot Array direction - self.slot_array_circular_direction_label = QtWidgets.QLabel(_('Circular Dir.:')) + self.slot_array_circular_direction_label = QtWidgets.QLabel('%s:' % _('Circular Dir.')) self.slot_array_circular_direction_label.setToolTip( _("Direction for circular array.\n" "Can be CW = clockwise or CCW = counter clockwise.") @@ -5489,7 +5664,7 @@ class ExcellonEditorPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.slot_array_circular_dir_radio, 20, 1) # Circular Slot Array Angle - self.slot_array_circular_angle_label = QtWidgets.QLabel(_('Circ. Angle:')) + self.slot_array_circular_angle_label = QtWidgets.QLabel('%s:' % _('Circ. Angle')) self.slot_array_circular_angle_label.setToolTip( _("Angle at which each element in circular array is placed.") ) @@ -5523,7 +5698,7 @@ class GeometryGenPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid0) # Number of circle steps for circular aperture linear approximation - self.circle_steps_label = QtWidgets.QLabel(_("Circle Steps:")) + self.circle_steps_label = QtWidgets.QLabel('%s:' % _("Circle Steps")) self.circle_steps_label.setToolTip( _("The number of circle steps for Geometry \n" "circle and arc shapes linear approximation.") @@ -5537,7 +5712,7 @@ class GeometryGenPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.tools_label, 2, 0, 1, 2) # Tooldia - tdlabel = QtWidgets.QLabel(_('Tool dia:')) + tdlabel = QtWidgets.QLabel('%s:' % _('Tool dia')) tdlabel.setToolTip( _("Diameters of the cutting tools, separated by ','") ) @@ -5558,7 +5733,7 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): # ------------------------------ # ## Create CNC Job # ------------------------------ - self.cncjob_label = QtWidgets.QLabel(_('Create CNC Job:')) + self.cncjob_label = QtWidgets.QLabel('%s:' % _('Create CNC Job')) self.cncjob_label.setToolTip( _("Create a CNC Job object\n" "tracing the contours of this\n" @@ -5570,7 +5745,7 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid1) # Cut Z - cutzlabel = QtWidgets.QLabel(_('Cut Z:')) + cutzlabel = QtWidgets.QLabel('%s:' % _('Cut Z')) cutzlabel.setToolTip( _("Cutting depth (negative)\n" "below the copper surface.") @@ -5580,14 +5755,19 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.cutz_entry, 0, 1) # Multidepth CheckBox - self.multidepth_cb = FCCheckBox(label=_('Multidepth')) + self.multidepth_cb = FCCheckBox(label=_('Multi-Depth')) self.multidepth_cb.setToolTip( - _("Multidepth usage: True or False.") + _( + "Use multiple passes to limit\n" + "the cut depth in each pass. Will\n" + "cut multiple times until Cut Z is\n" + "reached." + ) ) grid1.addWidget(self.multidepth_cb, 1, 0) # Depth/pass - dplabel = QtWidgets.QLabel(_('Depth/Pass:')) + dplabel = QtWidgets.QLabel('%s:' % _('Depth/Pass')) dplabel.setToolTip( _("The depth to cut on each pass,\n" "when multidepth is enabled.\n" @@ -5603,7 +5783,7 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): self.ois_multidepth = OptionalInputSection(self.multidepth_cb, [self.depthperpass_entry]) # Travel Z - travelzlabel = QtWidgets.QLabel(_('Travel Z:')) + travelzlabel = QtWidgets.QLabel('%s:' % _('Travel Z')) travelzlabel.setToolTip( _("Height of the tool when\n" "moving without cutting.") @@ -5613,26 +5793,31 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.travelz_entry, 3, 1) # Tool change: - toolchlabel = QtWidgets.QLabel(_("Tool change:")) + toolchlabel = QtWidgets.QLabel('%s:' % _("Tool change")) toolchlabel.setToolTip( - _("Include tool-change sequence\n" - "in G-Code (Pause for tool change).") + _( + "Include tool-change sequence\n" + "in the Machine Code (Pause for tool change)." + ) ) self.toolchange_cb = FCCheckBox() grid1.addWidget(toolchlabel, 4, 0) grid1.addWidget(self.toolchange_cb, 4, 1) # Toolchange Z - toolchangezlabel = QtWidgets.QLabel(_('Toolchange Z:')) + toolchangezlabel = QtWidgets.QLabel('%s:' % _('Toolchange Z')) toolchangezlabel.setToolTip( - _("Toolchange Z position.") + _( + "Z-axis position (height) for\n" + "tool change." + ) ) grid1.addWidget(toolchangezlabel, 5, 0) self.toolchangez_entry = LengthEntry() grid1.addWidget(self.toolchangez_entry, 5, 1) # Feedrate X-Y - frlabel = QtWidgets.QLabel(_('Feed Rate X-Y:')) + frlabel = QtWidgets.QLabel('%s:' % _('Feed Rate X-Y')) frlabel.setToolTip( _("Cutting speed in the XY\n" "plane in units per minute") @@ -5642,7 +5827,7 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.cncfeedrate_entry, 6, 1) # Feedrate Z (Plunge) - frz_label = QtWidgets.QLabel(_('Feed Rate Z:')) + frz_label = QtWidgets.QLabel('%s:' % _('Feed Rate Z')) frz_label.setToolTip( _("Cutting speed in the XY\n" "plane in units per minute.\n" @@ -5653,17 +5838,20 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.cncplunge_entry, 7, 1) # Spindle Speed - spdlabel = QtWidgets.QLabel(_('Spindle speed:')) + spdlabel = QtWidgets.QLabel('%s:' % _('Spindle speed')) spdlabel.setToolTip( - _("Speed of the spindle\n" - "in RPM (optional)") + _( + "Speed of the spindle in RPM (optional).\n" + "If LASER postprocessor is used,\n" + "this value is the power of laser." + ) ) grid1.addWidget(spdlabel, 8, 0) self.cncspindlespeed_entry = IntEntry(allow_empty=True) grid1.addWidget(self.cncspindlespeed_entry, 8, 1) # Spindle direction - spindle_dir_label = QtWidgets.QLabel(_('Spindle dir.:')) + spindle_dir_label = QtWidgets.QLabel('%s:' % _('Spindle dir.')) spindle_dir_label.setToolTip( _("This sets the direction that the spindle is rotating.\n" "It can be either:\n" @@ -5677,14 +5865,14 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.spindledir_radio, 9, 1) # Dwell - self.dwell_cb = FCCheckBox(label=_('Dwell:')) + self.dwell_cb = FCCheckBox(label='%s:' % _('Dwell')) self.dwell_cb.setToolTip( _("Pause to allow the spindle to reach its\n" "speed before cutting.") ) - dwelltime = QtWidgets.QLabel(_('Duration:')) + dwelltime = QtWidgets.QLabel('%s:' % _('Duration')) dwelltime.setToolTip( - _("Number of milliseconds for spindle to dwell.") + _("Number of time units for spindle to dwell.") ) self.dwelltime_entry = FCEntry() grid1.addWidget(self.dwell_cb, 10, 0) @@ -5694,10 +5882,10 @@ class GeometryOptPrefGroupUI(OptionsGroupUI): self.ois_dwell = OptionalInputSection(self.dwell_cb, [self.dwelltime_entry]) # postprocessor selection - pp_label = QtWidgets.QLabel(_("Postprocessor:")) + pp_label = QtWidgets.QLabel('%s:' % _("Postprocessor")) pp_label.setToolTip( - _("The postprocessor file that dictates\n" - "Machine Code output.") + _("The Postprocessor file that dictates\n" + "the Machine Code (like GCode, RML, HPGL) output.") ) grid1.addWidget(pp_label, 12, 0) self.pp_geometry_name_cb = FCComboBox() @@ -5717,7 +5905,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): # ------------------------------ # ## Advanced Options # ------------------------------ - self.cncjob_label = QtWidgets.QLabel(_('Advanced Options:')) + self.cncjob_label = QtWidgets.QLabel('%s:' % _('Advanced Options')) self.cncjob_label.setToolTip( _("Parameters to create a CNC Job object\n" "tracing the contours of a Geometry object.") @@ -5728,7 +5916,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid1) # Toolchange X,Y - toolchange_xy_label = QtWidgets.QLabel(_('Toolchange X,Y:')) + toolchange_xy_label = QtWidgets.QLabel(_('%s:' % 'Toolchange X-Y')) toolchange_xy_label.setToolTip( _("Toolchange X,Y position.") ) @@ -5737,7 +5925,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.toolchangexy_entry, 1, 1) # Start move Z - startzlabel = QtWidgets.QLabel(_('Start move Z:')) + startzlabel = QtWidgets.QLabel('%s:' % _('Start move Z')) startzlabel.setToolTip( _("Height of the tool just after starting the work.\n" "Delete the value if you don't need this feature.") @@ -5747,7 +5935,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.gstartz_entry, 2, 1) # End move Z - endzlabel = QtWidgets.QLabel(_('End move Z:')) + endzlabel = QtWidgets.QLabel('%s:' % _('End move Z')) endzlabel.setToolTip( _("Height of the tool after\n" "the last move at the end of the job.") @@ -5757,7 +5945,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.gendz_entry, 3, 1) # Feedrate rapids - fr_rapid_label = QtWidgets.QLabel(_('Feedrate Rapids:')) + fr_rapid_label = QtWidgets.QLabel('%s:' % _('Feed Rate Rapids')) fr_rapid_label.setToolTip( _("Cutting speed in the XY plane\n" "(in units per minute).\n" @@ -5770,7 +5958,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.cncfeedrate_rapid_entry, 4, 1) # End move extra cut - self.extracut_cb = FCCheckBox(label=_('Re-cut 1st pt.')) + self.extracut_cb = FCCheckBox(label='%s' % _('Re-cut 1st pt.')) self.extracut_cb.setToolTip( _("In order to remove possible\n" "copper leftovers where first cut\n" @@ -5780,7 +5968,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.extracut_cb, 5, 0) # Probe depth - self.pdepth_label = QtWidgets.QLabel(_("Probe Z depth:")) + self.pdepth_label = QtWidgets.QLabel('%s:' % _("Probe Z depth")) self.pdepth_label.setToolTip( _("The maximum depth that the probe is allowed\n" "to probe. Negative value, in current units.") @@ -5790,7 +5978,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.pdepth_entry, 6, 1) # Probe feedrate - self.feedrate_probe_label = QtWidgets.QLabel(_("Feedrate Probe:")) + self.feedrate_probe_label = QtWidgets.QLabel('%s:' % _("Feedrate Probe")) self.feedrate_probe_label.setToolTip( _("The feedrate used while the probe is probing.") ) @@ -5799,7 +5987,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.feedrate_probe_entry, 7, 1) # Fast Move from Z Toolchange - fplungelabel = QtWidgets.QLabel(_('Fast Plunge:')) + fplungelabel = QtWidgets.QLabel('%s:' % _('Fast Plunge')) fplungelabel.setToolTip( _("By checking this, the vertical move from\n" "Z_Toolchange to Z_move is done with G0,\n" @@ -5811,7 +5999,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.fplunge_cb, 8, 1) # Size of trace segment on X axis - segx_label = QtWidgets.QLabel(_("Seg. X size:")) + segx_label = QtWidgets.QLabel('%s:' % _("Seg. X size")) segx_label.setToolTip( _("The size of the trace segment on the X axis.\n" "Useful for auto-leveling.\n" @@ -5822,7 +6010,7 @@ class GeometryAdvOptPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.segx_entry, 9, 1) # Size of trace segment on Y axis - segy_label = QtWidgets.QLabel(_("Seg. Y size:")) + segy_label = QtWidgets.QLabel('%s:' % _("Seg. Y size")) segy_label.setToolTip( _("The size of the trace segment on the Y axis.\n" "Useful for auto-leveling.\n" @@ -5853,7 +6041,7 @@ class GeometryEditorPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid0) # Selection Limit - self.sel_limit_label = QtWidgets.QLabel(_("Selection limit:")) + self.sel_limit_label = QtWidgets.QLabel('%s:' % _("Selection limit")) self.sel_limit_label.setToolTip( _("Set the number of selected geometry\n" "items above which the utility geometry\n" @@ -5888,13 +6076,11 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): # Plot CB # self.plot_cb = QtWidgets.QCheckBox('Plot') self.plot_cb = FCCheckBox(_('Plot Object')) - self.plot_cb.setToolTip( - "Plot (show) this object." - ) + self.plot_cb.setToolTip(_("Plot (show) this object.")) grid0.addWidget(self.plot_cb, 0, 0) # Plot Kind - self.cncplot_method_label = QtWidgets.QLabel(_("Plot kind:")) + self.cncplot_method_label = QtWidgets.QLabel('%s:' % _("Plot kind:")) self.cncplot_method_label.setToolTip( _("This selects the kind of geometries on the canvas to plot.\n" "Those can be either of type 'Travel' which means the moves\n" @@ -5913,10 +6099,12 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): grid0.addWidget(QtWidgets.QLabel(''), 1, 2) # Display Annotation - self.annotation_label = QtWidgets.QLabel(_("Display Annotation:")) + self.annotation_label = QtWidgets.QLabel('%s:' % _("Display Annotation")) self.annotation_label.setToolTip( _("This selects if to display text annotation on the plot.\n" - "When checked it will display numbers in order for each end\n") + "When checked it will display numbers in order for each end\n" + "of a travel line." + ) ) self.annotation_cb = FCCheckBox() @@ -5925,7 +6113,7 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): grid0.addWidget(QtWidgets.QLabel(''), 2, 2) # Annotation Font Size - self.annotation_fontsize_label = QtWidgets.QLabel(_("Annotation Size:")) + self.annotation_fontsize_label = QtWidgets.QLabel('%s:' % _("Annotation Size")) self.annotation_fontsize_label.setToolTip( _("The font size of the annotation text. In pixels.") ) @@ -5935,7 +6123,7 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): grid0.addWidget(QtWidgets.QLabel(''), 3, 2) # Annotation Font Color - self.annotation_color_label = QtWidgets.QLabel(_('Annotation Color:')) + self.annotation_color_label = QtWidgets.QLabel('%s:' % _('Annotation Color')) self.annotation_color_label.setToolTip( _("Set the font color for the annotation texts.") ) @@ -5958,7 +6146,7 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): # ################################################################### # Number of circle steps for circular aperture linear approximation # # ################################################################### - self.steps_per_circle_label = QtWidgets.QLabel(_("Circle Steps:")) + self.steps_per_circle_label = QtWidgets.QLabel('%s:' % _("Circle Steps")) self.steps_per_circle_label.setToolTip( _("The number of circle steps for GCode \n" "circle and arc shapes linear approximation.") @@ -5968,7 +6156,7 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.steps_per_circle_entry, 5, 1) # Tool dia for plot - tdlabel = QtWidgets.QLabel(_('Tool dia:')) + tdlabel = QtWidgets.QLabel('%s:' % _('Tool dia')) tdlabel.setToolTip( _("Diameter of the tool to be\n" "rendered in the plot.") @@ -5978,7 +6166,7 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.tooldia_entry, 6, 1) # Number of decimals to use in GCODE coordinates - cdeclabel = QtWidgets.QLabel(_('Coords dec.:')) + cdeclabel = QtWidgets.QLabel('%s:' % _('Coords dec.')) cdeclabel.setToolTip( _("The number of decimals to be used for \n" "the X, Y, Z coordinates in CNC code (GCODE, etc.)") @@ -5988,7 +6176,7 @@ class CNCJobGenPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.coords_dec_entry, 7, 1) # Number of decimals to use in GCODE feedrate - frdeclabel = QtWidgets.QLabel(_('Feedrate dec.:')) + frdeclabel = QtWidgets.QLabel('%s:' % _('Feedrate dec.')) frdeclabel.setToolTip( _("The number of decimals to be used for \n" "the Feedrate parameter in CNC code (GCODE, etc.)") @@ -6016,7 +6204,7 @@ class CNCJobOptPrefGroupUI(OptionsGroupUI): self.layout.addWidget(self.export_gcode_label) # Prepend to G-Code - prependlabel = QtWidgets.QLabel(_('Prepend to G-Code:')) + prependlabel = QtWidgets.QLabel('%s:' % _('Prepend to G-Code')) prependlabel.setToolTip( _("Type here any G-Code commands you would\n" "like to add at the beginning of the G-Code file.") @@ -6027,7 +6215,7 @@ class CNCJobOptPrefGroupUI(OptionsGroupUI): self.layout.addWidget(self.prepend_text) # Append text to G-Code - appendlabel = QtWidgets.QLabel(_('Append to G-Code:')) + appendlabel = QtWidgets.QLabel('%s:' % _('Append to G-Code')) appendlabel.setToolTip( _("Type here any G-Code commands you would\n" "like to append to the generated file.\n" @@ -6049,7 +6237,7 @@ class CNCJobAdvOptPrefGroupUI(OptionsGroupUI): self.setTitle(str(_("CNC Job Adv. Options"))) # ## Export G-Code - self.export_gcode_label = QtWidgets.QLabel("%s:" % _("Export G-Code")) + self.export_gcode_label = QtWidgets.QLabel("%s:" % _("Export CNC Code")) self.export_gcode_label.setToolTip( _("Export and save G-Code to\n" "make this object to a file.") @@ -6057,12 +6245,18 @@ class CNCJobAdvOptPrefGroupUI(OptionsGroupUI): self.layout.addWidget(self.export_gcode_label) # Prepend to G-Code - toolchangelabel = QtWidgets.QLabel(_('Toolchange G-Code:')) + toolchangelabel = QtWidgets.QLabel('%s:' % _('Toolchange G-Code')) toolchangelabel.setToolTip( - _("Type here any G-Code commands you would\n" - "like to be executed when Toolchange event is encountered.\n" - "This will constitute a Custom Toolchange GCode,\n" - "or a Toolchange Macro.") + _( + "Type here any G-Code commands you would\n" + "like to be executed when Toolchange event is encountered.\n" + "This will constitute a Custom Toolchange GCode,\n" + "or a Toolchange Macro.\n" + "The FlatCAM variables are surrounded by '%' symbol.\n\n" + "WARNING: it can be used only with a postprocessor file\n" + "that has 'toolchange_custom' in it's name and this is built\n" + "having as template the 'Toolchange Custom' posprocessor file." + ) ) self.layout.addWidget(toolchangelabel) @@ -6073,7 +6267,7 @@ class CNCJobAdvOptPrefGroupUI(OptionsGroupUI): self.layout.addLayout(hlay) # Toolchange Replacement GCode - self.toolchange_cb = FCCheckBox(label=_('Use Toolchange Macro')) + self.toolchange_cb = FCCheckBox(label='%s' % _('Use Toolchange Macro')) self.toolchange_cb.setToolTip( _("Check this box if you want to use\n" "a Custom Toolchange GCode (macro).") @@ -6143,7 +6337,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): grid0 = QtWidgets.QGridLayout() self.layout.addLayout(grid0) - ncctdlabel = QtWidgets.QLabel(_('Tools dia:')) + ncctdlabel = QtWidgets.QLabel('%s:' % _('Tools dia')) ncctdlabel.setToolTip( _("Diameters of the cutting tools, separated by ','") ) @@ -6173,7 +6367,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.ncc_order_label, 1, 0) grid0.addWidget(self.ncc_order_radio, 1, 1) - nccoverlabel = QtWidgets.QLabel(_('Overlap Rate:')) + nccoverlabel = QtWidgets.QLabel('%s:' % _('Overlap Rate')) nccoverlabel.setToolTip( _("How much (fraction) of the tool width to overlap each tool pass.\n" "Example:\n" @@ -6189,7 +6383,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): self.ncc_overlap_entry = FloatEntry() grid0.addWidget(self.ncc_overlap_entry, 2, 1) - nccmarginlabel = QtWidgets.QLabel(_('Margin:')) + nccmarginlabel = QtWidgets.QLabel('%s:' % _('Margin')) nccmarginlabel.setToolTip( _("Bounding box margin.") ) @@ -6198,7 +6392,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.ncc_margin_entry, 3, 1) # Method - methodlabel = QtWidgets.QLabel(_('Method:')) + methodlabel = QtWidgets.QLabel('%s:' % _('Method')) methodlabel.setToolTip( _("Algorithm for non-copper clearing:
" "Standard: Fixed step inwards.
" @@ -6214,7 +6408,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.ncc_method_radio, 4, 1) # Connect lines - pathconnectlabel = QtWidgets.QLabel(_("Connect:")) + pathconnectlabel = QtWidgets.QLabel('%s:' % _("Connect")) pathconnectlabel.setToolTip( _("Draw lines between resulting\n" "segments to minimize tool lifts.") @@ -6223,7 +6417,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): self.ncc_connect_cb = FCCheckBox() grid0.addWidget(self.ncc_connect_cb, 5, 1) - contourlabel = QtWidgets.QLabel(_("Contour:")) + contourlabel = QtWidgets.QLabel('%s:' % _("Contour")) contourlabel.setToolTip( _("Cut around the perimeter of the polygon\n" "to trim rough edges.") @@ -6232,13 +6426,14 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): self.ncc_contour_cb = FCCheckBox() grid0.addWidget(self.ncc_contour_cb, 6, 1) - restlabel = QtWidgets.QLabel(_("Rest M.:")) + restlabel = QtWidgets.QLabel('%s:' % _("Rest M.")) restlabel.setToolTip( _("If checked, use 'rest machining'.\n" "Basically it will clear copper outside PCB features,\n" "using the biggest tool and continue with the next tools,\n" "from bigger to smaller, to clear areas of copper that\n" - "could not be cleared by previous tool.\n" + "could not be cleared by previous tool, until there is\n" + "no more copper to clear or there are no more tools.\n" "If not checked, use the standard algorithm.") ) grid0.addWidget(restlabel, 7, 0) @@ -6246,7 +6441,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.ncc_rest_cb, 7, 1) # ## NCC Offset choice - self.ncc_offset_choice_label = QtWidgets.QLabel(_("Offset:")) + self.ncc_offset_choice_label = QtWidgets.QLabel('%s:' % _("Offset")) self.ncc_offset_choice_label.setToolTip( _("If used, it will add an offset to the copper features.\n" "The copper clearing will finish to a distance\n" @@ -6258,7 +6453,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.ncc_choice_offset_cb, 8, 1) # ## NCC Offset value - self.ncc_offset_label = QtWidgets.QLabel(_("Offset value:")) + self.ncc_offset_label = QtWidgets.QLabel('%s:' % _("Offset value")) self.ncc_offset_label.setToolTip( _("If used, it will add an offset to the copper features.\n" "The copper clearing will finish to a distance\n" @@ -6277,7 +6472,7 @@ class ToolsNCCPrefGroupUI(OptionsGroupUI): # ## Reference self.reference_radio = RadioSet([{'label': _('Itself'), 'value': 'itself'}, {'label': _('Box'), 'value': 'box'}]) - reference_label = QtWidgets.QLabel(_("Reference:")) + reference_label = QtWidgets.QLabel('%s:' % _("Reference")) reference_label.setToolTip( _("When choosing the 'Itself' option the non copper clearing extent\n" "is based on the object that is copper cleared.\n " @@ -6309,16 +6504,17 @@ class ToolsCutoutPrefGroupUI(OptionsGroupUI): grid0 = QtWidgets.QGridLayout() self.layout.addLayout(grid0) - tdclabel = QtWidgets.QLabel(_('Tool dia:')) + tdclabel = QtWidgets.QLabel('%s:' % _('Tool dia')) tdclabel.setToolTip( - _("Diameter of the cutting tool.") + _("Diameter of the tool used to cutout\n" + "the PCB shape out of the surrounding material.") ) grid0.addWidget(tdclabel, 0, 0) self.cutout_tooldia_entry = LengthEntry() grid0.addWidget(self.cutout_tooldia_entry, 0, 1) # Object kind - kindlabel = QtWidgets.QLabel(_('Obj kind:')) + kindlabel = QtWidgets.QLabel('%s:' % _('Obj kind')) kindlabel.setToolTip( _("Choice of what kind the object we want to cutout is.
" "- Single: contain a single PCB Gerber outline object.
" @@ -6332,26 +6528,28 @@ class ToolsCutoutPrefGroupUI(OptionsGroupUI): ]) grid0.addWidget(self.obj_kind_combo, 1, 1) - marginlabel = QtWidgets.QLabel(_('Margin:')) + marginlabel = QtWidgets.QLabel('%s:' % _('Margin')) marginlabel.setToolTip( - _("Distance from objects at which\n" - "to draw the cutout.") + _("Margin over bounds. A positive value here\n" + "will make the cutout of the PCB further from\n" + "the actual PCB border") ) grid0.addWidget(marginlabel, 2, 0) self.cutout_margin_entry = LengthEntry() grid0.addWidget(self.cutout_margin_entry, 2, 1) - gaplabel = QtWidgets.QLabel(_('Gap size:')) + gaplabel = QtWidgets.QLabel('%s:' % _('Gap size')) gaplabel.setToolTip( - _("Size of the gaps in the toolpath\n" - "that will remain to hold the\n" - "board in place.") + _("The size of the bridge gaps in the cutout\n" + "used to keep the board connected to\n" + "the surrounding material (the one \n" + "from which the PCB is cutout).") ) grid0.addWidget(gaplabel, 3, 0) self.cutout_gap_entry = LengthEntry() grid0.addWidget(self.cutout_gap_entry, 3, 1) - gaps_label = QtWidgets.QLabel(_('Gaps:')) + gaps_label = QtWidgets.QLabel('%s:' % _('Gaps')) gaps_label.setToolTip( _("Number of bridge gaps used for the cutout.\n" "There can be maximum 8 bridges/gaps.\n" @@ -6374,9 +6572,10 @@ class ToolsCutoutPrefGroupUI(OptionsGroupUI): # Surrounding convex box shape self.convex_box = FCCheckBox() - self.convex_box_label = QtWidgets.QLabel(_("Convex Sh.:")) + self.convex_box_label = QtWidgets.QLabel('%s:' % _("Convex Sh.")) self.convex_box_label.setToolTip( - _("Create a convex shape surrounding the entire PCB.") + _("Create a convex shape surrounding the entire PCB.\n" + "Used only if the source object type is Gerber.") ) grid0.addWidget(self.convex_box_label, 5, 0) grid0.addWidget(self.convex_box, 5, 1) @@ -6404,7 +6603,7 @@ class Tools2sidedPrefGroupUI(OptionsGroupUI): # ## Drill diameter for alignment holes self.drill_dia_entry = LengthEntry() - self.dd_label = QtWidgets.QLabel(_("Drill diam.:")) + self.dd_label = QtWidgets.QLabel('%s:' % _("Drill dia")) self.dd_label.setToolTip( _("Diameter of the drill for the " "alignment holes.") @@ -6428,11 +6627,11 @@ class Tools2sidedPrefGroupUI(OptionsGroupUI): # ## Axis Location self.axis_location_radio = RadioSet([{'label': _('Point'), 'value': 'point'}, {'label': _('Box'), 'value': 'box'}]) - self.axloc_label = QtWidgets.QLabel(_("Axis Ref:")) + self.axloc_label = QtWidgets.QLabel('%s:' % _("Axis Ref")) self.axloc_label.setToolTip( _("The axis should pass through a point or cut\n " - "a specified box (in a Geometry object) in \n" - "the middle.") + "a specified box (in a FlatCAM object) through \n" + "the center.") ) # grid_lay.addRow("Axis Location:", self.axis_location) grid0.addWidget(self.axloc_label, 3, 0) @@ -6464,7 +6663,7 @@ class ToolsPaintPrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid0) # Tool dia - ptdlabel = QtWidgets.QLabel(_('Tool dia:')) + ptdlabel = QtWidgets.QLabel('%s:' % _('Tool dia')) ptdlabel.setToolTip( _("Diameter of the tool to\n" "be used in the operation.") @@ -6475,17 +6674,24 @@ class ToolsPaintPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.painttooldia_entry, 0, 1) # Overlap - ovlabel = QtWidgets.QLabel(_('Overlap Rate:')) + ovlabel = QtWidgets.QLabel('%s:' % _('Overlap Rate')) ovlabel.setToolTip( - _("How much (fraction) of the tool\n" - "width to overlap each tool pass.") + _("How much (fraction) of the tool width to overlap each tool pass.\n" + "Example:\n" + "A value here of 0.25 means 25% from the tool diameter found above.\n\n" + "Adjust the value starting with lower values\n" + "and increasing it if areas that should be painted are still \n" + "not painted.\n" + "Lower values = faster processing, faster execution on PCB.\n" + "Higher values = slow processing and slow execution on CNC\n" + "due of too many paths.") ) grid0.addWidget(ovlabel, 1, 0) self.paintoverlap_entry = LengthEntry() grid0.addWidget(self.paintoverlap_entry, 1, 1) # Margin - marginlabel = QtWidgets.QLabel(_('Margin:')) + marginlabel = QtWidgets.QLabel('%s:' % _('Margin')) marginlabel.setToolTip( _("Distance by which to avoid\n" "the edges of the polygon to\n" @@ -6496,11 +6702,12 @@ class ToolsPaintPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.paintmargin_entry, 2, 1) # Method - methodlabel = QtWidgets.QLabel(_('Method:')) + methodlabel = QtWidgets.QLabel('%s:' % _('Method')) methodlabel.setToolTip( - _("Algorithm to paint the polygon:
" + _("Algorithm for non-copper clearing:
" "Standard: Fixed step inwards.
" - "Seed-based: Outwards from seed.") + "Seed-based: Outwards from seed.
" + "Line-based: Parallel lines.") ) grid0.addWidget(methodlabel, 3, 0) self.paintmethod_combo = RadioSet([ @@ -6511,7 +6718,7 @@ class ToolsPaintPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.paintmethod_combo, 3, 1) # Connect lines - pathconnectlabel = QtWidgets.QLabel(_("Connect:")) + pathconnectlabel = QtWidgets.QLabel('%s:' % _("Connect")) pathconnectlabel.setToolTip( _("Draw lines between resulting\n" "segments to minimize tool lifts.") @@ -6521,7 +6728,7 @@ class ToolsPaintPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.pathconnect_cb, 4, 1) # Paint contour - contourlabel = QtWidgets.QLabel(_("Contour:")) + contourlabel = QtWidgets.QLabel('%s:' % _("Contour")) contourlabel.setToolTip( _("Cut around the perimeter of the polygon\n" "to trim rough edges.") @@ -6531,7 +6738,7 @@ class ToolsPaintPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.contour_cb, 5, 1) # Polygon selection - selectlabel = QtWidgets.QLabel(_('Selection:')) + selectlabel = QtWidgets.QLabel('%s:' % _('Selection')) selectlabel.setToolTip( _("How to select the polygons to paint.
" "Options:
" @@ -6586,7 +6793,7 @@ class ToolsFilmPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.film_type_radio, 0, 1) self.film_boundary_entry = FCEntry() - self.film_boundary_label = QtWidgets.QLabel(_("Border:")) + self.film_boundary_label = QtWidgets.QLabel('%s:' % _("Border")) self.film_boundary_label.setToolTip( _("Specify a border around the object.\n" "Only for negative film.\n" @@ -6601,7 +6808,7 @@ class ToolsFilmPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.film_boundary_entry, 1, 1) self.film_scale_entry = FCEntry() - self.film_scale_label = QtWidgets.QLabel(_("Scale Stroke:")) + self.film_scale_label = QtWidgets.QLabel('%s:' % _("Scale Stroke")) self.film_scale_label.setToolTip( _("Scale the line stroke thickness of each feature in the SVG file.\n" "It means that the line that envelope each SVG feature will be thicker or thinner,\n" @@ -6634,7 +6841,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): # ## Spacing Columns self.pspacing_columns = FCEntry() - self.spacing_columns_label = QtWidgets.QLabel(_("Spacing cols:")) + self.spacing_columns_label = QtWidgets.QLabel('%s:' % _("Spacing cols")) self.spacing_columns_label.setToolTip( _("Spacing between columns of the desired panel.\n" "In current units.") @@ -6644,7 +6851,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): # ## Spacing Rows self.pspacing_rows = FCEntry() - self.spacing_rows_label = QtWidgets.QLabel(_("Spacing rows:")) + self.spacing_rows_label = QtWidgets.QLabel('%s:' % _("Spacing rows")) self.spacing_rows_label.setToolTip( _("Spacing between rows of the desired panel.\n" "In current units.") @@ -6654,7 +6861,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): # ## Columns self.pcolumns = FCEntry() - self.columns_label = QtWidgets.QLabel(_("Columns:")) + self.columns_label = QtWidgets.QLabel('%s:' % _("Columns")) self.columns_label.setToolTip( _("Number of columns of the desired panel") ) @@ -6663,7 +6870,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): # ## Rows self.prows = FCEntry() - self.rows_label = QtWidgets.QLabel(_("Rows:")) + self.rows_label = QtWidgets.QLabel('%s:' % _("Rows")) self.rows_label.setToolTip( _("Number of rows of the desired panel") ) @@ -6673,7 +6880,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): # ## Type of resulting Panel object self.panel_type_radio = RadioSet([{'label': _('Gerber'), 'value': 'gerber'}, {'label': _('Geo'), 'value': 'geometry'}]) - self.panel_type_label = QtWidgets.QLabel(_("Panel Type:")) + self.panel_type_label = QtWidgets.QLabel('%s:' % _("Panel Type")) self.panel_type_label.setToolTip( _("Choose the type of object for the panel object:\n" "- Gerber\n" @@ -6684,7 +6891,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): grid0.addWidget(self.panel_type_radio, 4, 1) # ## Constrains - self.pconstrain_cb = FCCheckBox(_("Constrain within:")) + self.pconstrain_cb = FCCheckBox('%s:' % _("Constrain within")) self.pconstrain_cb.setToolTip( _("Area define by DX and DY within to constrain the panel.\n" "DX and DY values are in current units.\n" @@ -6695,7 +6902,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): grid0.addWidget(self.pconstrain_cb, 5, 0) self.px_width_entry = FCEntry() - self.x_width_lbl = QtWidgets.QLabel(_("Width (DX):")) + self.x_width_lbl = QtWidgets.QLabel('%s:' % _("Width (DX)")) self.x_width_lbl.setToolTip( _("The width (DX) within which the panel must fit.\n" "In current units.") @@ -6704,7 +6911,7 @@ class ToolsPanelizePrefGroupUI(OptionsGroupUI): grid0.addWidget(self.px_width_entry, 6, 1) self.py_height_entry = FCEntry() - self.y_height_lbl = QtWidgets.QLabel(_("Height (DY):")) + self.y_height_lbl = QtWidgets.QLabel('%s:' % _("Height (DY)")) self.y_height_lbl.setToolTip( _("The height (DY)within which the panel must fit.\n" "In current units.") @@ -6736,7 +6943,7 @@ class ToolsCalculatorsPrefGroupUI(OptionsGroupUI): # ## Tip Diameter self.tip_dia_entry = FCEntry() - self.tip_dia_label = QtWidgets.QLabel(_("Tip Diameter:")) + self.tip_dia_label = QtWidgets.QLabel('%s:' % _("Tip Diameter")) self.tip_dia_label.setToolTip( _("This is the tool tip diameter.\n" "It is specified by manufacturer.") @@ -6746,7 +6953,7 @@ class ToolsCalculatorsPrefGroupUI(OptionsGroupUI): # ## Tip angle self.tip_angle_entry = FCEntry() - self.tip_angle_label = QtWidgets.QLabel(_("Tip angle:")) + self.tip_angle_label = QtWidgets.QLabel('%s:' % _("Tip Angle")) self.tip_angle_label.setToolTip( _("This is the angle on the tip of the tool.\n" "It is specified by manufacturer.") @@ -6756,7 +6963,7 @@ class ToolsCalculatorsPrefGroupUI(OptionsGroupUI): # ## Depth-of-cut Cut Z self.cut_z_entry = FCEntry() - self.cut_z_label = QtWidgets.QLabel(_("Cut Z:")) + self.cut_z_label = QtWidgets.QLabel('%s:' % _("Cut Z")) self.cut_z_label.setToolTip( _("This is depth to cut into material.\n" "In the CNCJob object it is the CutZ parameter.") @@ -6777,7 +6984,7 @@ class ToolsCalculatorsPrefGroupUI(OptionsGroupUI): # ## PCB Length self.pcblength_entry = FCEntry() - self.pcblengthlabel = QtWidgets.QLabel(_("Board Length:")) + self.pcblengthlabel = QtWidgets.QLabel('%s:' % _("Board Length")) self.pcblengthlabel.setToolTip(_('This is the board length. In centimeters.')) grid1.addWidget(self.pcblengthlabel, 0, 0) @@ -6785,14 +6992,14 @@ class ToolsCalculatorsPrefGroupUI(OptionsGroupUI): # ## PCB Width self.pcbwidth_entry = FCEntry() - self.pcbwidthlabel = QtWidgets.QLabel(_("Board Width:")) + self.pcbwidthlabel = QtWidgets.QLabel('%s:' % _("Board Width")) self.pcbwidthlabel.setToolTip(_('This is the board width.In centimeters.')) grid1.addWidget(self.pcbwidthlabel, 1, 0) grid1.addWidget(self.pcbwidth_entry, 1, 1) # ## Current Density - self.cdensity_label = QtWidgets.QLabel(_("Current Density:")) + self.cdensity_label = QtWidgets.QLabel('%s:' % _("Current Density")) self.cdensity_entry = FCEntry() self.cdensity_label.setToolTip(_("Current density to pass through the board. \n" @@ -6801,7 +7008,7 @@ class ToolsCalculatorsPrefGroupUI(OptionsGroupUI): grid1.addWidget(self.cdensity_entry, 2, 1) # ## PCB Copper Growth - self.growth_label = QtWidgets.QLabel(_("Copper Growth:")) + self.growth_label = QtWidgets.QLabel('%s:' % _("Copper Growth")) self.growth_entry = FCEntry() self.growth_label.setToolTip(_("How thick the copper growth is intended to be.\n" @@ -6832,34 +7039,39 @@ class ToolsTransformPrefGroupUI(OptionsGroupUI): # ## Rotate Angle self.rotate_entry = FCEntry() - self.rotate_label = QtWidgets.QLabel(_("Rotate Angle:")) + self.rotate_label = QtWidgets.QLabel('%s:' % _("Rotate Angle")) self.rotate_label.setToolTip( - _("Angle for rotation. In degrees.") + _("Angle for Rotation action, in degrees.\n" + "Float number between -360 and 359.\n" + "Positive numbers for CW motion.\n" + "Negative numbers for CCW motion.") ) grid0.addWidget(self.rotate_label, 0, 0) grid0.addWidget(self.rotate_entry, 0, 1) # ## Skew/Shear Angle on X axis self.skewx_entry = FCEntry() - self.skewx_label = QtWidgets.QLabel(_("Skew_X angle:")) + self.skewx_label = QtWidgets.QLabel('%s:' % _("Skew_X angle")) self.skewx_label.setToolTip( - _("Angle for Skew/Shear on X axis. In degrees.") + _("Angle for Skew action, in degrees.\n" + "Float number between -360 and 359.") ) grid0.addWidget(self.skewx_label, 1, 0) grid0.addWidget(self.skewx_entry, 1, 1) # ## Skew/Shear Angle on Y axis self.skewy_entry = FCEntry() - self.skewy_label = QtWidgets.QLabel(_("Skew_Y angle:")) + self.skewy_label = QtWidgets.QLabel('%s:' % _("Skew_Y angle")) self.skewy_label.setToolTip( - _("Angle for Skew/Shear on Y axis. In degrees.") + _("Angle for Skew action, in degrees.\n" + "Float number between -360 and 359.") ) grid0.addWidget(self.skewy_label, 2, 0) grid0.addWidget(self.skewy_entry, 2, 1) # ## Scale factor on X axis self.scalex_entry = FCEntry() - self.scalex_label = QtWidgets.QLabel(_("Scale_X factor:")) + self.scalex_label = QtWidgets.QLabel('%s:' % _("Scale_X factor")) self.scalex_label.setToolTip( _("Factor for scaling on X axis.") ) @@ -6868,7 +7080,7 @@ class ToolsTransformPrefGroupUI(OptionsGroupUI): # ## Scale factor on X axis self.scaley_entry = FCEntry() - self.scaley_label = QtWidgets.QLabel(_("Scale_Y factor:")) + self.scaley_label = QtWidgets.QLabel('%s:' % _("Scale_Y factor")) self.scaley_label.setToolTip( _("Factor for scaling on Y axis.") ) @@ -6884,7 +7096,7 @@ class ToolsTransformPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.link_cb, 5, 0) # ## Scale Reference - self.reference_cb = FCCheckBox(_("Scale Reference")) + self.reference_cb = FCCheckBox('%s' % _("Scale Reference")) self.reference_cb.setToolTip( _("Scale the selected object(s)\n" "using the origin reference when checked,\n" @@ -6895,7 +7107,7 @@ class ToolsTransformPrefGroupUI(OptionsGroupUI): # ## Offset distance on X axis self.offx_entry = FCEntry() - self.offx_label = QtWidgets.QLabel(_("Offset_X val:")) + self.offx_label = QtWidgets.QLabel('%s:' % _("Offset_X val")) self.offx_label.setToolTip( _("Distance to offset on X axis. In current units.") ) @@ -6904,7 +7116,7 @@ class ToolsTransformPrefGroupUI(OptionsGroupUI): # ## Offset distance on Y axis self.offy_entry = FCEntry() - self.offy_label = QtWidgets.QLabel(_("Offset_Y val:")) + self.offy_label = QtWidgets.QLabel('%s:' % _("Offset_Y val")) self.offy_label.setToolTip( _("Distance to offset on Y axis. In current units.") ) @@ -6912,7 +7124,7 @@ class ToolsTransformPrefGroupUI(OptionsGroupUI): grid0.addWidget(self.offy_entry, 7, 1) # ## Mirror (Flip) Reference Point - self.mirror_reference_cb = FCCheckBox(_("Mirror Reference")) + self.mirror_reference_cb = FCCheckBox('%s' % _("Mirror Reference")) self.mirror_reference_cb.setToolTip( _("Flip the selected object(s)\n" "around the point in Point Entry Field.\n" @@ -6925,7 +7137,7 @@ class ToolsTransformPrefGroupUI(OptionsGroupUI): "Point Entry field and click Flip on X(Y)")) grid0.addWidget(self.mirror_reference_cb, 8, 1) - self.flip_ref_label = QtWidgets.QLabel(_(" Mirror Ref. Point:")) + self.flip_ref_label = QtWidgets.QLabel('%s:' % _(" Mirror Ref. Point")) self.flip_ref_label.setToolTip( _("Coordinates in format (x, y) used as reference for mirroring.\n" "The 'x' in (x, y) will be used when using Flip on X and\n" @@ -6958,7 +7170,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): self.layout.addLayout(grid0) # Nozzle Tool Diameters - nozzletdlabel = QtWidgets.QLabel(_('Tools dia:')) + nozzletdlabel = QtWidgets.QLabel('%s:' % _('Tools dia')) nozzletdlabel.setToolTip( _("Diameters of nozzle tools, separated by ','") ) @@ -6967,7 +7179,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): grid0.addWidget(self.nozzle_tool_dia_entry, 0, 1) # New Nozzle Tool Dia - self.addtool_entry_lbl = QtWidgets.QLabel(_('New Nozzle Dia:')) + self.addtool_entry_lbl = QtWidgets.QLabel('%s:' % _('New Nozzle Dia')) self.addtool_entry_lbl.setToolTip( _("Diameter for the new Nozzle tool to add in the Tool Table") ) @@ -6977,7 +7189,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Z dispense start self.z_start_entry = FCEntry() - self.z_start_label = QtWidgets.QLabel(_("Z Dispense Start:")) + self.z_start_label = QtWidgets.QLabel('%s:' % _("Z Dispense Start")) self.z_start_label.setToolTip( _("The height (Z) when solder paste dispensing starts.") ) @@ -6986,7 +7198,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Z dispense self.z_dispense_entry = FCEntry() - self.z_dispense_label = QtWidgets.QLabel(_("Z Dispense:")) + self.z_dispense_label = QtWidgets.QLabel('%s:' % _("Z Dispense")) self.z_dispense_label.setToolTip( _("The height (Z) when doing solder paste dispensing.") ) @@ -6995,7 +7207,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Z dispense stop self.z_stop_entry = FCEntry() - self.z_stop_label = QtWidgets.QLabel(_("Z Dispense Stop:")) + self.z_stop_label = QtWidgets.QLabel('%s:' % _("Z Dispense Stop")) self.z_stop_label.setToolTip( _("The height (Z) when solder paste dispensing stops.") ) @@ -7004,7 +7216,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Z travel self.z_travel_entry = FCEntry() - self.z_travel_label = QtWidgets.QLabel(_("Z Travel:")) + self.z_travel_label = QtWidgets.QLabel('%s:' % _("Z Travel")) self.z_travel_label.setToolTip( _("The height (Z) for travel between pads\n" "(without dispensing solder paste).") @@ -7014,7 +7226,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Z toolchange location self.z_toolchange_entry = FCEntry() - self.z_toolchange_label = QtWidgets.QLabel(_("Z Toolchange:")) + self.z_toolchange_label = QtWidgets.QLabel('%s:' % _("Z Toolchange")) self.z_toolchange_label.setToolTip( _("The height (Z) for tool (nozzle) change.") ) @@ -7023,7 +7235,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # X,Y Toolchange location self.xy_toolchange_entry = FCEntry() - self.xy_toolchange_label = QtWidgets.QLabel(_("XY Toolchange:")) + self.xy_toolchange_label = QtWidgets.QLabel('%s:' % _("Toolchange X-Y")) self.xy_toolchange_label.setToolTip( _("The X,Y location for tool (nozzle) change.\n" "The format is (x, y) where x and y are real numbers.") @@ -7033,7 +7245,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Feedrate X-Y self.frxy_entry = FCEntry() - self.frxy_label = QtWidgets.QLabel(_("Feedrate X-Y:")) + self.frxy_label = QtWidgets.QLabel('%s:' % _("Feedrate X-Y")) self.frxy_label.setToolTip( _("Feedrate (speed) while moving on the X-Y plane.") ) @@ -7042,7 +7254,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Feedrate Z self.frz_entry = FCEntry() - self.frz_label = QtWidgets.QLabel(_("Feedrate Z:")) + self.frz_label = QtWidgets.QLabel('%s:' % _("Feedrate Z")) self.frz_label.setToolTip( _("Feedrate (speed) while moving vertically\n" "(on Z plane).") @@ -7052,7 +7264,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Feedrate Z Dispense self.frz_dispense_entry = FCEntry() - self.frz_dispense_label = QtWidgets.QLabel(_("Feedrate Z Dispense:")) + self.frz_dispense_label = QtWidgets.QLabel('%s:' % _("Feedrate Z Dispense")) self.frz_dispense_label.setToolTip( _("Feedrate (speed) while moving up vertically\n" "to Dispense position (on Z plane).") @@ -7062,7 +7274,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Spindle Speed Forward self.speedfwd_entry = FCEntry() - self.speedfwd_label = QtWidgets.QLabel(_("Spindle Speed FWD:")) + self.speedfwd_label = QtWidgets.QLabel('%s:' % _("Spindle Speed FWD")) self.speedfwd_label.setToolTip( _("The dispenser speed while pushing solder paste\n" "through the dispenser nozzle.") @@ -7072,7 +7284,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Dwell Forward self.dwellfwd_entry = FCEntry() - self.dwellfwd_label = QtWidgets.QLabel(_("Dwell FWD:")) + self.dwellfwd_label = QtWidgets.QLabel('%s:' % _("Dwell FWD")) self.dwellfwd_label.setToolTip( _("Pause after solder dispensing.") ) @@ -7081,7 +7293,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Spindle Speed Reverse self.speedrev_entry = FCEntry() - self.speedrev_label = QtWidgets.QLabel(_("Spindle Speed REV:")) + self.speedrev_label = QtWidgets.QLabel('%s:' % _("Spindle Speed REV")) self.speedrev_label.setToolTip( _("The dispenser speed while retracting solder paste\n" "through the dispenser nozzle.") @@ -7091,7 +7303,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): # Dwell Reverse self.dwellrev_entry = FCEntry() - self.dwellrev_label = QtWidgets.QLabel(_("Dwell REV:")) + self.dwellrev_label = QtWidgets.QLabel('%s:' % _("Dwell REV")) self.dwellrev_label.setToolTip( _("Pause after solder paste dispenser retracted,\n" "to allow pressure equilibrium.") @@ -7100,7 +7312,7 @@ class ToolsSolderpastePrefGroupUI(OptionsGroupUI): grid0.addWidget(self.dwellrev_entry, 14, 1) # Postprocessors - pp_label = QtWidgets.QLabel(_('PostProcessors:')) + pp_label = QtWidgets.QLabel('%s:' % _('PostProcessor')) pp_label.setToolTip( _("Files that control the GCode generation.") ) diff --git a/flatcamGUI/ObjectUI.py b/flatcamGUI/ObjectUI.py index 8ebbb37d..dea19c6c 100644 --- a/flatcamGUI/ObjectUI.py +++ b/flatcamGUI/ObjectUI.py @@ -76,7 +76,7 @@ class ObjectUI(QtWidgets.QWidget): # ########################### # ### Scale #### - self.scale_label = QtWidgets.QLabel(_('Scale:')) + self.scale_label = QtWidgets.QLabel('%s:' % _('Scale')) self.scale_label.setToolTip( _("Change the size of the object.") ) @@ -86,7 +86,7 @@ class ObjectUI(QtWidgets.QWidget): layout.addLayout(self.scale_grid) # Factor - faclabel = QtWidgets.QLabel(_('Factor:')) + faclabel = QtWidgets.QLabel('%s:' % _('Factor')) faclabel.setToolTip( _("Factor by which to multiply\n" "geometric features of this object.") @@ -105,7 +105,7 @@ class ObjectUI(QtWidgets.QWidget): self.scale_grid.addWidget(self.scale_button, 0, 2) # ### Offset #### - self.offset_label = QtWidgets.QLabel(_('Offset:')) + self.offset_label = QtWidgets.QLabel('%s:' % _('Offset')) self.offset_label.setToolTip( _("Change the position of this object.") ) @@ -114,7 +114,7 @@ class ObjectUI(QtWidgets.QWidget): self.offset_grid = QtWidgets.QGridLayout() layout.addLayout(self.offset_grid) - self.offset_vectorlabel = QtWidgets.QLabel(_('Vector:')) + self.offset_vectorlabel = QtWidgets.QLabel('%s:' % _('Vector')) self.offset_vectorlabel.setToolTip( _("Amount by which to move the object\n" "in the x and y axes in (x, y) format.") @@ -189,7 +189,7 @@ class GerberObjectUI(ObjectUI): self.custom_box.addLayout(hlay_plot) # ### Gerber Apertures #### - self.apertures_table_label = QtWidgets.QLabel(_('Apertures:')) + self.apertures_table_label = QtWidgets.QLabel('%s:' % _('Apertures')) self.apertures_table_label.setToolTip( _("Apertures Table for the Gerber Object.") ) @@ -256,7 +256,7 @@ class GerberObjectUI(ObjectUI): grid1 = QtWidgets.QGridLayout() self.custom_box.addLayout(grid1) - tdlabel = QtWidgets.QLabel(_('Tool dia:')) + tdlabel = QtWidgets.QLabel('%s:' % _('Tool dia')) tdlabel.setToolTip( _("Diameter of the cutting tool.\n" "If you want to have an isolation path\n" @@ -269,7 +269,7 @@ class GerberObjectUI(ObjectUI): self.iso_tool_dia_entry = LengthEntry() grid1.addWidget(self.iso_tool_dia_entry, 0, 1) - passlabel = QtWidgets.QLabel(_('Passes:')) + passlabel = QtWidgets.QLabel('%s:' % _('# Passes')) passlabel.setToolTip( _("Width of the isolation gap in\n" "number (integer) of tool widths.") @@ -280,7 +280,7 @@ class GerberObjectUI(ObjectUI): self.iso_width_entry.setRange(1, 999) grid1.addWidget(self.iso_width_entry, 1, 1) - overlabel = QtWidgets.QLabel(_('Pass overlap:')) + overlabel = QtWidgets.QLabel('%s:' % _('Pass overlap')) overlabel.setToolTip( _("How much (fraction) of the tool width to overlap each tool pass.\n" "Example:\n" @@ -292,7 +292,7 @@ class GerberObjectUI(ObjectUI): grid1.addWidget(self.iso_overlap_entry, 2, 1) # Milling Type Radio Button - self.milling_type_label = QtWidgets.QLabel(_('Milling Type:')) + self.milling_type_label = QtWidgets.QLabel('%s:' % _('Milling Type')) self.milling_type_label.setToolTip( _("Milling type:\n" "- climb / best for precision milling and to reduce tool usage\n" @@ -304,7 +304,7 @@ class GerberObjectUI(ObjectUI): grid1.addWidget(self.milling_type_radio, 3, 1) # combine all passes CB - self.combine_passes_cb = FCCheckBox(label=_('Combine')) + self.combine_passes_cb = FCCheckBox(label=_('Combine Passes')) self.combine_passes_cb.setToolTip( _("Combine all passes into one object") ) @@ -425,7 +425,7 @@ class GerberObjectUI(ObjectUI): self.custom_box.addLayout(grid4) # Margin - bmlabel = QtWidgets.QLabel(_('Boundary Margin:')) + bmlabel = QtWidgets.QLabel('%s:' % _('Boundary Margin')) bmlabel.setToolTip( _("Specify the edge of the PCB\n" "by drawing a box around all\n" @@ -449,7 +449,7 @@ class GerberObjectUI(ObjectUI): grid4.addWidget(self.generate_noncopper_button, 1, 1) # ## Bounding box - self.boundingbox_label = QtWidgets.QLabel(_('Bounding Box:')) + self.boundingbox_label = QtWidgets.QLabel('%s:' % _('Bounding Box')) self.boundingbox_label.setToolTip( _("Create a geometry surrounding the Gerber object.\n" "Square shape.") @@ -459,7 +459,7 @@ class GerberObjectUI(ObjectUI): grid5 = QtWidgets.QGridLayout() self.custom_box.addLayout(grid5) - bbmargin = QtWidgets.QLabel(_('Boundary Margin:')) + bbmargin = QtWidgets.QLabel('%s:' % _('Boundary Margin')) bbmargin.setToolTip( _("Distance of the edges of the box\n" "to the nearest polygon.") @@ -531,7 +531,7 @@ class ExcellonObjectUI(ObjectUI): self.tools_box.addLayout(hlay_plot) # ### Tools Drills #### - self.tools_table_label = QtWidgets.QLabel(_('Tools Table')) + self.tools_table_label = QtWidgets.QLabel('%s:' % _('Tools Table')) self.tools_table_label.setToolTip( _("Tools in this Excellon object\n" "when are used for drilling.") @@ -539,7 +539,7 @@ class ExcellonObjectUI(ObjectUI): hlay_plot.addWidget(self.tools_table_label) # Plot CB - self.plot_cb = FCCheckBox(_('Plot Object')) + self.plot_cb = FCCheckBox(_('Plot')) self.plot_cb.setToolTip( _("Plot (show) this object.") ) @@ -579,7 +579,7 @@ class ExcellonObjectUI(ObjectUI): self.tools_box.addWidget(self.empty_label) # ### Create CNC Job #### - self.cncjob_label = QtWidgets.QLabel(_('Create CNC Job')) + self.cncjob_label = QtWidgets.QLabel('%s' % _('Create CNC Job')) self.cncjob_label.setToolTip( _("Create a CNC Job object\n" "for this drill object.") @@ -590,7 +590,7 @@ class ExcellonObjectUI(ObjectUI): self.tools_box.addLayout(grid1) # Cut Z - cutzlabel = QtWidgets.QLabel(_('Cut Z:')) + cutzlabel = QtWidgets.QLabel('%s:' % _('Cut Z')) cutzlabel.setToolTip( _("Drill depth (negative)\n" "below the copper surface.") @@ -600,7 +600,7 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.cutz_entry, 0, 1) # Travel Z (z_move) - travelzlabel = QtWidgets.QLabel(_('Travel Z:')) + travelzlabel = QtWidgets.QLabel('%s:' % _('Travel Z')) travelzlabel.setToolTip( _("Tool height when travelling\n" "across the XY plane.") @@ -610,7 +610,7 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.travelz_entry, 1, 1) # Tool change: - self.toolchange_cb = FCCheckBox(_("Tool change")) + self.toolchange_cb = FCCheckBox('%s:' % _("Tool change")) self.toolchange_cb.setToolTip( _("Include tool-change sequence\n" "in G-Code (Pause for tool change).") @@ -618,7 +618,7 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.toolchange_cb, 2, 0) # Tool change Z: - toolchzlabel = QtWidgets.QLabel(_("Tool change Z:")) + toolchzlabel = QtWidgets.QLabel('%s:' % _("Tool change Z")) toolchzlabel.setToolTip( _("Z-axis position (height) for\n" "tool change.") @@ -629,9 +629,9 @@ class ExcellonObjectUI(ObjectUI): self.ois_tcz_e = OptionalInputSection(self.toolchange_cb, [self.toolchangez_entry]) # Start move Z: - self.estartz_label = QtWidgets.QLabel(_("Start move Z:")) + self.estartz_label = QtWidgets.QLabel('%s:' % _("Start move Z")) self.estartz_label.setToolTip( - _("Tool height just before starting the work.\n" + _("Height of the tool just after start.\n" "Delete the value if you don't need this feature.") ) grid1.addWidget(self.estartz_label, 4, 0) @@ -639,17 +639,17 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.estartz_entry, 4, 1) # End move Z: - self.eendz_label = QtWidgets.QLabel(_("End move Z:")) + self.eendz_label = QtWidgets.QLabel('%s:' % _("End move Z")) self.eendz_label.setToolTip( - _("Z-axis position (height) for\n" - "the last move.") + _("Height of the tool after\n" + "the last move at the end of the job.") ) grid1.addWidget(self.eendz_label, 5, 0) self.eendz_entry = LengthEntry() grid1.addWidget(self.eendz_entry, 5, 1) # Excellon Feedrate - frlabel = QtWidgets.QLabel(_('Feedrate (Plunge):')) + frlabel = QtWidgets.QLabel('%s:' % _('Feedrate (Plunge):')) frlabel.setToolTip( _("Tool speed while drilling\n" "(in units per minute).\n" @@ -660,14 +660,13 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.feedrate_entry, 6, 1) # Excellon Rapid Feedrate - self.feedrate_rapid_label = QtWidgets.QLabel(_('Feedrate Rapids:')) + self.feedrate_rapid_label = QtWidgets.QLabel('%s:' % _('Feedrate Rapids')) self.feedrate_rapid_label.setToolTip( _("Tool speed while drilling\n" "(in units per minute).\n" "This is for the rapid move G00.\n" "It is useful only for Marlin,\n" - "ignore for any other cases." - ) + "ignore for any other cases.") ) grid1.addWidget(self.feedrate_rapid_label, 7, 0) self.feedrate_rapid_entry = LengthEntry() @@ -677,7 +676,7 @@ class ExcellonObjectUI(ObjectUI): self.feedrate_rapid_entry.hide() # Spindlespeed - spdlabel = QtWidgets.QLabel(_('Spindle speed:')) + spdlabel = QtWidgets.QLabel('%s:' % _('Spindle speed')) spdlabel.setToolTip( _("Speed of the spindle\n" "in RPM (optional)") @@ -687,14 +686,14 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.spindlespeed_entry, 8, 1) # Dwell - self.dwell_cb = FCCheckBox(_('Dwell:')) + self.dwell_cb = FCCheckBox('%s:' % _('Dwell')) self.dwell_cb.setToolTip( _("Pause to allow the spindle to reach its\n" "speed before cutting.") ) self.dwelltime_entry = FCEntry() self.dwelltime_entry.setToolTip( - _("Number of milliseconds for spindle to dwell.") + _("Number of time units for spindle to dwell.") ) grid1.addWidget(self.dwell_cb, 9, 0) grid1.addWidget(self.dwelltime_entry, 9, 1) @@ -702,10 +701,10 @@ class ExcellonObjectUI(ObjectUI): self.ois_dwell = OptionalInputSection(self.dwell_cb, [self.dwelltime_entry]) # postprocessor selection - pp_excellon_label = QtWidgets.QLabel(_("Postprocessor:")) + pp_excellon_label = QtWidgets.QLabel('%s:' % _("Postprocessor")) pp_excellon_label.setToolTip( - _("The json file that dictates\n" - "gcode output.") + _("The postprocessor JSON file that dictates\n" + "Gcode output.") ) self.pp_excellon_name_cb = FCComboBox() self.pp_excellon_name_cb.setFocusPolicy(QtCore.Qt.StrongFocus) @@ -713,7 +712,7 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.pp_excellon_name_cb, 10, 1) # Probe depth - self.pdepth_label = QtWidgets.QLabel(_("Probe Z depth:")) + self.pdepth_label = QtWidgets.QLabel('%s:' % _("Probe Z depth")) self.pdepth_label.setToolTip( _("The maximum depth that the probe is allowed\n" "to probe. Negative value, in current units.") @@ -725,7 +724,7 @@ class ExcellonObjectUI(ObjectUI): self.pdepth_entry.setVisible(False) # Probe feedrate - self.feedrate_probe_label = QtWidgets.QLabel(_("Feedrate Probe:")) + self.feedrate_probe_label = QtWidgets.QLabel('%s:' % _("Feedrate Probe")) self.feedrate_probe_label.setToolTip( _("The feedrate used while the probe is probing.") ) @@ -743,7 +742,7 @@ class ExcellonObjectUI(ObjectUI): # ### Choose what to use for Gcode creation: Drills, Slots or Both gcode_box = QtWidgets.QFormLayout() - gcode_type_label = QtWidgets.QLabel(_('Type: ')) + gcode_type_label = QtWidgets.QLabel('%s' % _('Gcode')) gcode_type_label.setToolTip( _("Choose what to use for GCode generation:\n" "'Drills', 'Slots' or 'Both'.\n" @@ -767,7 +766,7 @@ class ExcellonObjectUI(ObjectUI): self.tools_box.addWidget(self.generate_cnc_button) # ### Milling Holes Drills #### - self.mill_hole_label = QtWidgets.QLabel(_('Mill Holes')) + self.mill_hole_label = QtWidgets.QLabel('%s' % _('Mill Holes')) self.mill_hole_label.setToolTip( _("Create Geometry for milling holes.") ) @@ -781,7 +780,7 @@ class ExcellonObjectUI(ObjectUI): grid2 = QtWidgets.QGridLayout() self.tools_box.addLayout(grid2) - self.tdlabel = QtWidgets.QLabel(_('Drills Tool dia:')) + self.tdlabel = QtWidgets.QLabel('%s:' % _('Drill Tool dia')) self.tdlabel.setToolTip( _("Diameter of the cutting tool.") ) @@ -797,9 +796,10 @@ class ExcellonObjectUI(ObjectUI): grid3 = QtWidgets.QGridLayout() self.custom_box.addLayout(grid3) - self.stdlabel = QtWidgets.QLabel(_('Slots Tool dia:')) + self.stdlabel = QtWidgets.QLabel('%s:' % _('Slot Tool dia')) self.stdlabel.setToolTip( - _("Diameter of the cutting tool.") + _("Diameter of the cutting tool\n" + "when milling slots.") ) grid3.addWidget(self.stdlabel, 0, 0) self.slot_tooldia_entry = LengthEntry() @@ -853,7 +853,7 @@ class GeometryObjectUI(ObjectUI): self.geo_tools_box.addLayout(hlay_plot) # ### Tools #### - self.tools_table_label = QtWidgets.QLabel(_('Tools Table')) + self.tools_table_label = QtWidgets.QLabel('%s:' % _('Tools Table')) self.tools_table_label.setToolTip( _("Tools in this Geometry object used for cutting.\n" "The 'Offset' entry will set an offset for the cut.\n" @@ -945,7 +945,7 @@ class GeometryObjectUI(ObjectUI): self.grid1 = QtWidgets.QGridLayout() self.geo_tools_box.addLayout(self.grid1) - self.tool_offset_lbl = QtWidgets.QLabel(_('Tool Offset:')) + self.tool_offset_lbl = QtWidgets.QLabel('%s:' % _('Tool Offset')) self.tool_offset_lbl.setToolTip( _( "The value to offset the cut when \n" @@ -971,7 +971,7 @@ class GeometryObjectUI(ObjectUI): # self.addtool_label.setToolTip( # "Add/Copy/Delete a tool to the tool list." # ) - self.addtool_entry_lbl = QtWidgets.QLabel(_('Tool Dia:')) + self.addtool_entry_lbl = QtWidgets.QLabel('%s:' % _('Tool Dia')) self.addtool_entry_lbl.setToolTip( _( "Diameter for the new tool" @@ -1022,7 +1022,7 @@ class GeometryObjectUI(ObjectUI): # Create CNC Job ### # ################## # ### Tools Data ## ## - self.tool_data_label = QtWidgets.QLabel(_('Tool Data')) + self.tool_data_label = QtWidgets.QLabel('%s' % _('Tool Data')) self.tool_data_label.setToolTip( _( "The data used for creating GCode.\n" @@ -1043,7 +1043,7 @@ class GeometryObjectUI(ObjectUI): self.geo_param_box.addLayout(self.grid3) # Tip Dia - self.tipdialabel = QtWidgets.QLabel(_('V-Tip Dia:')) + self.tipdialabel = QtWidgets.QLabel('%s:' % _('V-Tip Dia')) self.tipdialabel.setToolTip( _( "The tip diameter for V-Shape Tool" @@ -1054,7 +1054,7 @@ class GeometryObjectUI(ObjectUI): self.grid3.addWidget(self.tipdia_entry, 1, 1) # Tip Angle - self.tipanglelabel = QtWidgets.QLabel(_('V-Tip Angle:')) + self.tipanglelabel = QtWidgets.QLabel('%s:' % _('V-Tip Angle')) self.tipanglelabel.setToolTip( _( "The tip angle for V-Shape Tool.\n" @@ -1066,7 +1066,7 @@ class GeometryObjectUI(ObjectUI): self.grid3.addWidget(self.tipangle_entry, 2, 1) # Cut Z - cutzlabel = QtWidgets.QLabel(_('Cut Z:')) + cutzlabel = QtWidgets.QLabel('%s:' % _('Cut Z')) cutzlabel.setToolTip( _( "Cutting depth (negative)\n" @@ -1078,15 +1078,13 @@ class GeometryObjectUI(ObjectUI): self.grid3.addWidget(self.cutz_entry, 3, 1) # Multi-pass - self.mpass_cb = FCCheckBox(_("Multi-Depth:")) + self.mpass_cb = FCCheckBox('%s:' % _("Multi-Depth")) self.mpass_cb.setToolTip( _( "Use multiple passes to limit\n" "the cut depth in each pass. Will\n" "cut multiple times until Cut Z is\n" - "reached.\n" - "To the right, input the depth of \n" - "each pass (positive value)." + "reached." ) ) self.grid3.addWidget(self.mpass_cb, 4, 0) @@ -1102,12 +1100,10 @@ class GeometryObjectUI(ObjectUI): self.ois_mpass_geo = OptionalInputSection(self.mpass_cb, [self.maxdepth_entry]) # Travel Z - travelzlabel = QtWidgets.QLabel(_('Travel Z:')) + travelzlabel = QtWidgets.QLabel('%s:' % _('Travel Z')) travelzlabel.setToolTip( - _( - "Height of the tool when\n" - "moving without cutting." - ) + _("Height of the tool when\n" + "moving without cutting.") ) self.grid3.addWidget(travelzlabel, 5, 0) self.travelz_entry = FloatEntry() @@ -1115,14 +1111,14 @@ class GeometryObjectUI(ObjectUI): # Tool change: - self.toolchzlabel = QtWidgets.QLabel(_("Tool change Z:")) + self.toolchzlabel = QtWidgets.QLabel('%s:' %_("Tool change Z")) self.toolchzlabel.setToolTip( _( "Z-axis position (height) for\n" "tool change." ) ) - self.toolchangeg_cb = FCCheckBox(_("Tool change")) + self.toolchangeg_cb = FCCheckBox('%s:' % _("Tool change")) self.toolchangeg_cb.setToolTip( _( "Include tool-change sequence\n" @@ -1148,52 +1144,44 @@ class GeometryObjectUI(ObjectUI): # self.grid3.addWidget(self.gstartz_entry, 8, 1) # The Z value for the end move - self.endzlabel = QtWidgets.QLabel(_('End move Z:')) + self.endzlabel = QtWidgets.QLabel('%s:' % _('End move Z')) self.endzlabel.setToolTip( - _( - "This is the height (Z) at which the CNC\n" - "will go as the last move." - ) + _("Height of the tool after\n" + "the last move at the end of the job.") ) self.grid3.addWidget(self.endzlabel, 9, 0) self.gendz_entry = FloatEntry() self.grid3.addWidget(self.gendz_entry, 9, 1) # Feedrate X-Y - frlabel = QtWidgets.QLabel(_('Feed Rate X-Y:')) + frlabel = QtWidgets.QLabel('%s:' % _('Feed Rate X-Y')) frlabel.setToolTip( - _( - "Cutting speed in the XY\n" - "plane in units per minute" - ) + _("Cutting speed in the XY\n" + "plane in units per minute") ) self.grid3.addWidget(frlabel, 10, 0) self.cncfeedrate_entry = FloatEntry() self.grid3.addWidget(self.cncfeedrate_entry, 10, 1) # Feedrate Z (Plunge) - frzlabel = QtWidgets.QLabel(_('Feed Rate Z (Plunge):')) + frzlabel = QtWidgets.QLabel('%s:' % _('Feed Rate Z')) frzlabel.setToolTip( - _( - "Cutting speed in the Z\n" - "plane in units per minute" - ) + _("Cutting speed in the XY\n" + "plane in units per minute.\n" + "It is called also Plunge.") ) self.grid3.addWidget(frzlabel, 11, 0) self.cncplunge_entry = FloatEntry() self.grid3.addWidget(self.cncplunge_entry, 11, 1) # Feedrate rapids - self.fr_rapidlabel = QtWidgets.QLabel(_('Feed Rate Rapids:')) + self.fr_rapidlabel = QtWidgets.QLabel('%s:' % _('Feed Rate Rapids')) self.fr_rapidlabel.setToolTip( - _( - "Cutting speed in the XY\n" - "plane in units per minute\n" + _("Cutting speed in the XY plane\n" "(in units per minute).\n" "This is for the rapid move G00.\n" "It is useful only for Marlin,\n" - "ignore for any other cases." - ) + "ignore for any other cases.") ) self.grid3.addWidget(self.fr_rapidlabel, 12, 0) self.cncfeedrate_rapid_entry = FloatEntry() @@ -1203,19 +1191,17 @@ class GeometryObjectUI(ObjectUI): self.cncfeedrate_rapid_entry.hide() # Cut over 1st point in path - self.extracut_cb = FCCheckBox(_('Cut over 1st pt')) + self.extracut_cb = FCCheckBox('%s' % _('Re-cut 1st pt.')) self.extracut_cb.setToolTip( - _( - "In order to remove possible\n" - "copper leftovers where first cut\n" - "meet with last cut, we generate an\n" - "extended cut over the first cut section." - ) + _("In order to remove possible\n" + "copper leftovers where first cut\n" + "meet with last cut, we generate an\n" + "extended cut over the first cut section.") ) self.grid3.addWidget(self.extracut_cb, 13, 0) # Spindlespeed - spdlabel = QtWidgets.QLabel(_('Spindle speed:')) + spdlabel = QtWidgets.QLabel('%s:' % _('Spindle speed')) spdlabel.setToolTip( _( "Speed of the spindle in RPM (optional).\n" @@ -1228,7 +1214,7 @@ class GeometryObjectUI(ObjectUI): self.grid3.addWidget(self.cncspindlespeed_entry, 14, 1) # Dwell - self.dwell_cb = FCCheckBox(_('Dwell:')) + self.dwell_cb = FCCheckBox('%s:' % _('Dwell')) self.dwell_cb.setToolTip( _( "Pause to allow the spindle to reach its\n" @@ -1237,9 +1223,7 @@ class GeometryObjectUI(ObjectUI): ) self.dwelltime_entry = FloatEntry() self.dwelltime_entry.setToolTip( - _( - "Number of milliseconds for spindle to dwell." - ) + _("Number of time units for spindle to dwell.") ) self.grid3.addWidget(self.dwell_cb, 15, 0) self.grid3.addWidget(self.dwelltime_entry, 15, 1) @@ -1247,12 +1231,10 @@ class GeometryObjectUI(ObjectUI): self.ois_dwell_geo = OptionalInputSection(self.dwell_cb, [self.dwelltime_entry]) # postprocessor selection - pp_label = QtWidgets.QLabel(_("PostProcessor:")) + pp_label = QtWidgets.QLabel('%s:' % _("PostProcessor")) pp_label.setToolTip( - _( - "The Postprocessor file that dictates\n" - "the Machine Code (like GCode, RML, HPGL) output." - ) + _("The Postprocessor file that dictates\n" + "the Machine Code (like GCode, RML, HPGL) output.") ) self.grid3.addWidget(pp_label, 16, 0) self.pp_geometry_name_cb = FCComboBox() @@ -1260,12 +1242,10 @@ class GeometryObjectUI(ObjectUI): self.grid3.addWidget(self.pp_geometry_name_cb, 16, 1) # Probe depth - self.pdepth_label = QtWidgets.QLabel(_("Probe Z depth:")) + self.pdepth_label = QtWidgets.QLabel('%s:' % _("Probe Z depth")) self.pdepth_label.setToolTip( - _( - "The maximum depth that the probe is allowed\n" - "to probe. Negative value, in current units." - ) + _("The maximum depth that the probe is allowed\n" + "to probe. Negative value, in current units.") ) self.grid3.addWidget(self.pdepth_label, 17, 0) self.pdepth_entry = FCEntry() @@ -1274,11 +1254,9 @@ class GeometryObjectUI(ObjectUI): self.pdepth_entry.setVisible(False) # Probe feedrate - self.feedrate_probe_label = QtWidgets.QLabel(_("Feedrate Probe:")) + self.feedrate_probe_label = QtWidgets.QLabel('%s:' % _("Feedrate Probe")) self.feedrate_probe_label.setToolTip( - _( - "The feedrate used while the probe is probing." - ) + _("The feedrate used while the probe is probing.") ) self.grid3.addWidget(self.feedrate_probe_label, 18, 0) self.feedrate_probe_entry = FCEntry() @@ -1297,16 +1275,14 @@ class GeometryObjectUI(ObjectUI): # Button self.generate_cnc_button = QtWidgets.QPushButton(_('Generate')) self.generate_cnc_button.setToolTip( - _( - "Generate the CNC Job object." - ) + _("Generate the CNC Job object.") ) self.geo_param_box.addWidget(self.generate_cnc_button) # ############## # Paint area ## # ############## - self.paint_label = QtWidgets.QLabel(_('Paint Area:')) + self.paint_label = QtWidgets.QLabel('%s' % _('Paint Area')) self.paint_label.setToolTip( _( "Creates tool paths to cover the\n" @@ -1320,9 +1296,7 @@ class GeometryObjectUI(ObjectUI): # GO Button self.paint_tool_button = QtWidgets.QPushButton(_('Paint Tool')) self.paint_tool_button.setToolTip( - _( - "Launch Paint Tool in Tools Tab." - ) + _("Launch Paint Tool in Tools Tab.") ) self.geo_tools_box.addWidget(self.paint_tool_button) @@ -1444,7 +1418,7 @@ class CNCObjectUI(ObjectUI): self.custom_box.addLayout(hlay) # CNC Tools Table for plot - self.cnc_tools_table_label = QtWidgets.QLabel(_('CNC Tools Table')) + self.cnc_tools_table_label = QtWidgets.QLabel('%s' % _('CNC Tools Table')) self.cnc_tools_table_label.setToolTip( _( "Tools in this CNCJob object used for cutting.\n" @@ -1464,9 +1438,7 @@ class CNCObjectUI(ObjectUI): # self.plot_cb = QtWidgets.QCheckBox('Plot') self.plot_cb = FCCheckBox(_('Plot Object')) self.plot_cb.setToolTip( - _( - "Plot (show) this object." - ) + _("Plot (show) this object.") ) self.plot_cb.setLayoutDirection(QtCore.Qt.RightToLeft) hlay.addStretch() @@ -1499,17 +1471,15 @@ class CNCObjectUI(ObjectUI): self.export_gcode_label = QtWidgets.QLabel("%s:" % _("Export CNC Code")) self.export_gcode_label.setToolTip( _("Export and save G-Code to\n" - "make this object to a file.") + "make this object to a file.") ) self.custom_box.addWidget(self.export_gcode_label) # Prepend text to GCode - prependlabel = QtWidgets.QLabel(_('Prepend to CNC Code:')) + prependlabel = QtWidgets.QLabel('%s:' % _('Prepend to CNC Code')) prependlabel.setToolTip( - _( - "Type here any G-Code commands you would\n" - "like to add to the beginning of the generated file." - ) + _("Type here any G-Code commands you would\n" + "like to add at the beginning of the G-Code file.") ) self.custom_box.addWidget(prependlabel) @@ -1517,13 +1487,11 @@ class CNCObjectUI(ObjectUI): self.custom_box.addWidget(self.prepend_text) # Append text to GCode - appendlabel = QtWidgets.QLabel(_('Append to CNC Code:')) + appendlabel = QtWidgets.QLabel('%s:' % _('Append to CNC Code')) appendlabel.setToolTip( - _( - "Type here any G-Code commands you would\n" - "like to append to the generated file.\n" - "I.e.: M2 (End of program)" - ) + _("Type here any G-Code commands you would\n" + "like to append to the generated file.\n" + "I.e.: M2 (End of program)") ) self.custom_box.addWidget(appendlabel) @@ -1538,7 +1506,7 @@ class CNCObjectUI(ObjectUI): self.cnc_frame.setLayout(self.cnc_box) # Toolchange Custom G-Code - self.toolchangelabel = QtWidgets.QLabel(_('Toolchange G-Code:')) + self.toolchangelabel = QtWidgets.QLabel('%s:' % _('Toolchange G-Code')) self.toolchangelabel.setToolTip( _( "Type here any G-Code commands you would\n" @@ -1560,12 +1528,10 @@ class CNCObjectUI(ObjectUI): self.cnc_box.addLayout(cnclay) # Toolchange Replacement Enable - self.toolchange_cb = FCCheckBox(label=_('Use Toolchange Macro')) + self.toolchange_cb = FCCheckBox(label='%s' % _('Use Toolchange Macro')) self.toolchange_cb.setToolTip( - _( - "Check this box if you want to use\n" - "a Custom Toolchange GCode (macro)." - ) + _("Check this box if you want to use\n" + "a Custom Toolchange GCode (macro).") ) # Variable list @@ -1611,19 +1577,15 @@ class CNCObjectUI(ObjectUI): # Edit GCode Button self.modify_gcode_button = QtWidgets.QPushButton(_('View CNC Code')) self.modify_gcode_button.setToolTip( - _( - "Opens TAB to view/modify/print G-Code\n" - "file." - ) + _("Opens TAB to view/modify/print G-Code\n" + "file.") ) # GO Button self.export_gcode_button = QtWidgets.QPushButton(_('Save CNC Code')) self.export_gcode_button.setToolTip( - _( - "Opens dialog to save G-Code\n" - "file." - ) + _("Opens dialog to save G-Code\n" + "file.") ) h_lay.addWidget(self.modify_gcode_button) diff --git a/flatcamTools/ToolCalculators.py b/flatcamTools/ToolCalculators.py index 5b88df71..17081246 100644 --- a/flatcamTools/ToolCalculators.py +++ b/flatcamTools/ToolCalculators.py @@ -89,28 +89,29 @@ class ToolCalculator(FlatCAMTool): form_layout = QtWidgets.QFormLayout() self.layout.addLayout(form_layout) - self.tipDia_label = QtWidgets.QLabel(_("Tip Diameter:")) + self.tipDia_label = QtWidgets.QLabel('%s:' % _("Tip Diameter")) self.tipDia_entry = FCEntry() # self.tipDia_entry.setFixedWidth(70) self.tipDia_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) - self.tipDia_label.setToolTip(_('This is the diameter of the tool tip.\n' - 'The manufacturer specifies it.')) - - self.tipAngle_label = QtWidgets.QLabel(_("Tip Angle:")) + self.tipDia_label.setToolTip( + _("This is the tool tip diameter.\n" + "It is specified by manufacturer.") + ) + self.tipAngle_label = QtWidgets.QLabel('%s:' % _("Tip Angle")) self.tipAngle_entry = FCEntry() # self.tipAngle_entry.setFixedWidth(70) self.tipAngle_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) self.tipAngle_label.setToolTip(_("This is the angle of the tip of the tool.\n" "It is specified by manufacturer.")) - self.cutDepth_label = QtWidgets.QLabel(_("Cut Z:")) + self.cutDepth_label = QtWidgets.QLabel('%s:' % _("Cut Z")) self.cutDepth_entry = FCEntry() # self.cutDepth_entry.setFixedWidth(70) self.cutDepth_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) self.cutDepth_label.setToolTip(_("This is the depth to cut into the material.\n" "In the CNCJob is the CutZ parameter.")) - self.effectiveToolDia_label = QtWidgets.QLabel(_("Tool Diameter:")) + self.effectiveToolDia_label = QtWidgets.QLabel('%s:' % _("Tool Diameter")) self.effectiveToolDia_entry = FCEntry() # self.effectiveToolDia_entry.setFixedWidth(70) self.effectiveToolDia_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) @@ -154,26 +155,26 @@ class ToolCalculator(FlatCAMTool): plate_form_layout = QtWidgets.QFormLayout() self.layout.addLayout(plate_form_layout) - self.pcblengthlabel = QtWidgets.QLabel(_("Board Length:")) + self.pcblengthlabel = QtWidgets.QLabel('%s:' % _("Board Length")) self.pcblength_entry = FCEntry() # self.pcblengthlabel.setFixedWidth(70) self.pcblength_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) self.pcblengthlabel.setToolTip(_('This is the board length. In centimeters.')) - self.pcbwidthlabel = QtWidgets.QLabel(_("Board Width:")) + self.pcbwidthlabel = QtWidgets.QLabel('%s:' % _("Board Width")) self.pcbwidth_entry = FCEntry() # self.pcbwidthlabel.setFixedWidth(70) self.pcbwidth_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) self.pcbwidthlabel.setToolTip(_('This is the board width.In centimeters.')) - self.cdensity_label = QtWidgets.QLabel(_("Current Density:")) + self.cdensity_label = QtWidgets.QLabel('%s:' % _("Current Density")) self.cdensity_entry = FCEntry() # self.cdensity_entry.setFixedWidth(70) self.cdensity_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) self.cdensity_label.setToolTip(_("Current density to pass through the board. \n" "In Amps per Square Feet ASF.")) - self.growth_label = QtWidgets.QLabel(_("Copper Growth:")) + self.growth_label = QtWidgets.QLabel('%s:' % _("Copper Growth")) self.growth_entry = FCEntry() # self.growth_entry.setFixedWidth(70) self.growth_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) @@ -182,7 +183,7 @@ class ToolCalculator(FlatCAMTool): # self.growth_entry.setEnabled(False) - self.cvaluelabel = QtWidgets.QLabel(_("Current Value:")) + self.cvaluelabel = QtWidgets.QLabel('%s:' % _("Current Value")) self.cvalue_entry = FCEntry() # self.cvaluelabel.setFixedWidth(70) self.cvalue_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) @@ -190,7 +191,7 @@ class ToolCalculator(FlatCAMTool): 'to be set on the Power Supply. In Amps.')) self.cvalue_entry.setDisabled(True) - self.timelabel = QtWidgets.QLabel(_("Time:")) + self.timelabel = QtWidgets.QLabel('%s:' % _("Time")) self.time_entry = FCEntry() # self.timelabel.setFixedWidth(70) self.time_entry.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter) diff --git a/flatcamTools/ToolCutOut.py b/flatcamTools/ToolCutOut.py index b77ef5d8..6388705a 100644 --- a/flatcamTools/ToolCutOut.py +++ b/flatcamTools/ToolCutOut.py @@ -51,7 +51,7 @@ class CutOut(FlatCAMTool): # self.type_obj_combo.setItemIcon(1, QtGui.QIcon("share/drill16.png")) self.type_obj_combo.setItemIcon(2, QtGui.QIcon("share/geometry16.png")) - self.type_obj_combo_label = QtWidgets.QLabel(_("Obj Type:")) + self.type_obj_combo_label = QtWidgets.QLabel('%s:' % _("Obj Type")) self.type_obj_combo_label.setToolTip( _("Specify the type of object to be cutout.\n" "It can be of type: Gerber or Geometry.\n" @@ -67,14 +67,14 @@ class CutOut(FlatCAMTool): self.obj_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex())) self.obj_combo.setCurrentIndex(1) - self.object_label = QtWidgets.QLabel(_("Object:")) + self.object_label = QtWidgets.QLabel('%s:' % _("Object")) self.object_label.setToolTip( _("Object to be cutout. ") ) form_layout.addRow(self.object_label, self.obj_combo) # Object kind - self.kindlabel = QtWidgets.QLabel(_('Obj kind:')) + self.kindlabel = QtWidgets.QLabel('%s:' % _('Obj kind')) self.kindlabel.setToolTip( _("Choice of what kind the object we want to cutout is.
" "- Single: contain a single PCB Gerber outline object.
" @@ -89,7 +89,7 @@ class CutOut(FlatCAMTool): # Tool Diameter self.dia = FCEntry() - self.dia_label = QtWidgets.QLabel(_("Tool Dia:")) + self.dia_label = QtWidgets.QLabel('%s:' % _("Tool dia")) self.dia_label.setToolTip( _("Diameter of the tool used to cutout\n" "the PCB shape out of the surrounding material.") @@ -98,7 +98,7 @@ class CutOut(FlatCAMTool): # Margin self.margin = FCEntry() - self.margin_label = QtWidgets.QLabel(_("Margin:")) + self.margin_label = QtWidgets.QLabel('%s:' % _("Margin:")) self.margin_label.setToolTip( _("Margin over bounds. A positive value here\n" "will make the cutout of the PCB further from\n" @@ -108,7 +108,7 @@ class CutOut(FlatCAMTool): # Gapsize self.gapsize = FCEntry() - self.gapsize_label = QtWidgets.QLabel(_("Gap size:")) + self.gapsize_label = QtWidgets.QLabel('%s:' % _("Gap size:")) self.gapsize_label.setToolTip( _("The size of the bridge gaps in the cutout\n" "used to keep the board connected to\n" @@ -127,7 +127,7 @@ class CutOut(FlatCAMTool): # Surrounding convex box shape self.convex_box = FCCheckBox() - self.convex_box_label = QtWidgets.QLabel(_("Convex Sh.:")) + self.convex_box_label = QtWidgets.QLabel('%s:' % _("Convex Sh.")) self.convex_box_label.setToolTip( _("Create a convex shape surrounding the entire PCB.\n" "Used only if the source object type is Gerber.") @@ -146,7 +146,7 @@ class CutOut(FlatCAMTool): self.layout.addLayout(form_layout_2) # Gaps - gaps_label = QtWidgets.QLabel(_('Gaps:')) + gaps_label = QtWidgets.QLabel('%s:' % _('Gaps')) gaps_label.setToolTip( _("Number of gaps used for the Automatic cutout.\n" "There can be maximum 8 bridges/gaps.\n" @@ -171,7 +171,7 @@ class CutOut(FlatCAMTool): hlay = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay) - title_ff_label = QtWidgets.QLabel("%s" % _('FreeForm:')) + title_ff_label = QtWidgets.QLabel("%s:" % _('FreeForm')) title_ff_label.setToolTip( _("The cutout shape can be of ny shape.\n" "Useful when the PCB has a non-rectangular shape.") @@ -191,7 +191,7 @@ class CutOut(FlatCAMTool): hlay2 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay2) - title_rct_label = QtWidgets.QLabel("%s" % _('Rectangular:')) + title_rct_label = QtWidgets.QLabel("%s:" % _('Rectangular')) title_rct_label.setToolTip( _("The resulting cutout shape is\n" "always a rectangle shape and it will be\n" @@ -228,7 +228,7 @@ class CutOut(FlatCAMTool): self.man_object_combo.setRootModelIndex(self.app.collection.index(2, 0, QtCore.QModelIndex())) self.man_object_combo.setCurrentIndex(1) - self.man_object_label = QtWidgets.QLabel(_("Geo Obj:")) + self.man_object_label = QtWidgets.QLabel('%s:' % _("Geo Obj")) self.man_object_label.setToolTip( _("Geometry object used to create the manual cutout.") ) @@ -241,7 +241,7 @@ class CutOut(FlatCAMTool): hlay3 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay3) - self.man_geo_label = QtWidgets.QLabel(_("Manual Geo:")) + self.man_geo_label = QtWidgets.QLabel('%s:' % _("Manual Geo")) self.man_geo_label.setToolTip( _("If the object to be cutout is a Gerber\n" "first create a Geometry that surrounds it,\n" @@ -263,7 +263,7 @@ class CutOut(FlatCAMTool): hlay4 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay4) - self.man_bridge_gaps_label = QtWidgets.QLabel(_("Manual Add Bridge Gaps:")) + self.man_bridge_gaps_label = QtWidgets.QLabel('%s:' % _("Manual Add Bridge Gaps")) self.man_bridge_gaps_label.setToolTip( _("Use the left mouse button (LMB) click\n" "to create a bridge gap to separate the PCB from\n" diff --git a/flatcamTools/ToolDblSided.py b/flatcamTools/ToolDblSided.py index 894f7628..a8cd5a05 100644 --- a/flatcamTools/ToolDblSided.py +++ b/flatcamTools/ToolDblSided.py @@ -149,7 +149,7 @@ class DblSidedTool(FlatCAMTool): # ## Point/Box self.point_box_container = QtWidgets.QVBoxLayout() - self.pb_label = QtWidgets.QLabel("%s" % _('Point/Box Reference:')) + self.pb_label = QtWidgets.QLabel("%s:" % _('Point/Box Reference')) self.pb_label.setToolTip( _("If 'Point' is selected above it store the coordinates (x, y) through which\n" "the mirroring axis passes.\n" @@ -189,7 +189,7 @@ class DblSidedTool(FlatCAMTool): self.box_combo_type.hide() # ## Alignment holes - self.ah_label = QtWidgets.QLabel("%s" % _('Alignment Drill Coordinates:')) + self.ah_label = QtWidgets.QLabel("%s:" % _('Alignment Drill Coordinates')) self.ah_label.setToolTip( _("Alignment holes (x1, y1), (x2, y2), ... " "on one side of the mirror axis. For each set of (x, y) coordinates\n" @@ -220,7 +220,7 @@ class DblSidedTool(FlatCAMTool): grid_lay3.addWidget(self.add_drill_point_button, 0, 1) # ## Drill diameter for alignment holes - self.dt_label = QtWidgets.QLabel("%s:" % _('Alignment Drill Diameter')) + self.dt_label = QtWidgets.QLabel("%s:" % _('Alignment Drill Diameter')) self.dt_label.setToolTip( _("Diameter of the drill for the " "alignment holes.") @@ -231,7 +231,7 @@ class DblSidedTool(FlatCAMTool): self.layout.addLayout(hlay) self.drill_dia = FCEntry() - self.dd_label = QtWidgets.QLabel(_("Drill diam.:")) + self.dd_label = QtWidgets.QLabel('%s:' % _("Drill dia")) self.dd_label.setToolTip( _("Diameter of the drill for the " "alignment holes.") diff --git a/flatcamTools/ToolFilm.py b/flatcamTools/ToolFilm.py index 0d4f36ae..d2ca9940 100644 --- a/flatcamTools/ToolFilm.py +++ b/flatcamTools/ToolFilm.py @@ -53,7 +53,7 @@ class Film(FlatCAMTool): self.tf_type_obj_combo.setItemIcon(0, QtGui.QIcon("share/flatcam_icon16.png")) self.tf_type_obj_combo.setItemIcon(2, QtGui.QIcon("share/geometry16.png")) - self.tf_type_obj_combo_label = QtWidgets.QLabel(_("Object Type:")) + self.tf_type_obj_combo_label = QtWidgets.QLabel('%s:' % _("Object Type")) self.tf_type_obj_combo_label.setToolTip( _("Specify the type of object for which to create the film.\n" "The object can be of type: Gerber or Geometry.\n" @@ -68,7 +68,7 @@ class Film(FlatCAMTool): self.tf_object_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex())) self.tf_object_combo.setCurrentIndex(1) - self.tf_object_label = QtWidgets.QLabel(_("Film Object:")) + self.tf_object_label = QtWidgets.QLabel('%s:' % _("Film Object")) self.tf_object_label.setToolTip( _("Object for which to create the film.") ) @@ -101,7 +101,7 @@ class Film(FlatCAMTool): self.tf_box_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex())) self.tf_box_combo.setCurrentIndex(1) - self.tf_box_combo_label = QtWidgets.QLabel(_("Box Object:")) + self.tf_box_combo_label = QtWidgets.QLabel('%s:' % _("Box Object")) self.tf_box_combo_label.setToolTip( _("The actual object that is used a container for the\n " "selected object for which we create the film.\n" @@ -127,7 +127,7 @@ class Film(FlatCAMTool): # Boundary for negative film generation self.boundary_entry = FCEntry() - self.boundary_label = QtWidgets.QLabel(_("Border:")) + self.boundary_label = QtWidgets.QLabel('%s:' % _("Border")) self.boundary_label.setToolTip( _("Specify a border around the object.\n" "Only for negative film.\n" @@ -141,7 +141,7 @@ class Film(FlatCAMTool): tf_form_layout.addRow(self.boundary_label, self.boundary_entry) self.film_scale_entry = FCEntry() - self.film_scale_label = QtWidgets.QLabel(_("Scale Stroke:")) + self.film_scale_label = QtWidgets.QLabel('%s:' % _("Scale Stroke")) self.film_scale_label.setToolTip( _("Scale the line stroke thickness of each feature in the SVG file.\n" "It means that the line that envelope each SVG feature will be thicker or thinner,\n" diff --git a/flatcamTools/ToolImage.py b/flatcamTools/ToolImage.py index 0d6061ae..f0f25265 100644 --- a/flatcamTools/ToolImage.py +++ b/flatcamTools/ToolImage.py @@ -50,7 +50,7 @@ class ToolImage(FlatCAMTool): self.tf_type_obj_combo.setItemIcon(0, QtGui.QIcon("share/flatcam_icon16.png")) self.tf_type_obj_combo.setItemIcon(1, QtGui.QIcon("share/geometry16.png")) - self.tf_type_obj_combo_label = QtWidgets.QLabel(_("Object Type:")) + self.tf_type_obj_combo_label = QtWidgets.QLabel('%s:' % _("Object Type")) self.tf_type_obj_combo_label.setToolTip( _("Specify the type of object to create from the image.\n" "It can be of type: Gerber or Geometry.") @@ -60,7 +60,7 @@ class ToolImage(FlatCAMTool): # DPI value of the imported image self.dpi_entry = IntEntry() - self.dpi_label = QtWidgets.QLabel(_("DPI value:")) + self.dpi_label = QtWidgets.QLabel('%s:' % _("DPI value")) self.dpi_label.setToolTip( _("Specify a DPI value for the image.") ) diff --git a/flatcamTools/ToolMeasurement.py b/flatcamTools/ToolMeasurement.py index 81c7eba2..4380def7 100644 --- a/flatcamTools/ToolMeasurement.py +++ b/flatcamTools/ToolMeasurement.py @@ -40,7 +40,7 @@ class Measurement(FlatCAMTool): form_layout = QtWidgets.QFormLayout() self.layout.addLayout(form_layout) - self.units_label = QtWidgets.QLabel(_("Units:")) + self.units_label = QtWidgets.QLabel('%s:' % _("Units")) self.units_label.setToolTip(_("Those are the units in which the distance is measured.")) self.units_value = QtWidgets.QLabel("%s" % str({'mm': _("METRIC (mm)"), 'in': _("INCH (in)")}[self.units])) self.units_value.setDisabled(True) @@ -51,10 +51,10 @@ class Measurement(FlatCAMTool): self.stop_label = QtWidgets.QLabel("%s %s:" % (_('Stop'), _('Coords'))) self.stop_label.setToolTip(_("This is the measuring Stop point coordinates.")) - self.distance_x_label = QtWidgets.QLabel(_("Dx:")) + self.distance_x_label = QtWidgets.QLabel('%s:' % _("Dx")) self.distance_x_label.setToolTip(_("This is the distance measured over the X axis.")) - self.distance_y_label = QtWidgets.QLabel(_("Dy:")) + self.distance_y_label = QtWidgets.QLabel('%s:' % _("Dy")) self.distance_y_label.setToolTip(_("This is the distance measured over the Y axis.")) self.total_distance_label = QtWidgets.QLabel("%s:" % _('DISTANCE')) diff --git a/flatcamTools/ToolNonCopperClear.py b/flatcamTools/ToolNonCopperClear.py index 4f6592ee..120ab189 100644 --- a/flatcamTools/ToolNonCopperClear.py +++ b/flatcamTools/ToolNonCopperClear.py @@ -192,7 +192,7 @@ class NonCopperClear(FlatCAMTool, Gerber): self.ncc_overlap_entry = FCEntry() grid3.addWidget(self.ncc_overlap_entry, 1, 1) - nccmarginlabel = QtWidgets.QLabel(_('Margin:')) + nccmarginlabel = QtWidgets.QLabel('%s:' % _('Margin')) nccmarginlabel.setToolTip( _("Bounding box margin.") ) @@ -201,7 +201,7 @@ class NonCopperClear(FlatCAMTool, Gerber): grid3.addWidget(self.ncc_margin_entry, 2, 1) # Method - methodlabel = QtWidgets.QLabel(_('Method:')) + methodlabel = QtWidgets.QLabel('%s:' % _('Method')) methodlabel.setToolTip( _("Algorithm for non-copper clearing:
" "Standard: Fixed step inwards.
" @@ -217,7 +217,7 @@ class NonCopperClear(FlatCAMTool, Gerber): grid3.addWidget(self.ncc_method_radio, 3, 1) # Connect lines - pathconnectlabel = QtWidgets.QLabel(_("Connect:")) + pathconnectlabel = QtWidgets.QLabel('%s:' % _("Connect")) pathconnectlabel.setToolTip( _("Draw lines between resulting\n" "segments to minimize tool lifts.") @@ -226,7 +226,7 @@ class NonCopperClear(FlatCAMTool, Gerber): self.ncc_connect_cb = FCCheckBox() grid3.addWidget(self.ncc_connect_cb, 4, 1) - contourlabel = QtWidgets.QLabel(_("Contour:")) + contourlabel = QtWidgets.QLabel('%s:' % _("Contour")) contourlabel.setToolTip( _("Cut around the perimeter of the polygon\n" "to trim rough edges.") @@ -235,7 +235,7 @@ class NonCopperClear(FlatCAMTool, Gerber): self.ncc_contour_cb = FCCheckBox() grid3.addWidget(self.ncc_contour_cb, 5, 1) - restlabel = QtWidgets.QLabel(_("Rest M.:")) + restlabel = QtWidgets.QLabel('%s:' % _("Rest M.")) restlabel.setToolTip( _("If checked, use 'rest machining'.\n" "Basically it will clear copper outside PCB features,\n" @@ -250,7 +250,7 @@ class NonCopperClear(FlatCAMTool, Gerber): grid3.addWidget(self.ncc_rest_cb, 6, 1) # ## NCC Offset choice - self.ncc_offset_choice_label = QtWidgets.QLabel(_("Offset:")) + self.ncc_offset_choice_label = QtWidgets.QLabel('%s:' % _("Offset")) self.ncc_offset_choice_label.setToolTip( _("If used, it will add an offset to the copper features.\n" "The copper clearing will finish to a distance\n" @@ -262,7 +262,7 @@ class NonCopperClear(FlatCAMTool, Gerber): grid3.addWidget(self.ncc_choice_offset_cb, 7, 1) # ## NCC Offset value - self.ncc_offset_label = QtWidgets.QLabel(_("Offset value:")) + self.ncc_offset_label = QtWidgets.QLabel('%s:' % _("Offset value")) self.ncc_offset_label.setToolTip( _("If used, it will add an offset to the copper features.\n" "The copper clearing will finish to a distance\n" @@ -291,10 +291,10 @@ class NonCopperClear(FlatCAMTool, Gerber): {'label': _('Box'), 'value': 'box'}]) self.reference_label = QtWidgets.QLabel(_("Reference:")) self.reference_label.setToolTip( - _("- 'Itself': the non copper clearing extent\n" + _("When choosing the 'Itself' option the non copper clearing extent\n" "is based on the object that is copper cleared.\n " - "- 'Box': will do non copper clearing within the box\n" - "specified by the object selected in the Ref. Object combobox.") + "Choosing the 'Box' option will do non copper clearing within the box\n" + "specified by another object different than the one that is copper cleared.") ) grid3.addWidget(self.reference_label, 9, 0) grid3.addWidget(self.reference_radio, 9, 1) @@ -302,7 +302,7 @@ class NonCopperClear(FlatCAMTool, Gerber): grid4 = QtWidgets.QGridLayout() self.tools_box.addLayout(grid4) - self.box_combo_type_label = QtWidgets.QLabel(_("Ref. Type:")) + self.box_combo_type_label = QtWidgets.QLabel('%s:' % _("Ref. Type")) self.box_combo_type_label.setToolTip( _("The type of FlatCAM object to be used as non copper clearing reference.\n" "It can be Gerber, Excellon or Geometry.") @@ -315,7 +315,7 @@ class NonCopperClear(FlatCAMTool, Gerber): grid4.addWidget(self.box_combo_type_label, 0, 0) grid4.addWidget(self.box_combo_type, 0, 1) - self.box_combo_label = QtWidgets.QLabel(_("Ref. Object:")) + self.box_combo_label = QtWidgets.QLabel('%s:' % _("Ref. Object")) self.box_combo_label.setToolTip( _("The FlatCAM object to be used as non copper clearing reference.") ) diff --git a/flatcamTools/ToolPaint.py b/flatcamTools/ToolPaint.py index 8e37b56a..6c6b7f60 100644 --- a/flatcamTools/ToolPaint.py +++ b/flatcamTools/ToolPaint.py @@ -58,7 +58,7 @@ class ToolPaint(FlatCAMTool, Gerber): self.object_combo.setRootModelIndex(self.app.collection.index(2, 0, QtCore.QModelIndex())) self.object_combo.setCurrentIndex(1) - self.object_label = QtWidgets.QLabel(_("Geometry:")) + self.object_label = QtWidgets.QLabel('%s:' % _("Geometry")) self.object_label.setToolTip( _("Geometry object to be painted. ") ) @@ -158,7 +158,7 @@ class ToolPaint(FlatCAMTool, Gerber): self.tools_box.addLayout(grid3) # Overlap - ovlabel = QtWidgets.QLabel(_('Overlap Rate:')) + ovlabel = QtWidgets.QLabel('%s:' % _('Overlap Rate')) ovlabel.setToolTip( _("How much (fraction) of the tool width to overlap each tool pass.\n" "Example:\n" @@ -175,7 +175,7 @@ class ToolPaint(FlatCAMTool, Gerber): grid3.addWidget(self.paintoverlap_entry, 1, 1) # Margin - marginlabel = QtWidgets.QLabel(_('Margin:')) + marginlabel = QtWidgets.QLabel('%s:' % _('Margin')) marginlabel.setToolTip( _("Distance by which to avoid\n" "the edges of the polygon to\n" @@ -186,7 +186,7 @@ class ToolPaint(FlatCAMTool, Gerber): grid3.addWidget(self.paintmargin_entry, 2, 1) # Method - methodlabel = QtWidgets.QLabel(_('Method:')) + methodlabel = QtWidgets.QLabel('%s:' % _('Method')) methodlabel.setToolTip( _("Algorithm for non-copper clearing:
" "Standard: Fixed step inwards.
" @@ -202,7 +202,7 @@ class ToolPaint(FlatCAMTool, Gerber): grid3.addWidget(self.paintmethod_combo, 3, 1) # Connect lines - pathconnectlabel = QtWidgets.QLabel(_("Connect:")) + pathconnectlabel = QtWidgets.QLabel('%s:' % _("Connect")) pathconnectlabel.setToolTip( _("Draw lines between resulting\n" "segments to minimize tool lifts.") @@ -211,7 +211,7 @@ class ToolPaint(FlatCAMTool, Gerber): self.pathconnect_cb = FCCheckBox() grid3.addWidget(self.pathconnect_cb, 4, 1) - contourlabel = QtWidgets.QLabel(_("Contour:")) + contourlabel = QtWidgets.QLabel('%s:' % _("Contour")) contourlabel.setToolTip( _("Cut around the perimeter of the polygon\n" "to trim rough edges.") @@ -220,7 +220,7 @@ class ToolPaint(FlatCAMTool, Gerber): self.paintcontour_cb = FCCheckBox() grid3.addWidget(self.paintcontour_cb, 5, 1) - restlabel = QtWidgets.QLabel(_("Rest M.:")) + restlabel = QtWidgets.QLabel('%s:' % _("Rest M.")) restlabel.setToolTip( _("If checked, use 'rest machining'.\n" "Basically it will clear copper outside PCB features,\n" @@ -235,7 +235,7 @@ class ToolPaint(FlatCAMTool, Gerber): grid3.addWidget(self.rest_cb, 6, 1) # Polygon selection - selectlabel = QtWidgets.QLabel(_('Selection:')) + selectlabel = QtWidgets.QLabel('%s:' % _('Selection')) selectlabel.setToolTip( _("How to select the polygons to paint.
" "Options:
" @@ -265,7 +265,7 @@ class ToolPaint(FlatCAMTool, Gerber): grid4 = QtWidgets.QGridLayout() self.tools_box.addLayout(grid4) - self.box_combo_type_label = QtWidgets.QLabel(_("Ref. Type:")) + self.box_combo_type_label = QtWidgets.QLabel('%s:' % _("Ref. Type")) self.box_combo_type_label.setToolTip( _("The type of FlatCAM object to be used as paint reference.\n" "It can be Gerber, Excellon or Geometry.") @@ -278,7 +278,7 @@ class ToolPaint(FlatCAMTool, Gerber): grid4.addWidget(self.box_combo_type_label, 0, 0) grid4.addWidget(self.box_combo_type, 0, 1) - self.box_combo_label = QtWidgets.QLabel(_("Ref. Object:")) + self.box_combo_label = QtWidgets.QLabel('%s:' % _("Ref. Object")) self.box_combo_label.setToolTip( _("The FlatCAM object to be used as non copper clearing reference.") ) diff --git a/flatcamTools/ToolPanelize.py b/flatcamTools/ToolPanelize.py index 00f89966..48df13bc 100644 --- a/flatcamTools/ToolPanelize.py +++ b/flatcamTools/ToolPanelize.py @@ -53,7 +53,7 @@ class Panelize(FlatCAMTool): self.type_obj_combo.setItemIcon(1, QtGui.QIcon("share/drill16.png")) self.type_obj_combo.setItemIcon(2, QtGui.QIcon("share/geometry16.png")) - self.type_obj_combo_label = QtWidgets.QLabel(_("Object Type:")) + self.type_obj_combo_label = QtWidgets.QLabel('%s:' % _("Object Type")) self.type_obj_combo_label.setToolTip( _("Specify the type of object to be panelized\n" "It can be of type: Gerber, Excellon or Geometry.\n" @@ -68,7 +68,7 @@ class Panelize(FlatCAMTool): self.object_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex())) self.object_combo.setCurrentIndex(1) - self.object_label = QtWidgets.QLabel(_("Object:")) + self.object_label = QtWidgets.QLabel('%s:' % _("Object")) self.object_label.setToolTip( _("Object to be panelized. This means that it will\n" "be duplicated in an array of rows and columns.") @@ -108,7 +108,7 @@ class Panelize(FlatCAMTool): self.type_box_combo.setItemIcon(0, QtGui.QIcon("share/flatcam_icon16.png")) self.type_box_combo.setItemIcon(2, QtGui.QIcon("share/geometry16.png")) - self.type_box_combo_label = QtWidgets.QLabel(_("Box Type:")) + self.type_box_combo_label = QtWidgets.QLabel('%s:' % _("Box Type")) self.type_box_combo_label.setToolTip( _("Specify the type of object to be used as an container for\n" "panelization. It can be: Gerber or Geometry type.\n" @@ -123,7 +123,7 @@ class Panelize(FlatCAMTool): self.box_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex())) self.box_combo.setCurrentIndex(1) - self.box_combo_label = QtWidgets.QLabel(_("Box Object:")) + self.box_combo_label = QtWidgets.QLabel('%s:' % _("Box Object")) self.box_combo_label.setToolTip( _("The actual object that is used a container for the\n " "selected object that is to be panelized.") @@ -144,7 +144,7 @@ class Panelize(FlatCAMTool): # Spacing Columns self.spacing_columns = FCEntry() - self.spacing_columns_label = QtWidgets.QLabel(_("Spacing cols:")) + self.spacing_columns_label = QtWidgets.QLabel('%s:' % _("Spacing cols")) self.spacing_columns_label.setToolTip( _("Spacing between columns of the desired panel.\n" "In current units.") @@ -153,7 +153,7 @@ class Panelize(FlatCAMTool): # Spacing Rows self.spacing_rows = FCEntry() - self.spacing_rows_label = QtWidgets.QLabel(_("Spacing rows:")) + self.spacing_rows_label = QtWidgets.QLabel('%s:' % _("Spacing rows")) self.spacing_rows_label.setToolTip( _("Spacing between rows of the desired panel.\n" "In current units.") @@ -162,7 +162,7 @@ class Panelize(FlatCAMTool): # Columns self.columns = FCEntry() - self.columns_label = QtWidgets.QLabel(_("Columns:")) + self.columns_label = QtWidgets.QLabel('%s:' % _("Columns")) self.columns_label.setToolTip( _("Number of columns of the desired panel") ) @@ -170,7 +170,7 @@ class Panelize(FlatCAMTool): # Rows self.rows = FCEntry() - self.rows_label = QtWidgets.QLabel(_("Rows:")) + self.rows_label = QtWidgets.QLabel('%s:' % _("Rows")) self.rows_label.setToolTip( _("Number of rows of the desired panel") ) @@ -190,7 +190,7 @@ class Panelize(FlatCAMTool): form_layout.addRow(self.panel_type_radio) # Constrains - self.constrain_cb = FCCheckBox(_("Constrain panel within:")) + self.constrain_cb = FCCheckBox('%s:' % _("Constrain panel within")) self.constrain_cb.setToolTip( _("Area define by DX and DY within to constrain the panel.\n" "DX and DY values are in current units.\n" @@ -201,7 +201,7 @@ class Panelize(FlatCAMTool): form_layout.addRow(self.constrain_cb) self.x_width_entry = FCEntry() - self.x_width_lbl = QtWidgets.QLabel(_("Width (DX):")) + self.x_width_lbl = QtWidgets.QLabel('%s:' % _("Width (DX)")) self.x_width_lbl.setToolTip( _("The width (DX) within which the panel must fit.\n" "In current units.") @@ -209,7 +209,7 @@ class Panelize(FlatCAMTool): form_layout.addRow(self.x_width_lbl, self.x_width_entry) self.y_height_entry = FCEntry() - self.y_height_lbl = QtWidgets.QLabel(_("Height (DY):")) + self.y_height_lbl = QtWidgets.QLabel('%s:' % _("Height (DY)")) self.y_height_lbl.setToolTip( _("The height (DY)within which the panel must fit.\n" "In current units.") diff --git a/flatcamTools/ToolPcbWizard.py b/flatcamTools/ToolPcbWizard.py index a52b1ba6..1bdcf054 100644 --- a/flatcamTools/ToolPcbWizard.py +++ b/flatcamTools/ToolPcbWizard.py @@ -54,7 +54,7 @@ class PcbWizard(FlatCAMTool): form_layout = QtWidgets.QFormLayout() self.layout.addLayout(form_layout) - self.excellon_label = QtWidgets.QLabel(_("Excellon file:")) + self.excellon_label = QtWidgets.QLabel('%s:' % _("Excellon file")) self.excellon_label.setToolTip( _("Load the Excellon file.\n" "Usually it has a .DRL extension") @@ -62,7 +62,7 @@ class PcbWizard(FlatCAMTool): self.excellon_brn = FCButton(_("Open")) form_layout.addRow(self.excellon_label, self.excellon_brn) - self.inf_label = QtWidgets.QLabel(_("INF file:")) + self.inf_label = QtWidgets.QLabel('%s:' % _("INF file")) self.inf_label.setToolTip( _("Load the INF file.") ) @@ -92,7 +92,7 @@ class PcbWizard(FlatCAMTool): # Integral part of the coordinates self.int_entry = FCSpinner() self.int_entry.set_range(1, 10) - self.int_label = QtWidgets.QLabel(_("Int. digits:")) + self.int_label = QtWidgets.QLabel('%s:' % _("Int. digits")) self.int_label.setToolTip( _("The number of digits for the integral part of the coordinates.") ) @@ -101,7 +101,7 @@ class PcbWizard(FlatCAMTool): # Fractional part of the coordinates self.frac_entry = FCSpinner() self.frac_entry.set_range(1, 10) - self.frac_label = QtWidgets.QLabel(_("Frac. digits:")) + self.frac_label = QtWidgets.QLabel('%s:' % _("Frac. digits")) self.frac_label.setToolTip( _("The number of digits for the fractional part of the coordinates.") ) @@ -111,7 +111,7 @@ class PcbWizard(FlatCAMTool): self.zeros_radio = RadioSet([{'label': _('LZ'), 'value': 'LZ'}, {'label': _('TZ'), 'value': 'TZ'}, {'label': _('No Suppression'), 'value': 'D'}]) - self.zeros_label = QtWidgets.QLabel(_("Zeros supp.:")) + self.zeros_label = QtWidgets.QLabel('%s:' % _("Zeros supp.")) self.zeros_label.setToolTip( _("The type of zeros suppression used.\n" "Can be of type:\n" diff --git a/flatcamTools/ToolSolderPaste.py b/flatcamTools/ToolSolderPaste.py index 0ebfb665..3ac90247 100644 --- a/flatcamTools/ToolSolderPaste.py +++ b/flatcamTools/ToolSolderPaste.py @@ -139,7 +139,7 @@ class SolderPaste(FlatCAMTool): grid0_1 = QtWidgets.QGridLayout() self.layout.addLayout(grid0_1) - step1_lbl = QtWidgets.QLabel("%s:" % _('STEP 1:')) + step1_lbl = QtWidgets.QLabel("%s:" % _('STEP 1')) step1_lbl.setToolTip( _("First step is to select a number of nozzle tools for usage\n" "and then optionally modify the GCode parameters bellow.") @@ -163,7 +163,7 @@ class SolderPaste(FlatCAMTool): # Z dispense start self.z_start_entry = FCEntry() - self.z_start_label = QtWidgets.QLabel(_("Z Dispense Start:")) + self.z_start_label = QtWidgets.QLabel('%s:' % _("Z Dispense Start")) self.z_start_label.setToolTip( _("The height (Z) when solder paste dispensing starts.") ) @@ -171,7 +171,7 @@ class SolderPaste(FlatCAMTool): # Z dispense self.z_dispense_entry = FCEntry() - self.z_dispense_label = QtWidgets.QLabel(_("Z Dispense:")) + self.z_dispense_label = QtWidgets.QLabel('%s:' % _("Z Dispense")) self.z_dispense_label.setToolTip( _("The height (Z) when doing solder paste dispensing.") ) @@ -179,7 +179,7 @@ class SolderPaste(FlatCAMTool): # Z dispense stop self.z_stop_entry = FCEntry() - self.z_stop_label = QtWidgets.QLabel(_("Z Dispense Stop:")) + self.z_stop_label = QtWidgets.QLabel('%s:' % _("Z Dispense Stop")) self.z_stop_label.setToolTip( _("The height (Z) when solder paste dispensing stops.") ) @@ -187,7 +187,7 @@ class SolderPaste(FlatCAMTool): # Z travel self.z_travel_entry = FCEntry() - self.z_travel_label = QtWidgets.QLabel(_("Z Travel:")) + self.z_travel_label = QtWidgets.QLabel('%s:' % _("Z Travel")) self.z_travel_label.setToolTip( _("The height (Z) for travel between pads\n" "(without dispensing solder paste).") @@ -196,7 +196,7 @@ class SolderPaste(FlatCAMTool): # Z toolchange location self.z_toolchange_entry = FCEntry() - self.z_toolchange_label = QtWidgets.QLabel(_("Z Toolchange:")) + self.z_toolchange_label = QtWidgets.QLabel('%s:' % _("Z Toolchange")) self.z_toolchange_label.setToolTip( _("The height (Z) for tool (nozzle) change.") ) @@ -204,7 +204,7 @@ class SolderPaste(FlatCAMTool): # X,Y Toolchange location self.xy_toolchange_entry = FCEntry() - self.xy_toolchange_label = QtWidgets.QLabel(_("XY Toolchange:")) + self.xy_toolchange_label = QtWidgets.QLabel('%s:' % _("Toolchange X-Y")) self.xy_toolchange_label.setToolTip( _("The X,Y location for tool (nozzle) change.\n" "The format is (x, y) where x and y are real numbers.") @@ -213,7 +213,7 @@ class SolderPaste(FlatCAMTool): # Feedrate X-Y self.frxy_entry = FCEntry() - self.frxy_label = QtWidgets.QLabel(_("Feedrate X-Y:")) + self.frxy_label = QtWidgets.QLabel('%s:' % _("Feedrate X-Y")) self.frxy_label.setToolTip( _("Feedrate (speed) while moving on the X-Y plane.") ) @@ -221,7 +221,7 @@ class SolderPaste(FlatCAMTool): # Feedrate Z self.frz_entry = FCEntry() - self.frz_label = QtWidgets.QLabel(_("Feedrate Z:")) + self.frz_label = QtWidgets.QLabel('%s:' % _("Feedrate Z")) self.frz_label.setToolTip( _("Feedrate (speed) while moving vertically\n" "(on Z plane).") @@ -230,7 +230,7 @@ class SolderPaste(FlatCAMTool): # Feedrate Z Dispense self.frz_dispense_entry = FCEntry() - self.frz_dispense_label = QtWidgets.QLabel(_("Feedrate Z Dispense:")) + self.frz_dispense_label = QtWidgets.QLabel('%s:' % _("Feedrate Z Dispense")) self.frz_dispense_label.setToolTip( _("Feedrate (speed) while moving up vertically\n" " to Dispense position (on Z plane).") @@ -239,7 +239,7 @@ class SolderPaste(FlatCAMTool): # Spindle Speed Forward self.speedfwd_entry = FCEntry() - self.speedfwd_label = QtWidgets.QLabel(_("Spindle Speed FWD:")) + self.speedfwd_label = QtWidgets.QLabel('%s:' % _("Spindle Speed FWD")) self.speedfwd_label.setToolTip( _("The dispenser speed while pushing solder paste\n" "through the dispenser nozzle.") @@ -248,7 +248,7 @@ class SolderPaste(FlatCAMTool): # Dwell Forward self.dwellfwd_entry = FCEntry() - self.dwellfwd_label = QtWidgets.QLabel(_("Dwell FWD:")) + self.dwellfwd_label = QtWidgets.QLabel('%s:' % _("Dwell FWD")) self.dwellfwd_label.setToolTip( _("Pause after solder dispensing.") ) @@ -256,7 +256,7 @@ class SolderPaste(FlatCAMTool): # Spindle Speed Reverse self.speedrev_entry = FCEntry() - self.speedrev_label = QtWidgets.QLabel(_("Spindle Speed REV:")) + self.speedrev_label = QtWidgets.QLabel('%s:' % _("Spindle Speed REV")) self.speedrev_label.setToolTip( _("The dispenser speed while retracting solder paste\n" "through the dispenser nozzle.") @@ -265,7 +265,7 @@ class SolderPaste(FlatCAMTool): # Dwell Reverse self.dwellrev_entry = FCEntry() - self.dwellrev_label = QtWidgets.QLabel(_("Dwell REV:")) + self.dwellrev_label = QtWidgets.QLabel('%s:' % _("Dwell REV")) self.dwellrev_label.setToolTip( _("Pause after solder paste dispenser retracted,\n" "to allow pressure equilibrium.") @@ -273,7 +273,7 @@ class SolderPaste(FlatCAMTool): self.gcode_form_layout.addRow(self.dwellrev_label, self.dwellrev_entry) # Postprocessors - pp_label = QtWidgets.QLabel(_('PostProcessors:')) + pp_label = QtWidgets.QLabel('%s:' % _('PostProcessor')) pp_label.setToolTip( _("Files that control the GCode generation.") ) @@ -303,7 +303,7 @@ class SolderPaste(FlatCAMTool): grid2 = QtWidgets.QGridLayout() self.generation_box.addLayout(grid2) - step2_lbl = QtWidgets.QLabel("%s" % _('STEP 2:')) + step2_lbl = QtWidgets.QLabel("%s:" % _('STEP 2')) step2_lbl.setToolTip( _("Second step is to create a solder paste dispensing\n" "geometry out of an Solder Paste Mask Gerber file.") @@ -321,7 +321,7 @@ class SolderPaste(FlatCAMTool): self.geo_obj_combo.setRootModelIndex(self.app.collection.index(2, 0, QtCore.QModelIndex())) self.geo_obj_combo.setCurrentIndex(1) - self.geo_object_label = QtWidgets.QLabel(_("Geo Result:")) + self.geo_object_label = QtWidgets.QLabel('%s:' % _("Geo Result")) self.geo_object_label.setToolTip( _("Geometry Solder Paste object.\n" "The name of the object has to end in:\n" @@ -332,7 +332,7 @@ class SolderPaste(FlatCAMTool): grid3 = QtWidgets.QGridLayout() self.generation_box.addLayout(grid3) - step3_lbl = QtWidgets.QLabel("%s" % _('STEP 3:')) + step3_lbl = QtWidgets.QLabel("%s:" % _('STEP 3')) step3_lbl.setToolTip( _("Third step is to select a solder paste dispensing geometry,\n" "and then generate a CNCJob object.\n\n" @@ -354,7 +354,7 @@ class SolderPaste(FlatCAMTool): self.cnc_obj_combo.setRootModelIndex(self.app.collection.index(3, 0, QtCore.QModelIndex())) self.cnc_obj_combo.setCurrentIndex(1) - self.cnc_object_label = QtWidgets.QLabel(_("CNC Result:")) + self.cnc_object_label = QtWidgets.QLabel('%s:' % _("CNC Result")) self.cnc_object_label.setToolTip( _("CNCJob Solder paste object.\n" "In order to enable the GCode save section,\n" @@ -378,7 +378,7 @@ class SolderPaste(FlatCAMTool): "on PCB pads, to a file.") ) - step4_lbl = QtWidgets.QLabel("%s" % _('STEP 4:')) + step4_lbl = QtWidgets.QLabel("%s:" % _('STEP 4')) step4_lbl.setToolTip( _("Fourth step (and last) is to select a CNCJob made from \n" "a solder paste dispensing geometry, and then view/save it's GCode.") diff --git a/flatcamTools/ToolSub.py b/flatcamTools/ToolSub.py index 1df7d259..486fc283 100644 --- a/flatcamTools/ToolSub.py +++ b/flatcamTools/ToolSub.py @@ -61,7 +61,7 @@ class ToolSub(FlatCAMTool): self.target_gerber_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex())) self.target_gerber_combo.setCurrentIndex(1) - self.target_gerber_label = QtWidgets.QLabel(_("Target:")) + self.target_gerber_label = QtWidgets.QLabel('%s:' % _("Target")) self.target_gerber_label.setToolTip( _("Gerber object from which to substract\n" "the substractor Gerber object.") @@ -75,7 +75,7 @@ class ToolSub(FlatCAMTool): self.sub_gerber_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex())) self.sub_gerber_combo.setCurrentIndex(1) - self.sub_gerber_label = QtWidgets.QLabel(_("Substractor:")) + self.sub_gerber_label = QtWidgets.QLabel('%s:' % _("Substractor")) self.sub_gerber_label.setToolTip( _("Gerber object that will be substracted\n" "from the target Gerber object.") @@ -107,7 +107,7 @@ class ToolSub(FlatCAMTool): self.target_geo_combo.setRootModelIndex(self.app.collection.index(2, 0, QtCore.QModelIndex())) self.target_geo_combo.setCurrentIndex(1) - self.target_geo_label = QtWidgets.QLabel(_("Target:")) + self.target_geo_label = QtWidgets.QLabel('%s:' % _("Target")) self.target_geo_label.setToolTip( _("Geometry object from which to substract\n" "the substractor Geometry object.") @@ -121,7 +121,7 @@ class ToolSub(FlatCAMTool): self.sub_geo_combo.setRootModelIndex(self.app.collection.index(2, 0, QtCore.QModelIndex())) self.sub_geo_combo.setCurrentIndex(1) - self.sub_geo_label = QtWidgets.QLabel(_("Substractor:")) + self.sub_geo_label = QtWidgets.QLabel('%s:' % _("Substractor")) self.sub_geo_label.setToolTip( _("Geometry object that will be substracted\n" "from the target Geometry object.") diff --git a/flatcamTools/ToolTransform.py b/flatcamTools/ToolTransform.py index 27b3f6bc..0dc5d10e 100644 --- a/flatcamTools/ToolTransform.py +++ b/flatcamTools/ToolTransform.py @@ -65,7 +65,7 @@ class ToolTransform(FlatCAMTool): self.transform_lay.addLayout(form_layout) form_child = QtWidgets.QHBoxLayout() - self.rotate_label = QtWidgets.QLabel(_("Angle:")) + self.rotate_label = QtWidgets.QLabel('%s:' % _("Angle")) self.rotate_label.setToolTip( _("Angle for Rotation action, in degrees.\n" "Float number between -360 and 359.\n" @@ -104,7 +104,7 @@ class ToolTransform(FlatCAMTool): form1_child_1 = QtWidgets.QHBoxLayout() form1_child_2 = QtWidgets.QHBoxLayout() - self.skewx_label = QtWidgets.QLabel(_("Angle X:")) + self.skewx_label = QtWidgets.QLabel('%s:' % _("Skew_X angle")) self.skewx_label.setToolTip( _("Angle for Skew action, in degrees.\n" "Float number between -360 and 359.") @@ -122,7 +122,7 @@ class ToolTransform(FlatCAMTool): "the bounding box for all selected objects.")) self.skewx_button.setMinimumWidth(90) - self.skewy_label = QtWidgets.QLabel(_("Angle Y:")) + self.skewy_label = QtWidgets.QLabel('%s:' % _("Skew_Y angle")) self.skewy_label.setToolTip( _("Angle for Skew action, in degrees.\n" "Float number between -360 and 359.") @@ -161,9 +161,9 @@ class ToolTransform(FlatCAMTool): form2_child_1 = QtWidgets.QHBoxLayout() form2_child_2 = QtWidgets.QHBoxLayout() - self.scalex_label = QtWidgets.QLabel(_("Factor X:")) + self.scalex_label = QtWidgets.QLabel('%s:' % _("Scale_X factor")) self.scalex_label.setToolTip( - _("Factor for Scale action over X axis.") + _("Factor for scaling on X axis.") ) self.scalex_label.setMinimumWidth(70) self.scalex_entry = FCEntry() @@ -178,9 +178,9 @@ class ToolTransform(FlatCAMTool): "the Scale reference checkbox state.")) self.scalex_button.setMinimumWidth(90) - self.scaley_label = QtWidgets.QLabel(_("Factor Y:")) + self.scaley_label = QtWidgets.QLabel('%s:' % _("Scale_Y factor")) self.scaley_label.setToolTip( - _("Factor for Scale action over Y axis.") + _("Factor for scaling on Y axis.") ) self.scaley_label.setMinimumWidth(70) self.scaley_entry = FCEntry() @@ -200,12 +200,13 @@ class ToolTransform(FlatCAMTool): self.scale_link_cb.setText(_("Link")) self.scale_link_cb.setToolTip( _("Scale the selected object(s)\n" - "using the Scale Factor X for both axis.")) + "using the Scale_X factor for both axis.") + ) self.scale_link_cb.setMinimumWidth(70) self.scale_zero_ref_cb = FCCheckBox() self.scale_zero_ref_cb.set_value(True) - self.scale_zero_ref_cb.setText(_("Scale Reference")) + self.scale_zero_ref_cb.setText('%s' % _("Scale Reference")) self.scale_zero_ref_cb.setToolTip( _("Scale the selected object(s)\n" "using the origin reference when checked,\n" @@ -235,9 +236,9 @@ class ToolTransform(FlatCAMTool): form3_child_1 = QtWidgets.QHBoxLayout() form3_child_2 = QtWidgets.QHBoxLayout() - self.offx_label = QtWidgets.QLabel(_("Value X:")) + self.offx_label = QtWidgets.QLabel('%s:' % _("Offset_X val")) self.offx_label.setToolTip( - _("Value for Offset action on X axis.") + _("Distance to offset on X axis. In current units.") ) self.offx_label.setMinimumWidth(70) self.offx_entry = FCEntry() @@ -252,9 +253,9 @@ class ToolTransform(FlatCAMTool): "the bounding box for all selected objects.\n")) self.offx_button.setMinimumWidth(90) - self.offy_label = QtWidgets.QLabel(_("Value Y:")) + self.offy_label = QtWidgets.QLabel('%s:' % _("Offset_Y val")) self.offy_label.setToolTip( - _("Value for Offset action on Y axis.") + _("Distance to offset on Y axis. In current units.") ) self.offy_label.setMinimumWidth(70) self.offy_entry = FCEntry() @@ -309,7 +310,7 @@ class ToolTransform(FlatCAMTool): self.flip_ref_cb = FCCheckBox() self.flip_ref_cb.set_value(True) - self.flip_ref_cb.setText(_("Ref Pt")) + self.flip_ref_cb.setText('%s' % _("Mirror Reference")) self.flip_ref_cb.setToolTip( _("Flip the selected object(s)\n" "around the point in Point Entry Field.\n" @@ -322,7 +323,7 @@ class ToolTransform(FlatCAMTool): "Point Entry field and click Flip on X(Y)")) self.flip_ref_cb.setMinimumWidth(70) - self.flip_ref_label = QtWidgets.QLabel(_("Point:")) + self.flip_ref_label = QtWidgets.QLabel('%s:' % _(" Mirror Ref. Point")) self.flip_ref_label.setToolTip( _("Coordinates in format (x, y) used as reference for mirroring.\n" "The 'x' in (x, y) will be used when using Flip on X and\n"