plot sub-functions; fixes #282

This commit is contained in:
Dominik Demuth
2024-07-16 18:58:31 +02:00
parent a8fcd658d9
commit e0c287d8a9
3 changed files with 26 additions and 11 deletions

View File

@@ -991,15 +991,19 @@ class NMRMainWindow(QtWidgets.QMainWindow, Ui_BaseWindow):
self.editor.setWindowModality(QtCore.Qt.WindowModality.ApplicationModal)
self.editor.show()
@QtCore.pyqtSlot(list)
def extend_fit(self, sets: list):
@QtCore.pyqtSlot(list, bool)
def extend_fit(self, sets: list, only_subplots: bool):
if only_subplots:
self.management.extend_fits(sets, None, True)
return
w = FitExtension(self)
res = w.exec()
if res:
p = w.values
spacefunc = geomspace if p[3] else linspace
x = spacefunc(p[0], p[1], num=p[2])
self.management.extend_fits(sets, x)
self.management.extend_fits(sets, x, False)
@QtCore.pyqtSlot(name='on_action_create_fit_function_triggered')
def open_fitmodel_wizard(self):