![]() |
Slicer 5.9
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
|
#include <Modules/Loadable/SubjectHierarchy/Widgets/qMRMLSubjectHierarchyTreeView.h>
Public Types | |
typedef QTreeView | Superclass |
Properties | |
bool | addNodeMenuActionVisible |
This property controls whether the add node context menu of the scene is visible for node types specified in "nodeTypes" property. | |
QString | attributeNameFilter |
QString | attributeValueFilter |
bool | colorColumnVisible |
bool | contextMenuEnabled |
Flag determining whether context menu is enabled. | |
bool | descriptionColumnVisible |
bool | editMenuActionVisible |
This property controls whether the Edit properties context menu action is visible. Visible by default. | |
QStringList | excludeItemAttributeNamesFilter |
QStringList | excludeNodeAttributeNamesFilter |
QStringList | hideChildNodeTypes |
bool | highlightReferencedItems |
bool | idColumnVisible |
QStringList | includeItemAttributeNamesFilter |
Filter to show only items that contain any of the given attributes with this name. Empty by default. | |
QStringList | includeNodeAttributeNamesFilter |
Filter to show only items for data nodes that contain any of the given attributes with this name. Empty by default. | |
QStringList | levelFilter |
bool | multiSelection |
Flag determining whether multiple items can be selected. | |
QString | nameFilter |
QStringList | nodeTypes |
QString | noneDisplay |
bool | noneEnabled |
QStringList | pluginAllowList |
QStringList | pluginBlockList |
bool | selectRoleSubMenuVisible |
This property controls whether the Select role context menu sub-menu is visible. Visible by default. | |
QVTK_OBJECTbool | showRootItem |
bool | transformColumnVisible |
bool | useTerminologySelector |
Double-clicking the color will show a standard terminology selector if true, otherwise show simple color picker. | |
bool | visibilityColumnVisible |
Public Slots | |
virtual vtkMRMLNode * | addNode (QString nodeType) |
Creates a node of the same type as in the "node types" property. | |
virtual void | collapseItem (vtkIdType itemID) |
Handle collapse item requests in the subject hierarchy tree. Collapses branch. | |
void | deleteSelectedItems () |
Delete selected subject hierarchy items and associated data nodes. | |
void | disablePlugin (QString plugin) |
virtual void | editCurrentItem () |
Edit properties of current item. | |
virtual void | expandItem (vtkIdType itemID) |
Handle expand item requests in the subject hierarchy tree. Expands branch. | |
void | hideSelectedItems () |
Hide selected subject hierarchy items. | |
void | renameCurrentItem () |
Rename currently selected one item by popping up a dialog. | |
void | resetColumnSizesToDefault () |
Resets column sizes and size policies to default. | |
virtual void | selectPluginForCurrentItem () |
Handle manual selection of a plugin as the new owner of a subject hierarchy node. | |
void | setAddNodeMenuActionVisible (bool show) |
Set whether to show the "Create node" actions in the context menu of the scene. | |
void | setAttributeNameFilter (QString &filter) |
void | setAttributeValueFilter (QString &filter) |
void | setContextMenuEnabled (bool enabled) |
virtual void | setCurrentItem (vtkIdType itemID) |
Set current (=selected) subject hierarchy item. | |
virtual void | setCurrentItems (QList< vtkIdType > items) |
Set current (=selected) subject hierarchy items. | |
virtual void | setCurrentItems (vtkIdList *items) |
Python compatibility function to set current (=selected) subject hierarchy items. | |
virtual void | setCurrentNode (vtkMRMLNode *node) |
Convenience method to set current item by associated data node. | |
void | setEditMenuActionVisible (bool visible) |
void | setExcludeItemAttributeNamesFilter (QStringList filter) |
void | setExcludeNodeAttributeNamesFilter (QStringList filter) |
void | setHighlightReferencedItems (bool highlightOn) |
void | setIncludeItemAttributeNamesFilter (QStringList filter) |
void | setIncludeNodeAttributeNamesFilter (QStringList filter) |
virtual void | setMRMLScene (vtkMRMLScene *scene) |
Set MRML scene. | |
virtual void | setMultiSelection (bool multiSelectionOn) |
Set multi-selection. | |
void | setNoneDisplay (const QString &displayName) |
void | setNoneEnabled (bool enable) |
void | setPluginAllowList (QStringList allowlist) |
void | setPluginAllowlist (QStringList allowlist) |
Deprecated. Use setPluginAllowList instead. | |
void | setPluginBlacklist (QStringList blocklist) |
Deprecated. Use setPluginBlocklist instead. | |
void | setPluginBlockList (QStringList blocklist) |
void | setPluginBlocklist (QStringList blocklist) |
Deprecated. Use setPluginBlockList instead. | |
void | setPluginWhitelist (QStringList allowlist) |
Deprecated. Use setPluginAllowlist instead. | |
virtual void | setRootItem (vtkIdType itemID) |
Set subject hierarchy item to be the root in the shown tree. | |
void | setSelectRoleSubMenuVisible (bool visible) |
void | setShowRootItem (bool show) |
Set root item visibility. | |
void | setUseTerminologySelector (bool useTerminologySelector) |
Set if standard terminologies are used for choosing segment name and color. | |
bool | showContextMenuHint (bool visibility=false) |
void | showSelectedItems () |
Show selected subject hierarchy items. | |
void | toggleVisibilityOfSelectedItems () |
Toggle visibility of selected subject hierarchy items. | |
virtual void | updateSelectPluginActions () |
Signals | |
void | currentItemChanged (vtkIdType) |
void | currentItemModified (vtkIdType) |
void | currentItemsChanged (QList< vtkIdType >) |
void | currentNodeChanged (vtkMRMLNode *) |
void | nodeAddedByUser (vtkMRMLNode *node) |
Signal emitted when node is added by the user. | |
Public Member Functions | |
Q_INVOKABLE void | addItemAttributeFilter (QString attributeName, QVariant attributeValue=QString(), bool include=true) |
Q_INVOKABLE void | addNodeAttributeFilter (QString attributeName, QVariant attributeValue=QString(), bool include=true, QString className=QString()) |
bool | addNodeMenuActionVisible () const |
Get whether the "Create node" actions are shown in the context menu of the scene. | |
QString | attributeNameFilter () const |
QString | attributeValueFilter () const |
QString | baseName (const QString &nodeType="") const |
bool | colorColumnVisible () |
bool | contextMenuEnabled () const |
Q_INVOKABLE vtkIdType | currentItem () const |
Get current (=selected) item. If there are multiple items selected, then the first one is returned. | |
QList< vtkIdType > | currentItems () |
Get current (=selected) items. | |
Q_INVOKABLE void | currentItems (vtkIdList *selectedItems) |
virtual vtkMRMLNode * | currentNode () const |
Convenience method to set current item by associated data node. | |
bool | descriptionColumnVisible () |
Q_INVOKABLE int | displayedItemCount () const |
Determine the number of shown items. | |
bool | editMenuActionVisible () const |
QStringList | excludeItemAttributeNamesFilter () const |
QStringList | excludeNodeAttributeNamesFilter () const |
Q_INVOKABLE vtkMRMLNode * | findFirstNodeByClass (const QString &className) const |
QStringList | hideChildNodeTypes () const |
bool | highlightReferencedItems () const |
bool | idColumnVisible () |
QStringList | includeItemAttributeNamesFilter () const |
QStringList | includeNodeAttributeNamesFilter () const |
QStringList | levelFilter () const |
Q_INVOKABLE qMRMLSubjectHierarchyModel * | model () const |
Q_INVOKABLE vtkMRMLScene * | mrmlScene () const |
bool | multiSelection () |
Get whether multi-selection is enabled. | |
QString | nameFilter () const |
Q_INVOKABLE QString | nodeTypeLabel (const QString &nodeType) const |
QStringList | nodeTypes () const |
QString | noneDisplay () const |
bool | noneEnabled () const |
QStringList | pluginAllowList () const |
QStringList | pluginBlockList () const |
qMRMLSubjectHierarchyTreeView (QWidget *parent=nullptr) | |
Q_INVOKABLE void | removeAttributeFilter () |
Remove item attribute filtering. | |
Q_INVOKABLE void | removeItemAttributeFilter (QString attributeName, bool include) |
Remove all item attribute filters specifying a given attribute name and include flag. | |
Q_INVOKABLE void | removeItemAttributeFilter (QString attributeName, QVariant attributeValue, bool include) |
Remove single item attribute filter specifying each attribute. | |
Q_INVOKABLE void | removeNodeAttributeFilter (QString attributeName, bool include) |
Remove all node attribute filters specifying a given attribute name and include flag. | |
Q_INVOKABLE void | removeNodeAttributeFilter (QString attributeName, QVariant attributeValue, bool include, QString className) |
Remove single node attribute filter specifying each attribute. | |
Q_INVOKABLE vtkIdType | rootItem () const |
Get root item of the tree. | |
bool | selectRoleSubMenuVisible () const |
Q_INVOKABLE void | setAttributeFilter (const QString &attributeName, const QVariant &attributeValue=QVariant()) |
void | setBaseName (const QString &baseName, const QString &nodeType="") |
void | setColorColumnVisible (bool visible) |
Set color column visibility. | |
void | setDescriptionColumnVisible (bool visible) |
Set description column visibility. | |
void | setHideChildNodeTypes (const QStringList &types) |
void | setIdColumnVisible (bool visible) |
Set ID column visibility. | |
void | setLevelFilter (QStringList &levelFilter) |
Set level filter that allows showing only items at a specified level and their parents. Show all items if empty. | |
void | setNameFilter (QString &nameFilter) |
Set name filter that allows showing only items containing a specified string (case-insensitive). Show all items if empty. | |
Q_INVOKABLE void | setNodeTypeLabel (const QString &label, const QString &nodeType) |
void | setNodeTypes (const QStringList &types) |
Set node type filter that allows showing only data nodes of a certain type. Show all data nodes if empty. | |
void | setTransformColumnVisible (bool visible) |
Set transform column visibility. | |
void | setVisibilityColumnVisible (bool visible) |
Set visibility column visibility. | |
bool | showRootItem () const |
Get root item visibility. | |
Q_INVOKABLE qMRMLSortFilterSubjectHierarchyProxyModel * | sortFilterProxyModel () const |
Q_INVOKABLE vtkMRMLSubjectHierarchyNode * | subjectHierarchyNode () const |
bool | transformColumnVisible () |
bool | useTerminologySelector () const |
bool | visibilityColumnVisible () |
~qMRMLSubjectHierarchyTreeView () override | |
Protected Slots | |
virtual void | addNode () |
void | onCustomContextMenu (const QPoint &point) |
virtual void | onItemCollapsed (const QModelIndex &collapsedItemIndex) |
Updates subject hierarchy item expanded property when item is collapsed. | |
virtual void | onItemExpanded (const QModelIndex &expandedItemIndex) |
Updates subject hierarchy item expanded property when item is expanded. | |
virtual void | onMRMLSceneEndBatchProcess (vtkObject *sceneObject) |
Called when batch processing ends. Restores selection, which is lost when the hierarchy is rebuilt. | |
virtual void | onMRMLSceneEndClose (vtkObject *sceneObject) |
Called when scene close is finished. Hierarchy is cleared in that case. | |
virtual void | onMRMLSceneStartBatchProcess (vtkObject *sceneObject) |
Called when batch processing starts. Makes sure stored selection does not get emptied before restoring. | |
virtual void | onMRMLSceneStartClose (vtkObject *sceneObject) |
Called when scene close is started. | |
virtual void | onSelectionChanged (const QItemSelection &selected, const QItemSelection &deselected) |
virtual void | onSubjectHierarchyItemModified (vtkObject *caller, void *callData) |
Propagate item modified event. | |
virtual void | onSubjectHierarchyItemTransformModified (vtkObject *caller, void *callData) |
Propagate item transform modified event. | |
virtual void | updateRootItem () |
Protected Member Functions | |
void | applyReferenceHighlightForItems (QList< vtkIdType > itemIDs) |
void | changeEvent (QEvent *e) override |
virtual bool | clickDecoration (QMouseEvent *e) |
vtkIdType | firstSelectedSubjectHierarchyItemInBranch (vtkIdType itemID) |
void | keyPressEvent (QKeyEvent *e) override |
Handle key press event. | |
void | mousePressEvent (QMouseEvent *e) override |
Handle mouse press event. | |
virtual void | populateContextMenuForItem (vtkIdType itemID) |
virtual void | populateTransformContextMenuForItem (vtkIdType itemID) |
Populate transform context menu for given subject hierarchy item. | |
virtual void | populateVisibilityContextMenuForItem (vtkIdType itemID) |
Populate visibility context menu for given subject hierarchy item. | |
virtual void | setSubjectHierarchyNode (vtkMRMLSubjectHierarchyNode *shNode) |
Set the subject hierarchy node found in the given scene. Called only internally. | |
Protected Attributes | |
QScopedPointer< qMRMLSubjectHierarchyTreeViewPrivate > | d_ptr |
Friends | |
class | qMRMLSubjectHierarchyComboBox |
Definition at line 43 of file qMRMLSubjectHierarchyTreeView.h.
typedef QTreeView qMRMLSubjectHierarchyTreeView::Superclass |
Definition at line 112 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
This property controls whether the add node context menu of the scene is visible for node types specified in "nodeTypes" property.
Definition at line 62 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Filter to show only items that contain an item attribute with this name. Empty by default. Sets and returns the first attribute in
Definition at line 101 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Filter to show only items that contain any item attribute given in
Definition at line 106 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 73 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Flag determining whether context menu is enabled.
Definition at line 58 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 75 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
This property controls whether the Edit properties context menu action is visible. Visible by default.
Definition at line 60 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Filter to hide items that contain any of the given attributes with this name. Empty by default Overrides
Definition at line 93 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Filter to hide items for data nodes that contain any of the given attributes with this name. Empty by default Overrides
Definition at line 96 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 70 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Flag determining whether to highlight items referenced by DICOM. Storing DICOM references: Referenced SOP instance UIDs (in attribute named vtkMRMLSubjectHierarchyConstants::GetDICOMReferencedInstanceUIDsAttributeName()) -> SH item instance UIDs (serialized string lists in subject hierarchy UID vtkMRMLSubjectHierarchyConstants::GetDICOMInstanceUIDName())
Definition at line 56 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 72 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Filter to show only items that contain any of the given attributes with this name. Empty by default.
Definition at line 88 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Filter to show only items for data nodes that contain any of the given attributes with this name. Empty by default.
Definition at line 90 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 67 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Flag determining whether multiple items can be selected.
Definition at line 66 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 68 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 69 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
This property controls the name that is displayed for the None item. "None" by default.
Definition at line 85 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
This property controls whether an extra item is added before any subject hierarchy item under the scene item for indicating 'None' selection.
Definition at line 81 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 76 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 77 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
This property controls whether the Select role context menu sub-menu is visible. Visible by default.
Definition at line 64 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
This property controls whether the root item (folder, an item for a data node, or the scene itself), if any is visible. When the root item is visible, it appears as a top-level item, if it is hidden only its children are top-level items. It doesn't have any effect if rootItem() is invalid. Shown by default.
Definition at line 52 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 74 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Double-clicking the color will show a standard terminology selector if true, otherwise show simple color picker.
Definition at line 109 of file qMRMLSubjectHierarchyTreeView.h.
|
readwrite |
Definition at line 71 of file qMRMLSubjectHierarchyTreeView.h.
qMRMLSubjectHierarchyTreeView::qMRMLSubjectHierarchyTreeView | ( | QWidget * | parent = nullptr | ) |
|
override |
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::addItemAttributeFilter | ( | QString | attributeName, |
QVariant | attributeValue = QString(), | ||
bool | include = true ) |
Add single item attribute filter specifying attribute name, value, include/exclude, and class name
attributeName | Name of the item attribute to filter |
attributeValue | Value of the item attribute to filter |
include | Flag indicating whether this is an include filter or exclude filter.
|
|
protectedvirtualslot |
|
virtualslot |
Creates a node of the same type as in the "node types" property.
Its name is generated using basename.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::addNodeAttributeFilter | ( | QString | attributeName, |
QVariant | attributeValue = QString(), | ||
bool | include = true, | ||
QString | className = QString() ) |
Add single node attribute filter specifying attribute name, value, include/exclude, and class name
attributeName | Name of the node attribute to filter |
attributeValue | Value of the node attribute to filter |
include | Flag indicating whether this is an include filter or exclude filter.
|
className | Only filter attributes on a certain type. Empty by default (i.e. allow all classes) |
bool qMRMLSubjectHierarchyTreeView::addNodeMenuActionVisible | ( | ) | const |
Get whether the "Create node" actions are shown in the context menu of the scene.
|
protected |
Apply highlight for subject hierarchy items referenced by argument items by DICOM
QString qMRMLSubjectHierarchyTreeView::attributeNameFilter | ( | ) | const |
QString qMRMLSubjectHierarchyTreeView::attributeValueFilter | ( | ) | const |
QString qMRMLSubjectHierarchyTreeView::baseName | ( | const QString & | nodeType = "" | ) | const |
|
overrideprotected |
|
protectedvirtual |
Handles clicks on the decoration of items (i.e. icon). In visibility column this means either toggle visibility or show visibility context menu.
|
virtualslot |
Handle collapse item requests in the subject hierarchy tree. Collapses branch.
bool qMRMLSubjectHierarchyTreeView::colorColumnVisible | ( | ) |
bool qMRMLSubjectHierarchyTreeView::contextMenuEnabled | ( | ) | const |
Q_INVOKABLE vtkIdType qMRMLSubjectHierarchyTreeView::currentItem | ( | ) | const |
Get current (=selected) item. If there are multiple items selected, then the first one is returned.
|
signal |
|
signal |
QList< vtkIdType > qMRMLSubjectHierarchyTreeView::currentItems | ( | ) |
Get current (=selected) items.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::currentItems | ( | vtkIdList * | selectedItems | ) |
Get current (=selected) items.
vtkIdList | for python compatibility |
|
signal |
|
virtual |
Convenience method to set current item by associated data node.
|
signal |
|
slot |
Delete selected subject hierarchy items and associated data nodes.
bool qMRMLSubjectHierarchyTreeView::descriptionColumnVisible | ( | ) |
|
slot |
Disable subject hierarchy plugin by adding it to the blocklist
plugin | Name of the plugin to disable |
Q_INVOKABLE int qMRMLSubjectHierarchyTreeView::displayedItemCount | ( | ) | const |
Determine the number of shown items.
|
virtualslot |
Edit properties of current item.
bool qMRMLSubjectHierarchyTreeView::editMenuActionVisible | ( | ) | const |
QStringList qMRMLSubjectHierarchyTreeView::excludeItemAttributeNamesFilter | ( | ) | const |
QStringList qMRMLSubjectHierarchyTreeView::excludeNodeAttributeNamesFilter | ( | ) | const |
|
virtualslot |
Handle expand item requests in the subject hierarchy tree. Expands branch.
Q_INVOKABLE vtkMRMLNode * qMRMLSubjectHierarchyTreeView::findFirstNodeByClass | ( | const QString & | className | ) | const |
Finds the first node that is visible in the tree and is of the specified class (either exactly that class or it is a class derived from that class).
|
protected |
Return the id of the first subject hierarchy item that is found to be selected within the branch that has the input item id as its root
QStringList qMRMLSubjectHierarchyTreeView::hideChildNodeTypes | ( | ) | const |
|
slot |
Hide selected subject hierarchy items.
bool qMRMLSubjectHierarchyTreeView::highlightReferencedItems | ( | ) | const |
bool qMRMLSubjectHierarchyTreeView::idColumnVisible | ( | ) |
QStringList qMRMLSubjectHierarchyTreeView::includeItemAttributeNamesFilter | ( | ) | const |
QStringList qMRMLSubjectHierarchyTreeView::includeNodeAttributeNamesFilter | ( | ) | const |
|
overrideprotected |
Handle key press event.
QStringList qMRMLSubjectHierarchyTreeView::levelFilter | ( | ) | const |
Q_INVOKABLE qMRMLSubjectHierarchyModel * qMRMLSubjectHierarchyTreeView::model | ( | ) | const |
|
overrideprotected |
Handle mouse press event.
Q_INVOKABLE vtkMRMLScene * qMRMLSubjectHierarchyTreeView::mrmlScene | ( | ) | const |
bool qMRMLSubjectHierarchyTreeView::multiSelection | ( | ) |
Get whether multi-selection is enabled.
QString qMRMLSubjectHierarchyTreeView::nameFilter | ( | ) | const |
|
signal |
Signal emitted when node is added by the user.
Q_INVOKABLE QString qMRMLSubjectHierarchyTreeView::nodeTypeLabel | ( | const QString & | nodeType | ) | const |
QStringList qMRMLSubjectHierarchyTreeView::nodeTypes | ( | ) | const |
QString qMRMLSubjectHierarchyTreeView::noneDisplay | ( | ) | const |
bool qMRMLSubjectHierarchyTreeView::noneEnabled | ( | ) | const |
|
protectedslot |
|
protectedvirtualslot |
Updates subject hierarchy item expanded property when item is collapsed.
|
protectedvirtualslot |
Updates subject hierarchy item expanded property when item is expanded.
|
protectedvirtualslot |
Called when batch processing ends. Restores selection, which is lost when the hierarchy is rebuilt.
|
protectedvirtualslot |
Called when scene close is finished. Hierarchy is cleared in that case.
|
protectedvirtualslot |
Called when batch processing starts. Makes sure stored selection does not get emptied before restoring.
|
protectedvirtualslot |
Called when scene close is started.
|
protectedvirtualslot |
|
protectedvirtualslot |
Propagate item modified event.
|
protectedvirtualslot |
Propagate item transform modified event.
QStringList qMRMLSubjectHierarchyTreeView::pluginAllowList | ( | ) | const |
Get list of subject hierarchy plugins that are enabled. An empty allowlist means all plugins are enabled. That is the default.
QStringList qMRMLSubjectHierarchyTreeView::pluginBlockList | ( | ) | const |
Get list of subject hierarchy plugins that are disabled. An empty blocklist means all plugins are enabled. That is the default.
|
protectedvirtual |
Populate general context menu for given subject hierarchy item
itemID | Subject hierarchy item ID of the item to show context menu for. It is only used to determine whether empty area or scene was clicked. If not, then use the current items vector so that multi-selection can also be handled. |
|
protectedvirtual |
Populate transform context menu for given subject hierarchy item.
|
protectedvirtual |
Populate visibility context menu for given subject hierarchy item.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::removeAttributeFilter | ( | ) |
Remove item attribute filtering.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::removeItemAttributeFilter | ( | QString | attributeName, |
bool | include ) |
Remove all item attribute filters specifying a given attribute name and include flag.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::removeItemAttributeFilter | ( | QString | attributeName, |
QVariant | attributeValue, | ||
bool | include ) |
Remove single item attribute filter specifying each attribute.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::removeNodeAttributeFilter | ( | QString | attributeName, |
bool | include ) |
Remove all node attribute filters specifying a given attribute name and include flag.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::removeNodeAttributeFilter | ( | QString | attributeName, |
QVariant | attributeValue, | ||
bool | include, | ||
QString | className ) |
Remove single node attribute filter specifying each attribute.
|
slot |
Rename currently selected one item by popping up a dialog.
|
slot |
Resets column sizes and size policies to default.
Q_INVOKABLE vtkIdType qMRMLSubjectHierarchyTreeView::rootItem | ( | ) | const |
Get root item of the tree.
|
virtualslot |
Handle manual selection of a plugin as the new owner of a subject hierarchy node.
bool qMRMLSubjectHierarchyTreeView::selectRoleSubMenuVisible | ( | ) | const |
|
slot |
Set whether to show the "Create node" actions in the context menu of the scene.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::setAttributeFilter | ( | const QString & | attributeName, |
const QVariant & | attributeValue = QVariant() ) |
Set attribute filter that allows showing only items that have the specified attribute and their parents.
attributeName | Name of the attribute by which the items are filtered |
attributeValue | Value of the specified attribute that needs to match this given value in order for it to be shown. If empty, then existence of the attribute is enough to show. Empty by default |
|
slot |
|
slot |
void qMRMLSubjectHierarchyTreeView::setBaseName | ( | const QString & | baseName, |
const QString & | nodeType = "" ) |
BaseName is the name used to generate a node name for all the new created nodes. If nodeType is not specified for setBaseName() then base name is set for all already defined node types. If nodeType is not specified for baseName() then base name of the first node type is returned.
void qMRMLSubjectHierarchyTreeView::setColorColumnVisible | ( | bool | visible | ) |
Set color column visibility.
|
slot |
|
virtualslot |
Set current (=selected) subject hierarchy item.
|
virtualslot |
Set current (=selected) subject hierarchy items.
|
virtualslot |
Python compatibility function to set current (=selected) subject hierarchy items.
|
virtualslot |
Convenience method to set current item by associated data node.
void qMRMLSubjectHierarchyTreeView::setDescriptionColumnVisible | ( | bool | visible | ) |
Set description column visibility.
|
slot |
|
slot |
|
slot |
void qMRMLSubjectHierarchyTreeView::setHideChildNodeTypes | ( | const QStringList & | types | ) |
Set child node types filter that allows hiding certain data node subclasses that would otherwise be accepted by the data node type filter. Show all data nodes if empty
|
slot |
void qMRMLSubjectHierarchyTreeView::setIdColumnVisible | ( | bool | visible | ) |
Set ID column visibility.
|
slot |
|
slot |
void qMRMLSubjectHierarchyTreeView::setLevelFilter | ( | QStringList & | levelFilter | ) |
Set level filter that allows showing only items at a specified level and their parents. Show all items if empty.
|
virtualslot |
Set MRML scene.
|
virtualslot |
Set multi-selection.
void qMRMLSubjectHierarchyTreeView::setNameFilter | ( | QString & | nameFilter | ) |
Set name filter that allows showing only items containing a specified string (case-insensitive). Show all items if empty.
Q_INVOKABLE void qMRMLSubjectHierarchyTreeView::setNodeTypeLabel | ( | const QString & | label, |
const QString & | nodeType ) |
NodeTypeLabel is the name displayed to the user as node type. By default the node's tag is used. Configuration is useful for cases when a more specific type name is preferred (e.g., instead of the generic "Create new SubjectHierarchy" option, a module can set up the widget to show "Create new Measurements"). If label is set to empty then the default label is used.
void qMRMLSubjectHierarchyTreeView::setNodeTypes | ( | const QStringList & | types | ) |
Set node type filter that allows showing only data nodes of a certain type. Show all data nodes if empty.
|
slot |
|
slot |
|
slot |
Set list of subject hierarchy plugins that are enabled.
allowlist | List of allowed subject hierarchy plugin names. An empty allowlist means all plugins are enabled. That is the default. |
|
inlineslot |
Deprecated. Use setPluginAllowList instead.
Definition at line 327 of file qMRMLSubjectHierarchyTreeView.h.
|
inlineslot |
Deprecated. Use setPluginBlocklist instead.
Definition at line 345 of file qMRMLSubjectHierarchyTreeView.h.
|
slot |
Set list of subject hierarchy plugins that are disabled.
blocklist | List of blocked subject hierarchy plugin names. An empty blocklist means all plugins are enabled. That is the default. |
|
inlineslot |
Deprecated. Use setPluginBlockList instead.
Definition at line 333 of file qMRMLSubjectHierarchyTreeView.h.
|
inlineslot |
Deprecated. Use setPluginAllowlist instead.
Definition at line 339 of file qMRMLSubjectHierarchyTreeView.h.
|
virtualslot |
Set subject hierarchy item to be the root in the shown tree.
|
slot |
|
slot |
Set root item visibility.
|
protectedvirtual |
Set the subject hierarchy node found in the given scene. Called only internally.
void qMRMLSubjectHierarchyTreeView::setTransformColumnVisible | ( | bool | visible | ) |
Set transform column visibility.
|
slot |
Set if standard terminologies are used for choosing segment name and color.
void qMRMLSubjectHierarchyTreeView::setVisibilityColumnVisible | ( | bool | visible | ) |
Set visibility column visibility.
|
slot |
Show hint to user about context menus
visibility | True if visibility context menu hint is to be shown, false for general context menu. False by default |
bool qMRMLSubjectHierarchyTreeView::showRootItem | ( | ) | const |
Get root item visibility.
|
slot |
Show selected subject hierarchy items.
Q_INVOKABLE qMRMLSortFilterSubjectHierarchyProxyModel * qMRMLSubjectHierarchyTreeView::sortFilterProxyModel | ( | ) | const |
Q_INVOKABLE vtkMRMLSubjectHierarchyNode * qMRMLSubjectHierarchyTreeView::subjectHierarchyNode | ( | ) | const |
Return the subject hierarchy node found in the current MRML scene. While the scene is closing, this method may return a null pointer.
|
slot |
Toggle visibility of selected subject hierarchy items.
bool qMRMLSubjectHierarchyTreeView::transformColumnVisible | ( | ) |
|
protectedvirtualslot |
Update root item to restore view (e.g. after tree was updated in the model from the subject hierarchy)
|
virtualslot |
Update select plugin actions. Is called when the plugin selection sub-menu is opened, and when the user manually changes the owner plugin of a node. It sets checked state and update confidence values in the select plugin actions in the node context menu for the currently selected node.
bool qMRMLSubjectHierarchyTreeView::useTerminologySelector | ( | ) | const |
Returns true if standard terminologies are used for choosing color. If false then simple selectors are used.
bool qMRMLSubjectHierarchyTreeView::visibilityColumnVisible | ( | ) |
|
friend |
Definition at line 454 of file qMRMLSubjectHierarchyTreeView.h.
|
protected |
Definition at line 449 of file qMRMLSubjectHierarchyTreeView.h.