- From: Arron Eicholz <Arron.Eicholz@microsoft.com>
- Date: Wed, 12 May 2010 21:00:26 +0000
- To: Gabriele Romanato <gabriele.romanato@gmail.com>
- CC: "public-css-testsuite@w3.org" <public-css-testsuite@w3.org>, "css21testsuite@gtalbot.org" <css21testsuite@gtalbot.org>
Gabriele Romanato wrote: > These testcases look more complicated that it could seem. First, Gerard has > specified a declaration in his author stylesheet. The declaration you've > mentioned is located in the UA default stylesheet. Author specified styles still have to deal with cascade. And the cascade is this tr (text-align: right (author style)) th (initial style for 'text-align', inheritance happens, default styles are then applied. text-align: center, not specified in author styles) Inheritance only occurs when you do not have the property explicitly defined on child. Or when you explicitly use the 'inherit' keyword. In this case the UA stylesheet defines the style and therefore overwrites the inheritance. If the 'text-align' was specified directly on the 'th' itself then the alignment on the 'th' would be overridden. > Now, inheritance should honor author or UA declarations? A th element > inherits direct from its parent element. Only if the values is its initial value not the default stylesheet value. In this case the style is defined by the default styles. Here is another example of how default styles come into play. The text in this case should be 'bolder' because the 'strong' has a definition (in the default styles) for 'font-weight'. <style type="text/css"> div { font-weight: normal; } </style> <div> <strong>Filler text</strong> </div>
Received on Wednesday, 12 May 2010 21:01:00 UTC