Smashing Magazine: 5 Principles And Ideas Of Setting Type On The Web
Articles & Notes
Optimal Line Height
The theory and the application of optimal line height — called leading in typographic circles — varies greatly in web design. Typography references consistently put ideal line height at 1.2 ems (a measure of type equivalent to the the letter height or point size of a typeface).
Yet, premier web designers (and typography affectionatos) regularly set line height to 1.5 ems or more. That is a 33% overstatement of the preferred height. This creates a striping of text, rather than the desired greying. When Jason Santa Maria crafted the current A List Apart design, he set the line height to a whopping 1.8 ems. Why is this done?
This is partly explained when one considers the line length of the subject designs. The designs require line lengths (or measure) notably longer than those recommended in typographic references. The increased line length demands increased line height to aide eye tracking. This does not make for ideal type, but it does make for the best typography for the subject design. James Felici says it well in his book The Complete Manual of Typography:
An axiom of computerized type is that leading should generally be 1.2 times the point size of type. This isn’t a terribly useful guideline, because it’s clear that leading must increase along with the measure.
One consequence of this is other web designers look at what the elite are doing, and apply that line height regardless of line length. This leads to line heights that are unnecessarily out of proportion.
So as a general rule, an optimal line length is 60 to 65 characters, or 30 ems. At that measure, the ideal line height should be approximately 1.2 ems. As line length increases, line height should follow proportionately. The body text in the KINGdesk design is set to a measure of nearly 27 em and a line height of 1.2 ems.
Moderate Rhythm
Excellent design is all about balance. The designer should be well grounded in theory and mindful of constraints. But rules should, on occasion, be broken. As valuable as vertical rhythm is to quality web design, there are times of rightful abandon. As in life, design should be moderate in all things, including moderation.
In 1992, Robert Bringhurst wrote in his book The Elements of Typographic Style:
For the same reason that the tempo must not change arbitrarily in music, [line height] must not change arbitrarily in type….
Headings, subheads, block quotations, footnotes, illustrations, captions and other intrusions into the text create syncopations and variations against the base rhythm of [regular line height]. These variations can and should add life to the page, but the main text should also return after each variation precisely on beat and in phase. This means that the total amount of vertical space consumed by each departure from the main text should be an even multiple of the basic [line height].
In late 2006, Richard Rutter picked up the mantle and introduced this principle to the web design community. Over the next year, articles at reputable sites continued the theme:
- Setting Type on the Web to a Baseline Gridat A List Apart
- Typography: Baseline Rhythm Deciphered at SitePoint
- Type that keeps the beat at 37Signals
Attention to vertical rhythm certainly increases the quality of web design. Alignment of baselines is imperative in adjacent columns of body text. Misaligned baselines communicate neglect of detail. This is true with newspaper or neighboring pages in a book. But rigidity of application can leave a design as stale as a march penned by a composer desperately needing introduction to Coltrane.
While the music analogy is helpful, we must not forget that type is its own form. Setting of type must have visual appeal. Situations exist where vertical rhythm no longer makes sense. On this site, extra padding has been added between list items. A full line height was excessive. No padding called for room to breathe. We settled on one-third of the standard line height to buffer each list item. This substantially increases readability, particularly with long lists (see our Comment Policy as an example).
However, as the padding is applied to lists of varying count, there is no guarantee the list height will total an even multiple of the basic [line height]
. In the list of links above, we actually lost one-third of a line-height — did you notice? Compromise like this will cause the baseline of the sidebar text to misalign with the body text. But that is a small compromise for visual balance.
From the PortfolioTurnAround Schools
A very clean and minimalist design that places emphasis on the content. This website consists primarily of static html pages, but incorporates a blogging content management system into a subdirectory. Refresh the front page a few times, and notice the photos and testimonials update.
Since the website redesign, TurnAround Schools has seen a dramatic increase in online registrations for their training institutes. This was a primary objective.
From the PortfolioKINGdesk
A contrast in bold color and subtle texture. The rich burgundy makes a strong statemen while its texture mimics that of a upscale leather desk — paying homage to the site’s name. Less noticed is the parchment texture behind the main content block.
This design challenges many norms in web design. While lacking a traditional header and footer, the order of the site still makes intuitive sense. By pushing the design horizontal, the dimension of the site works well with today’s widescreen monitors.
Typography played an important role in this site’s development. Many designers shy away from justified margins because of the difficulty of hyphenation on the web. KINGdesk incorporates a hyphenation engine that allows for justified text without ghastly oversized word spaces. Nearly every spacial dimension of the site is dependent upon the text size. This allows for zooming of the site in every modern browser by resizing the text. A widget has been specifically developed and included in the sidebar to conveniently facilitate this.
A Lack of Monetary Incentive
Designing one’s own website has the same blessing and curse: there is no immediate financial incentive to completion. This can (and does) push the roll-out date, mostly as paying jobs take priority.
But this also works as an advantage. Without the burdens of timelines or productivity on my shoulders, I find that I am much more innovative. This innovation is not just a benefit to this site, but to my client’s sites as well — as these ideas are reused. In short, designing this site has become a playground, where I can try things that I would normally not have time for.
In particular, during the course of development of the new KINGdesk design, I have assembled two significant advances in web design. One will have broad application; the other more narrow. Before I roll these out for public consumption, I need to get a little further along with the KINGdesk design. They may draw a little attention, and we need to have our Sunday’s Best on. Stay tuned…
Safari Run-in Errors
Safari 3 run-in errors:
- Loses position on text resizing, causing text overlap
- Top margin improperly collapses when following an unordered list
- Loses position when page is returned to using back button (mobile Safari only)
But Safari does support display: run-in;, which is more than can be said for Firefox 2 or IE 7.
