[PyQt] QtGui.QSessionManager: Syntax

Phil Thompson phil at riverbankcomputing.co.uk
Fri Dec 14 08:55:36 GMT 2007


On Friday 14 December 2007, Chris Giles wrote:
> I want to use "QSessionManager" in my PyQt4 application, so that it will be
> reloaded when the user logs back into KDE.  I've tried all of the following
> without success.
>
>    - QtGui.QApplication.saveState ( QtGui.QSessionManager() )
>    - aMain.saveState( QtGui.QSessionManager() )
>    - smCurrent = QtGui.QSessionManager()
>
> The error message I receive in each case is as follows.
>
>    - TypeError: QtGui.QSessionManager cannot be instantiated or
>    sub-classed
>
> I searched on the web for this but found nothing of much use.  Can someone
> please explain how to use "QSessionManager" from within a PyQt4
> application?

http://doc.trolltech.com/4.3/session.html

Phil


More information about the PyQt mailing list