ignoring right on inline elements

VERIFIED FIXED

Status

()

P2
normal
VERIFIED FIXED
20 years ago
19 years ago

People

(Reporter: dbaron, Assigned: buster)

Tracking

Trunk
x86
Windows 95
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

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")

Updated

20 years ago
Assignee: troy → kipp

Updated

20 years ago
Status: NEW → ASSIGNED

Updated

20 years ago
Status: ASSIGNED → RESOLVED
Last Resolved: 20 years ago
Resolution: --- → FIXED

Comment 4

20 years ago
Fixed during recent line-layout/inline-reflow rework. The values computed by the
html-reflow-state (thanks troy!) work dandy.
You need to log in before you can comment on or make changes to this bug.