Adam,
To start with your last question, the purpose of this is indeed to draw to an
accurate size. My background is in engineering, and there it is good practise
to draw accurately to scale.
Normally this is achieved by calibrating the screen: display a rectangle on the
screen, and ask to measure this rectangle with a ruler, and to return the measured
values to the application. I actually still could do this, but i erroneously
understood that the Graphics Get PPI function could take care of it.
If i get you right, if there is made reference to inches or millimeters with respect
to screen graphics, it is always about logical inches or millimeters, that have no
direct relation to the size they have in the real world. And even the physical screen
size, as returned by the GetDeviceCaps function is measured in logical millimeters,
although this is not stated :
GetDeviceCaps
HORZSIZE Width, in millimeters, of the physical screen.
VERTSIZE Height, in millimeters, of the physical screen.
HORZSIZE Width, in millimeters, of the physical screen.
VERTSIZE Height, in millimeters, of the physical screen.
If logical units are needed, that's fine, put please give them a different name.
Also, if the Graphic Get PPI function just returns the Windows DPI setting,
it would have helped a lot if the manual simply said that.
It's indeed a very confusing subject, thank you very much for clearing this up.
Thank you for your help.
Arie Verheul
Leave a comment: