Closed Bug 234578 Opened 22 years ago Closed 21 years ago

clear: right doesn't work with float: right and vice versa

Categories

(Core :: Layout: Floats, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: bugzilla1, Unassigned)

References

()

Details

(Keywords: testcase)

Attachments

(1 file)

User-Agent: Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040206 Firefox/0.8 Taken from page: The two colored boxes above are left and right floated boxes. Left comes first in the source, right second, and both are followed by a flowed header ("The Setup") that has 'clear: right' applied to it. The floats have a fixed pixel width. That's basically all there is to it. The body is margined a bit, and the main header is absolute, so it is not involved with this demo in any important way. So you're asking "what's the big deal?". Well, when opposing floats like this cannot both fit side by side in a container, the second one is forced below the first. In this case the green right float would go below the red left float (but still remain floated to the right). Since the header is cleared for right floats, it should appear below the right float. The Bug In Mozilla that does not happen. Instead, if the screen is narrowed enough to cause a float wrap, the header (and the following flowed elements) begin up alongside the left float! In fact, the content is broken into two sections. Reproducible: Always Steps to Reproduce: 1. Load page 2. Resize browser window 3. Actual Results: Text flowed in wrong place Expected Results: A different rendering of text placement
Summary: clear: right doesn't work with float: right → clear: right doesn't work with float: right and vice versa
Attached file simplified test case
Simplified test case - width's/border's are only present to make seeing the bug easier - the bug occurs without them as well. Just make the window narrower and watch the result.
I see what the reporter see in LInux 2004031607
OS: Windows XP → All
I confirm too, with a 2004-04-06 linux build
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: testcase
Confirmed on both testcase and URL. - Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8a) Gecko/20040512 Firefox/0.8.0+ - Microsoft Windows 2000 Pro 5.00.2195 SP4
I think this was fixed by fixing bug 148994. The testcase shows the bug in: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8a2) Gecko/2004-06-07 Firefox/0.8.0+ The testcase doesn't show the bug in: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8a2) Gecko/2004-06-09 Firefox/0.8.0+ See also the story in the url's testcase at the bottom. (At the "Correction:")
Confirming fixed.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: