- renamed classes to have shorter names and grouped
This commit is contained in:
42
AppGUI/preferences/tools/ToolsSubPrefGroupUI.py
Normal file
42
AppGUI/preferences/tools/ToolsSubPrefGroupUI.py
Normal file
@@ -0,0 +1,42 @@
|
||||
from PyQt5 import QtWidgets
|
||||
from PyQt5.QtCore import QSettings
|
||||
|
||||
from AppGUI.GUIElements import FCCheckBox
|
||||
from AppGUI.preferences.OptionsGroupUI import OptionsGroupUI
|
||||
|
||||
import gettext
|
||||
import AppTranslation as fcTranslate
|
||||
import builtins
|
||||
|
||||
fcTranslate.apply_language('strings')
|
||||
if '_' not in builtins.__dict__:
|
||||
_ = gettext.gettext
|
||||
|
||||
settings = QSettings("Open Source", "FlatCAM")
|
||||
if settings.contains("machinist"):
|
||||
machinist_setting = settings.value('machinist', type=int)
|
||||
else:
|
||||
machinist_setting = 0
|
||||
|
||||
|
||||
class ToolsSubPrefGroupUI(OptionsGroupUI):
|
||||
def __init__(self, decimals=4, parent=None):
|
||||
|
||||
super(ToolsSubPrefGroupUI, self).__init__(self, parent=parent)
|
||||
|
||||
self.setTitle(str(_("Substractor Tool Options")))
|
||||
self.decimals = decimals
|
||||
|
||||
# ## Subtractor Tool Parameters
|
||||
self.sublabel = QtWidgets.QLabel("<b>%s:</b>" % _("Parameters"))
|
||||
self.sublabel.setToolTip(
|
||||
_("A tool to substract one Gerber or Geometry object\n"
|
||||
"from another of the same type.")
|
||||
)
|
||||
self.layout.addWidget(self.sublabel)
|
||||
|
||||
self.close_paths_cb = FCCheckBox(_("Close paths"))
|
||||
self.close_paths_cb.setToolTip(_("Checking this will close the paths cut by the Geometry substractor object."))
|
||||
self.layout.addWidget(self.close_paths_cb)
|
||||
|
||||
self.layout.addStretch()
|
||||
Reference in New Issue
Block a user