[PyKDE] Re: Panel applets with PyKDE/Python

Jim Bublitz jbublitz at nwinternet.com
Tue Aug 19 03:11:18 BST 2003


On Monday August 18 2003 16:47, David Boddie wrote:
> Did you see the launchapplet.py script. I should have
> documented it, or at least draw attention to it, as it goes
> some way to dealing with this problem. When run by the support
> library, it tries to find a suitable applet based on the name
> of the configuration file suppled by kicker, or whatever
> mechanism is being invoked.

I'll go back and look at it (most of the good ideas I stole from 
you). The problem I see is that configFile is always:

    <libname> + _ + <random stuff> + _rc

and since <libname> never changes (there's only one .so lib for 
every Python panel applet), there's no way to tell what app to 
launch. The code for this is in the AppletInfo ctor in the 
kdebase src tarball (under kicker/ somewhere). The only way to 
get more names is to create more .so libs as far as I can see.

> > What I did is delegate the task - I filed a feature request
> > with KDE to change the way panel applets are specified
> > (.desktop file) and loaded, so that PyKDE can have a single
> > .so that will load any Python-based panel applet by having
> > an identifying field placed in the .desktop file for the
> > applet. It's only a very small code change, but of course
> > won't be available until the next KDE release if they agree
> > to make the change.

> Well, good luck with that!

I'm optimistic - some of the KDE guys are getting bugged about 
Python support by friends/other users, and this is really easy 
to implement - probably no more than 10 lines of code, no side 
effects, no compatibility problems.

> > In the meantime I'll clean up what I have, send a copy to
> > David for review and improvement, and maybe even document
> > it.

> Looking forward to it.

It'll be mostly for your reading enjoyment unfortunately.

> > If anyone is interested, I can post the KDE bug number and
> > you can all go to bugs.kde.org and vote for it.

> Could be interesting to do. Why not?!

It's bug 62859 - go to bugs.kde.com, vote early and vote often (I 
could end up governor of California if I get enough votes - I 
think that's how it works).

Jim




More information about the PyQt mailing list