Qt-interest Archive, April 2007
Checkable QListWidgetItem
Message 1 in thread
Hi,
I'm trying to insert checkable items:
QListWidgetItem* item = new QListWidgetItem(string, qListWidget);
item->setFlags(Qt::ItemIsEnabled
| Qt::ItemIsSelectable
| Qt::ItemIsUserCheckable);
I can't make the item to be checkable.
Am I missunderstanding the API?
Paulo
--
[ signature omitted ]
Message 2 in thread
> I can't make the item to be checkable.
>
> Am I missunderstanding the API?
Hi
One must also initialize the check state. See QListWidgetItem::setCheckState().
--
[ signature omitted ]