The art of setting text to KStatusNotifierItem

Aaron J. Seigo aseigo at
Wed Jun 2 18:57:35 BST 2010

On June 1, 2010, Andriy Rysin wrote:
> 1. Allow setting text to KStatusNotifierItem (and let it deal with picking
> appropriate font size, color etc) - architecturally nice solution and very
> nice for the client app, but keyboard layout indicator being the only
> customer for this I don't see this implemented (unfortunately for me)

it pushes the problem elsewhere, albeit where it can be solved once: into the 
system tray visualization. the text would still need to be halo'd.

my biggest concern is that we would end up with texts in various icons and 
we'd have a nasty jungle of icons and text that looks horrible and destroys 
any chance of spacing out an iconic representation nicely. (see the changes 
for the battery plasmoid in 4.5 when on a panel, for instance)

> 2. Drawing text halo, e.g black text with white halo - I tried quickly and
> could not find with a quick and reliable way to get the nice text: if you

look in kdelibs/plasma/paintutils.[h|cpp] and feel free to steal the code for 

> 3. "Cheat" by finding out (somehow) how to get the systray background and
> just set the text color to be "opposite"

impossible, since as Thomas noted you could be on a random wallpaper. remember 
that the system tray isn't even guaranteed to be in a panel these days ... it 
can sit quite happily on the desktop or in a dashboard.

Aaron J. Seigo
humru othro a kohnu se
GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA  EE75 D6B7 2EB1 A7F1 DB43

KDE core developer sponsored by Qt Development Frameworks
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <>

More information about the kde-core-devel mailing list