Clone wiki

plasma-test / Home

What's this

A barebone Python-powered plasmoid for KDE 4.2.1+.


I couldn't find any working example of Python-powered Plasma widgets. All existing tutorials were out of date and didn't work under KDE 4.2.1. So I took and compared it with some python plasmoids that came with Kubuntu 9.04. After some experiments I finally had some working code. Then I stripped the script to the bones. Fork and enjoy ;-)


Get the code:

$ hg clone

Install the plasmoid:

$ plasmapkg -i plasma-test/

Test the installed plasmoid in a separate window:

$ plasmoidviewer plasma-test

(If something goes wrong at this point, please ensure your KDE is 4.2.1 or newer; if it is, please file a bug!)

You can edit the installed code directly (in $HOME/.kde/share/apps/plasma/plasmoids/plasma-test) and execute the above-mentioned command to see whether your customized plasmoid works at all.

However, if you would like the Plasma workspace to refresh its knowledge about plasmoid's metadata, you would prefer editing the code elsewhere and reinstall ("update") it each time:

$ plasmapkg -u plasma-test/
Successfully removed plasma-test
Successfully installed /home/john/devel/plasma-test

To pack the plasmoid for distribution, just zip it:

$ zip -r plasma-test/*

The zipped package can be installed directly, without unpacking:

$ plasmapkg -i

To uninstall ("remove") the plasmoid:

$ plasmapkg -r plasma-test