mvp for script runner
This commit is contained in:
@@ -985,13 +985,21 @@ class NMRMainWindow(QtWidgets.QMainWindow, Ui_BaseWindow):
|
||||
@QtCore.pyqtSlot(name='on_actionFunction_editor_triggered')
|
||||
def edit_models(self):
|
||||
if self.editor is None:
|
||||
from ..lib.usermodeleditor import QUsermodelEditor
|
||||
from ..editors.usermodeleditor import QUsermodelEditor
|
||||
|
||||
self.editor = QUsermodelEditor(config_paths() / 'usermodels.py', parent=self)
|
||||
self.editor.modelsChanged.connect(lambda: self.fit_dialog.read_and_load_functions())
|
||||
self.editor.setWindowModality(QtCore.Qt.WindowModality.ApplicationModal)
|
||||
self.editor.show()
|
||||
|
||||
@QtCore.pyqtSlot(name='on_actionUse_script_triggered')
|
||||
def open_editor(self):
|
||||
from ..editors.script_editor import QEditor
|
||||
|
||||
editor = QEditor(self.path, parent=self)
|
||||
editor.runSignal.connect(self.management.run_script)
|
||||
editor.show()
|
||||
|
||||
@QtCore.pyqtSlot(list, bool)
|
||||
def extend_fit(self, sets: list, only_subplots: bool):
|
||||
if only_subplots:
|
||||
|
||||
Reference in New Issue
Block a user