linuxmint/Cinnamon — pull request #723 by mtwebster (2012-06-06 02:03:30+00:00)
Title: Applet gravity

Add an extra setting in the gconf listing for applet positions -
a percentage value of the screen width. A slider for this becomes
available when panel edit mode is activated, in the context menu of
each applet. The user can slide the value (the full range of the
slider theoretically represents the width of the screen) and we apply
that much 'padding' to the 'pull' or gravity side of the applet.

This has the net effect of allowing you to position applets where you
want them along the panel, but creating padding in between applets
in a given panel location (left, right, middle) - note the padding is
reversed in the right zone, since gravity is reversed.

Things I sort of want to improve upon:

- make the slider invert for right-zone applets
- make the slider a bit smaller, so it doesn't kill the appearance
of the standard context menu
- Have applet padding reset when it's dragged to a different spot
- or... eliminate the slider altogether and integrate this seamlessly
into panel edit mode drag-n-drop. A bit of a taller order, but I
think this is a decent starting point.

I can keep working on it to iron out those things I noted, but I want to make sure there's an interest in this first, as it may affect existing applets somewhat (at least until they're updated) - if they've been messing with padding at all. It should not require any maintenance to the settings provider, it will simply default to 0 padding and then tag the new setting on the end the first time padding is used for a particular applet.

This was tested on UP3, and can be tried out simple by replacing the applet.js and appletManager.js files in your installation.

Thanks