T
Toby A Inkster
brucie said:i'm saying that the <body> element is the available canvas area of the
browser, not the <html> element.
What about if I do:
head, title { display: block; }
?
All current browsers treat <html> as the available canvas area.
Opera (sensibly) has a default <body> margin and <html> padding of 0.
Internet Explorer and Mozilla however set the <html> padding to 0 and the
<body> margin to some positive value (1em?). This leaves a gap of <html>
showing between the site contents and the browser chrome.
However, when web designers set body { background: whatever; } in CSS,
they don't expect a gap of unstyled <html> around their page, so IE and
Mozilla both have a bunch of special case code to "inherit" the <body>
background to <html> if <html> doesn't have its own background set. (I
think that this is probably where IE's attachment:fixed limitation comes
from?)
Mozilla and IEs code is a mess.