source: projectionDesigner/trunk/projdesigner/include/gui/QProjectorWindow.h @ 361

Last change on this file since 361 was 4, checked in by Torben Dannhauer, 15 years ago
File size: 1.2 KB
Line 
1#ifndef _QPROJECTORWINDOW_H_
2#define _QPROJECTORWINDOW_H_
3
4#include <QtXml>
5#include <QGLWidget>
6
7namespace projection
8{
9class ProjectionModel;
10class Channel;
11
12class QProjectorWindow : public QGLWidget
13{
14    Q_OBJECT
15
16public:
17
18    QProjectorWindow(QWidget* pParent=0, QGLWidget* pSharedWidget=0, Qt::WFlags flag=0);
19    virtual ~QProjectorWindow();
20
21    void setModel(ProjectionModel* pModel);
22
23    void setChannel(Channel* pChannel);
24    Channel* getChannel() const { return m_pChannel; }
25
26        void updateTitle();
27
28        void initFromDOMElement(const QDomElement& element);
29        QDomElement domElement(QDomDocument& document) const;
30
31protected:
32
33    virtual void initializeGL();
34    virtual void resizeGL(int width, int height);
35    virtual void paintGL();
36        virtual void keyReleaseEvent(QKeyEvent* pEvent);
37    virtual void mousePressEvent(QMouseEvent* pEvent);
38    virtual void mouseMoveEvent(QMouseEvent* pEvent);
39    virtual void wheelEvent(QWheelEvent* pEvent);
40    virtual void closeEvent(QCloseEvent* pEvent);
41
42protected:
43
44    Channel* m_pChannel;
45    QFont m_overlayFont;
46    QFont m_infoFont;
47
48    unsigned int m_blendChannelIndex;
49
50    static bool m_bInitialized;
51
52    ProjectionModel* m_pModel;
53};
54
55}; // projection
56
57#endif // _QPROJECTORWINDOW_H_
Note: See TracBrowser for help on using the repository browser.