Closed
Bug 550889
Opened 14 years ago
Closed 14 years ago
"ASSERTION: Invalid computed height: 'aComputedHeight >= 0'" with negative margins and display:block in XUL
Categories
(Core :: Layout, defect)
Core
Layout
Tracking
()
RESOLVED
FIXED
mozilla1.9.3a5
People
(Reporter: mstange, Assigned: mstange)
References
Details
Attachments
(2 files, 1 obsolete file)
311 bytes,
application/vnd.mozilla.xul+xml
|
Details | |
1.27 KB,
patch
|
bzbarsky
:
review+
|
Details | Diff | Splinter Review |
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.3a3pre) Gecko/20100307 Minefield/3.7a3pre Loading the testcase causes nsFrame::BoxReflow to pass negative values to SetComputedHeight. I'm hitting this assertion in bug 547787 because I'm using ::before and ::after with negative margins. (I need to set display: block on them because display: -moz-box will give me the warning "XUL box for _moz_generated_content_before element contained an inline #text child, forcing all its children to be wrapped in a block.")
Assignee | ||
Comment 1•14 years ago
|
||
the other testcase was wrong
Attachment #431103 -
Attachment is obsolete: true
Comment 2•14 years ago
|
||
> Loading the testcase causes nsFrame::BoxReflow to pass negative values to
> SetComputedHeight.
Sounds like a bug in nsFrame::BoxReflow. Want to fix?
Assignee | ||
Comment 3•14 years ago
|
||
I'm not sure how to. Why does it add the margins to the width / height at all?
Comment 4•14 years ago
|
||
Possibly because in the XUL box model there's really no good place to put the margins? One of the neils might know better...
Assignee | ||
Comment 5•14 years ago
|
||
Neil, do you know what to do here?
Assignee | ||
Comment 6•14 years ago
|
||
Ah, some lines further down there's this code: computedHeight = NS_MAX(computedHeight, 0); reflowState.SetComputedHeight(computedHeight); Should we just do the same here?
Comment 7•14 years ago
|
||
That should generally be done at SetComputedHeight callsites that can't guarantee non-negative numbers, yes.
Assignee | ||
Comment 8•14 years ago
|
||
Comment 9•14 years ago
|
||
Comment on attachment 438255 [details] [diff] [review] v1 r=bzbarsky. Sorry for the terrible lag here...
Attachment #438255 -
Flags: review?(bzbarsky) → review+
Assignee | ||
Comment 10•14 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/985cdfad1c7e
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Assignee | ||
Updated•14 years ago
|
Target Milestone: --- → mozilla1.9.3a5
You need to log in
before you can comment on or make changes to this bug.
Description
•