Open Bug 1499027 Opened 6 years ago Updated 2 months ago

Inline position absolute layout bug

Categories

(Core :: Layout: Block and Inline, defect, P3)

62 Branch
x86_64
All
defect

Tracking

()

People

(Reporter: luke, Unassigned)

References

(Depends on 1 open bug)

Details

(Keywords: regressionwindow-wanted)

Attachments

(1 file, 1 obsolete file)

Attached file ff-bug.html
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.1.2 Safari/605.1.15

Steps to reproduce:

Please open the attached html document. Resize the browser's width to trigger vary the paragraph's width, and watch the red box trailing the anchor in the paragraph.


Actual results:

The red box is sometimes drawn several lines above where it is meant to be drawn. There does not appear to be an issue with the box placement on the X axis, but the Y axis is often incorrect.


Expected results:

The red box should always be drawn on the same line as the anchor, in between the blue text and the period.
OS: Unspecified → Mac OS X
Hardware: Unspecified → x86_64
It seems that when the bounding box for the anchor crosses over 2 lines, the red box is drawn relative to the top line, and not the box as a whole. `bottom: -3px` should be relative to the box of the entire anchor. Setting `display: inline-block` on the anchor does "fix" the issue, but the anchor will no longer break over multiple lines.
I can also reproduce the issue on Nightly64.0a1 Windows10 x64.
Status: UNCONFIRMED → NEW
Component: Untriaged → Layout: Block and Inline
Ever confirmed: true
OS: Mac OS X → All
Product: Firefox → Core
This triggers a bunch of warnings like:

> We shouldn't be backing up more than once! Someone must have set a break opportunity beyond the available width, even though there were better break opportunities before it.

When run in a debug build, fwiw.

Do you know if this is a regression? i.e., has this worked in earlier Firefox versions? If so it'd be really helpful to know.
Nice testcase!

I don't think this is a recent regression, at least. We have some existing bugs on file that involve hitting this same assertion, though I don't know offhand if this is directly equivalent to any of them: e.g. bug 1140279, bug 1486541. Back in bug 512978 it was only a warning, apparently, but may still be the same issue.
See Also: → 1140279, 1486541, 512978
@jfkthame @emilio

I tested back to version 40.0, and I could reproduce this issue in every major version between 62.0 and 40.0 (macOS).
A further observation: when the width is such that the testcase displays incorrectly, the position of the red box may be quite unstable (as well as wrong); reloading the page or zooming in and then out again may cause it to shift to a new -- but still incorrect -- position. (Results vary depending on the exact width/line-break involved.)
This may be similar to bug 779896 and bug 1144259, and may be fixed by doing bug 255139.
Depends on: 255139
See Also: → 779896, 1144259
Priority: -- → P3
Severity: normal → S3

The severity field for this bug is relatively low, S3. However, the bug has 5 See Also bugs.
:jfkthame, could you consider increasing the bug severity?

For more information, please visit auto_nag documentation.

Flags: needinfo?(jfkthame)

The last needinfo from me was triggered in error by recent activity on the bug. I'm clearing the needinfo since this is a very old bug and I don't know if it's still relevant.

Flags: needinfo?(jfkthame)
Attachment #9387633 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: