news2mail.com

HomeComp › Text

comp.text.tex

TeX, LaTeX and friends.

The working group of the TeX world: macro debugging, font sorcery (Metafont to Type 1 and beyond), package announcements and typographic doctrine, with many principals of the TeX community posting directly.

Its answers migrated into FAQs, then into StackExchange — but the originals were argued out here first.

Long-form reference · 3,955 words · about a 17-minute read

The galley proofs of 1977

The system this group existed to discuss began with a disappointment that can be dated to the day. The first volume of Donald Knuth’s The Art of Computer Programming had been set in hot metal on a Monotype machine in 1968, in a style Knuth admired; when a second edition was prepared in 1976 that technology had given way to phototypesetting and the original fonts were gone, so the whole book had to be set again. Knuth received the galley proofs of the new setting on 30 March 1977 and found them inferior. On 13 May 1977 he wrote himself a memo describing the basic features of a typesetting system of his own, to be finished during his sabbatical the following year. The result was TeX.

The first version, TeX78, was written in the SAIL language for a PDP-10 under Stanford’s WAITS operating system. Guy Steele was at Stanford in the summer of 1978, while Knuth was building it, and on returning to the Massachusetts Institute of Technology in the autumn he rewrote TeX’s input and output to run under the Incompatible Timesharing System. Portability was thus part of the program’s life from the first year, and TeX has since been carried to nearly every operating system.

Typesetting needs type, and Knuth had begun on the fonts in 1977 as well. Metafont is a description language for raster fonts, with an interpreter that turns those descriptions into bitmap fonts at a chosen resolution; the first version appeared in 1979, and limitations in the original language led Knuth to redesign it completely in 1984. Pairing a typesetter that knows only the dimensions of its characters with a separate program that draws them is why the font question in TeX was never a side issue but a permanent department of the subject.

A single thick black closed stroke forming a wide bean-shaped loop, its upper edge dipping in the middle and its lower edge bowing downwards: one glyph produced by a Metafont program
The output of a short Metafont program. Metafont describes a character as a system of coordinate equations with a pen dragged along the resulting curve; this file, uploaded to Commons in 2015, renders the example program given in Wikipedia’s Metafont article, in which a bean-like shape is defined from six points and assigned to the character B. ngoclong19 · public domain · via Wikimedia Commons.

For the later versions Knuth invented the practice he called literate programming: compilable source and cross-linked documentation produced from one file, written in a language called WEB. The five volumes of Computers and Typesetting, published by Addison-Wesley in 1986, are its artefact, documenting the two languages, the source code of both interpreters, and the Computer Modern typefaces character by character. The set was typeset with TeX in Computer Modern, so that in Knuth’s words the books “belong to the class of sets of books that describe precisely their own appearance”.

TeX82, and a program built to stop changing

TeX78 did not survive. A version rewritten from scratch, published in 1982, replaced it, and it is TeX82 rather than the original that everything later rests on. Three of its changes mattered permanently. The old hyphenation routine gave way to a pattern-matching algorithm devised by Frank Liang, whose Stanford thesis of August 1983 bore the title Word Hy-phen-a-tion by Com-put-er. Fixed-point arithmetic replaced floating point, so that the same input would produce the same output on different hardware. And, after what the record describes as intense lobbying by Guy Steele, the macro language was made a real, Turing-complete programming language — the decision behind everything later called macro programming, and behind a good deal of what made it hard.

The other celebrated piece of TeX82 is its treatment of paragraphs. Most line-breaking algorithms are greedy: each break is chosen in turn and never revisited. TeX instead uses the globally optimising algorithm published by Knuth and Michael Plass in 1981, which considers every possible breakpoint, scores each for badness as the spaces on a line must stretch or shrink, adds penalties for breaks such as two hyphenated lines running, and minimises the sum of the squares of those values. The method has since been taken up elsewhere, notably in Adobe InDesign.

Knuth released new versions of both programs in 1989, and TeX 3.0 followed on 15 March 1990. Its main change was the ability to accept 8-bit input, allowing 256 characters where there had been 128 — a concession to languages other than English that governed how the system handled accented text for years afterwards. After version 3.0 the design was frozen: no new feature, no fundamental change, bug fixes only.

