home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 12 Font / 12-Font.zip / PFM2AFM.ZIP / pfm2afm.doc < prev    next >
Text File  |  1991-10-14  |  2KB  |  49 lines

  1. pfm2afm - Convert Windows pfm files to afm files for OS/2
  2.  
  3. Version 1.0 - 14 OCT 1991
  4. -------------------------
  5. This is the first version of this code.
  6.  
  7. What are pfm and afm files?
  8. ---------------------------
  9. The afm file is an Adobe Font Metrics file.  This is an ASCII flatfile
  10. giving the metrics for a type 1 font.  ATM on OS/2 requires this file
  11. to install a type 1 font.  It also requires the matching .pfb file
  12. which is the actual font.
  13.  
  14. The Windows pfm file is a Printer Font Metrics file.  This is a binary
  15. encoding of the metrics for a font.  OS/2 also keeps a pfm file for fonts,
  16. but it is different from the Windows pfm.  ATM for Windows will install
  17. a type 1 font if you have either the pfm file, or the afm and inf (Info)
  18. files.  (And of course you need the font itself).
  19.  
  20. Many fonts from outside vendors were shipped for Windows with the pfm
  21. files, but without the matching afm file.  This utility overcomes that
  22. problem.
  23.  
  24. Problems with pfm2afm:
  25. ----------------------
  26. When the pfm file is created, much of the information in the afm file
  27. is thrown away as unnecessary.  The major pieces which are lost are data
  28. for characters not in the Windows character set, and bounding boxes for
  29. all characters.  Also lost is the name of characters.  This is not a major
  30. problem for characters in the standard Windows encoding, but for other
  31. character sets (Symbol, Dingbats) the names are missing.  Another missing
  32. piece of data in the font FullName, which is what OS/2 uses.  However, it
  33. appears OS/2 picks this out of the font and not the afm file.
  34.  
  35. pfm2afm is able to reconstruct the character widths and kerning tables,
  36. which is the important metrics information.  The font bounding box is a
  37. pure guess based on other metrics.
  38.  
  39. The documentation for pfm files is a little sparse, so different vendors
  40. could interpret it in different ways.
  41.  
  42. Source
  43. ------
  44. The source for the utility is included in this package.  It is copyright
  45. IBM as a requirement of placing this code on the IBM internal tools disk.
  46.  
  47. Ken Borgendale
  48. kwb@betasvm2.vnet.ibm.com
  49.