[Interest] QAbstractItemModel::headerData

Bill Crocker william.crocker at analog.com
Fri Nov 22 20:19:43 CET 2013


Gang:

I have created my own item model by sub-classing QAbstractItemModel.

Functions like rowCount take a parent index so the model
knows for which index it is being asked to return the count.
This is good.

My model is hierarchical and different points in the hierarchy
have a different number of rows and (especially) columns.

So, how come ::headerData is not passed an index so it knows for
which parent index it is being asked to return the data?

I'm using Qt 4.7.1

Bill




More information about the Interest mailing list