Smarter desktop applet placement

Ambroz Bizjak ambro at b4ever.net
Sat Aug 9 01:02:15 CEST 2008


Hi,

I have now written some code for a QGraphicsLayout for the desktop. It
does some simple position management of the applets on the desktop. First
is the placing of new applets, which uses the same code I have written
before. Second is handling screen size changes. It works somehow similar
to the way KDE3 does with desktop icons:
Every applet has, apart from the current position, a "preferred position".
The applet is placed as close to the preferred position as the screen size
allows. When the screen size decreases, an applet that would reach over
the edge is moved, however its preferred position stays the same. The
preferred position is only updated when the user moves an applet to a new
place. This allows the user to temporarily decrease the resolution and be
able to see all the applets, while the applets are still placed back to
their original positions when the resolution is restored.

Currently, when the resolution decreases, affected applets are simply
moved so they stay visible, possibly colliding with other applets. I am
planning to make this smarter, so that those applets will be moved as
well.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: plasma-placement-layout1.patch
Type: application/octet-stream
Size: 36694 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/plasma-devel/attachments/20080809/50765e22/attachment-0001.obj 


More information about the Plasma-devel mailing list