]> git.mar77i.info Git - bigintmandel/blob - settingswidget.h
make zoom_factor part of MandelSettings
[bigintmandel] / settingswidget.h
1
2 // settingswidget.h
3
4 #ifndef SETTINGSWIDGET_H
5 #define SETTINGSWIDGET_H
6
7 #include <QDialog>
8 #include <QLabel>
9 #include <QLineEdit>
10
11 #include "mandel.h"
12
13 class SettingsWidget : public QDialog {
14 Q_OBJECT
15
16 QLineEdit *max_iter, *width, *height, *center_f_x, *center_f_y, *one;
17 bool is_finished;
18
19 public:
20 explicit SettingsWidget(QWidget *parent = nullptr);
21 void update_fields(const MandelParams &params, const bool is_finished);
22 inline const QString get_max_iter() const { return max_iter->text(); };
23
24 inline void set_finished(const bool is_finished) {
25 this->is_finished = is_finished;
26 max_iter->setReadOnly(!is_finished);
27 }
28
29 public Q_SLOTS:
30 void apply();
31 };
32
33 #endif // SETTINGSWIDGET_H