

It is sometimes useful to update the splash screen with messages, for example, announcing connections established or modules loaded as the application starts up: QPixmap pixmap( ":/splash.png") Since the splash screen is typically displayed before the event loop has started running, it is necessary to periodically call QApplication::processEvents() to receive the mouse clicks. The user can hide the splash screen by clicking on it with the mouse. This is illustrated in the following code snippet in which a splash screen is displayed and some initialization tasks are performed before the application's main window is shown: int main( int argc, char *argv ) The most common usage is to show a splash screen before the main widget is displayed on the screen. A solution is to set up a timer that periodically calls raise() on the splash screen to simulate the "stays on top" effect. Some X11 window managers do not support the "stays on top" flag. It may be useful to add the Qt::WindowStaysOnTopHint to the splash widget's window flags if you want to keep it above all the other windows on the desktop. The splash screen appears in the center of the screen. database or networking applications that take time to establish connections) to provide the user with feedback that the application is loading. Splash screens are often used for applications that have long start up times (e.g. The QSplashScreen widget provides a splash screen that can be shown during application startup.Ī splash screen is a widget that is usually displayed when an application is being started. 1 protected slot inherited from QWidget.7 static public members inherited from QObject.4 static public members inherited from QWidget.1 protected function inherited from QPaintDevice.8 protected functions inherited from QObject.

37 protected functions inherited from QWidget.Reimplemented Protected Functions virtual bool MessageChanged ( const QString & message ) ShowMessage ( const QString & message, int alignment = Qt::AlignLeft, const QColor & color = Qt::black ) 13 public functions inherited from QPaintDevice.29 public functions inherited from QObject.221 public functions inherited from QWidget.QSplashScreen ( QWidget * parent, const QPixmap & pixmap = QPixmap(), Qt::WindowFlags f = 0 ) QSplashScreen ( const QPixmap & pixmap = QPixmap(), Qt::WindowFlags f = 0 ) List of all members, including inherited members.The QSplashScreen widget provides a splash screen that can be shown during application startup.
