The canon, as code
Every rule cites its page.
The books were read cover to cover and encoded as assertions; the test suite reproduces the books' own dimensioned grids: the 8-field, 20-field and 32-field A4 reference grids exactly as printed. When the library and the book disagree, the book is right. A sample of the rules in force:
| The rule | Source |
|---|---|
| No half lines in typography: every vertical distance is whole lines | MB 58–59 |
| Field height is a whole number of text lines; gutters are empty lines | MB 64, 134 |
| The narrower the column, the smaller the typeface | MB 57 |
| Seven to ten words a line; 8–12 pt for the text of books | MB 18, 30–31 |
| Cross‑size register: every style's line height meets one module | MB 59, 66 |
| A picture's width matches the width of a column of text | MB 63 |
| The band under a captioned picture grows in whole body lines | MB 64 |
| Captions belong in the caption column, beside their picture | MB 63, 87, 120 |
| The margin column sits at the outer edge, and mirrors | MB 55 |
| Few graded picture sizes; one picture may dominate | MB 11, 70 |
| The type area floats high: mass may not sink | MB 51 |
| Lines may be set flush right and left, but never the last | MB 80 |
| Statistics have the size of 1, 2, 3 or 4 grid fields, so a chart's bars are whole text lines | MB 14, 58–59 |
| A title is set in its own face, on whole slots of the register; eight canonical placements | MB 46–47, 87 |
| Empty spaces around titles are whole lines; the rest zone gives a title its importance | MB 69–70 |
| A paragraph announces itself by an empty line, an indented first line, or an initial | MB 34, 36 |
| The centred axis is one of the six settings of text | MB 79 |
| A cut-out is tied down by a tint beneath, a field border, bracketing rules, or an overprint | MB 98 |
| The type area may stand in a 1:2 relation to the paper area; wide spines for thick books | MB 51 |
| The mobile grid: one unit count, many simultaneous divisions | Gerstner 58–61 |
| The morphological box: the parameter space, enumerated | Gerstner 59 |
Sources: Josef Müller-Brockmann, Grid Systems in Graphic
Design (Niggli, 1981); Karl Gerstner, Designing Programmes (Niggli, 1964).
The books stay out of the repository; buy them, they are worth it. The compiled
specification lives in research/foundations.md.