March 16, 2012

bright day bright day
Lab Rat
10 posts

how to animate expanding of QListWidgetItem?


I have QListWidget, and each item has its own widget (e.g. _listWidget->setItemWidget(itm,lbl)). how can I animate expanding of QListWidgetItem when one is selected?

this, of course, doesn’t work, because QListWidgetItem doesn’t inherit QWidget

  1. QListWidgetItem * itm = new QListWidgetItem; ...
  2. QPropertyAnimation * anim = new QPropertyAnimation(itm,"sizeHint",this);
  3. ...
  4. anim->start();

0 replies

  ‹‹ QTextStream and file.tar.gz      Idiomatic model/view binding for non-tabular data ››

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