Closed Bug 3458 Opened 26 years ago Closed 26 years ago

ignoring right on inline elements

Categories

(Core :: Layout, defect, P2)

x86
Windows 95
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: dbaron, Assigned: buster)

References

()

Details

There is one problem with combining horizontal relative positioning and margins of inline elements. It happens with both inline and replaced elements, so you can see it in the last two tests (possibly four - I plan to expand the test a little to help isolate the problem) of these two pages: non-replaced: http://www.fas.harvard.edu/~dbaron/csstest/sec100301 replaced: http://www.fas.harvard.edu/~dbaron/csstest/sec100302 The problem is that right: -10px; margin-right: 20px; puts all 20px of space on the right side of the element, rather than 10px on each side.
For the non-replaced elements, the problem is simply that you are ignoring "right" altogether. If left is auto, then left:=-right, otherwise right := - left (per CSS2 errata). I should add a simple "right" test. For the replaced elements, the problem seems as I described it before, and therefore shows on all four tests at the end.
Summary: horizontal relative positioning and margins of inline elements → ignoring right on inline elements
Whoops... typo in the tests (forgot to change the class="" on the second test!). The problem is now much simpler: You are ignoring right on inline elements. Fix is as described for non- replaced elements in my previous comment. Retitling bug to "ignoring right on inline elements" (from "horizontal relative positioning and margins of inline elements")
Assignee: troy → kipp
Status: NEW → ASSIGNED
This seems to have been fixed.
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
Fixed during recent line-layout/inline-reflow rework. The values computed by the html-reflow-state (thanks troy!) work dandy.
Status: RESOLVED → VERIFIED
Verified fixed.
You need to log in before you can comment on or make changes to this bug.