September 30, 2011

ahmed kato ahmed kato
Lab Rat
72 posts

connection between multiple widget in designer

 

hii all…i am doing an app of mine that include a dialog where there is 200 check boxes and one listwidget…so i need some method that i could connect when any checkbox is checked its name will be included in the list …thx in advance =)

 Signature 

Ahmed Kato
Computer & communications student
Intern and MSP at Microsoft

2 replies

September 30, 2011

mlong mlong
Robot Herder
1551 posts

You probably want to look at QSignalMapper [doc.qt.nokia.com]

 Signature 

Senior Software Engineer
AccuWeather Enterprise Solutions
/* My views and opinions do not necessarily reflect those of my employer.  Void where prohibited. */

October 2, 2011

Andre Andre
Robot Herder
6393 posts

Personally, I think that you need to re-think that UI. Sounds like hell to use a UI like that.

Why don’t you put the 200 items in a list view themselves? You do realize that list views can also display checkboxes, don’t you. That way, you can at least provide sorting and filtering on the list, so your users can actually find the items they need from it.

If you use a model-view approach to begin with, then displaying a list that only contains the items checked in the other list is trivial. You only need a QSortFilterProxyModel to filter on the checkstate role.

 
  ‹‹ setTabOrder problem      Auto adjust size (width) of QDockWidget ››

You must log in to post a reply. Not a member yet? Register here!