ecce
12th April 2015, 09:41
Hi all,
I'm creating a small application using PySide. The application has a list to the left (QListView at the moment, fiddeling around a bit) and a QStackedWidget to the right. When I click an item in the list, the corresponding widget should be poped from the stack.
I'm stuck on connecting a click event in the list items. I've managed to make things happen if you check/uncheck a checkable QListView item, but I don't want the items to be checkable, just clicking on them should trigger the function.
What's a suitable widget to use as a list? QListView, QListWidget or something else? How do you connect the model properly to achieve this behaviour? Right now I only need one column, but having the option to use more in the future would be nice.
Cheers,
ecce
I'm creating a small application using PySide. The application has a list to the left (QListView at the moment, fiddeling around a bit) and a QStackedWidget to the right. When I click an item in the list, the corresponding widget should be poped from the stack.
I'm stuck on connecting a click event in the list items. I've managed to make things happen if you check/uncheck a checkable QListView item, but I don't want the items to be checkable, just clicking on them should trigger the function.
What's a suitable widget to use as a list? QListView, QListWidget or something else? How do you connect the model properly to achieve this behaviour? Right now I only need one column, but having the option to use more in the future would be nice.
Cheers,
ecce