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

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 UTC