The freeze is recorded in the version numbers themselves, and this is the detail most often explained to newcomers. Since version 3 each update has added one more digit to the decimal, so that the number creeps towards pi; the current version is 3.141592653, last updated in 2021. Metafont’s numbers approach e in the same way and stand at 2.71828182. Knuth has said the absolutely final change, to be made after his death, will be to set the number to pi exactly, at which point all remaining bugs become features.

Licensing follows the same logic. Knuth has repeatedly said the source is in the public domain and encouraged others to modify it; what he will not allow is that a modified system keep the name. Any implementation must pass a test suite called the TRIP test before it may be called TeX. The name needed guarding in a smaller way as well: Knuth asks that it be set with the E dropped below the baseline and the letters tightened, which, as he explains in The TeXbook, distinguishes it from TEX, the Text EXecutive processor of Honeywell Information Systems.

The bug log and the reward cheques

Since 1982 Knuth has kept a detailed log of every bug he has corrected and every change he has made to the program. As of 2025 that list runs to 440 entries, not counting the version change reserved for after his death. What made the log famous is the payment scheme attached to it.

Knuth offers a monetary award to anyone who finds and reports a genuine bug in TeX. It began at 2.56 US dollars — one hexadecimal dollar — and doubled every year until it was frozen at its present value of 327.68 dollars. Because bugs have been so few the cost to him has been slight, and a further economy is provided by the recipients, who are known to frame the cheque as evidence rather than cash it. That habit had a consequence: scanned images circulated online and were used by fraudsters attempting to draw on his account, so real cheques are no longer sent. Reporters of bugs now receive credit at the Bank of San Serriffe, the national bank of the fictitious island invented by The Guardian for its April Fools’ supplement of 1 April 1977.

A printed personal cheque headed Donald E. Knuth, Computer Science Department, Stanford University, dated 8 March 1999, made out for 2.56 dollars and signed by hand; the payee's name has been blurred out
One of Donald Knuth’s reward cheques, printed with his Stanford computer science department address, drawn on a Palo Alto bank and signed on 8 March 1999 for 2.56 dollars — one hexadecimal dollar, the scheme’s original unit. The payee’s name is obscured, and the uploader states that the machine-readable digits along the bottom were randomly swapped or altered before publication so that no account details are disclosed. Signature by Donald Knuth · public domain · via Wikimedia Commons.

The stability that policy protects is not abstract: the 2021 revision, which Knuth described in TUGboat as that year’s TeX tuneup, was accompanied by new printings of the first four volumes of Computers and Typesetting, dated February 2021 and labelled a 35th Jubilee Edition.

Plain TeX, LaTeX and the macro layer

TeX by itself is an engine with a macro language on top; the commands an author types come from a format, a set of macros loaded into the engine. Knuth’s own format is plain TeX, and it is what The TeXbook teaches. The format that carried TeX into the wider academic world was LaTeX, written in the early 1980s by Leslie Lamport at SRI International, who had been writing TeX macros for his own use and judged that with a little more effort they could be made into a package others could use; he released versions of them in 1984 and 1985. An Addison-Wesley editor, Peter Gordon, persuaded him to write a manual; Lamport doubted anyone would pay for it, and it sold hundreds of thousands of copies after appearing in 1986.

The distinction that manual drew — TeX handles the layout, LaTeX the content, and the author writes structure rather than appearance — is what made technical writing in TeX teachable, and it is why so much of the answering done under the name of TeX is really about LaTeX: the community FAQ still says that its typesetting answers are given mostly from the viewpoint of a LaTeX user.

The handover is dated. On 21 August 1989, at a TeX Users Group meeting at Stanford, Lamport agreed to turn over maintenance and development to Frank Mittelbach, who with Chris Rowley and Rainer Schöpf formed the LaTeX3 team. Their first substantial product was not LaTeX3 but LaTeX2e, released in 1994 to replace the version then in use, LaTeX 2.09; it has been the current version ever since, updated incrementally rather than superseded, while LaTeX3 was abandoned as a separate format and became, from 2018, a programming layer inside LaTeX2e. For years after 1994 a document, a class file or a package could still belong to either generation, which is why the two names had to be told apart before anything else could be diagnosed.

