[PyKDE] QSettings

Detlev Offenbach detlev at die-offenbachs.de
Sat Mar 11 18:45:54 GMT 2006


The single instance method works quiet well in eric3. Maybe you get a copy of 
it and have a look at its Preferences system.

Detlev

Am Samstag, 11. März 2006 19:21 schrieb Fabian Steiner:
> Andreas Pakulat wrote:
> > On 11.03.06 16:55:25, Fabian Steiner wrote:
> >> How can I solve this problem? I thought of passing the current Config
> >> class instance to one of the Dialog constructor's arguments. Is there
> >> any better solution?
> >
> > Only create 1 instance of the class. Not sure if this works in python
> > but I would start like this:
> >
> > Config.py:
> >
> > configobj = Prefs()
> >
> > class Prefs:
> > ...
> >
> > then you can always use
> >
> > from Config import configobj
> >
> > and work with configobj.
> >
> > Andreas
>
> Unfortunately, this won't work. I always get the following error:
>
> "AttributeError: Preferences instance has no __call__ method"
>
> The orginal class "Prefs" was renamed to "Preferences" and the single
> instance is now called "Prefs".
> Any other ideas?
>
> Fabian
>
>
> _______________________________________________
> PyKDE mailing list    PyKDE at mats.imk.fraunhofer.de
> http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

-- 
Detlev Offenbach
detlev at die-offenbachs.de




More information about the PyQt mailing list