[PyKDE] PyQt4 Questions
Detlev Offenbach
detlev at die-offenbachs.de
Sat Mar 18 13:42:35 GMT 2006
Hi,
I have a dialog, that creates a new dialog and shows it. The code is like
self.dlg = MyDialog(self)
dlg.show()
This code is part of a slot. Whenever this code is hit, a new dialog is
created with destroying the old one. I thought, that the garbage collector
should take care of deleting the old one.
Same thing happens with nonmodal dialogs spawned from the QMainWidget. When
closing the application, I have to close every single dialog, that was
displayed via the show() method, individually.
Additionally I have seen this strange behavior. If I create the dialog above
with self as a parent, the dialog containing the slot is put behind all other
windows.
Another observation is, that the newly generated dialog (using the above code)
is put centered on top of the generating dialog. I expected the window
manager to take care of the placement.
The last observation is, that the generating dialog is always behind the
generated dialog. I cannot bring it into the foreground.
What am I doing wrongly?
Detlev
--
Detlev Offenbach
detlev at die-offenbachs.de
More information about the PyQt
mailing list