Open Bug 979834 Opened 10 years ago Updated 2 years ago

{inc} Text is not correctly re-flown around floating elements on resize

Categories

(Core :: Layout: Floats, defect, P4)

27 Branch
defect

Tracking

()

People

(Reporter: post+mozilla, Unassigned)

References

Details

(Keywords: regression, testcase)

Attachments

(2 files)

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:27.0) Gecko/20100101 Firefox/27.0 (Beta/Release)
Build ID: 20140212131424

Steps to reproduce:

I wrote a website that has a div floating to the left with a fixed width of 5em, and another div with a max-width of 50em and a margin of "0 auto" (so that it's horizontally centred). Then I kept resizing the Firefox window.


Actual results:

The text in the centred div is not re-flown correctly when the floating box moves to the outside, leaving a "dent" in the text where there should be none.


Expected results:

The text should have been re-flown correctly. Pressing "F5" without changing window size causes Firefox to re-compute everything, and then the page looks correct.

I will attach a small example page demonstrating the issue, and a screenshot.
Here's the promised screenshot. The "dent" in the text in the middle shouldn't be there, and it goes away when pressing F5.

I also just tried this in the current Firefox 28 beta, which shows the same issue.
Regression window
Good:
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9a1) Gecko/20061207 Minefield/3.0a1
Bad:
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9a1) Gecko/20061208 Minefield/3.0a1
Bonsai log:
http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2006-12-07+00%3A00%3A00&maxdate=2006-12-08+03%3A00%3A00&cvsroot=%2Fcvsroot

Triggered by:
Bug 300030 - (reflow-refactor) Refactor intrinsic width computation out of nsIFrame::Reflow
Keywords: regression
OS: Linux → All
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: testcase
Priority: -- → P4
Hardware: x86_64 → All
Summary: Text is not correctly re-flown around floating elements on resize → {inc} Text is not correctly re-flown around floating elements on resize
To fix this and bug 1234011, I think we need to make the last bit of nsBlockFrame::PropagateFloatDamage, currently conditioned on:
  // Check if the line is moving relative to the float manager
  if (aDeltaBCoord + aState.mReflowState.mBlockDelta != 0) {
also test for horizontal movement relative to the float manager.
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: