On Monday 25 August 2008 12:24:26 Petri Damstén wrote: > On Monday 25 August 2008 13:19:22 Alex Merry wrote: > > On Monday 25 August 2008 09:28:09 Petri Damstén wrote: > > > + workingGeom.translate(-desktop->screenGeometry(screen()).topLeft()); > > > > This is the same as workingGeom.setTopLeft(QPointF(0,0)). > > I thought that availableGeometry != screenGeometry so it's not always 0,0. > > > If you actually want it in containment co-ordinates, you should probably > > use mapFromScene(), and you need to do it even if there's no associated > > screen: > > Geometry for containment can be 2571,0,1280,1024 when screenGeometry for it > is 0,0,1280,1024, so mapFromScene won't return correct value in both cases?
Hmm. Yes, you're right in both cases. But I think you still need to correct the value returned by geometry() when we're not attached to a screen: If we have a containment at 2571,0,1280,1024, but not attached to a screen, it will try to lay out off the containment (I'm assuming the layout deals in containment co-ordinates, rather than scene co-ordinates). Alex -- Proud KDE hacker: http://www.kde.org Get KDE 4.1 - out now! Arch Linux: perfect for geeks like me - http://www.archlinux.org OpenSUSE: just works - http://www.opensuse.org
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Plasma-devel mailing list [email protected] https://mail.kde.org/mailman/listinfo/plasma-devel
