- added as ToolTip for the the Preprocessor combobox items, the actual name of the items
This commit is contained in:
parent
6edd7f051a
commit
5e9455991f
|
@ -11,6 +11,7 @@ CHANGELOG for FlatCAM beta
|
|||
|
||||
- Tool Drilling - working on the UI
|
||||
- Tool Drilling - added more tool parameters; laying the ground for adding "Drilling Slots" feature
|
||||
- added as ToolTip for the the Preprocessor combobox items, the actual name of the items
|
||||
|
||||
7.07.2020
|
||||
|
||||
|
|
|
@ -399,9 +399,15 @@ class GeometryObject(FlatCAMObj, Geometry):
|
|||
self.units = self.app.defaults['units'].upper()
|
||||
self.units_found = self.app.defaults['units']
|
||||
|
||||
# make sure the preprocessor combobox is clear
|
||||
self.ui.pp_geometry_name_cb.clear()
|
||||
# populate preprocessor names in the combobox
|
||||
for name in list(self.app.preprocessors.keys()):
|
||||
self.ui.pp_geometry_name_cb.addItem(name)
|
||||
# add tooltips
|
||||
for it in range(self.ui.pp_geometry_name_cb.count()):
|
||||
self.ui.pp_geometry_name_cb.setItemData(
|
||||
it, self.ui.pp_geometry_name_cb.itemText(it), QtCore.Qt.ToolTipRole)
|
||||
|
||||
self.form_fields.update({
|
||||
"plot": self.ui.plot_cb,
|
||||
|
|
|
@ -242,12 +242,18 @@ class ToolDrilling(AppTool, Excellon):
|
|||
except Exception:
|
||||
pass
|
||||
|
||||
# reset the Excellon preprocessor combo
|
||||
self.t_ui.pp_excellon_name_cb.clear()
|
||||
# populate Excellon preprocessor combobox list
|
||||
for name in list(self.app.preprocessors.keys()):
|
||||
# the HPGL preprocessor is only for Geometry not for Excellon job therefore don't add it
|
||||
if name == 'hpgl':
|
||||
continue
|
||||
self.t_ui.pp_excellon_name_cb.addItem(name)
|
||||
# add tooltips
|
||||
for it in range(self.t_ui.pp_excellon_name_cb.count()):
|
||||
self.t_ui.pp_excellon_name_cb.setItemData(
|
||||
it, self.t_ui.pp_excellon_name_cb.itemText(it), QtCore.Qt.ToolTipRole)
|
||||
|
||||
# update the changes in UI depending on the selected preprocessor in Preferences
|
||||
# after this moment all the changes in the Posprocessor combo will be handled by the activated signal of the
|
||||
|
|
14
app_Main.py
14
app_Main.py
|
@ -561,6 +561,7 @@ class App(QtCore.QObject):
|
|||
# and now put back the ordered dict with 'default' key first
|
||||
self.preprocessors = new_ppp_dict
|
||||
|
||||
# populate the Preprocessor ComboBoxes in the PREFERENCES
|
||||
for name in list(self.preprocessors.keys()):
|
||||
# 'Paste' preprocessors are to be used only in the Solder Paste Dispensing Tool
|
||||
if name.partition('_')[0] == 'Paste':
|
||||
|
@ -574,6 +575,19 @@ class App(QtCore.QObject):
|
|||
|
||||
self.ui.excellon_defaults_form.excellon_opt_group.pp_excellon_name_cb.addItem(name)
|
||||
|
||||
# add ToolTips for the Preprocessor ComboBoxes in Preferences
|
||||
for it in range(self.ui.tools_defaults_form.tools_solderpaste_group.pp_combo.count()):
|
||||
self.ui.tools_defaults_form.tools_solderpaste_group.pp_combo.setItemData(
|
||||
it, self.ui.tools_defaults_form.tools_solderpaste_group.pp_combo.itemText(it), QtCore.Qt.ToolTipRole)
|
||||
for it in range(self.ui.geometry_defaults_form.geometry_opt_group.pp_geometry_name_cb.count()):
|
||||
self.ui.geometry_defaults_form.geometry_opt_group.pp_geometry_name_cb.setItemData(
|
||||
it, self.ui.geometry_defaults_form.geometry_opt_group.pp_geometry_name_cb.itemText(it),
|
||||
QtCore.Qt.ToolTipRole)
|
||||
for it in range(self.ui.excellon_defaults_form.excellon_opt_group.pp_excellon_name_cb.count()):
|
||||
self.ui.excellon_defaults_form.excellon_opt_group.pp_excellon_name_cb.setItemData(
|
||||
it, self.ui.excellon_defaults_form.excellon_opt_group.pp_excellon_name_cb.itemText(it),
|
||||
QtCore.Qt.ToolTipRole)
|
||||
|
||||
# ###########################################################################################################
|
||||
# ##################################### UPDATE PREFERENCES GUI FORMS ########################################
|
||||
# ###########################################################################################################
|
||||
|
|
Loading…
Reference in New Issue