RecursiveSortFilterProxyModel Class Reference

This model filter source model as QSortFilterProxyModel to search an element in the hierachy. More...

#include <recursivesortfilterproxymodel.h>

Inheritance diagram for RecursiveSortFilterProxyModel:

List of all members.

Public Member Functions

 RecursiveSortFilterProxyModel (QObject *parent=0)
bool showAllChild () const
void setShowAllChild (bool value)
void setFilterRegExp (const QString &regExp)
void setHidePath (const QStringList &hidePath)
void setIncludeIndex (const QModelIndexList &indexes)
void setDisabledVisible (bool value)
bool disabledVisible () const

Protected Member Functions

virtual bool filterAcceptsRow (int source_row, const QModelIndex &source_parent) const
bool canBeShow (const QModelIndex &index) const
bool mustBeShow (const QModelIndex &index) const

Detailed Description

This model filter source model as QSortFilterProxyModel to search an element in the hierachy.

In a hierarchy, you can search an element by it's name. But if it's parrent don't have the same pattern, the index will not be found. This sub-class of QSortFilterProxyModel, will automatically show parent, if a child match the searching string. This model work only with filterRegExp().

This object can hide some path too, even if this path match the the searching string, or conversely, force to show a path.


Constructor & Destructor Documentation

RecursiveSortFilterProxyModel::RecursiveSortFilterProxyModel ( QObject parent = 0  )  [explicit]

Member Function Documentation

bool RecursiveSortFilterProxyModel::canBeShow ( const QModelIndex index  )  const [protected]
bool RecursiveSortFilterProxyModel::disabledVisible (  )  const
bool RecursiveSortFilterProxyModel::filterAcceptsRow ( int  source_row,
const QModelIndex source_parent 
) const [protected, virtual]
bool RecursiveSortFilterProxyModel::mustBeShow ( const QModelIndex index  )  const [protected]
void RecursiveSortFilterProxyModel::setDisabledVisible ( bool  value  ) 
void RecursiveSortFilterProxyModel::setFilterRegExp ( const QString regExp  ) 
void RecursiveSortFilterProxyModel::setHidePath ( const QStringList hidePath  ) 
void RecursiveSortFilterProxyModel::setIncludeIndex ( const QModelIndexList &  indexes  ) 
void RecursiveSortFilterProxyModel::setShowAllChild ( bool  value  ) 
bool RecursiveSortFilterProxyModel::showAllChild (  )  const