BornAgain  1.19.79
Simulate and fit neutron and x-ray scattering at grazing incidence
PlotEventInfo.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file GUI/View/PlotUtil/PlotEventInfo.h
6 //! @brief Defines the class PlotEventInfo
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_PLOTUTIL_PLOTEVENTINFO_H
16 #define BORNAGAIN_GUI_VIEW_PLOTUTIL_PLOTEVENTINFO_H
17 
19 #include <QString>
20 
21 class ColorMap;
22 class SpecularPlot;
23 
24 //! Contains parameters of mouse position in 1D or 2D plot.
25 
28 
29 public:
31 
32  QString statusString() const;
33 
34  // setters, getters
35  void setInAxesRange(bool flag) { m_in_axes_range = flag; }
36  bool inAxesRange() const { return m_in_axes_range; }
37 
38  void setLogValueAxis(bool flag) { m_log_valued_axis = flag; }
39  bool isLogValueAxis() const { return m_log_valued_axis; }
40 
41  void setX(double x) { m_x = x; }
42  double x() const { return m_x; }
43  void setY(double y) { m_y = y; }
44  double y() const { return m_y; }
45 
46  void setValue(double value) { m_value = value; }
47  double value() const { return m_value; }
48 
49  void setNx(int nx) { m_nx = nx; }
50  int nx() const { return m_nx; }
51  void setNy(int ny) { m_ny = ny; }
52  int ny() const { return m_ny; }
53 
54 private:
55  QString valueToString() const;
56 
58  double m_x, m_y, m_value;
59  int m_nx, m_ny;
61 };
62 
63 #endif // BORNAGAIN_GUI_VIEW_PLOTUTIL_PLOTEVENTINFO_H
Declares class ScientificPlot.
The ColorMap class presents 2D intensity data from IntensityDataItem as color map.
Definition: ColorMap.h:36
Contains parameters of mouse position in 1D or 2D plot.
Definition: PlotEventInfo.h:26
double x() const
Definition: PlotEventInfo.h:42
bool m_log_valued_axis
Definition: PlotEventInfo.h:57
void setNx(int nx)
Definition: PlotEventInfo.h:49
QString valueToString() const
void setNy(int ny)
Definition: PlotEventInfo.h:51
int ny() const
Definition: PlotEventInfo.h:52
void setInAxesRange(bool flag)
Definition: PlotEventInfo.h:35
bool m_in_axes_range
Definition: PlotEventInfo.h:57
double y() const
Definition: PlotEventInfo.h:44
PLOT_TYPE m_info_type
Definition: PlotEventInfo.h:60
bool inAxesRange() const
Definition: PlotEventInfo.h:36
PlotEventInfo(PLOT_TYPE type)
void setX(double x)
Definition: PlotEventInfo.h:41
void setY(double y)
Definition: PlotEventInfo.h:43
void setValue(double value)
Definition: PlotEventInfo.h:46
double value() const
Definition: PlotEventInfo.h:47
void setLogValueAxis(bool flag)
Definition: PlotEventInfo.h:38
int nx() const
Definition: PlotEventInfo.h:50
bool isLogValueAxis() const
Definition: PlotEventInfo.h:39
QString statusString() const
The SpecularPlot class presents 1D intensity data from SpecularDataItem.
Definition: SpecularPlot.h:32