W3C home > Mailing lists > Public > www-style@w3.org > March 2012

Re: [CSS3-fonts] Proposal: Allow a font name as value for font-size-adjust

From: Markus Ernst <derernst@gmx.ch>
Date: Tue, 06 Mar 2012 23:31:26 +0100
Message-ID: <4F56903E.5020302@gmx.ch>
To: Brad Kemper <brad.kemper@gmail.com>
CC: "Tab Atkins Jr." <jackalmage@gmail.com>, "www-style@w3.org" <www-style@w3.org>
Am 06.03.2012 21:37 schrieb Brad Kemper:
> But font-size-adjust is for when the first font isn't available, the the size of the font that is available gets adjusted.

This applies only for "typical usage", as the spec says: "This value 
applies to any font that is selected but in typical usage it should be 
based on the aspect value of the first font in the font-family list."

But as it works for all fonts in the list including the first one, many 
authors will use some incidental value such as 0.5 instead of bothering 
to find out the correct value for their font of first choice, and then 
correct the font-size to achieve their preferred appearance.

My proposal just makes font-size-adjust a little more intuitive. In 
cases where the property is used with a font name instead of a number, 
the "typical usage" would be to apply the most general of the 
non-generic font names, as in:

font-family: Calibri, "Lucida Grande", Arial, sans-serif;
font-size-adjust: Arial;

The author then applies a font-size that is perfect for Arial, and the 
adjusting happens if Calibri or Lucida Grande is available.

> If the font isn't available, and it is thus ignored, then when would there ever be a font that applies its x-height to another font? The first font available would always adjust to its own existing x-height.

Exactly. Wrong usage will have no effect in this case, the font is just 
displayed according to the font-size (as it is in legacy browsers, too). 
I think this is actually no problem, there is even less harm potential 
than in the use of font-size-adjust with a number.
Received on Tuesday, 6 March 2012 22:32:00 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 22 May 2012 03:48:51 GMT