LaTeX is distributed under the LaTeX Project Public License, a free software licence whose distinguishing requirement is that a modified component identify itself to the user as modified and carry a prominent record of what was changed — the same instinct that produced the TRIP test, since in a system where thousands of packages load one another a file that behaves differently from what its name promises breaks more than itself.

Other formats stood alongside LaTeX and were argued over on equal terms — ConTeXt, developed by Hans Hagen, took a different view of how much a format should do for the author — and beyond the formats lay the packages, where most users met the system’s complexity. A package is ordinary macro code with no privileged status, free to redefine anything the format defined; two packages may each work perfectly and fail together. The community FAQ has entries titled “Option clash for package” and “Package reports ‘command already defined’”, which name the genre exactly.

Mathematics, AMS-TeX and the AMS fonts

The reason TeX took hold in the sciences rather than in general publishing is that Knuth treated mathematical spacing as the hard problem it is. He worked from three bodies of printing he regarded as exemplary: books produced by Addison-Wesley under the supervision of Hans Wolf, editions of the journal Acta Mathematica from around 1910, and a copy of the Dutch journal Indagationes Mathematicae. From these he derived spacing rules that remain among the parts of TeX least often reproduced elsewhere; the OpenType specification for mathematics borrows substantially from them.

The American Mathematical Society was an early institutional adopter, and its involvement dates from the beginning: the first issue of TUGboat, October 1980, carries both a panel discussion on AMS-TeX and an article by Michael Spivak titled “AmSTeX — a very friendly product”. AMS-TeX, which Spivak wrote, was used by the Society from 1983 to 1985 and documented in his book The Joy of TeX. It has since been largely superseded by AMS-LaTeX, a collection of classes and packages providing multi-line equation environments, theorem and proof structures, and fonts carrying a large repertoire of mathematical symbols.

The Society also commissioned type. AMS Euler is an upright cursive face designed by Hermann Zapf with the assistance of Knuth and his Stanford graduate students, meant to resemble the way a mathematician writes on a blackboard rather than the sloped italic of printed mathematics. Zapf drew the alphabets in 1980 and 1981; the Metafont implementation was carried out by a succession of students, the last of whom, David Siegel, completed the digitisation as his master’s thesis in 1985. Knuth then drew a text face to sit beside it, Concrete Roman, which he named after the book it was first used in, Concrete Mathematics. In 2009 the Society released version 3.0 of its fonts with many Euler glyphs reshaped by Zapf.

Three lines of displayed mathematics under the heading AMS Euler: a definite integral, Euler's formula for the complex exponential, and the quadratic formula, all set in an upright cursive face rather than the usual sloping italic
A specimen of AMS Euler, the upright cursive face commissioned by the American Mathematical Society and designed by Hermann Zapf with Knuth and his students. The uploader produced this image in 2008 by processing a LaTeX source with pdfTeX and tracing the resulting page. Peter J. Acklam · public domain · via Wikimedia Commons.

Mathematical typesetting is also what connected this newsgroup to its neighbours in the directory. The computer-algebra and symbolic-mathematics groups — sci.math.symbolic and comp.soft-sys.math.maple among them — dealt with the other half of the same working day, the part where the mathematics was computed rather than printed.

The engines that came after

Knuth froze TeX but did not close it. He had deliberately built hooks into the program and released the source in the hope that others would produce versions suited to their needs, on the single condition that they not use the name. Most people extended TeX only through macros, but a handful of genuine engine forks appeared, and each changed what a user had to know: the Omega project, begun after 1991, aimed at multilingual typesetting, and e-TeX added extensions that became the assumed base for later work.

The most consequential fork was pdfTeX, written by Hàn Thê Thành as part of his doctoral work at Masaryk University in Brno, from an idea discussed in the early 1990s between Jiří Zlatuška, Philip Taylor and Knuth at Stanford. Its obvious contribution was output: TeX writes a device-independent DVI file that must then be converted, whereas pdfTeX writes PDF directly, which allowed hyperlinks and document metadata to be integrated through packages such as hyperref. Its less obvious contribution was micro-typographic — character protrusion, a generalisation of hanging punctuation, and font expansion, an implementation of Hermann Zapf’s ideas for evening out the greyness of a page. The change was not free of cost: packages that depended on the old route through PostScript, PSTricks among them, could fail under the new engine, and replacements such as PGF and TikZ were written.

