Closed
Bug 191151
Opened 22 years ago
Closed 20 years ago
[FIXr]Make nsCSSFrameConstructor::GetGeometricParent()
Categories
(Core :: Layout: Floats, defect, P2)
Core
Layout: Floats
Tracking
()
RESOLVED
FIXED
mozilla1.8beta1
People
(Reporter: john, Assigned: bzbarsky)
Details
Attachments
(2 files, 2 obsolete files)
461 bytes,
text/html
|
Details | |
41.64 KB,
patch
|
roc
:
review+
roc
:
superreview+
|
Details | Diff | Splinter Review |
There are a number of places in nsCSSFrameConstructor that get the "geometric parent" of a frame--the parent frame in the visual hierarchy rather than the logical content hierarchy. Nearly all of them do this in exactly the same way. It should be factored out into GetGeometricParent().
Reporter | ||
Comment 1•22 years ago
|
||
This patch runs and builds happily and survives under my typical mail / web daily usage. However, it does change one thing: many places that were calculating the geometric parent were not taking floating into account with the geometric parent, so I made them do that. However, I do not yet have sufficient knowledge of the intricacies of floating to construct testcases that may fail when this happens. troy checked in the fix that made most elements do this, and indicated that (at least at that time) there was an actual problem. http://bonsai.mozilla.org/cvsblame.cgi?file=mozilla/layout/html/style/src/nsCSSFrameConstructor.cpp&rev=1.156#2665 Two things I'd like to do as well: - stop passing around aIsAbsolutelyPositioned and aIsFixedPositioned--maybe even stop grabbing them in the main function if it turns out to be useful - make nsIFrame have virtual method(s) to determine whether the frame supports positioning / floating--that information does *not* belong in nsCSSFrameConstructor where it currently resides (canBePositioned). Testcases for the above problem or hints on how to make them are appreciated.
Assignee | ||
Comment 2•20 years ago
|
||
I was about to file this bug. Taking. I'll attach a slew of testcases for the various places in CSSFrameConstructor that get this wrong... John's patch is a good place to start.
Assignee: john → bzbarsky
OS: Windows XP → All
Hardware: PC → All
Assignee | ||
Comment 3•20 years ago
|
||
Assignee | ||
Comment 4•20 years ago
|
||
Fieldsets and selects manage to work somehow, but I'm not sure how.
Assignee | ||
Comment 5•20 years ago
|
||
Attachment #113000 -
Attachment is obsolete: true
Assignee | ||
Comment 6•20 years ago
|
||
Comment on attachment 160120 [details] [diff] [review] Proposed patch Alex, would you review the SVG changed? David, would you review the rest? I'm not set on the svg stuff, since my changes may have some memory/perf impact... so if people don't like it, I'll revert it.
Attachment #160120 -
Flags: superreview?(dbaron)
Attachment #160120 -
Flags: review?(alex)
Assignee | ||
Comment 7•20 years ago
|
||
ccing the svg folks and rbs (for the mathml changes, but they were non-substantive, except for floated mathml).
Priority: -- → P2
Target Milestone: --- → mozilla1.8beta
Assignee | ||
Updated•20 years ago
|
Summary: Make nsCSSFrameConstructor::GetGeometricParent() → [FIX]Make nsCSSFrameConstructor::GetGeometricParent()
I can review this if David wants to delegate it to me.
Assignee | ||
Comment 9•20 years ago
|
||
Comment on attachment 160120 [details] [diff] [review] Proposed patch Actually, the svg changes are wrong, because we may end up with an <svg> inside HTML inside a <foreignobject>. Fixed patch coming up in a sec.
Attachment #160120 -
Flags: superreview?(dbaron)
Attachment #160120 -
Flags: superreview-
Attachment #160120 -
Flags: review?(alex)
Attachment #160120 -
Flags: review-
Assignee | ||
Comment 10•20 years ago
|
||
The only change this makes to svg is to make it possible to float or fixed-position "outermost" <svg> elements.
Attachment #160120 -
Attachment is obsolete: true
Assignee | ||
Comment 11•20 years ago
|
||
Comment on attachment 160154 [details] [diff] [review] Patch that doesn't change SVG behavior Pinging roc for review, since he volunteered (and since there are no longer substantive SVG changes here, r+sr should be ok, I think).
Attachment #160154 -
Flags: superreview?(roc)
Attachment #160154 -
Flags: review?(roc)
Comment on attachment 160154 [details] [diff] [review] Patch that doesn't change SVG behavior + // If there is no container for a fixed, absolute, or floating table because + // it is the root content frame, we will ignore the positioning. Rephrase this to make it clear that as implemented, this hack applies to all elements, not just tables. + // XXXbz roc says stacks do, or should.... Take this out since I'm not sure...
Attachment #160154 -
Flags: superreview?(roc)
Attachment #160154 -
Flags: superreview+
Attachment #160154 -
Flags: review?(roc)
Attachment #160154 -
Flags: review+
Assignee | ||
Updated•20 years ago
|
Summary: [FIX]Make nsCSSFrameConstructor::GetGeometricParent() → [FIXr]Make nsCSSFrameConstructor::GetGeometricParent()
Assignee | ||
Comment 13•20 years ago
|
||
Fixed on trunk for 1.8a5.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 14•20 years ago
|
||
Note: this broke absolute positioning of tables. See bug 262898 (which has a fix).
You need to log in
before you can comment on or make changes to this bug.
Description
•