Item view for listing items.
More...
|
| DCategorizedView (QWidget *const parent=nullptr) |
|
virtual QModelIndexList | categorizedIndexesIn (const QRect &rect) const |
| This method will return all indexes whose visual rect intersects rect .
|
|
virtual QModelIndex | categoryAt (const QPoint &point) const |
| This method will return the first index of the category in the region of which point is found.
|
|
DCategoryDrawer * | categoryDrawer () const |
|
virtual QItemSelectionRange | categoryRange (const QModelIndex &index) const |
| This method returns the range of indexes contained in the category in which index is sorted.
|
|
virtual QRect | categoryVisualRect (const QModelIndex &index) const |
| This method will return the visual rect of the header of the category in which index is sorted.
|
|
QModelIndex | indexAt (const QPoint &point) const override |
|
void | setCategoryDrawer (DCategoryDrawer *categoryDrawer) |
|
void | setDrawDraggedItems (bool drawDraggedItems) |
| Switch on drawing of dragged items.
|
|
void | setGridSize (const QSize &size) |
|
void | setModel (QAbstractItemModel *model) override |
|
QRect | visualRect (const QModelIndex &index) const override |
|
|
void | currentChanged (const QModelIndex ¤t, const QModelIndex &previous) override |
|
void | rowsInserted (const QModelIndex &parent, int start, int end) override |
|
virtual void | rowsInsertedArtifficial (const QModelIndex &parent, int start, int end) |
|
virtual void | rowsRemoved (const QModelIndex &parent, int start, int end) |
|
virtual void | slotLayoutChanged () |
|
void | updateGeometries () override |
|
|
void | dragLeaveEvent (QDragLeaveEvent *event) override |
|
void | dragMoveEvent (QDragMoveEvent *event) override |
|
void | dropEvent (QDropEvent *event) override |
|
void | leaveEvent (QEvent *event) override |
|
void | mouseMoveEvent (QMouseEvent *event) override |
|
void | mousePressEvent (QMouseEvent *event) override |
|
void | mouseReleaseEvent (QMouseEvent *event) override |
|
QModelIndex | moveCursor (CursorAction cursorAction, Qt::KeyboardModifiers modifiers) override |
|
void | paintEvent (QPaintEvent *event) override |
|
void | resizeEvent (QResizeEvent *event) override |
|
void | setSelection (const QRect &rect, QItemSelectionModel::SelectionFlags flags) override |
|
void | startDrag (Qt::DropActions supportedActions) override |
|
DCategorizedView allows you to use it as it were a QListView. Subclass DCategorizedSortFilterProxyModel to provide category information for items.
◆ categorizedIndexesIn()
QModelIndexList Digikam::DCategorizedView::categorizedIndexesIn |
( |
const QRect & |
rect | ) |
const |
|
virtual |
- Parameters
-
rect | rectangle to test intersection with |
- Note
- Returns an empty list if the view is not categorized.
◆ categoryAt()
QModelIndex Digikam::DCategorizedView::categoryAt |
( |
const QPoint & |
point | ) |
const |
|
virtual |
- Note
- Returns QModelIndex() if the view is not categorized.
◆ categoryRange()
QItemSelectionRange Digikam::DCategorizedView::categoryRange |
( |
const QModelIndex & |
index | ) |
const |
|
virtual |
- Note
- Returns an empty range if the view is no categorized.
◆ categoryVisualRect()
QRect Digikam::DCategorizedView::categoryVisualRect |
( |
const QModelIndex & |
index | ) |
const |
|
virtual |
- Note
- Returns QRect() if the view is not categorized.
◆ setDrawDraggedItems()
void Digikam::DCategorizedView::setDrawDraggedItems |
( |
bool |
drawDraggedItems | ) |
|
Default: on. While dragging over the view, dragged items will be drawn transparently following the mouse cursor.
- Parameters
-
drawDraggedItems | if true , dragged items will be drawn |