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

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

## Public Member Functions
| ItemCategoryDrawer (ItemCategorizedView *const parent)
int | categoryHeight (const QModelIndex &index, const QStyleOption &option) const override
void | drawCategory (const QModelIndex &index, int sortRole, const QStyleOption &option, QPainter *painter) const override
| This method purpose is to draw a category represented by the given.
void | invalidatePaintingCache ()
virtual int | maximumHeight () const
void | setDefaultViewOptions (const QStyleOptionViewItem &option)
void | setLowerSpacing (int spacing)
Public Member Functions inherited from Digikam::DCategoryDrawer
| DCategoryDrawer (DCategorizedView *const view)
| Construct a category drawer for a given view.
virtual int | leftMargin () const
virtual int | rightMargin () const
DCategorizedView * | view () const

## Additional Inherited Members
Signals inherited from Digikam::DCategoryDrawer
void | actionRequested (int action, const QModelIndex &index)
| Emit this signal on your subclass implementation to notify that something happened.
void | collapseOrExpandClicked (const QModelIndex &index)
| This signal becomes emitted when collapse or expand has been clicked.
Protected Member Functions inherited from Digikam::DCategoryDrawer
virtual void | mouseButtonDoubleClicked (const QModelIndex &index, const QRect &blockRect, QMouseEvent *event)
| Method called when the mouse button has been double clicked.
virtual void | mouseButtonPressed (const QModelIndex &index, const QRect &blockRect, QMouseEvent *event)
| Method called when the mouse button has been pressed.
virtual void | mouseButtonReleased (const QModelIndex &index, const QRect &blockRect, QMouseEvent *event)
| Method called when the mouse button has been released.
virtual void | mouseLeft (const QModelIndex &index, const QRect &blockRect)
| Method called when the mouse button has left this block.
virtual void | mouseMoved (const QModelIndex &index, const QRect &blockRect, QMouseEvent *event)
| Method called when the mouse has been moved.

## Member Function Documentation

## ◆ categoryHeight()

int Digikam::ItemCategoryDrawer::categoryHeight | ( | const QModelIndex & | index,
|  | const QStyleOption & | option
| ) |  | const
| override virtual

Returns
  The category height for the category represented by index `index` with style options `option`.

Reimplemented from Digikam::DCategoryDrawer.

## ◆ drawCategory()

void Digikam::ItemCategoryDrawer::drawCategory | ( | const QModelIndex & | index,
|  | int | sortRole,
|  | const QStyleOption & | option,
|  | QPainter * | painter
| ) |  | const
| override virtual

Parameters

  index | The index with the given
  sortRole | The sorting role
  option | The painter style options
  painter | The painter instance

Note
  This method will be called one time per category, always with the first element in that category

Reimplemented from Digikam::DCategoryDrawer.