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

RESOLVED DUPLICATE of bug 1149357

Status

()

RESOLVED DUPLICATE of bug 1149357
2 years ago
6 months ago

People

(Reporter: wisniewskit, Unassigned)

Tracking

unspecified
Points:
---

Firefox Tracking Flags

(firefox54 affected, firefox55 affected, firefox56 affected)

Details

(Whiteboard: [webcompat])

Attachments

(1 attachment)

(Reporter)

Description

2 years ago
Created attachment 8891579 [details]
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?
status-firefox54: --- → affected
status-firefox55: --- → affected
status-firefox56: --- → affected
Flags: webcompat?
(Reporter)

Comment 1

2 years ago
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
Last Resolved: 2 years ago
Flags: needinfo?(dbaron)
Resolution: --- → DUPLICATE
Duplicate of bug: 1149357
Flags: needinfo?(josh)

Updated

6 months ago
Product: Core → Core Graveyard

Updated

6 months ago
Product: Core Graveyard → Core
You need to log in before you can comment on or make changes to this bug.