Go to the documentation of this file.
11 #ifndef PROCESS_PARMS_HPP
12 #define PROCESS_PARMS_HPP
18 #include <QStringList>
21 #include <unordered_map>
38 setIcon(QIcon(
":images/Process.png"));
54 QString description()
const;
61 QStringList parmNames()
const;
68 QStringList parmDescs()
const;
73 QStringList parmDefaults()
const;
83 static QStringList
booleanChoice() {
return QStringList() <<
"Yes" <<
"No"; }
87 static QStringList
storeChoice() {
return QStringList() <<
"Main" <<
"Work"; }
91 static QStringList
stackChoice() {
return QStringList() <<
"Stack 1" <<
"Stack 2" <<
"Current" <<
"Other"; }
95 static QStringList
meshChoice() {
return QStringList() <<
"Mesh 1" <<
"Mesh 2" <<
"Current" <<
"Other"; }
99 static QStringList
dimensionChoice() {
return QStringList() <<
"Vertices" <<
"Edges" <<
"Faces" <<
"Volumes"; }
103 static QStringList
dimChoice() {
return QStringList() <<
"Vertices" <<
"Faces" <<
"Volumes" <<
"All"; }
116 QString parm(
const QString &name)
const;
121 const QStringList &getParms();
126 bool setName(
const QString &name);
131 bool setDesc(
const QString &description);
136 bool addParm(
const QString &parmName,
const QString &desc,
const QString &def,
const QStringList &choices = QStringList());
141 bool insertParm(
const QString &parmName,
const QString &desc,
const QString &def,
int pos,
const QStringList &choices = QStringList());
146 bool setParm(
const QString &parmName,
const QString &parm);
151 bool setParms(
const QStringList &parms);
156 bool setParmDesc(
const QString &parmName,
const QString &desc);
161 bool setParmDefault(
const QString &parmName,
const QString &def);
166 bool setParmChoices(
const QString &parmName,
const QStringList &choices);
171 bool setIcon(
const QIcon &icon);
176 QStringList parmList(
const QString &key = QString())
const;
180 QString _description;
182 std::unordered_map<QString, int> _parmIdx;
183 QStringList _parmNames;
184 QStringList _parmDescs;
185 QStringList _parmDefaults;
static QStringList booleanChoice()
Helper function that provides a list of choices for a boolean argument.
Distributed matrix library.
static QStringList meshChoice()
Helper function that provides a list of choices for choosing between stack 1 and 2.
QList< QStringList > ParmChoiceList
Type of the dictionary giving the list of possible strings for each argument.
static QStringList dimChoice()
Helper function that provides a list of choices for choosing the dimension.
static QStringList stackChoice()
Helper function that provides a list of choices for choosing between stack 1 and 2.
static QStringList dimensionChoice()
Helper function that provides a list of choices for choosing the dimension.
static QStringList storeChoice()
Helper function that provides a list of choices for choosing from the main or work stack.