W3C home > Mailing lists > Public > whatwg@whatwg.org > November 2014

Re: [whatwg] How do CSS "object-position" & "object-fit" affect the coordinates used by image <map>/<area>?

From: L. David Baron <dbaron@dbaron.org>
Date: Fri, 7 Nov 2014 09:35:08 -0800
To: Daniel Holbert <dholbert@mozilla.com>
Message-ID: <20141107173508.GA31140@crum.dbaron.org>
Cc: whatwg@whatwg.org
On Thursday 2014-11-06 12:36 -0800, Daniel Holbert wrote:
> Should these coordinates be relative to...
>  (A) ...the top-left corner of the <img> element itself?
> OR
>  (B) ...the top-left corner of the rectangle where the image's pixel
> data actually maps to? (which may be inside or outside the bounds of the
> <img> element) (Of course, parts outside the <img> won't render and
> shouldn't receive clicks, but the rect is still there.)
> I tend to think "B" is the correct answer, but I'm not 100% sure, and
> I'd like a sanity-check.

I also think it should be (B), since the meaning of the coordinates
in the imagemap shouldn't change as a result of CSS styling of the


𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla                          https://www.mozilla.org/   𝄂
             Before I built a wall I'd ask to know
             What I was walling in or walling out,
             And to whom I was like to give offense.
               - Robert Frost, Mending Wall (1914)
Received on Friday, 7 November 2014 17:36:03 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 17:00:26 UTC