-
Notifications
You must be signed in to change notification settings - Fork 0
/
plotwindow.h
78 lines (70 loc) · 1.87 KB
/
plotwindow.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 PLOTWINDOW_H
#define PLOTWINDOW_H
#include <QMainWindow>
#include <QPainter>
#include <QDoubleValidator>
#include <QGraphicsView>
#include "settingsdialog.h"
#include <QColorDialog>
#include <QGridLayout>
#include <QImage>
#include <QFileDialog>
#include <QDir>
#include <QDebug>
#include <QMessageBox>
#include "Mandel.h"
namespace Ui {
class plotWindow;
}
class plotWindow : public QMainWindow
{
Q_OBJECT
public:
explicit plotWindow(QWidget *parent = nullptr);
~plotWindow();
void updateVars();
private:
Ui::plotWindow *ui;
double Xmin;
double Xmax;
double Ymin;
double Ymax;
int WindowWidth;
int WindowHeight;
QColor color = (0,0,0);
QImage screenshot;
QPainter *painter;
QPen *pen;
QGraphicsView *graphic;
QPixmap *imgmap;
QGraphicsScene *scene;
int imgWidth = 800;
int imgHeight = 800;
int imgIterations = 80;
SettingsDialog *settings;
QMessageBox *welcome;
double ZoomLevel = 1.0;
void calculateZoom();
protected:
void paintEvent(QPaintEvent *pEvent);
signals:
void pushCurrentSettings(const int& imgWidth,const int& imgHeight, const int& imgIterations, const int&renderIterations);
private slots:
// void on_Refresh_clicked();
void on_ZoomInButton_clicked();
void on_ZoomOutButton_clicked();
void on_reset_clicked();
void on_ColorButton_clicked();
void on_configButton_clicked();
void on_settingsDataChanged(const int& imgiterations, const int& imgWidth, const int& imgHeight, const int& renderIterations);
void on_XminField_returnPressed();
void on_XmaxField_returnPressed();
void on_YminField_returnPressed();
void on_YmaxField_returnPressed();
void on_upButton_clicked();
void on_rightButton_clicked();
void on_downButton_clicked();
void on_leftButton_clicked();
void on_exportButton_clicked();
};
#endif // PLOTWINDOW_H