When it comes right down to it, positioning is a very compelling technology. It's also likely to be an exercise in frustration if you're trying to get it to behave consistently in a cross-browser environment. The problem isn't so much that it won't work in some browsers: it's that it will only sort of work in a number of them, such as Navigator 4 and Internet Explorer 4 and 5. It can be great fun to play with positioning, and one day we'll be able to use it in place of tables and frames while dramatically improving accessibility and backward compatibility. As of this writing, though, it remains a great way to create design prototypes, but a tricky thing to use on a public web site.
As it happens, this sentiment may be applied to the majority of CSS2,
As opposed to the size of a font, which will be discussed in Chapter 5, "Fonts", line-height refers to the distance between the baselines of lines of text -- sort of. In fact, this property determines the amount by which the height of each element's line box is increased or decreased. In the simplest cases, it's which is given an overview in the next chapter.
Copyright © 2002 O'Reilly & Associates. All rights reserved.has a line-height of 12px,since line-height is an inherited property. Whathappens is that the difference between font-sizeand line-height is divided in half, and thenapplied to the top and bottom of each element's content-heightto arrive at the inline box. Each halfof the divided difference is referred to ashalf-leading. the border, but the background has to go through the padding before it even gets to the border.
The default value of padding is 0 (zero), and padding values cannot be negative.