- From: L. David Baron <dbaron@fas.harvard.edu>
- Date: Sat, 25 Sep 1999 08:33:04 -0400 (EDT)
- To: dbaron@fas.harvard.edu, plh@w3.org
- Cc: www-dom@w3.org
On Sat, 25 Sep 1999 11:19:15 +0200, Philippe Le Hegaret (plh@w3.org) wrote: > L. David Baron wrote: > > There are messy issues with the border-color property. See > > http://lists.w3.org/Archives/Public/www-style/1999Sep/0082.html > > http://lists.w3.org/Archives/Public/www-style/1999Sep/0085.html > > The border-color gets his value from the color property when the border > property doesn't contain a color, but the value of the color is the > _specified_ value of the color property and not the value in the style sheet. > Since we don't compute the inheritance in the CSS OM (except for the computed > style delcaration), the border color should be empty. However, empty is equivalent to not being specified, which is clearly wrong. An application that *uses* the methods of the CSS OM to cascade and find computed values would be unable to handle the following rules correctly: div { border-color: green; } div { border: medium solid; color: red; } It would give div elements a green border (instead of the correct red, assuming the color isn't changed anywhere else), since the border-color property seems (through the CSS OM) not to be set within the second ruleset. This is more a problem with CSS than the DOM, but I'm bringing it to the attention of the DOM list as well. > > I think the following statement in [2] is unnecessary because the special > > system font shorthand values *can* be decomposed (and must, since some of the > > equivalent longhand properties can be changed, leaving others intact). > > Unfortunately, this is not true, see the font shorthand property definition > in CSS2 : > http://www.w3.org/TR/REC-CSS2/fonts.html#propdef-font > > > [ [ <'font-style'> || <'font-variant'> || <'font-weight'> ]? <'font-size'> > [ / <'line-height'> ]? <'font-family'> ] > | caption | icon | menu | message-box | small-caption | status-bar | inherit > > caption, icon, menu, message-box, small-caption and status-bar are not > supported by the longhand properties. They cannot be specified by the longhand properties, but they can clearly be decomposed into those longhand properties. In particular, see the second sentence of the following (which is within the URL you cite): # That is why this property is "almost" a shorthand property: system # fonts can only be specified with this property, not with # 'font-family' itself, so 'font' allows authors to do more than the # sum of its subproperties. However, the individual properties such as # 'font-weight' are still given values taken from the system font, # which can be independently varied. David L. David Baron Sophomore, Harvard (Physics) dbaron@fas.harvard.edu Links, SatPix, CSS, etc. <URL: http://www.fas.harvard.edu/~dbaron/ > WSP CSS AC <URL: http://www.webstandards.org/css/ >
Received on Saturday, 25 September 1999 08:33:15 UTC