9 #ifndef UI_PQCOLORANNOTATIONSWIDGET_H 10 #define UI_PQCOLORANNOTATIONSWIDGET_H 12 #include <QtCore/QVariant> 13 #include <QtGui/QIcon> 14 #include <QtWidgets/QApplication> 15 #include <QtWidgets/QCheckBox> 16 #include <QtWidgets/QGridLayout> 17 #include <QtWidgets/QHeaderView> 18 #include <QtWidgets/QSpacerItem> 19 #include <QtWidgets/QToolButton> 20 #include <QtWidgets/QVBoxLayout> 21 #include <QtWidgets/QWidget> 43 void setupUi(QWidget *ColorAnnotationsWidget)
45 if (ColorAnnotationsWidget->objectName().isEmpty())
46 ColorAnnotationsWidget->setObjectName(QString::fromUtf8(
"ColorAnnotationsWidget"));
47 ColorAnnotationsWidget->resize(358, 230);
48 gridLayout =
new QGridLayout(ColorAnnotationsWidget);
49 gridLayout->setObjectName(QString::fromUtf8(
"gridLayout"));
50 verticalLayout =
new QVBoxLayout();
51 verticalLayout->setObjectName(QString::fromUtf8(
"verticalLayout"));
52 Add =
new QToolButton(ColorAnnotationsWidget);
53 Add->setObjectName(QString::fromUtf8(
"Add"));
55 icon.addFile(QString::fromUtf8(
":/QtWidgets/Icons/pqPlus.svg"), QSize(), QIcon::Normal, QIcon::Off);
58 verticalLayout->addWidget(Add);
60 Remove =
new QToolButton(ColorAnnotationsWidget);
61 Remove->setObjectName(QString::fromUtf8(
"Remove"));
63 icon1.addFile(QString::fromUtf8(
":/QtWidgets/Icons/pqMinus.svg"), QSize(), QIcon::Normal, QIcon::Off);
64 Remove->setIcon(icon1);
66 verticalLayout->addWidget(Remove);
68 AddActive =
new QToolButton(ColorAnnotationsWidget);
69 AddActive->setObjectName(QString::fromUtf8(
"AddActive"));
71 icon2.addFile(QString::fromUtf8(
":/pqWidgets/Icons/pqFilter16.png"), QSize(), QIcon::Normal, QIcon::Off);
72 AddActive->setIcon(icon2);
74 verticalLayout->addWidget(AddActive);
76 AddActiveFromVisible =
new QToolButton(ColorAnnotationsWidget);
77 AddActiveFromVisible->setObjectName(QString::fromUtf8(
"AddActiveFromVisible"));
79 icon3.addFile(QString::fromUtf8(
":/pqWidgets/Icons/pqFilterEyeball16.png"), QSize(), QIcon::Normal, QIcon::Off);
80 AddActiveFromVisible->setIcon(icon3);
82 verticalLayout->addWidget(AddActiveFromVisible);
84 ChoosePreset =
new QToolButton(ColorAnnotationsWidget);
85 ChoosePreset->setObjectName(QString::fromUtf8(
"ChoosePreset"));
87 icon4.addFile(QString::fromUtf8(
":/pqWidgets/Icons/pqFavorites.svg"), QSize(), QIcon::Normal, QIcon::Off);
88 ChoosePreset->setIcon(icon4);
90 verticalLayout->addWidget(ChoosePreset);
92 SaveAsPreset =
new QToolButton(ColorAnnotationsWidget);
93 SaveAsPreset->setObjectName(QString::fromUtf8(
"SaveAsPreset"));
95 icon5.addFile(QString::fromUtf8(
":/pqWidgets/Icons/pqSave.svg"), QSize(), QIcon::Normal, QIcon::Off);
96 SaveAsPreset->setIcon(icon5);
98 verticalLayout->addWidget(SaveAsPreset);
100 SaveAsNewPreset =
new QToolButton(ColorAnnotationsWidget);
101 SaveAsNewPreset->setObjectName(QString::fromUtf8(
"SaveAsNewPreset"));
103 icon6.addFile(QString::fromUtf8(
":/pqWidgets/Icons/pqSaveAs.svg"), QSize(), QIcon::Normal, QIcon::Off);
104 SaveAsNewPreset->setIcon(icon6);
106 verticalLayout->addWidget(SaveAsNewPreset);
108 verticalSpacer =
new QSpacerItem(20, 1, QSizePolicy::Minimum, QSizePolicy::Expanding);
110 verticalLayout->addItem(verticalSpacer);
112 DeleteAll =
new QToolButton(ColorAnnotationsWidget);
113 DeleteAll->setObjectName(QString::fromUtf8(
"DeleteAll"));
115 icon7.addFile(QString::fromUtf8(
":/QtWidgets/Icons/pqDelete.svg"), QSize(), QIcon::Normal, QIcon::Off);
116 DeleteAll->setIcon(icon7);
118 verticalLayout->addWidget(DeleteAll);
121 gridLayout->addLayout(verticalLayout, 0, 1, 1, 1);
124 AnnotationsTable->setObjectName(QString::fromUtf8(
"AnnotationsTable"));
125 AnnotationsTable->setDragDropMode(QAbstractItemView::InternalMove);
126 AnnotationsTable->setDefaultDropAction(Qt::MoveAction);
127 AnnotationsTable->setAlternatingRowColors(
true);
128 AnnotationsTable->setSelectionBehavior(QAbstractItemView::SelectRows);
129 AnnotationsTable->setProperty(
"maximumRowCountBeforeScrolling", QVariant(10));
130 AnnotationsTable->verticalHeader()->setVisible(
false);
132 gridLayout->addWidget(AnnotationsTable, 0, 0, 1, 1);
134 EnableOpacityMapping =
new QCheckBox(ColorAnnotationsWidget);
135 EnableOpacityMapping->setObjectName(QString::fromUtf8(
"EnableOpacityMapping"));
137 gridLayout->addWidget(EnableOpacityMapping, 1, 0, 1, 2);
142 QMetaObject::connectSlotsByName(ColorAnnotationsWidget);
147 ColorAnnotationsWidget->setWindowTitle(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Form",
nullptr));
148 #if QT_CONFIG(tooltip) 149 Add->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Add new entry",
nullptr));
150 #endif // QT_CONFIG(tooltip) 151 Add->setText(QCoreApplication::translate(
"ColorAnnotationsWidget",
"...",
nullptr));
152 #if QT_CONFIG(tooltip) 153 Remove->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Remove current entry",
nullptr));
154 #endif // QT_CONFIG(tooltip) 155 Remove->setText(QCoreApplication::translate(
"ColorAnnotationsWidget",
"...",
nullptr));
156 #if QT_CONFIG(tooltip) 157 AddActive->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Add active values from selected source",
nullptr));
158 #endif // QT_CONFIG(tooltip) 159 AddActive->setText(QCoreApplication::translate(
"ColorAnnotationsWidget",
"...",
nullptr));
160 #if QT_CONFIG(tooltip) 161 AddActiveFromVisible->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Add active values from visible pipeline objects",
nullptr));
162 #endif // QT_CONFIG(tooltip) 163 AddActiveFromVisible->setText(QCoreApplication::translate(
"ColorAnnotationsWidget",
"...",
nullptr));
164 #if QT_CONFIG(tooltip) 165 ChoosePreset->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Choose preset",
nullptr));
166 #endif // QT_CONFIG(tooltip) 167 ChoosePreset->setText(QString());
168 #if QT_CONFIG(tooltip) 169 SaveAsPreset->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Save to preset",
nullptr));
170 #endif // QT_CONFIG(tooltip) 171 SaveAsPreset->setText(QString());
172 #if QT_CONFIG(tooltip) 173 SaveAsNewPreset->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Save to new preset",
nullptr));
174 #endif // QT_CONFIG(tooltip) 175 SaveAsNewPreset->setText(QString());
176 #if QT_CONFIG(tooltip) 177 DeleteAll->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Delete all annotations",
nullptr));
178 #endif // QT_CONFIG(tooltip) 179 DeleteAll->setText(QCoreApplication::translate(
"ColorAnnotationsWidget",
"...",
nullptr));
180 #if QT_CONFIG(tooltip) 181 EnableOpacityMapping->setToolTip(QCoreApplication::translate(
"ColorAnnotationsWidget",
"When checked, the opacity function is used to render translucent surfaces.",
nullptr));
182 #endif // QT_CONFIG(tooltip) 183 EnableOpacityMapping->setText(QCoreApplication::translate(
"ColorAnnotationsWidget",
"Enable opacity mapping for surfaces",
nullptr));
194 #endif // UI_PQCOLORANNOTATIONSWIDGET_H
pqExpandableTableView extends pqTableView to add support for the following features: ...