The Unicode question was answered twice. XeTeX, written by Jonathan Kew, was released for Mac OS X only in April 2004 with Unicode and Apple Advanced Typography support; OpenType layout features followed in 2005, a Linux version was announced in 2006 and ported to Windows soon after, and the engine entered TeX Live 2007 for all major platforms. XeTeX assumes UTF-8 input and can use any font installed on the operating system without the traditional TeX font metric files, which removed at a stroke much of the font-installation procedure TeX had required.

LuaTeX took the other route. Begun by Taco Hoekwater, Hartmut Henkel and Hans Hagen, it started as a version of pdfTeX with a Lua scripting engine embedded, so that TeX’s internals could be reached from a real programming language rather than new features being hard-coded into the engine. Its first public beta was shown at the TeX Users Group conference in San Diego in 2007, a stable production version arrived in 2010 and version 1.0 in September 2016.

The dates sit close together. TeX Live 2003 made e-TeX the default and shipped the Latin Modern fonts; XeTeX appeared in April 2004; and by TeX Live 2007 a Unicode engine was in every major installation. The engine that everyone had assumed to be permanent quietly stopped being the one everyone ran.

Computer Modern and the font question

Computer Modern is the original family of typefaces used by TeX, created by Knuth with Metafont and last updated in 1992. It sits in the Scotch Roman class, close to the Didone faces, with high contrast between thick and thin strokes and a vertical axis but bracketed serifs, and it was based specifically on the ten-point size of the American Lanston Monotype Company’s Modern Extended 8A, from a family first released in 1896. The choice was deliberate: modern faces had been used extensively for printing mathematics before Times New Roman became popular for it from the 1950s.

What makes the family unlike any other is that it is a parametric design. The sources are governed by 62 distinct parameters controlling widths and heights, the presence of serifs, the style of the numerals, whether the dot on an i is square or round, and the degree of superness in the bowls of letters such as g and o. Very few other designers followed the method: Knuth himself observed in 1996 that asking an artist to become enough of a mathematician to write a font with sixty parameters is too much, and the type designer Jonathan Hoefler remarked in 2015 that the underlying idea that letters begin as skeletal forms is flawed.

The practical difficulty was technological. Metafont produces bitmaps at a stated resolution, and TeX knows nothing about its fonts beyond their dimensions, leaving the device driver to handle the rest; as PostScript, PDF and laser printers took hold, outline formats renderable at any size became the sensible target. Blue Sky first converted Computer Modern to PostScript Type 3 in 1988, then to Type 1 in 1992 so that hinting could be included; that version was afterwards donated to the American Mathematical Society, which distributes it freely. That passage from Metafont to Type 1 is why a font question in TeX was so often a question about drivers, encodings and installation rather than about letterforms.

A designed type specimen: the words Computer Modern set large, roman and italic pairs Aa Ee Rr, an oversized lowercase t, the word Matrix in blue, and the lower-case alphabet with numerals on a blue panel
A specimen of Computer Modern, the family Knuth generated with Metafont and shipped as TeX’s default type. The sheet was drawn up by a Commons contributor in 2019; it shows the modern-face model — strong contrast between thick and thin strokes on a vertical axis, with bracketed serifs — that Knuth took from nineteenth-century Monotype originals. Rogi Lensing · CC BY 3.0 · via Wikimedia Commons.

Extension followed conversion. The EC fonts, which look much like Computer Modern but differ slightly in metrics, were the first TeX fonts to use the Cork encoding — T1 in LaTeX terms — providing precomposed glyphs for western European languages. Latin Modern, maintained by Bogusław Jackowski and Janusz M. Nowacki of the Polish user group GUST, was made by converting the Blue Sky Type 1 fonts back into outline programs and rebuilding extended Type 1 and OpenType fonts from them; it is now standard in the TeX community and the default in ConTeXt.

User groups, TUGboat and the archive

The institutions around TeX are older than the newsgroup and outlasted it. The TeX Users Group was founded in 1980; the minutes of its first meeting, held that February, were printed in the first issue of TUGboat, dated October 1980. TUGboat is still published three times a year and still covers digital typography broadly rather than TeX narrowly.

