Introduction
What mLaTeX is, what it reads, and what it does differently.
mLaTeX (Modernized LaTeX) is a LaTeX typesetter written from scratch in C++. It reads LaTeX documents as people already write them and turns them into PDF with a single program: no TeX distribution, no format files, no package tree on disk and no auxiliary files between runs.
mlatex paper.texThis is mLaTeX 0.1.0.
paper.tex
Output written on paper.pdf (11 pages, 423273 bytes).The language is the same. The machinery underneath is new: the lexer, the macro expander, the parser, the line breaker, the page builder, the font shaper and the PDF writer are one program, and the work LaTeX does with thousands of lines of TeX macros is done once, in compiled code.
What it reads
LaTeX as written
509 packages and 14 document classes, each checked by a sample document of its own, plus a glossary of about 630 commands from packages that have no module of their own. An unknown package is a warning, not a failed build.
The parts people use
Mathematics, tables, floats, cross-references, tables of contents, indexes, hyperref links and bookmarks, TikZ and pgfplots, tikz-cd and xy-pic diagrams, beamer slides with overlays and themes, BibTeX bibliographies in the standard, natbib and biblatex styles, right-to-left and CJK text, and PNG, JPEG, WebP, PDF, EPS and SVG pictures.
TeX itself
Category codes, \def and \edef, \csname, \expandafter, the \if family, registers and e-TeX's expressions work as TeX's do, so a preamble's own macros run unchanged.
What it does differently
One run
Cross-references, page numbers and the table of contents are resolved in a second pass in memory, so there is no .aux file and no need to run the program twice.
No separate tools
Bibliographies are read straight from .bib files and indexes are sorted by mLaTeX, so there is no BibTeX, Biber or makeindex step.
Packages are compiled in
Packages are written in mLaTeX's own language and compiled into the program. .sty and .cls files are never read from disk.
Safe by design
A document cannot run programs (\write18 does not exist), cannot write files, and can only read from its own folder and the folders you allow. See Security.
Fast
A one-page article is set in a few milliseconds, and an eleven-page paper with a bibliography, two passes included, in under 30 ms. See Performance.
Where to go next
Installation
Build mLaTeX from source, or install a package for your system.
Basic Usage
Write a first document and turn it into a PDF.
Migrating from LaTeX
What compiles unchanged, and the few things to adapt.
Guides
Documents, text, mathematics, tables, pictures, references and slides, command by command.
Supported Packages
Every package and class mLaTeX reads, and how.
Reference
A page for each package: how to load it, its commands and an example.
Embedding
Make documents from C++, C, Python or JavaScript.
mLaTeX is pre-release software, version 0.1. The aot target, which writes the PDF directly, is complete. The command line's jit target is accepted but not implemented yet. WebAssembly is not a target of the command line but a build of mLaTeX itself, for browsers and Node.