PDA

View Full Version : Table Widget Vs. Table View



winston2020
19th October 2008, 04:30
I realise that Table View is "Model Based" and that Table Widget is "Item Based". But what does that actually boil down to? If I was using the table for realtime data (eg. a torrent app of some sort) which would be the better choice? Can I render a progress bar in the cells of both?

aamer4yu
19th October 2008, 08:23
You are right that table view is model based and table widget item based.
But internally tablewidget also uses its own model. Its useful when you dont have much to do with your data.
When data is large and needs some customization, table view is helpful.
analyse ur case, if u can use tablewidget, go for it. otherwise table view is there ;)

And you can render progress bar in both i guess. Tablewidget is derived from table view. and you will need to use delegates in this case.

One more thing. You cant set a new model in case of tablewidget

wysota
19th October 2008, 10:56
Tablewidget tends to be less scalable than tableview. If you can fit your data into one of the models already available in Qt, tableview should be a better choice. If you can't then it depends.