Re: Meaning of keyword "inherit" for non-inheritable properties

Karen Lease <klease@club-internet.fr> writes:

> I suppose this has been mentioned before, but it still bothers me to be
> able to specify xxx="inherit" when xxx isn't inheritable.

I guess one should read 'Inherited by default: none' where the spec
says 'Inherited: no'.

> (Of course, if it is inheritable, there's no reason to say so, since
> if xxx isn't specified, it will get the value from its parent.)

In CSS, it makes sense to specify 'inherit' as a value even though the
property is inheritable because the value may have been set to
something else in the cascading process and you want to override it.

In XSL it also makes sense, but for shorthand properties. For example
you might have (probably as the result of the expansion of a
use-attribute-set): font="bold 12pt helvetica" font-size="inherited".
font-size is inherited by default but you still have to specify it to
override the shorthand property.

Does this answer your question?

Max.

Received on Tuesday, 20 February 2001 07:37:25 UTC