9 #ifndef UI_PQSCALARVALUELISTPROPERTYWIDGET_H 10 #define UI_PQSCALARVALUELISTPROPERTYWIDGET_H 12 #include <QtCore/QVariant> 13 #include <QtGui/QIcon> 14 #include <QtWidgets/QApplication> 15 #include <QtWidgets/QGridLayout> 16 #include <QtWidgets/QHeaderView> 17 #include <QtWidgets/QLabel> 18 #include <QtWidgets/QSpacerItem> 19 #include <QtWidgets/QToolButton> 20 #include <QtWidgets/QVBoxLayout> 21 #include <QtWidgets/QWidget> 39 void setupUi(QWidget *ScalarValueListPropertyWidget)
41 if (ScalarValueListPropertyWidget->objectName().isEmpty())
42 ScalarValueListPropertyWidget->setObjectName(QString::fromUtf8(
"ScalarValueListPropertyWidget"));
43 ScalarValueListPropertyWidget->resize(212, 215);
44 gridLayout =
new QGridLayout(ScalarValueListPropertyWidget);
45 gridLayout->setContentsMargins(0, 0, 0, 0);
46 gridLayout->setObjectName(QString::fromUtf8(
"gridLayout"));
47 gridLayout->setHorizontalSpacing(0);
49 Table->setObjectName(QString::fromUtf8(
"Table"));
50 Table->setDragDropMode(QAbstractItemView::InternalMove);
51 Table->setDefaultDropAction(Qt::MoveAction);
52 Table->setAlternatingRowColors(
true);
53 Table->setSelectionBehavior(QAbstractItemView::SelectRows);
54 Table->setProperty(
"maximumRowCountBeforeScrolling", QVariant(10));
56 gridLayout->addWidget(Table, 1, 0, 1, 1);
58 verticalLayout =
new QVBoxLayout();
59 verticalLayout->setSpacing(1);
60 verticalLayout->setObjectName(QString::fromUtf8(
"verticalLayout"));
61 Add =
new QToolButton(ScalarValueListPropertyWidget);
62 Add->setObjectName(QString::fromUtf8(
"Add"));
64 icon.addFile(QString::fromUtf8(
":/QtWidgets/Icons/pqPlus.svg"), QSize(), QIcon::Normal, QIcon::Off);
67 verticalLayout->addWidget(Add);
69 Remove =
new QToolButton(ScalarValueListPropertyWidget);
70 Remove->setObjectName(QString::fromUtf8(
"Remove"));
72 icon1.addFile(QString::fromUtf8(
":/QtWidgets/Icons/pqMinus.svg"), QSize(), QIcon::Normal, QIcon::Off);
73 Remove->setIcon(icon1);
75 verticalLayout->addWidget(Remove);
77 AddRange =
new QToolButton(ScalarValueListPropertyWidget);
78 AddRange->setObjectName(QString::fromUtf8(
"AddRange"));
80 icon2.addFile(QString::fromUtf8(
":/pqWidgets/Icons/pqRulerScale16.png"), QSize(), QIcon::Normal, QIcon::Off);
81 AddRange->setIcon(icon2);
83 verticalLayout->addWidget(AddRange);
85 verticalSpacer =
new QSpacerItem(0, 0, QSizePolicy::Minimum, QSizePolicy::Expanding);
87 verticalLayout->addItem(verticalSpacer);
89 RemoveAll =
new QToolButton(ScalarValueListPropertyWidget);
90 RemoveAll->setObjectName(QString::fromUtf8(
"RemoveAll"));
92 icon3.addFile(QString::fromUtf8(
":/QtWidgets/Icons/pqDelete.svg"), QSize(), QIcon::Normal, QIcon::Off);
93 RemoveAll->setIcon(icon3);
95 verticalLayout->addWidget(RemoveAll);
98 gridLayout->addLayout(verticalLayout, 1, 1, 1, 1);
100 ScalarRangeLabel =
new QLabel(ScalarValueListPropertyWidget);
101 ScalarRangeLabel->setObjectName(QString::fromUtf8(
"ScalarRangeLabel"));
103 gridLayout->addWidget(ScalarRangeLabel, 0, 0, 1, 2);
108 QMetaObject::connectSlotsByName(ScalarValueListPropertyWidget);
113 ScalarValueListPropertyWidget->setWindowTitle(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"Form",
nullptr));
114 #if QT_CONFIG(tooltip) 115 Add->setToolTip(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"Add new entry",
nullptr));
116 #endif // QT_CONFIG(tooltip) 117 Add->setText(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"...",
nullptr));
118 #if QT_CONFIG(tooltip) 119 Remove->setToolTip(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"Remove current entry",
nullptr));
120 #endif // QT_CONFIG(tooltip) 121 Remove->setText(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"...",
nullptr));
122 #if QT_CONFIG(tooltip) 123 AddRange->setToolTip(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"Add a range of values",
nullptr));
124 #endif // QT_CONFIG(tooltip) 125 AddRange->setText(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"...",
nullptr));
126 #if QT_CONFIG(tooltip) 127 RemoveAll->setToolTip(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"Remove all entries",
nullptr));
128 #endif // QT_CONFIG(tooltip) 129 RemoveAll->setText(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"...",
nullptr));
130 ScalarRangeLabel->setText(QCoreApplication::translate(
"ScalarValueListPropertyWidget",
"<html><head/><body><p><span style=\" font-weight:600;\">Value Range:</span> [%1, %2]</p></body></html>",
nullptr));
141 #endif // UI_PQSCALARVALUELISTPROPERTYWIDGET_H
pqExpandableTableView extends pqTableView to add support for the following features: ...