- From: Stanimir Stamenkov <stanio@myrealbox.com>
- Date: Sat, 24 Jan 2004 17:29:19 +0200
- To: www-style@w3.org
Something I really miss about the font handling is related to the 'font-size-adjust' propery. There are actually 2 things: 1. The 'font-size-adjust' value is function of the 'font-size' and the 'x-height' font properties, only. It would be nice if the average character width is included in that function, too. I don't know if such information comes predefined in the font data but I suppose there could be used the width of the space character for the font, so there would be no need of excessive computations to be made. 2. There should be included functionallity to compensate for the font size depending on the auto-computed 'font-size-adjust' for a particular font. What I mean: Suppose a default font-family/font-size is '16px "Times New Roman"'. If one could use: E { font-family: Verdana, inherit; font-size-adjust: compensate; } the 'E' element to result in a font size such the text would have an equal visual weight as the text (font-family/font-size) of the parent element. If there's no "Verdana" font on the particular system the font-family would not change and the font will stay exactly as the parent's one. Probably the proposed functionality would need a different named property because the above 2 points introduce new incompatible behavior for the 'font-size-adjust' property. If one introduce a new property there could be added even more options, for example: font-family: "Another", inherit; font-size-compensate: 1; should result in a full (100%) "equalization" of the size in respect to the parent element's and this element's font weight (not the glyph boldnes). If one specify: font-size-compesate: 0.8; would result in a 80% "equalization", so if we have: P { font: 16px "Times New Roman", serif; } E { font-family: Verdana, sans-serif; font-size-compensate: 0.8; } <P> Parent's text. <E>Child element's text.</E> </P> where the parent element's font has a smaller, than the child element's, 'font-size-adjust' value - the child element's text size would stay somewhat larger (80% of the overall equalization) than the parent's one. But if the parent/child 'font-size-adjust' proportion is inverted (from the initial example) - the child's text would stay somewhat smaller than the parent's one. But I haven't thought over that last part, really. -- Stanimir
Received on Saturday, 24 January 2004 10:29:25 UTC