![]() |
SWMMVis
6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
|
#include <attributedelegates.h>
Public Member Functions | |
| EnumDelegate (QObject *parent, QVariantList values) | |
| QWidget * | createEditor (QWidget *parent, const QStyleOptionViewItem &opt, const QModelIndex &index) const override |
| void | setEditorData (QWidget *editor, const QModelIndex &index) const override |
| void | setModelData (QWidget *editor, QAbstractItemModel *model, const QModelIndex &index) const override |
Static Public Member Functions | |
| static QVariantList | makePairs (const QStringList &labels, const QVariantList &data) |
Enum editor. The list is {label, data} pairs — display shows the label, the model stores the data value.
| openswmmvis::EnumDelegate::EnumDelegate | ( | QObject * | parent, |
| QVariantList | values | ||
| ) |
| values | list of QVariantList entries, each a 2-element [label QString, data QVariant] pair. |
|
override |
|
static |
Helper: build the {label, data} pair-list from two parallel StringList / VariantList arrays. Useful for static-table schema definitions.
|
override |
|
override |