MNE-CPP  beta 1.0
graph.h
Go to the documentation of this file.
1 //=============================================================================================================
36 #ifndef GRAPH_H
37 #define GRAPH_H
38 
39 //*************************************************************************************************************
40 //=============================================================================================================
41 // INCLUDES
42 //=============================================================================================================
43 
44 #include "disp_global.h"
45 
46 
47 //*************************************************************************************************************
48 //=============================================================================================================
49 // QT INCLUDES
50 //=============================================================================================================
51 
52 #include <QWidget>
53 #include <QString>
54 #include <QPen>
55 #include <QSharedPointer>
56 
57 
58 //*************************************************************************************************************
59 //=============================================================================================================
60 // Eigen INCLUDES
61 //=============================================================================================================
62 
63 #include <Eigen/Core>
64 
65 
66 //*************************************************************************************************************
67 //=============================================================================================================
68 // DEFINE NAMESPACE DISP3DLIB
69 //=============================================================================================================
70 
71 namespace DISPLIB
72 {
73 
74 //*************************************************************************************************************
75 //=============================================================================================================
76 // USED NAMESPACES
77 //=============================================================================================================
78 
79 using namespace Eigen;
80 
81 
82 //*************************************************************************************************************
83 //=============================================================================================================
84 // FORWARD DECLARATIONS
85 //=============================================================================================================
86 
87 
88 
89 //=============================================================================================================
95 class DISPSHARED_EXPORT Graph : public QWidget
96 {
97  Q_OBJECT
98 public:
99  explicit Graph(QWidget *parent = 0);
100 
101  void init();
102 
103  //=========================================================================================================
109  void setTitle(const QString &p_sTitle);
110  //=========================================================================================================
116  void setXLabel(const QString &p_sXLabel);
117  //=========================================================================================================
123  void setYLabel(const QString &p_sYLabel);
124 
125 protected:
126 // void paintEvent(QPaintEvent*);
127  void resizeEvent(QResizeEvent*);
128 
129  void drawLabels(qint32 p_iContentWidth, qint32 p_iContentHeight);
130 
133  QString m_sTitle;
134  QFont m_qFontTitle;
135  QPen m_qPenTitle;
140  QString m_sXLabel;
141  QString m_sYLabel;
142  QFont m_qFontAxes;
143  QPen m_qPenAxes;
144 };
145 
146 //*************************************************************************************************************
147 //=============================================================================================================
148 // INLINE DEFINITIONS
149 //=============================================================================================================
150 
151 } // NAMESPACE
152 
153 #endif // GRAPH_H
#define DISPSHARED_EXPORT
Definition: disp_global.h:57
qint32 m_iBorderLeftRight
Definition: graph.h:138
QString m_sTitle
Definition: graph.h:133
qint32 m_iBorderTopBottom
Definition: graph.h:137
QFont m_qFontAxes
Definition: graph.h:142
QFont m_qFontTitle
Definition: graph.h:134
QString m_sXLabel
Definition: graph.h:140
QString m_sYLabel
Definition: graph.h:141
Base class for graphs.
Definition: graph.h:95
disp library export/import macros.
QSize m_qSizeWidget
Definition: graph.h:131
QPen m_qPenAxes
Definition: graph.h:143
QPen m_qPenTitle
Definition: graph.h:135