CNC job general prefs

This commit is contained in:
David Robertson
2020-05-09 18:53:42 +01:00
parent cac97f585a
commit 17eaa6e8ad
3 changed files with 133 additions and 417 deletions

View File

@@ -6,19 +6,25 @@ from flatcamGUI.preferences.cncjob.CNCJobAdvOptPrefGroupUI import CNCJobAdvOptPr
from flatcamGUI.preferences.cncjob.CNCJobOptPrefGroupUI import CNCJobOptPrefGroupUI
from flatcamGUI.preferences.cncjob.CNCJobGenPrefGroupUI import CNCJobGenPrefGroupUI
import gettext
import FlatCAMTranslation as fcTranslate
import builtins
fcTranslate.apply_language('strings')
if '_' not in builtins.__dict__:
_ = gettext.gettext
class CNCJobPreferencesUI(PreferencesSectionUI):
def __init__(self, decimals, **kwargs):
self.decimals = decimals
self.cncjob_gen_group = CNCJobGenPrefGroupUI(decimals=self.decimals)
self.cncjob_opt_group = CNCJobOptPrefGroupUI(decimals=self.decimals)
self.cncjob_adv_opt_group = CNCJobAdvOptPrefGroupUI(decimals=self.decimals)
super().__init__(**kwargs)
def build_groups(self) -> [OptionsGroupUI]:
return [
self.cncjob_gen_group,
CNCJobGenPrefGroupUI(decimals=self.decimals),
self.cncjob_opt_group,
self.cncjob_adv_opt_group
]