- From: Frank Boumphrey <bckman@ix.netcom.com>
- Date: Mon, 6 Apr 1998 11:44:52 -0700
- To: "John Ky (HxG)" <z2206460@student.unsw.edu.au>, "STYLE" <www-style@w3.org>
- Message-ID: <01bd618c$15c21ac0$9bacdccf@uspppBckman>
em takes on a different meaning in CSS to the usual typographic term. In Typography, 6em's=1 inch, in CSS an em is the height of the actual font, inluding internal leading, (so the em of a 12 pt nuptial glyph and a 12pt arial gyyph are identical). If the base font of the containing box is a 12 point font then 1em= 1/6th of an inch. Note also that if you set the margin property to 1em it will (should) take the measurement from the font of the containing box, not the box you are creating so: <DIV STYLE="font-size:12pt"> <DIV STYLE="margin-left:1em;font-size:36pt"> The left margin in this element should be 12pt not 36pt. </DIV> </DIV> On the other hand the ex unit refers not to the width, but the height of the x character (or equivalent in non-ascii glyphs), so the ex unit will (should!!, implementation of this property is spoty at best) be different in a Nuptial and an Arial font. Hope this clears it up. Frank -----Original Message----- From: John Ky (HxG) <z2206460@student.unsw.edu.au> To: STYLE <www-style@w3.org> Date: Monday, April 06, 1998 5:19 AM Subject: Units of measurements I'm a little concerned about the way the em and ex units used in style sheets are implemented in IE4. I chose to use a monospaced font and specified a left margin of 1 em unit and found the margin did not match the width of the character 'm'. Rather it turned out about 1.5 times larger than the 'm' character. Also, the ex unit turned out to be slightly less than the width of the 'x' character. Because of this, I am unable to specify a margin that is a multiple of the width of the characters in a monospaced font. Can someone explain why this is so? The problem also exists in NN4.
Received on Monday, 6 April 1998 11:44:36 UTC