Hello,
        i have a QTableView with a QSortFilterProxyModel using a QSqlQueryModel 
as
source, in Qt 4.5 i execute after the query has populated the data of the table
resizeColumnsToContents() or resizeColumnToContent(int) and it get adjusted to
the column contents but in Qt 4.6 if i have not reimplemented the sizeHint method in
the delegate and i use the default QStyledItemDelegate.sizeHint method the col
get not resized correctly, you can see an example here:

http://img819.imageshack.us/img819/804/examplet.png

I have printed to console the output of the sizehint of the delegate for the
first visible col "SERIE" and row 0 and i get QSize(31, 15) in QT 4.6 and
QSize(31, 16) in QT 4.5 but when i print the size of the section from the
horizontal QHeaderView after the resize of the col i get 73 in Qt 4.6 and 46 in
Qt 4.5, this col it is ever of three chars in all the rows of the model, the 
same
three chars, so i don't understand why happens this difference, can anyone help
me with this? Thanks.

Regards,
Miguel Angel.
_______________________________________________
PyQt mailing list    [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to