Re: Calculating Desktop Icon Positions
Re: Calculating Desktop Icon Positions
- Subject: Re: Calculating Desktop Icon Positions
- From: Uli Kusterer <email@hidden>
- Date: Wed, 14 Jun 2006 19:07:56 +0200
Am 14.06.2006 um 17:43 schrieb dave miller:
And this will only work for cases where *one* monitor is connected.
How would you go about doing this when multiple monitors are
connected? I know the NSScreen class can return an array containing
information about the displays, but how one goes about correlating
the window position and the desktop icons to see if they match is
beyond me. This all depends on how the displays are positioned
relative to each other in System Preferences, etc.
All monitors are basically combined into one huge canvas. However,
the origin of desktop coordinates is always on the main screen. So,
it's always either at the top or bottom left of the screen. Just
treat all your coordinates as being on one huge main screen and
you'll correctly convert it. You only need to bother with the other
screens if you're positioning something to make sure they don't land
offscreen.
Cheers,
-- M. Uli Kusterer
http://www.zathras.de
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden