SWMMVis  6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
Loading...
Searching...
No Matches
mesh2dgroundwaterdialog.h
Go to the documentation of this file.
1
32#ifndef OPENSWMMVIS_UI_DIALOGS_MESH2DGROUNDWATERDIALOG_H
33#define OPENSWMMVIS_UI_DIALOGS_MESH2DGROUNDWATERDIALOG_H
34
35#include <QDialog>
36
37#include <openswmm/engine/openswmm_engine.h>
38
39class QCheckBox;
40class QComboBox;
41class QDoubleSpinBox;
42class QLabel;
43class QPlainTextEdit;
44class QPushButton;
45class QSpinBox;
46class QTableView;
47class QTabWidget;
48
49class UnitSystem; // core/unitsystem.h — global scope, as every other dialog declares it
50
51namespace openswmmvis::ui {
52
53class Mesh2DAquiferModel;
54class Mesh2DAquiferNodeModel;
55
56class Mesh2DGroundwaterDialog : public QDialog
57{
58 Q_OBJECT
59
60public:
63
65 QWidget *parent = nullptr,
66 Page initialPage = Page::AquiferProperties,
67 const UnitSystem *units = nullptr);
68
70 [[nodiscard]] static QStringList soilModelTokens();
72 [[nodiscard]] static QStringList closureTokens();
73
74private slots:
75 void onApply();
76 void onAddAquiferRow();
77 void onRemoveAquiferRow();
78 void onAddNodeBed();
79 void onRemoveNodeBed();
80 void refreshState();
81
82private:
83 void buildUi(Page initialPage);
84 QWidget *buildOptionsPage();
85 QWidget *buildAquiferPage();
86 QWidget *buildNodeBedPage();
87 QWidget *buildStatePage();
88
89 void loadFromEngine();
90 QString applyOptions();
91 void setEditable(bool on, const QString &whyNot);
92
93 SWMM_Engine m_engine = nullptr;
94 const UnitSystem *m_units = nullptr;
95
96 QTabWidget *m_tabs = nullptr;
97 QLabel *m_banner = nullptr;
98
99 // Options
100 QComboBox *m_soilCombo = nullptr;
101 QComboBox *m_closureCombo = nullptr;
102 QSpinBox *m_layersSpin = nullptr;
103 QCheckBox *m_capillaryCheck = nullptr;
104 QDoubleSpinBox *m_cgwSpin = nullptr;
105 QDoubleSpinBox *m_ccolSpin = nullptr;
106 QCheckBox *m_forceCfCheck = nullptr;
107 QCheckBox *m_dunneCheck = nullptr;
108 QComboBox *m_modeCombo = nullptr;
109 QComboBox *m_gwEtCombo = nullptr;
110
111 // Tables
112 QTableView *m_aquiferView = nullptr;
113 Mesh2DAquiferModel *m_aquifer = nullptr;
114 QTableView *m_nodeView = nullptr;
115 Mesh2DAquiferNodeModel *m_nodes = nullptr;
116 QPushButton *m_addRowBtn = nullptr;
117 QPushButton *m_delRowBtn = nullptr;
118 QPushButton *m_addBedBtn = nullptr;
119 QPushButton *m_delBedBtn = nullptr;
120
121 // State
122 QPlainTextEdit *m_stateText = nullptr;
123 QPushButton *m_refreshBtn = nullptr;
124};
125
126} // namespace openswmmvis::ui
127
128#endif // OPENSWMMVIS_UI_DIALOGS_MESH2DGROUNDWATERDIALOG_H
Per-project flow-units state + label helpers.
Definition unitsystem.h:28
The [2D_AQUIFER] rows: scope, the five positional columns, and the law/closure selections.
Definition mesh2daquifermodel.h:38
The [2D_AQUIFER_NODE] beds: which 1D node exchanges with which cell, through what conductance.
Definition mesh2daquifermodel.h:125
Definition mesh2dgroundwaterdialog.h:57
static QStringList soilModelTokens()
Soil characteristic laws, in the engine's enum order.
Definition mesh2dgroundwaterdialog.cpp:90
static QStringList closureTokens()
Unsaturated-zone closures, AUTO first.
Definition mesh2dgroundwaterdialog.cpp:95
Page
Which page opens first.
Definition mesh2dgroundwaterdialog.h:62
Definition openswmmvislayer.h:43
void * SWMM_Engine
Definition objectdefaultsapplier.h:19
QVector< int > parent
union-find
Definition pslgminsize.cpp:176