National groups followed. DANTE, the German-speaking users’ association, was founded on 14 April 1989 in Heidelberg and publishes Die TeXnische Komödie four times a year; CSTUG in the Czech Republic, DK-TUG in Denmark, GUTenberg in France, GuIT in Italy, NTG in the Netherlands and GUST in Poland are among those still listed by the TeX Users Group, which keeps the register of them. That structure matters for reading the archive: much TeX work was done in national associations and their journals, and the English-language newsgroup was one venue among several.

The archive is the other institution. Before CTAN there were scattered collections and no systematic one. The idea of bringing them together arose at a podium discussion organised by Joachim Schrod at the EuroTeX conference of 1991, and the Comprehensive TeX Archive Network was built in 1992 by Rainer Schöpf and Joachim Schrod in Germany, Sebastian Rahtz in the United Kingdom and George Greenwade in the United States, who supplied the name. The nodes were synchronised at the start of 1993, and the network was announced formally at the EuroTeX conference held at Aston University that year. The main nodes now serve more than six terabytes a month, not counting ninety-four mirrors.

What users installed was a distribution. On Unix-like systems that meant teTeX, whose maintainer Thomas Esser stopped work on it in 2006 and pointed users at TeX Live instead; TeX Live had been started in May 1996 by Sebastian Rahtz in collaboration with the user groups worldwide, and is now maintained by Karl Berry and others. On Windows the common choice was MiKTeX, written by Christian Schenk, which installs a minimal set of packages on the principle of just enough TeX and then offers to fetch anything a document turns out to need. The difference between those two approaches mattered in practice: the same document could fail on one system and succeed on the other for reasons that had nothing to do with the document.

What the group carried, and where the answers went

Four kinds of question follow from the way the system is built rather than from the temperament of anyone answering them. The first is error-message diagnosis. TeX reports trouble in its own vocabulary and then stops and waits, and the line it names is frequently inside a macro package rather than in anything the author wrote. The community FAQ still keeps a whole department for this, with separate entries for messages such as “Missing $ inserted” and “Too many unprocessed floats”, for the several varieties of capacity exceeded, and one devoted simply to the structure of TeX error messages.

The second is package interaction. Because packages are ordinary macro code with the power to redefine whatever the format defined, and because a real document may load dozens of them, failure is often a property of a combination rather than of any component. Diagnosis meant reducing a document to a minimal example that still failed.

The third is macro programming proper — expansion order, category codes, the boundary between what is expanded and what is executed, and the consequences of the 1982 decision to make the language Turing-complete. The fourth is fonts and their installation: metrics, encodings, drivers, and the long migration from bitmaps to outlines.

What the answers became is documented. The English-language FAQ, for years hosted in the United Kingdom at tex.ac.uk and now at texfaq.org, organises itself under headings such as background, bibliographies, concepts, documentation, errors, floats, fonts, formatting, graphics, installing, programming and usage. Its curators do not delete questions that have gone stale but retire them from the main index.

The question-and-answer site followed. A proposal for a TeX and LaTeX site went through the Stack Exchange proposal process and opened as a private beta on 26 July 2010, went to public beta a week later on 2 August, and graduated from beta on 11 November 2010. Its arrival did not close the newsgroup, and the TeX Users Group’s own list of places to get help still names both, though it now warns that an active Usenet feed may be hard to find.

That warning has a concrete cause. Google Groups stopped accepting new Usenet content on 22 February 2024, closing the route by which the group had been read and posted to on the web for two decades. The archive itself remains readable, and a live feed remains available to anyone with access to a news server — see accessing Usenet today for the current options, and the comp hierarchy for the group’s neighbours in this directory.

Reading comp.text.tex today

  • Historical archive: Google Groups — comp.text.tex (coverage varies by group and era).
  • Open in a newsreader: news:comp.text.tex — the original site offered exactly this link, and it still works if your system has a newsreader registered for the news: scheme.
  • Live access: point an NNTP newsreader at a modern server — see accessing Usenet today.
  • The original news2mail e-mail subscription service ended in the mid-2000s and no longer operates.