Hello everybody,

I am currently playing with the 'font' shorthand property. According to the spec (1) the values for 'font-size' and 'font-family' must be specified at all times.

Meanwhile, 'font' also serves as the only way to set a system font as a value for 'font-family'.

Furthermore the spec states: "System fonts may only be set as a whole; that is, the font family, size, weight, style, etc. are all set at the same time. These values may then be altered individually if desired."

That sounds to me like

  button { font: 1em menu; }

should be the correct minimal form. Instead it must be written as:

  button { font: menu; }

which then can be altered via single properties. This seems to violate the "last two values are mandatory" rule.

Further reading brings me to (2). Here it says: "So a simple value like 'icon' embodies a whole lot of other values." So the system font keywords are an exception to the above rule, correct?

Should this exception not be noted/explained further in the specification?

Any pointers towards the path of enlightenment are most welcome.

Jørgen W. Lang

1) http://www.w3.org/TR/CSS2/fonts.html#font-shorthand
2) http://bit.ly/mSZ0bA (CSS TDG Ch 13, Google Books)

______________________________________________________________________
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to