How can I be informed if an item is added to my QListWidget?
A very simple example: PyQt4.QtGui import from * Import Sys app = QApplication (sys.argv) to listWidget = I in category for QListWidget (): Item = QListWidgetItem ("item% i"% i) listWidget.addItem (item) # ^^^ What do I want to do to control the
addItem
event?
You have to capture the contained object object in the widget :
model = ListWidget.model ()
has a identification of rows
that you can connect to .
No comments:
Post a Comment