From 517ebd721e12e3a4a3430ac3cba8ce99b33c5b0e Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Sun, 23 Oct 2011 21:30:40 +0200 Subject: Improve group-header layout - Apply a dynamic width - Use a height that depends on the style - Cleanup some interfaces and replace xxxBoundingRect() by xxxRect() --- src/kitemviews/kitemlistview.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/kitemviews/kitemlistview.h') diff --git a/src/kitemviews/kitemlistview.h b/src/kitemviews/kitemlistview.h index 985b7c278..fd2f286db 100644 --- a/src/kitemviews/kitemlistview.h +++ b/src/kitemviews/kitemlistview.h @@ -162,10 +162,10 @@ public: virtual QHash visibleRolesSizes(const KItemRangeList& itemRanges) const; /** - * @return The bounding rectangle of the item relative to the top/left of + * @return The rectangle of the item relative to the top/left of * the currently visible area (see KItemListView::offset()). */ - QRectF itemBoundingRect(int index) const; + QRectF itemRect(int index) const; /** * @return The number of items that can be shown in parallel for one offset. @@ -335,6 +335,13 @@ private: */ void updateGroupHeaderForWidget(KItemListWidget* widget); + /** + * Updates the position and size of the group-header that belongs + * to the itemlist widget \a widget. The given widget must represent + * the first item of a group. + */ + void updateGroupHeaderLayout(KItemListWidget* widget); + /** * Recycles the group-header from the widget. */ -- cgit v1.3.1