IE11 CanvasRenderingContext2D.measureText is wrong for Surrogate Pair+IVS

Won’t fix Issue #9711523

Details

Author
Koji N.
Created
Nov 8, 2016
Privacy
This issue is public.
Found in
  • Internet Explorer
Reports
Reported by 1 person

Sign in to watch or report this issue.

Steps to reproduce

When text includes characters that is surrogate pair+IVS, CanvasRenderingContext2D.measureText(text).width is wrong.
It seems the width is doubled.

var context = document.createElement("canvas").getContext("2d");

//Surrogate pair only
console.log(context.measureText("\u{26270}").width);

//Surrogate pair + IVS
//It seems width is doubled in IE11.
console.log(context.measureText("\u{26270}\u{E0101}").width);

Note that since IE11 does not support ES6, the above code will not work.
The attached HTML works with IE11.

Attachments

Comments and activity

  • Microsoft Edge Team

    Changed Assigned To to “Brad E.”

    Changed Status to “Won’t fix”

  •  

    Thank you for your
    feedback and sorry to hear that you are having difficulties with Internet
    Explorer. However we’re not presently working on feature bugs in Internet
    Explorer outside of security-related issues.

    Alternatively, if
    you have a premier support contract you can visit
    https://premier.microsoft.com

    and open
    a support incident and work with an engineer to address this issue.

     

    Best regards,

    The MS Edge Team

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

Sign in