Commit 61c1e689 authored by payno's avatar payno
Browse files

[XASObjectViewer] add baseline plot optional regarding the silx version

parent bfefad92
Pipeline #13544 passed with stage
in 4 minutes and 43 seconds
......@@ -72,6 +72,9 @@ def process_spectr_autobk(spectrum, configuration, overwrite=True,
if opt_name in _conf:
opts[opt_name] = _conf[opt_name]
# print(opts)
# print(opts)
if _DEBUG is True:
assert isinstance(spectrum, Group)
if overwrite:
......
......@@ -341,16 +341,20 @@ class SpectrumViewer(qt.QMainWindow):
for res in curves:
if res is not None and res.x is not None:
if isinstance(res, _CurveOperation):
curve = self._plot.addCurve(x=res.x,
y=res.y,
legend=res.legend,
yaxis=res.yaxis,
linestyle=res.linestyle,
symbol=res.symbol,
color=res.color,
ylabel=res.ylabel,
baseline=res.baseline,
)
kwargs = {
'x': res.x,
'y': res.y,
'legend': res.legend,
'yaxis': res.yaxis,
'linestyle': res.linestyle,
'symbol': res.symbol,
'color': res.color,
'ylabel': res.ylabel,
}
if silx_plot_has_baseline_feature:
kwargs['baseline'] = res.baseline,
curve = self._plot.addCurve(**kwargs)
curve = self._plot.getCurve(curve)
curve.setAlpha(res.alpha)
elif isinstance(res, _XMarkerOperation):
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment