digiKam Developer Documentation: Digikam::AbstractAlbumTreeViewSelectComboBox Class Reference

| digiKam Developer Documentation Professional Photo Management with the Power of Open Source

Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Digikam::AbstractAlbumTreeViewSelectComboBox Class Reference
Inheritance diagram for Digikam::AbstractAlbumTreeViewSelectComboBox:

## Public Member Functions
| AbstractAlbumTreeViewSelectComboBox (QWidget *const parent=nullptr)
| Abstract class.
void | addCheckUncheckContextMenuActions ()
| Enables a context menu which contains options to check or uncheck groups of albums, given you have a checkable model.
void | setTreeView (AbstractAlbumTreeView *const treeView)
| Set a tree view created by you instead of creating a default view (in the subclasses).
Public Member Functions inherited from Digikam::AlbumSelectComboBox
| AlbumSelectComboBox (QWidget *const parent=nullptr)
QSortFilterProxyModel * | filterModel () const
| Return the filter model in use.
bool | isCheckable () const
AbstractCheckableAlbumModel * | model () const
| Returns the source model.
void | setAlbumModels (AbstractCheckableAlbumModel *model, AlbumFilterModel *filterModel=nullptr)
void | setAllSelectedText (bool all)
| Enable or disable the text used to describe the status when all album is selected.
void | setCheckable (bool checkable)
| Enable checkboxes next to the items.
void | setCloseOnActivate (bool close)
| Enable closing when an item was activated (clicked).
void | setDefaultAlbumModel ()
| Once after creation, call one of these three methods.
void | setDefaultTagModel ()
void | setNoSelectionText (const QString &text)
| Sets the text that is used to describe the state when no album is selected.
void | setRecursive (bool recursive)
| If all subalbums shall be selected when parent will be selected.
void | setShowCheckStateSummary (bool show)
| If the box is checkable, enable showing a resume a la "3 Albums checked" in the combo box text.
Public Member Functions inherited from Digikam::TreeViewLineEditComboBox
| TreeViewLineEditComboBox (QWidget *const parent=nullptr)
| This class provides a TreeViewComboBox with a read-only line edit.
void | installView (QAbstractItemView *view=nullptr) override
| Replace the standard combo box list view with a QTreeView.
void | setLineEdit (QLineEdit *edit)
void | setLineEditText (const QString &text)
| Set the text of the line edit (the text that is visible if the popup is not opened).
Public Member Functions inherited from Digikam::TreeViewComboBox
| TreeViewComboBox (QWidget *parent=nullptr)
| This class provides a QComboBox with a QTreeView instead of the usual QListView.
virtual QTreeView * | view () const
| Returns the QTreeView of this class.
Public Member Functions inherited from Digikam::StayPoppedUpComboBox
| StayPoppedUpComboBox (QWidget *const parent=nullptr)
| This class provides an abstract QComboBox with a custom view (which is created by implementing subclasses) instead of the usual QListView.
Public Member Functions inherited from Digikam::ModelIndexBasedComboBox
| ModelIndexBasedComboBox (QWidget *const parent=nullptr)
| QComboBox has a current index based on a single integer.
QModelIndex | currentIndex () const
void | hidePopup () override
void | setCurrentIndex (const QModelIndex &index)
void | showPopup () override

## Protected Member Functions
void | installView (QAbstractItemView *view=nullptr) override
| Replace the standard combo box list view with a QTreeView.
void | sendViewportEventToView (QEvent *e) override
| Implement in subclass: Send the given event to the viewportEvent() method of m_view.
Protected Member Functions inherited from Digikam::AlbumSelectComboBox
void | installView (QAbstractItemView *view=nullptr) override
| Replace the standard combo box list view with a QTreeView.
Protected Member Functions inherited from Digikam::TreeViewLineEditComboBox
virtual void | installLineEdit ()
| Sets a line edit.
Protected Member Functions inherited from Digikam::TreeViewComboBox
void | sendViewportEventToView (QEvent *e) override
| Implement in subclass: Send the given event to the viewportEvent() method of m_view.
Protected Member Functions inherited from Digikam::StayPoppedUpComboBox
bool | eventFilter (QObject *watched, QEvent *event) override
void | installView (QAbstractItemView *view)
| Replace the standard combo box list view with the given view.

## Protected Attributes
AbstractAlbumTreeView * | m_treeView = nullptr
Protected Attributes inherited from Digikam::TreeViewLineEditComboBox
QLineEdit * | m_comboLineEdit = nullptr
Protected Attributes inherited from Digikam::StayPoppedUpComboBox
QAbstractItemView * | m_view = nullptr
Protected Attributes inherited from Digikam::ModelIndexBasedComboBox
QPersistentModelIndex | m_currentIndex

## Additional Inherited Members
Public Slots inherited from Digikam::AlbumSelectComboBox
void | hidePopup () override
virtual void | updateText ()
| Updates the text describing the selection ("3 Albums selected").

## Constructor & Destructor Documentation

## ◆ AbstractAlbumTreeViewSelectComboBox()

Digikam::AbstractAlbumTreeViewSelectComboBox::AbstractAlbumTreeViewSelectComboBox | ( | QWidget *const | parent = `nullptr` | ) |
| explicit

This is an AlbumSelectComboBox which installs an AlbumTreeView, not a plain QTreeView, as view.

## Member Function Documentation

## ◆ addCheckUncheckContextMenuActions()

void Digikam::AbstractAlbumTreeViewSelectComboBox::addCheckUncheckContextMenuActions | ( |  | ) |

Call this method after setModel().

## ◆ installView()

void Digikam::AbstractAlbumTreeViewSelectComboBox::installView | ( | QAbstractItemView * | view = `nullptr` | ) |
| overrideprotectedvirtual

Call this after installing an appropriate model.

Reimplemented from Digikam::TreeViewComboBox.

## ◆ sendViewportEventToView()

void Digikam::AbstractAlbumTreeViewSelectComboBox::sendViewportEventToView | ( | QEvent * | e | ) |
| overrideprotectedvirtual

This method is protected for a usual QAbstractItemView. You can override, pass a view, and call parent implementation. The existing view will be used. You must then also reimplement sendViewportEventToView.

Implements Digikam::StayPoppedUpComboBox.

## ◆ setTreeView()

void Digikam::AbstractAlbumTreeViewSelectComboBox::setTreeView | ( | AbstractAlbumTreeView *const | treeView | ) |

Only takes effect before calling setModel.