From: Robert K. <rk...@uc...> - 2004-10-27 03:57:51
|
John Hunter wrote: > Another idea I had while reading Knuth's "TeX: The Program" is to use > the layout information in the TFM font metric files. Apparently math > fonts have additional layout information in them, like where to place > superscripts. I've looked at several tfm parsing implementations, and > haven't found one yet that actually extracts this information; most > extract the standard font information but not the special math > information. But if we could access this info, we could include the > tfm files for common raster sizes and use the layout info crafted by > the master himself. Taking this as a challenge (and having little to do while waiting for images to process), I wrote a TFM parser that handles the extra parameters for math symbols. This format[1] is excruciatingly painful. http://starship.python.net/crew/kernr/tfm.py And then I realized that the output of tftopl(1) is incredibly easy to parse and contains the same information. <sigh> Either way, you now have the information you need for some fonts, at least. [1] http://www.ctan.org/tex-archive/dviware/driv-standard/level-0/dvistd0.pdf -- Robert Kern rk...@uc... "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard Harter |