W3C home > Mailing lists > Public > www-style@w3.org > May 2012

Re: [css2.1][css3-fonts] keywords in unquoted font family names

From: Gérard Talbot <www-style@gtalbot.org>
Date: Fri, 25 May 2012 14:32:25 -0400
Message-ID: <620ebec4397c6e4279c9817205139fca.squirrel@ed-sh-cp3.entirelydigital.com>
To: "John Daggett" <jdaggett@mozilla.com>
Cc: "W3C www-style mailing list" <www-style@w3.org>, "Tab Atkins Jr." <jackalmage@gmail.com>

Le Ven 25 mai 2012 0:42, John Daggett a écrit :
>
> Hi Gérard,
>
> Why does your test require the default font to be set?

So that invalid declarations can display "PASS" thanks to "5678" characters.

> That doesn't
> make much sense to me.

Well, if a font declaration is invalid, then it is ignored and then the
UA-dependent default 'font-family' is applied.


> Include a containing div and set its
> font-family to "CSSTest FamilyName".

*_This is_* what I did at line 94 of
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/font-family-rule-004a.xht

and at line 99 of
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/font-52.xht

with

<div id="verify">User agent's default font must be set to be "CSSTest
FamilyName": 5678</div>


>  <div id="verify">User agent's default font must be set to be "CSSTest
> FamilyName": 5678</div>
>
> I also think you should include tests for 'foo, inherit' and 'inherit,
> foo' and the same set of tests for the 'initial' keyword.


In

http://www.gtalbot.org/BrowserBugsSection/css21testsuite/font-family-rule-004a.xht


  div#firstTest {font-family: inherit, "CSSTest Fallback";}
  /* invalid: unquoted inherit is a reserved keyword and not a font-family
name */

  div#secondTest {font-family: "CSSTest Fallback", inherit;}
  /* invalid: unquoted inherit is a reserved keyword and not a font-family
name */

  <div id="firstTest">5678</div>

  <div id="secondTest">5678</div>

If the declarations are parsed as valid, then "CSSTest Fallback" will
apply and we will read FAIL. If the declarations are invalid, then
"CSSTest
 FamilyName" will be applied and we will read PASS.

It's the same thing as 'foo, inherit' and 'inherit, foo' except that
CSSTest Fallback exists and is installed on the tester's system.

http://www.gtalbot.org/BrowserBugsSection/css21testsuite/font-family-rule-004a.xht


Gérard
-- 
CSS 2.1 Test suite RC6, March 23rd 2011
http://test.csswg.org/suites/css2.1/20110323/html4/toc.html

Contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/

Web authors' contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/web-authors-contributions-css21-testsuite.html
Received on Friday, 25 May 2012 18:32:57 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:54 GMT