New TextMetrics object in canvas

The implementation of an extended API of text metrics started in 2014: https://groups.google.com/a/chromium.org/d/msg/blink-dev/SgofW_bQ3ps/jNYamQHplAMJ But was never shipped, and had multiple undefined values that were not addressed for years. The spec has now evolved and we intend to ship actualBoundingBoxLeft, actualBoundingBoxRight, actualBoundingBoxAscent and actualBoundingBoxDescent according to the current spec: https://html.spec.whatwg.org/multipage/canvas.html#textmetrics

Comments

This is an important API that had a lot of requests from developers.

Specification

Editor's draft

Status in Chromium

Blink>Canvas


Enabled by default (tracking bug) in:

  • Chrome for desktop release 77
  • Chrome for Android release 77
  • Android WebView release 77

Consensus & Standardization

After a feature ships in Chrome, the values listed here are not guaranteed to be up to date.

Owners

Last updated on 2019-08-15