Qt-interest Archive, October 2007
Re: QStyle and QListView / QTableView
Message 1 in thread
Sven Flossmann wrote:
> Hi all,
>
> I would like to display a customized background for the rows in a
> QListView / QTableView. This background shall not only be a simple color
> but a specific "frame" (= a pixmap that depends on the rows width and
> height). (Otherwise it would be to simple ;) )
>
Have you seen QItemDelegate and its virtual functions drawBackground and
drawDisplay?
Implementing it using QStyle has a good advantage that you can make this
background appear on all your QListView's and QTableView's in a single
shot. Unfortunately, as it stands, the item views are not very
customizable using the QStyle API.
Girish
--
[ signature omitted ]