Fix accidental settings differences between CanvasRenderingContext2D and OffscreenCanvasRenderingContext2D
DRANK

There is a lot of duplicated spec text for CanvasRenderingContext2D and OffscreenCanvasRenderingContext2D, especially related to how CanvasRenderingContext2DSettings is handled. As with all things that are duplicated, there are accidental divergences. In particular, several members of CanvasRenderingContext2DSettings are accidentally ignored in the OffscreenCanvasRenderingContext2D spec text. Additionally, the getContextAttributes method was accidentally not added to OffscreenCanvasRenderingContext2D when it was added to CanvasRenderingContext2D. This creates a new mixin interface CanvasSettings. This will unify the accidentally diverged paths, and also prevent this from happening in the future. See details here. An archeology of where the accidental divergence came from is in this issue. To the extent that original authors are still contact-able, they have confirmed that the divergences were indeed accidental oversights. At least two implementers are interested (and none opposed): Chromium WebKit: TBD tentative approval Gecko: TBD Tests are written and can be reviewed and commented upon at: https://chromium-review.googlesource.com/c/chromium/src/+/6157844 (awaiting implementation) Implementation bugs are filed: Chromium: https://crbug.com/388437261 Gecko: https://bugzilla.mozilla.org/show_bug.cgi?id=1940414 WebKit: TBD Corresponding HTML AAM & ARIA in HTML issues & PRs: N/A MDN issue: https://github.com/mdn/content/issues/37727 The top of this comment includes a clear commit message to use. /canvas.html ( diff ) /index.html ( diff )

github.com
Related Topics: Web Standards / Browsers