Closed Bug 549184 Opened 14 years ago Closed 14 years ago

A line box containing an inline element with padding is rendered as zero height

Categories

(Core :: Layout: Block and Inline, defect, P2)

x86
Windows XP
defect

Tracking

()

RESOLVED FIXED
Tracking Status
blocking2.0 --- final+

People

(Reporter: fassino, Assigned: roc)

References

Details

(Keywords: regression, testcase)

Attachments

(2 files)

The testcase is rendered differently in: 

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.3a2pre) Gecko/20100227 Minefield/3.7a2pre (.NET CLR 3.5.30729)

and in:

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6

Essentially a 
<div><span style="padding-left: 1em"></span></div>
is now rendered as zero height, which I don't think is correct.

The same occurs with margin instead of padding.
Almost certainly, yes.
Blocks: 538935
blocking2.0: --- → ?
Assignee: nobody → roc
Attached patch fixSplinter Review
This backs out the patch for bug 538935, reverting LineIsEmpty to mean that all frames on the line return true for nsIFrame::IsEmpty. Then we refix bug 538935 by adding a new flag that is set when all non-span frames on the line are empty.
Attachment #429469 - Flags: review?(dbaron)
Whiteboard: [needs review]
Though, one thing I'm worried about:  do we depend on TEXT_START_OF_LINE being set during intrinsic width computation?   That happens before reflow.  (I guess if we do, it's an existing problem, though.)
(In reply to comment #5)
> Though, one thing I'm worried about:  do we depend on TEXT_START_OF_LINE being
> set during intrinsic width computation?

I don't think we do.
Whiteboard: [needs review] → [needs landing]
http://hg.mozilla.org/mozilla-central/rev/58864f51e68e
Status: NEW → RESOLVED
Closed: 14 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Whiteboard: [needs landing]
blocking2.0: ? → final+
Priority: -- → P2
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: