Slicer  4.8
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
List of all members | Public Types | Properties | Public Slots | Public Member Functions | Protected Member Functions | Protected Attributes
qMRMLSortFilterSubjectHierarchyProxyModel Class Reference

#include <Modules/Loadable/SubjectHierarchy/Widgets/qMRMLSortFilterSubjectHierarchyProxyModel.h>

Inheritance diagram for qMRMLSortFilterSubjectHierarchyProxyModel:
Inheritance graph
[legend]
Collaboration diagram for qMRMLSortFilterSubjectHierarchyProxyModel:
Collaboration graph
[legend]

Public Types

typedef QSortFilterProxyModel Superclass
 

Properties

QString attributeNameFilter
 Filter to show only items that contain an attribute with this name. Empty by default. More...
 
QString attributeValueFilter
 
vtkIdType hideItemsUnaffiliatedWithItemID
 
QString levelFilter
 
QString nameFilter
 Filter to show only items that contain the string in their names. Empty by default. More...
 

Public Slots

void setAttributeNameFilter (QString filter)
 
void setAttributeValueFilter (QString filter)
 
void setLevelFilter (QString filter)
 
void setNameFilter (QString filter)
 

Public Member Functions

Q_INVOKABLE int acceptedItemCount (vtkIdType rootItemID) const
 
QString attributeNameFilter () const
 
QString attributeValueFilter () const
 
virtual bool filterAcceptsItem (vtkIdType itemID, bool canAcceptIfAnyChildIsAccepted=true) const
 Filters items to decide which to display in the view. More...
 
virtual bool filterAcceptsRow (int sourceRow, const QModelIndex &sourceParent) const
 
virtual Qt::ItemFlags flags (const QModelIndex &index) const
 
vtkIdType hideItemsUnaffiliatedWithItemID ()
 
Q_INVOKABLE QModelIndex indexFromSubjectHierarchyItem (vtkIdType itemID, int column=0) const
 Retrieve an index for a given a subject hierarchy item ID. More...
 
QString levelFilter () const
 
Q_INVOKABLE vtkMRMLScenemrmlScene () const
 
QString nameFilter () const
 
 qMRMLSortFilterSubjectHierarchyProxyModel (QObject *parent=0)
 
void setHideItemsUnaffiliatedWithItemID (vtkIdType itemID)
 
Q_INVOKABLE vtkIdType subjectHierarchyItemFromIndex (const QModelIndex &index) const
 Retrieve the associated subject hierarchy item ID from a model index. More...
 
Q_INVOKABLE vtkMRMLSubjectHierarchyNodesubjectHierarchyNode () const
 
Q_INVOKABLE QModelIndex subjectHierarchySceneIndex () const
 Retrieve the index of the MRML scene (the root item) in the subject hierarchy tree. More...
 
virtual ~qMRMLSortFilterSubjectHierarchyProxyModel ()
 

Protected Member Functions

QStandardItem * sourceItem (const QModelIndex &index) const
 

Protected Attributes

QScopedPointer< qMRMLSortFilterSubjectHierarchyProxyModelPrivate > d_ptr
 

Detailed Description

Definition at line 42 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.

Member Typedef Documentation

◆ Superclass

Definition at line 63 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.

Property Documentation

◆ attributeNameFilter

QString qMRMLSortFilterSubjectHierarchyProxyModel::attributeNameFilter
readwrite

Filter to show only items that contain an attribute with this name. Empty by default.

Definition at line 50 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.

◆ attributeValueFilter

QString qMRMLSortFilterSubjectHierarchyProxyModel::attributeValueFilter
readwrite

Filter to show only items that contain an attribute with

See also
attributeNameFilter (must be set) with this value. If empty, then existence of the attribute is enough to show Exact match is required. Empty by default

Definition at line 54 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.

◆ hideItemsUnaffiliatedWithItemID

vtkIdType qMRMLSortFilterSubjectHierarchyProxyModel::hideItemsUnaffiliatedWithItemID
readwrite

This property controls whether items unaffiliated with a given subject hierarchy item are hidden or not. All the nodes are visible (invalid item ID - vtkMRMLSubjectHierarchyNode::INVALID_ITEM_ID) by default

Definition at line 57 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.

◆ levelFilter

QString qMRMLSortFilterSubjectHierarchyProxyModel::levelFilter
readwrite

Filter to show only items of a certain level (and their parents). If empty, then show all Exact match is required. Empty by default

Definition at line 60 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.

◆ nameFilter

QString qMRMLSortFilterSubjectHierarchyProxyModel::nameFilter
readwrite

Filter to show only items that contain the string in their names. Empty by default.

Definition at line 48 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.

Constructor & Destructor Documentation

◆ qMRMLSortFilterSubjectHierarchyProxyModel()

