Sent by Gary Bland on 21 June 2002 15:03
Big John wrote:
> That's just it. It's the computed value that is getting
> inherited, not the number. I believe this is so because
> when I apply the same line-height value used in 'body' to
> the descendant div, the font-size on that div now controls
> the line-height.
>
> Before, the div's rendered line-height was whatever the
> computed global value happened to be, no matter what
> font-size was put on the div. Take away the global
> line-height, and no problem.
Big John wrote:
t's just it. It's the computed value that is getting
> inherited, not the number. I believe this is so because
> when I apply the same line-height value used in 'body' to
> the descendant div, the font-size on that div now controls
> the line-height.
>
> Before, the div's rendered line-height was whatever the
> computed global value happened to be, no matter what
> font-size was put on the div. Take away the global
> line-height, and no problem.
>
Hi Big John,
In a perfect world your assumptions are correct, line-height should
change according to the height of the text being used/declared. In the
world of X's and 0's declaring something globally mean that it should
act the same across the code unless you change the rule for a block of
code. So the browsers are probably doing it correctly by making you
change the rule.
In print, they deal mostly pts and ems and use some expensive software
designed to automate the task. Can you imagine what it would take to
make a browser rendering engine automate the line-height task for
Keywords, pt, px, em, cm, mm, Picas, cxs, and %? What day would you want
the page rendered on?
gary