Bug 1749242 [wpt PR 32302] - Fix letterSpacing and wordSpacing values, a=testonly
commit9cfdd616b336824d0ab6e12cb4f8e0b158d0e740
authorYi Xu <yiyix@chromium.org>
Tue, 11 Jan 2022 21:40:28 +0000 (11 21:40 +0000)
committermoz-wptsync-bot <wptsync@mozilla.com>
Wed, 12 Jan 2022 10:45:42 +0000 (12 10:45 +0000)
tree0bc8f83f5fe86aee73d21f84884c9680cbf8179d
parente998dba919b120ce436ce875c17de9f72c7fbb56
Bug 1749242 [wpt PR 32302] - Fix letterSpacing and wordSpacing values, a=testonly

Automatic update from web-platform-tests
Fix letterSpacing and wordSpacing values

According to the WhatWG spec letterSpacing and wordSpacing returns
the serialized CSS <length> value. The following should hold:
ctx.letterSpacing = '5PX'
ctx.letterSpacing // returns 5px. (lowercase)

Updated code to fix this issue.

Bug: 1263632

Change-Id: Ic894e322f6ad5e27f3d299114674b77e319b9656
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3376722
Reviewed-by: Aaron Krajeski <aaronhk@chromium.org>
Commit-Queue: Yi Xu <yiyix@chromium.org>
Cr-Commit-Position: refs/heads/main@{#957168}

--

wpt-commits: 817a0a463101c451223c6f67d1298858694e8af8
wpt-pr: 32302
testing/web-platform/tests/html/canvas/element/drawing-text-to-the-canvas/2d.text.drawing.style.spacing.html
testing/web-platform/tests/html/canvas/offscreen/text/2d.text.drawing.style.spacing.html
testing/web-platform/tests/html/canvas/offscreen/text/2d.text.drawing.style.spacing.worker.js
testing/web-platform/tests/html/canvas/tools/yaml/element/drawing-text-to-the-canvas.yaml
testing/web-platform/tests/html/canvas/tools/yaml/offscreen/text.yaml