Metafont Compiler

About the tool

Metafont is a programming language used to define fonts. It was created by Donald Knuth and is a companion to the TeX typesetting system.

A Metafont script describes the shape of a glyph (or multiple glyphs) as a collection of pen strokes. The cool thing about Metafont is that it is a programming language. You can use variables (parameters), loops, and conditionals to define the shape of a glyph. You can also describe the pen strokes declaratively in terms of their desired shape rather than explicitly list the commands to draw them. This allows you to create complex shapes that would be difficult to draw by hand.

To execute Metafont code, you usually need to install the Metafont interpreter on your computer (typically as part of the TeX distribution). To make it easier to experiment with Metafont, I've created this online tool that allows you to run Metafont code online and see the generated output.

P.S. A warning from Donald Knuth:

Demo

Input in the Metafont language.
Mode
The log will be displayed here when compilation starts.
Any generated files appear here.
Any generated glyph previews are displayed here.

See also

Made by Anton Vasetenkov.

If you want to say hi, you can reach me on LinkedIn or via email. If you like my work, you can support me by buying me a coffee.