BornAgain  1.19.79
Simulate and fit neutron and x-ray scattering at grazing incidence
MaskAllView.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file GUI/View/Mask/MaskAllView.h
6 //! @brief Defines MaskAllView class
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_MASK_MASKALLVIEW_H
16 #define BORNAGAIN_GUI_VIEW_MASK_MASKALLVIEW_H
17 
19 
20 class MaskAllItem;
21 
22 //! This is a view of MaskAllItem which covers whole detector plane with mask value=true.
23 
24 class MaskAllView : public IShape2DView {
25  Q_OBJECT
26 
27 public:
28  int type() const override { return MaskEditorHelper::MASKALL; }
29 
30  explicit MaskAllView(MaskAllItem* item);
31  ~MaskAllView() override;
32 
33  SessionItem* parameterizedItem() const override;
34 
35 protected slots:
36  void update_view() override;
37 
38 protected:
39  void paint(QPainter* painter, const QStyleOptionGraphicsItem*, QWidget*) override;
40 
41 private:
42  void onItemDestroyed() override;
43 
44 private:
46 };
47 
48 #endif // BORNAGAIN_GUI_VIEW_MASK_MASKALLVIEW_H
Defines interface IShape2DView.
Main interface class for views representing MaskItems, Projections on graphics scene.
Definition: IShape2DView.h:27
This is a view of MaskAllItem which covers whole detector plane with mask value=true.
Definition: MaskAllView.h:24
void onItemDestroyed() override
Definition: MaskAllView.cpp:62
MaskAllItem * m_item
Definition: MaskAllView.h:45
void update_view() override
Definition: MaskAllView.cpp:39
SessionItem * parameterizedItem() const override
Definition: MaskAllView.cpp:34
MaskAllView(MaskAllItem *item)
Definition: MaskAllView.cpp:22
~MaskAllView() override
Definition: MaskAllView.cpp:29
int type() const override
Definition: MaskAllView.h:28
void paint(QPainter *painter, const QStyleOptionGraphicsItem *, QWidget *) override
Definition: MaskAllView.cpp:46
Base class for a GUI data item.
Definition: SessionItem.h:204