BornAgain  1.19.79
Simulate and fit neutron and x-ray scattering at grazing incidence
FitComparisonViewController.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file GUI/View/PlotComparison/FitComparisonViewController.h
6 //! @brief Defines classes DiffItemController, FitComparison1DViewController
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2018
11 //! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
15 #ifndef BORNAGAIN_GUI_VIEW_PLOTCOMPARISON_FITCOMPARISONVIEWCONTROLLER_H
16 #define BORNAGAIN_GUI_VIEW_PLOTCOMPARISON_FITCOMPARISONVIEWCONTROLLER_H
17 
18 #include <QObject>
19 
20 class DataItem;
21 class Data1DViewItem;
22 class JobItem;
23 class PropertyRepeater;
24 class SessionModel;
25 
26 class DiffItemController : public QObject {
27 public:
28  DiffItemController(const QString& data_type, QObject* parent);
29  ~DiffItemController() override;
31  void setJobItem(JobItem* job_item);
33  void updateDiffData();
34  DataItem* diffItem() { return m_diff_item; }
35  void subscribe();
36  void unsubscribe();
37 
38 private:
42 };
43 
44 class FitComparison1DViewController : public QObject {
45 public:
46  explicit FitComparison1DViewController(QObject* parent);
47 
49 
50  void setItem(JobItem* job_item);
51  void updateDiffData();
52  void resetDiffView();
53 
54  void clear();
55 
56 private:
57  void createDiffViewItem(JobItem* job_item);
58  void deleteDiffViewItem();
59 
64 };
65 
66 #endif // BORNAGAIN_GUI_VIEW_PLOTCOMPARISON_FITCOMPARISONVIEWCONTROLLER_H
View model for 1D DataItem. Can represent several items at once. In current implementation the first ...
Abstract base class for IntensityDataItem and SpecularDataItem. Owns one simulated data set of type D...
Definition: DataItem.h:34
void setJobItem(JobItem *job_item)
DiffItemController(const QString &data_type, QObject *parent)
Tracks property change (axes range, units etc) for the collection of IntensityDataItems and sets same...
Base class for a GUI data collection. A collection is e.g. all real data (RealDataModel)....
Definition: SessionModel.h:42