Hello,

I am trying to display a list view of all contacts in phone book within my app.I used QListWidget and ListWidgetItem to setup my List view. It works well, but if the list is very huge for example if the number of contacts is more than 200 or so, the list loads in around 4-5 secs, and during such time the app hangs. This approach is also bad i guess in terms of memory usage. Adding to the QlistWidget is via a for loop for all the items i have.

I need pointers to how to optimize it. I understand delegating listview is correct thing to do. Please correct me on the following.

1.) Can i use set a model for QListWidget, and use delegates for it.

2.) Each row in my list has a background,a button, and text field. I need to able to set these for each row. I think the delegates paint and size hint methods must be used.

2.) Setting the model for the list view. Do I need to inherit my data structure from the model classes and implement methods? I hope this is the starting point for setting a model.

In Cocoa-touch framework there is something called UITableViewDelegate and UITableViewCell e.t.c., in which the view just loads only visible rows. I am looking for something similar and hope QList MVC is similar.