projetmbc | 3 Oct 12:03
Favicon

Splash Screen

Hello,

I would to know how to do a Splash Screen with PyQT.

<div>
<p>Hello,</p>
<p>I would to know how to do a Splash Screen with PyQT.</p>
</div>
Benno Dielmann | 3 Oct 13:13

Re: Splash Screen

On Friday 03 October 2008 12:04:49 projetmbc <at> club-internet.fr wrote:
| Hello,
| I would to know how to do a Splash Screen with PyQT.

Create some window (e.g. a QWidget) and call

setWindowFlags(Qt.FramelessWindowHint)

on it. 

Regards, 

Benno Dielmann. 
Detlev Offenbach | 3 Oct 13:35
Favicon

Re: Splash Screen

On Freitag, 3. Oktober 2008, Benno Dielmann wrote:
> On Friday 03 October 2008 12:04:49 projetmbc <at> club-internet.fr wrote:
> | Hello,
> | I would to know how to do a Splash Screen with PyQT.
>
> Create some window (e.g. a QWidget) and call
>
> setWindowFlags(Qt.FramelessWindowHint)
>
> on it.
>

Or just use QSplashScreen.

Detlev
--

-- 
Detlev Offenbach
detlev <at> die-offenbachs.de
V. Armando Sole | 3 Oct 13:43

Re: Splash Screen

At 13:13 03/10/2008 +0200, Benno Dielmann wrote:
>On Friday 03 October 2008 12:04:49 projetmbc <at> club-internet.fr wrote:
>| Hello,
>| I would to know how to do a Splash Screen with PyQT.
>
>Create some window (e.g. a QWidget) and call
>
>setWindowFlags(Qt.FramelessWindowHint)
>
>on it.
>
>Regards,
>
>Benno Dielmann.

What about using the QSplashScreen class?

Armando 

David Douard | 6 Oct 10:57
Favicon

Re: Splash Screen

Le Friday 03 October 2008 12:04:49 projetmbc <at> club-internet.fr, vous avez 
écrit :
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
> <html>
> <head>
> <meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
> <title>Flashmail</title>
> <style type="text/css">
> BODY, TABLE, TR, TD, P {margin:0;padding:0;}
> BODY {background:#FFFFFF;}
> </style>
> </head>
> <body>
> <P>Hello,</P>
> <P>I would to know how to do a Splash Screen with PyQT.</P></body></html>

First, please use plain text format when sending messages to this 
mailing-list.

Now, for your problem, here is an example:

	# make proper imports
	app = QApplication([])
        pixmap = QPixmap(":/images/splashscreen.png")
        splash = QSplashScreen(pixmap, Qt.WindowStaysOnTopHint)
        splash.setMask(pixmap.mask()) # this is usefull if the splashscreen is 
not a regular ractangle...
        splash.show()
        splash.showMessage(_(u'Starting...'), Qt.AlignRight | Qt.AlignBottom, 
Qt.yellow)
        # make sure Qt really display the splash screen 
        app.processEvents()

	# start tha main app window
	mainwindow = ...
	# ...
	# now kill the splashscreen
	splash.finish(mainwindow)

-- 
David Douard                        LOGILAB, Paris (France), +33 1 45 32 03 12
Formations Python, Zope, Debian :   http://www.logilab.fr/formations
Développement logiciel sur mesure : http://www.logilab.fr/services
Informatique scientifique :         http://www.logilab.fr/science
Le Friday 03 October 2008 12:04:49 projetmbc <at> club-internet.fr, vous avez 
écrit :
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
> <html>
> <head>
> <meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
> <title>Flashmail</title>
> <style type="text/css">
> BODY, TABLE, TR, TD, P {margin:0;padding:0;}
> BODY {background:#FFFFFF;}
> </style>
> </head>
> <body>
> <P>Hello,</P>
> <P>I would to know how to do a Splash Screen with PyQT.</P></body></html>

First, please use plain text format when sending messages to this 
mailing-list.

Now, for your problem, here is an example:

	# make proper imports
	app = QApplication([])
        pixmap = QPixmap(":/images/splashscreen.png")
        splash = QSplashScreen(pixmap, Qt.WindowStaysOnTopHint)
        splash.setMask(pixmap.mask()) # this is usefull if the splashscreen is 
not a regular ractangle...
        splash.show()
        splash.showMessage(_(u'Starting...'), Qt.AlignRight | Qt.AlignBottom, 
Qt.yellow)
        # make sure Qt really display the splash screen 
        app.processEvents()

	# start tha main app window
	mainwindow = ...
	# ...
	# now kill the splashscreen
	splash.finish(mainwindow)

--

-- 
David Douard                        LOGILAB, Paris (France), +33 1 45 32 03 12
Formations Python, Zope, Debian :   http://www.logilab.fr/formations
Développement logiciel sur mesure : http://www.logilab.fr/services
Informatique scientifique :         http://www.logilab.fr/science

Gmane