-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainWindow.h
More file actions
101 lines (80 loc) · 2.14 KB
/
MainWindow.h
File metadata and controls
101 lines (80 loc) · 2.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/*
* header file for MainWindow class
* Original by: christian moellinger <ch.moellinger@gmail.com>
* Modified by: Chung-Yeon Lee <cylee@bi.snu.ac.kr> and Beom-Jin Lee <bjlee@bi.snu.ac.kr>
* 03/2011 - 06/2011 Project "InfoVis: Word Tree"
* 11/2013 - 12/2013 Project "InfoVis: Word Tree ++"
*/
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QObject>
#include <QMainWindow>
#include <QGraphicsScene>
class SearchHistory;
class WTTreeVisualizer;
class WTBackend;
namespace Ui {
class MainWindow;
}
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
/*! \name Constructor / Destructor */
//@{
/// Constructor
explicit MainWindow(QWidget *parent = 0);
QList< int > Total_index;
bool imhere[1908];
/// Destructor
~MainWindow();
//@}
/*! \name Setter */
//@{
/// sets the search history window
void SetSearchHistoryWindow(SearchHistory *pSearchHistory);
//@}
void FindWordIndex(QString search_phrase);
protected:
/*! \name Overrided events */
//@{
/// handles close event
void closeEvent(QCloseEvent *event);
//@}
private slots:
/*! \name public slots */
//@{
/// provides opening dialog and loads a file
void LoadFile();
/// searches for a phrase and visualizes the word tree
void Search(QString search_phrase);
/// handles changes in the search box (and sometimes, calls Search() )
void HandleSearchBoxValueChanged(QString sValue);
/// handles clicking on the tree
void HandleClickOnTree(int iX, int iY, bool bControlPressed);
/// handles clicking on "create word tree" button
void ForceSearch();
/// handles changes of the check box
void on_checkBox_stateChanged(int arg1);
/*
/// handles clicking on "enable opengl"
void HandleEnableOpenGL();
/// handles clicking on "disable opengl"
void HandleDisableOpenGL();
*/
/// quits the program
void Quit();
//@}
private:
/*! \name Member variables */
//@{
/// the ui
Ui::MainWindow *ui;
/// ptr to the search history window
SearchHistory *m_pSearchHistory;
/// ptr to the tree visualizer
WTTreeVisualizer *m_pTreeVisualizer;
//QGraphicsView *m_pGraphicsView2;
//@}
};
#endif // MAINWINDOW_H