- added icons to some of the push buttons

This commit is contained in:
Marius Stanciu 2020-07-15 02:23:45 +03:00 committed by Marius
parent e67e676e45
commit 66adab95ca
17 changed files with 43 additions and 4 deletions

View File

@ -7,6 +7,10 @@ CHANGELOG for FlatCAM beta
=================================================
15.07.2020
- added icons to some of the push buttons
14.07.2020
- Drilling Tool - now there is an Excellon preference that control the autoload of tools from the Tools Database

View File

@ -2054,6 +2054,7 @@ class ToolsDB2UI:
self.buttons_frame.show()
self.add_entry_btn = FCButton(_("Add Tool in DB"))
self.add_entry_btn.setIcon(QtGui.QIcon(self.app.resource_location + '/plus16.png'))
self.add_entry_btn.setToolTip(
_("Add a new tool in the Tools Database.\n"
"It will be used in the Geometry UI.\n"
@ -2070,24 +2071,28 @@ class ToolsDB2UI:
# self.buttons_box.addWidget(add_fct_entry_btn)
self.remove_entry_btn = FCButton(_("Delete Tool from DB"))
self.remove_entry_btn.setIcon(QtGui.QIcon(self.app.resource_location + '/trash16.png'))
self.remove_entry_btn.setToolTip(
_("Remove a selection of tools in the Tools Database.")
)
self.buttons_box.addWidget(self.remove_entry_btn)
self.export_db_btn = FCButton(_("Export DB"))
self.export_db_btn.setIcon(QtGui.QIcon(self.app.resource_location + '/export.png'))
self.export_db_btn.setToolTip(
_("Save the Tools Database to a custom text file.")
)
self.buttons_box.addWidget(self.export_db_btn)
self.import_db_btn = FCButton(_("Import DB"))
self.import_db_btn.setIcon(QtGui.QIcon(self.app.resource_location + '/import.png'))
self.import_db_btn.setToolTip(
_("Load the Tools Database information's from a custom text file.")
)
self.buttons_box.addWidget(self.import_db_btn)
self.save_db_btn = FCButton(_("Save DB"))
self.save_db_btn.setIcon(QtGui.QIcon(self.app.resource_location + '/save_as.png'))
self.save_db_btn.setToolTip(
_("Save the Tools Database information's.")
)

View File

@ -936,7 +936,7 @@ class MainGUI(QtWidgets.QMainWindow):
self.isolation_btn = self.toolbartools.addAction(
QtGui.QIcon(self.app.resource_location + '/iso_16.png'), _("Isolation Tool"))
self.drill_btn = self.toolbartools.addAction(
QtGui.QIcon(self.app.resource_location + '/drill16.png'), _("Drilling Tool"))
QtGui.QIcon(self.app.resource_location + '/drilling_tool32.png'), _("Drilling Tool"))
self.toolbartools.addSeparator()
self.panelize_btn = self.toolbartools.addAction(
@ -1385,8 +1385,8 @@ class MainGUI(QtWidgets.QMainWindow):
self.pref_tab_bottom_layout_1.setAlignment(QtCore.Qt.AlignLeft | QtCore.Qt.AlignVCenter)
self.pref_tab_bottom_layout.addLayout(self.pref_tab_bottom_layout_1)
self.pref_defaults_button = QtWidgets.QPushButton()
self.pref_defaults_button.setText(_("Restore Defaults"))
self.pref_defaults_button = FCButton(_("Restore Defaults"))
self.pref_defaults_button.setIcon(QtGui.QIcon(self.app.resource_location + '/restore32.png'))
self.pref_defaults_button.setMinimumWidth(130)
self.pref_defaults_button.setToolTip(
_("Restore the entire set of default values\n"
@ -1395,6 +1395,7 @@ class MainGUI(QtWidgets.QMainWindow):
self.pref_open_button = QtWidgets.QPushButton()
self.pref_open_button.setText(_("Open Pref Folder"))
self.pref_open_button.setIcon(QtGui.QIcon(self.app.resource_location + '/pref.png'))
self.pref_open_button.setMinimumWidth(130)
self.pref_open_button.setToolTip(
_("Open the folder where FlatCAM save the preferences files."))
@ -1402,6 +1403,7 @@ class MainGUI(QtWidgets.QMainWindow):
# Clear Settings
self.clear_btn = FCButton('%s' % _('Clear GUI Settings'))
self.clear_btn.setIcon(QtGui.QIcon(self.app.resource_location + '/trash32.png'))
self.clear_btn.setMinimumWidth(130)
self.clear_btn.setToolTip(
@ -1416,6 +1418,7 @@ class MainGUI(QtWidgets.QMainWindow):
self.pref_tab_bottom_layout.addLayout(self.pref_tab_bottom_layout_2)
self.pref_apply_button = FCButton()
self.pref_apply_button.setIcon(QtGui.QIcon(self.app.resource_location + '/apply32.png'))
self.pref_apply_button.setText(_("Apply"))
self.pref_apply_button.setMinimumWidth(130)
self.pref_apply_button.setToolTip(
@ -1423,6 +1426,7 @@ class MainGUI(QtWidgets.QMainWindow):
self.pref_tab_bottom_layout_2.addWidget(self.pref_apply_button)
self.pref_save_button = QtWidgets.QPushButton()
self.pref_save_button.setIcon(QtGui.QIcon(self.app.resource_location + '/save_as.png'))
self.pref_save_button.setText(_("Save"))
self.pref_save_button.setMinimumWidth(130)
self.pref_save_button.setToolTip(
@ -2087,7 +2091,7 @@ class MainGUI(QtWidgets.QMainWindow):
self.isolation_btn = self.toolbartools.addAction(
QtGui.QIcon(self.app.resource_location + '/iso_16.png'), _("Isolation Tool"))
self.drill_btn = self.toolbartools.addAction(
QtGui.QIcon(self.app.resource_location + '/drill16.png'), _("Drilling Tool"))
QtGui.QIcon(self.app.resource_location + '/drilling_tool32.png'), _("Drilling Tool"))
self.toolbartools.addSeparator()
self.panelize_btn = self.toolbartools.addAction(

View File

@ -150,6 +150,7 @@ class ObjectUI(QtWidgets.QWidget):
self.common_grid.addWidget(self.offset_button, 4, 1)
self.transformations_button = QtWidgets.QPushButton(_('Transformations'))
self.transformations_button.setIcon(QtGui.QIcon(self.app.resource_location + '/transform.png'))
self.transformations_button.setToolTip(
_("Geometrical transformations of the current object.")
)
@ -311,6 +312,7 @@ class GerberObjectUI(ObjectUI):
# Editor
self.editor_button = QtWidgets.QPushButton(_('Gerber Editor'))
self.editor_button.setIcon(QtGui.QIcon(self.app.resource_location + '/edit_file32.png'))
self.editor_button.setToolTip(
_("Edit an Gerber object.")
)
@ -341,6 +343,7 @@ class GerberObjectUI(ObjectUI):
# Isolation Tool - will create isolation paths around the copper features
self.iso_button = QtWidgets.QPushButton(_('Isolation Routing'))
# self.iso_button.setIcon(QtGui.QIcon(self.app.resource_location + '/iso_16.png'))
self.iso_button.setToolTip(
_("Create a Geometry object with\n"
"toolpaths to cut around polygons.")
@ -355,6 +358,7 @@ class GerberObjectUI(ObjectUI):
# ## Clear non-copper regions
self.generate_ncc_button = QtWidgets.QPushButton(_('NCC Tool'))
self.generate_ncc_button.setIcon(QtGui.QIcon(self.app.resource_location + '/eraser26.png'))
self.generate_ncc_button.setToolTip(
_("Create the Geometry Object\n"
"for non-copper routing.")
@ -369,6 +373,7 @@ class GerberObjectUI(ObjectUI):
# ## Board cutout
self.generate_cutout_button = QtWidgets.QPushButton(_('Cutout Tool'))
self.generate_cutout_button.setIcon(QtGui.QIcon(self.app.resource_location + '/cut32_bis.png'))
self.generate_cutout_button.setToolTip(
_("Generate the geometry for\n"
"the board cutout.")
@ -615,6 +620,8 @@ class ExcellonObjectUI(ObjectUI):
# Editor
self.editor_button = QtWidgets.QPushButton(_('Excellon Editor'))
self.editor_button.setIcon(QtGui.QIcon(self.app.resource_location + '/edit_file32.png'))
self.editor_button.setToolTip(
_("Edit an Excellon object.")
)
@ -645,6 +652,7 @@ class ExcellonObjectUI(ObjectUI):
# Drilling Tool - will create GCode for drill holes
self.drill_button = QtWidgets.QPushButton(_('Drilling Tool'))
self.drill_button.setIcon(QtGui.QIcon(self.app.resource_location + '/drilling_tool32.png'))
self.drill_button.setToolTip(
_("Generate GCode out of drill holes in an Excellon object.")
)
@ -658,6 +666,7 @@ class ExcellonObjectUI(ObjectUI):
# Milling Tool - will create GCode for slot holes
self.milling_button = QtWidgets.QPushButton(_('Milling Tool'))
self.milling_button.setIcon(QtGui.QIcon(self.app.resource_location + '/milling_tool32.png'))
self.milling_button.setToolTip(
_("Generate GCode out of slot holes in an Excellon object.")
)
@ -914,6 +923,21 @@ class GeometryObjectUI(ObjectUI):
# self.geo_tools_table.setSortingEnabled(False)
# self.geo_tools_table.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows)
# Editor
self.editor_button = QtWidgets.QPushButton(_('Geometry Editor'))
self.editor_button.setIcon(QtGui.QIcon(self.app.resource_location + '/edit_file32.png'))
self.editor_button.setToolTip(
_("Edit an Geometry object.")
)
self.editor_button.setStyleSheet("""
QPushButton
{
font-weight: bold;
}
""")
grid0.addWidget(self.editor_button, 3, 0, 1, 2)
# Tool Offset
grid1 = QtWidgets.QGridLayout()
self.geo_table_box.addLayout(grid1)

View File

@ -872,6 +872,7 @@ class PreferencesUIManager:
# restore the default stylesheet by setting a blank one
self.ui.pref_apply_button.setStyleSheet("")
self.ui.pref_apply_button.setIcon(QtGui.QIcon(self.ui.app.resource_location + '/apply32.png'))
self.inform.emit('%s' % _("Preferences applied."))
@ -1096,6 +1097,7 @@ class PreferencesUIManager:
self.ui.plot_tab_area.tabBar.setTabTextColor(idx, QtGui.QColor('red'))
self.ui.pref_apply_button.setStyleSheet("QPushButton {color: red;}")
self.ui.pref_apply_button.setIcon(QtGui.QIcon(self.ui.app.resource_location + '/apply_red32.png'))
self.preferences_changed_flag = True

Binary file not shown.

After

Width:  |  Height:  |  Size: 444 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 543 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 543 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 543 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 793 B

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 932 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 736 B

After

Width:  |  Height:  |  Size: 854 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 836 B