home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!ogicse!decwrl!netcomsv!mork!daveb
- From: daveb@netcom.com (Dave Briccetti)
- Newsgroups: comp.os.os2.programmer
- Subject: Re: OUTLINE FONT METRICS
- Message-ID: <t2km8fn.daveb@netcom.com>
- Date: 26 Jul 92 18:12:10 GMT
- Article-I.D.: netcom.t2km8fn.daveb
- References: <ddesroch.711989648@mailseq>
- Organization: Netcom - Online Communication Services (408 241-9760 guest)
- Lines: 25
-
- ddesroch@oracle.uucp (David DesRoches) writes:
- : OK, so I've chosen this really cool OUTLINE font that I want to scale to say,
- : 32 points. I compute the necessary character cell dimensions, call
- : GpiSetCharBox() and GpiSetCharSet() to select my new logical font.
- :
- : QUESTION: How do I get the metrics for this font AT THE SELECTED POINT SIZE?
- : Calling GpiQueryFontMetrics() at this point returns the same metrics structure
- : I got back from my initial font query, with metrics designed around a 12 point
- : font or so.
- :
- : My only current idea is to compute the ratio of logical.lMaxBaselineExt to
- : physical(base).lMaxBaselineExt and multiply the metrics by this ratio to
- : scale them (ascent, descent, maxwidth) to the point size I'm using. This
- : seems bogus and prone to round-off error.
- :
- : Am I missing something?
-
- That's the approach I'm using. If there is a better way, I'd like to
- know about it too.
- --
-
- Dave Briccetti, Owner, Dave Briccetti & Associates
- OS/2 Developer/Consultant
- P.O. Box 1713
- Lafayette, CA 94549-7013
-