Incorrect mouse event area on scaled SVG elements

Confirmed Issue #9481381 • Assigned to Kevin B.

Details

Author
Vasco A.
Created
Oct 22, 2016
Privacy
This issue is public.
Found in
  • Microsoft Edge
  • Internet Explorer
Reports
Reported by 1 person

Sign in to watch or report this issue.

Steps to reproduce

It seems that the mouse events area of SVG elements gets rounded to the nearest px boundary of the native element dimensions before scaling is applied. Which results in a pixelated event area when you’re scaling up an element which native resolution is sub-pixel.

This example highlights the issue:
http://bl.ocks.org/vasturiano/75a04dc471ed4b8d6b396c9fc702ff6d

Current workarounds are:

  • Avoid scaling for elements with mouse events, which is a large hit in the abstraction of the layout.
  • Always calculate element dimensions 1eN times bigger, and then scale down by the same amount. But it’s hacky code and unnecessary clutter.

Issue reproduceable up to IE Edge 38.

Attachments

0 attachments

    Comments and activity

    • Microsoft Edge Team

      Changed Assigned To to “Ibrahim O.”

      Changed Assigned To from “Ibrahim O.” to “Kevin B.”

      Changed Status to “Confirmed”

    You need to sign in to your Microsoft account to add a comment.

    Sign in