Friday, September 22, 2006

Set opening paragraphs flush left | The Elements of Typographic Style Applied to the Web

I'm puzzled by the short technical discussion here, maybe he's not done? The reason I'm puzzled is because he hasn't mentioned how he addresses this very issue on webtypography.net. The code he's using now is:
p + p {
    margin-top: 0pt;
    text-indent: 1.5em;
}

Which, in modern browsers pulls the 2nd and subsequent paragraphs up to touch the prevous, and indents it. That first bit is actually pretty ingenious. His default paragraph top margin is 1.5em, which is what obsolete browsers will see, and newer browsers get the better typography.

What he used to do, at least when the site first launched, is put a class="first" on opening paragraphs, which is what I do on my blog. Yes, I know this because I observed that he was following this typographic rule and looked at the source. His new technique, especially with IE7 on deck, is more clever and less of a maintenance headache.

No comments: