ParaView
|
pqSignalAdaptorCompositeTreeWidget is used to connect a property with vtkSMCompositeTreeDomain as its domain to a Tree widget. More...
#include <pqSignalAdaptorCompositeTreeWidget.h>
Inherits QObject.
Public Types | |
enum | IndexModes { INDEX_MODE_FLAT, INDEX_MODE_LEVEL_INDEX, INDEX_MODE_LEVEL } |
Public Slots | |
void | setValues (const QList< QVariant > &values) |
Set the values. More... | |
void | domainChanged () |
Called when domain changes. More... | |
void | portInformationChanged () |
Called when the output port says that the data information has been updated. More... | |
Signals | |
void | valuesChanged () |
Fired when the widget value changes. More... | |
Public Member Functions | |
pqSignalAdaptorCompositeTreeWidget (QTreeWidget *, vtkSMIntVectorProperty *smproperty, bool autoUpdateWidgetVisibility=false, bool showSelectedElementCounts=false) | |
Constructor. More... | |
pqSignalAdaptorCompositeTreeWidget (QTreeWidget *, vtkSMOutputPort *outputport, int domainMode, IndexModes indexMode=INDEX_MODE_FLAT, bool selectMultiple=false, bool autoUpdateWidgetVisibility=false, bool showSelectedElementCounts=false) | |
Alternate constructor. More... | |
virtual | ~pqSignalAdaptorCompositeTreeWidget () |
Destructor. More... | |
QList< QVariant > | values () const |
Returns the current value. More... | |
void | setAutoUpdateWidgetVisibility (bool val) |
When set, the adaptor will update the visibility of the widget depending on whether the data is composite or not. More... | |
bool | autoUpdateWidgetVisibility () const |
void | select (unsigned int flatIndex) |
Select the item with the given flat index. More... | |
unsigned int | getCurrentFlatIndex (bool *valid=NULL) |
API to get information about the currently selected item. More... | |
QString | blockName (const QTreeWidgetItem *item) const |
API to get information about an item. More... | |
unsigned int | hierarchicalLevel (const QTreeWidgetItem *item) const |
API to get information about an item. More... | |
unsigned int | hierarchicalBlockIndex (const QTreeWidgetItem *item) const |
API to get information about an item. More... | |
unsigned int | flatIndex (const QTreeWidgetItem *item) const |
API to get information about an item. More... | |
Properties | |
QList< QVariant > | values |
Friends | |
class | pqCallbackAdaptor |
pqSignalAdaptorCompositeTreeWidget is used to connect a property with vtkSMCompositeTreeDomain as its domain to a Tree widget.
It updates the tree to show composite data tree. Caveats: This widget does not handle SINGLE_ITEM selection where non-leaves are acceptable.
Definition at line 54 of file pqSignalAdaptorCompositeTreeWidget.h.
Enumerator | |
---|---|
INDEX_MODE_FLAT | |
INDEX_MODE_LEVEL_INDEX | |
INDEX_MODE_LEVEL |
Definition at line 61 of file pqSignalAdaptorCompositeTreeWidget.h.
pqSignalAdaptorCompositeTreeWidget::pqSignalAdaptorCompositeTreeWidget | ( | QTreeWidget * | , |
vtkSMIntVectorProperty * | smproperty, | ||
bool | autoUpdateWidgetVisibility = false , |
||
bool | showSelectedElementCounts = false |
||
) |
Constructor.
domain
is used to build the tree layout to show in the widget. autoUpdateWidgetVisibility
- is true, the tree widget is hidden if the data information says that the data is not composite. showSelectedElementCounts
- when true, next to each leaf node, an entry will be added showing the number of selected elements (cells|points).
pqSignalAdaptorCompositeTreeWidget::pqSignalAdaptorCompositeTreeWidget | ( | QTreeWidget * | , |
vtkSMOutputPort * | outputport, | ||
int | domainMode, | ||
IndexModes | indexMode = INDEX_MODE_FLAT , |
||
bool | selectMultiple = false , |
||
bool | autoUpdateWidgetVisibility = false , |
||
bool | showSelectedElementCounts = false |
||
) |
Alternate constructor.
outputport
- the output port producing the composite dataset to show. domainMode
- vtkSMCompositeTreeDomain::ALL|LEAVES|NON_LEAVES|NONE. Indicates what types of nodes in the composite tree are selectable. indexMode
- indicates how the values are set/get (using composite-flat-index, using level-dataset-index or using only the level number. selectMultiple
- true if possible to select multiple nodes. autoUpdateWidgetVisibility
- is true, the tree widget is hidden if the data information says that the data is not composite. showSelectedElementCounts
- when true, next to each leaf node, an entry will be added showing the number of selected elements (cells|points).
|
virtual |
Destructor.
QList<QVariant> pqSignalAdaptorCompositeTreeWidget::values | ( | ) | const |
Returns the current value.
This is a QList of unsigned ints.
|
inline |
When set, the adaptor will update the visibility of the widget depending on whether the data is composite or not.
Definition at line 117 of file pqSignalAdaptorCompositeTreeWidget.h.
|
inline |
Definition at line 118 of file pqSignalAdaptorCompositeTreeWidget.h.
void pqSignalAdaptorCompositeTreeWidget::select | ( | unsigned int | flatIndex | ) |
Select the item with the given flat index.
unsigned int pqSignalAdaptorCompositeTreeWidget::getCurrentFlatIndex | ( | bool * | valid = NULL | ) |
API to get information about the currently selected item.
Returns the flat index for the current item.
QString pqSignalAdaptorCompositeTreeWidget::blockName | ( | const QTreeWidgetItem * | item | ) | const |
API to get information about an item.
Returns the block name for the item.
unsigned int pqSignalAdaptorCompositeTreeWidget::hierarchicalLevel | ( | const QTreeWidgetItem * | item | ) | const |
API to get information about an item.
Returns the AMR level for the item if valid.
unsigned int pqSignalAdaptorCompositeTreeWidget::hierarchicalBlockIndex | ( | const QTreeWidgetItem * | item | ) | const |
API to get information about an item.
Returns the AMR block number for the item if valid.
unsigned int pqSignalAdaptorCompositeTreeWidget::flatIndex | ( | const QTreeWidgetItem * | item | ) | const |
API to get information about an item.
Returns the flat index for the item.
|
slot |
Set the values.
|
slot |
Called when domain changes.
|
slot |
Called when the output port says that the data information has been updated.
|
signal |
Fired when the widget value changes.
|
friend |
Definition at line 257 of file pqSignalAdaptorCompositeTreeWidget.h.
|
readwrite |
Definition at line 59 of file pqSignalAdaptorCompositeTreeWidget.h.