[CSS21] Question on "Applies to:" information

Dear fellow www-style colleagues,

"
1.4.2.3 Applies to

This part lists the elements to which the property applies. All elements
are considered to have all properties, but some properties have no
rendering effect on some types of elements. For example, the 'clear'
property only affects block-level elements.
"
http://www.w3.org/TR/CSS21/about.html#applies-to


According the wording of the spec, the "Applies to:" info indicates
whether a property will have an effect on some types of elements. So, what
should I be thinking when, for example, font-weight is said to applies to
all elements when, in fact and in reality, it does not and it can not. I'm
not referring to computed value cascaded through inheritance. I'm only
talking about applicability of a property... which is what the "Applies
to:" info is supposed to be indicating to begin with.

Does font-weight apply to <hr> elements? Yes, according to the spec. But
in reality, no one can seriously say that it does.

Does font-weight apply to table-header-group elements? Yes, according to
the spec. But in reality, no one can seriously say that it does.
table-header-group elements do not have text content and can only have
table-row elements.

Why the spec is not saying instead that font-weight can only apply on
elements which can render text content in the "Applies to:" info to begin
with?

A closer look at the spec wrt such perspective reveals, at first sight,
rather weird statements ...

Text-decoration: it is supposed to apply to *_all elements_* but we can read
"Underlines, overlines, and line-throughs are applied only to text
(including white space, letter spacing, and word spacing): margins,
borders, and padding are skipped. User agents must not render these text
decorations on content that is not text. For example, images and inline
blocks (sic) must not be underlined."
http://www.w3.org/TR/CSS21/text.html#decoration

So then why state that text-decoration applies to all elements in the
first place? And what if an inline-block only has text content[1]?

If text-decoration does not apply to an image because it's not text
content, then why it shouldn't apply to its alt text if/when rendered?

What I am missing here? Where am I wrong?

regards, 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 Tuesday, 8 November 2011 22:00:05 UTC