How to use the code to set item's state activated ?
Hi, Thanks and regards advance!
When i use the
QListWidget, i saw the document and found the following
[signal] void QListWidget::itemActivated(QListWidgetItem *item)
This signal is emitted when the item is activated. The item is activated when the user clicks or double clicks on it, depending on the system configuration. It is also activated when the user presses the activation key (on Windows and X11 this is the Return key, on Mac OS X it is Command+O).
It says the user can make item to activated by clicks or double clicks ...
Now, I want to use the code to set one item activated. but, I found nothing, there isn't one set_function to set it. like the following function
How to use code to set item activated ? and what's state of item is Activated?
Sets the current item to item. Unless the selection mode is NoSelection, the item is also selected.
Thanks, But it is wrong way! I tried.
setCurrentItemisn't emitted the
itemActivatedsignal. I want to use the code to set item activated and then emit the
And i want to know, is there another way to emit the
itemActivatedsignal but users clicks or double clicks...
Like you already saw, the conditions for itemActivated to be generate are explained in the signal's documentation.
Are you trying to trigger the edition of that item ?