Closed Bug 4833 Opened 26 years ago Closed 26 years ago

pseudo-elements cannot be positioned

Categories

(Core :: Layout, defect, P3)

Other
Other
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: dbaron, Assigned: troy)

References

()

Details

You should ignore positioning (absolute and relative) on :before and :after pseudo-elements. The above test case describes the correct behavior. The problems are in the :after of the second test and the :before of the third test.
Status: NEW → ASSIGNED
Target Milestone: M6
Other problems in this page are described in bug 4834.
Target Milestone: M6 → M5
I have a fix for this in my tree, and I'll check it in when the tree opens. BTW, there's a missing ';' in your test which is why "The end." isn't displayed: P.two:after { position: absolute; /* ignored */ top: 0; left: 0; content: " The end." border-left: inherit; }
Thanks for the fix. That shows you are ignoring absolute positioning (I thought it was getting positioned and clipped). So the only problem is/was relative positioning (other than bug 4834).
Yes, exactly right. The generated code code is doing the correct thing and ignoring positioning and float, i.e. it's nit moving the frame out of the flow The problem is that the nsHTMLReflowState code (used during reflow) is seeing the 'position' property set and computing the constraints as if the element were relatively positioned. My fix is to reset the style information so 'position' is set to 'normal' which fixes the problem
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
Status: RESOLVED → VERIFIED
Verified fixed.
You need to log in before you can comment on or make changes to this bug.