For most of its history, printing was a craft of patient accumulation. A compositor stood before a case of metal type and assembled each line by hand, letter by letter, spacing the words with thin slivers of lead until the line filled the measure exactly. The work demanded concentration and a practised eye, because every decision about spacing affected the appearance of the whole page. A paragraph that looked even and calm on the press had usually been rearranged several times before anyone inked it. Mistakes were expensive, since correcting one line often meant resetting several others.
Justified setting, in which both margins form straight vertical edges, became the convention for books and newspapers because it gave the page an orderly, architectural quality. Achieving it, however, was never automatic. When a line ended awkwardly, the compositor could widen the spaces between words, tighten them slightly, or divide a long word across two lines with a hyphen. Experienced printers developed strong opinions about when each remedy was acceptable, and their accumulated judgement became the unwritten grammar of typography.
The arrival of mechanical typesetting in the late nineteenth century changed the speed of the work but not its underlying problems. Operators of the great keyboard machines still had to decide where lines should break, and the machines simply cast whatever the operator chose. Later, photographic and then digital systems took over much of this labour, and programmers began to describe the old rules in mathematical terms. One celebrated approach evaluates an entire paragraph at once, weighing every possible combination of breaks before choosing the arrangement with the most consistent spacing.
Web browsers inherited these questions in a simplified form. For many years they placed words on a line until no more would fit and then moved on, never reconsidering an earlier decision. The results were serviceable but often uneven, with conspicuous gaps in justified text and solitary words stranded at the ends of paragraphs. Recent improvements allow browsers to hyphenate automatically, using dictionaries for each language, and to look ahead a little before committing to a break, which produces noticeably more balanced paragraphs. Designers can also influence the outcome directly, inserting optional break points into unusual words or adjusting the rules that govern how many letters must remain on either side of a hyphen.
None of this technology removes the need for judgement. A designer still chooses the typeface, the size, the length of the line, and the space between lines, and each choice influences how comfortably the text can be read. Long lines tire the eye as it travels back to the beginning of the next one; very short lines fragment sentences and exaggerate irregular spacing. Somewhere between sixty and eighty characters per line is a traditional recommendation, although the right answer always depends on the typeface and the purpose of the page. Good typography rarely draws attention to itself. Its achievement is that readers forget about it entirely and simply follow the argument from one sentence to the very next.