home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!news.tek.com!tekig7!tekig1!brianr
- From: brianr@tekig1.PEN.TEK.COM (Brian E Rhodefer)
- Newsgroups: comp.sys.amiga.programmer
- Subject: Why redundant Font info in RastPort?
- Message-ID: <7992@tekig7.PEN.TEK.COM>
- Date: 17 Dec 92 19:14:30 GMT
- Sender: news@tekig7.PEN.TEK.COM
- Lines: 21
-
- I'm just a duffer Amiga programmer, so pardon me if I'm raking up the dead
- past. While concocting a simple "debate timer" program for one of our user
- group members, I bumped once more into the question of how to figure out the
- on-screen size of characters rendered in the current Font. The RastPort
- structure contains a pointer to the current Font, so the obvious authoritative
- source for the tf_Baseline, tf_YSize, and other related data seemed to be
- from the pointed-to Font structure. (Is this correct?)
-
- Then I noticed that the RastPort itself purportedly contains these same
- values, in identically-named fields. Does this mean that the SetFont
- subroutine is lumbered with the inefficiency of filling these redundant
- RastPort fields with copies of the corresponding values from the Font
- it's handed?
-
- Worse, do some programs actually USE the values from the RastPort structure?
-
-
- A detester of multiply-sourced "identical" data,
-
- Brian Rhodefer
-
-