-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcontroller.h
78 lines (65 loc) · 1.21 KB
/
controller.h
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
#ifndef CONTROLLER_H
#define CONTROLLER_H
#include <QObject>
#include "mainwindow.h"
#include "model.h"
class Controller : public QObject
{
Q_OBJECT
private:
MainWindow *mainwindow;
Model *model;
public:
explicit Controller(QObject *parent = nullptr);
/**
* @brief Set the Model object
*
* @param _model
*/
void setModel(Model *_model);
/**
* @brief Set the Main Window object
*
* @param _mainwindow
*/
void setMainWindow(MainWindow *_mainwindow);
public slots:
/**
*
* @brief Opens and read a JSon file to create a chart
*
* @param path string of the path
*/
void open(std::string path);
/**
* @brief Creates and shows a new graph on the window
*
*/
void newGraph();
/**
* @brief Saves
*
*/
void save();
/**
* @brief Saves your chart in .pdf format
*
*/
void saveAsPfd();
/**
* @brief closes the window
*
*/
void exit();
/**
* @brief Zooms in the content of the window
*
*/
void zoomIn();
/**
* @brief >Zooms out the content of the window
*
*/
void zoomOut();
};
#endif // CONTROLLER_H