From fdab593c01964ff4e5bf6c7cc093b802d0a1bbf7 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Mon, 2 Apr 2012 22:15:57 +0200 Subject: Fix focus-rectangle issues Assure that the focus-rectangle exactly matches to the bottom of the rendered text. BUG: 297203 BUG: 289804 FIXED-IN: 4.9.0 --- src/kitemviews/kitemlistwidget.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/kitemviews/kitemlistwidget.h') diff --git a/src/kitemviews/kitemlistwidget.h b/src/kitemviews/kitemlistwidget.h index 66d96d449..4c8ff1a95 100644 --- a/src/kitemviews/kitemlistwidget.h +++ b/src/kitemviews/kitemlistwidget.h @@ -120,6 +120,15 @@ public: */ virtual QRectF textRect() const = 0; + /** + * @return Focus rectangle for indicating the current item. Per default + * textRect() will be returned. Overwrite this method if textRect() + * provides a larger rectangle than the actual text (e.g. to + * be aligned with the iconRect()). The textFocusRect() may not be + * outside the boundaries of textRect(). + */ + virtual QRectF textFocusRect() const; + /** * @return Rectangle for the selection-toggle that is used to select or deselect an item. * Per default an empty rectangle is returned which means that no selection-toggle -- cgit v1.3