Closed Bug 218473 Opened 17 years ago Closed 13 years ago

block contained in and containing a float gets not specified padding-bottom

Categories

(Core :: Layout: Floats, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: svl-bmo, Unassigned)

References

()

Details

(Keywords: testcase)

Attachments

(2 files)

2003062408 - win98 (verified to still exist in recent nightly (winxp) by Sparr
in #mozillazine)
See the url for the testcase. Three block elements nested in each other, with
the outer and inner floating, and the outer having padding-top. If the middle
element is block and not floating, an amount of padding-bottom equal to the
padding-top seems to be acquired by one of the elements, though the
dom-inspector doesn't show values for it. Floating the middle element, or making
it inline, makes the behaviour go away.
I'm not even certain this is a bug, but the behaviour doesn't make any sense to
me, so I'm assuming so. Opera 7.0 doesn't show it.
Attached file Testcase
OS: Windows 98 → All
I fear this has something to do with the space manager using a different
coordinate system from everything else (see the comment in
nsBlockReflowState::RecoverStateFrom and the code in
nsBlockFrame::ComputeFinalSize that uses nsSpaceManager::YMost).
I just ran into this today in a real site I'm working on. Actually, the top padding is not duplicated and applied as the bottom padding, but instead is added to the declared bottom padding. So if the top padding is 100px and the bottom padding is 0, the rendered bottom padding is 100px. If the top padding is 100px and the bottom padding is 50px, the rendered bottom padding is 150px. You can see this here:
http://www.pixelsurge.com/experiment/FF-bug_floats-padding-dup.html

I hope this can get fixed soon.
I just ran into this today in a real site I'm working on. Actually, the top padding is not duplicated and applied as the bottom padding, but instead is added to the declared bottom padding. So if the top padding is 100px and the bottom padding is 0, the rendered bottom padding is 100px. If the top padding is 100px and the bottom padding is 50px, the rendered bottom padding is 150px. You can see this here:
http://www.pixelsurge.com/experiment/FF-bug_floats-padding-dup.html

I hope this can get fixed soon.
Sorry for the double post -- don't know how that happened.
This got fixed by the reflow branch landing.
Status: NEW → RESOLVED
Closed: 13 years ago
Depends on: reflow-refactor
Flags: in-testsuite?
Resolution: --- → FIXED
Checked in test.
Flags: in-testsuite? → in-testsuite+
You need to log in before you can comment on or make changes to this bug.