Sophie

Sophie

distrib > * > 2009.0 > i586 > by-pkgid > a6711891ce757817bba854bf3f25205a > files > 2201

qtjambi-doc-4.3.3-3mdv2008.1.i586.rpm

<class name="QSplashScreen" doc="/**
&lt;p&gt;The &lt;a href=&quot;QSplashScreen.html#QSplashScreen(com.trolltech.qt.gui.QWidget, com.trolltech.qt.gui.QPixmap, com.trolltech.qt.core.Qt.WindowFlags)&quot;&gt;&lt;tt&gt;QSplashScreen&lt;/tt&gt;&lt;/a&gt; widget provides a splash screen that can be shown during application startup.&lt;/p&gt;
&lt;p&gt;A splash screen is a widget that is usually displayed when an application is being started. Splash screens are often used for applications that have long start up times (e.g&amp;#x2e; database or networking applications that take time to establish connections) to provide the user with feedback that the application is loading.&lt;/p&gt;
&lt;p&gt;The splash screen appears in the center of the screen. 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.&lt;/p&gt;
&lt;p&gt;Some X11 window managers do not support the &amp;quot;stays on top&amp;quot; flag. A solution is to set up a timer that periodically calls &lt;a href=&quot;QWidget.html#raise()&quot;&gt;&lt;tt&gt;raise&lt;/tt&gt;&lt;/a&gt; on the splash screen to simulate the &amp;quot;stays on top&amp;quot; effect.&lt;/p&gt;
&lt;p&gt;The most common usage is to show a splash screen before the main widget is displayed on the screen. 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:&lt;/p&gt;
&lt;pre&gt;    int main(int argc, char *argv[])
    {
        QApplication app(argc, argv);
        QPixmap pixmap(&amp;quot;:/splash.png&amp;quot;);
        QSplashScreen splash(pixmap);
        splash.show();
        app.processEvents();
        ...
        QMainWindow window;
        window.show();
        splash.finish(&amp;amp;window);
        return app.exec();
    }&lt;/pre&gt;
&lt;p&gt;The user can hide the splash screen by clicking on it with the mouse. 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.&lt;/p&gt;
&lt;p&gt;It is sometimes useful to update the splash screen with messages, for example, announcing connections established or modules loaded as the application starts up:&lt;/p&gt;
&lt;pre&gt;    QPixmap pixmap(&amp;quot;:/splash.png&amp;quot;);
    QSplashScreen *splash = new QSplashScreen(pixmap);
    splash-&amp;gt;show();

    ... &lt;span class=&quot;comment&quot;&gt;// Loading some items&lt;/span&gt;
    splash-&amp;gt;showMessage(&amp;quot;Loaded modules&amp;quot;);

    qApp-&amp;gt;processEvents();

    ... &lt;span class=&quot;comment&quot;&gt;// Establishing connections&lt;/span&gt;
    splash-&amp;gt;showMessage(&amp;quot;Established connections&amp;quot;);

    qApp-&amp;gt;processEvents();&lt;/pre&gt;
&lt;p&gt;&lt;a href=&quot;QSplashScreen.html#QSplashScreen(com.trolltech.qt.gui.QWidget, com.trolltech.qt.gui.QPixmap, com.trolltech.qt.core.Qt.WindowFlags)&quot;&gt;&lt;tt&gt;QSplashScreen&lt;/tt&gt;&lt;/a&gt; supports this with the &lt;a href=&quot;QSplashScreen.html#showMessage(java.lang.String, int, com.trolltech.qt.gui.QColor)&quot;&gt;&lt;tt&gt;showMessage&lt;/tt&gt;&lt;/a&gt; function. If you wish to do your own drawing you can get a pointer to the pixmap used in the splash screen with &lt;a href=&quot;QSplashScreen.html#pixmap()&quot;&gt;&lt;tt&gt;pixmap&lt;/tt&gt;&lt;/a&gt;. Alternatively, you can subclass &lt;a href=&quot;QSplashScreen.html#QSplashScreen(com.trolltech.qt.gui.QWidget, com.trolltech.qt.gui.QPixmap, com.trolltech.qt.core.Qt.WindowFlags)&quot;&gt;&lt;tt&gt;QSplashScreen&lt;/tt&gt;&lt;/a&gt; and reimplement &lt;a href=&quot;QSplashScreen.html#drawContents(com.trolltech.qt.gui.QPainter)&quot;&gt;&lt;tt&gt;drawContents&lt;/tt&gt;&lt;/a&gt;.&lt;/p&gt;
 */">
    <signal name="protected final void customContextMenuRequested(com.trolltech.qt.core.QPoint pos)" doc="/**
&lt;p&gt;This signal is emitted when the widget's &lt;a href=&quot;QWidget.html#contextMenuPolicy()&quot;&gt;&lt;tt&gt;contextMenuPolicy&lt;/tt&gt;&lt;/a&gt; is Qt::CustomContextMenu, and the user has requested a context menu on the widget. The position &lt;tt&gt;pos&lt;/tt&gt; is the position of the context menu event that the widget receives. Normally this is in widget coordinates. The exception to this rule is &lt;a href=&quot;QAbstractScrollArea.html&quot;&gt;&lt;tt&gt;QAbstractScrollArea&lt;/tt&gt;&lt;/a&gt; and its subclasses that map the context menu event to coordinates of the viewport()&lt;/tt&gt; .&lt;/p&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;b&gt;Compatible Slot Signatures:&lt;/b&gt;&lt;/dt&gt;
&lt;dd&gt;&lt;tt&gt;void mySlot(com.trolltech.qt.core.QPoint pos)&lt;/tt&gt;&lt;/dd&gt;
&lt;dd&gt;&lt;tt&gt;void mySlot()&lt;/tt&gt;&lt;/dd&gt;
&lt;/dl&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;b&gt;See Also:&lt;/b&gt;&lt;/dt&gt;
&lt;dd&gt;&lt;a href=&quot;QWidget.html#mapToGlobal(com.trolltech.qt.core.QPoint)&quot;&gt;&lt;tt&gt;mapToGlobal&lt;/tt&gt;&lt;/a&gt;, &lt;a href=&quot;QMenu.html&quot;&gt;&lt;tt&gt;QMenu&lt;/tt&gt;&lt;/a&gt;, &lt;a href=&quot;QWidget.html#contextMenuPolicy()&quot;&gt;&lt;tt&gt;contextMenuPolicy&lt;/tt&gt;&lt;/a&gt;&lt;/dd&gt;
&lt;/dl&gt;
 */"/>
    <signal name="protected final void messageChanged(java.lang.String message)" doc="/**
&lt;p&gt;This signal is emitted when the message on the splash screen changes. &lt;tt&gt;message&lt;/tt&gt; is the new message and is a null-string when the message has been removed.&lt;/p&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;b&gt;Compatible Slot Signatures:&lt;/b&gt;&lt;/dt&gt;
&lt;dd&gt;&lt;tt&gt;void mySlot(java.lang.String message)&lt;/tt&gt;&lt;/dd&gt;
&lt;dd&gt;&lt;tt&gt;void mySlot()&lt;/tt&gt;&lt;/dd&gt;
&lt;/dl&gt;
&lt;dl&gt;
&lt;dt&gt;&lt;b&gt;See Also:&lt;/b&gt;&lt;/dt&gt;
&lt;dd&gt;&lt;a href=&quot;QSplashScreen.html#showMessage(java.lang.String, int, com.trolltech.qt.gui.QColor)&quot;&gt;&lt;tt&gt;showMessage&lt;/tt&gt;&lt;/a&gt;, &lt;a href=&quot;QSplashScreen.html#clearMessage()&quot;&gt;&lt;tt&gt;clearMessage&lt;/tt&gt;&lt;/a&gt;&lt;/dd&gt;
&lt;/dl&gt;
 */"/>
    <method name="public QSplashScreen(com.trolltech.qt.gui.QPixmap pixmap, com.trolltech.qt.core.Qt.WindowFlags f)" doc="/**
&lt;p&gt;Construct a splash screen that will display the &lt;tt&gt;pixmap&lt;/tt&gt;.&lt;/p&gt;
&lt;p&gt;There should be no need to set the widget flags, &lt;tt&gt;f&lt;/tt&gt;, except perhaps Qt::WindowStaysOnTopHint.&lt;/p&gt;
 */"/>
    <method name="public QSplashScreen(com.trolltech.qt.gui.QPixmap pixmap)" doc="/**
&lt;p&gt;Equivalent to &lt;a href=&quot;QSplashScreen.html#QSplashScreen(com.trolltech.qt.gui.QWidget, com.trolltech.qt.gui.QPixmap, com.trolltech.qt.core.Qt.WindowFlags)&quot;&gt;&lt;tt&gt;QSplashScreen&lt;/tt&gt;&lt;/a&gt;(&lt;tt&gt;pixmap&lt;/tt&gt;, 0). */"/>
    <method name="public QSplashScreen()" doc="/**
&lt;p&gt;Equivalent to &lt;a href=&quot;QSplashScreen.html#QSplashScreen(com.trolltech.qt.gui.QWidget, com.trolltech.qt.gui.QPixmap, com.trolltech.qt.core.Qt.WindowFlags)&quot;&gt;&lt;tt&gt;QSplashScreen&lt;/tt&gt;&lt;/a&gt;(QPixmap(), 0). */"/>
    <method name="public QSplashScreen(com.trolltech.qt.gui.QWidget parent, com.trolltech.qt.gui.QPixmap pixmap, com.trolltech.qt.core.Qt.WindowFlags f)" doc="/**
&lt;p&gt;This function allows you to specify a parent for your splashscreen. The typical use for this constructor is if you have a multiple screens and prefer to have the splash screen on a different screen than your primary one. In that case pass the proper desktop() as the &lt;tt&gt;parent&lt;/tt&gt;.&lt;/p&gt;
 */"/>
    <method name="public QSplashScreen(com.trolltech.qt.gui.QWidget parent, com.trolltech.qt.gui.QPixmap pixmap)" doc="/**
&lt;p&gt;Equivalent to &lt;a href=&quot;QSplashScreen.html#QSplashScreen(com.trolltech.qt.gui.QWidget, com.trolltech.qt.gui.QPixmap, com.trolltech.qt.core.Qt.WindowFlags)&quot;&gt;&lt;tt&gt;QSplashScreen&lt;/tt&gt;&lt;/a&gt;(&lt;tt&gt;parent&lt;/tt&gt;, &lt;tt&gt;pixmap&lt;/tt&gt;, 0). */"/>
    <method name="public QSplashScreen(com.trolltech.qt.gui.QWidget parent)" doc="/**
&lt;p&gt;Equivalent to &lt;a href=&quot;QSplashScreen.html#QSplashScreen(com.trolltech.qt.gui.QWidget, com.trolltech.qt.gui.QPixmap, com.trolltech.qt.core.Qt.WindowFlags)&quot;&gt;&lt;tt&gt;QSplashScreen&lt;/tt&gt;&lt;/a&gt;(&lt;tt&gt;parent&lt;/tt&gt;, QPixmap(), 0). */"/>
    <method name="public final void clearMessage()" doc="/**
&lt;p&gt;Removes the message being displayed on the splash screen&lt;/p&gt;

@see &lt;a href=&quot;QSplashScreen.html#showMessage(java.lang.String, int, com.trolltech.qt.gui.QColor)&quot;&gt;&lt;tt&gt;showMessage&lt;/tt&gt;&lt;/a&gt; */"/>
    <method name="public final void finish(com.trolltech.qt.gui.QWidget w)" doc="/**
&lt;p&gt;Makes the splash screen wait until the widget &lt;tt&gt;w&lt;/tt&gt; is displayed before calling &lt;a href=&quot;QWidget.html#close()&quot;&gt;&lt;tt&gt;close&lt;/tt&gt;&lt;/a&gt; on itself.&lt;/p&gt;
 */"/>
    <method name="public final com.trolltech.qt.gui.QPixmap pixmap()" doc="/**
&lt;p&gt;Returns the pixmap that is used in the splash screen. The image does not have any of the text drawn by &lt;a href=&quot;QSplashScreen.html#showMessage(java.lang.String, int, com.trolltech.qt.gui.QColor)&quot;&gt;&lt;tt&gt;showMessage&lt;/tt&gt;&lt;/a&gt; calls.&lt;/p&gt;

@see &lt;a href=&quot;QSplashScreen.html#setPixmap(com.trolltech.qt.gui.QPixmap)&quot;&gt;&lt;tt&gt;setPixmap&lt;/tt&gt;&lt;/a&gt; */"/>
    <method name="public final void setPixmap(com.trolltech.qt.gui.QPixmap pixmap)" doc="/**
&lt;p&gt;Sets the pixmap that will be used as the splash screen's image to &lt;tt&gt;pixmap&lt;/tt&gt;.&lt;/p&gt;

@see &lt;a href=&quot;QSplashScreen.html#pixmap()&quot;&gt;&lt;tt&gt;pixmap&lt;/tt&gt;&lt;/a&gt; */"/>
    <method name="public final void showMessage(java.lang.String message, int alignment, com.trolltech.qt.gui.QColor color)" doc="/**
&lt;p&gt;Draws the &lt;tt&gt;message&lt;/tt&gt; text onto the splash screen with color &lt;tt&gt;color&lt;/tt&gt; and aligns the text according to the flags in &lt;tt&gt;alignment&lt;/tt&gt;.&lt;/p&gt;

@see Qt::Alignment&lt;/tt&gt;
@see &lt;a href=&quot;QSplashScreen.html#clearMessage()&quot;&gt;&lt;tt&gt;clearMessage&lt;/tt&gt;&lt;/a&gt; */"/>
    <method name="public final void showMessage(java.lang.String message, int alignment)" doc="/**
&lt;p&gt;Equivalent to &lt;a href=&quot;QSplashScreen.html#showMessage(java.lang.String, int, com.trolltech.qt.gui.QColor)&quot;&gt;&lt;tt&gt;showMessage&lt;/tt&gt;&lt;/a&gt;(&lt;tt&gt;message&lt;/tt&gt;, &lt;tt&gt;alignment&lt;/tt&gt;, Qt::black). */"/>
    <method name="public final void showMessage(java.lang.String message)" doc="/**
&lt;p&gt;Equivalent to &lt;a href=&quot;QSplashScreen.html#showMessage(java.lang.String, int, com.trolltech.qt.gui.QColor)&quot;&gt;&lt;tt&gt;showMessage&lt;/tt&gt;&lt;/a&gt;(&lt;tt&gt;message&lt;/tt&gt;, Qt::AlignLeft, Qt::black). */"/>
    <method name="protected void drawContents(com.trolltech.qt.gui.QPainter painter)" doc="/**
&lt;p&gt;Draw the contents of the splash screen using painter &lt;tt&gt;painter&lt;/tt&gt;. The default implementation draws the message passed by &lt;a href=&quot;QSplashScreen.html#showMessage(java.lang.String, int, com.trolltech.qt.gui.QColor)&quot;&gt;&lt;tt&gt;showMessage&lt;/tt&gt;&lt;/a&gt;. Reimplement this function if you want to do your own drawing on the splash screen.&lt;/p&gt;
 */"/>
    <method name="public boolean event(com.trolltech.qt.core.QEvent e)" doc="/**
&lt;p&gt;This function is reimplemented for internal reasons.&lt;/p&gt;
 */"/>
    <method name="protected void mousePressEvent(com.trolltech.qt.gui.QMouseEvent arg__1)" doc="/**
&lt;p&gt;This function is reimplemented for internal reasons.&lt;/p&gt;
 */"/>
</class>