StupidBeauty
Read times:1147Posted at:Mon Dec 26 16:31:22 2011
- no title specified

QT练习5:显示GIF图片

对于gif图片的显示,无论该图片是动态的,还是静态的,都可以用QMovie。

http://www.cnblogs.com/hnrainll/archive/2011/05/22/2053701.html

亮点:

#include "widget.h"

#include "ui_widget.h"

#include <QLabel>

#include <QMovie>

Widget::Widget(QWidget *parent) :

QWidget(parent),

ui( new Ui::Widget)

{

ui->setupUi( this );

QMovie *movie = new QMovie( "D:/Project/Qt/testclass/2.gif" );

ui->label->setMovie(movie);

movie->start();

}

Widget::~Widget()

{

delete ui;

}

Your opinions
Your name:Email:Website url:Opinion content:
- no title specified

HxLauncher: Launch Android applications by voice commands