OGS
MeshMapping2DDialog.h
Go to the documentation of this file.
1
11#pragma once
12
13#include "ui_MeshMapping2D.h"
14
15#include <QDialog>
16#include <QLineEdit>
17#include <QString>
18
22class MeshMapping2DDialog : public QDialog, private Ui_MeshMapping2D
23{
24 Q_OBJECT
25
26public:
27 explicit MeshMapping2DDialog(QDialog* parent = nullptr);
28
29 bool useRasterMapping() const { return this->rasterValueButton->isChecked(); }
30 bool useStaticMapping() const { return this->staticValueButton->isChecked(); }
31 std::string getRasterPath() const { return this->rasterPathEdit->text().toStdString(); }
32 double getNoDataReplacement() const { return this->noDataValueEdit->text().toDouble(); }
33 bool getIgnoreNoData() const { return this->ignoreNoDataCheckbox->isChecked(); }
34 double getStaticValue() const { return this->staticValueEdit->text().toDouble(); }
35 std::string getNewMeshName() const { return this->newNameEdit->text().toStdString(); }
36
37private slots:
38 void on_ignoreNoDataCheckbox_toggled(bool isChecked);
39 void on_rasterValueButton_toggled(bool isChecked);
41
43 void accept() override;
44
46 void reject() override { this->done(QDialog::Rejected); }
47};
A dialog window for mapping a 2d mesh based on a raster file.
std::string getNewMeshName() const
void on_rasterValueButton_toggled(bool isChecked)
void on_ignoreNoDataCheckbox_toggled(bool isChecked)
void accept() override
Instructions if the OK-Button has been pressed.
std::string getRasterPath() const
double getNoDataReplacement() const
void reject() override
Instructions if the Cancel-Button has been pressed.
MeshMapping2DDialog(QDialog *parent=nullptr)
double getStaticValue() const