[Panel-devel] Desktop applet: remember icons positions
Aaron J. Seigo
aseigo at kde.org
Fri Aug 10 12:51:47 CEST 2007
On Wednesday 08 August 2007, Matías Costa wrote:
> Hello list. My intention now is to provide icon position persistence. But
> before I'd like to seek people advice.
please look at how applet persistence is currently implemented. it's very
simple but pretty effective. i suppose you are, however, looking at how to
position items in the "desktop applet". personally, i think the desktop
applet is a design "bump". it shouldn't be one applet (that then has to
reimplemnt a bunch of stuff that's already there and try and stay "out of the
way" of the rest of plasma) but multiple applets whose state is maintained by
a single class that doesn't necessarily paint anything to screen.
essentially, the "desktop applet" really needs to simply call
Corona::addApplet() when they appear in the $DESKTOP_PATH or when new devices
are announced and remove them as appropriate (and respondt o the user
removing said items as well)
> [IconPosition::trash.desktop]
> Xabs=1203
> Xabs_1280x1024=1203
> Yabs=855
> Yabs_1280x1024=855
yeah, not sure that system is very pleasant. in fact, it's pretty fugly imho.
the real question is how to handle desktop resizes (which is the point of
keeping the res in the above example ini file, of course). it would probably
be enough to record the last seen res for the given layout (which may or may
not be the full screen (why that is the case is left as an exercise to the
reader ;)) and simply scale it down if it shrinks. we could scale up the
whitespace as well for extra bonus points. i don't think it is worth storing
N positions in a config file, one per pixel geometry, however.
--
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 Trolltech
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/panel-devel/attachments/20070810/73eec086/attachment.pgp
More information about the Panel-devel
mailing list