January 14, 2011

Mohsen Mohsen
Lab Rat
685 posts

QTableView: How to get those few records that are visible to user?

 

I just wanna know if it’s possible to have only those few records which are visible to user in QTableView area. This gives possibility to take the process to its lowest state when i operate for only few items instead of too many records.

 Signature 

www.madagon.com

1 reply

January 14, 2011

Gerolf Gerolf
Hobby Entomologist
3251 posts

You could try QAbstractItemView::indexAt() for the top left corner and the bottom right corner.
I’m not sure whther rect() gives the correct indizes or if you have to ask the viewport for the coordinates, just try that out.

 Signature 

Nokia Certified Qt Specialist.
Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

 
  ‹‹ QTabWidget Background Color Doesn’t Change      [Moved] [Suggestion] Positive and negative lookbehind ››

You must log in to post a reply. Not a member yet? Register here!