A typesetting system with a statically typed functional language that compiles LaTeX-like document markup and custom commands into PDF.