On Sat, 17 Aug 2002, Brandon Oto wrote:
> Quickie: any comments on the concept of surrounding a font face that's got
> more than one word with quotes? A la:
> font-family: "Hoefler Text", Palatino, serif;
> As opposed to:
> font-family: Hoefler Text, Palatino, serif;
> I've seen both done, but no definitive writ saying either is correct.
Per the CSS specs, both are correct, and both mean the same thing.
Using quotes is suggested, because apparently some UAs might have bugs
with family names that don't have quotes (which UAs?), but according to
the specs quotes are only required in these cases:
When the whitespace in the font name is in odd places or in odd amounts
(e.g. at the start, end, or when there are two contiguous spaces in the
When the font name contains a semicolon, comma, exclamation mark, a
quote character, a backslash, or unbalanced parenthesis, brackets or
braces, or a commercial at sign, or a colon. (Not 100% sure about this
list, you'd need a CSS grammar guru to be sure. The spec definitely
needs to make this clearer.)
When the font name is identical to a generic name (such as serif).
Actually in the first two backslash escaping the problematic character
should be enough, but the odds that any UA supports that are pretty low.
Ian Hickson )\._.,--....,'``. fL
"meow" /, _.. \ _\ ;`._ ,.