Re: [CSS21] Font-family syntax

Matthew van Eerde (<mailto:Matthew.van.Eerde@hbinc.com>) wrote to 
<mailto:www-style@w3.org> on 27 August 2004 in "RE: [CSS21] Font-family 
syntax" (<mid:61192FA29C719B469A2B13E57DEDF75B0300F190@mail.hbinc.com>):

> Philip TAYLOR wrote:
>> Could I suggest :
>>
>> "... Similarly, quotation marks (both single and double), ...
>> and leading slashes (both forward and reverse)... must be escaped."
>>
>> If either of my "both" clauses are wrong, then the prose should
>> still be more explicit at this point.
>
> I can think of many different kinds of quotes off the top of my
> head.

Searching the Unicode Database (version 4.0.1) reveals ten characters 
in general categories Pi and Pf (initial quotation marks and final 
quotation marks, respectively). Then there are the various European and 
East Asian quotation-mark characters used in general categories Ps and 
Pe. And, of course, there are the ASCII-repertoire apostrophe (U+0027) 
and quotation mark (U+0022).

Of all these quotation marks, only U+0027 and U+0022 require escaping 
in font-family names. Both the Working Group's revised wording and 
Phillip Taylor's wording are too vague on this.

> But what if a font-name starts out with two slashes?  Do both have to 
> be escaped, or can just the first
> one be escaped?

Only the first requires escaping.

There remains a prohibition on series of unescaped slashes optionally 
separated by white space.

Illegal example:

     example { font-family: Slash//slash; }

Corrected examples:

     example { font-family: Slash\//slash; }
     example { font-family: Slash/\/slash; }

The problem is the insistence of Appendix G on a restrictive grammar 
for declaration values.

I suggest a survey of current user-agent practice. I have the tests 
ready. Can the W3C or another party host them?

-- 
Etan Wexler.

Received on Wednesday, 27 October 2004 13:27:00 UTC