- From: John Russell <VE3LL@RAC.CA>
- Date: Fri, 24 Sep 1999 15:54:23 -0400
- To: www-amaya@w3.org
- Message-Id: <199909241944.PAA14947@admin.cgocable.net>
here is the file i am testing on margin and paragraph are using em measures but they appear to be using width determined by h1 size and this continues even when i drop the heading entirely. my thought would be that they should use the size of the text in the paragraph itself, not what preceeds it.... so calc of width done at wrong point ??? but i could be wrong and i find it inconsistant with other browsers... thus my question as to whether the spec is tight enuff Date forwarded: Fri, 24 Sep 1999 12:41:09 -0400 (EDT) From: Dave J Woolley <DJW@bts.co.uk> Send reply to: www-amaya@w3.org To: www-amaya@w3.org Date sent: Fri, 24 Sep 1999 17:38:15 +0100 Subject: RE: em size as margin Forwarded by: www-amaya@w3.org > > From: John Russell [SMTP:VE3LL@RAC.CA] > > > > By definition an em is the width of the letter m. > > Normally one assumes that this is measured on the > > normal text font used (either determined by the browser > > user or defined by the page designer with their font settings) > > > This is what the CSS2 spec says. Unfortunately you > don't say what element you are setting the size on. > (The sample style sheet uses the browser default as > the reference for all sizes.) > > The 'em' unit is equal to the computed value of the 'font-size' property of > the > element on which it is used. The exception is when 'em' occurs in the value > of > the 'font-size' property itself, in which case it refers to the font size of > the parent > element. It may be used for vertical or horizontal measurement. (This unit > is also > sometimes called the quad-width in typographic texts.) > > john russell VE3LL@RAC.CA homepage: http://web.cgocable.net/~jrussel
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html lang="en"> <head> <title>HTML Test Zone</title> <style type="text/css"> BODY { margin: 10em } P { text-indent: 4em } </style> </head> <body> <h1>My Big Title</h1> <p>Trivial paragraph for testing browser interpretation of settings using em notation.</p> <dl> <dt><b>A Term</b> <dd>A definition for testing. <dt><b>Another Term</b> <dd>And its definition for testing. </dl> <p>One more paragraph for testing browser interpretation of settings using em notation.</p> </body></html>
Received on Friday, 24 September 1999 15:44:08 UTC