|
Posted by Steve Pugh on 11/22/78 11:39
Mark Parnell wrote:
> Deciding to do something for the good of humanity, John Salerno
> <johnjsal@NOSPAMgmail.com> declared in alt.html:
>
> > I know em is relative to its ancestors, but I don't
> > see how that works here.
>
> No it's not. It's always relative to the user's default font size.
No, 1em = the current font size, which may or may not be relative to
the user's default.
silly example:
body [font-size: 15pt;}
p {margin: 2em;}
"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."
http://www.w3.org/TR/CSS21/syndata.html#length-units
Steve
Navigation:
[Reply to this message]
|