3
votes

I have used LaTeX. I have used TexMacs.

What I want -- is to somehow be able to rip the "font/characters" out of MetaFont, and then arrange them myself (using an algorithm different from TeX).

This brings up the questions:

(1) what is the output format of MetaFont? (2) How can I get Tex/LaTeX/MetaFont to dump out all the math characters? (3) How can I get these math formulas represented as some type of vector graphics (i.e. curves), as well as the statistics on the charaters (baeline, width, height, ...)

Thanks!

1
The question may find better answers at tex.stackexchange.com. Could some moderator please move it?Paŭlo Ebermann
@Paŭlo Ebermann It's up to the author. @anon, would you like us to migrate this to a site devoted strictly to this topic? If so, please flag your question for moderator attention and let us know.Tim Post

1 Answers

3
votes

The output format of METAFONT is the generic font (gf) format. If you have a current TeX system installed, texdoc gftopk should give you the documentation of a converter from gf to the pk format finally used by most DVI processors, as well as pdftex (if they don't use TrueType or PostScript fonts instead). This manual contains a description of this format, too.

Instead of interpreting the GF format, you may think about interpreting the PK format instead, it is claimed to be "easier to convert into a raster representation" (and its description is in the same manual, too.)

If you don't want to do this conversion yourself, you can go one step further - there is as part of the netpbm bundle a program named pktopbm, which allows you converting individual characters of a font to bitmaps (other programs of this bundle allow you converting from pbm to any bitmap format you may wish for).

Additionally to the actual character bitmaps you would need the font metrics - TeX uses them in the TFM format, which is also output by metafont. Its format is described (as well as the other formats mentioned) in the document The DVI Driver Standard, Level 0, to be found on CTAN.

So, then you only need to look which fonts are math fonts, and here you go.