[Icon Plasmoid] Provide a generic plasmoid class for icon based plasmoid
Loïc Marteau
loic.marteau at gmail.com
Tue Jun 3 00:57:30 CEST 2008
Hi all
Here is the patch I made for IconApplet in order to use this
implementation.
This patch need reviews and *correction* as i'm not sure i have done the
right thing about constraintsEvent.
The result is that .desktop icon plasmoids take less width place in the
panel.
In fact i have some question :
1) in void IconApplet::constraintsEvent(Plasma::Constraints constraints)
the first line is
setBackgroundHints(NoBackground);
is this really needed each time we call constraintsEvent as it is
already done in the constructor ?
2) When plasmoid is in the panel i call
setAspectRatioMode(Plasma::Square) to let plasma:square related code do
the stuff with size constraint
is there a way to unset this in Desktop mode bracket (formFactor() ==
Plasma::Planar || formFactor() == Plasma::MediaCenter)
3) Should i call a resize() (and with witch parameter ?) after the call
setAspectRatioMode(Plasma::Square) in constraintevent method ?
4) Is there issue with this code ?
Thanks and cheers !
PS : according to what we said in the thread the idea is to provide a
common simple and correct way to implement size constraints stuff in all
icon based plasmoid.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: icon_iconplasmoid.patch
Type: text/x-diff
Size: 1561 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/panel-devel/attachments/20080603/e12430e4/attachment.bin
More information about the Panel-devel
mailing list