WordTree
|
00001 /* 00002 * header file for WTWordTreeView class 00003 * written by: christian moellinger <ch.moellinger@gmail.com> 00004 * 03/2011 - 06/2011 Project "InfoVis: Word Tree" 00005 */ 00006 00007 #ifndef WTWORDTREEVIEW_H 00008 #define WTWORDTREEVIEW_H 00009 00010 #include <QGraphicsView> 00011 00012 /// this class is simply an inherited class of QGraphicsView 00013 /// which only reimplements some event handling to react on mouse clicks 00014 00015 class WTWordTreeView : public QGraphicsView 00016 { 00017 Q_OBJECT 00018 public: 00019 explicit WTWordTreeView(QWidget *parent = 0); 00020 00021 protected: 00022 void mousePressEvent (QMouseEvent * e); 00023 void keyPressEvent(QKeyEvent *event); 00024 void keyReleaseEvent(QKeyEvent *event); 00025 00026 bool m_bControlPressed; 00027 signals: 00028 void OnClicked(int, int, bool); 00029 00030 public slots: 00031 00032 }; 00033 00034 #endif // WTWORDTREEVIEW_H