Closed
Bug 167210
Opened 23 years ago
Closed 23 years ago
BR element before H2 causes extra spacing
Categories
(Core :: Layout, defect, P3)
Tracking
()
RESOLVED
INVALID
Future
People
(Reporter: mgalli, Assigned: attinasi)
Details
Attachments
(3 files)
I will add one testcase that demonstrates the problem. The first BR Element that
is next to the H2, causes some extra spacing.
Reporter | ||
Comment 1•23 years ago
|
||
Testecase table with 4 columns.
Col 1 = have two H2 elements next to each other
Col 2 = Have one h2, br and another h2
col 3 = have one h2, br, br, h2
col 4 = have one h2, br, br, br, h2
note that the difference of height space between 2-3-4 is one br. however the
diff between col 1 and 2 is more than one BR.
Reporter | ||
Updated•23 years ago
|
Summary: BR element before H2 causes extra spacing → BR element before H2 causes extra spacing
Comment 2•23 years ago
|
||
I think this one is INVALID. In the first column, margin collapising occurs, but
in the second column there's an element between the headings so margin
collapsing does not occur and, threfore, both the margin-bottom of the top
heading and the margin-top of the bottom heading are in effect.
Comment 3•23 years ago
|
||
Henri, here are some questions/comments back:
[1]
So what is "margin collapsing" exactly? For this test case, does this term have
to do specifically with tables, meaning the margins within the columns or
something like that?
[2]
So how can the HTML be changed to "correct" the behavour? Meaning: How can it
be made such that in the first column in the test case, there is no whitespace
between the two lines? ( I tried modifying the test case #1 such that the first
column has 200 pixels of horizontal width, to see if that's what you mean by
margins as far as margins/word wrap within the column, but the white space is
still there between the two text lines, even though the text is not hitting the
right edge/margin of its cell. )
[3]
If "margin collapsing" in this case --is-- specific to tables, then I've
attached a second test case that is even more extreme (even more extremely
buggy) that shows a non-tables version, with a single BR between two H2 text
blurbs, and it seems to show 3 blank H2-sized lines between the two text
blurbs/lines (!!!!) even though only on BR in the source code exists between them.
Comment 4•23 years ago
|
||
Comment 5•23 years ago
|
||
> So what is "margin collapsing" exactly?
http://www.w3.org/TR/REC-CSS2/box.html#collapsing-margins
> For this test case, does this term have to do specifically with tables,
No.
> So how can the HTML be changed to "correct" the behavour? Meaning: How
> can it be made such that in the first column in the test case, there is
> no whitespace between the two lines?
h2 {
margin-top: 0;
margin-bottom: 0;
}
Updated•23 years ago
|
QA Contact: petersen → amar
Updated•23 years ago
|
Priority: -- → P3
Updated•23 years ago
|
Target Milestone: --- → Future
Comment 6•23 years ago
|
||
Marking INVALID as per comment #2.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → INVALID
You need to log in
before you can comment on or make changes to this bug.
Description
•