Re: [afp-renderer-developers] Funny looking constants in AFPFontReader
Brought to you by:
towny,
tumbarumba
From: Pete T. <pe...@to...> - 2004-11-13 09:35:24
|
Joe, They are not mixed up, the formula is as follows: (FO millipoints per inch) / (AFP dpi) * 1000 72000 / 240 * 1000 = 300000; 72000 / 300 * 1000 = 240000; Cheers, Pete. ----- Original Message ----- From: "Joe Schmetzer" <jo...@ex...> To: <afp...@li...> Sent: Friday, November 12, 2004 9:31 PM Subject: [afp-renderer-developers] Funny looking constants in AFPFontReader > The follow snippet of code was seen in AFPFontReader.java. Maybe there's > a logical explanation, but the constant names and the constant values > look suspiciously like they've been mixed up. Thoughts? > > Additionally, they have a naming convention that indicates that they are > constants, yet they are not final. > > Cheers, > Joe > > > /** > * The conversion factor to millipoints for 240 dpi > */ > private static int FOP_240_DPI_FACTOR = 300000; > > /** > * The conversion factor to millipoints for 300 dpi > */ > private static int FOP_300_DPI_FACTOR = 240000; > > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: > Sybase ASE Linux Express Edition - download now for FREE > LinuxWorld Reader's Choice Award Winner for best database on Linux. > http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click > _______________________________________________ > afp-renderer-developers mailing list > afp...@li... > https://lists.sourceforge.net/lists/listinfo/afp-renderer-developers |