#include <MultiPeakFitTool.h>
Signals | |
void | statusText (const QString &) |
void | statusText (const QString &) |
Public Member Functions | |
MultiPeakFitTool (Graph *graph, ApplicationWindow *app, MultiPeakFit::PeakProfile profile, int num_peaks, const QObject *status_target, const char *status_slot) | |
MultiPeakFitTool (Graph *graph, ApplicationWindow *app, MultiPeakFit::PeakProfile profile, int num_peaks, const QObject *status_target, const char *status_slot) | |
virtual int | rtti () const |
virtual int | rtti () const |
virtual | ~MultiPeakFitTool () |
virtual | ~MultiPeakFitTool () |
Protected Slots | |
void | selectPeak (QwtPlotCurve *curve, int point_index) |
void | selectPeak (QwtPlotCurve *curve, int point_index) |
Private Member Functions | |
void | finalize () |
void | finalize () |
Private Attributes | |
QwtPlotCurve * | d_curve |
MultiPeakFit * | d_fit |
QList< QwtPlotMarker * > | d_lines |
int | d_num_peaks |
DataPickerTool * | d_picker_tool |
MultiPeakFit::PeakProfile | d_profile |
int | d_selected_peaks |
Plot tool for doing multi-peak fitting.
This class can be seen as a user-interface wrapper around MultiPeakFit, providing functionality for visually selecting estimated peak positions and finally executing the fit.
Maybe some other parts of the multi-peak fitting process (namely, specifying the number of peaks and optionally the peak profile) could be moved here as well.
MultiPeakFitTool::MultiPeakFitTool | ( | Graph * | graph, | |
ApplicationWindow * | app, | |||
MultiPeakFit::PeakProfile | profile, | |||
int | num_peaks, | |||
const QObject * | status_target, | |||
const char * | status_slot | |||
) |
References cursor_xpm, d_curve, d_fit, PlotToolInterface::d_graph, d_num_peaks, d_picker_tool, d_profile, d_selected_peaks, DataPickerTool::Display, MultiPeakFit::enablePeakCurves(), ApplicationWindow::fitPoints, Fit::generateFunction(), ApplicationWindow::generatePeakCurves, ApplicationWindow::generateUniformFitPoints, ApplicationWindow::peakCurvesColor, selectPeak(), MultiPeakFit::setPeakCurvesColor(), and statusText().
MultiPeakFitTool::~MultiPeakFitTool | ( | ) | [virtual] |
References d_fit, and d_picker_tool.
MultiPeakFitTool::MultiPeakFitTool | ( | Graph * | graph, | |
ApplicationWindow * | app, | |||
MultiPeakFit::PeakProfile | profile, | |||
int | num_peaks, | |||
const QObject * | status_target, | |||
const char * | status_slot | |||
) |
virtual MultiPeakFitTool::~MultiPeakFitTool | ( | ) | [virtual] |
void MultiPeakFitTool::finalize | ( | ) | [private] |
void MultiPeakFitTool::finalize | ( | ) | [private] |
References Graph::activeTool(), d_curve, d_fit, PlotToolInterface::d_graph, d_num_peaks, d_picker_tool, d_profile, d_selected_peaks, Filter::dataSize(), Fit::fit(), Fit::initialGuess(), MultiPeakFit::Lorentz, Graph::removeMarker(), PlotToolInterface::rtti(), PlotToolInterface::Rtti_RangeSelector, Filter::setDataFromCurve(), Fit::setInitialGuess(), Filter::x(), and Filter::y().
Referenced by selectPeak().
virtual int MultiPeakFitTool::rtti | ( | ) | const [inline, virtual] |
Reimplemented from PlotToolInterface.
References PlotToolInterface::Rtti_MultiPeakFitTool.
virtual int MultiPeakFitTool::rtti | ( | ) | const [inline, virtual] |
Reimplemented from PlotToolInterface.
References PlotToolInterface::Rtti_MultiPeakFitTool.
void MultiPeakFitTool::selectPeak | ( | QwtPlotCurve * | curve, | |
int | point_index | |||
) | [protected, slot] |
void MultiPeakFitTool::selectPeak | ( | QwtPlotCurve * | curve, | |
int | point_index | |||
) | [protected, slot] |
References d_curve, d_fit, PlotToolInterface::d_graph, d_num_peaks, d_selected_peaks, finalize(), Graph::insertMarker(), Fit::setInitialGuess(), and statusText().
Referenced by MultiPeakFitTool().
void MultiPeakFitTool::statusText | ( | const QString & | ) | [signal] |
Emitted whenever a new message should be presented to the user.
You don't have to connect to this signal if you alreay specified a reciever during initialization.
void MultiPeakFitTool::statusText | ( | const QString & | ) | [signal] |
Emitted whenever a new message should be presented to the user.
You don't have to connect to this signal if you alreay specified a reciever during initialization.
Referenced by MultiPeakFitTool(), and selectPeak().
QwtPlotCurve * MultiPeakFitTool::d_curve [private] |
Referenced by finalize(), MultiPeakFitTool(), and selectPeak().
MultiPeakFit * MultiPeakFitTool::d_fit [private] |
Referenced by finalize(), MultiPeakFitTool(), selectPeak(), and ~MultiPeakFitTool().
QList<QwtPlotMarker *> MultiPeakFitTool::d_lines [private] |
int MultiPeakFitTool::d_num_peaks [private] |
Referenced by finalize(), MultiPeakFitTool(), and selectPeak().
DataPickerTool * MultiPeakFitTool::d_picker_tool [private] |
Referenced by finalize(), MultiPeakFitTool(), and ~MultiPeakFitTool().
Referenced by finalize(), and MultiPeakFitTool().
int MultiPeakFitTool::d_selected_peaks [private] |
Referenced by finalize(), MultiPeakFitTool(), and selectPeak().