Page 1 of 1

Dialog Units

Posted: Fri Aug 07, 2009 11:56 am
by ConvertFromOldNGs
by Iain S. Kerr >> Wed, 23 Aug 2000 3:42:30 GMT

Can anyone tell me how to convert Dialog units to pixels?

Paper & Form Margins are in dialog units whilst the freeformat printing requires pixels to be specified.

To ensure I can line up data correctly I need to be able to convert one to the other rather than using trial and error for each Form.

Thanks

Re: Dialog Units

Posted: Fri Aug 07, 2009 11:56 am
by ConvertFromOldNGs
by JADE Kid - Ray Hidayat >> Wed, 23 Aug 2000 9:56:19 GMT

If these dialog units are twips, which I think they are, then this bit of information might help.

There are 1440 twips per inch.

--
Ray Hidayat
JADE Kid - 2000
www.jadekids.com

Re: Dialog Units

Posted: Fri Aug 07, 2009 11:56 am
by ConvertFromOldNGs
by John Eyers >> Thu, 31 Aug 2000 21:22:05 GMT

A horizontal dialog base unit is one-quarter the average character width for the current system font, and a vertical dialog base unit is one-eighth the average character height for the current system font. I believe that a capital M is regarded as an average character in typography, so it should be possible to use the getTextExtent("M") and getTextHeight("M") methods to do the conversion?