Re: Resolution Independent View?
Re: Resolution Independent View?
- Subject: Re: Resolution Independent View?
- From: "Gerriet M. Denkmann" <email@hidden>
- Date: Wed, 13 May 2009 10:12:00 +0200
On 12 May 2009, at 16:33, Alastair Houghton <email@hidden
> wrote:
If, however, you really want the display to physically show a 5cm x
5cm block, you can obtain the screen's actual dimensions in
millimeters from CGDisplayScreenSize() and then use those numbers in
conjunction with the pixel dimensions to calculate a suitable
transform.
I just tried this on a white MacBook (1280 x 800 pixels).
I was told that my screen is 290 x 190 mm.
The I took a ruler and measured it and got: 286.208 x 178.88 (actually
I measured 286 x 179, but I doctored the numbers to make them look
better and produce square pixels 0.2236 mm wide).
I tried this before on different screens and always got answers which
were wrong and very boldly rounded to some centimeter.
So CGDisplayScreenSize does not return the actual screen size but the
size to be displayed in promotional brochures - as clearly indicated
by the function name (which is NOT CGActualScreenSize for a reason).
Kind regards,
Gerriet.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please 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