BornAgain  1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
DetectorMaskDelegate.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file GUI/coregui/Views/InstrumentWidgets/DetectorMaskDelegate.h
6 //! @brief Defines class DetectorMaskDelegate
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_COREGUI_VIEWS_INSTRUMENTWIDGETS_DETECTORMASKDELEGATE_H
16 #define BORNAGAIN_GUI_COREGUI_VIEWS_INSTRUMENTWIDGETS_DETECTORMASKDELEGATE_H
17 
18 #include <QModelIndex>
19 #include <QObject>
20 
21 class InstrumentModel;
22 class IntensityDataItem;
23 class MaskEditor;
24 class SessionModel;
25 class DetectorItem;
26 
27 //! The DetectorMaskDelegate class provides synchronization between DetectorItem (defined
28 //! in InstrumentModel) and temporary IntensityDataItem (defined in temporary SessionModel).
29 //! The later one is used by MaskEditor for mask drawing.
30 
31 class DetectorMaskDelegate : public QObject {
32  Q_OBJECT
33 
34 public:
35  DetectorMaskDelegate(QObject* parent);
36 
37  void initMaskEditorContext(MaskEditor* maskEditor, InstrumentModel* instrumentModel,
38  DetectorItem* detectorItem);
39 
40 private:
42 
47 };
48 
49 #endif // BORNAGAIN_GUI_COREGUI_VIEWS_INSTRUMENTWIDGETS_DETECTORMASKDELEGATE_H
The DetectorMaskDelegate class provides synchronization between DetectorItem (defined in InstrumentMo...
void createIntensityDataItem()
Creates IntensityDataItem from DetectorItem for later usage in MaskEditor.
void initMaskEditorContext(MaskEditor *maskEditor, InstrumentModel *instrumentModel, DetectorItem *detectorItem)
SessionModel * m_tempIntensityDataModel
IntensityDataItem * m_intensityItem
DetectorItem * m_detectorItem
DetectorMaskDelegate(QObject *parent)
InstrumentModel * m_instrumentModel
Main class to draw masks on top of intensity data map.
Definition: MaskEditor.h:31