The New PyKDE Sampler
Python is Goodness. KDE is Goodness. Put together, they become PyKDE, the Grand Supreme Goodness of desktop environment language bindings.
But there’s a grain of sand in the jelly. Between the three, there’s plenty of documentation but very little example code for PyKDE. Enter the new sampler application. Check it out:
The primary intent of the sampler app is to provide code examples. To that end, it displays the source code for every sample it renders. And for every sample displayed, it provides a relevent link to the PyKDE docs.
The secondary intent is to make writing samples easy. To realize this, I wrote the sampler application to introspect its directory for packages, and introspect those packages for modules (and subpackages). Every module found is imported and inspected for a handful of sampler-specific attributes. The values of those attributes are then used to control the placement and appearance of the sample module within the application. The net effect of this is that writing samples is as easy as writing stand-alone modules.
There isn’t a release yet, but there is a SVN repository. To get the code, run this in your nearest terminal:
svn checkout http://pykde-sampler.googlecode.com/svn/trunk/ pykde-sampler
Then start it:
python pykde-sampler/sampler.py
The sampler is far from complete, and you can help remedy that! The first step is to read the HOWTO. Then pick a KDE widget, write a module showing how it’s used and send it to me. I’ll be glad to include it in the repository and subsequent releases.