qMRMLSortFilterSubjectHierarchyProxyModel::qMRMLSortFilterSubjectHierarchyProxyModel ( QObject *  parent = 0)

◆ ~qMRMLSortFilterSubjectHierarchyProxyModel()

virtual qMRMLSortFilterSubjectHierarchyProxyModel::~qMRMLSortFilterSubjectHierarchyProxyModel ( )
virtual

Member Function Documentation

◆ acceptedItemCount()

Q_INVOKABLE int qMRMLSortFilterSubjectHierarchyProxyModel::acceptedItemCount ( vtkIdType  rootItemID) const

Determine the number of accepted (shown) items

Parameters
rootItemIDAncestor item of branch in which the accepted items are counted

◆ attributeNameFilter()

QString qMRMLSortFilterSubjectHierarchyProxyModel::attributeNameFilter ( ) const

◆ attributeValueFilter()

QString qMRMLSortFilterSubjectHierarchyProxyModel::attributeValueFilter ( ) const

◆ filterAcceptsItem()

virtual bool qMRMLSortFilterSubjectHierarchyProxyModel::filterAcceptsItem ( vtkIdType  itemID,
bool  canAcceptIfAnyChildIsAccepted = true 
) const
virtual

Filters items to decide which to display in the view.

◆ filterAcceptsRow()

virtual bool qMRMLSortFilterSubjectHierarchyProxyModel::filterAcceptsRow ( int  sourceRow,
const QModelIndex &  sourceParent 
) const
virtual

Returns true if the item in the row indicated by the given sourceRow and sourceParent should be included in the model; otherwise returns false. This method test each item via filterAcceptsItem

◆ flags()

virtual Qt::ItemFlags qMRMLSortFilterSubjectHierarchyProxyModel::flags ( const QModelIndex &  index) const
virtual

◆ hideItemsUnaffiliatedWithItemID()

vtkIdType qMRMLSortFilterSubjectHierarchyProxyModel::hideItemsUnaffiliatedWithItemID ( )

◆ indexFromSubjectHierarchyItem()

Q_INVOKABLE QModelIndex qMRMLSortFilterSubjectHierarchyProxyModel::indexFromSubjectHierarchyItem ( vtkIdType  itemID,
int  column = 0 
) const

Retrieve an index for a given a subject hierarchy item ID.

◆ levelFilter()

QString qMRMLSortFilterSubjectHierarchyProxyModel::levelFilter ( ) const

◆ mrmlScene()

Q_INVOKABLE vtkMRMLScene* qMRMLSortFilterSubjectHierarchyProxyModel::mrmlScene ( ) const

◆ nameFilter()

QString qMRMLSortFilterSubjectHierarchyProxyModel::nameFilter ( ) const

◆ setAttributeNameFilter

void qMRMLSortFilterSubjectHierarchyProxyModel::setAttributeNameFilter ( QString  filter)
slot

◆ setAttributeValueFilter

void qMRMLSortFilterSubjectHierarchyProxyModel::setAttributeValueFilter ( QString  filter)
slot

◆ setHideItemsUnaffiliatedWithItemID()

void qMRMLSortFilterSubjectHierarchyProxyModel::setHideItemsUnaffiliatedWithItemID ( vtkIdType  itemID)

◆ setLevelFilter

void qMRMLSortFilterSubjectHierarchyProxyModel::setLevelFilter ( QString  filter)
slot

◆ setNameFilter

void qMRMLSortFilterSubjectHierarchyProxyModel::setNameFilter ( QString  filter)
slot

◆ sourceItem()

QStandardItem* qMRMLSortFilterSubjectHierarchyProxyModel::sourceItem ( const QModelIndex &  index) const
protected

◆ subjectHierarchyItemFromIndex()

Q_INVOKABLE vtkIdType qMRMLSortFilterSubjectHierarchyProxyModel::subjectHierarchyItemFromIndex ( const QModelIndex &  index) const

Retrieve the associated subject hierarchy item ID from a model index.

◆ subjectHierarchyNode()

Q_INVOKABLE vtkMRMLSubjectHierarchyNode* qMRMLSortFilterSubjectHierarchyProxyModel::subjectHierarchyNode ( ) const

◆ subjectHierarchySceneIndex()

Q_INVOKABLE QModelIndex qMRMLSortFilterSubjectHierarchyProxyModel::subjectHierarchySceneIndex ( ) const

Retrieve the index of the MRML scene (the root item) in the subject hierarchy tree.

Member Data Documentation

◆ d_ptr

QScopedPointer<qMRMLSortFilterSubjectHierarchyProxyModelPrivate> qMRMLSortFilterSubjectHierarchyProxyModel::d_ptr
protected

Definition at line 112 of file qMRMLSortFilterSubjectHierarchyProxyModel.h.


The documentation for this class was generated from the following file: