dev #285

Merged
dominik merged 20 commits from dev into master 2024-09-11 15:33:00 +00:00
2 changed files with 11 additions and 5 deletions
Showing only changes of commit 7b61c1244d - Show all commits

View File

@ -219,8 +219,14 @@ class QFitDialog(QtWidgets.QWidget, Ui_FitDialog):
if len(self.models) == 1:
self.model_frame.hide()
def _prepare(self, model: list, function_use: list = None,
parameter: dict = None, add_idx: bool = False, cnt: int = 0) -> tuple[dict, int]:
def _prepare(
self,
model: list,
function_use: list = None,
parameter: dict = None,
add_idx: bool = False,
cnt: int = 0,
) -> tuple[dict, int]:
if parameter is None:
parameter = {
@ -263,7 +269,7 @@ class QFitDialog(QtWidgets.QWidget, Ui_FitDialog):
if f['children']:
# recurse for children
_, cnt = self._prepare(f['children'], parameter=parameter, add_idx=add_idx, cnt=cnt)
_, cnt = self._prepare(f['children'], parameter=parameter, function_use=function_use, add_idx=add_idx, cnt=cnt)
return parameter, cnt
@ -495,7 +501,7 @@ class QFitDialog(QtWidgets.QWidget, Ui_FitDialog):
if model_p['active']:
cnt += self.param_widgets[model_p['cnt']].set_parameter(fit_id, param[cnt:])
if model_p['children']:
cnt += self.set_parameter_iter(fit_id, param, model_p['children'], cnt=cnt)
cnt = self.set_parameter_iter(fit_id, param, model_p['children'], cnt=cnt)
return cnt

View File

@ -12,7 +12,7 @@ from nmreval.lib.logger import logger
from nmreval.io.sessionwriter import NMRWriter
from .management import UpperManagement
from ..lib.logger import ConsoleDock, QTextHandler
from ..lib.logger import QTextHandler
from ..Qt import QtGui, QtPrintSupport
from ..data.shift_graphs import QShift
from ..data.signaledit import QPreviewDialog, QBaselineDialog