GIF image as background for QListWidget
Solved
General and Desktop
-
Hi Ratzz,
Thanks for replying, actually i have already tried the method which you have said.
In general we will use the QMovie to load a gif images and to see the actions that were present in the gif image but on using the setStylesheet i was unable to see the actions or animation moving that was present in the gif image i need to see the animation too when i apply the image as a background for QListWidget.Thanks in advance,
Rohith.G -
myMovie = new QMovie(":/images/icon_gif.gif"); movieLabel = new QLabel(this); movieLabel->setMovie(myMovie); myMovie->start(); listWidget = new QListWidget(this); listWidget->setViewMode(QListView::IconMode); listWidget->resize(800,600); QListWidgetItem *sample = new QListWidgetItem(); sample->setIcon(QIcon(":/images/shutdown.png")); sample->setText("Sample"); sample->setTextAlignment(Qt::AlignHCenter); listWidget->addItem(sample); listWidget->setItemWidget(sample,movieLabel);
I have tried in this manner Ratzz,please correct if there are any mistakes
Thanks in advance,
Rohith.G