- removed the 'machinist setting' and allow all over the app the usages of both negative and positive values (where it is the case)

This commit is contained in:
Marius Stanciu
2021-01-02 16:53:50 +02:00
committed by Marius Stanciu
parent 1a53dd80b4
commit f5751d3f59
67 changed files with 186 additions and 740 deletions

View File

@@ -3,7 +3,6 @@ from PyQt5.QtCore import QSettings
from appGUI.GUIElements import FCDoubleSpinner, FCCheckBox, FCComboBox, RadioSet, OptionalInputSection, FCSpinner, \
FCColorEntry, FCLabel
from appGUI.preferences import settings
from appGUI.preferences.OptionsGroupUI import OptionsGroupUI
import gettext
@@ -14,12 +13,6 @@ 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 GeneralAPPSetGroupUI(OptionsGroupUI):
def __init__(self, decimals=4, parent=None):
@@ -242,7 +235,7 @@ class GeneralAPPSetGroupUI(OptionsGroupUI):
qsettings = QSettings("Open Source", "FlatCAM")
if qsettings.contains("textbox_font_size"):
self.textbox_font_size_spinner.set_value(settings.value('textbox_font_size', type=int))
self.textbox_font_size_spinner.set_value(qsettings.value('textbox_font_size', type=int))
else:
self.textbox_font_size_spinner.set_value(10)
@@ -261,7 +254,7 @@ class GeneralAPPSetGroupUI(OptionsGroupUI):
qsettings = QSettings("Open Source", "FlatCAM")
if qsettings.contains("hud_font_size"):
self.hud_font_size_spinner.set_value(settings.value('hud_font_size', type=int))
self.hud_font_size_spinner.set_value(qsettings.value('hud_font_size', type=int))
else:
self.hud_font_size_spinner.set_value(8)
@@ -411,18 +404,6 @@ class GeneralAPPSetGroupUI(OptionsGroupUI):
grid0.addWidget(self.toggle_tooltips_cb, 33, 0, 1, 2)
# Machinist settings that allow unsafe settings
self.machinist_cb = FCCheckBox(_("Allow Machinist Unsafe Settings"))
self.machinist_cb.setToolTip(
_("If checked, some of the application settings will be allowed\n"
"to have values that are usually unsafe to use.\n"
"Like Z travel negative values or Z Cut positive values.\n"
"It will applied at the next application start.\n"
"<<WARNING>>: Don't change this unless you know what you are doing !!!")
)
grid0.addWidget(self.machinist_cb, 34, 0, 1, 2)
# Bookmarks Limit in the Help Menu
self.bm_limit_spinner = FCSpinner()
self.bm_limit_spinner.set_range(0, 9999)

View File

@@ -15,12 +15,6 @@ 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 GeneralAppPrefGroupUI(OptionsGroupUI):
def __init__(self, decimals=4, parent=None):

View File

@@ -1,6 +1,5 @@
from PyQt5 import QtCore
from appGUI.GUIElements import OptionalInputSection
from appGUI.preferences import settings
from appGUI.preferences.OptionUI import *
from appGUI.preferences.OptionsGroupUI import OptionsGroupUI2
@@ -268,15 +267,6 @@ class GeneralAppSettingsGroupUI(OptionsGroupUI2):
label_tooltip="Check this box if you want to have toolTips displayed\n"
"when hovering with mouse over items throughout the App."
),
CheckboxOptionUI(
option="global_machinist_setting",
label_text="Allow Machinist Unsafe Settings",
label_tooltip="If checked, some of the application settings will be allowed\n"
"to have values that are usually unsafe to use.\n"
"Like Z travel negative values or Z Cut positive values.\n"
"It will applied at the next application start.\n"
"<<WARNING>>: Don't change this unless you know what you are doing !!!"
),
SpinnerOptionUI(
option="global_bookmarks_limit",
label_text="Bookmarks limit",

View File

@@ -12,12 +12,6 @@ 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 GeneralGUIPrefGroupUI(OptionsGroupUI):
def __init__(self, decimals=4, parent=None):

View File

@@ -1,5 +1,4 @@
from PyQt5 import QtWidgets
from PyQt5.QtCore import QSettings
from appGUI.preferences.general.GeneralAppPrefGroupUI import GeneralAppPrefGroupUI
from appGUI.preferences.general.GeneralAPPSetGroupUI import GeneralAPPSetGroupUI
@@ -13,12 +12,6 @@ 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 GeneralPreferencesUI(QtWidgets.QWidget):
def __init__(self, decimals, parent=None):