Re: Points
Re: Points
- Subject: Re: Points
- From: Steve Christensen <email@hidden>
- Date: Sun, 8 Apr 2007 14:00:23 -0700
On Apr 8, 2007, at 1:26 PM, Ryan Brown wrote:
[[NSScreen mainScreen] frame] reports the resolution of the main
screen in points. Points are defined to be 1/72th of an inch. If my
resolution is 1680x1050, [[NSScreen mainScreen] frame] returns
(1680, 1050) and if my resolution (hypothetically) is 10x10 it
returns (10, 10). But how can this be so? 10 pixels are being
mapped onto to my 21" screen (making each pixel > 1in), so the
number returned by [[NSScreen mainScreen] frame] should be
significantly higher. Why isn't it? Is there some level of
abstraction I'm missing?
The documentation on Apple's website (http://developer.apple.com/
documentation/Cocoa/Reference/ApplicationKit/Classes/NSScreen_Class/
Reference/Reference.html#//apple_ref/occ/instm/NSScreen/frame) says
the following:
frame
Returns the dimensions and location of the receiver.
- (NSRect)frame
Return Value
The full screen rectangle at the current resolution. This rectangle
includes any space currently occupied by the menu bar and dock.
This suggests that we're talking pixels, not points.
steve
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
References: | |
| >Points (From: Ryan Brown <email@hidden>) |