- fixed the Punch Gerber Tool bug that did not allowed the projects to be loaded or to create a new project. Fixed issue #456

- in Tool Subtract added an option to delete the source objects after a successful operation. Fixed issue #455
This commit is contained in:
Marius Stanciu
2020-10-30 12:04:35 +02:00
committed by Marius
parent a7c03248d6
commit 46900d795d
4 changed files with 49 additions and 17 deletions

View File

@@ -1425,6 +1425,8 @@ class ToolsDB2(QtWidgets.QWidget):
'''
self.db_tool_dict = {}
self.old_color = QtGui.QColor('black')
# ##############################################################################
# ##############################################################################
# TOOLS DATABASE UI
@@ -1719,6 +1721,12 @@ class ToolsDB2(QtWidgets.QWidget):
self.ui_connect()
def setup_db_ui(self):
# set the old color for the Tools Database Tab
for idx in range(self.app.ui.plot_tab_area.count()):
if self.app.ui.plot_tab_area.tabText(idx) == _("Tools Database"):
self.old_color = self.app.ui.plot_tab_area.tabBar.tabTextColor(idx)
filename = self.app.tools_database_path()
# load the database tools from the file
@@ -2155,7 +2163,7 @@ class ToolsDB2(QtWidgets.QWidget):
# Preferences save, update the color of the Tools DB Tab text
for idx in range(self.app_ui.plot_tab_area.count()):
if self.app_ui.plot_tab_area.tabText(idx) == _("Tools Database"):
self.app_ui.plot_tab_area.tabBar.setTabTextColor(idx, QtGui.QColor('black'))
self.app_ui.plot_tab_area.tabBar.setTabTextColor(idx, self.old_color)
self.ui.save_db_btn.setStyleSheet("")
# clean the dictionary and leave only keys of interest