#include <QSplashScreen> QPixmap pixmap(":/Resources/login.png"); QSplashScreen splash(pixmap); splash.show(); //设置显示信息 splash.showMessage("程序初始化中...", Qt::AlignLeft | Qt::AlignBottom, QColor(255, 255, 255)); QWidget* w = new Widget(this); w->show(); splash.finish(w);//程序启动画面结束