plasmoid geometry event
Toussis Manolis
manolis at koppermind.homelinux.org
Sun May 25 12:30:43 CEST 2008
I have a plasmoid that is free-aspect-ratio when on desktop
but when it is on a panel , I want to have a 2.4 ratio
I tried this:
void PlasmaTvGr::constraintsEvent(Plasma::Constraints constrains)
{
if(formFactor()==Plasma::Planar)
{
setMinimumSize(80,48);
};
if(formFactor()==Plasma::Horizontal)
{
kDebug()<<"contsRecH:"<<geometry().height();
setMinimumSize(geometry().height()*2.4,geometry().height());
setMaximumSize(geometry().height()*2.4,geometry().height());
};
if(formFactor()==Plasma::Vertical)
{
};
calculateSizes(contentsRect().toRect());
updateGeometry();
}
but it ignores any geometry resize... any help?
More information about the Panel-devel
mailing list