[Qt-interest] Not sure which widgets to use

Scott Aron Bloom Scott.Bloom at sabgroup.com
Tue Sep 15 18:42:59 CEST 2009


QListView requires a model, you could use QStringModel
QListWidget is a QListView that has a QStandardItemModel, and does a lot of the work for you.  But you don’t have to maintain the model, only the data in and out of the ListWidget...
QListWidgetItem is the individual nodes of the QListWidget
QTextList is for QTextDocument.. not a standalone widget.

QListWidget should be good enough for you
Scott

-----Original Message-----
From: qt-interest-bounces at trolltech.com [mailto:qt-interest-bounces at trolltech.com] On Behalf Of Dan White
Sent: Tuesday, September 15, 2009 9:30 AM
To: Qt Mailing List
Subject: [Qt-interest] Not sure which widgets to use

I know what I want to do, but I am confuzzled as to which widgets to use.

I want a list of (words/short phrases)
The user should be able to insert and delete items
The user should be able to reorder items

Then the software should know how many items are in the list and be able to access them sequentially or randomly.

I have looked at QListView, QListWidget, QListWidgetItem, and QTextList and I have no idea which to use

Thanks.

“Sometimes I think the surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us.”
Bill Waterson (Calvin & Hobbes)

_______________________________________________
Qt-interest mailing list
Qt-interest at trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-interest




More information about the Qt-interest-old mailing list