pqPropertyGroupWidget.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2 // SPDX-FileCopyrightText: Copyright (c) Sandia Corporation
3 // SPDX-License-Identifier: BSD-3-Clause
4 #ifndef pqPropertyGroupWidget_h
5 #define pqPropertyGroupWidget_h
6 
7 #include "pqPropertyWidget.h"
8 
9 class QCheckBox;
10 class QComboBox;
11 class QDoubleSpinBox;
12 class QGroupBox;
13 class QLineEdit;
14 class QSpinBox;
15 class QToolButton;
16 class QWidget;
19 class vtkSMProxy;
20 class vtkSMPropertyGroup;
21 
30 {
31  Q_OBJECT
33 
34 public:
35  pqPropertyGroupWidget(vtkSMProxy* proxy, vtkSMPropertyGroup* smGroup, QWidget* parent = nullptr);
36  vtkSMPropertyGroup* propertyGroup() const { return this->PropertyGroup; }
37  // make this function accessible without class prefix
38  using Superclass::addPropertyLink;
39  void addPropertyLink(QComboBox* cb, const char* propertyName, int smindex = -1);
40  void addPropertyLink(QLineEdit* edit, const char* propertyName, int smindex = -1);
41  void addPropertyLink(QCheckBox* button, const char* propertyName, int smindex = -1);
42  void addPropertyLink(QToolButton* button, const char* propertyName, int smindex = -1);
43  void addPropertyLink(QGroupBox* groupBox, const char* propertyName, int smindex = -1);
44  void addPropertyLink(QDoubleSpinBox* spinBox, const char* propertyName, int smindex = -1);
45  void addPropertyLink(QSpinBox* spinBox, const char* propertyName, int smindex = -1);
46  void addPropertyLink(pqColorChooserButton* color, const char* propertyName, int smindex = -1);
47  void addPropertyLink(pqDoubleSliderWidget* slider, const char* propertyName, int smindex = -1);
48  // make this signal public
49  using Superclass::changeFinished;
50 
54  char* panelVisibility() const override;
55  void setPanelVisibility(const char* vis) override;
56 
57 private:
58  void addCheckedPropertyLink(QWidget* button, const char* propertyName, int smindex = -1);
59  void addDoubleValuePropertyLink(QWidget* widget, const char* propertyName, int smindex = -1);
60  void addIntValuePropertyLink(QWidget* widget, const char* propertyName, int smindex = -1);
61  void addStringPropertyLink(QWidget* widget, const char* propertyName, int smindex);
62 
63  vtkSMPropertyGroup* PropertyGroup;
64 };
65 
66 #endif
color
virtual void setPanelVisibility(const char *vis)
pqPropertyWidget represents a widget created for each property of a proxy on the pqPropertiesPanel (f...
void addPropertyLink(QObject *qobject, const char *qproperty, const char *qsignal, vtkSMProperty *smproperty, int smindex=-1)
pqColorChooserButton is a QToolButton subclass suitable for showing a a button that allows the use to...
#define PQCOMPONENTS_EXPORT
pqPropertyGroupWidget is a (custom) widget created for a PropertyGroup.
A widget with a tied slider and line edit for editing a double property.
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:140
virtual char * panelVisibility() const
Forward calls to vtkSMProperty.
vtkSMPropertyGroup * propertyGroup() const