Sub topic 14
Checking a paragraph by eye and fixing it
This chapter assumes you know what leading and measure are, and that you can write basic CSS. You will use a short routine to judge a paragraph and fix it. Each step ties back to an earlier chapter.
The four-step check
Look at the paragraph before you touch any numbers. Numbers are the fix, not the diagnosis.
- Count the line length. Pick a typical full line and count its characters, spaces included. Body text usually reads well at roughly 45 to 75 characters. Under about 40 feels choppy. Over about 80 makes the eye lose its place.
- Squint at the texture. Blur your eyes or step back from the screen. The paragraph should look like an even gray block. Dark bands mean tight leading. Pale, stripy rows mean loose leading.
- Trace a line return. Read the end of one line and jump to the start of the next. If you hit the wrong line, the leading is too tight for this measure.
- Check the neighbors. Look at paragraph spacing, caption size, and what happens on a narrow screen.
Common problems and fixes
| What you see | Likely cause | Fix |
|---|---|---|
| Eye skips or rereads a line | Leading too tight for the measure | Raise `line-height` by 0.1 |
| Lines past about 80 characters | No measure limit | Add `max-width` in `ch` |
| Text feels choppy, many short lines | Measure too narrow | Widen the container or reduce padding |
| Paragraph looks airy and stripy | Leading too loose | Lower `line-height` toward 1.4 or 1.5 |
| Descenders touch the next line's ascenders | Leading too tight for the typeface | Raise `line-height`, especially for fonts with a large x-height |
Change one value at a time. If you change both measure and leading, you cannot tell which one helped.
Worked example
This paragraph has two problems. The lines run very long and the leading is tight.
p {
font-size: 1rem;
line-height: 1.2;
}On a wide monitor each line holds about 130 characters. Tracing a line return is hard. Fix the measure first, because it changes how much leading you need.
p {
font-size: 1rem;
line-height: 1.5;
max-width: 65ch;
margin-block: 0 1.5rem;
}The max-width: 65ch limit brings lines to roughly 65 characters. The unitless line-height: 1.5 scales with the font size. The bottom margin of 1.5rem equals one line height, so the paragraph gap matches the line rhythm.
Now recheck. Squint again: the gray should be even. Trace a line return: it should land correctly. Then shrink the browser window. On a narrow screen max-width no longer applies because the container is already narrower, so lines may fall below 45 characters. That is acceptable on phones, where 35 to 45 characters is common. Do not keep leading generous only to fill space.
Verify with the text-spacing override
A final test comes from WCAG 2.1 criterion 1.4.12. Temporarily apply these overrides and look for clipped or overlapping text.
p {
line-height: 1.5 !important;
letter-spacing: 0.12em !important;
word-spacing: 0.16em !important;
}
p + p {
margin-top: 2em !important;
}If text is cut off, a container probably has a fixed height. Use min-height or let the box grow.
Exercise
A paragraph has font-size: 1rem; line-height: 1.3; and no max-width. On a wide screen, lines hold about 110 characters, and your eye often lands on the wrong line after a line break. Which change do you make first, and what values would you try?
Show answer
Fix the measure first by adding max-width: 65ch;, which brings lines to about 65 characters. Then raise leading to about line-height: 1.5 if the line return still feels uncertain. Change one value at a time and recheck by tracing a line return. Often the shorter measure alone fixes most of the problem.
Exercise
After you apply the WCAG text-spacing overrides, the last line of text in a card is cut off. What is the most likely cause and the fix?
Show answer
The card likely has a fixed height (or overflow: hidden with a set height), so it cannot grow when spacing increases. Replace height with min-height, or remove it, so the box expands with its content.