Closed Bug 1385517 Opened 3 years ago Closed 3 years ago

inline-block/floated parent of <picture> with a srcset/2x on HiDPI monitor is twice as wide as the image

Categories

(Core :: Layout: Images, Video, and HTML Frames, defect)

defect
Not set

Tracking

()

RESOLVED DUPLICATE of bug 1149357
Tracking Status
firefox54 --- affected
firefox55 --- affected
firefox56 --- affected

People

(Reporter: wisniewskit, Unassigned)

References

Details

(Whiteboard: [webcompat])

Attachments

(1 file)

Attached file testcase.html
In the attached testcase there is a <picture> element with a srcset that has a 2x green image option. That <picture> is in an inline-block element with a red background.

When the picture is rendered on a HiDPI display (at least on my Intel Iris MacBook Pro), then that parent element ends up being twice the width as the rendered image. The parent element can also be floated to achieve the same effect.

Other browsers do not do this, and on a regular DPI screen the behavior doesn't seem to manifest (or when there is no "2x" image option in the srcset).
Flags: webcompat?
Flags: webcompat?
jdm, do you have any thoughts on this?
Flags: needinfo?(josh)
Flags: needinfo?(aschen)
Last good revision: ad587ca628cf (2015-03-28)
First bad revision: 385840329d91 (2015-03-29)
Pushlog:
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=ad587ca628cf&tochange=385840329d91
Flags: needinfo?(aschen)
I suspect bug 1139560 made this srcset value be parsed correctly, but is not actually the cause of the layout issue here.
(In reply to Josh Matthews [:jdm] from comment #3)
> I suspect bug 1139560 made this srcset value be parsed correctly, but is not
> actually the cause of the layout issue here.

Yes, it seems the case.
I found that <img> render was broken first(no layout issue before it's broken) and then layout issue introduced within this broken period and appeared after bug 1139560.
David, this bug could be a dupe of bug 1149357. Can you help to confirm? Thanks.
Flags: needinfo?(dbaron)
Status: NEW → RESOLVED
Closed: 3 years ago
Flags: needinfo?(dbaron)
Resolution: --- → DUPLICATE
Duplicate of bug: 1149357
Flags: needinfo?(josh)
Product: Core → Core Graveyard
Product: Core Graveyard → Core
You need to log in before you can comment on or make changes to this bug.