Closed
Bug 189758
Opened 23 years ago
Closed 23 years ago
<p> tag has whitespace rendered above text when DOCTYPE defined, but no space without DOCTYPE
Categories
(Core :: Layout, defect)
Tracking
()
RESOLVED
INVALID
People
(Reporter: mathgod79, Unassigned)
References
()
Details
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.2.1) Gecko/20021130
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.2.1) Gecko/20021130
Well, I think this is a bug. If this is aprt of some HTML spec, please let me know.
Basically, look at the following pages:
http://www.chris.caseyhome.com/htmltop.html
http://www.chris.caseyhome.com/html4top.html
http://www.chris.caseyhome.com/xhtmltop.html
You'll see that the text without a DOCTYPE definition in the html is rendered
very close to the top edge. The pages with HTML 4.01 and XHTML DOCTYPES is
pushed down from the edge. IE doesn't push the text down for any of the above
URLs, and it seems to me that the text shouldn't be pushed down at all, or
should be pushed down no matter what the DOCTYPE is (or not defined).
I assume this problem exists because there is supposed to be some space between
<p> lines, so Mozilla may be putting a little space above and below each <p>
section, but I don't think there should be any space rendered above the text if
<p> is at the top of the page.
Reproducible: Always
Steps to Reproduce:
Basically, look at the following pages:
http://www.chris.caseyhome.com/htmltop.html
http://www.chris.caseyhome.com/html4top.html
http://www.chris.caseyhome.com/xhtmltop.html
Actual Results:
You'll see mozilla positions the text a bit differently depending on the doctype.
Expected Results:
I think the text should be positioned at the top of the page (no space above
it), like it is in the first URL. IE does it this way. Even if there should be
space, Mozilla should put the text at the same position regardless of the doctype.
Comment 1•23 years ago
|
||
Yes, this effect is desired for DOCTYPE. Read
http://www.mozilla.org/docs/web-developer/quirks/.
When you put document to standarts mode using doctype, Mozilla try to apply
every w3c recomendations, so there could not be collapsing border with <p> and
viewport.
But in quirks mode (wich emulate buggie behaviour of other browsers),
margin-top:0 rule apply, and border colapse occured.
In standarts mode to produce border-colapse designer SHOULD manualy set margin
to 0.
| Reporter | ||
Comment 2•23 years ago
|
||
OK, well, I have the <body style="margin:0;"> on those pages, which is what you
seem to suggest, but that still doesn't get rid of the space on top. Did I
misundarstand you, or is it impossible to get rid of the border if I use the
doctype?
Comment 3•23 years ago
|
||
Not <body>, <p style="margin: 0px">, read
http://lxr.mozilla.org/seamonkey/source/layout/html/document/src/quirk.css#122
for style of quirk mode, wich you want to emulate
Comment 4•23 years ago
|
||
I realy think this bug is same with bug 189673, so it should be resolved as
INVALID (once again, to produce border-colapse between body and P author should
use style="margin: 0px" for both body and <p> tag).
Status: UNCONFIRMED → RESOLVED
Closed: 23 years ago
Resolution: --- → INVALID
You need to log in
before you can comment on or make changes to this bug.
Description
•