[CSS2.1] Assigning property values, Cascading, and Inheritance

S6.1.1: Specified values
http://www.w3.org/TR/2003/WD-CSS21-20030915/cascade.html#specified-value

# User agents must first assign a specified value to a property...
                                                      ^
to _each_ property

# Since it has no parent, the root of the document tree... if necessary.

Take this paragraph out; this case is already handled by the
rules above it.

S6.1.2: Computed values
http://www.w3.org/TR/2003/WD-CSS21-20030915/cascade.html#computed-value

# For absolute values, no computation is needed to find the computed value.

Is the computed value of "1cm" and "10mm" the same or different?
Because you need to convert in order to make them the same, and
converting units involves computation...

# However, some properties may define the computed value of a property
# for an element to depend on whether the property applies to that element.

This sentence serves no purpose here and therefore is just confusing.
Take it out.

S6.2: Inheritance

# When inheritance occurs, elements inherit computed values. The
# computed value from the parent element becomes both the specified
# value and the computed value on the child.
...
# Each property may also have a specified value of 'inherit', which
# means that, for a given element, the property takes the same
# computed value as the property for the element's parent.

There's a dichotomy in how the "specified value" for inherited values
works, depending on whether it's explicit or implied. It would be best
if the initial behavior of 'color' and "color: inherit" meant exactly
the same thing. And this way the meaning of "color: inherit" on the
root element would follow from the inheritance logic without having to
be handled as another exception.

# If the user agent does not have the 12pt font available...

Change 120% to 130% and make it 13pt font. Because the vast majority
of fonts out there do have 12pt versions--13pt is not a common size
and is therefore more likely not to exist.

6.3 The @import rule
http://www.w3.org/TR/2003/WD-CSS21-20030915/cascade.html#at-import

Move this section to either before Specified, Computed and Actual Values
or after The Cascade, because it breaks up the conceptual flow between
these two sections.

6.4 The Cascade
http://www.w3.org/TR/2003/WD-CSS21-20030915/cascade.html#cascade

# Note that the default style sheet may change if system settings are
# modified by the user (e.g., system colors). However, due to limitations
# in a user agent's internal implementation, it may be impossible to
# change the values in the default style sheet.

This note seems rather useless. If there's no good justification for
putting it in, then take it out.

# Rules specified in a given style sheet override rules of the same
# weight imported from other style sheets.

Even if the imported rules have higher specificity?
I think you mean to say that rules in an imported style sheet are
considered to be before the rules in the importing stylesheet.

6.4.2 !important rules
http://www.w3.org/TR/2003/WD-CSS21-20030915/cascade.html#important-rules

# the keywords "!" and "important" follow the declaration

Since when is "!" a keyword?

# The first rule in the user's style sheet in the following example...

I think the example would be more illustrative if the second rules
in the author and user style sheets were switched.

S6.4.3: Calculating a selector's specificity
http://www.w3.org/TR/2003/WD-CSS21-20030915/cascade.html#specificity

# Concatenating the four numbers a-b-c-d (in a number system with
# a large base) gives the specificity.

Use of dashes here doesn't match use of commas in the examples.

# Note: The specificity is based only on the form of the selector.
# In particular, a selector of the form "[id=p33]" is counted as an
# attribute selector (a=0, b=0, c=1, d=0), even if the id attribute
# is defined as an "ID" in the source document's DTD.

This text should be normative, not informative, and therefore should
not be marked as a note.
Also, move it up to before "Some examples", right after "Contcatenating
the four numbers a-b-c-d (in a number system with a large base) gives
the specificity".

S6.4.4: Precedence of non-CSS presentational hints

# For XHTML and other languages written in XML, no attribute should
# be considered presentational. The styling of elements and
# non-presentational attributes should be handled in the user agent
# stylesheet.

First off, the non-presentational attributes aren't being styled.
The elements to which they belong are being styled based on these
attributes.

Secondly, the 'spacing' attribute of <orderedlist> in DocBook
  <http://www.docbook.org/tdg/en/html/orderedlist.html>
is clearly presentational. Trying to deny this is silly. What you
/want/ to do is to restrict the special handling of presentational
hints to HTML.

Like this:
# The UA may choose to honor presentational attributes in the source
# document.

 > The UA may choose to honor presentational attributes in an HTML
 > source document.

# For XHTML and other languages written in XML, no attribute should
# be considered presentational. The styling of elements and
# non-presentational attributes should be handled in the user agent
# stylesheet.

 > For other languages, all document language-based styling should be
 > handled in the user agent style sheet.

(SGML needs to be handled somewhere, so one can't say HTML and XML
without leaving room for the general case.)

# The following user stylesheet would override the font weight of
# 'b' elements in all documents, and the color of 'font' elements
# with color attributes...

I personally think an example with <center> and <div align="center">
would be more interesting... =]

~fantasai

Received on Monday, 20 October 2003 15:09:52 UTC