Quote:
Originally Posted by Rev. Bob
Completely platform-dependent. W3C originally recommended a 1.5x factor between each step in CSS1, then changed their mind and decided 1.2x was better in CSS2, and is now rethinking it yet again. That said, their new table translates to:
H6/xx-small: 0.6em
x-small: 0.75em
H5/small: 0.89em (8/9)
H3/large: 1.2em
H2/x-large: 1.5em
H1/xx-large: 2em
Just don't expect to see that etched in stone anywhere. It's a suggestion, not a set of ironclad rules, and implementations will differ.
No, that's called paying attention to detail. If you want exactly 1em (absolute) of space between lines that are not 1em tall, you have to set the appropriate vertical margin to the reciprocal of the active font size. Simply saying "margin-top: 1em" won't do it; that 1em is relative to the element's current size, not an absolute value.*
In other words, the H2 element traditionally carries a 1em (relative) top and bottom margin. If it also carries the 1.5em (absolute) font size listed above, then the gap between two consecutive H2 elements will be 1.5em (absolute) - translating to "skip a line between H2 elements."
Thus, if you want an actual 1em (absolute) space between those elements, you have to tinker with the margins by setting them to 0.6667em (relative). That way, 0.6667 x 1.5 = 1, and you get what you're after: a gap the size of a line of standard body text.
|
No that is what is called over thinking and applying a Rube Goldberg solution to a non problem. Doing stuff like that is what makes ebooks look crappie and turns people off from them.
What works on paper does not necessary work on screen, especially small screens.
The KISS principle works best
bernie.