PDA

View Full Version : Scrolling items in QTableView



steg90
8th May 2007, 13:04
Hi,

I'm trying to scroll items within a QTableView, at the moment I use the following :



QModelIndex index = m_ptreeModel->index( nCount, 0 );
ui.tableView->scrollTo( index );


Problem with this is that it seems very slow, is there any other way to do this?

Regards,
Steve

marcel
8th May 2007, 13:09
:) No it is not.
As I told you, it would be faster to determine if the index is visible, and then scroll to it only if it isn't.

Determining the visibility should be very fast... :)

steg90
8th May 2007, 13:59
Thanks again,

Still don't know how to find if the index is visible though!

Regards,
Steve