graph_analysis
GraphAnalysisGui.hpp
Go to the documentation of this file.
1 #ifndef GRAPH_ANALYSIS_GUI_HPP
2 #define GRAPH_ANALYSIS_GUI_HPP
3 
4 #include <QMainWindow>
5 #include "QBaseGraph.hpp"
6 #include <QSettings>
7 
8 namespace Ui
9 {
10 class GraphAnalysisGui;
11 }
12 
13 namespace graph_analysis
14 {
15 namespace gui
16 {
17 
18 class BaseGraphView;
19 
20 class GraphAnalysisGui : public QMainWindow
21 {
22  Q_OBJECT
23 
24 public:
26  explicit GraphAnalysisGui( BaseGraph::Ptr graph );
28 
29 private:
30  // gui elements
31  Ui::GraphAnalysisGui* mpUi;
32 
33  // the basegraph where the subwidgets will work upon
34  QBaseGraph* mpQBaseGraph;
35  BaseGraph::Ptr mpBaseGraph;
36 
37  // the subwigets, present in this window
38  BaseGraphView* mpBaseGraphView;
39 
40  QList<QAction*> mpRecentFileActions;
41  enum { MaxRecentFiles = 5 };
42 
43  void init();
44 
45  void notifyAll();
46 
51  void updateRecentFileActions();
52 
53  QString strippedName(const QString& fullFileName);
54 
55  void activateGraph(graph_analysis::BaseGraph::Ptr& graph);
56 
57 public slots:
58  void importGraph();
59  void exportGraph();
60  void selectLayout();
61  void saveScene();
62 
63  void playGraph();
64  void reversePlayGraph();
65  void importRecentFile();
66 
67 private slots:
68  /*Connected to QBaseGraph*/
69  void updateVisualization();
70  void on_tabWidget_currentChanged(int index);
71 
72 };
73 
74 } // end namespace gui
75 } // end namespace graph_analysis
76 #endif // GRAPH_ANALYSIS_GUI_HPP
graph_analysis::gui::GraphAnalysisGui
Definition: GraphAnalysisGui.hpp:20
graph_analysis::gui::GraphAnalysisGui::reversePlayGraph
void reversePlayGraph()
Definition: GraphAnalysisGui.cpp:147
graph_analysis::gui::GraphAnalysisGui::importGraph
void importGraph()
Definition: GraphAnalysisGui.cpp:118
graph_analysis::gui::GraphAnalysisGui::~GraphAnalysisGui
~GraphAnalysisGui()
Definition: GraphAnalysisGui.cpp:113
graph_analysis::gui::BaseGraphView
displaying the raw hypergraph in all its glory
Definition: BaseGraphView.hpp:42
graph_analysis
Main namespace of the graph analysis library.
Definition: BFS.cpp:3
graph_analysis::gui::GraphAnalysisGui::importRecentFile
void importRecentFile()
Definition: GraphAnalysisGui.cpp:208
graph_analysis::BaseGraph::Ptr
shared_ptr< BaseGraph > Ptr
Definition: BaseGraph.hpp:34
graph_analysis::gui::GraphAnalysisGui::selectLayout
void selectLayout()
Definition: GraphAnalysisGui.cpp:131
graph_analysis::gui::GraphAnalysisGui::exportGraph
void exportGraph()
Definition: GraphAnalysisGui.cpp:126
QBaseGraph.hpp
Ui
Definition: AddEdgeDialog.hpp:6
graph_analysis::gui::QBaseGraph
This class converts the callback based interface to the base graph into a Qt signal It implements a v...
Definition: QBaseGraph.hpp:22
graph_analysis::gui::GraphAnalysisGui::playGraph
void playGraph()
Definition: GraphAnalysisGui.cpp:158
graph_analysis::gui::GraphAnalysisGui::GraphAnalysisGui
GraphAnalysisGui()
Definition: GraphAnalysisGui.cpp:29
graph_analysis::gui::GraphAnalysisGui::saveScene
void saveScene()
Definition: GraphAnalysisGui.cpp:166