9 #ifndef UI_PQBOXPROPERTYWIDGET_H 10 #define UI_PQBOXPROPERTYWIDGET_H 12 #include <QtCore/QVariant> 13 #include <QtWidgets/QApplication> 14 #include <QtWidgets/QCheckBox> 15 #include <QtWidgets/QFrame> 16 #include <QtWidgets/QGridLayout> 17 #include <QtWidgets/QLabel> 18 #include <QtWidgets/QPushButton> 19 #include <QtWidgets/QSpacerItem> 20 #include <QtWidgets/QVBoxLayout> 21 #include <QtWidgets/QWidget> 69 if (BoxPropertyWidget->objectName().isEmpty())
70 BoxPropertyWidget->setObjectName(QString::fromUtf8(
"BoxPropertyWidget"));
71 BoxPropertyWidget->resize(230, 428);
72 vboxLayout =
new QVBoxLayout(BoxPropertyWidget);
73 vboxLayout->setSpacing(2);
74 vboxLayout->setObjectName(QString::fromUtf8(
"vboxLayout"));
75 vboxLayout->setContentsMargins(0, 0, 0, 0);
76 show3DWidget =
new QCheckBox(BoxPropertyWidget);
77 show3DWidget->setObjectName(QString::fromUtf8(
"show3DWidget"));
78 show3DWidget->setChecked(
true);
80 vboxLayout->addWidget(show3DWidget);
82 gridLayout =
new QGridLayout();
83 gridLayout->setSpacing(2);
84 gridLayout->setObjectName(QString::fromUtf8(
"gridLayout"));
85 gridLayout->setContentsMargins(0, 0, 0, 0);
86 labelRotate =
new QLabel(BoxPropertyWidget);
87 labelRotate->setObjectName(QString::fromUtf8(
"labelRotate"));
89 gridLayout->addWidget(labelRotate, 1, 0, 1, 1);
92 rotateX->setObjectName(QString::fromUtf8(
"rotateX"));
94 gridLayout->addWidget(rotateX, 1, 1, 1, 1);
96 labelTranslate =
new QLabel(BoxPropertyWidget);
97 labelTranslate->setObjectName(QString::fromUtf8(
"labelTranslate"));
99 gridLayout->addWidget(labelTranslate, 0, 0, 1, 1);
102 rotateZ->setObjectName(QString::fromUtf8(
"rotateZ"));
104 gridLayout->addWidget(rotateZ, 1, 3, 1, 1);
107 translateZ->setObjectName(QString::fromUtf8(
"translateZ"));
109 gridLayout->addWidget(translateZ, 0, 3, 1, 1);
112 translateY->setObjectName(QString::fromUtf8(
"translateY"));
114 gridLayout->addWidget(translateY, 0, 2, 1, 1);
117 rotateY->setObjectName(QString::fromUtf8(
"rotateY"));
119 gridLayout->addWidget(rotateY, 1, 2, 1, 1);
122 translateX->setObjectName(QString::fromUtf8(
"translateX"));
124 gridLayout->addWidget(translateX, 0, 1, 1, 1);
127 scaleY->setObjectName(QString::fromUtf8(
"scaleY"));
129 gridLayout->addWidget(scaleY, 2, 2, 1, 1);
132 scaleX->setObjectName(QString::fromUtf8(
"scaleX"));
134 gridLayout->addWidget(scaleX, 2, 1, 1, 1);
137 scaleZ->setObjectName(QString::fromUtf8(
"scaleZ"));
139 gridLayout->addWidget(scaleZ, 2, 3, 1, 1);
141 labelScale =
new QLabel(BoxPropertyWidget);
142 labelScale->setObjectName(QString::fromUtf8(
"labelScale"));
144 gridLayout->addWidget(labelScale, 2, 0, 1, 1);
147 vboxLayout->addLayout(gridLayout);
149 verticalLayout_2 =
new QVBoxLayout();
150 verticalLayout_2->setSpacing(0);
151 verticalLayout_2->setObjectName(QString::fromUtf8(
"verticalLayout_2"));
152 referenceBoundsLabel =
new QLabel(BoxPropertyWidget);
153 referenceBoundsLabel->setObjectName(QString::fromUtf8(
"referenceBoundsLabel"));
156 referenceBoundsLabel->setFont(font);
158 verticalLayout_2->addWidget(referenceBoundsLabel);
160 referenceBoundsHLine =
new QFrame(BoxPropertyWidget);
161 referenceBoundsHLine->setObjectName(QString::fromUtf8(
"referenceBoundsHLine"));
162 referenceBoundsHLine->setFrameShape(QFrame::HLine);
163 referenceBoundsHLine->setFrameShadow(QFrame::Sunken);
165 verticalLayout_2->addWidget(referenceBoundsHLine);
168 vboxLayout->addLayout(verticalLayout_2);
170 useReferenceBounds =
new QCheckBox(BoxPropertyWidget);
171 useReferenceBounds->setObjectName(QString::fromUtf8(
"useReferenceBounds"));
172 useReferenceBounds->setChecked(
true);
174 vboxLayout->addWidget(useReferenceBounds);
176 gridLayout2 =
new QGridLayout();
177 gridLayout2->setObjectName(QString::fromUtf8(
"gridLayout2"));
179 xmin->setObjectName(QString::fromUtf8(
"xmin"));
181 gridLayout2->addWidget(xmin, 0, 0, 1, 1);
184 xmax->setObjectName(QString::fromUtf8(
"xmax"));
186 gridLayout2->addWidget(xmax, 0, 1, 1, 1);
189 ymin->setObjectName(QString::fromUtf8(
"ymin"));
191 gridLayout2->addWidget(ymin, 1, 0, 1, 1);
194 ymax->setObjectName(QString::fromUtf8(
"ymax"));
196 gridLayout2->addWidget(ymax, 1, 1, 1, 1);
199 zmin->setObjectName(QString::fromUtf8(
"zmin"));
201 gridLayout2->addWidget(zmin, 2, 0, 1, 1);
204 zmax->setObjectName(QString::fromUtf8(
"zmax"));
206 gridLayout2->addWidget(zmax, 2, 1, 1, 1);
209 vboxLayout->addLayout(gridLayout2);
211 verticalLayout =
new QVBoxLayout();
212 verticalLayout->setSpacing(0);
213 verticalLayout->setObjectName(QString::fromUtf8(
"verticalLayout"));
214 label =
new QLabel(BoxPropertyWidget);
215 label->setObjectName(QString::fromUtf8(
"label"));
216 label->setFont(font);
218 verticalLayout->addWidget(label);
220 line_2 =
new QFrame(BoxPropertyWidget);
221 line_2->setObjectName(QString::fromUtf8(
"line_2"));
222 line_2->setFrameShape(QFrame::HLine);
223 line_2->setFrameShadow(QFrame::Sunken);
225 verticalLayout->addWidget(line_2);
228 vboxLayout->addLayout(verticalLayout);
230 gridLayout1 =
new QGridLayout();
231 gridLayout1->setObjectName(QString::fromUtf8(
"gridLayout1"));
232 enableRotation =
new QCheckBox(BoxPropertyWidget);
233 enableRotation->setObjectName(QString::fromUtf8(
"enableRotation"));
235 gridLayout1->addWidget(enableRotation, 3, 0, 1, 1);
237 enableTranslation =
new QCheckBox(BoxPropertyWidget);
238 enableTranslation->setObjectName(QString::fromUtf8(
"enableTranslation"));
240 gridLayout1->addWidget(enableTranslation, 1, 0, 1, 1);
242 enableScaling =
new QCheckBox(BoxPropertyWidget);
243 enableScaling->setObjectName(QString::fromUtf8(
"enableScaling"));
245 gridLayout1->addWidget(enableScaling, 1, 1, 1, 1);
247 enableMoveFaces =
new QCheckBox(BoxPropertyWidget);
248 enableMoveFaces->setObjectName(QString::fromUtf8(
"enableMoveFaces"));
250 gridLayout1->addWidget(enableMoveFaces, 3, 1, 1, 1);
253 vboxLayout->addLayout(gridLayout1);
255 resetBounds =
new QPushButton(BoxPropertyWidget);
256 resetBounds->setObjectName(QString::fromUtf8(
"resetBounds"));
258 vboxLayout->addWidget(resetBounds);
260 visibleBoundsOnly =
new QCheckBox(BoxPropertyWidget);
261 visibleBoundsOnly->setObjectName(QString::fromUtf8(
"visibleBoundsOnly"));
263 vboxLayout->addWidget(visibleBoundsOnly);
265 verticalSpacer =
new QSpacerItem(20, 0, QSizePolicy::Minimum, QSizePolicy::Expanding);
267 vboxLayout->addItem(verticalSpacer);
269 QWidget::setTabOrder(show3DWidget, translateX);
270 QWidget::setTabOrder(translateX, translateY);
271 QWidget::setTabOrder(translateY, translateZ);
272 QWidget::setTabOrder(translateZ, rotateX);
273 QWidget::setTabOrder(rotateX, rotateY);
274 QWidget::setTabOrder(rotateY, rotateZ);
275 QWidget::setTabOrder(rotateZ, scaleX);
276 QWidget::setTabOrder(scaleX, scaleY);
277 QWidget::setTabOrder(scaleY, scaleZ);
278 QWidget::setTabOrder(scaleZ, enableTranslation);
279 QWidget::setTabOrder(enableTranslation, enableScaling);
280 QWidget::setTabOrder(enableScaling, enableRotation);
281 QWidget::setTabOrder(enableRotation, enableMoveFaces);
282 QWidget::setTabOrder(enableMoveFaces, useReferenceBounds);
283 QWidget::setTabOrder(useReferenceBounds, xmin);
284 QWidget::setTabOrder(xmin, xmax);
285 QWidget::setTabOrder(xmax, ymin);
286 QWidget::setTabOrder(ymin, ymax);
287 QWidget::setTabOrder(ymax, zmin);
288 QWidget::setTabOrder(zmin, zmax);
289 QWidget::setTabOrder(zmax, resetBounds);
292 QObject::connect(useReferenceBounds, SIGNAL(toggled(
bool)), xmin, SLOT(setVisible(
bool)));
293 QObject::connect(useReferenceBounds, SIGNAL(toggled(
bool)), xmax, SLOT(setVisible(
bool)));
294 QObject::connect(useReferenceBounds, SIGNAL(toggled(
bool)), ymin, SLOT(setVisible(
bool)));
295 QObject::connect(useReferenceBounds, SIGNAL(toggled(
bool)), ymax, SLOT(setVisible(
bool)));
296 QObject::connect(useReferenceBounds, SIGNAL(toggled(
bool)), zmax, SLOT(setVisible(
bool)));
297 QObject::connect(useReferenceBounds, SIGNAL(toggled(
bool)), zmin, SLOT(setVisible(
bool)));
299 QMetaObject::connectSlotsByName(BoxPropertyWidget);
304 BoxPropertyWidget->setWindowTitle(QCoreApplication::translate(
"BoxPropertyWidget",
"Form",
nullptr));
305 #if QT_CONFIG(tooltip) 306 show3DWidget->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Show the interactive box widget in the 3d scene.",
nullptr));
307 #endif // QT_CONFIG(tooltip) 308 show3DWidget->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Show Box",
nullptr));
309 labelRotate->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Rotate",
nullptr));
310 labelTranslate->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Translate",
nullptr));
311 labelScale->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Scale",
nullptr));
312 referenceBoundsLabel->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Reference Bounds",
nullptr));
313 #if QT_CONFIG(tooltip) 314 useReferenceBounds->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"<html><head/><body><p>Use reference bounding box. When checked, <span style=\" font-weight:600;\">Position</span>, <span style=\" font-weight:600;\">Rotation</span>, and <span style=\" font-weight:600;\">Scale</span> are specified relative to the explicitly provided reference bounding box.</p></body></html>",
nullptr));
315 #endif // QT_CONFIG(tooltip) 316 useReferenceBounds->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Use Reference Bounds",
nullptr));
317 #if QT_CONFIG(tooltip) 318 xmin->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Minimum X",
nullptr));
319 #endif // QT_CONFIG(tooltip) 320 #if QT_CONFIG(tooltip) 321 xmax->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Maximum X",
nullptr));
322 #endif // QT_CONFIG(tooltip) 323 #if QT_CONFIG(tooltip) 324 ymin->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Minimum Y",
nullptr));
325 #endif // QT_CONFIG(tooltip) 326 #if QT_CONFIG(tooltip) 327 ymax->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Maximum Y",
nullptr));
328 #endif // QT_CONFIG(tooltip) 329 #if QT_CONFIG(tooltip) 330 zmin->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Minimum Z",
nullptr));
331 #endif // QT_CONFIG(tooltip) 332 #if QT_CONFIG(tooltip) 333 zmax->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Maximum Z",
nullptr));
334 #endif // QT_CONFIG(tooltip) 335 label->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Interactivity Controls",
nullptr));
336 #if QT_CONFIG(tooltip) 337 enableRotation->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Enable rotation of the 3d box widget.",
nullptr));
338 #endif // QT_CONFIG(tooltip) 339 enableRotation->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Rotation",
nullptr));
340 #if QT_CONFIG(tooltip) 341 enableTranslation->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Enable translation of the 3d box widget.",
nullptr));
342 #endif // QT_CONFIG(tooltip) 343 enableTranslation->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Translation",
nullptr));
344 #if QT_CONFIG(tooltip) 345 enableScaling->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Enable scaling of the 3d box widget.",
nullptr));
346 #endif // QT_CONFIG(tooltip) 347 enableScaling->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Scaling",
nullptr));
348 #if QT_CONFIG(tooltip) 349 enableMoveFaces->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Enable moving faces of the 3d box widget.",
nullptr));
350 #endif // QT_CONFIG(tooltip) 351 enableMoveFaces->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Face Movement",
nullptr));
352 #if QT_CONFIG(tooltip) 353 resetBounds->setToolTip(QCoreApplication::translate(
"BoxPropertyWidget",
"Reset box using current data bounds",
nullptr));
354 #endif // QT_CONFIG(tooltip) 355 resetBounds->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Reset Bounds",
nullptr));
356 visibleBoundsOnly->setText(QCoreApplication::translate(
"BoxPropertyWidget",
"Take account of block visibility",
nullptr));
367 #endif // UI_PQBOXPROPERTYWIDGET_H
pqLineEdit subclass that supports a low precision view when inactive