Langmuir
Simulation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
axis.h
Go to the documentation of this file.
1 #ifndef AXIS_H
2 #define AXIS_H
3 
4 #include "sceneobject.h"
5 
6 namespace LangmuirView {
7 
11 class Axis : public SceneObject
12 {
13  Q_OBJECT
14 public:
20  explicit Axis(LangmuirViewer &viewer, QObject *parent = 0);
21 
25  const QColor& getXColor() const;
26 
30  const QColor& getYColor() const;
31 
35  const QColor& getZColor() const;
36 
40  double getLength() const;
41 
45  double getRadius() const;
46 
47 signals:
52  void xColorChanged(QColor color);
53 
58  void yColorChanged(QColor color);
59 
64  void zColorChanged(QColor color);
65 
70  void radiusChanged(double value);
71 
76  void lengthChanged(double value);
77 
78 public slots:
83  void setXColor(QColor color);
84 
89  void setYColor(QColor color);
90 
95  void setZColor(QColor color);
96 
101  void setRadius(double value);
102 
107  void setLength(double value);
108 
112  virtual void makeConnections();
113 
114 protected:
118  virtual void init();
119 
123  virtual void draw();
124 
126  double m_radius;
127 
129  double m_length;
130 
132  QColor m_xcolor;
133 
135  QColor m_ycolor;
136 
138  QColor m_zcolor;
139 };
140 
141 }
142 
143 #endif // AXIS_H
void setRadius(double value)
set the radius of axes
double getRadius() const
get axis radius
void setYColor(QColor color)
set the color of the x-axis
Axis(LangmuirViewer &viewer, QObject *parent=0)
create the Axis
Base class for objects in OpenGL scene.
Definition: sceneobject.h:22
double m_length
axes length
Definition: axis.h:129
void setZColor(QColor color)
set the color of the x-axis
void zColorChanged(QColor color)
signal that the color of z-axis has changed
void yColorChanged(QColor color)
signal that the color of y-axis has changed
double m_radius
axes radius
Definition: axis.h:126
QColor m_ycolor
color of y-axis
Definition: axis.h:135
const QColor & getYColor() const
get color of y-axis
A class to represent an xyz axis.
Definition: axis.h:11
void setLength(double value)
set the length of axes
QColor m_xcolor
color of x-axis
Definition: axis.h:132
const QColor & getXColor() const
get color of x-axis
const QColor & getZColor() const
get color of z-axis
Definition: axis.h:6
Widget to view Langmuir Simulation in real time.
Definition: langmuirviewer.h:47
void xColorChanged(QColor color)
signal that the color of x-axis has changed
virtual void init()
initialize object
void radiusChanged(double value)
signal that the axes radius has changed
virtual void draw()
perform OpenGL drawing operations
double getLength() const
get axis length
QColor m_zcolor
color of z-axis
Definition: axis.h:138
void setXColor(QColor color)
set the color of the x-axis
virtual void makeConnections()
make signal/slot connections
void lengthChanged(double value)
signal that the axes length has changed