[PyKDE] Custom MessageBox - simulating QMessageBox.warning

Henry Kleynhans henry at obsidian.co.za
Thu Jul 3 15:02:01 BST 2003


Hi Peter,

Thanks for the help.

Kind regards,

Henry

On Thursday 03 July 2003 14:29, Peter Osborne wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> You just need to pass in the modal = 1 flag when you subclass, and then
> when you call your dilaog, use exec_loop() instead of show().
>
> class configoptions(configoptionsui):
>
> 	def __init__(self, parent=""):
> 		configoptionsui.__init__(self,parent = None,name = None,modal = 1,fl = 0)
>
> options = configoptions()
> if options.exec_loop():
> 	print "Success!"
>
> Pete
>
> On July 3, 2003 07:43 am, Henry Kleynhans wrote:
> > Hi All,
> >
> > I think this might be a silly question.  I am trying to create a custom
> > message box without subclassing/using QMessageBox.  I would like to know
> > how to get the messagebox shown in a way that blocks execution in my
> > program so that I can get the results from the messagebox.  I can show
> > the messagebox in a modal fashion, but the show() method does not block
> > execution, hence I'm not too sure on how to create a message box that
> > would work the same as the static QMessageBox.warning() method.
> >
> > Kind regards,
> >
> > Henry
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.2.2 (GNU/Linux)
>
> iD8DBQE/BCG3u9OyE9DhLmERAnXXAKCUKN9qXCQdnWd7v9WaU/jqtc+T2QCeMx/X
> vwh5wXSRNQgzqOoh1r8VXVQ=
> =3E8+
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> PyKDE mailing list    PyKDE at mats.imk.fraunhofer.de
> http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

-- 
Henry Kleynhans <henry at obsidian.co.za>
Obsidian Systems




More information about the PyQt mailing list